Skip to content

CLI: edit -a ID --comment replaces the comment of a version (#56) - #125

Merged
DraTeots merged 2 commits into
v2-mainfrom
fix-56-edit-comment
Nov 4, 2026
Merged

DraTeots merged 2 commits into
v2-mainfrom
fix-56-edit-comment

Conversation

@DraTeots

@DraTeots DraTeots commented Nov 3, 2026

Copy link
Copy Markdown
Contributor

Adds the command #56 asked for:

ccdb edit -a 4213 --comment "Undo the BCAL cable swap for future runs"
ccdb edit -a /test/test_vars/test_table:100 --comment ""     # clears it
  • AlchemyProvider.set_assignment_comment(assignment, comment): data, run range, variation and creation time stay; anonymous is refused; the log record "Changed the comment of assignment ''" keeps the previous comment.
  • edit gets -a/--assignment (id or request string) and --comment; its value-editing stub is left as it was.
  • Tests test_edit_comment, test_edit_comment_needs_assignment; docs/cli.md.

Also the tool for the 530 607 Hall D versions without a comment.

Closes #56

🤖 Generated with Claude Code

DraTeots and others added 2 commits November 3, 2026 12:55
AlchemyProvider.set_assignment_comment(assignment, comment) replaces an assignment's comment; data, run range,
variation and creation time stay. It refuses the anonymous user and writes a log record "Changed the comment of
assignment '<request>'" whose comment keeps the previous text, so nothing is lost. `ccdb edit -a <id or request>
--comment "text"` calls it; an empty text clears the comment. The edit command's value-editing stub is unchanged.

Closes #56

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
# Conflicts:
#	python/tests/integ_test_cli_manager.py
DraTeots added a commit that referenced this pull request Nov 4, 2026
ccdb.ucum.is_ucum checks a unit string against UCUM's grammar (products,
quotients, exponents, prefixes on metric atoms, parentheses, 10*N, {annota-
tions}) with a table of the atoms calibration tables use; no dependency, no
network. mktbl warns on units UCUM can't read (Mev, nsec, GeV/c) and stores
them as written. AlchemyProvider.set_column_units sets or clears the units
of a column of an existing table, with a log record: `edit` has no option for
it while #125 rewrites that command. The readiness profile fills
units.columns_with_ucum_units. unit_test_ucum.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@DraTeots
DraTeots merged commit 74327fd into v2-main Nov 4, 2026
50 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Retroactively adding comments

1 participant