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

[pull] master from allbridge-io:master #22

Open
wants to merge 22 commits into
base: master
Choose a base branch
from

Conversation

pull[bot]
Copy link

@pull pull bot commented Oct 1, 2024

See Commits and Changes for more details.


Created by pull[bot]

Can you help keep this open source service alive? 💖 Please sponsor : )

AntonKozAllB and others added 22 commits July 22, 2024 12:28
with feat(swap/pool): return swap/pool tokens set;
with dependencies updates;
# [3.18.0-beta.1](v3.17.0...v3.18.0-beta.1) (2024-08-08)

### Bug Fixes

* **ENVIRONMENT:** remove ENVIRONMENT ([8d7e927](8d7e927))
* **Error:** add ConfigError: Requires SRB_NODE_URL and STLR_NODE_URL both ([bdbbaf8](bdbbaf8))
* **Error:** return errorCode in sdkError case ([3595b2b](3595b2b))
* **NETWORKS:** remove NETWORKS ([66b7dc8](66b7dc8))

### Features

* add optional token type ([af0ee28](af0ee28))
* **README:** add `Host on Heroku` ([274d3ac](274d3ac))
* **README:** update ([0ee3013](0ee3013))
* sdk release 3.18.0.beta3 ([76739eb](76739eb))

Docker image: https://hub.docker.com/r/allbridge/io.allbridge.rest-api:3.18.0-beta.1
# [3.18.0](v3.17.0...v3.18.0) (2024-10-01)

### Bug Fixes

* **ENVIRONMENT:** remove ENVIRONMENT ([8d7e927](8d7e927))
* **Error:** add ConfigError: Requires SRB_NODE_URL and STLR_NODE_URL both ([bdbbaf8](bdbbaf8))
* **Error:** return errorCode in sdkError case ([3595b2b](3595b2b))
* **NETWORKS:** remove NETWORKS ([66b7dc8](66b7dc8))

### Features

* add optional token type ([af0ee28](af0ee28))
* **README:** add `Host on Heroku` ([274d3ac](274d3ac))
* **README:** update ([0ee3013](0ee3013))
* sdk release 3.18.0 ([2a8fe86](2a8fe86))
* sdk release 3.18.0.beta3 ([76739eb](76739eb))
* sdk release 3.18.0.beta6 ([1ac9832](1ac9832))

Docker image: https://hub.docker.com/r/allbridge/io.allbridge.rest-api:3.18.0
Copy link

changeset-bot bot commented Oct 1, 2024

⚠️ No Changeset found

Latest commit: 5363b39

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

Copy link

sourcery-ai bot commented Oct 1, 2024

Reviewer's Guide by Sourcery

This pull request implements several improvements and updates to the Allbridge Core REST API and related examples. The changes include code refactoring, dependency updates, error handling enhancements, and the addition of new features. Key modifications include removing environment-specific configurations, updating the SDK to version 3.18.0, improving error handling, and adding support for optional token types.

No sequence diagrams generated as the changes look simple and do not need a visual representation.

File-Level Changes

Change Details Files
Removed environment-specific configurations and simplified setup
  • Removed ENVIRONMENT and NETWORKS environment variables
  • Simplified SDK initialization by removing environment-specific logic
  • Updated getRPCUrls method to dynamically load RPC URLs for all chain symbols
  • Added check to ensure both SRB_NODE_URL and STLR_NODE_URL are present
rest-api/src/service/config.service.ts
rest-api/src/service/sdk.service.ts
README.md
Updated SDK to version 3.18.0 and added support for optional token types
  • Updated SDK initialization to use mainnet configuration
  • Added optional 'type' parameter to getTokens and chainDetailsMap methods
  • Updated REST API endpoints to support the new 'type' parameter
rest-api/src/service/sdk.service.ts
rest-api/src/controller/rest.controller.ts
Improved error handling and added new error types
  • Added ConfigError for configuration-related errors
  • Implemented httpException function to handle SDK-specific errors
  • Updated error handling in REST API endpoints to use the new httpException function
rest-api/src/error/errors.ts
rest-api/src/controller/rest.controller.ts
Refactored and improved code quality across the project
  • Updated code formatting and style using Prettier
  • Removed unused imports and variables
  • Improved type safety and added type annotations
  • Updated examples to use more consistent coding style
examples/src/usage/bridge/srb/srb-send-full-example.ts
examples/src/usage/bridge/evm/evm-build-approve-and-send-tx-gas-fee-with-stables.ts
examples/src/usage/bridge/solana/sol-build-send-tx.ts
examples/src/usage/bridge/evm/evm-build-approve-and-send-tx.ts
examples/src/usage/bridge/evm/evm-build-swap-tx.ts
examples/src/usage/bridge/evm/evm-send-full-example.ts
examples/src/usage/bridge/evm/evm-check-allowance.ts
Updated README with new deployment instructions and API documentation
  • Added instructions for hosting on Heroku
  • Updated environment variable requirements
  • Improved API documentation with more detailed endpoint descriptions
README.md
Added new utility functions for amount calculations
  • Implemented convertIntAmountToFloat function
  • Added toPowBase10 function for decimal calculations
rest-api/src/utils/calculation.ts

Tips and commands

Interacting with Sourcery

  • Trigger a new review: Comment @sourcery-ai review on the pull request.
  • Continue discussions: Reply directly to Sourcery's review comments.
  • Generate a GitHub issue from a review comment: Ask Sourcery to create an
    issue from a review comment by replying to it.

Customizing Your Experience

Access your dashboard to:

  • Enable or disable review features such as the Sourcery-generated pull request
    summary, the reviewer's guide, and others.
  • Change the review language.
  • Add, remove or edit custom review instructions.
  • Adjust other review settings.

Getting Help

Copy link

@sourcery-ai sourcery-ai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We have skipped reviewing this pull request. It seems to have been created by a bot (hey, pull[bot]!). We assume it knows what it's doing!

@pull pull bot added ⤵️ pull merge-conflict Resolve conflicts manually labels Oct 1, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
⤵️ pull merge-conflict Resolve conflicts manually
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants