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

Qwik City on Fastly #711

Open
kalebpace opened this issue Dec 17, 2023 · 2 comments
Open

Qwik City on Fastly #711

kalebpace opened this issue Dec 17, 2023 · 2 comments

Comments

@kalebpace
Copy link

Summary

Hello 👋

I've been working on an adapter for the Qwik City meta-framework so it can be run on Compute@Edge. I wanted to open this issue to ask a few questions and socialize this work a bit in case this is helpful to anyone else.

I've run into a few missing APIs in the js-compute runtime when implementing the adapter in Qwik City's e2e integration project:

  • AbortSignal API
  • formData/blob on Request objects
  • Intl API - Causes wizer error
Wizer Error

Exception while evaluating JS: (new ReferenceError("Intl is not defined", "<stdin>", 20115))
  @<stdin>:20115:12
  @<stdin>:25647:3

Error: the `wizer.initialize` function trapped

Caused by:
    0: error while executing at wasm backtrace:
           0: 0x7ec9a5 - <unknown>!<wasm function 21789>
           1: 0x7ec6b7 - <unknown>!<wasm function 21765>
           2: 0x7edbd2 - <unknown>!<wasm function 21836>
           3: 0xfd6f - <unknown>!<wasm function 223>
           4: 0x1043c - <unknown>!<wasm function 226>
           5: 0x108b3 - <unknown>!<wasm function 229>
    1: Exited with i32 exit status 1
Error: Failed to compile JavaScript to Wasm:  Wizer initialization failure
 ELIFECYCLE  Command failed with exit code 1.

Questions

I am mainly curious about:

  1. Whether these APIs are planned for the runtime
  2. How a project like https://github.com/fastly/next-compute-js might suggest solving for their unavailability

Thanks very much in advance for your time and attention to this!

@kalebpace kalebpace changed the title Qwik/Qwik City on Fastly Qwik City on Fastly Dec 17, 2023
@JakeChampion
Copy link
Contributor

Hi @kalebpace,

Whether these APIs are planned for the runtime

Yes, we would like to implement these APIs

How a project like fastly/next-compute-js might suggest solving for their unavailability

I'm not sure on that one, I don't work on the next-compute-js project, if you open an issue on that project then hopefully the team their will be able to answer 🤞

@kalebpace
Copy link
Author

Hey @JakeChampion, thanks for looking at this.

Yes, we would like to implement these APIs

Since there is interest here, is there a recommendation on how best to contribute/start work on these changes?

For example, the missing Intl API seems to be a flag in the spidermonkey runtime.

Would it be as simple as opening a PR with a successful build of it enabled or are there larger implications to making a change like this?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants