-
-
Notifications
You must be signed in to change notification settings - Fork 98
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
Component queries broken on server-side on Svelte 3.56.0 #989
Comments
Hm... I was able to get the component query e2e test to work by replacing the For context, here is the fully transformed version of the component. Maybe you can see why making <script lang="ts">
import { ComponentQueryTestStore } from "$houdini/plugins/houdini-svelte/stores/ComponentQueryTest";
import { isBrowser } from "$houdini/plugins/houdini-svelte/runtime/adapter";
import { RequestContext } from "$houdini/plugins/houdini-svelte/runtime/session";
import { getCurrentConfig } from "$houdini/runtime/lib/config";
import { marshalInputs } from "$houdini/runtime/lib/scalars";
import { graphql } from "$houdini";
const _houdini_ComponentQueryTest = new ComponentQueryTestStore();
export function _ComponentQueryTestVariables(
{
props
}: {
props: {
id?: string;
};
}
) {
return {
id: props.id || "3"
};
}
export let id = "";
const result = _houdini_ComponentQueryTest;
$: isBrowser && _houdini_ComponentQueryTest.fetch({
variables: marshalInputs({
config: getCurrentConfig(),
artifact: _houdini_ComponentQueryTest.artifact,
input: _ComponentQueryTestVariables.call(new RequestContext(), {
props: {
id: id
}
})
})
});
</script>
{$result.data?.user.name} |
Okay, so after clicking around a bit, I suspect this issue was caused by a bug introduced in sveltejs/svelte#7942. The tanstack svelte bindings also have a very similar problem (which is what makes me think this is a svelte issue, not a problem in Houdini). It looks like the PR is being reverted in sveltejs/svelte#8382 so hopefully this issue goes away when that is merged/released. |
Just confirmed this is now fixed in |
Describe the bug
After upgrading to Svelte v3.56.0, component queries give an error when getting loaded on server-side
Checked on e2e sveltekit project in the repo
brach: main @ commit d00c17b (houdini version
1.1.0
)Severity
blocking an upgrade
Steps to Reproduce the Bug
3.56.0
pnpm install && pnpm dev
Plugin_query_component
link, see everything work nicely (page is loaded on client-side)/plugin/query/component
route (page is loaded on server-side)Reproduction
No response
The text was updated successfully, but these errors were encountered: