Skip to content

Fix subscriber count response handling#67

Merged
ma2za merged 1 commit into
mainfrom
agent/fix-subscriber-count
Jul 18, 2026
Merged

Fix subscriber count response handling#67
ma2za merged 1 commit into
mainfrom
agent/fix-subscriber-count

Conversation

@ma2za

@ma2za ma2za commented Jul 18, 2026

Copy link
Copy Markdown
Owner

Summary

  • support Substack's current subscribers list response
  • preserve compatibility with the legacy subscriberCount response
  • add regression tests for both response shapes

Root cause

The publication launch checklist endpoint no longer returns a top-level subscriberCount for this account. It now returns subscriber records in a subscribers list, causing substack status to raise KeyError.

Impact

substack status reports the subscriber count with both the current and legacy API response formats.

Validation

  • python -m pytest tests/substack/test_api.py tests/substack/test_cli_operations.py -q: 23 passed, 5 skipped
  • live substack status: completed successfully
  • commit hooks: Check Yaml, Fix End of Files, Trim Trailing Whitespace, black, and isort passed

The full suite remains blocked by the unrelated missing mdit_py_plugins.subscript module in the local environment.

@ma2za
ma2za merged commit 0807226 into main Jul 18, 2026
6 checks passed
@ma2za
ma2za deleted the agent/fix-subscriber-count branch July 18, 2026 08:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant