Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Since the commit hash was a parameter that could be or not be sent in order to get the endpoint data, it was turned into an optional query parameter instead of being a separate endpoint.
In the frontend, the routes for
/checkout/$treeName/$branch/$hash
and/c/$treeName/$branch/$hash
still exists in order to keep backwards compatibility. IF someone tries to access the url for a tree such assoc arm/fixes
, they can avoid parameter conflict by encoding the/
, for examplehttp://localhost:5173/checkout/soc/arm%2Ffixes/0c952efa0d7cf5258879406077df33d23cb06d5e
.In the backend, the branch was altered to a
path
type, and the parameters are now returned by the endpoint if it doesn't encounter a tree in order to be clearer on how the variables were parsed.Changes
How to test
Access the /tree/tree_name/branch endpoint with different arguments for commit_hash. Also check the frontend routes for
/tree/$treeName/$branch
,/checkout/$treeName/$branch
,/checkout/$treeName/$branch/$hash
,/c/treeName/$branch
, and/c/$treeName/$branch/$hash
Closes #1476