Add feature flags for Pinecone, Cloudinary, and GitLab OAuth detectors#4961
Add feature flags for Pinecone, Cloudinary, and GitLab OAuth detectors#4961camgunz wants to merge 10 commits into
Conversation
| PineconeDetector atomic.Bool | ||
| CloudinaryDetector atomic.Bool | ||
| GitLabOAuthDetector atomic.Bool |
There was a problem hiding this comment.
Just wondering if it would be better to add Enabled suffix since this is a bool
amanfcp
left a comment
There was a problem hiding this comment.
Just trying to understand the motivation: what prompted flagging these three specifically?
Another thing from OSS perspective is that since atomic.Bool defaults to false and main.go does not .Store(true) these (the way it does for EnableAPKHandler, UseGitMirror, etc.), OSS users on main will silently lose these three detectors with no CLI way to turn them back on. Might be worth a release-note callout, or wiring a flag.
|
…remove them when their flag is disabled
amanfcp
left a comment
There was a problem hiding this comment.
LGTM. We just need to find a way to exclude them from the test that is failing
mustansir14
left a comment
There was a problem hiding this comment.
LGTM. For the failing test, you will need to add these detectors to excludedFromDefaultList in the test, ideally in a separate section with a comment explaining why it was added.
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, have a team admin enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit e59c77d. Configure here.
|
Yeah I wanted to try and minimize the number of changes needed to feature flag a detector, but I think this is what we have to do for now. |

Description:
Puts the Pinecone, Cloudinary, and GitLab OAuth detectors behind feature flags.
Checklist:
make test-community)?make lintthis requires golangci-lint)?