Integration with Bitbucket Failing
Hi
First, I want to express my appreciation for the hard work and dedication you've put into developing this repository. It has greatly aided our workflow by providing automatic GPT-based code reviews for our Bitbucket projects.
Unfortunately, we've encountered an issue where the integration has stopped functioning as expected. The problem began two days ago, coinciding with a new release, which might be related.
Here is our bitbucket-pipelines.yml:
- step:
# https://github.com/minhlucvan/crgpt
name: CRGPT Code Review
image: node
script:
- echo "Environment Variables"
- echo "BITBUCKET_PR_ID $BITBUCKET_PR_ID"
- echo "BITBUCKET_BRANCH $BITBUCKET_BRANCH"
- echo "BITBUCKET_PR_DESTINATION_BRANCH $BITBUCKET_PR_DESTINATION_BRANCH"
- echo "BITBUCKET_REPO_SLUG $BITBUCKET_REPO_SLUG"
- echo "BITBUCKET_WORKSPACE $BITBUCKET_WORKSPACE"
- echo "Installing crgpt"
- npm install -g crgpt
- git fetch origin "+refs/heads/*:refs/remotes/origin/*"
- crgpt -o bitbucket -p $BITBUCKET_PR_ID -s "refs/remotes/origin/$BITBUCKET_BRANCH" -t "refs/remotes/origin/$BITBUCKET_PR_DESTINATION_BRANCH" -rs $BITBUCKET_REPO_SLUG -ps $BITBUCKET_WORKSPACE -bt $BITBUCKET_ACCESS_TOKEN -at $OPENAI_TOKEN review
The process fails with the following error log:
- crgpt -o bitbucket -p $BITBUCKET_PR_ID -s "refs/remotes/origin/$BITBUCKET_BRANCH" -t "refs/remotes/origin/$BITBUCKET_PR_DESTINATION_BRANCH" -rs $BITBUCKET_REPO_SLUG -ps $BITBUCKET_WORKSPACE -bt $BITBUCKET_ACCESS_TOKEN -at $OPENAI_TOKEN review (node:46) [DEP0040] DeprecationWarning: The
punycodemodule is deprecated. Please use a userland alternative instead. (Usenode --trace-deprecation ...to show where the warning was created) run CRGPT sourceBranch: refs/remotes/origin/revert-pr-925 targetBranch: refs/remotes/origin/master Processing file: Posting comment to Bitbucket PR: 929 Error posting comment to Bitbucket PR: Not Found Error: Error posting comment to Bitbucket PR: Not Found at /usr/local/lib/node_modules/crgpt/dist/lib/bitbucket.js:82:31 at step (/usr/local/lib/node_modules/crgpt/dist/lib/bitbucket.js:33:23) at Object.next (/usr/local/lib/node_modules/crgpt/dist/lib/bitbucket.js:14:53) at fulfilled (/usr/local/lib/node_modules/crgpt/dist/lib/bitbucket.js:5:58) at process.processTicksAndRejections (node:internal/process/task_queues:105:5)
Could you please investigate whether the recent release might be causing this issue? Additionally, if there's a temporary workaround to restore functionality, it would be greatly appreciated. Thank you for your attention to this matter, and for your continued support and improvements to this project.
FYI: By downgrading the crgpt package from the latest version to 1.1.2 using the following command, we were able to restore functionality:
npm install -g [email protected]
thanks @weiyuDatawiza , I'am gonna fix this asap