-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Serialize with CBOR instead of pickle
- I was having serious issues using pickle - $ uvx hatch version rc - updated uv handles dynamic project version in uv.lock
- Loading branch information
Showing
4 changed files
with
37 additions
and
47 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -25,12 +25,12 @@ $ pip install ubank | |
Register a new passkey with ubank: | ||
|
||
```console | ||
$ python -m ubank [email protected] --output passkey.pickle | ||
$ python -m ubank [email protected] --output passkey.cbor | ||
Enter ubank password: | ||
Enter security code sent to 04xxxxx789: 123456 | ||
``` | ||
|
||
The above writes a new passkey to `passkey.pickle`. | ||
The above writes a new passkey to `passkey.cbor`. | ||
You'll be prompted for your ubank username and SMS security code. | ||
|
||
> [!CAUTION] | ||
|
@@ -43,7 +43,7 @@ Use your passkey to access ubank's API in a Python script: | |
from ubank import Client, Passkey | ||
|
||
# Load passkey from file. | ||
with open("passkey.pickle", "rb") as f: | ||
with open("passkey.cbor", "rb") as f: | ||
passkey = Passkey.load(f) | ||
|
||
# Authenticate to ubank with passkey and print account balances. | ||
|
@@ -125,7 +125,7 @@ Run tests locally: | |
$ uv run pytest -v | ||
``` | ||
|
||
`test_ubank_client` requires a valid `passkey.pickle` file for testing ubank | ||
`test_ubank_client` requires a valid `passkey.cbor` file for testing ubank | ||
authentication. | ||
Skip this test using the following expression: | ||
|
||
|
@@ -146,12 +146,6 @@ Old: 2.0.0 | |
New: 2.1.0 | ||
``` | ||
|
||
Update uv lockfile: | ||
|
||
```console | ||
$ uv lock | ||
``` | ||
|
||
Update `test_version` test. | ||
|
||
Create version tag and push to GitHub: | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.