Skip to content

Build Scan URL parsing is more resilient #398

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

Merged
merged 2 commits into from
Apr 12, 2023

Conversation

erichaagdev
Copy link
Member

This PR makes the Build Scan URL parsing logic much more resilient.

Previously, given a Build Scan URL with additional path parts after the ID, then parsing would fail. For example:

./04-validate-remote-build-caching-ci-ci.sh \
  -1 https://e.grdev.net/s/meiwdomvrhneo/timeline \
  -2 https://e.grdev.net/s/7fmkhoppnrpre/projects#:admin-database

This would result in:

image

image

Now, the same command results in a successful experiment and investigation quick links:

image

image

@erichaagdev erichaagdev self-assigned this Apr 12, 2023
@erichaagdev erichaagdev changed the title Make Build Scan URL parsing more resilient Build Scan URL parsing is more resilient Apr 12, 2023
Copy link
Member

@etiennestuder etiennestuder left a comment

Choose a reason for hiding this comment

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

Nice. LGTM.

@erichaagdev erichaagdev merged commit 2f68f96 into main Apr 12, 2023
@erichaagdev erichaagdev deleted the erichaagdev/flexible-build-scan-url-parsing branch April 12, 2023 17:03
import static org.junit.jupiter.api.Assertions.assertEquals;
import static org.junit.jupiter.api.Assertions.assertThrows;

class NumberedBuildScanTests {
Copy link
Member

Choose a reason for hiding this comment

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

🥇 I love that you added tests for this!

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.

3 participants