Datapush
Datapush is a Python package that generate data to MySQL Database dynamically.
When you need data for MySQL for some reasons (for test), and too lazy to make mock data, here is the answer.
Just enter your table, datapush will check each column and automatically generate the appropriate data!
Download
pip install datapush
Usage
# Connect to db
conn = datapush.mysql.connect(
host='localhost',
port=3306,
user='root',
password='',
database=''
)
# Make generator with connection
generator = datapush.Generator(conn)
# Generate!
generator.generate(
table='example_table'
)
Option
In generator.generate(), there has several options.
Args:
- table (str): The name of the table.
- count (int): The number of data you want to generate. (default: 10)
- **option (dict): Some specific data for each column
you want to generate (uuid, username, ip, etc...)
ex) user=id, uuid=uuid, ip_address=ip,
ex) column_name=type
Extra Usage
generator.generate(
table='example_table',
count=1000,
char_col='ip', # column_name is char_col and make unique ip
text_col='id', # column_name is text_col and make unique id
varchar_col='uuid' # column_name is varchar_col and make unique uuid
)
Note
Currently, we don't support spartial data type (geometry, point, polygon etc...)
Metadata
Release files for datapush 1.0.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| datapush-1.0.1.tar.gz | 6.8 kB | Without provenance | Details for datapush-1.0.1.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| datapush-1.0.1-py3-none-any.whl | Python 3 | none | any | Details for datapush-1.0.1-py3-none-any.whl |
Total release size: 19.0 kB
Release files / datapush-1.0.1.tar.gz
| Download URL | datapush-1.0.1.tar.gz |
|---|---|
| Size | 6.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
ddbaffeb8088b4df4c24ceea34c627eeeb5082405beb2cd5ebc2fe46be92db69
|
|
BLAKE2b-256 checksum How to use checksums |
fd4b8f49962b4ade94af9b9637ec1937bae824bfaecbb726c4fcaac790cea65a
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/5.1.1 CPython/3.11.9
|
Release files / datapush-1.0.1-py3-none-any.whl
| Download URL | datapush-1.0.1-py3-none-any.whl |
|---|---|
| Size | 12.3 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
4e2992414721895440ff31a49047d24e3a8eb98625f2e82fdea9ae622b3f212b
|
|
BLAKE2b-256 checksum How to use checksums |
eab5e5f61debb093eb74344e5e9eff04a9dc04a1b46cfb0f79fcb26f1444539b
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/5.1.1 CPython/3.11.9
|
Security for datapush 1.0.1
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.