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(astro): ignore query params when matching .astro extension #11240

Merged
merged 3 commits into from
Jun 12, 2024
Merged

Conversation

ascorbic
Copy link
Contributor

@ascorbic ascorbic commented Jun 12, 2024

Changes

Checks the filename for the .astro, rather than the full ID. Fixes #11230, where a query that ended in the string .astro would incorrectly match.

Testing

I wasn't able to find a place where there were tests of this part of the code. If anyone has suggestions for a good place to test it then that would be welcome.

Docs

Nothing changed

Copy link

changeset-bot bot commented Jun 12, 2024

🦋 Changeset detected

Latest commit: 0945f44

The changes in this PR will be included in the next version bump.

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@github-actions github-actions bot added the pkg: astro Related to the core `astro` package (scope) label Jun 12, 2024
@ascorbic ascorbic changed the title fix: ignore query params when matching .astro extension fix(astro): ignore query params when matching .astro extension Jun 12, 2024
@ematipico
Copy link
Member

I wasn't able to find a place where there were tests of this part of the code. If anyone has suggestions for a good place to test it then that would be welcome.

Can't you create a new fixture by replicating the reproduction provided in the original issue?

@ascorbic
Copy link
Contributor Author

ascorbic commented Jun 12, 2024

@ematipico good suggestion. Done

Copy link
Member

@ematipico ematipico left a comment

Choose a reason for hiding this comment

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

Awesome!

@ascorbic ascorbic merged commit 2851b0a into main Jun 12, 2024
14 checks passed
@ascorbic ascorbic deleted the plt-2188 branch June 12, 2024 11:44
@astrobot-houston astrobot-houston mentioned this pull request Jun 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
pkg: astro Related to the core `astro` package (scope)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Virtual module ids with query parameters that end in .astro throw errors
2 participants