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

build(deps): bump error-stack from version 0.3.1 to 0.4.1 #4188

Merged
merged 24 commits into from
Apr 1, 2024

Conversation

SanchithHegde
Copy link
Member

Type of Change

  • Bugfix
  • New feature
  • Enhancement
  • Refactoring
  • Dependency updates
  • Documentation
  • CI/CD

Description

This PR updates the error-stack dependency from version 0.3.1 to 0.4.1. As part of this update, they've deprecated the IntoReport trait and its into_report() method, which is quite a big change, given the size of our codebase.

You can find the changelog here: https://github.com/hashintel/hash/blob/main/libs/error-stack/CHANGELOG.md

The PR can easily be reviewed one commit at a time. When doing so, please skip the second commit on this PR (title: "chore: replace error_stack::IntoReport with error_stack::ResultExt and remove into_report()"), since it was scripted, involving the following commands (gsed being the GNU sed tool on MacOS):

gsed \
  --in-place \
  --expression \
  '
  s/use error_stack::IntoReport;/use error_stack::ResultExt;/g
  s/use error_stack::{IntoReport, Report, ResultExt};/use error_stack::{Report, ResultExt};/g
  s/use error_stack::{IntoReport, ResultExt};/use error_stack::ResultExt;/g
  s/use error_stack::{ResultExt, IntoReport};/use error_stack::ResultExt;/g
  s/use error_stack::{report, FutureExt, IntoReport, ResultExt};/use error_stack::{report, FutureExt, ResultExt};/g
  s/use error_stack::{report, IntoReport, Report, ResultExt};/use error_stack::{report, Report, ResultExt};/g
  s/use error_stack::{report, IntoReport, ResultExt};/use error_stack::{report, ResultExt};/g
  s/use error_stack::{report, IntoReport};/use error_stack::{report, ResultExt};/g
  s/use error_stack::{self, IntoReport, ResultExt};/use error_stack::{self, ResultExt};/g
  s/.into_report()//g
  ' \
  **/*.rs

gsed --in-place --regexp-extended 's/^\s+$//g' crates/**/*.rs

cargo +nightly fmt

All other commits involved manual changes and need to be reviewed. I have also grouped changes based on teams which own the parts of code, for easier reviews.

Motivation and Context

Catching up with our dependencies.

How did you test it?

It should work as long as the code compiles (and CI checks pass). I've also done a round of sanity testing by successfully creating payments using Postman.

Checklist

  • I formatted the code cargo +nightly fmt --all
  • I addressed lints thrown by cargo clippy
  • I reviewed the submitted code
  • I added unit tests for my changes where possible
  • I added a CHANGELOG entry if applicable

@SanchithHegde SanchithHegde added A-dependencies Area: Dependencies S-waiting-on-review Status: This PR has been implemented and needs to be reviewed C-refactor Category: Refactor labels Mar 25, 2024
@SanchithHegde SanchithHegde added this to the March 2024 milestone Mar 25, 2024
@SanchithHegde SanchithHegde self-assigned this Mar 25, 2024
@SanchithHegde SanchithHegde requested review from a team as code owners March 25, 2024 19:31
@SanchithHegde SanchithHegde changed the title Dep error stack 0.4.1 build(deps): bump error-stack from version 0.3.1 to 0.4.1 Mar 25, 2024
@SanchithHegde SanchithHegde force-pushed the dep-error-stack-0.4.1 branch 2 times, most recently from 189599e to 47c7a22 Compare March 25, 2024 20:02
@SanchithHegde
Copy link
Member Author

Rebased on current main (7b337ac).

Copy link
Contributor

@kashif-m kashif-m left a comment

Choose a reason for hiding this comment

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

Approved this commit - 2455732

Copy link
Contributor

@ThisIsMani ThisIsMani left a comment

Choose a reason for hiding this comment

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

Dashboard specific changes looks fine.

@likhinbopanna likhinbopanna added this pull request to the merge queue Apr 1, 2024
Merged via the queue into main with commit ea730d4 Apr 1, 2024
10 of 12 checks passed
@likhinbopanna likhinbopanna deleted the dep-error-stack-0.4.1 branch April 1, 2024 07:16
@SanchithHegde SanchithHegde removed the S-waiting-on-review Status: This PR has been implemented and needs to be reviewed label Apr 1, 2024
pixincreate added a commit that referenced this pull request Apr 1, 2024
* 'main' of github.com:juspay/hyperswitch:
  refactor(core): removed the processing status for payment_method_status (#4213)
  docs(README): remove link to outdated early access form
  build(deps): bump `error-stack` from version `0.3.1` to `0.4.1` (#4188)
  chore(version): 2024.04.01.0
  feat(mandates): allow off-session payments using `payment_method_id` (#4132)
  ci(CI-pr): determine modified crates more deterministically (#4233)
  chore(config): add billwerk base URL in deployment configs (#4243)
  feat(payment_method): API to list countries and currencies supported by a country and payment method type (#4126)
  chore(version): 2024.03.28.0
  refactor(config): allow wildcard origin for development and Docker Compose setups (#4231)
  fix(core): Amount capturable remain same for `processing` status in capture (#4229)
  fix(euclid_wasm): checkout wasm metadata issue (#4198)
  fix(trustpay): [Trustpay] Add error code mapping '800.100.100'  (#4224)
  feat(connector): [billwerk] add connector template code (#4123)
  fix(connectors): fix wallet token deserialization error  (#4133)
  fix(log): adding span metadata to `tokio` spawned futures (#4118)
  chore(version): 2024.03.27.0
  fix(connector): [CRYPTOPAY] Skip metadata serialization if none (#4205)
  fix(connector): [Trustpay] fix deserialization error for incoming webhook response for trustpay and add error code mapping '800.100.203' (#4199)
  fix(core): make eci in AuthenticationData optional (#4187)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-dependencies Area: Dependencies C-refactor Category: Refactor
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet