Example SDK usage - Python
The below code covers a scenario for some back-end system where some process must fetch stock data from a database (e.g. MySQL) and process this data so that it is in a format required by the client to display, based on a ticker symbol and fetching and processing this data is expensive. Caching the data provides a way of speeding up this process.
from GhostDB.cache import Cache
cache = Cache("my_ghostdb.conf")
def getStockData(ticker_smbl):
# Fetch data from cache
stock_data = cache.get(ticker_smbl)
if not stock_data:
# Fetch from MySQL.
# After any processing, we can
# assume our computed value is stored in
# a variable called stock_data
# Store result in cache
cache.put(ticker_smbl, stock_data)
return stock_data
return getStockData("AMZN")
Metadata
Release files for ghostdb 0.9
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 |
|---|---|---|---|---|
| ghostdb-0.9.tar.gz | 6.4 kB | Without provenance | Details for ghostdb-0.9.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| ghostdb-0.9-py3-none-any.whl | Python 3 | none | any | Details for ghostdb-0.9-py3-none-any.whl |
Total release size: 14.2 kB
Release files / ghostdb-0.9.tar.gz
| Download URL | ghostdb-0.9.tar.gz |
|---|---|
| Size | 6.4 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
c4ca5912ae28bc1bb8d5150cc43e8bde59e907ba423d487e4e335ec210c2edb2
|
|
BLAKE2b-256 checksum How to use checksums |
6779f9b90ad57f3bdcb96257744840245424c52b4b5ecfe8e620b77810a4b0ce
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/46.1.1 requests-toolbelt/0.9.1 tqdm/4.43.0 CPython/3.6.9
|
Release files / ghostdb-0.9-py3-none-any.whl
| Download URL | ghostdb-0.9-py3-none-any.whl |
|---|---|
| Size | 7.8 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
ccc2b89e6650af50cfb908cfb1a120d126ecdc79eae50b0f08cfe70ab4347d8a
|
|
BLAKE2b-256 checksum How to use checksums |
79ffce231d50d812ce3949c8ee2dceaa1ac5a1f97b7962d230ffb8a4c85bce52
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/46.1.1 requests-toolbelt/0.9.1 tqdm/4.43.0 CPython/3.6.9
|
Security for ghostdb 0.9
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.