Repository navigation
feat(forms)!: forms answers list is a listing like every other, and columns-list gives its columns - #574
Merged
Conversation
… `columns-list` gives its columns
The answers of a form are listed with the three handles of every listing: `--limit`, `--all` and `--next` in the CLI, `limit` / `all` / `next` in the tool, a lazy `Listing[Answer]` in the SDK. The columns the cells of an answer stand in are read by a command of their own, `forms answers columns-list` (`forms_answers_columns_list`, `forms.answers.columns_list`): the API has no request for them alone, so it reads one answer to learn them.
BREAKING CHANGE: `forms answers list -o json` prints `{items, truncated, next, total}` instead of `{columns, answers, next}`: a script reads `.items[]` where it read `.answers[]`, and takes the columns from `forms answers columns-list`. `forms.answers.list()` returns `Listing[Answer]` instead of `AnswersResponse`, and the tool `forms_answers_list` returns the listing object.
Decision 3-Б of #538.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This was referenced Oct 10, 2026
This branch was previously deployed
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.
Decision 3-Б of #538: the last listing that could not go on from a token.
What changes
forms answers list SURVEY_ID(keeps its name)forms answers columns-list SURVEY_ID(new)--limit,--all,--nextlike every listing-o json{items: [{id, created, uid, data}], truncated, next, total}[{id, slug, type, text, has_scores}, …]--next--questions,--use-slugs: the two that change the columnsforms_answers_listforms_answers_columns_listforms.answers.list(...)→Listing[Answer]forms.answers.columns_list(...)→ItemList[Column]-o nameThe name is
columns-list, notcolumnsas the example in #538 wrote it: the repository names an operation of a sub-thing this way (integrations-listbeside it,fields-list,tags-list).Breaking
forms answers list -o jsonprinted{columns, answers, next}; it prints the listing object. A script reads.items[]where it read.answers[], and takes the columns fromforms answers columns-list.forms.answers.list()returnedAnswersResponse; it returnsListing[Answer].forms_answers_listreturns the listing object and takesallandnext.The cells and the columns
The cells of an answer (
data) are positional. After the split the answers alone do not say what a cell is, so the help oflist(command, tool and method) says that the positions are those ofcolumns-listasked with the same--questionsand--use-slugs, and names--answer-format raw, which keys the data by question and needs no columns. There is no joining code. A test holds the claim: asked the same way, an answer has as many cells ascolumns-listgives columns.columns-listsends the sameGET /surveys/{id}/answerswithpage_size=1: the API has no request for the columns alone, so one answer is read to learn them and left out; its help says so. Against the mock, a form with no answers at all returns its columns all the same (a contract case). Couldn't verify live: the test organization has no form.The listing exception is gone
forms.answers.listis removed fromARCH1_LISTINGS_WITHOUT_NEXTintests/architecture/test_arch1.py; one entry is left there (wiki.comments.thread_list). No other file named the exception.One published operation, two ycli operations
Measured, not only read:
tests/tooling/test_api_drift.pypasses with no new entry inEXPLAINEDorNOT_WRAPPED, and the README numbers for Forms stay "84 of 84 published operations wrapped, 8 differ".compare()inscripts/api_drift.pycollects the calls of a published operation into a list and compares their union, so two operations sending the same published GET is what it is written for.Also here
Answer.idandColumn.idget theIdentity()mark, so both listings print names. I had told the architectAnswer.idwas already marked; it was not, andtests/architecture/test_names.pyfailed on it until it was.Column.idis taken to be the question id--questionsaccepts: not verified live.e2e/scenarios/forms/survey_options.yamlexpects the listing object and has a step forcolumns-list. It collects in an environment without extras (30 scenarios); it was not run.Checked
uv run pytest: 7020 passed, 5 skipped, coverage 100% (lines and branches);lint-imports,ty,ruffclean; pre-commit hooks passed. That run was on this tree; only the squash followed it.next(the ARCH-1 check of listings failed);columns-listnot passing--questions/--use-slugs(the positions test failed).Not run
🤖 Generated with Claude Code