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

PAT from keychain works during init but not for any other command #791

Open
wduda opened this issue Oct 26, 2024 · 1 comment
Open

PAT from keychain works during init but not for any other command #791

wduda opened this issue Oct 26, 2024 · 1 comment

Comments

@wduda
Copy link

wduda commented Oct 26, 2024

Describe the bug
I have added my PAT to keychain on macOS. I run jira init and the config is successful and lists the boards in the project for example. However, when I try to execute any other command (like jira me) it asks me to put the PAT in the env variable or netrc file, and does nothing, and seemingly forgets the existence of the PAT in the keychain.

Please provide following details

  1. JiraCLI Version:
    (Version="1.5.2", GitCommit="34221786aaa12d5bc66039d164b6d9587b0799c7", CommitDate="2024-09-20T08:29:56+00:00", GoVersion="go1.23.1", Compiler="gc", Platform="darwin/arm64")
  2. Are you using Jira cloud or on-premise jira server?
    on premise
    No serverinfo output as jira-cli asks to put PAT in env variable but I have it in keychain.
    I cpopied this from the config file generated by jira init:
    version:
    major: 9
    minor: 12
    patch: 13
  3. What operating system are you using? Also mention version.
    macOS Version 15.0.1 (24A348)
  4. What terminal are you using? Also mention version.
    iTerm 2 Build 3.5.5

Steps to reproduce the behavior:

  1. Add PAT to Keychain
  2. Do NOT set an env variable JIRA_API_TOKEN
  3. Install jira-cli
  4. Run jira init successfully with PAT being provided by keychain
  5. Try any command like jira me or jira serverinfo
  6. JIRA CLI will print the error message starting with "The tool needs a Jira API token to function. ..."

Expected behavior
All Jira-cli commands work with PAT provided from keychain.

@wduda
Copy link
Author

wduda commented Oct 26, 2024

Providing the PAT through export JIRA_API_TOKEN="" makes all commands successful again. But that cannot be the point of claiming keychain support if one still has to use the env variable.

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

1 participant