Skip to content

Error cannot fetch your preferences when not logged in #464

Closed

Description

@bourgeoa
Unable to fetch your preferences - this was the error:  Error: (via loadPrefs) Error: Can't log in: Error: Could not log in
    at _callee5$ (authn.ts:288)
    at tryCatch (runtime.js:63)
    at Generator.invoke [as _invoke] (runtime.js:294)
    at Generator.throw (runtime.js:119)
    at asyncGeneratorStep (asyncToGenerator.js:3)
    at _throw (asyncToGenerator.js:29)

The error is raised in https://github.com/solid/solid-ui/blob/6a9e81a980072cb7f7b8e8098346bd1acac55269/src/authn/authn.ts#L219

This is caused by calling solidLogicSingelton without being logged in

Activity

  1. SharonStrats commented on Jan 9, 2022

    @SharonStrats
    Collaborator

    Hi @bourgeoa I'm wondering what would the expected behavior be? Should we just be told that we are not logged in?

    I also can't seem to recreate it. I'm wondering if you could show the steps you took to produce it. I logged in, went to preferences, logged out and it just refreshes and goes to my public data.

  2. bourgeoa commented on Jan 9, 2022

    @bourgeoa
    ContributorAuthor

    what would the expected behavior be? Should we just be told that we are not logged in?

    @SharonStrats Profile and public preferences should be available.

    I also can't seem to recreate it. I'm wondering if you could show the steps you took to produce it. I logged in, went to preferences, logged out and it just refreshes and goes to my public data.

    Logging out do not clear public preferences

  3. ewingson commented on Jan 9, 2022

    @ewingson
    Member

    @bourgeoa @SharonStrats

    maybe this is a good first issue to wrap my head around.
    I' m trying to reproduce it. being not logged in and opening the settings container throws a 401 (see pic).

    what is the desired behaviour ? being in which state and doing what exact steps shows the error ?
    where would the public preferences be meant to be shown ?

    Bildschirmfoto_2022-01-09_11-31-32

  4. bourgeoa commented on Jan 9, 2022

    @bourgeoa
    ContributorAuthor

    @ewingson
    The error appears in the browser developper :
    image

  5. ewingson commented on Jan 9, 2022

    @ewingson
    Member

    @bourgeoa @SharonStrats

    I was able to reproduce it (see pic).
    Alain, you already tracked it down fortunately.
    Dunno though if the code seems to trigger (or need) a Login.

    maybe we must remove (or modify) the triggering mechanism solidLogicSingelton.
    Bildschirmfoto_2022-01-09_13-12-44

  6. ewingson commented on Jan 9, 2022

    @ewingson
    Member

    @bourgeoa @SharonStrats

    I tried to follow the code flow.
    to me the console says Line 288. ((see two pics)).
    Bildschirmfoto_2022-01-09_14-07-58
    Bildschirmfoto_2022-01-09_14-07-12

  7. added
    priority-highto be used for important issues and pull requests that need to be addressed soon
    on Mar 31, 2022
  8. timea-solid commented on Apr 26, 2022

    @timea-solid
    Member

    Since we are not logged in, it should not even try to read the preference file. The check to see if the user is logged in should happen before, in the code. @jeff-zucker am I correct to say that the app should not even look for it?

  9. jeff-zucker commented on Apr 27, 2022

    @jeff-zucker
    Contributor

    Yes, I believe that is correct, the preferencesFile is private and can only be accessed when logged in so there is no point in looking for it if not logged in. I believe the correct behavior is

    1. Load the WebID Profile Document
    2. If logged in, load the preferences file
      2a. If no preferences file found, offer to create one
    3. If not logged in, perhaps informative message in console :"not logged in, no preferences loaded"
  10. timea-solid commented on Apr 28, 2022

    @timea-solid
    Member

    This was also discussed in SolidOS team meeting (see under tech topics).
    Same steps as Jeff mentioned a bit more implementation detail.

  11. self-assigned this
    on Mar 15, 2026
  12. SharonStrats commented on Mar 15, 2026

    @SharonStrats
    Collaborator

    PR #710

    The error is now from solid-ui installHook.js:1 Unable to fetch your preferences - this was the error: Error: (via loadPrefs) Error: Can't log in: Error: Could not log in
    at solid-ui.js:9659:17
    at solid-ui.js:655:18
    at Generator. (solid-ui.js:921:51)
    at Generator.throw (solid-ui.js:456:21)
    at v (solid-ui.js:1350:15)
    at s (solid-ui.js:1367:9)

  13. linked a pull request that will close this issuePost milestone3m #744on May 28, 2026
  14. SharonStrats commented on May 28, 2026

    @SharonStrats
    Collaborator

    I believe this was closed with post-milestone3m solid-logic and solid-ui.

  15. moved this from Done to Backlog in SolidOS NLNet UIon Jun 11, 2026
  16. moved this from Backlog to In review in SolidOS NLNet UIon Jul 4, 2026
  17. moved this from In review to Ready in SolidOS NLNet UIon Jul 13, 2026
  18. closed this as completedby moving to Done in SolidOS NLNet UIon Sep 29, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

bugpriority-highto be used for important issues and pull requests that need to be addressed soon

Type

No type

Projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions