Skip to content

Conversation

@florian-lefebvre
Copy link
Member

Changes

  • Fixes the serizalization of astro:config/server URLS, which were emitted as strings instead of URLs

Testing

Updated

Docs

Changeset

@florian-lefebvre florian-lefebvre self-assigned this Sep 30, 2025
@changeset-bot
Copy link

changeset-bot bot commented Sep 30, 2025

🦋 Changeset detected

Latest commit: 7ea3d82

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 Sep 30, 2025
@codspeed-hq
Copy link

codspeed-hq bot commented Sep 30, 2025

CodSpeed Performance Report

Merging #14460 will not alter performance

Comparing fix/config-server-url-serialization (7ea3d82) with main (667bd64)

Summary

✅ 6 untouched

<p id="out-dir">{outDir}</p>
<p id="src-dir">{srcDir}</p>
<p id="root">{root}</p>
<p id="root-type">{typeof root}</p>
Copy link
Contributor

Choose a reason for hiding this comment

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

How about testing instanceof URL?

Copy link
Member Author

Choose a reason for hiding this comment

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

Yeah I don't know why I didn't do that, updated!

Comment on lines 111 to 113
if (Array.isArray(value)) {
return JSON.stringify(value);
}
Copy link
Contributor

Choose a reason for hiding this comment

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

Are arrays always of scalars?

Copy link
Member Author

Choose a reason for hiding this comment

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

Updated to handle this case

Copy link
Member

@delucis delucis left a comment

Choose a reason for hiding this comment

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

LGTM! Is there any risk this is now a breaking change for anyone using this as a string? Or do we think the types should be the source of truth?

@florian-lefebvre
Copy link
Member Author

Yeah I thought about this and I think the types should be the source of truth here

@florian-lefebvre florian-lefebvre merged commit 008dc75 into main Oct 1, 2025
21 of 22 checks passed
@florian-lefebvre florian-lefebvre deleted the fix/config-server-url-serialization branch October 1, 2025 08:59
@astrobot-houston astrobot-houston mentioned this pull request Oct 1, 2025
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.

4 participants