Django-polaris

Latest version: v2.5.0

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

Scan your dependencies

Page 4 of 13

2.1.0

This release adds support for using SEP-38 quotes in SEP-6, 24, and 31 transactions. It also adds support for authenticating, sending payments to, and receiving payments from multiplexed accounts.

Breaking Changes

- SEP-24 templates have been updated with altered template variables. If you're using the default templates provided by Polaris, ensure your views are still rendering correctly. See the `.content_for_template()`integration function documentation for a detailed list of changes to the template variables.

Endpoints

- Added all SEP-38 Anchor RFQ API endpoints
- Added SEP-6 `GET /deposit-exchange` and `GET /withdraw-exchange` endpoints for using quotes
- Updated SEP-31 `POST /transactions` to accept quotes
- SEP-10 authenticates clients using shared accounts

Integrations

- `QuoteIntegration` base class for SEP-38 integrations
- The integration functions correspond directly to endpoints defined in the specification
- `.content_for_template()` can now return a `template_name` key-value pair for rendering a custom template
- The default template variables present in `deposit.html` and `withdraw.html` have been greatly expanded, and the values can be overridden using `.content_for_template()`. The integration function documentation for specifics.

Data Model

- Add the following models: `Quote`, `ExchangePair`, `OffChainAsset`, & `DeliveryMethod`
- Adds a `Transaction.account_memo` column for a shared account using memos to disambiguate users
- Adds a `Transaction.muxed_account` column. `Transaction.stellar_account` will always be the `G...` address derived from the muxed account, if present.
- Adds a `Transaction.quote` column
- Adds a `Transaction.fee_asset` column
- Adds a `Asset.sep38_enabled` column
- Updates the following fields to be nullable:
- `Transaction.deposit_fee_fixed`
- `Transaction.deposit_fee_percent`
- `Transaction.withdrawal_fee_fixed`
- `Transaction.withdrawal_fee_percent`
- `Transaction.send_fee_percent`
- `Transaction.send_fee_fixed`
- Updates `Transaction.kind` to support the following new values: `deposit-exchange` and `withdrawal-exchange`
- Added `Asset.asset_identification_format` property for using SEP-38 asset format

Environment Variables

- The python SDK's `ENABLE_SEP_0023` environment variable must be truthy

Miscellaneous

- `SEP10Token` now has the additional properties: `muxed_account`, `memo`

Bug Fixes

- `GET /transaction(s)` response bodies contained improperly formatted datetime strings

2.0.9

Dependencies

- Updates the `stellar-sdk` to `5.0.1`, resolving a dependency conflict with `aiohttp`

2.0.7

Bug Fixes

- SEP-24 `POST /deposit` and `POST /withdraw` endpoints would return `501 Not Implemented` if the anchor had not implemented the `.save_sep9_fields()` integration function, but saving these fields is optional
- Anchors can now ignore SEP-9 values passed in SEP-24 requests

2.0.6

Bug Fixes

- The `WithdrawalIntegration.save_sep9_fields()` function definition did not include the `token: SEP10Token` argument, which Polaris passes. This resulted in a `TypeError` thrown if SEP-9 fields were passed in withdrawal requests.
- This release adds the `token` parameter

2.0.5

Updates

- Handle cases where account balances contain liquidity pool shares

Dependencies

- Updates `stellar-sdk` to [v5.0](https://github.com/StellarCN/py-stellar-base/releases/tag/5.0.0) in preparation for the Stellar Network's [protocol 18 update](https://stellar.org/developers-blog/protocol-18-upgrade-guide?locale=en)

2.0.3

Bug Fixes

- SEP-24: `after_form_validation()` was not called prior to attempting to fetch the next form using `form_for_transaction()`
- This likely affects SEP-24 implementations that depend on state changes implemented in `after_form_validation()` to determine which form to return in calls to `form_for_transaction()`

Security

- [`sqlparse`](https://pypi.org/project/sqlparse/), a sub-dependency of Django, was listed as a direct dependency until Django requires v0.4.2 or above.

Page 4 of 13

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.