GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — fix(user-agent): identify Basics API requests by lelia · Pull Request #133 · SocketDev/socket-basics

Conversation

@lelia

@lelia lelia commented Nov 3, 2026 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Contributor

⚠️ DO NOT MERGE until backend changes are confirmed deployed ⚠️

Summary

Basics currently inherits SocketSDKPython/<SDK version> for Socket API requests, so request attribution cannot distinguish it from standalone SDK consumers. Send socket-basics/<Basics version> from both dashboard configuration reads and scan uploads, using one shared constant.

Blocked on backend deployment. Keep this PR in draft and do not merge or release it until depscan recognizes socket-basics/ as basics. Backend dependency PR has been raised. Client releases must follow deployment, not merely backend PR merge.

Changes

  • Override the SDK User-Agent on both Basics API clients without requiring an SDK upgrade.
  • Derive the identity from the existing Basics version module and record the change under Unreleased.
  • Keep this work separate from fix(scanner): preserve option values #125, which fixes Tier 1 argument parsing.

Testing

  • 487 Python tests passed using the installed SDK 3.5.0; isolated test Git configuration disables local signing and hooks for temporary fixture repos.
  • The Java/OpenGrep module was excluded because the installed OpenGrep scanner fails to start locally. The initial broader run exposed that environment issue; CI retains its normal scanner coverage.
  • Both new request tests also passed against the proposed SDK changes in fix(user-agent): identify the Python SDK consistently socket-sdk-python#127.
  • New tests exercise the real SDK and inspect prepared HTTP headers for organization discovery, Basics settings, and multipart scan upload. Only the HTTP transport boundary is replaced.
  • Black and Flake8 passed for the new module and tests; git diff --check passed. Added code contains no comments requiring revision in the fourth-wall audit.

Rollout and reviewer context

Prior art: SocketDev/socket-python-cli#320 by jdalton. Basics follows the same application override pattern and uses its own version rather than the SDK version. Select the unpublished patch version during release preparation after backend deployment; this draft leaves release metadata unchanged.


Note

Low Risk
Only HTTP client metadata changes; scan logic, auth, and payloads are unchanged, though attribution depends on a coordinated backend deploy.

Overview
Socket Basics no longer leaves Socket API traffic labeled as the generic Python SDK. Dashboard configuration loads (org discovery and Basics settings) and full-scan uploads now pass a shared user_agent when constructing socketdev, so outbound requests use socket-basics/<Basics version> instead of SocketSDKPython/<SDK version>.

A small user_agent module centralizes that string from the existing package version, and the Unreleased changelog records the behavior change. New tests stub HTTP at the transport layer and assert the User-Agent header on both the config path and the multipart scan POST.

Release is blocked on backend recognizing the socket-basics/ prefix as Basics traffic (per PR description).

Reviewed by Cursor Bugbot for commit 9179f8f. Configure here.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@lelia
fix(user-agent): identify Basics API requests
9179f8f
Assisted-by: Codex:GPT-6
@lelia

lelia commented Nov 4, 2026

Copy link
Copy Markdown
Contributor Author

bugbot run

cursor[bot] reacted with thumbs up emoji
All reactions
  • 👍 1 reaction

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

cursor[bot]
cursor Bot reviewed Nov 4, 2026
View reviewed changes

@cursor cursor Bot left a comment

Copy link
Copy Markdown

There was a problem hiding this comment.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ Bugbot reviewed your changes and found no new issues!

Comment @cursor review or bugbot run to trigger another review on this PR

Reviewed by Cursor Bugbot for commit 9179f8f. Configure here.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

@cursor cursor[bot] cursor[bot] left review comments

At least 1 approving review is required to merge this pull request.

Uh oh!

There was an error while loading. Please reload this page.

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

Uh oh!

There was an error while loading. Please reload this page.

1 participant

@lelia
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.