Prevent copying assignments#2918
Open
cqnykamp wants to merge 1 commit into
Open
Conversation
- Backend: throw InvalidRequestError when attempting to copy an assignment root - Frontend: disable "Make a copy" action bar button when any selected item is an assignment - Tests: add two tests covering attempt to copy singleDoc and sequence assignment roots https://claude.ai/code/session_019HTqQkPWkZ35RM1x1HRQ2W
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.
$(cat <<'EOF'
Summary
Closes #2614
copyContentnow throwsInvalidRequestError("Cannot copy an assignment")when any of the requested content IDs is an assignment root (isAssignmentRoot = true). Previously, copying an assignment was silently allowed, producing a regular activity without assignment data.Activitiespage action bar is now disabled whenever any selected item is an assignment (hasassignmentInfoset).copy_move.test.tsverify that copying a sequence-based assignment and a singleDoc assignment both throw the expected error.Test plan
cannot copy an assignmentpasses in CIcannot copy an assignment (singleDoc)passes in CIhttps://claude.ai/code/session_019HTqQkPWkZ35RM1x1HRQ2W
EOF
)
Generated by Claude Code