A fake data generator (a faker) for Python, extended with Rust.
This module contains bindings to [fake-rs](https//github.com/cksac/fake-rs),
a fake-data generator written in [Rust](https//www.rust-lang.org/).
The reason for this library is performance. When you're generating large amounts
of fake data, this library will serve you well.
## Example API
```python
from pyfakers import Name
print(Name.first_name())
print(Name.last_name())
```
## Installation
Install with pip, wheel files are provided for Linux and macOS
THIS WONT WORK YET (BUT WILL SHORTLY) pip install pyfakers
## Building from source
Install libffi, python3 headers, setuptools and wheel. The following command will install these on Ubuntu
apt-get install libffi-dev python3-dev python3-setuptools python3-wheel
Check out the repository
git clone git@github.comdowwie/pyfakers.git
cd pyfakers
In order to compile the Rust code, you'll need to have Rust nightly toolchain installed and enabled.
Use rustup to set this up, find installation instructions for rustup at https//www.rustup.rs/
To use Rust nightly, run the following commands (from the project root)
rustup update nightly
rustup override add nightly
Install the ``pipenv`` utility from pypi
pip install pipenv
Install dependencies (from the project root)
pipenv install
Launch a virtual environment (from the project root)
pipenv shell
Now you can build the package
python3 setup.py bdist_wheel
Install the wheel
pip install dist/<wheel file name>
## Full API
```python
from pyfakers import Name, Internet, Company, Address, PhoneNumber
print(Name.first_name())
print(Name.last_name())
print(Name.full_name())
print(Name.title_descriptor())
print(Name.title_level())
print(Name.title_job())
print(Name.title())
print(Internet.free_email_provider())
print(Internet.domain_suffix())
print(Internet.user_name())
print(Internet.free_email())
print(Internet.safe_email())
print(Company.suffix())
print(Company.name())
print(Company.buzzword())
print(Company.catch_phrase())
print(Company.bs())
print(Company.profession())
print(Company.industry())
print(Address.time_zone())
print(Address.city_prefix())
print(Address.city_suffix())
print(Address.street_suffix())
print(Address.state())
print(Address.state_abbr())
print(Address.city())
print(Address.street_name())
print(Address.building_number())
print(Address.street_address())
print(Address.secondary_address())
print(Address.postal_code())
print(Address.latitude())
print(Address.longitude())
print(PhoneNumber.phone_number())
```
Metadata
Release files for pyfakers 0.1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| pyfakers-0.1.0-py2.py3-none-manylinux1_x86_64.whl | Python 3, Python 2 | none | Linux glibc 2.5+ x86-64 | Details for pyfakers-0.1.0-py2.py3-none-manylinux1_x86_64.whl |
Release files / pyfakers-0.1.0-py2.py3-none-manylinux1_x86_64.whl
| Download URL | pyfakers-0.1.0-py2.py3-none-manylinux1_x86_64.whl |
|---|---|
| Size | 853.1 kB |
| Tags | Linux glibc 2.5+ x86-64 Python 2 Python 3 |
|
SHA-256 checksum How to use checksums |
98c3a29bb7d962cb3c927e8f2d8e449d0b96ad7118e1ba6943c7c853d4d4fbb1
|
|
BLAKE2b-256 checksum How to use checksums |
66413c54ba40f49a0e1da5cc6ca8c4c54195a120f130f06b9176dc5c8dacb69f
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
Security for pyfakers 0.1.0
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.