token not found - cml send-comment
however I found some issue in "cml send-comment report.md" command, even report with one line has token not found error (using bitbucket):
{"level":"error","message":"token not found","stack":"Error: token not found\n at new BitbucketCloud (/usr/lib/node_modules/@dvcorg/cml/src/drivers/bitbucket_cloud.js:18:23)\n at getDriver (/usr/lib/node_modules/@dvcorg/cml/src/cml.js:88:29)\n at CML.triggerSha (/usr/lib/node_modules/@dvcorg/cml/src/cml.js:153:21)\n at CML.commentCreate (/usr/lib/node_modules/@dvcorg/cml/src/cml.js:163:35)\n at Object.exports.handler (/usr/lib/node_modules/@dvcorg/cml/bin/cml/send-comment.js:11:25)\n at /usr/lib/node_modules/@dvcorg/cml/node_modules/yargs/build/index.cjs:1:8891\n at j (/usr/lib/node_modules/@dvcorg/cml/node_modules/yargs/build/index.cjs:1:4956)\n at M.handleValidationAndGetResult (/usr/lib/node_modules/@dvcorg/cml/node_modules/yargs/build/index.cjs:1:8860)\n at M.applyMiddlewareAndGetResult (/usr/lib/node_modules/@dvcorg/cml/node_modules/yargs/build/index.cjs:1:9502)\n at M.runCommand (/usr/lib/node_modules/@dvcorg/cml/node_modules/yargs/build/index.cjs:1:7231)"}
Have you exposed an environment variables named REPO_TOKEN with a personal access token?
Do you have any example to use REPO_TOKEN in Bitbucket?
👋 @eb-art here you can find how to setup a proper REPO_TOKEN in BB
@eb-art, were you able to resolve the problem with the above link?
unfortunately I still have an authorization error despite the steps from link
@eb-art is your pipeline public that I can take a look?
Some other debug steps that might help is to run env | grep REPO_TOKEN to make sure it is present. Additionally you can make sure that the value is correct, run: echo -n "$REPO_TOKEN | md5sum" this should produce the same sum as if you regenerate the token: echo -n "my_username:my_app_password" | base64 then echo -n "token" | md5sum
@eb-art we are closing this. Please reopen it if you find is still unresolved.