Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,12 @@
# Changelog

## 2.10.11

### Changed: use lowercase hyphenated Python CLI User-Agent

- Use `socket-python-cli/` consistently for CLI and SDK requests so API
attribution matches the Socket client naming convention.

## 2.10.10

### Changed: bump pinned @coana-tech/cli to 15.12.3
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ build-backend = "hatchling.build"

[project]
name = "socketsecurity"
version = "2.10.10"
version = "2.10.11"
requires-python = ">= 3.11"
license = {"file" = "LICENSE"}
dependencies = [
Expand Down
7 changes: 5 additions & 2 deletions socketsecurity/__init__.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
__author__ = 'socket.dev'
__version__ = '2.10.10'
USER_AGENT = f'SocketPythonCLI/{__version__}'
__version__ = '2.10.11'
# The name Socket's API attributes this client by. Callers that build their
# own User-Agent read it from here, so a rename lands in one place.
USER_AGENT_NAME = 'socket-python-cli'
USER_AGENT = f'{USER_AGENT_NAME}/{__version__}'
3 changes: 2 additions & 1 deletion socketsecurity/socketcli.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
from socketdev import socketdev
from socketdev.fullscans import FullScanParams

from socketsecurity import USER_AGENT_NAME
from socketsecurity.config import CliConfig, truncate_commit_message
from socketsecurity.core import Core
from socketsecurity.core.classes import Diff
Expand Down Expand Up @@ -240,7 +241,7 @@ def apply_git_context(config: CliConfig) -> Tuple[bool, Optional[Git]]:


def build_socket_sdk(config: CliConfig) -> socketdev:
cli_user_agent_string = f"SocketPythonCLI/{config.version}"
cli_user_agent_string = f"{USER_AGENT_NAME}/{config.version}"
return socketdev(
token=config.api_token,
timeout=get_api_request_timeout(config),
Expand Down
2 changes: 1 addition & 1 deletion uv.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading