Current beta character-order code has two correctness concerns surfaced by the automated review of #729:
CharacterOrderRevision._post_save_object() reads order_code from StoryCharacterRevision, although the value belongs to CharacterThroughOrderRevision, and then saves the character rather than the through row. This can raise AttributeError and fail to persist ordering changes.StoryCharacterRevisionForm assumes a saved instance before evaluating related managers. The outer if instance does not distinguish saved from unsaved model instances, and group_name.exists() is reached before the bot-proposed instance.pk guard. Confirm whether normal inline-formset construction exercises this path before choosing the complete fix.These paths already exist on beta; #729 only exposed them because it synchronizes beta into api-v2.
Review context:
StoryCharacterRevision instances, then guard all related-manager access that is reachable for unsaved instances.—
Reply to this email directly, view it on GitHub, or unsubscribe.
Triage notifications, keep track of coding agent tasks and review pull requests on the go with GitHub Mobile for iOS and Android. Download it today!
You are receiving this because you are subscribed to this thread.![]()
there are no unsaved instances here
—
Reply to this email directly, view it on GitHub, or unsubscribe.
Triage notifications, keep track of coding agent tasks and review pull requests on the go with GitHub Mobile for iOS and Android. Download it today!
You are receiving this because you are subscribed to this thread.![]()
—
Reply to this email directly, view it on GitHub, or unsubscribe.
Triage notifications, keep track of coding agent tasks and review pull requests on the go with GitHub Mobile for iOS and Android. Download it today!
You are receiving this because you are subscribed to this thread.![]()