Skip to content

Conversation

@mvdoc
Copy link

@mvdoc mvdoc commented Jan 26, 2026

I was trying to upload a new dataset with the CLI (v4.4.0), but kept getting login errors despite having logged in multiple times. The following was fixed with Claude. Now I'm able to upload the dataset (ongoing).


Claude's comment:

Commit 2fae59b changed getRepoAccess() signature to require an instance URL as the first parameter, but these three callers were not updated. This caused getConfig(instance) to look up tokens using the dataset ID instead of the URL, resulting in "Run openneuro login" errors.

Commit 2fae59b changed getRepoAccess() signature to require an instance
URL as the first parameter, but these three callers were not updated.
This caused getConfig(instance) to look up tokens using the dataset ID
instead of the URL, resulting in "Run openneuro login" errors.

Co-Authored-By: Claude Opus 4.5 <[email protected]>
Copilot AI review requested due to automatic review settings January 26, 2026 21:49
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Fixes CLI authentication failures by updating remaining getRepoAccess() call sites to pass the instance URL as the first argument, aligning with the updated function signature and ensuring tokens are looked up using the correct config key.

Changes:

  • Update upload command to call getRepoAccess(clientConfig.url, datasetId).
  • Update download command to call getRepoAccess(clientConfig.url, datasetId).
  • Update special-remote to derive instanceUrl from the provided URL and call getRepoAccess(instanceUrl, datasetId).

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated no comments.

File Description
cli/src/commands/upload.ts Passes configured instance URL into getRepoAccess() so repo tokens resolve correctly during upload.
cli/src/commands/download.ts Passes configured instance URL into getRepoAccess() so repo tokens resolve correctly during download.
cli/src/commands/special-remote.ts Extracts instance origin from the remote URL and passes it into getRepoAccess() for correct token lookup.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

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

Successfully merging this pull request may close these issues.

1 participant