Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Release v12.1.0 #993

Merged
merged 3 commits into from
Jun 14, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 11 additions & 6 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,18 +6,23 @@ A breaking change will get clearly marked in this log.

## Unreleased


## [v12.1.0](https://github.com/stellar/js-stellar-sdk/compare/v12.0.1...v12.1.0)

### Added
- `contract` now exports the `DEFAULT_TIMEOUT` ([#984](https://github.com/stellar/js-stellar-sdk/pull/984)).
- `contract.AssembledTransaction` now has:
- `toXDR` and `fromXDR` methods for serializing the transaction to and from XDR. Additionally, `contract.Client` now has a `txFromXDR`. These methods should be used in place of `AssembledTransaction.toJSON`, `AssembledTransaction.fromJSON`, and `Client.txFromJSON` for multi-auth signing. The JSON methods are now deprecated. **Note you must now call `simulate` on the transaction before the final `signAndSend` call after all required signatures are gathered when using the XDR methods.
- a `restoreFootprint` method which accepts the `restorePreamble` returned when a simulation call fails due to some contract state that has expired. When invoking a contract function, one can now set `restore` to `true` in the `MethodOptions`. When enabled, a `restoreFootprint` transaction will be created and await signing when required.
- separate `sign` and `send` methods so that you can sign a transaction without sending it. You can continue to use `signAndSend` if you prefer.
- `toXDR` and `fromXDR` methods for serializing the transaction to and from XDR. These methods should be used in place of `AssembledTransaction.toJSON` and `AssembledTransaction.fromJSON`for multi-auth signing. The JSON methods are now deprecated. **Note:** you must now call `simulate` on the transaction before the final `signAndSend` call after all required signatures are gathered when using the XDR methods ([#977](https://github.com/stellar/js-stellar-sdk/pull/977)).
- a `restoreFootprint` method which accepts the `restorePreamble` returned when a simulation call fails due to some contract state that has expired. When invoking a contract function, one can now set `restore` to `true` in the `MethodOptions`. When enabled, a `restoreFootprint` transaction will be created and await signing when required ([#991](https://github.com/stellar/js-stellar-sdk/pull/991)).
- separate `sign` and `send` methods so that you can sign a transaction without sending it (`signAndSend` still works as before; [#922](https://github.com/stellar/js-stellar-sdk/pull/992)).
- `contract.Client` now has a `txFromXDR` method which should be used in place of `txFromJSON` for multi-auth signing ([#977](https://github.com/stellar/js-stellar-sdk/pull/977)).

### Deprecated
- In `contract.AssembledTransaction`, `toJSON` and `fromJSON` should be replaced with `toXDR` and
`fromXDR`. Similarly, in `contract.Client`, `txFromJSON` should be replaced with `txFromXDR`.
- In `contract.AssembledTransaction`, `toJSON` and `fromJSON` should be replaced with `toXDR` and `fromXDR`.
- In `contract.Client`, `txFromJSON` should be replaced with `txFromXDR`.

### Fixed
- Contract Client: if you edit an `AssembledTransaction` with `tx.raw = cloneFrom(tx.build)`, the `tx.simulationData` will now be updated correctly. `simulationData` is effectively a cache, and we now make sure we clear it when you re-simulate.
- If you edit an `AssembledTransaction` with `tx.raw = cloneFrom(tx.build)`, the `tx.simulationData` will now be updated correctly ([#985](https://github.com/stellar/js-stellar-sdk/pull/985)).


## [v12.0.1](https://github.com/stellar/js-stellar-sdk/compare/v11.3.0...v12.0.1)
Expand Down
28 changes: 14 additions & 14 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@stellar/stellar-sdk",
"version": "12.0.1",
"version": "12.1.0",
"description": "A library for working with the Stellar network, including communication with the Horizon and Soroban RPC servers.",
"keywords": [
"stellar"
Expand Down Expand Up @@ -93,11 +93,11 @@
]
},
"devDependencies": {
"@babel/cli": "^7.24.6",
"@babel/core": "^7.24.6",
"@babel/eslint-plugin": "^7.24.6",
"@babel/preset-env": "^7.24.6",
"@babel/preset-typescript": "^7.24.6",
"@babel/cli": "^7.24.7",
"@babel/core": "^7.24.7",
"@babel/eslint-plugin": "^7.24.7",
"@babel/preset-env": "^7.24.7",
"@babel/preset-typescript": "^7.24.7",
"@babel/register": "^7.24.6",
"@definitelytyped/dtslint": "^0.2.20",
"@istanbuljs/nyc-config-babel": "3.0.0",
Expand All @@ -106,13 +106,13 @@
"@types/detect-node": "^2.0.0",
"@types/eventsource": "^1.1.12",
"@types/json-schema": "^7.0.15",
"@types/lodash": "^4.17.4",
"@types/lodash": "^4.17.5",
"@types/mocha": "^10.0.2",
"@types/node": "^20.12.13",
"@types/node": "^20.14.2",
"@types/randombytes": "^2.0.1",
"@types/sinon": "^17.0.2",
"@types/urijs": "^1.19.20",
"@typescript-eslint/parser": "^7.7.1",
"@typescript-eslint/parser": "^7.13.0",
"axios-mock-adapter": "^1.22.0",
"babel-loader": "^9.1.3",
"babel-plugin-istanbul": "^6.1.1",
Expand All @@ -127,7 +127,7 @@
"eslint-config-airbnb-typescript": "^18.0.0",
"eslint-config-prettier": "^9.0.0",
"eslint-plugin-import": "^2.29.1",
"eslint-plugin-jsdoc": "^48.2.7",
"eslint-plugin-jsdoc": "^48.2.12",
"eslint-plugin-node": "^11.1.0",
"eslint-plugin-prefer-import": "^0.0.1",
"eslint-plugin-prettier": "^5.1.2",
Expand All @@ -144,25 +144,25 @@
"karma-mocha": "^2.0.0",
"karma-sinon-chai": "^2.0.2",
"karma-webpack": "^5.0.1",
"lint-staged": "^15.2.5",
"lint-staged": "^15.2.7",
"lodash": "^4.17.21",
"minami": "^1.1.1",
"mocha": "^10.3.0",
"node-polyfill-webpack-plugin": "^3.0.0",
"nyc": "^15.1.0",
"prettier": "^3.2.5",
"prettier": "^3.3.2",
"randombytes": "^2.1.0",
"sinon": "^17.0.1",
"sinon-chai": "^3.7.0",
"taffydb": "^2.7.3",
"terser-webpack-plugin": "^5.3.10",
"ts-node": "^10.9.2",
"typescript": "^5.4.3",
"webpack": "^5.91.0",
"webpack": "^5.92.0",
"webpack-cli": "^5.0.1"
},
"dependencies": {
"@stellar/stellar-base": "^12.0.0",
"@stellar/stellar-base": "^12.0.1",
"axios": "^1.7.2",
"bignumber.js": "^9.1.2",
"eventsource": "^2.0.2",
Expand Down
Loading
Loading