René's URL Explorer Experiment


Title: Add Bitbucket PR comment support by obarrera · Pull Request #206 · SocketDev/socket-python-cli · GitHub

Open Graph Title: Add Bitbucket PR comment support by obarrera · Pull Request #206 · SocketDev/socket-python-cli

X Title: Add Bitbucket PR comment support by obarrera · Pull Request #206 · SocketDev/socket-python-cli

Description: Summary Adds socketsecurity/core/scm/bitbucket.py with BitbucketConfig + Bitbucket SCM that posts/updates Dependency Overview and Security Issue comments on Bitbucket Cloud PRs, mirroring the GitHub and GitLab modules. Reads BITBUCKET_* Pipelines env vars; supports Bearer (BITBUCKET_TOKEN) or Basic auth (BITBUCKET_USERNAME + BITBUCKET_APP_PASSWORD). BITBUCKET_API_URL lets Server/Data Center users point at a self-hosted REST API. Normalizes Bitbucket's {content: {raw}, user: {nickname, uuid}} payload onto the shared Comment dataclass so the existing Comments helpers, ignore-command flow, and security-comment scrubbing all work unchanged. Substitutes Bitbucket's missing reaction API with a hidden marker that has_thumbsup_reaction looks for on subsequent runs. Wires --scm bitbucket into socketcli.py and updates workflows/bitbucket-pipelines.yml to use it. Why The Bitbucket comment implementation was partially completed, but couldn't get the API to accept comments. Most likely culprit: GitHub-style {"body": "..."} form-encoded payloads, where Bitbucket Cloud requires JSON {"content": {"raw": "..."}} with Content-Type: application/json. This PR uses that shape. Out of scope Azure DevOps — left for a follow-up since it's a separate API surface. Live smoke test on a real Bitbucket workspace — a test instance still needs to be set up. Test plan uv run pytest tests/unit/test_bitbucket.py — 15 new tests covering env parsing (Bearer + Basic + missing creds), default-branch detection, event-type detection, comment normalization (raw content, deleted, missing fields), POST/PUT payload shape, and create-vs-update dispatch. uv run pytest tests/unit -q --no-cov — 164 passed, 2 pre-existing skips. End-to-end run against a Bitbucket Cloud PR on a workspace with BITBUCKET_TOKEN configured. End-to-end run with BITBUCKET_USERNAME / BITBUCKET_APP_PASSWORD to confirm Basic auth path. Verify ignore-comment flow: post @SocketSecurity ignore npm/foo@1.0.0, re-run, confirm alert filtered + hidden marker appended. (Optional) Bitbucket Server / Data Center run with BITBUCKET_API_URL override.

Open Graph Description: Summary Adds socketsecurity/core/scm/bitbucket.py with BitbucketConfig + Bitbucket SCM that posts/updates Dependency Overview and Security Issue comments on Bitbucket Cloud PRs, mirroring the GitH...

X Description: Summary Adds socketsecurity/core/scm/bitbucket.py with BitbucketConfig + Bitbucket SCM that posts/updates Dependency Overview and Security Issue comments on Bitbucket Cloud PRs, mirroring the GitH...

Opengraph URL: https://github.com/SocketDev/socket-python-cli/pull/206

X: @github

direct link

Domain: redirect.github.com

route-pattern/:user_id/:repository/pull/:id/files(.:format)
route-controllerpull_requests
route-actionfiles
fetch-noncev2:4782e69e-f18a-637a-4cbb-d6459889a243
current-catalog-service-hashae870bc5e265a340912cde392f23dad3671a0a881730ffdadd82f2f57d81641b
request-id81D2:9E5FA:10C55C8:173CECF:6A4E9376
html-safe-noncef93ac5cd68ae414505ee63fb130ede3e4bb903d7cb699190e238b7d286ad451e
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiI4MUQyOjlFNUZBOjEwQzU1Qzg6MTczQ0VDRjo2QTRFOTM3NiIsInZpc2l0b3JfaWQiOiI1MzQ3MDg3NTQzNDUwODk5MzE4IiwicmVnaW9uX2VkZ2UiOiJpYWQiLCJyZWdpb25fcmVuZGVyIjoiaWFkIn0=
visitor-hmac4580ae16d9306a7a139d4d8c32b4952370a8acf7e5800971b7e3711226d75927
hovercard-subject-tagpull_request:3763432919
github-keyboard-shortcutsrepository,pull-request-list,pull-request-conversation,pull-request-files-changed,copilot
google-site-verificationApib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I
octolytics-urlhttps://collector.github.com/github/collect
analytics-location///pull_requests/show/files
fb:app_id1401488693436528
apple-itunes-appapp-id=1477376905, app-argument=https://github.com/SocketDev/socket-python-cli/pull/206/files
twitter:imagehttps://avatars.githubusercontent.com/u/1621370?s=400&v=4
twitter:cardsummary_large_image
og:imagehttps://avatars.githubusercontent.com/u/1621370?s=400&v=4
og:image:altSummary Adds socketsecurity/core/scm/bitbucket.py with BitbucketConfig + Bitbucket SCM that posts/updates Dependency Overview and Security Issue comments on Bitbucket Cloud PRs, mirroring the GitH...
og:site_nameGitHub
og:typeobject
hostnamegithub.com
expected-hostnamegithub.com
None41b6ab3ba6d20a71766ac245b5a4a94c6fc672a9cd4da7d44c1b33ab8bf6a21c
turbo-cache-controlno-preview
diff-viewunified
go-importgithub.com/SocketDev/socket-python-cli git https://github.com/SocketDev/socket-python-cli.git
octolytics-dimension-user_id69326764
octolytics-dimension-user_loginSocketDev
octolytics-dimension-repository_id802230750
octolytics-dimension-repository_nwoSocketDev/socket-python-cli
octolytics-dimension-repository_publictrue
octolytics-dimension-repository_is_forkfalse
octolytics-dimension-repository_network_root_id802230750
octolytics-dimension-repository_network_root_nwoSocketDev/socket-python-cli
turbo-body-classeslogged-out env-production page-responsive full-width
disable-turbotrue
browser-stats-urlhttps://api.github.com/_private/browser/stats
browser-errors-urlhttps://api.github.com/_private/browser/errors
releasee6a744804e8e70f97b4d5a18a94dcc63db22f97a
ui-targetfull
theme-color#1e2327
color-schemelight dark

Links:

Skip to contenthttps://redirect.github.com/SocketDev/socket-python-cli/pull/206/files#start-of-content
https://redirect.github.com/
Sign in https://redirect.github.com/login?return_to=https%3A%2F%2Fgithub.com%2FSocketDev%2Fsocket-python-cli%2Fpull%2F206%2Ffiles
GitHub CopilotWrite better code with AIhttps://github.com/features/copilot
GitHub Copilot appDirect agents from issue to mergehttps://github.com/features/ai/github-app
MCP RegistryNewIntegrate external toolshttps://github.com/mcp
ActionsAutomate any workflowhttps://github.com/features/actions
CodespacesInstant dev environmentshttps://github.com/features/codespaces
IssuesPlan and track workhttps://github.com/features/issues
Code ReviewManage code changeshttps://github.com/features/code-review
GitHub Advanced SecurityFind and fix vulnerabilitieshttps://github.com/security/advanced-security
Code securitySecure your code as you buildhttps://github.com/security/advanced-security/code-security
Secret protectionStop leaks before they starthttps://github.com/security/advanced-security/secret-protection
Why GitHubhttps://github.com/why-github
Documentationhttps://docs.github.com
Bloghttps://github.blog
Changeloghttps://github.blog/changelog
Marketplacehttps://github.com/marketplace
View all featureshttps://github.com/features
Enterpriseshttps://github.com/enterprise
Small and medium teamshttps://github.com/team
Startupshttps://github.com/enterprise/startups
Nonprofitshttps://github.com/solutions/industry/nonprofits
App Modernizationhttps://github.com/solutions/use-case/app-modernization
DevSecOpshttps://github.com/solutions/use-case/devsecops
DevOpshttps://github.com/solutions/use-case/devops
CI/CDhttps://github.com/solutions/use-case/ci-cd
View all use caseshttps://github.com/solutions/use-case
Healthcarehttps://github.com/solutions/industry/healthcare
Financial serviceshttps://github.com/solutions/industry/financial-services
Manufacturinghttps://github.com/solutions/industry/manufacturing
Governmenthttps://github.com/solutions/industry/government
View all industrieshttps://github.com/solutions/industry
View all solutionshttps://github.com/solutions
AIhttps://github.com/resources/articles?topic=ai
Software Developmenthttps://github.com/resources/articles?topic=software-development
DevOpshttps://github.com/resources/articles?topic=devops
Securityhttps://github.com/resources/articles?topic=security
View all topicshttps://github.com/resources/articles
Customer storieshttps://github.com/customer-stories
Events & webinarshttps://github.com/resources/events
Ebooks & reportshttps://github.com/resources/whitepapers
Business insightshttps://github.com/solutions/executive-insights
GitHub Skillshttps://skills.github.com
Documentationhttps://docs.github.com
Customer supporthttps://support.github.com
Community forumhttps://github.com/orgs/community/discussions
Trust centerhttps://github.com/trust-center
Partnershttps://github.com/partners
View all resourceshttps://github.com/resources
GitHub SponsorsFund open source developershttps://github.com/open-source/sponsors
Security Labhttps://securitylab.github.com
Maintainer Communityhttps://maintainers.github.com
Acceleratorhttps://github.com/open-source/accelerator
GitHub Starshttps://stars.github.com
Archive Programhttps://archiveprogram.github.com
Topicshttps://github.com/topics
Trendinghttps://github.com/trending
Collectionshttps://github.com/collections
Enterprise platformAI-powered developer platformhttps://github.com/enterprise
GitHub Advanced SecurityEnterprise-grade security featureshttps://github.com/security/advanced-security
Copilot for BusinessEnterprise-grade AI featureshttps://github.com/features/copilot/copilot-business
Premium SupportEnterprise-grade 24/7 supporthttps://github.com/enterprise/premium-support
Pricinghttps://github.com/pricing
Search syntax tipshttps://docs.github.com/search-github/github-code-search/understanding-github-code-search-syntax
documentationhttps://docs.github.com/search-github/github-code-search/understanding-github-code-search-syntax
Sign in https://redirect.github.com/login?return_to=https%3A%2F%2Fgithub.com%2FSocketDev%2Fsocket-python-cli%2Fpull%2F206%2Ffiles
Sign up https://redirect.github.com/signup?ref_cta=Sign+up&ref_loc=header+logged+out&ref_page=%2F%3Cuser-name%3E%2F%3Crepo-name%3E%2Fpull_requests%2Fshow%2Ffiles&source=header-repo&source_repo=SocketDev%2Fsocket-python-cli
Reloadhttps://redirect.github.com/SocketDev/socket-python-cli/pull/206/files
Reloadhttps://redirect.github.com/SocketDev/socket-python-cli/pull/206/files
Reloadhttps://redirect.github.com/SocketDev/socket-python-cli/pull/206/files
Please reload this pagehttps://redirect.github.com/SocketDev/socket-python-cli/pull/206/files
SocketDev https://redirect.github.com/SocketDev
socket-python-clihttps://redirect.github.com/SocketDev/socket-python-cli
Notifications https://redirect.github.com/login?return_to=%2FSocketDev%2Fsocket-python-cli
Fork 11 https://redirect.github.com/login?return_to=%2FSocketDev%2Fsocket-python-cli
Star 9 https://redirect.github.com/login?return_to=%2FSocketDev%2Fsocket-python-cli
Code https://redirect.github.com/SocketDev/socket-python-cli
Pull requests 5 https://redirect.github.com/SocketDev/socket-python-cli/pulls
Actions https://redirect.github.com/SocketDev/socket-python-cli/actions
Models https://redirect.github.com/SocketDev/socket-python-cli/models
Security and quality 0 https://redirect.github.com/SocketDev/socket-python-cli/security
Insights https://redirect.github.com/SocketDev/socket-python-cli/pulse
Code https://redirect.github.com/SocketDev/socket-python-cli
Pull requests https://redirect.github.com/SocketDev/socket-python-cli/pulls
Actions https://redirect.github.com/SocketDev/socket-python-cli/actions
Models https://redirect.github.com/SocketDev/socket-python-cli/models
Security and quality https://redirect.github.com/SocketDev/socket-python-cli/security
Insights https://redirect.github.com/SocketDev/socket-python-cli/pulse
Sign up for GitHub https://redirect.github.com/signup?return_to=%2FSocketDev%2Fsocket-python-cli%2Fissues%2Fnew%2Fchoose
terms of servicehttps://docs.github.com/terms
privacy statementhttps://docs.github.com/privacy
Sign inhttps://redirect.github.com/login?return_to=%2FSocketDev%2Fsocket-python-cli%2Fissues%2Fnew%2Fchoose
Orlando Barrera II (obarrera)https://redirect.github.com/obarrera
mainhttps://redirect.github.com/SocketDev/socket-python-cli/tree/main
orlando/ce-89-add-comment-ability-for-bitbucket-for-python-clihttps://redirect.github.com/SocketDev/socket-python-cli/tree/orlando/ce-89-add-comment-ability-for-bitbucket-for-python-cli
Conversation 1 https://redirect.github.com/SocketDev/socket-python-cli/pull/206
Commits 4 https://redirect.github.com/SocketDev/socket-python-cli/pull/206/commits
Checks 15 https://redirect.github.com/SocketDev/socket-python-cli/pull/206/checks
Files changed https://redirect.github.com/SocketDev/socket-python-cli/pull/206/files
Please reload this pagehttps://redirect.github.com/SocketDev/socket-python-cli/pull/206/files
Add Bitbucket PR comment support https://redirect.github.com/SocketDev/socket-python-cli/pull/206/files#top
Show all changes 4 commits https://redirect.github.com/SocketDev/socket-python-cli/pull/206/files
37de6a0 Add Bitbucket PR comment support (CE-89) obarrera May 28, 2026 https://redirect.github.com/SocketDev/socket-python-cli/pull/206/commits/37de6a0bae10e70bb17a00bca915cbce32006632
46f6de5 Apply Bitbucket SCM review feedback lelia May 28, 2026 https://redirect.github.com/SocketDev/socket-python-cli/pull/206/commits/46f6de50c4f6127bf4b3d9500e37ab472fa5d85c
6f520e6 Bump version to 2.2.91 obarrera May 28, 2026 https://redirect.github.com/SocketDev/socket-python-cli/pull/206/commits/6f520e6429b312e8bb5b2196ee03159a92addb96
96433ee Apply code-review improvements + bump to 2.2.92 obarrera May 28, 2026 https://redirect.github.com/SocketDev/socket-python-cli/pull/206/commits/96433eee2e030e21d14f662f46b90aaf3ca5537e
Clear filters https://redirect.github.com/SocketDev/socket-python-cli/pull/206/files
Please reload this pagehttps://redirect.github.com/SocketDev/socket-python-cli/pull/206/files
Please reload this pagehttps://redirect.github.com/SocketDev/socket-python-cli/pull/206/files
pyproject.toml https://redirect.github.com/SocketDev/socket-python-cli/pull/206/files#diff-50c86b7ed8ac2cf95bd48334961bf0530cdc77b5a56f852c5c61b89d735fd711
__init__.py https://redirect.github.com/SocketDev/socket-python-cli/pull/206/files#diff-9ae7a3b3f6a847c0c7bbe145ba187b0f9a0cfd2e1316ab84d135c13830934814
bitbucket.py https://redirect.github.com/SocketDev/socket-python-cli/pull/206/files#diff-a2bbc1ea5e7a8195969269cf15cb3740703da801d78a5eb68bbe3d218d05b920
socketcli.py https://redirect.github.com/SocketDev/socket-python-cli/pull/206/files#diff-42c07200ab90333cb355430e90c085abda17d6bb5705e57e1a141a6f404b2acc
test_bitbucket.py https://redirect.github.com/SocketDev/socket-python-cli/pull/206/files#diff-0c97a2569bd58f7e1d0905acf8b2374a7925a8dbe1f18c8f2ff596c9f5a4858c
uv.lock https://redirect.github.com/SocketDev/socket-python-cli/pull/206/files#diff-84321598744d84dbee2318e634c74c9aae39a1c253f1c4bd17ebf9ef2f807b11
bitbucket-pipelines.yml https://redirect.github.com/SocketDev/socket-python-cli/pull/206/files#diff-ffd81cfb36995e7db61affcdd4b9feab8b71a34c2022618887319d65ffe7d2e1
https://redirect.github.com/SocketDev/socket-python-cli/blob/main/.github/CODEOWNERS#L1
pyproject.tomlhttps://redirect.github.com/SocketDev/socket-python-cli/pull/206/files#diff-50c86b7ed8ac2cf95bd48334961bf0530cdc77b5a56f852c5c61b89d735fd711
View file https://redirect.github.com/SocketDev/socket-python-cli/blob/96433eee2e030e21d14f662f46b90aaf3ca5537e/pyproject.toml
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://redirect.github.com/SocketDev/socket-python-cli/pull/206/{{ revealButtonHref }}
https://redirect.github.com/SocketDev/socket-python-cli/pull/206/files#diff-50c86b7ed8ac2cf95bd48334961bf0530cdc77b5a56f852c5c61b89d735fd711
https://redirect.github.com/SocketDev/socket-python-cli/pull/206/files#diff-50c86b7ed8ac2cf95bd48334961bf0530cdc77b5a56f852c5c61b89d735fd711
https://redirect.github.com/SocketDev/socket-python-cli/blob/main/.github/CODEOWNERS#L1
socketsecurity/__init__.pyhttps://redirect.github.com/SocketDev/socket-python-cli/pull/206/files#diff-9ae7a3b3f6a847c0c7bbe145ba187b0f9a0cfd2e1316ab84d135c13830934814
View file https://redirect.github.com/SocketDev/socket-python-cli/blob/96433eee2e030e21d14f662f46b90aaf3ca5537e/socketsecurity/__init__.py
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://redirect.github.com/SocketDev/socket-python-cli/pull/206/{{ revealButtonHref }}
https://redirect.github.com/SocketDev/socket-python-cli/blob/main/.github/CODEOWNERS#L1
socketsecurity/core/scm/bitbucket.pyhttps://redirect.github.com/SocketDev/socket-python-cli/pull/206/files#diff-a2bbc1ea5e7a8195969269cf15cb3740703da801d78a5eb68bbe3d218d05b920
View file https://redirect.github.com/SocketDev/socket-python-cli/blob/96433eee2e030e21d14f662f46b90aaf3ca5537e/socketsecurity/core/scm/bitbucket.py
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://redirect.github.com/SocketDev/socket-python-cli/pull/206/{{ revealButtonHref }}
https://redirect.github.com/SocketDev/socket-python-cli/blob/main/.github/CODEOWNERS#L1
socketsecurity/socketcli.pyhttps://redirect.github.com/SocketDev/socket-python-cli/pull/206/files#diff-42c07200ab90333cb355430e90c085abda17d6bb5705e57e1a141a6f404b2acc
View file https://redirect.github.com/SocketDev/socket-python-cli/blob/96433eee2e030e21d14f662f46b90aaf3ca5537e/socketsecurity/socketcli.py
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://redirect.github.com/SocketDev/socket-python-cli/pull/206/{{ revealButtonHref }}
https://redirect.github.com/SocketDev/socket-python-cli/pull/206/files#diff-42c07200ab90333cb355430e90c085abda17d6bb5705e57e1a141a6f404b2acc
https://redirect.github.com/SocketDev/socket-python-cli/pull/206/files#diff-42c07200ab90333cb355430e90c085abda17d6bb5705e57e1a141a6f404b2acc
Please reload this pagehttps://redirect.github.com/SocketDev/socket-python-cli/pull/206/files
Please reload this pagehttps://redirect.github.com/SocketDev/socket-python-cli/pull/206/files
https://github.com
Termshttps://docs.github.com/site-policy/github-terms/github-terms-of-service
Privacyhttps://docs.github.com/site-policy/privacy-policies/github-privacy-statement
Securityhttps://github.com/security
Statushttps://www.githubstatus.com/
Communityhttps://github.community/
Docshttps://docs.github.com/
Contacthttps://support.github.com?tags=dotcom-footer

Viewport: width=device-width


URLs of crawlers that visited me.