ProtoSchool / protoschool.github.io

The code that runs the ProtoSchool website. Visit https://proto.school for interactive tutorials on decentralized web protocols. Explore IPFS and Filecoin through code challenges, code-free lessons, and local events.
https://proto.school
Other
165 stars 67 forks source link

Address blockers to enabling DNSlink and allowing discovery via IPFS Companion #548

Open terichadbourne opened 4 years ago

terichadbourne commented 4 years ago

We're about to switch ProtoSchool hosting to Fleek without DNSlink enabled so that IPFS Companion doesn't discover that ProtoSchool is available on IPFS. The reasoning for this is that we have a number of unsolved issues to address before an IPFS-hosted version of the site will function properly. This issue will serve as a place to document those issues and discuss solutions before enabling DNSlink.

I'll let @zebateira add more context and then it would be great to meet with @lidel & @hugomrdias for more context to ensure we approach these challenges in the most effective manner.

zebateira commented 4 years ago

Note about relative paths deployment (ipfs gateway): since fleek has deployment setup to subdomains, this will not be an issue.

lidel commented 4 years ago

Quick brain dump before today's meeting:

Regarding "new localStorage" and losing progress history:

terichadbourne commented 4 years ago

Is there a way to have Cypress simulate the experience of having IPFS Companion installed and toggling it on and off? Wondering how we’ll build tests for when DNSlink is enabled but only a subset of users are accessing the site that way.

zebateira commented 4 years ago

Is there a way to have Cypress simulate the experience of having IPFS Companion installed and toggling it on and off? Wondering how we’ll build tests for when DNSlink is enabled but only a subset of users are accessing the site that way.

Apparently yes: https://www.npmjs.com/package/cypress-browser-extension-plugin But I think we will need to have a workaround to load the extension because this package loads the extension from the file system (maybe we can load it from the URL when cypress loads?), otherwise we will need to add the extension to version control and keep updating it from time to time.

terichadbourne commented 4 years ago

Notes from 2020-09-11 call with @zebateira @andyschwab @lidel @hugomrdias re challenges and UX options for enabling DNSlink for ProtoSchool:

terichadbourne commented 3 years ago

@lidel This is a belated response regarding the PR to add the deny list in IPFS Companion. I really appreciate your work on that and the great wording tweaks from @jessicaschilling! My notes here are probably a mix of suggestions that could potentially apply to everyone in Companion and things that are just me confirming I know where we're at. 😂 Happy to move any suggestions over to your repo if merited.

My one uncomfortable gut reaction to that PR was about that I think of "manual" meaning I exerted effort to do it myself, and wouldn't expect automatic things to be under that label. Do we want to explain how something could be in your supposedly manual opt-out list when you didn't manually put it there yourself? One way to do it might be a text link under the box that says "Don't recognize one of these sites?" and if you click it, it says something longer like "Some web developers disable [insert right words] by default because certain features may be affected when accessing their site via [insert right words]. Before removing a site you use from this opt-out list, you may want to check their website for a guide to functionality differences". But shorter and with words like DNSLink or IPFS Companion or local gateway inserted as appropriate. 😂 (Sorry, still working on getting the right vocab on this one.)

Also just confirming I understand the flow and options here under the new system based on the change you just merged. Is my interpretation below correct?

If I'm understanding correctly, we've arrived (from the Companion side) at Option 3, Deny List Option A from the previous comment. There's an open issue to switch to Deny List Option B, which won't affect the ProtoSchool team moving forward. And it's up to the ProtoSchool team to get us to Option 4 using by mimicking Lidel's POC. Does that sound accurate?

jessicaschilling commented 3 years ago

Hi @terichadbourne - I can't weigh in on anything after your second paragraph, but just a note that subsequent commits in https://github.com/ipfs-shipyard/ipfs-companion/pull/929 got rid of the "manual" wording and explained that you can also add/remove items on those two lists by using the toggle in the browser bar menu. 😊

lidel commented 3 years ago

@terichadbourne thank you for this thoughtful analysis :pray:

We indeed implemented Option 3A, but instead of 3B (centralized opt-out list) we plan to let website owners to control default behavior somehow (https://github.com/ipfs-shipyard/ipfs-companion/issues/930) (no central list to manage, every site controls their own fate). Option 4 is up to you, but see my last note below.

Overall, things are a bit simpler than what you described and I believe the gist is:

lidel commented 3 years ago

Some updates:

terichadbourne commented 3 years ago

@lidel Wanted to check in and ask whether either the recent Brave integration or the DNSLink / TLS updates you shared today will change anything about the effects of us enabling DNSLink?

lidel commented 3 years ago

@terichadbourne loading ipns://proto.school will have the same effect as loading from localhost gateway: it will get a different Origin than https://proto.school (separate storage and users will lose progress)