semvec/pypi-packages huggingface dataset:
libs-appium 0.0.1
A small example package
Requires Python: >=3.6


# Make sure you have upgraded version of pip
Windows
```
py -m pip install --upgrade pip
```

Linux/MAC OS
```
python3 -m pip install --upgrade pip
```

## Create a project with the following structure
```
packaging_tutorial/
├── LICENSE
├── pyproject.toml
├── README.md
├── setup.cfg
├── src/
│   └── example_package/
│       ├── __init__.py
│       └── example.py
└── tests/
touch LICENSE
touch pyproject.toml
touch setup.cfg
mkdir src/mypackage
touch src/mypackage/__init__.py
touch src/mypackage/main.py
mkdir tests
```

## pyproject.toml 

This file tells tools like pip and build how to create your project

```
[build-system]
requires = [
    "setuptools>=42",
    "wheel"
]
build-backend = "setuptools.build_meta"
```
build-system.requires gives a list of packages that are needed to build your package. Listing something here will only make it available during the build, not after it is installed.

build-system.build-backend is the name of Python object that will be used to perform the build. If you were to use a different build system, such as flit or poetry, those would go here, and the configuration details would be completely different than the setuptools configuration described below.


# Setup.cfg setup
Using setup.cfg is a best practice, but you could have a dynamic setup file using setup.py

```
[metadata]
name = example-pkg-YOUR-USERNAME-HERE
version = 0.0.1
author = Example Author
author_email = author@example.com
description = A small example package
long_description = file: README.md
long_description_content_type = text/markdown
url = https://github.com/pypa/sampleproject
project_urls =
    Bug Tracker = https://github.com/pypa/sampleproject/issues
classifiers =
    Programming Language :: Python :: 3
    License :: OSI Approved :: MIT License
    Operating System :: OS Independent

[options]
package_dir =
    = src
packages = find:
python_requires = >=3.6

[options.packages.find]
where = src

```
# Running the build
### Make sure your build tool is up to date
Windows
```
py -m pip install --upgrade build
```
Linux/MAC OS
```
python3 -m pip install --upgrade build
```


### Create the build
```
py -m build
```

### Upload to pypi
```
twine upload dist/*
```














### References
https://packaging.python.org/tutorials/packaging-projects/
zenlib-desultory 1.0.0
Zen library, a collection of useful functions
Requires Python: >=3.9

# Zenlib

Personal functions, classes, and decorators used in some of my projects


## Logging

### @loggify

This decorator can be added to any class to initialize it with a logger, and add extra logging functionality to that class

### ColorLognameFormatter

A `logging.Formatter` which colors the loglevel portion.

## Threading

### @threaded

Runs the wrapped function in a thread when called.

Adds the thread to `_threads` within the object.

If an exception is raised, it will be added to `self._threads` in the form `(thread, exception_queue)`.

### @thread_wrapped('threadname')

Meant to be used with `@add_thread`, the argument is the threadname that function is associated with.

### @add_thread('threadname', 'target_function', 'description')

`@add_thread` decorates a class, and adds `create_{threadname}_thread`, `start_` and `stop_` functions which are used to handle thread management of a `thread_wrapped` function.

Once added, a thread will be added to `self.threads[threadname]`.

## Util

### @handle_plural

This decorator is designed to be added to functions, automatically expands pased dicts/lists into the function it wraps.

> This function does not return values for most operations, it is designed to be used within a class where the wrapped function sets class attributes.

### NoDupFlatList

Essentially a dumb set, but is a list so is ordered

### pretty_print

A function designed to print complex data structures in a nice manner

### replace_file_line

Replaces a line in a file

`def replace_file_line(file_path, old_line, new_line):`

### update_init

Used by `@add_thread`, appends the passed function to the init of a class.
pbscraper 1.0.26
A small example package
Requires Python: >=3.8.10

# Example Package

This is a simple example package. You can use
[Github-flavored Markdown](https://guides.github.com/features/mastering-markdown/)
to write your content.

# How to build package

This is a note for how to packaging a project into Pypi

- Root directory should contain __init__.py file, means it's a library
- Prepare pyporject.toml
- python -m build 產生dist/ will load pyproject.toml
- pip install twine
- Prepare Pypi Account
- save .pypirc 
- twine upload --config-file .pypirc dist/*

PS. package_dir={'mypkg': 'src/mypkg'},
PS. Under root should have a folder of package name as same as project name.
picobox 4.0.0
Dependency injection framework designed with Python in mind.
Requires Python: >=3.8

Picobox
=======

.. image:: https://img.shields.io/pypi/l/picobox
   :target: https://pypi.python.org/pypi/picobox
   :alt: PyPI - License

.. image:: https://img.shields.io/pypi/v/picobox.svg
   :target: https://pypi.python.org/pypi/picobox
   :alt: PyPI - Version

.. image:: https://img.shields.io/pypi/pyversions/picobox
   :target: https://pypi.python.org/pypi/picobox
   :alt: PyPI - Python Versions

.. image:: https://img.shields.io/pypi/dm/picobox
   :target: https://pypi.python.org/pypi/picobox
   :alt: PyPI - Downloads

Picobox is opinionated dependency injection framework designed to be clean,
pragmatic and with Python in mind. No complex graphs, no implicit injections,
no type bindings – just picoboxes, and explicit demands!


Why?
----

Because we usually want to decouple our code and Python lack of clean and
pragmatic solutions (even third parties).


Features
--------

* Support both values and factories.
* Support scopes (e.g. singleton, threadlocal, contextvars).
* Push boxes on stack, and use the top one to access values.
* Thread-safe.
* Lightweight (~500 LOC including scopes).
* Zero dependencies.
* Pure Python.
* Annotated with types.



Quickstart
----------

First

.. code:: bash

    $ [sudo] python -m pip install picobox

and then

.. code:: python

    import picobox
    import requests


    @picobox.pass_("conf")
    @picobox.pass_("requests", as_="session")
    def get_resource(uri, session, conf):
        return session.get(conf["base_uri"] + uri)


    box = picobox.Box()
    box.put("conf", {"base_uri": "http://example.com"})
    box.put("requests", factory=requests.Session, scope=picobox.threadlocal)

    with picobox.push(box):
        get_resource("/resource", requests.Session(), {})
        get_resource("/resource", requests.Session())
        get_resource("/resource")


Links
-----

* Documentation: https://picobox.readthedocs.io
* Source: https://github.com/ikalnytskyi/picobox
* Bugs: https://github.com/ikalnytskyi/picobox/issues