Skip to content

Conversation

mvadari
Copy link
Collaborator

@mvadari mvadari commented Sep 14, 2022

High Level Overview of Change

This PR fixes an issue with the AuthAccount models such that they had to have their account field capitalized.

Context of Change

The dictionary with the only field being account matched a PathStep, which needs to be entirely lowercase. However, AuthAccount needs to be autocapitalized.

Type of Change

  • Bug fix (non-breaking change which fixes an issue)

Test Plan

Tests pass now.

@mvadari mvadari changed the base branch from master to amm September 14, 2022 23:16
@mvadari mvadari marked this pull request as ready for review September 14, 2022 23:18
@khancode khancode merged commit fc82cf3 into amm Sep 15, 2022
@khancode khancode deleted the auth-account-fix branch September 15, 2022 01:10
khancode added a commit that referenced this pull request Aug 18, 2023
* add AMMInstanceCreate

* update definitions to get AMMInstanceCreate working

* fix lint errors

* add unit test for Instance Create

* fix lint errors

* fix definitions and change AmmCreate to AMMInstanceCreate

* fix lint error

* add AMMInfo

* update AMMInfo docstring

* add docstring to AMMInfo params

* update definitions.json

* remove AMMAccount from AMMInstanceCreate model

* add AMMDeposit

* fix lint errors

* add AMMWithdraw

* add AMMVote

* add AMMBid

* fix typo

* update AMMBid test

* add MaxSlotPrice param to AMMBid

* refactor test

* update definitions and replace AMMHash with AMMID

* update lptokens type to IssuedCurrencyAmount

* assert with error message

* assert with error messages for AMMInstanceCreate and amm_info

* move to_xrpl tests to test_base_model

* rename lptokens to lp_tokens

* update amm_info request params to be in snake_case

* update docstrings

* reorder SPECIAL_CAMELCASE_STRINGS to alphabetical order

* refactor ABBREVIATIONS to be set in one place

* rename LPTokens to LPToken

* update CHANGELOG.md

* fix typo

* fix lint error

* refactor max trading fee to be in one place

* update amm_bid error message

* add AuthAccount base model for AMMBid

* update definitions to fix AMM in LEDGER_ENTRY_TYPES

* update CHANGELOG.md to specify XLS-30

* update wording on AMMDeposit & AMMWithdraw validation errors

* add negative FeeVal check

* add negative TradingFee check

* fix lint error

* export AuthAccount model

* add AuthAccount and refactor special case models check

* revert Path and _value_to_tx_json() changes

* fix AuthAccount capitalization issues (#432)

Co-authored-by: Omar Khan <[email protected]>

* add AMMBid codec-fixture

* add AMMInstanceCreate codec-fixture

* update definitions.json with different AuthAccounts number

* remove AMM codec-fixtures

* Change amm_info asset parameters to Currency type

* API name changes with updated definitions.json

* rename amm_info param asset1 -> asset

* change AMM_MAX_TRADING_FEE to 1% and rename fee_val to trading_fee

* rename MinBidPrice -> BidMin and MaxBidPrice -> BidMax

* update definitions to change Asset & Asset2 nth values to 3 & 4

* Use asset/asset2 instead of amm_id for Deposit/Withdraw/Bid/Vote

* update definitions

* add Issue type

* add flags to AMM deposit & withdraw

* add Issue model

* add Issue type to models with asset & asset2; remove amm_id

* resolve lint errors

* rename LPToken in amm deposit & withdraw

* update docstrings

* add AMM codec-fixtures

* add one asset withdraw & withdraw all tests

* update definitions.json with refactored error codes

* add Owner Reserve Fee for AMMCreate transaction

* refactor asset pair to be Currency type

* update amm_info asset pair to be Currency type and remove Issue model

* update definitions and codec-fixtures

* update DiscountedFee definition

* update definitions and codec-fixtures

* update definitions

* remove sidechain method

* small refactor

* update docstrings

* refactor _value_to_tx_json to remove special case for auth_account

* refactor AuthAccount to be a NestedModel

* remove test_base_model tests for amm

* add test_to_xrpl_auth_accounts

* fix indentation with tests

* update definitions

* add AMMDelete

* add AMMDelete docstring

---------

Co-authored-by: Mayukha Vadari <[email protected]>
vlad-trmlabs pushed a commit to trmlabs/xrpl-py that referenced this pull request Mar 22, 2024
* add AMMInstanceCreate

* update definitions to get AMMInstanceCreate working

* fix lint errors

* add unit test for Instance Create

* fix lint errors

* fix definitions and change AmmCreate to AMMInstanceCreate

* fix lint error

* add AMMInfo

* update AMMInfo docstring

* add docstring to AMMInfo params

* update definitions.json

* remove AMMAccount from AMMInstanceCreate model

* add AMMDeposit

* fix lint errors

* add AMMWithdraw

* add AMMVote

* add AMMBid

* fix typo

* update AMMBid test

* add MaxSlotPrice param to AMMBid

* refactor test

* update definitions and replace AMMHash with AMMID

* update lptokens type to IssuedCurrencyAmount

* assert with error message

* assert with error messages for AMMInstanceCreate and amm_info

* move to_xrpl tests to test_base_model

* rename lptokens to lp_tokens

* update amm_info request params to be in snake_case

* update docstrings

* reorder SPECIAL_CAMELCASE_STRINGS to alphabetical order

* refactor ABBREVIATIONS to be set in one place

* rename LPTokens to LPToken

* update CHANGELOG.md

* fix typo

* fix lint error

* refactor max trading fee to be in one place

* update amm_bid error message

* add AuthAccount base model for AMMBid

* update definitions to fix AMM in LEDGER_ENTRY_TYPES

* update CHANGELOG.md to specify XLS-30

* update wording on AMMDeposit & AMMWithdraw validation errors

* add negative FeeVal check

* add negative TradingFee check

* fix lint error

* export AuthAccount model

* add AuthAccount and refactor special case models check

* revert Path and _value_to_tx_json() changes

* fix AuthAccount capitalization issues (XRPLF#432)

Co-authored-by: Omar Khan <[email protected]>

* add AMMBid codec-fixture

* add AMMInstanceCreate codec-fixture

* update definitions.json with different AuthAccounts number

* remove AMM codec-fixtures

* Change amm_info asset parameters to Currency type

* API name changes with updated definitions.json

* rename amm_info param asset1 -> asset

* change AMM_MAX_TRADING_FEE to 1% and rename fee_val to trading_fee

* rename MinBidPrice -> BidMin and MaxBidPrice -> BidMax

* update definitions to change Asset & Asset2 nth values to 3 & 4

* Use asset/asset2 instead of amm_id for Deposit/Withdraw/Bid/Vote

* update definitions

* add Issue type

* add flags to AMM deposit & withdraw

* add Issue model

* add Issue type to models with asset & asset2; remove amm_id

* resolve lint errors

* rename LPToken in amm deposit & withdraw

* update docstrings

* add AMM codec-fixtures

* add one asset withdraw & withdraw all tests

* update definitions.json with refactored error codes

* add Owner Reserve Fee for AMMCreate transaction

* refactor asset pair to be Currency type

* update amm_info asset pair to be Currency type and remove Issue model

* update definitions and codec-fixtures

* update DiscountedFee definition

* update definitions and codec-fixtures

* update definitions

* remove sidechain method

* small refactor

* update docstrings

* refactor _value_to_tx_json to remove special case for auth_account

* refactor AuthAccount to be a NestedModel

* remove test_base_model tests for amm

* add test_to_xrpl_auth_accounts

* fix indentation with tests

* update definitions

* add AMMDelete

* add AMMDelete docstring

---------

Co-authored-by: Mayukha Vadari <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants