Details
-
Bug
-
Status: Resolved (View Workflow)
-
Minor
-
Resolution: Fixed
-
Atlassian Bitbucket Server Integration plugin versions 2.1.2 and below
-
-
3.0.0
Description
Steps to reproduce:
- Create a Bitbucket Server instance in Jenkins, and register with an invalid personal access token (either completely fake, without sufficient permissions, or one that was valid but is later revoked)
- Create a new Multibranch Pipeline job
- Configure a Bitbucket SCM Source using the server instance created previously. Make sure the job credentials are read-only (and thus cannot push a webhook)
- Check the `Bitbucket Server trigger scan after push` trigger
- Save the job
Expected Behaviour:
Jenkins informs you in a gentle and polite way that the admin token does not have webhook write permission, and to please contact your system administrator to resolve the issue.
Actual Behaviour:
Angry jenkins and a non-descriptive "401" buried in the stack trace.
Workaround
None needed- this is more a usability issue. If encountering this screen, check your token credentials have access to the resource specified in failing job.
This seems to have been fixed by https://github.com/jenkinsci/atlassian-bitbucket-server-integration-plugin/commit/d447031a255b52b27d3ca7ab6fa64afd89661e9f#diff-ed9f29c11fc5b996df33a07d0643914c98ac75e7a28a3f90335963929725c5ee which was released in 3.0.0