stackblitz / tutorialkit

TutorialKit by StackBlitz - Create interactive tutorials powered by the WebContainer API
https://tutorialkit.dev
MIT License
232 stars 22 forks source link

ERROR_INVALID_PROTOCOL on IOS #258

Open noam-honig opened 3 weeks ago

noam-honig commented 3 weeks ago

Describe the bug

I'm testing my tutorial on IOS and I get an error saying:

npm ERR! code ERR_INVALID_PROTOCOL
npm ERR! Protocol "https:" not supported. Expected "http:"

When I tested it with the default demo - I did not get this error, but I have no Idea where to start looking for the cause of this problem.

Any change you can give me a pointer?

Link to a StackBlitz project which shows the error

No response

Steps to reproduce

On an IPhone -

  1. go to learn.remult.dev
  2. Toggle to Editor at the bottom
  3. Click on Run this tutorial Wait a long while, and you'll get this error

Expected behavior

I expect it to work as it does on your tutorial :)

Screenshots

image

Platform

Additional context

No response

Nemikolh commented 3 weeks ago

Hey @noam-honig! Thanks for the report!

Do you think you could create a project on https://stackblitz.com that has the same error on iOS? Both TutorialKit and StackBlitz use the same version of npm and WebContainer, so it should be possible to reproduce it there.

If not, then that's also an interesting data point! :eyes:

noam-honig commented 3 weeks ago

Hi @Nemikolh, I created a stackblitz project (by clicking open in stackblitz on my machine and sharing that)

https://stackblitz.com/edit/xccutk

This link completes the npm install, but then crashes the browser tab

Could the error rise from a missing header on learn.remult.dev other than the ones that are specified in the configuration page?

Nemikolh commented 3 weeks ago

Thanks for the link! I can reproduce locally :pray:

I don't think this could be caused by a missing header. Safari support for WebContainer is still in beta though and from a quick look it seems that no requests to get a package metadata or content is even sent. So probably something get stuck there.

Another bug for us to debug! :smile: