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]: [Cybersource] Remove Default Case Handling #2268

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

[REFACTOR]: [Cybersource] Remove Default Case Handling #2268

Sakilmostak opened this issue Sep 22, 2023 · 15 comments · Fixed by #2705
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
@KGoutham7214
Copy link

i want to work on this can you please describe more about the issue and assign it to me

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

Hey @KGoutham7214, 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 @KGoutham7214 ,
Let us know if you face any issues. Happy to help! : )

@swangi-kumari
Copy link
Contributor

Hey @KGoutham7214 . Are you still working on this issue?
Let us know if you face any issues. Happy to help! : )

@HeetVekariya
Copy link
Contributor

HeetVekariya commented Oct 17, 2023

  • I have worked on two issues, similar like this.
  • I have already find the cases that should be added against the default case.

image

  • @KGoutham7214, if you are still working on this issue, then you can take the hint from the screenshort.
  • If he doesn't continue to work on this issue, so @swangi-kumari can you please assign me this issue.

@KGoutham7214
Copy link

hey @HeetVekariya let's connect and work on this together

@HeetVekariya
Copy link
Contributor

HeetVekariya commented Oct 17, 2023

  • @KGoutham7214 we can connect on discord, i have already joined the hyperswitch discord server.
  • ping me in the dev-help-oss-contrib channel with @HeetVekariya

@deepanshu-iiitu
Copy link
Contributor

Hey @KGoutham7214
Just checking in - are you working on it? Do you need help from our side?

@KGoutham7214
Copy link

No I'm not able to do it

@deepanshu-iiitu deepanshu-iiitu added the S-awaiting-triage Status: New issues that have not been assessed yet label Oct 26, 2023
@TejasMate
Copy link
Contributor

@deepanshu-iiitu
Could you please assign this issue to me?

@deepanshu-iiitu
Copy link
Contributor

Hey @TejasMate , 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

@deepanshu-iiitu deepanshu-iiitu removed the S-awaiting-triage Status: New issues that have not been assessed yet label Oct 26, 2023
@Rutam21
Copy link
Contributor

Rutam21 commented Oct 29, 2023

Hello Team, I am clear about the changes and would like to work on this. Thanks.

cc: @VedantKhairnar

@deepanshu-iiitu
Copy link
Contributor

Hey @TejasMate
Just checking in - are you working on it? Do you need help from our side?

@TejasMate
Copy link
Contributor

@deepanshu-iiitu i submitted PR #2705 for this issue

@VedantKhairnar
Copy link
Contributor

VedantKhairnar commented Oct 30, 2023

@deepanshu-iiitu Will you pls check #2705 and get it merged.
@Rutam21 As Tejas is already working on it, we will give him preference. If it happens that the things aren't resolved till the end moment of hacktoberfest then we will assign it to you and will merge yours, before the end of hacktoberfest.
Thanks for understanding.
@TejasMate Thanks for your contribution.

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
9 participants