fix(deploy): CI topic seeding — correct S3 bucket + missing seed non-fatal - #329
Merged
Conversation
- Set PROMPTS_BUCKET to purposepath-coaching-prompts-380276784420- plus stack name (STAGE) in deploy workflows; matches infrastructure/pulumi S3 bucket - Treat registry topics without TopicSeedData as missing_seed_topics, not errors, so seed exits 0 when S3/Dynamo succeed - Fix unit tests to patch list_all_topics; add coverage for missing-seed path Made-with: Cursor
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.
Problem
Deploy Dev failed on the post-merge Seed topic registry step:
NoSuchBucketforpurposepath-coaching-prompts-dev. The seed script usedSettingsdefaults while infrastructure/pulumi createspurposepath-coaching-prompts-380276784420-<stack>(seeinfrastructure/pulumi/__main__.py).After fixing the bucket, seeding would still exit 1 because many registry topics have no
TopicSeedDatarow; those were counted aserrors.Changes
Workflows (
deploy-dev,deploy-staging,deploy-production): exportPROMPTS_BUCKET=purposepath-coaching-prompts-380276784420-${STAGE}before runningseed_topics.TopicSeedingService: topics with no seed data go to
SeedingResult.missing_seed_topics(warning path), noterrors, sois_successfulstays true when Dynamo/S3 operations succeed.seed_topics CLI: print a Registry topics without seed data section and summary line
Missing seed:.Tests: patch
list_all_topics(what the service actually calls); add test for missing-seed behavior; assertmissing_seed_topicsdoes not failis_successful.Validation
pytest coaching/tests/unit/services/test_topic_seeding_service.py -v; ruff + mypy on touched modules.