opni-nats-wrapper
This repo contains shared code used to build the pypi package https://pypi.org/project/opni-nats/ which is used in several opni services
Testing
- have your nats server running in another terminal. For Mac user, you can do:
brew install nats-server
nats-server
- test the script: (assume your nats server is running on nats://0.0.0.0:4222)
export NATS_SERVER_URL="nats://0.0.0.0:4222"
export NATS_USERNAME=
export NATS_PASSWORD=
cd src/opni_nats
python nats_wrapper.py
Contributing
We use pre-commit for formatting auto-linting and checking import. Please refer to installation to install the pre-commit or run pip install pre-commit. Then you can activate it for this repo. Once it's activated, it will lint and format the code when you make a git commit. It makes changes in place. If the code is modified during the reformatting, it needs to be staged manually.
# Install
pip install pre-commit
# Install the git commit hook to invoke automatically every time you do "git commit"
pre-commit install
# (Optional)Manually run against all files
pre-commit run --all-files
Metadata
Release files for opni-nats-test 0.0.2.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 | |
|---|---|---|---|
| opni-nats-test-0.0.2.0.tar.gz | 8.6 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| opni_nats_test-0.0.2.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 17.9 kB
Release files / opni-nats-test-0.0.2.0.tar.gz
| Download URL | opni-nats-test-0.0.2.0.tar.gz |
|---|---|
| Size | 8.6 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
08009b29bc973e3ee8033ff6b5de1db885c0559e84680fc38dccd090b705cf84
|
|
BLAKE2b-256 checksum How to use checksums |
b70cf34555b120a8eaaf219dc29304b6b75d0a03a2b27bbaaa7e34a21ebbde38
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.2 CPython/3.8.6
|
Release files / opni_nats_test-0.0.2.0-py3-none-any.whl
| Download URL | opni_nats_test-0.0.2.0-py3-none-any.whl |
|---|---|
| Size | 9.3 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
097b72091faef21e2c4a5f6a1cf38d1b747654f9c246720692ab004b3e2c1c4f
|
|
BLAKE2b-256 checksum How to use checksums |
8cdd208c5c94debffa3196ce68f8d8ae336d034f04900cbab40c7d4b629275e3
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.2 CPython/3.8.6
|