rfacts
a very simple wrapper around requests/aiohttp for uselessfacts.jsph.pl
provides 1 object that implements 2 methods, and 5 attributes.
the fact classmethods get and aget each take one argument, and return a fact instance:
each instance of fact has the following attributes:
-
id- Type[str] - the id of the fact -
source- Type[str] - the source for the fact -
permalink- Type[str] - the permanent link to this fact -
text- Type[str] - the text of the fact itself -
language- Type[str] - the language of the fact -
_raw- Type[dict] - the raw json returned from the api
examples:
from rfacts import fact
def main() -> None:
x = fact.get()
print(x.text)
if __name__ == "__main__":
main()
from rfacts import fact
import asyncio
async def main() -> None:
x = await fact.aget()
print(x.text)
if __name__ == "__main__":
asyncio.run(main())
Metadata
Release files for rfacts 0.1.0
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 |
|---|---|---|---|---|
| rfacts-0.1.0.tar.gz | 14.4 kB | Without provenance | Details for rfacts-0.1.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| rfacts-0.1.0-py3-none-any.whl | Python 3 | none | any | Details for rfacts-0.1.0-py3-none-any.whl |
Total release size: 28.8 kB
Release files / rfacts-0.1.0.tar.gz
| Download URL | rfacts-0.1.0.tar.gz |
|---|---|
| Size | 14.4 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
de4bfb692d4fd55108442c3a3898258c9b42a7742abc27382680647f8925ab1a
|
|
BLAKE2b-256 checksum How to use checksums |
ede9aa63410a0606038f38c170951e642a6ef8bf588a460eefc8676cb52a5f16
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.0 CPython/3.8.7
|
Release files / rfacts-0.1.0-py3-none-any.whl
| Download URL | rfacts-0.1.0-py3-none-any.whl |
|---|---|
| Size | 14.4 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
27877ced1959855d6069b519ad994c3241a96cb5c9c947dbbf03c9dfb8ca5491
|
|
BLAKE2b-256 checksum How to use checksums |
5bb921a8813b4ebe6e9ca71f6f68b8245da078bb300f88d1374d84339fc0b493
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.0 CPython/3.8.7
|
Security for rfacts 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.