Skip to content

Conversation

@ematipico
Copy link
Member

@ematipico ematipico commented Oct 28, 2025

Changes

This PR refactors how we load the driver for Astro sessions. It uses the same loading mechanism that use we for middleware, actions and renderers.

  • we have a virtual module that returns the driver
  • the driver is saved in the pipeline
  • the render context creates AstroSession by using the driver passed by the pipeline
  • to the manifest we assign a function that returns the driver
  • updated the plugin-manifest to return the manifest with the new sessionDriver property

The refactor was done using Claude AI

Testing

Added a new page to the test fixture. Unfortunately it doesn't work with my current cloudflare account, and I don't know why, however it's an error regarding the binding session.

Tested that session.test.js passes.

Docs

@changeset-bot
Copy link

changeset-bot bot commented Oct 28, 2025

⚠️ No Changeset found

Latest commit: 5640fd6

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

Click here to learn what changesets are, and how to add one.

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

@github-actions github-actions bot added pkg: integration Related to any renderer integration (scope) pkg: astro Related to the core `astro` package (scope) docs pr labels Oct 28, 2025
@ematipico ematipico merged commit 714f755 into feat/environment-api Oct 29, 2025
6 of 18 checks passed
@ematipico ematipico deleted the env-api/sessions branch October 29, 2025 09:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

docs pr pkg: astro Related to the core `astro` package (scope) pkg: integration Related to any renderer integration (scope)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants