Open terichadbourne opened 4 years ago
Note about relative paths deployment (ipfs gateway): since fleek has deployment setup to subdomains, this will not be an issue.
Quick brain dump before today's meeting:
?x-ipfs-companion-no-redirect
or #x-ipfs-companion-no-redirect
to the URL of a resource that should not be redirected
Regarding "new localStorage" and losing progress history:
window.location.origin
is not https://proto.school
and if there is no progress data in localStorage display modal informing user that the progress will be tied to current origin, and if they see progress missing, suggest disabling gateway redirect for protoschool and resume at https://proto.school
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.
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.
Notes from 2020-09-11 call with @zebateira @andyschwab @lidel @hugomrdias re challenges and UX options for enabling DNSlink for ProtoSchool:
Currently testing on Fleek - backend on IPFS but delivered with user’s browser unaware that it’s on IPFS, can’t discover on Companion until DNSlink is set up
Redirect issues
Issue Chris opened re native redirects in IPFS (via HTTP Gateway) is not expected to land in 0.8, not anytime soon, at least 2 releases from now
Have ipfs-404.html feature but can’t set up manifest
This issue affects ability to:
Doing redirects in SEO-safe way (header, sitemap)
You get penalized for client-side redirects (not as bad w/o timers/ads)
Using ipfs-404.html file for Fleek to address /*
Non-404 redirects (eg chapters -> events): Fleek can do some server-side stuff but better to address it from IPFS side - shortcoming of IPFS, not Fleek
Persistence issues with user history in localStorage
Current issues with ProtoSchool + DNSlink (once enabled)
UX options for lost history issue:
OPTION 1: Automatically switch to IPFS version w/o messaging on why history disappears
OPTION 2: Automatically switch to IPFS version and pop up a message about why their history is lost
OPTION 3: Opt out of Companion by default and let them toggle on, with no ProtoSchool-specific messaging
Deny List Option B: serve deny list through IPNS and updatable from, say, a GitHub repo (so anyone could add themselves to the list, and it wouldn’t require publishing a new release)
OPTION 4: Opt out of Companion by default and let user toggle on, warning them in advance that it will delete their history
Can website detect that a user is running a local IPFS gateway in order to pop up a warning before they use the option to toggle on?
Root question of persistence - what would be the web3 equivalent of localStorage?
NEXT ACTIONS:
@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?
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. 😊
@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:
/ipfs/<cid>
etc)window.location.origin === 'https://proto.school'
and display some infobox informing user that their progress will be tied to window.location.origin
Some updates:
x-ipfs-path
header unless DNSLink is set up, to avoid in-between state for other websites where human-readable domain gets redirected to immutable CID.@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?
@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)
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.