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

fix: go 1.22 test breakage #3459

Merged
merged 1 commit into from
Feb 6, 2025
Merged

fix: go 1.22 test breakage #3459

merged 1 commit into from
Feb 6, 2025

Conversation

amanv8060
Copy link
Contributor

Use correct url escaping to fix the errors caused by mux changes.

Fixes: #3409

Verified

This commit was signed with the committer’s verified signature.
Letiste Léo Salé
@amanv8060
Copy link
Contributor Author

@gmlewis could you please approve actions test to see if all works correctly?

Copy link

codecov bot commented Feb 5, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 91.03%. Comparing base (d392e2c) to head (927eeeb).
Report is 6 commits behind head on master.

Additional details and impacted files
@@           Coverage Diff           @@
##           master    #3459   +/-   ##
=======================================
  Coverage   91.03%   91.03%           
=======================================
  Files         179      179           
  Lines       15535    15535           
=======================================
  Hits        14142    14142           
  Misses       1221     1221           
  Partials      172      172           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@gmlewis
Copy link
Collaborator

gmlewis commented Feb 5, 2025

@gmlewis could you please approve actions test to see if all works correctly?

Yes, however we don't want to remove problematic (but valid) branch names from the unit tests (as you have done in this PR)...
Instead, we want to fix the testing mux harness to properly handle all the problematic branch names.
Does that make sense?

@gmlewis gmlewis added the DO NOT MERGE Do not merge this PR. label Feb 5, 2025
@amanv8060
Copy link
Contributor Author

Yes, however we don't want to remove problematic (but valid) branch names from the unit tests (as you have done in this PR)... Instead, we want to fix the testing mux harness to properly handle all the problematic branch names. Does that make sense?

I am not sure if I get what you're saying, I haven't really removed any branch names, instead in the mux urls(the one's to be called) by api, I have just Path escaped them, github also does this, for eg,

This would go like this:

https://github.com/flutter/engine/compare/commit-list?range=main...shorebirdtech%3Aengine%3Ashorebird%2Fdev

Also see, tests in net/http.

IMO, one thing that could be done better here is,to create a util function of sort that would take the branch name and path escape them before adding it to mux route.

@gmlewis gmlewis added NeedsReview PR is awaiting a review before merging. and removed DO NOT MERGE Do not merge this PR. labels Feb 5, 2025
@gmlewis
Copy link
Collaborator

gmlewis commented Feb 5, 2025

I am not sure if I get what you're saying, I haven't really removed any branch names, instead in the mux urls(the one's to be called) by api, I have just Path escaped them

Ah! I see now what you are saying, @amanv8060. I apologize for the confusion I caused.

Yes, a utility function would help tremendously, I would think, and make it clearer what is happening.

Would you mind doing that as part of this PR?

@amanv8060
Copy link
Contributor Author

I would prefer to do that in seperate pr so that review becomes easier.

Copy link
Collaborator

@gmlewis gmlewis left a comment

Choose a reason for hiding this comment

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

Thank you, @amanv8060 !
LGTM.

Awaiting second LGTM+Approval from any other contributor to this repo before merging.

@stevehipwell - might you have time for a code review? Thanks!

Copy link
Contributor

@stevehipwell stevehipwell left a comment

Choose a reason for hiding this comment

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

LGTM

@gmlewis
Copy link
Collaborator

gmlewis commented Feb 6, 2025

Thank you, @stevehipwell and @alexandear !
Merging.

@gmlewis gmlewis removed the NeedsReview PR is awaiting a review before merging. label Feb 6, 2025
@gmlewis gmlewis merged commit 0ccbfaf into google:master Feb 6, 2025
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Update unit tests so that GODEBUG=httpmuxgo121=1 is not required
4 participants