Skip to content

GITHUB_PERSONAL_ACCESS_TOKEN not set #144

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

Closed
greggh opened this issue Apr 6, 2025 · 6 comments
Closed

GITHUB_PERSONAL_ACCESS_TOKEN not set #144

greggh opened this issue Apr 6, 2025 · 6 comments
Labels
bug Something isn't working

Comments

@greggh
Copy link

greggh commented Apr 6, 2025

Describe the bug

I am getting this fatal error when starting up the MCP:

GITHUB_PERSONAL_ACCESS_TOKEN not set

It is in my environment, set with an export in my .zshrc. It is in the env key in the mcpServers entry for github. It is also set in the args for the docker command. It is in every place I can put the token.

Affected version

Please run docker run -i --rm ghcr.io/github/github-mcp-server ./github-mcp-server --version and paste the output below

server version v0.1.0 (b893367) 2025-04-04T15:38:19Z

Steps to reproduce the behavior

Start the MCP, get this error.

Expected vs actual behavior

MCP sees the settings and doesnt give me the error.

Logs

Image

@greggh greggh added the bug Something isn't working label Apr 6, 2025
@rpfelgueiras
Copy link

rpfelgueiras commented Apr 7, 2025

I had this same error. Not sure if I will help or not, but I was replacing the GITHUB_PERSONAL_ACCESS_TOKEN in too many places 😅 See the screenshot below.

Image

I hope it helps.

@lukeojones
Copy link

I've tried following the readme to use the promptString input method (and therefore leverage VSCode's secrets functionality) but that doesn't work here so I've had to add the pat key directly to the settings.json for now (which I obviously don't want to do as it's bad practice).

Anyone else managed to figure this out? Or get the prompt to show when starting the server?

@greggh
Copy link
Author

greggh commented Apr 7, 2025

I had this same error. Not sure if I will help or not, but I was replacing the GITHUB_PERSONAL_ACCESS_TOKEN in too many places 😅 See the screenshot below.

Image I hope it helps.

This fixes it. thank you @rpfelgueiras

@greggh greggh closed this as completed Apr 7, 2025
@VladyslavXXI
Copy link

@lukeojones this might help.

@lukeojones
Copy link

@lukeojones this might help.

Nice! Will give this a try. Thanks.

@jlehnGIT
Copy link

jlehnGIT commented May 8, 2025

Hello, I am seeing this issue and have tried the install via the link as well as manually copying and pasting the settings.

FATA[0000] GITHUB_PERSONAL_ACCESS_TOKEN not set

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

5 participants