Repository navigation
Sync the archive with Substack again and follow its new cursor paging - #39
Merged
Merged
Conversation
Substack's archive endpoint began answering HTTP 400 to offset and to a limit
above 25, and returns {posts, nextCursor} instead of a list, so the sync had
failed since early September. list_posts now pages by cursor (limit=25). The
archive gains 36 posts and three titles and subtitles change as Substack has
them; companions are rebuilt and match the archive. Tests cover the cursor
paging and fail if offset is ever sent again.
pytest: 34 passed. build_companions.py --check: PASS.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_011RjaPcC924ePsEE8X6uH72
…ests Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_011RjaPcC924ePsEE8X6uH72
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
What does this PR do?
Substack's archive endpoint began answering HTTP 400 to
offsetand to alimitabove 25, and returns{posts, nextCursor}instead of a list, soscripts/sync_substack.pycould no longer list posts. The archive was six weeks behind (it stopped at 7 September).list_postspages by cursor withlimit=25, and still accepts a bare list in case Substack reverts.offsetis ever sent again. CLAUDE.md records what is known about the failure.Type of change
Checklist
pytest: 34 passed;build_companions.py --check: PASS)Note: the monthly sync workflow opens its own PR, so this should merge first.
Generated by Claude Code