Skip to content

hardcoded API url leads to bad credentials error on GitHub Enterprise server #90

@Th3S4mur41

Description

@Th3S4mur41

Running the conventional-pr action on an on premise GitHub Enterprise server results in a bad crendentials error.
The error is misleading though and results from the fact that the action is trying to fetch the pull request data from github.com instead of the actual GitHub server.

Run Namchee/conventional-pr@v0.13.0
2023/09/06 06:23:14 [INFO] Initializing conventional-pr
2023/09/06 06:23:14 [INFO] Reading configuration from environment variables
2023/09/06 06:23:14 [INFO] Reading repository metadata
2023/09/06 06:23:14 [INFO] Initializing GitHub Client
2023/09/06 06:23:14 [INFO] Reading pull request metadata
2023/09/06 06:23:14 [INFO] Validating pull request sub-events
Error: /06 06:23:14 [ERROR] Failed to fetch pull request data: GET https://api.github.com/repos/***/***/pulls/20: 401 Bad credentials []

All references to https://api.github.com should be replaced through ${{github.api_url}} to allow the action to work on Enterprise server

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions