inrupt / inrupt/solid-client-authn-js

node/examples/bootstrappedAppESM/ : A redirection handler must be provided in the Node environment. but we can't have one

Open
#3,175 7 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

bug
Dominant language
TypeScript
Stars
77
Forks
49
Avg merge
18h 20m
Merged PRs (30d)
32

Description

trying ~/dev/solid-client-authn-js/packages/node/examples/bootstrappedAppESM/src$ node authenticatedScript.mjs --clientId https://id.inrupt.com/my_user --oidcIssuer https://login.inrupt.com/ --clientSecret mypassword --resource https://otherpod.solidcommunity.net/profile/card

i've got this error

Error: A redirection handler must be provided in the Node environment.
    at Redirector.redirect (file:///home/user/dev/solid-client-authn-js/packages/node/dist/index.mjs:896:19)
    at AuthorizationCodeWithPkceOidcHandler.handleRedirect (file:///home/user/dev/solid-client-authn-js/packages/core/dist/index.mjs:349:25)
    at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
    at async ClientAuthentication.login (file:///home/user/dev/solid-client-authn-js/packages/node/dist/index.mjs:83:33)
    at async Session.login (file:///home/user/dev/solid-client-authn-js/packages/node/dist/index.mjs:1292:31)
    at async main (file:///home/user/dev/solid-client-authn-js/packages/node/examples/bootstrappedAppESM/src/authenticatedScript.mjs:37:3)

whereas in the doc , a handler is optional

image

and as we are on the server side, we can not have a url for redirection

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with packages/node/examples/bootstrappedAppESM/src/authenticatedScript.mjs and reproduce the command shown in the issue. Trace the login path from that entry point through the Node redirect handling, then compare it with the documentation shown; done means the documented optional-handler behavior and the Node example's actual requirements are reconciled.

Written by the indexing model from the issue text.

Assessment

Tech stack
node.js, typescript
Domain
authentication, backend
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.