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

[REFACTOR]: [Worldline] Remove Default Case Handling #2289

Closed
2 tasks done
Sakilmostak opened this issue Sep 22, 2023 · 20 comments · Fixed by #2674
Closed
2 tasks done

[REFACTOR]: [Worldline] Remove Default Case Handling #2289

Sakilmostak opened this issue Sep 22, 2023 · 20 comments · Fixed by #2674
Assignees
Labels
A-connector-integration Area: Connector integration C-feature Category: Feature request or enhancement good first issue Good for newcomers hacktoberfest Issues that are up for grabs for Hacktoberfest participants

Comments

@Sakilmostak
Copy link
Contributor

📝 Feature Description

  • We utilize match statements to make pivotal decisions, such as generating requests based on the payment method type and managing responses received from the connector.
  • These conditions generally go hand in hand with enum variants.
  • Default case is used because a match statement needs to be exhaustive i.e. every variant needs to be covered.
  • So, if all the explicit cases are handled then default is used to handle the rest.
  • Each connector have these match statements but many of them don’t provide reference to each variant in their default case, rather a _ is put to handle all the other cases.
  • This approach carries a risk because developers may inadvertently overlook the need for explicit handling of the new cases.

🔨 Possible Implementation

🔖 Note: All the changes needed should be contained within hyperswitch/crates/router/src/connector/

📦 Have you spent some time checking if this feature request has been raised before?

  • I checked and didn't find a similar issue

📦 Have you read the Contributing Guidelines?

✨ Are you willing to submit a PR?

@Sakilmostak Sakilmostak added A-connector-integration Area: Connector integration C-feature Category: Feature request or enhancement S-awaiting-triage Status: New issues that have not been assessed yet hacktoberfest Issues that are up for grabs for Hacktoberfest participants labels Sep 22, 2023
@VedantKhairnar VedantKhairnar added the good first issue Good for newcomers label Sep 28, 2023
@nik132-eng
Copy link

can you assign me this issue?

@AkshayaFoiger AkshayaFoiger removed the S-awaiting-triage Status: New issues that have not been assessed yet label Sep 30, 2023
@AkshayaFoiger
Copy link
Contributor

Hey @nik132-eng , sure! I've assigned this to you.

In case you have any queries, you can ask them on this issue thread, or on our discord server, or on slack whichever you are comfortable with

@VedantKhairnar
Copy link
Contributor

Hey @nik132-eng ,
Let us know if you face any issues. Happy to help! : )

@VedantKhairnar
Copy link
Contributor

Hey @nik132-eng ,
Just checking in - are you working on it or shall we consider reassigning it to someone else?

@swangi-kumari
Copy link
Contributor

Hello @nik132-eng , we didn't hear back from you, so we are unassigning you from this issue. If you are interested, we will assign you with other issues, if the current one is taken.

@swangi-kumari swangi-kumari added the S-awaiting-triage Status: New issues that have not been assessed yet label Oct 17, 2023
@Hangsaai
Copy link
Contributor

Hey @swangi-kumari can you assign this to me I am willing to submit PR

@swangi-kumari swangi-kumari removed the S-awaiting-triage Status: New issues that have not been assessed yet label Oct 17, 2023
@swangi-kumari
Copy link
Contributor

Hey @Hangsaai , sure! I've assigned this to you.

In case you have any queries, you can ask them on this issue thread, or on our discord server, or on slack whichever you are comfortable with.

@Hangsaai
Copy link
Contributor

Thank you @swangi-kumari for assigning me this issue. I have started working on this.

@Hangsaai
Copy link
Contributor

I am not able to push the code shows that I am not a collaborator @swangi-kumari

@Hangsaai
Copy link
Contributor

image

@swangi-kumari
Copy link
Contributor

Hey @Hangsaai ,
Disable browser extensions and try, or you can also try it with a different browser without any extensions installed.

@Hangsaai
Copy link
Contributor

Yep I have already tried using Brave aswell but same problem occuring
image

@SanchithHegde
Copy link
Member

@Hangsaai Which repository are you trying to open a pull request from? Please ensure that you have write access to the repository you're opening the PR from.

@Hangsaai
Copy link
Contributor

I am directly pushing to a branch in hyperswitch itself and then creating a PR to main @SanchithHegde

@SanchithHegde
Copy link
Member

@Hangsaai Could you please share the link to the repository/branch you're pushing to?

@Hangsaai
Copy link
Contributor

@SanchithHegde
Copy link
Member

@Hangsaai Ideally you shouldn't have had access to push a branch to our repository. Could you push the branch to your fork instead and open a PR from there?

@Hangsaai
Copy link
Contributor

Yep I just figured it out I guess it's a vulnerability of github shouldn't have happened

@Hangsaai
Copy link
Contributor

Hey @SanchithHegde @swangi-kumari , can you guys assign this issue to me.

@swangi-kumari swangi-kumari linked a pull request Oct 25, 2023 that will close this issue
15 tasks
@swangi-kumari
Copy link
Contributor

Completed in 2674

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-connector-integration Area: Connector integration C-feature Category: Feature request or enhancement good first issue Good for newcomers hacktoberfest Issues that are up for grabs for Hacktoberfest participants
Projects
None yet
Development

Successfully merging a pull request may close this issue.

7 participants