Lnurl

Latest version: v0.5.1

Safety actively analyzes 629564 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 2 of 3

0.3.3

Added
- Support for `.onion` Tor URLs without SSL certificate (both http and https are valid for `TorUrl`).

Fixed
- `__repr__` mixin.

0.3.2

Added
- Custom exception when `lnurl.get()` request fails.

Fixed
- `LNURL_FORCE_SSL` and `LNURL_STRICT_RFC3986` environment variables are `True` when value is `"1"`.

0.3.1

Fixed
- Stupid import error for `Literal` in Python 3.8 :(

0.3.0

Added
- Changelog.
- New LNURL-pay metadata mime types for images.
- New `LnurlPayMetadata` properties: `.images` (_list_) and `.text` (_str_).
- `LnurlPayMetadata` now checks if the required "text/plain" entry exists.
- `LNURL_FORCE_SSL` and `LNURL_STRICT_RFC3986` environment variables.

Changed
- For `LnurlPayMetadata` there is no `.list` property anymore: use `.list()` method instead.
- Hashed metadata should be accessed now with `LnurlPayResponse().metadata.h` instead of `LnurlPayResponse().h`
- `HttpsUrl` type is now called `Url`.
- `Url` is not valid when control characters are found or if it is not RFC3986 compliant.

Fixed
- Fix `Url` type tests.
- Install `typing-extensions` only if Python version < 3.8.

0.2.0

Added
- Extra documentation in README.
- Full validation of LNURL responses using `pydantic` models.
- `.json()` and `.dict()` methods to export data from responses. Data is exported in camelCase
by default, but internally all properties are still pythonic (snake_case).
- `LnurlResponse.from_dict()` helper to parse a response and assign the right type.
- `handle()` function to get a typed response directly from a LNURL if you have `requests` installed.
- Typed returns for `encode()` and `decode()` functions.
- `black` for code formating.

Changed
- Responses now require that you pass kwargs instead of a dictionary: use `LnurlResponseModel(**dict)`
instead of the previous `LnurlResponse(dict)`
- `HttpsUrl` uses default `pydantic` validations now.

0.1.1

Added
- Get URL checks back into `validate_url()` function (from 0.0.2).

Changed
- We can now parse error responses in lowercase (even if this is not in the spec).

Page 2 of 3

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.