Add issue create dependency contract#215
Merged
Merged
Conversation
Allow POST /api/v1/issues to accept dependency_ids by extending CreateIssueInput and running issue creation plus dependency replacement in one store transaction. Update OpenAPI, generated frontend API types, mock state, and design docs to reflect the create contract. Verify create-time dependency success, empty dependencies, self-reference, missing dependencies, duplicates, rollback on failure, and response dependency_ids coverage.
This was referenced Jul 12, 2026
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.
Add issue create dependency contract
Summary
POST /api/v1/issuesnow acceptsdependency_idsand persists the new issue plus its initial dependency set in one store transaction.主な変更点:
CreateIssueInputにdependency_idsを追加し、create/update で dependency ID の基本検証を共有Store.CreateIssueを transaction 化し、issue insert 後に既存のsetDependencyIDsTxを再利用チケットへのリンク
Issue #41
やったこと
dependency_idsが含まれることを API test で確認npm run generate:apiで再生成動作確認
go test ./internal/issue/...npm run generate:apifromcmd/web/frontendnpm run typecheckfromcmd/web/frontendnpm run buildfromcmd/web/frontendgo test ./...レビュー & 動作確認 チェックリスト
POST /api/v1/issuesのdependency_idsが OpenAPI と生成型に反映されていること推奨テスト計画:
go test ./internal/issue/...npm run typecheckfromcmd/web/frontendgo test ./...その他気になることや相談ごと
作成時に既存 issue との cycle を作るには新規 issue ID を事前参照できる必要があるため、実際に作成時に発生し得る cycle は自己参照として検証しています。既存 issue 間の cycle は既存の update dependency test で継続確認しています。