semvec/pypi-packages huggingface dataset:
random-strings 0.1.1
strings that are ✨ random ✨
License: MIT
Requires Python: >=3.6, <4
Keywords: random,strings,utilities,security

# random-strings

Generate strings that are ✨ random ✨

## how to install

```bash
$ pip install random-strings
```

## how to use

```python

>>> from random_strings import random_string
>>> random_string(5)
'YSuz5'

```

## advanced usage

```python
from random_strings import random_hex, random_string

password = random_string(16)
SECRET_KEY = random_string(64)

# hexadecimal characters
SECURE_TOKEN = random_hex(128)

# no uppercase letters
verification_code = random_string(12,upper=False)
# only uppercase letters
verification_code = random_string(12,lower=False,digit=False)

# custom characters
characters = '23456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz'
verification_code = random_string(12,character_string=characters)

```

## more examples

```python

>>> from random_strings import *

>>> random_hex(16)
'ec583ef0aaa226cba9cb07e3dc2e623c'

>>> random_uuid()
'85273146-3ad8-489f-9964-e7af16ab6a26'

>>> random_uuid(dashes=False)
'a33ee36ad08242e4a2a819147f084a51'
```

## more details

Generated strings are suitable for cryptographically secure usecase

See `os.urandom`, `random.SystemRandom` and PEP 506 for more details on how it works.

also, this package is named `random-strings`.
There are other packages on pypi with similar names but they don't do the same thing.
gaps 0.1.1
Generalized assignment problem solver
License: MIT
Requires Python: >=3.7,<4.0
Keywords: assignment,assign,optimizer,search

# GAPS

_Generalized Assignment Problem Solver_

This code aims to implement an efficient solver for the generalized assignment problem.

## The generalized assignment problem

The generalized assignment problem is described quite well [on Wikipedia](https://en.wikipedia.org/wiki/Generalized_assignment_problem).

This code actually allows for further generalization, multiple agents to perform a single task (regulated by a task budget).

## The implementation

The implementation is a simple depth-first search algorithm. Therefore, it does not work well for very large problems.

The depth-first search expands most promising nodes first. True maximum assignment is guaranteed when algorithm is allowed to complete. Otherwise, the assignment printed last may be used as a best guess.

The code makes use of `frozendict` to keep track of the set of assignments.

## Running the code

Solving your assignment problem is easy. Just specify your assignment problem (refer to main method in `assign.py` for an example), then run it. An example problem specification is given, to make clear what syntax is expected.

The code offers a few features:
* Optional 'hard assignment' initializes the assignment with certain agents assigned to certain tasks
* Optional 'fair' parameter maximizes the profits related to the least profitable task (and thus equalizes the profits among tasks).
* Optional 'complete' parameter requires agents and tasks to fully use their budgets.
* 'verbose' option prettily prints the assignment information after the code finishes. May be turned off.
Quart-Authorization-Discord 1.0.3
Quart Discord Authorization Library
License: MIT

# Quart-Authorization
## A Library For Quart Discord Authorization

_Note: This Fixed  Version Of [This Package](https://pypi.org/project/quart-oauth2-discord.py/)_

### Whats Changed In This Package?

- Some Errors Fixed Like Unclosed Clients
- logout() Function Errors Fixed
- Added .is_logged() Function

### Usage

```py
from Quart_Authorization_Discord import DiscordOauth2Client
from Quart import Quart, redirect, url_for, render_template_string

app = Quart(__name__)
app.secret_key = b"random bytes representing quart secret key"
app.config['DISCORD_CLIENT_ID'] = "Client ID here"
app.config['DISCORD_CLIENT_SECRET'] = 'CLIENT_SECRET_HERE'
app.config['SCOPES'] = ['identify', 'guilds']
app.config['DISCORD_REDIRECT_URI'] = 'http://127.0.0.1:5000/callback'
app.config['DISCORD_BOT_TOKEN'] = "Token"

client = DiscordOauth2Client(app)

@app.route("/")
async def index():
    if client.is_logged():
        return "You Are Already Logged In, Go To This Page: /me"
    else:
        return "You Are Not Logged In, Go To Authorization: /login"

@app.route("/login")
async def login():
    return await client.create_session()

@app.route("/logout")
async def logout():
    await client.logout()
    return redirect(url_for("index"))

@app.route("/callback")
async def callback():
    await client.callback()
    return redirect(url_for("index"))

@app.route("/me")
@client.is_logged_in # Checks If User Logged In, Raises 401
async def me():
    user = await client.fetch_user()
    return await render_template_string("""<html><head></head>
<body><p>You Are Succesfully Logged In As {{user.name}}</p>
</html>    
""",user=user)

@app.errorhandler(401)
async def handle_unathorized(e):
    return redirect(url_for("login"))

if __name__ == "__main__":
    app.run()
```

#### This Package Still On Development.
Bugs And Errors Can Be Found While Using. Please [Contact Me](https://discord.gg/MeaWMrVX) If You Found Any Of These.
abero 1.0.6
Analyze multiple files for similarity and/or uniqueness.
License: MIT
Requires Python: >=3.6
Keywords: Python,similarity,diff,compare,files

![](/resources/banner.png)

# runner
Analyze multiple files for similarity and/or uniqueness.
Finding similarities of works duplicated from one or more part of different works to create a seemingly unique one can be difficult because of different strategies being used, but this can be done better with a software like runner.

## Requirements
- [Arkivist](https://pypi.org/project/arkivist/) `pip install arkivist`

## Usage
Install the latest abero package, upcoming versions might introduce unannounced changes, so a virtual environment is a must have before installation.
```bash
pip install -U abero
```

To integrate abero into your Python codes, check the code snippet below:
```python
import abero

abero.analyze(directory, extension="txt", threshold=80, template=None, skipnames=0, group=0, unzip=0, reset=0)
```

## CLI Usage
```bash
# usage: runner [-h] -d directory [-e extension] [-c control] [-t threshold] [-u unzip] [-s skipnames] [-g group] [-r reset]

py runner.py -d "<path_to_files>" -e "txt" -c "<path_to_control_file>" -t 1 -u 1 -s 1 -r 1
```

1. `-d <path>` - Full path of the dirctory containing the files to analyze.
2. `-e <txt>` - List of allowed file extensions to analyze.
3. `-c <*.txt>` - Full path of the control file.
4. `-t <80>` - Threshold level for uniqueness, treats similarity below threshold as unique (1-100; default = 0)
5. `-u <0>` - Unzip/extract ZIP files (0-1; default = 0)
6. `-s <0>` - Skip files with common names (0-1; default = 0)
7. `-g <1>` - Only compare if files contains the same identifier (0-1; default = 1)

&emsp; **Example:** student1*_set1*.py >> student2*_set1*.py

8. `-r <0>` - Reset analytics before execution (0-1; default = 0)

## Control File
Control file contains words or phrases, checked line-by-line, that are deem allowed to be contained in all files to analyzed; therefore, if found on the test files, it will not be flagged as duplicate work.

## Features
- [x] Unzip feature
- [x] File comparison 
- [x] Threshold levels
- [x] Skip / group compare
- [ ] Diff tool, content viewer

## Did you know?
The repository name `abero` was inspired from the words aberrant and runner (Latin), which may mean deviating or being absent.