HoudiniGraphql / houdini

The disappearing GraphQL framework
http://www.houdinigraphql.com
MIT License
913 stars 98 forks source link

Fix watchFiles error with vite 5.3 #1312

Closed SeppahBaws closed 4 months ago

SeppahBaws commented 4 months ago

Fixes #1306

Since the addWatchFile is context-aware, it ended up being invalid by the time the houdini plugins came around to use the function. This PR is a quick fix to ensure that people can keep using Houdini with the latest version of Vite. We'll need to properly rewrite the Vite plugin at one point so that this.addWatchFile is only called from within the houdini vite plugin itself.

For more context, take a look at the referenced issue, or this thread in Discord

To help everyone out, please make sure your PR does the following:

changeset-bot[bot] commented 4 months ago

🦋 Changeset detected

Latest commit: 8978afd64ee9011f7108775aa669408236b966fc

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

This PR includes changesets to release 8 packages | Name | Type | | ----------------------------------- | ----- | | houdini | Patch | | houdini-adapter-auto | Patch | | houdini-adapter-cloudflare | Patch | | houdini-adapter-node | Patch | | houdini-react | Patch | | houdini-svelte | Patch | | houdini-plugin-svelte-global-stores | Patch | | create-houdini | Patch |

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

netlify[bot] commented 4 months ago

Deploy Preview for houdinigraphql canceled.

Name Link
Latest commit 8978afd64ee9011f7108775aa669408236b966fc
Latest deploy log https://app.netlify.com/sites/houdinigraphql/deploys/668404752359ff0008f7252a
netlify[bot] commented 4 months ago

Deploy Preview for houdini-docs-next canceled.

Name Link
Latest commit 8978afd64ee9011f7108775aa669408236b966fc
Latest deploy log https://app.netlify.com/sites/houdini-docs-next/deploys/66840475d960ed0008effea5
macmillen commented 4 months ago

Awesome, thanks for fixing it! When will it be released?

SeppahBaws commented 4 months ago

Hopefully by the end of this week, I'm just bumping some versions in the repository, and I want it to be part to the next version as well.

SeppahBaws commented 4 months ago

@macmillen and others: I just published the fix, it's up on v1.2.48

I wasn't able to bump the dependencies yet, as I'm getting some very strange errors when building. But the package is forwards compatible so everything should just work.

macmillen commented 4 months ago

Thank you! :rocket: