semvec/pypi-packages huggingface dataset:
popstock 0.2.1
A lightweight package for fast evaluation of the stochastic GW energy density Omega_GW emitted by a population of binary black holes and/or neutron stars.
License: MIT
Requires Python: >=3.9

# popstock

A lightweight package for quick evaluation of the stochastic GW energy density `Omega_GW` emitted by a population of binary black holes and/or neutron stars.
Assumes Planck15 cosmology.
clash-of-clans-python-api 0.2.5
A wrapper for the official Clash of Clans API.
License: MIT
Requires Python: >=3.11

# Clash of Clans Python API Wrapper
[![PyPI - Version](https://img.shields.io/pypi/v/clash-of-clans-python-api)](https://pypi.org/project/clash-of-clans-python-api/)

An (in development) **asynchronous Python wrapper** for the official Clash of Clans API.  
This library simplifies accessing player and clan data, handling authentication, HTTP requests, and response parsing.

## Installation

```bash
pip install clash-of-clans-python-api
````

## Usage Example
```python
import asyncio
import os
from coc_api import ClashOfClansAPI
from coc_api.models import Player

API_TOKEN = os.getenv("API_TOKEN")
PLAYER_TAG = "#L8PRCJVL2"

async def main() -> None:
    """
    Example usage of the ClashOfClansAPI to fetch and print player data.
    """
    if not API_TOKEN:
        raise ValueError("API_TOKEN environment variable is not set.")

    api = ClashOfClansAPI(token=API_TOKEN, proxy=True)

    try:
        # Fetch player data
        player: Player = await api.players.get(PLAYER_TAG)
        print("Player Info:")
        print(f"Name: {player.name}")
        print(f"Town Hall Level: {player.town_hall_level}")
        print(f"Clan: {player.clan.name if player.clan else 'No clan'}")
    except Exception as e:
        print("An error occurred while fetching player data:")
        print(repr(e))
    finally:
        await api.close()

if __name__ == "__main__":
    asyncio.run(main())
```

## API Overview

### `ClashOfClansAPI(token: str, timeout: int = 10, proxy: bool = False)`

Main client class to interact with the Clash of Clans API.

* `token`: Your Clash of Clans API token.
* `timeout`: Request timeout in seconds (default: 10).
* `proxy`: If `True`, routes requests through RoyaleAPI's proxy.

#### Attributes:

* `players`: Access player-related API endpoints.
* `clans`: Access clan-related API endpoints.

### PlayerEndpoints

* `get(player_tag: str) -> Player`

  Fetch detailed information about a player.

* `verify_token(player_tag: str, token: str)`

  Verify a player token with the API.

### ClanEndpoints

* `get(clan_tag: str) -> Clan`

  Fetch detailed information about a clan.

## GoldPassEndpoint

* `get(unix: bool = False) -> GoldPass`

  Fetch start and endtime of the current goldpass season.

  * `unix`: If `True` returns start_time and end_time as unix timestampts instead of `datime.datime`. Defaults to False.
patcher-trex 0.1.0
An AI-powered CLI tool to enhance your coding workflow by fixing errors, modifying code, adding comments, and generating files.
License: MIT
Requires Python: >=3.7
Keywords: ai, cli, code-fix, debugging, patch, automation, gemini, stack-overflow

# AI Patch Tool 🛠️✨

An AI-powered CLI tool to enhance your coding workflow by fixing errors, modifying code, adding comments, and even generating full files — all powered by Python, Typer, and Google's Gemini API.

## 🔍 Features

- 📌 `searcherr`: Finds errors in your code and searches Stack Overflow for relevant solutions
- 🔧 `fix`: Automatically detects and corrects errors in your script using AI
- ✏️ `modify`: Take user input and modify code behavior accordingly
- 💡 `query`: Generate code files based on user intent and desired filetype
- 💬 `addComments`: Automatically add meaningful comments to code without changing its functionality

## 📦 Installation

```bash
pip install ai-patch-tool
```

## 🚀 Usage

```bash
# Fix errors in your code
patchtool fix script.py

# Search for error solutions
patchtool searcherr script.py

# Modify code behavior
patchtool modify script.py "add error handling"

# Generate new code files
patchtool query "create a web scraper" --filetype py

# Add comments to existing code
patchtool addComments script.py
```

## 🔧 Setup

Before using, make sure to set your Google Gemini API key:
```bash
export GEMINI_API_KEY="your-api-key-here"
```
intctl 0.111.0
INTELLITHING Bootstrap CLI for provisioning cloud resources
License: MIT
Requires Python: >=3.9

remove the existing package: rm -rf build/ dist/ *.egg-info
build again: python -m build 

upload to pypi: twine upload dist/* 















## 📦 Overview

The CLI now supports:

* 🔐 Secure login via browser-based device authorization (OAuth2-compliant)
* 🏢 Organization-scoped login (per session)
* 🔁 Automatic token refresh using offline tokens
* 👤 User context inspection (`whoami`)
* 👋 Session clearing (`logout`)

---

## 🧑‍💻 Commands

All auth-related commands are grouped under:

```bash
intctl auth <subcommand>
```

### 1. 🔐 `intctl auth login`

Start login flow via browser:

```bash
intctl auth login
```

**Flow:**

1. Prompts for organization ID or name
2. Opens Keycloak device login via browser
3. User authenticates (e.g., via password or IdP)
4. Token is issued and saved locally:

   * `access_token`: short-lived
   * `refresh_token`: long-lived
   * `username`, `org`: stored with token

**Stored at:** `~/.intctl_token`

---

### 2. 🧾 `intctl auth whoami`

Displays the current authenticated user and selected organization:

```bash
intctl auth whoami
```

**Output:**

```
👤 User: saeid
🏢 Org:  org-abc
```

---

### 3. 🚪 `intctl auth logout`

Clears the local session:

```bash
intctl auth logout
```

This deletes the token and org information stored in `~/.intctl_token`.

---

## 🔁 Token Refresh

The CLI automatically refreshes your token when it's near expiry:

* Refreshes if token expires in **less than 60 seconds**
* Uses stored `refresh_token` (offline token)
* Seamless; no user input required

### 🔧 Use in Code

```python
from login import get_valid_access_token

headers = {
    "Authorization": f"Bearer {get_valid_access_token()}",
    "X-Org": load_login_data()["org"]
}
```

---

## 🗂️ Token Storage Format

Stored as JSON at `~/.intctl_token`:

```json
{
  "access_token": "eyJhbGci...",
  "refresh_token": "eyJhbGci...",
  "username": "saeid",
  "org": "intellithing"
}
```

---

## 🔐 Keycloak Client Configuration Summary

| Field                | Value                   |
| -------------------- | ----------------------- |
| Client Type          | OpenID Connect (Public) |
| Device Auth Grant    | ✅ Enabled               |
| Offline Access Scope | ✅ Assigned              |
| Access Type          | Public                  |

---

## 🔄 Future Ideas (Optional Enhancements)

* `intctl auth switch-org`: change org context without full re-login
* Encrypt token file using `keyring` or GPG
* Add `intctl auth refresh` (manual token refresh)

---

## 📎 Example Usage

```bash
intctl auth login
intctl configure
intctl setup
intctl auth whoami
intctl auth logout
```

---