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

Improve UX when $IPFS_PATH/api exists and API is offline #713

Closed
lidel opened this issue Nov 24, 2018 · 6 comments
Closed

Improve UX when $IPFS_PATH/api exists and API is offline #713

lidel opened this issue Nov 24, 2018 · 6 comments
Assignees

Comments

@lidel
Copy link
Member

lidel commented Nov 24, 2018

The $IPFS_PATH/api file is used by a lot of developers to talk to remote nodes (learning from ipfs-companion users). T

How to improve UX for "the API defined in $IPFS_PATH/api is offline" scenario?

Perhaps like this:

  • IF $IPFS_PATH/api file exists and is different from the one in the config file
  • AND IF multiaddr inside of api file points at remote API which produces ECONNREFUSED error,
  • THEN ipfs-desktop should inform user about the problem with connection to remote node at {multiaddr} and display error window with built-in UI for dealing with it.

It could be a styled window similar to this mockup but with nice UI to:

  • (A) Change value in api file
  • (B) Run ipfs repo fsck
    • to remove api and potential lockfiles and try again (should be safe, technical user can always restore file by hand)
  • (C) Quit
@hacdias
Copy link
Member

hacdias commented Nov 24, 2018

Reminder to self: #711 (review).

@hacdias hacdias self-assigned this Nov 26, 2018
This was referenced Nov 27, 2018
@lidel
Copy link
Member Author

lidel commented Nov 28, 2018

(updated description to reflect what we learned during today's sync call)

This was referenced Dec 7, 2018
@hacdias
Copy link
Member

hacdias commented Dec 8, 2018

I believe we can close this now as #722 was closed!

@hacdias hacdias closed this as completed Dec 8, 2018
@lidel
Copy link
Member Author

lidel commented Dec 9, 2018

Just tested master @ 3b7c781 and having an empty $IPFS_PATH with api file alone produces this error:

Error: ENOENT: no such file or directory, open '/home/lidel/.ipfs/config'

We need to add proper error handling for that setup :)
(We really should plan to create tests for startup logic, otherwise we will fix one thing and then break another)

@lidel lidel reopened this Dec 9, 2018
@hacdias
Copy link
Member

hacdias commented Dec 9, 2018

@lidel that error might be caused by this line which will be removed as soon as the CORS PR (#738) is merged 😄 So it won't be a problem as we won't be testing the existence of any files.

@hacdias
Copy link
Member

hacdias commented Feb 16, 2019

That case is already solved. I'm closing this for now since we've already added the necessary logic for the scenarios here described.

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