monday-cli 0.6.0 → 0.7.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +388 -0
- package/README.md +165 -52
- package/dist/api/column-types.d.ts +61 -28
- package/dist/api/column-types.d.ts.map +1 -1
- package/dist/api/column-types.js +32 -13
- package/dist/api/column-types.js.map +1 -1
- package/dist/api/column-values.d.ts +22 -17
- package/dist/api/column-values.d.ts.map +1 -1
- package/dist/api/column-values.js +50 -34
- package/dist/api/column-values.js.map +1 -1
- package/dist/api/file-column-set.d.ts +164 -58
- package/dist/api/file-column-set.d.ts.map +1 -1
- package/dist/api/file-column-set.js +168 -110
- package/dist/api/file-column-set.js.map +1 -1
- package/dist/api/raw-write.d.ts +29 -18
- package/dist/api/raw-write.d.ts.map +1 -1
- package/dist/api/raw-write.js +48 -26
- package/dist/api/raw-write.js.map +1 -1
- package/dist/commands/board/column-create.d.ts +11 -6
- package/dist/commands/board/column-create.d.ts.map +1 -1
- package/dist/commands/board/column-create.js +23 -12
- package/dist/commands/board/column-create.js.map +1 -1
- package/dist/commands/item/create.d.ts +24 -8
- package/dist/commands/item/create.d.ts.map +1 -1
- package/dist/commands/item/create.js +494 -35
- package/dist/commands/item/create.js.map +1 -1
- package/dist/commands/item/update.d.ts +175 -6
- package/dist/commands/item/update.d.ts.map +1 -1
- package/dist/commands/item/update.js +697 -29
- package/dist/commands/item/update.js.map +1 -1
- package/package.json +1 -1
|
@@ -82,30 +82,57 @@
|
|
|
82
82
|
* after metadata loads). When any resolved column has `type ===
|
|
83
83
|
* 'file'`:
|
|
84
84
|
*
|
|
85
|
-
* - Exactly ONE file `--set` entry allowed per call (
|
|
86
|
-
* file scope; multi-file dispatch defers to v0.
|
|
85
|
+
* - Exactly ONE file `--set` entry allowed per call (single-
|
|
86
|
+
* file scope; multi-file dispatch defers to v0.7.x — Monday's
|
|
87
|
+
* `add_file_to_column` is single-column per call on the wire
|
|
88
|
+
* regardless of how many items the dispatch fans out across,
|
|
89
|
+
* so this rule is universal).
|
|
87
90
|
* - NO other value `--set` / `--set-raw` / `--name` flags
|
|
88
|
-
* allowed (mixing would force non-atomic multi-leg dispatch
|
|
89
|
-
*
|
|
90
|
-
*
|
|
91
|
-
* v0.
|
|
92
|
-
*
|
|
93
|
-
*
|
|
94
|
-
*
|
|
95
|
-
*
|
|
96
|
-
*
|
|
91
|
+
* allowed (mixing would force non-atomic multi-leg dispatch
|
|
92
|
+
* across the multipart + JSON wire surfaces).
|
|
93
|
+
* - Bulk `item update --where ... --set <file-col>=<path>` —
|
|
94
|
+
* **CARVED OUT at v0.7-M42** (D5 fold). At v0.6-M38 this was
|
|
95
|
+
* REJECTED with `'file_set_on_bulk_unsupported'`; v0.7-M42's
|
|
96
|
+
* pre-flight contract diff returns
|
|
97
|
+
* `{ kind: 'file_bulk', columnId, rawValue }` from
|
|
98
|
+
* {@link enforceSingleFileColumnSet} on the clean dispatch
|
|
99
|
+
* path so the action body can branch into the per-item
|
|
100
|
+
* multipart fan-out. Multi-file / mixed mutex rules STILL
|
|
101
|
+
* apply on bulk (those are universal).
|
|
102
|
+
* - `item create --set <file-col>=<path>` — **CARVED OUT at
|
|
103
|
+
* v0.7-M43** (D6 fold). At v0.6-M38 this was REJECTED with
|
|
104
|
+
* `'file_set_on_create_unsupported'`; v0.7-M43's pre-flight
|
|
105
|
+
* contract diff returns
|
|
106
|
+
* `{ kind: 'file_create', columnId, rawValue }` from
|
|
107
|
+
* {@link enforceSingleFileColumnSet} on the clean dispatch
|
|
108
|
+
* path so the action body can branch into the two-leg
|
|
109
|
+
* dispatch (`create_item` then `add_file_to_column`).
|
|
110
|
+
* Multi-file mutex rule STILL applies on create (universal).
|
|
111
|
+
* The mixed rule is callShape-aware: on `'item_create'` the
|
|
112
|
+
* `--name` arm + non-file value `--set` / `--set-raw` arms
|
|
113
|
+
* are SUPPRESSED (leg-1 `create_item` natively bundles
|
|
114
|
+
* `column_values` atomically + `item_name` is required on
|
|
115
|
+
* create); the D3 `--set-raw <file-col>=<json>` rejection
|
|
116
|
+
* at `raw-write.ts:translateRawColumnValue` stays in force
|
|
117
|
+
* (separate enforcement layer).
|
|
97
118
|
*
|
|
98
119
|
* Rejection surfaces share the `usage_error.details.reason`
|
|
99
120
|
* discriminator pattern from M14 / M27 / M31:
|
|
100
121
|
*
|
|
101
122
|
* - `'mixed_file_and_value_sets'` — file `--set` + any value
|
|
102
|
-
* `--set` / `--set-raw` / `--name` in same call.
|
|
123
|
+
* `--set` / `--set-raw` / `--name` in same call. Applies on
|
|
124
|
+
* single-item AND bulk call shapes (universal mutex rule).
|
|
103
125
|
* - `'multi_file_set_unsupported'` — 2+ file `--set` entries
|
|
104
|
-
* in same call.
|
|
105
|
-
*
|
|
106
|
-
*
|
|
107
|
-
*
|
|
108
|
-
*
|
|
126
|
+
* in same call. Applies on single-item AND bulk call shapes
|
|
127
|
+
* (universal mutex rule).
|
|
128
|
+
* - `'file_set_on_bulk_unsupported'` — **NO LONGER SURFACES**
|
|
129
|
+
* at v0.7-M42 onwards. Historical reference only; the
|
|
130
|
+
* discriminator literal stays reserved across the codebase
|
|
131
|
+
* (do not reuse for a different rejection reason).
|
|
132
|
+
* - `'file_set_on_create_unsupported'` — **NO LONGER SURFACES**
|
|
133
|
+
* at v0.7-M43 onwards. Historical reference only; the
|
|
134
|
+
* discriminator literal stays reserved across the codebase
|
|
135
|
+
* (do not reuse for a different rejection reason).
|
|
109
136
|
*
|
|
110
137
|
* **D3 closure — `--set-raw <file-col>=<json>` STAYS REJECTED.**
|
|
111
138
|
* Files have no JSON wire shape Monday's `change_column_value`
|
|
@@ -113,16 +140,19 @@
|
|
|
113
140
|
* `change_column_value` accepts" doesn't compose with the
|
|
114
141
|
* multipart wire. The existing rejection at
|
|
115
142
|
* `raw-write.ts:translateRawColumnValue` stays unchanged; the
|
|
116
|
-
* prose
|
|
117
|
-
*
|
|
118
|
-
*
|
|
143
|
+
* prose enumerates every shipped friendly write path (v0.6-M38
|
|
144
|
+
* single-item, v0.7-M42 bulk, v0.7-M43 create-time, v0.4-M31
|
|
145
|
+
* verb-shaped upload) so agents reading the `--set-raw`
|
|
146
|
+
* rejection see the full set of working alternatives rather
|
|
147
|
+
* than just the M38 single-item form.
|
|
119
148
|
*
|
|
120
149
|
* **D7 closure — `<path>='-'` stdin support OUT OF SCOPE.**
|
|
121
150
|
* Mirrors M31 `monday item upload`'s rejection rationale — no
|
|
122
151
|
* clean `--filename` companion shape pinned for `--set
|
|
123
152
|
* <file-col>=-` syntax (stdin reads byte-anonymously; the
|
|
124
153
|
* filename is the load-bearing handle for Monday's wire
|
|
125
|
-
* `Asset.name` slot).
|
|
154
|
+
* `Asset.name` slot). Carry-forward candidate for v0.7.x once a
|
|
155
|
+
* `--filename` companion shape is pinned.
|
|
126
156
|
*
|
|
127
157
|
* **No new ERROR_CODE (D8 closure; registry stays at 29).** All
|
|
128
158
|
* M38-specific rejections route through existing `usage_error`
|
|
@@ -231,26 +261,40 @@ export const executeFileColumnSet = async (inputs) => {
|
|
|
231
261
|
* `{ kind: 'file', columnId, rawValue }` (clean dispatch path), or
|
|
232
262
|
* throws `ApiError('usage_error', ...)` on a mutex violation.
|
|
233
263
|
*
|
|
234
|
-
* Mutex priority (ratified at M38 pre-flight
|
|
264
|
+
* Mutex priority (ratified at M38 pre-flight; updated at v0.7-M42
|
|
265
|
+
* + v0.7-M43 pre-flights to fold the D5 bulk + D6 create carve-outs):
|
|
235
266
|
*
|
|
236
|
-
* 1. **callShape
|
|
237
|
-
*
|
|
238
|
-
* (
|
|
239
|
-
* to
|
|
240
|
-
*
|
|
241
|
-
*
|
|
242
|
-
*
|
|
243
|
-
*
|
|
244
|
-
*
|
|
245
|
-
*
|
|
267
|
+
* 1. **callShape gate — NONE remaining post-v0.7-M43** — both
|
|
268
|
+
* `'item_update_bulk'` (D5 fold at v0.7-M42) and `'item_create'`
|
|
269
|
+
* (D6 fold at v0.7-M43) short-circuit-throws have been removed.
|
|
270
|
+
* Every callShape falls through to the universal multi-file
|
|
271
|
+
* gate + a callShape-aware mixed gate, then returns a per-
|
|
272
|
+
* callShape `kind` on the clean path.
|
|
273
|
+
* 2. **multi-file leg** — 2+ file `--set` entries (any callShape)
|
|
274
|
+
* surface `'multi_file_set_unsupported'`. Universal rule:
|
|
275
|
+
* Monday's `add_file_to_column` is single-column per call on
|
|
276
|
+
* the wire regardless of fan-out shape.
|
|
246
277
|
* 3. **mixed leg** — 1 file `--set` + any value `--set` /
|
|
247
|
-
* `--set-raw` / `--name`
|
|
248
|
-
*
|
|
249
|
-
*
|
|
250
|
-
*
|
|
251
|
-
*
|
|
252
|
-
*
|
|
253
|
-
*
|
|
278
|
+
* `--set-raw` / `--name` surfaces `'mixed_file_and_value_sets'`
|
|
279
|
+
* on `'item_set'` / `'item_update_single'` / `'item_update_bulk'`.
|
|
280
|
+
* Universal rule on those callShapes: mixing forces non-atomic
|
|
281
|
+
* multi-leg dispatch across the multipart + JSON wire surfaces.
|
|
282
|
+
* **SUPPRESSED on `'item_create'`** per v0.7-M43 D6 mixed-rule
|
|
283
|
+
* asymmetry — `create_item` natively bundles non-file
|
|
284
|
+
* `column_values` atomically into leg-1, and `--name` is
|
|
285
|
+
* required on create.
|
|
286
|
+
* 4. **clean leg** — 1 file `--set`, no mutex violation:
|
|
287
|
+
* - `'item_update_single'` / `'item_set'` → return
|
|
288
|
+
* `{ kind: 'file', columnId, rawValue }` for downstream
|
|
289
|
+
* {@link precheckLocalFile} + {@link executeFileColumnSet}
|
|
290
|
+
* (M38 path; unchanged).
|
|
291
|
+
* - `'item_update_bulk'` → return `{ kind: 'file_bulk',
|
|
292
|
+
* columnId, rawValue }` for the action body's per-item
|
|
293
|
+
* multipart fan-out (v0.7-M42 D5 carve-out fold).
|
|
294
|
+
* - `'item_create'` → return `{ kind: 'file_create', columnId,
|
|
295
|
+
* rawValue }` for the action body's two-leg `create_item`
|
|
296
|
+
* then `add_file_to_column` helper (v0.7-M43 D6 carve-out
|
|
297
|
+
* fold).
|
|
254
298
|
*
|
|
255
299
|
* The function is sync + pure. No I/O. Path validation lives at a
|
|
256
300
|
* SEPARATE step (`precheckLocalFile` from `src/utils/file-source.ts`)
|
|
@@ -262,78 +306,38 @@ export const enforceSingleFileColumnSet = (inputs) => {
|
|
|
262
306
|
if (fileSetEntries.length === 0) {
|
|
263
307
|
return { kind: 'json' };
|
|
264
308
|
}
|
|
265
|
-
// callShape
|
|
266
|
-
//
|
|
267
|
-
//
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
`\`monday item set <iid> <file-col>=<path>\` or \`monday item ` +
|
|
282
|
-
`upload <iid> --column <col> <file>\` (v0.4-M31; verb-shaped).`, {
|
|
283
|
-
details: {
|
|
284
|
-
reason: 'file_set_on_bulk_unsupported',
|
|
285
|
-
column_id: fe.columnId,
|
|
286
|
-
deferred_to: 'v0.6.x',
|
|
287
|
-
hint: 'bulk file dispatch is not supported at v0.6-M38; iterate ' +
|
|
288
|
-
'matched items in your script and call `monday item set ' +
|
|
289
|
-
'<iid> <file-col>=<path>` per item, or use `monday item ' +
|
|
290
|
-
'upload <iid> --column <col> <file>` (v0.4-M31).',
|
|
291
|
-
},
|
|
292
|
-
});
|
|
293
|
-
}
|
|
294
|
-
if (inputs.callShape === 'item_create') {
|
|
295
|
-
const fe = fileSetEntries[0];
|
|
296
|
-
/* c8 ignore next 3 */
|
|
297
|
-
if (fe === undefined) {
|
|
298
|
-
throw new ApiError('internal_error', 'enforceSingleFileColumnSet: file entry narrowing failed (create)');
|
|
299
|
-
}
|
|
300
|
-
throw new ApiError('usage_error', `--set <file-col>=<path> is not supported on \`monday item create\` ` +
|
|
301
|
-
`at v0.6-M38 (deferred to v0.6.x per cli-design §13 v0.6 entry + ` +
|
|
302
|
-
`v0.6-plan §3 M38 D6 closure). Monday's wire has no atomic ` +
|
|
303
|
-
`create-with-file mutation at API \`2026-01\`; file upload at ` +
|
|
304
|
-
`create time would require a non-atomic post-create ` +
|
|
305
|
-
`\`add_file_to_column\` that breaks §5.8 state safety. Create ` +
|
|
306
|
-
`the item first, then attach the file with \`monday item set ` +
|
|
307
|
-
`<iid> <file-col>=<path>\` or \`monday item upload <iid> ` +
|
|
308
|
-
`--column <col> <file>\` (v0.4-M31; verb-shaped).`, {
|
|
309
|
-
details: {
|
|
310
|
-
reason: 'file_set_on_create_unsupported',
|
|
311
|
-
column_id: fe.columnId,
|
|
312
|
-
deferred_to: 'v0.6.x',
|
|
313
|
-
hint: 'create the item with non-file `--set` values, then attach ' +
|
|
314
|
-
'the file with `monday item set <iid> <file-col>=<path>` ' +
|
|
315
|
-
'(v0.6-M38) or `monday item upload <iid> --column <col> ' +
|
|
316
|
-
'<file>` (v0.4-M31).',
|
|
317
|
-
},
|
|
318
|
-
});
|
|
319
|
-
}
|
|
320
|
-
// Multi-file leg (D2). 2+ file `--set` entries on a non-bulk /
|
|
321
|
-
// non-create call shape — defers to v0.6.x.
|
|
309
|
+
// callShape gate — NO callShape short-circuits at this layer
|
|
310
|
+
// post v0.7-M43. The v0.6-M38 `'item_create'` short-circuit-throw
|
|
311
|
+
// (`'file_set_on_create_unsupported'`) FOLDED at v0.7-M43 (D6):
|
|
312
|
+
// create-time file `--set` falls through to the universal multi-
|
|
313
|
+
// file gate + a callShape-aware mixed gate, then returns
|
|
314
|
+
// `{ kind: 'file_create', ... }` on the clean path. The discriminator
|
|
315
|
+
// literal `'file_set_on_create_unsupported'` stays RESERVED in
|
|
316
|
+
// docstrings + regression-guard tests; do not re-introduce it as a
|
|
317
|
+
// runtime rejection without a fresh contract decision. (Parallels
|
|
318
|
+
// the v0.7-M42 fold of `'file_set_on_bulk_unsupported'` for
|
|
319
|
+
// `'item_update_bulk'`.)
|
|
320
|
+
// Multi-file leg (D2 multi). 2+ file `--set` entries on any
|
|
321
|
+
// callShape — applies universally (single-item AND bulk) because
|
|
322
|
+
// Monday's `add_file_to_column` is single-column per call on the
|
|
323
|
+
// wire regardless of how many items the dispatch fans out across.
|
|
324
|
+
// Multi-file dispatch carries forward as a v0.7.x candidate.
|
|
322
325
|
if (fileSetEntries.length > 1) {
|
|
323
|
-
throw new ApiError('usage_error', `Multi-file \`--set <file-col>=<path>\` is not supported
|
|
324
|
-
`
|
|
325
|
-
`
|
|
326
|
-
|
|
327
|
-
|
|
328
|
-
`the wire; multi-file dispatch +
|
|
329
|
-
`shared transport carry design
|
|
330
|
-
`milestone. Pass exactly one
|
|
331
|
-
|
|
326
|
+
throw new ApiError('usage_error', `Multi-file \`--set <file-col>=<path>\` is not supported ` +
|
|
327
|
+
`(${String(fileSetEntries.length)} file \`--set\` entries ` +
|
|
328
|
+
`detected; deferred to v0.7.x per cli-design §5.3 + v0.6-plan ` +
|
|
329
|
+
`§3 M38 D2 closure — carry-forward from v0.6 unchanged at ` +
|
|
330
|
+
`v0.7-M42). Monday's \`add_file_to_column\` mutation is ` +
|
|
331
|
+
`single-column per call on the wire; multi-file dispatch + ` +
|
|
332
|
+
`concurrent multipart over the shared transport carry design ` +
|
|
333
|
+
`dimensions worth their own milestone. Pass exactly one ` +
|
|
334
|
+
`\`--set <file-col>=<path>\` per call; for multiple uploads, ` +
|
|
335
|
+
`run separate calls.`, {
|
|
332
336
|
details: {
|
|
333
337
|
reason: 'multi_file_set_unsupported',
|
|
334
338
|
file_count: fileSetEntries.length,
|
|
335
339
|
file_column_ids: fileSetEntries.map((e) => e.columnId),
|
|
336
|
-
deferred_to: 'v0.
|
|
340
|
+
deferred_to: 'v0.7.x',
|
|
337
341
|
hint: 'pass exactly one `--set <file-col>=<path>` per call; ' +
|
|
338
342
|
'run separate calls for multiple file uploads.',
|
|
339
343
|
},
|
|
@@ -344,9 +348,26 @@ export const enforceSingleFileColumnSet = (inputs) => {
|
|
|
344
348
|
// of multipart `add_file_to_column` + JSON `change_column_value` /
|
|
345
349
|
// `change_multiple_column_values` (mixing forces non-atomic
|
|
346
350
|
// multi-leg dispatch that breaks the §5.3 atomicity contract).
|
|
351
|
+
//
|
|
352
|
+
// v0.7-M43 callShape carve-out (D6 mixed-rule asymmetry): on
|
|
353
|
+
// `'item_create'` the two-leg dispatch (`create_item` with bundled
|
|
354
|
+
// non-file column_values then `add_file_to_column`) absorbs the
|
|
355
|
+
// mixed scenarios into leg-1 atomicity for the non-file values +
|
|
356
|
+
// leg-2 atomicity for the file. `--name` is REQUIRED on create
|
|
357
|
+
// (not an opt-in rename like on update), so the universal `hasName`
|
|
358
|
+
// arm would auto-reject every M43 path; suppress on `'item_create'`.
|
|
359
|
+
// Non-file value `--set` + `--set-raw` entries are ALSO allowed on
|
|
360
|
+
// create-time mixed (they bundle into leg-1's `column_values`); the
|
|
361
|
+
// separate D3 `--set-raw <file-col>=<json>` rejection still applies
|
|
362
|
+
// at `raw-write.ts:translateRawColumnValue` for `file`-typed raw
|
|
363
|
+
// tokens, so the action-body path stays safe. The non-create
|
|
364
|
+
// callShapes ('item_set' / 'item_update_single' / 'item_update_bulk')
|
|
365
|
+
// keep the universal mixed rule unchanged.
|
|
347
366
|
const nonFileSetCount = inputs.setEntries.length - fileSetEntries.length;
|
|
348
367
|
const setRawCount = inputs.setRawEntries.length;
|
|
349
|
-
|
|
368
|
+
const mixedApplies = inputs.callShape !== 'item_create' &&
|
|
369
|
+
(nonFileSetCount > 0 || setRawCount > 0 || inputs.hasName);
|
|
370
|
+
if (mixedApplies) {
|
|
350
371
|
const fe = fileSetEntries[0];
|
|
351
372
|
/* c8 ignore next 3 */
|
|
352
373
|
if (fe === undefined) {
|
|
@@ -373,13 +394,27 @@ export const enforceSingleFileColumnSet = (inputs) => {
|
|
|
373
394
|
},
|
|
374
395
|
});
|
|
375
396
|
}
|
|
376
|
-
// Clean dispatch leg. Single file `--set`, no
|
|
377
|
-
//
|
|
397
|
+
// Clean dispatch leg. Single file `--set`, no mutex violation.
|
|
398
|
+
// Discriminators:
|
|
399
|
+
// - `'item_update_single'` / `'item_set'` → `kind: 'file'`
|
|
400
|
+
// (M38 single-item path; unchanged).
|
|
401
|
+
// - `'item_update_bulk'` → `kind: 'file_bulk'` (v0.7-M42 D5
|
|
402
|
+
// carve-out fold; action body's per-item multipart fan-out).
|
|
403
|
+
// - `'item_create'` → `kind: 'file_create'` (v0.7-M43 D6
|
|
404
|
+
// carve-out fold; action body's two-leg `create_item` then
|
|
405
|
+
// `add_file_to_column` dispatch with orphan-warn atomicity
|
|
406
|
+
// envelope per D1 closure).
|
|
378
407
|
const fe = fileSetEntries[0];
|
|
379
408
|
/* c8 ignore next 3 */
|
|
380
409
|
if (fe === undefined) {
|
|
381
410
|
throw new ApiError('internal_error', 'enforceSingleFileColumnSet: file entry narrowing failed (clean)');
|
|
382
411
|
}
|
|
412
|
+
if (inputs.callShape === 'item_update_bulk') {
|
|
413
|
+
return { kind: 'file_bulk', columnId: fe.columnId, rawValue: fe.rawValue };
|
|
414
|
+
}
|
|
415
|
+
if (inputs.callShape === 'item_create') {
|
|
416
|
+
return { kind: 'file_create', columnId: fe.columnId, rawValue: fe.rawValue };
|
|
417
|
+
}
|
|
383
418
|
return { kind: 'file', columnId: fe.columnId, rawValue: fe.rawValue };
|
|
384
419
|
};
|
|
385
420
|
/**
|
|
@@ -487,7 +522,8 @@ export const preCheckM38FileDispatch = async (inputs) => {
|
|
|
487
522
|
cacheAgeSeconds: aggregateCacheAge,
|
|
488
523
|
};
|
|
489
524
|
}
|
|
490
|
-
// enforcement.kind
|
|
525
|
+
// enforcement.kind is `'file'` (single-item) OR `'file_bulk'`
|
|
526
|
+
// (v0.7-M42 D5 carve-out fold). Find the matching resolved entry
|
|
491
527
|
// for the file-column token (echo into resolved_ids downstream).
|
|
492
528
|
const fileResolved = resolved.find((r) => r.columnType === 'file' &&
|
|
493
529
|
r.columnId === enforcement.columnId &&
|
|
@@ -497,6 +533,28 @@ export const preCheckM38FileDispatch = async (inputs) => {
|
|
|
497
533
|
if (fileResolved === undefined) {
|
|
498
534
|
throw new ApiError('internal_error', 'preCheckM38FileDispatch: file entry not found in resolved set after enforcement');
|
|
499
535
|
}
|
|
536
|
+
if (enforcement.kind === 'file_bulk') {
|
|
537
|
+
return {
|
|
538
|
+
kind: 'file_bulk',
|
|
539
|
+
columnId: enforcement.columnId,
|
|
540
|
+
rawValue: enforcement.rawValue,
|
|
541
|
+
token: fileResolved.token,
|
|
542
|
+
warnings,
|
|
543
|
+
source: aggregateSource,
|
|
544
|
+
cacheAgeSeconds: aggregateCacheAge,
|
|
545
|
+
};
|
|
546
|
+
}
|
|
547
|
+
if (enforcement.kind === 'file_create') {
|
|
548
|
+
return {
|
|
549
|
+
kind: 'file_create',
|
|
550
|
+
columnId: enforcement.columnId,
|
|
551
|
+
rawValue: enforcement.rawValue,
|
|
552
|
+
token: fileResolved.token,
|
|
553
|
+
warnings,
|
|
554
|
+
source: aggregateSource,
|
|
555
|
+
cacheAgeSeconds: aggregateCacheAge,
|
|
556
|
+
};
|
|
557
|
+
}
|
|
500
558
|
return {
|
|
501
559
|
kind: 'file',
|
|
502
560
|
columnId: enforcement.columnId,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"file-column-set.js","sourceRoot":"","sources":["../../src/api/file-column-set.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"file-column-set.js","sourceRoot":"","sources":["../../src/api/file-column-set.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAyKG;AAEH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,QAAQ,EAAE,MAAM,oBAAoB,CAAC;AAC9C,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,QAAQ,EAAE,WAAW,CAAC,QAAQ;QAC9B,QAAQ,EAAE,WAAW,CAAC,QAAQ;QAC9B,KAAK,EAAE,YAAY,CAAC,KAAK;QACzB,QAAQ;QACR,MAAM,EAAE,eAAe;QACvB,eAAe,EAAE,iBAAiB;KACnC,CAAC;AACJ,CAAC,CAAC"}
|
package/dist/api/raw-write.d.ts
CHANGED
|
@@ -22,19 +22,24 @@
|
|
|
22
22
|
* from CLI-time to Monday-time with no new information.
|
|
23
23
|
* * **`files`-shaped** (`file`, anything else where Monday
|
|
24
24
|
* uses `add_file_to_column` rather than `change_column_value`)
|
|
25
|
-
* → `unsupported_column_type` rejection STAYS
|
|
26
|
-
*
|
|
25
|
+
* → `unsupported_column_type` rejection STAYS per D3
|
|
26
|
+
* closure (permanent). The `--set-raw` payload reaches
|
|
27
27
|
* `change_column_value` / `change_multiple_column_values`
|
|
28
28
|
* only; files-shaped types can't be written through that
|
|
29
29
|
* wire surface (Monday's wire has no JSON-shape for
|
|
30
|
-
* `change_column_value` on file columns).
|
|
31
|
-
*
|
|
32
|
-
*
|
|
33
|
-
*
|
|
30
|
+
* `change_column_value` on file columns). The friendly
|
|
31
|
+
* `--set <file-col>=<path>` form ships across three
|
|
32
|
+
* shipped paths (v0.6-M38 single-item + v0.7-M42 bulk +
|
|
33
|
+
* v0.4-M31 verb-shaped upload — all dispatching into the
|
|
34
|
+
* multipart wire at the command action body) but keeps
|
|
35
|
+
* `--set-raw` rejected — the escape-hatch contract
|
|
34
36
|
* "user supplies JSON `change_column_value` accepts"
|
|
35
|
-
* doesn't compose with multipart. Hint
|
|
36
|
-
* v0.6-M38
|
|
37
|
-
*
|
|
37
|
+
* doesn't compose with multipart. Hint enumerates every
|
|
38
|
+
* shipped multipart write path: v0.6-M38 single-item
|
|
39
|
+
* friendly `--set` form on `monday item set` + `monday
|
|
40
|
+
* item update <iid>`; v0.7-M42 bulk friendly `--set`
|
|
41
|
+
* form on `monday item update --where ...` (per-item
|
|
42
|
+
* fan-out); v0.4-M31 verb-shaped `monday item upload`.
|
|
38
43
|
* Otherwise builds a `TranslatedColumnValue` with `payload:
|
|
39
44
|
* { format: 'rich', value: <parsed> }` so the existing
|
|
40
45
|
* `selectMutation` dispatcher handles it uniformly.
|
|
@@ -109,19 +114,25 @@ export declare const parseSetRawExpression: (raw: string) => ParsedSetRawExpress
|
|
|
109
114
|
* `read_only: true`. Monday computes these server-side; no
|
|
110
115
|
* payload (raw or friendly) is ever accepted.
|
|
111
116
|
* - **`files`-shaped** → `unsupported_column_type` rejection
|
|
112
|
-
* STAYS
|
|
117
|
+
* STAYS per D3 closure (permanent). Monday writes via
|
|
113
118
|
* `add_file_to_column` (multipart upload), not
|
|
114
119
|
* `change_column_value`; the raw payload can't reach the
|
|
115
120
|
* right wire surface (Monday's wire has no JSON-shape for
|
|
116
|
-
* `change_column_value` on file columns).
|
|
117
|
-
*
|
|
118
|
-
* the multipart wire
|
|
119
|
-
* `
|
|
120
|
-
*
|
|
121
|
+
* `change_column_value` on file columns). The friendly
|
|
122
|
+
* `--set <file-col>=<path>` form ships across four paths
|
|
123
|
+
* reaching the multipart wire: v0.6-M38 single-item friendly
|
|
124
|
+
* (`monday item set` + `monday item update <iid>`); v0.7-M42
|
|
125
|
+
* bulk friendly (`monday item update --where ...` per-item
|
|
126
|
+
* fan-out under `--concurrency` / `--continue-on-error`);
|
|
127
|
+
* v0.7-M43 create-time friendly (`monday item create --set
|
|
128
|
+
* <file-col>=<path>` two-leg `create_item` + `add_file_to_
|
|
129
|
+
* column` dispatch under the §5.8 orphan-warn atomicity
|
|
130
|
+
* envelope); v0.4-M31 verb-shaped (`monday item upload <iid>
|
|
131
|
+
* --column <col> <file>`). The escape-hatch contract "user
|
|
132
|
+
* supplies JSON `change_column_value` accepts" doesn't
|
|
121
133
|
* compose with multipart, so `--set-raw <file-col>=<json>`
|
|
122
|
-
* stays rejected. Hint
|
|
123
|
-
*
|
|
124
|
-
* multipart).
|
|
134
|
+
* stays rejected regardless. Hint enumerates every shipped
|
|
135
|
+
* path.
|
|
125
136
|
*
|
|
126
137
|
* Anything else (writable + tentative-slipped + future where the API
|
|
127
138
|
* accepts `change_column_value`) is accepted — the user took the
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"raw-write.d.ts","sourceRoot":"","sources":["../../src/api/raw-write.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"raw-write.d.ts","sourceRoot":"","sources":["../../src/api/raw-write.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAuEG;AAOH,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAC;AACnD,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,oBAAoB,CAAC;AAEhE,MAAM,WAAW,sBAAsB;IACrC,mFAAmF;IACnF,QAAQ,CAAC,KAAK,EAAE,MAAM,CAAC;IACvB;;;;;OAKG;IACH,QAAQ,CAAC,KAAK,EAAE,UAAU,CAAC;IAC3B,wEAAwE;IACxE,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;CAC1B;AAED;;;;;;;;;;;;;;;;;GAiBG;AACH,eAAO,MAAM,qBAAqB,GAAI,KAAK,MAAM,KAAG,sBA+DnD,CAAC;AAEF;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA4CG;AACH,eAAO,MAAM,uBAAuB,GAClC,QAAQ;IAAE,QAAQ,CAAC,EAAE,EAAE,MAAM,CAAC;IAAC,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAA;CAAE,EACtD,OAAO,UAAU,EACjB,SAAS,MAAM,KACd,qBAwFF,CAAC;AAsBF,YAAY,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAC"}
|
package/dist/api/raw-write.js
CHANGED
|
@@ -22,19 +22,24 @@
|
|
|
22
22
|
* from CLI-time to Monday-time with no new information.
|
|
23
23
|
* * **`files`-shaped** (`file`, anything else where Monday
|
|
24
24
|
* uses `add_file_to_column` rather than `change_column_value`)
|
|
25
|
-
* → `unsupported_column_type` rejection STAYS
|
|
26
|
-
*
|
|
25
|
+
* → `unsupported_column_type` rejection STAYS per D3
|
|
26
|
+
* closure (permanent). The `--set-raw` payload reaches
|
|
27
27
|
* `change_column_value` / `change_multiple_column_values`
|
|
28
28
|
* only; files-shaped types can't be written through that
|
|
29
29
|
* wire surface (Monday's wire has no JSON-shape for
|
|
30
|
-
* `change_column_value` on file columns).
|
|
31
|
-
*
|
|
32
|
-
*
|
|
33
|
-
*
|
|
30
|
+
* `change_column_value` on file columns). The friendly
|
|
31
|
+
* `--set <file-col>=<path>` form ships across three
|
|
32
|
+
* shipped paths (v0.6-M38 single-item + v0.7-M42 bulk +
|
|
33
|
+
* v0.4-M31 verb-shaped upload — all dispatching into the
|
|
34
|
+
* multipart wire at the command action body) but keeps
|
|
35
|
+
* `--set-raw` rejected — the escape-hatch contract
|
|
34
36
|
* "user supplies JSON `change_column_value` accepts"
|
|
35
|
-
* doesn't compose with multipart. Hint
|
|
36
|
-
* v0.6-M38
|
|
37
|
-
*
|
|
37
|
+
* doesn't compose with multipart. Hint enumerates every
|
|
38
|
+
* shipped multipart write path: v0.6-M38 single-item
|
|
39
|
+
* friendly `--set` form on `monday item set` + `monday
|
|
40
|
+
* item update <iid>`; v0.7-M42 bulk friendly `--set`
|
|
41
|
+
* form on `monday item update --where ...` (per-item
|
|
42
|
+
* fan-out); v0.4-M31 verb-shaped `monday item upload`.
|
|
38
43
|
* Otherwise builds a `TranslatedColumnValue` with `payload:
|
|
39
44
|
* { format: 'rich', value: <parsed> }` so the existing
|
|
40
45
|
* `selectMutation` dispatcher handles it uniformly.
|
|
@@ -146,19 +151,25 @@ export const parseSetRawExpression = (raw) => {
|
|
|
146
151
|
* `read_only: true`. Monday computes these server-side; no
|
|
147
152
|
* payload (raw or friendly) is ever accepted.
|
|
148
153
|
* - **`files`-shaped** → `unsupported_column_type` rejection
|
|
149
|
-
* STAYS
|
|
154
|
+
* STAYS per D3 closure (permanent). Monday writes via
|
|
150
155
|
* `add_file_to_column` (multipart upload), not
|
|
151
156
|
* `change_column_value`; the raw payload can't reach the
|
|
152
157
|
* right wire surface (Monday's wire has no JSON-shape for
|
|
153
|
-
* `change_column_value` on file columns).
|
|
154
|
-
*
|
|
155
|
-
* the multipart wire
|
|
156
|
-
* `
|
|
157
|
-
*
|
|
158
|
+
* `change_column_value` on file columns). The friendly
|
|
159
|
+
* `--set <file-col>=<path>` form ships across four paths
|
|
160
|
+
* reaching the multipart wire: v0.6-M38 single-item friendly
|
|
161
|
+
* (`monday item set` + `monday item update <iid>`); v0.7-M42
|
|
162
|
+
* bulk friendly (`monday item update --where ...` per-item
|
|
163
|
+
* fan-out under `--concurrency` / `--continue-on-error`);
|
|
164
|
+
* v0.7-M43 create-time friendly (`monday item create --set
|
|
165
|
+
* <file-col>=<path>` two-leg `create_item` + `add_file_to_
|
|
166
|
+
* column` dispatch under the §5.8 orphan-warn atomicity
|
|
167
|
+
* envelope); v0.4-M31 verb-shaped (`monday item upload <iid>
|
|
168
|
+
* --column <col> <file>`). The escape-hatch contract "user
|
|
169
|
+
* supplies JSON `change_column_value` accepts" doesn't
|
|
158
170
|
* compose with multipart, so `--set-raw <file-col>=<json>`
|
|
159
|
-
* stays rejected. Hint
|
|
160
|
-
*
|
|
161
|
-
* multipart).
|
|
171
|
+
* stays rejected regardless. Hint enumerates every shipped
|
|
172
|
+
* path.
|
|
162
173
|
*
|
|
163
174
|
* Anything else (writable + tentative-slipped + future where the API
|
|
164
175
|
* accepts `change_column_value`) is accepted — the user took the
|
|
@@ -204,19 +215,30 @@ export const translateRawColumnValue = (column, value, rawJson) => {
|
|
|
204
215
|
`the right wire surface for this type. Use ` +
|
|
205
216
|
`\`monday item set <iid> <file-col>=<path>\` / ` +
|
|
206
217
|
`\`monday item update <iid> --set <file-col>=<path>\` (v0.6-M38; ` +
|
|
207
|
-
`friendly
|
|
208
|
-
|
|
218
|
+
`single-item friendly) OR \`monday item update --where ... --set ` +
|
|
219
|
+
`<file-col>=<path>\` (v0.7-M42; bulk friendly with per-item ` +
|
|
220
|
+
`multipart fan-out) OR \`monday item create --set ` +
|
|
221
|
+
`<file-col>=<path>\` (v0.7-M43; create-time two-leg under ` +
|
|
222
|
+
`the §5.8 orphan-warn atomicity envelope) OR \`monday item ` +
|
|
223
|
+
`upload <iid> --column <col> <file>\` (v0.4-M31; verb-shaped ` +
|
|
224
|
+
`multipart).`, {
|
|
209
225
|
details: {
|
|
210
226
|
column_id: column.id,
|
|
211
227
|
type: column.type,
|
|
212
|
-
hint: '
|
|
228
|
+
hint: 'four write paths reach Monday\'s add_file_to_column ' +
|
|
213
229
|
'multipart wire: (a) `monday item set <iid> ' +
|
|
214
230
|
'<file-col>=<path>` / `monday item update <iid> --set ' +
|
|
215
|
-
'<file-col>=<path>` (v0.6-M38; friendly
|
|
216
|
-
'
|
|
217
|
-
'<file>` (v0.
|
|
218
|
-
'
|
|
219
|
-
'
|
|
231
|
+
'<file-col>=<path>` (v0.6-M38; single-item friendly); ' +
|
|
232
|
+
'(b) `monday item update --where ... --set ' +
|
|
233
|
+
'<file-col>=<path>` (v0.7-M42; bulk friendly per-item ' +
|
|
234
|
+
'fan-out under --concurrency / --continue-on-error); ' +
|
|
235
|
+
'(c) `monday item create --set <file-col>=<path>` ' +
|
|
236
|
+
'(v0.7-M43; create-time two-leg friendly translator ' +
|
|
237
|
+
'under the §5.8 orphan-warn atomicity envelope); ' +
|
|
238
|
+
'(d) `monday item upload <iid> --column <col> <file>` ' +
|
|
239
|
+
'(v0.4-M31; verb-shaped). --set-raw rejects file-shaped ' +
|
|
240
|
+
'columns per D3 closure (permanent) — the escape-hatch ' +
|
|
241
|
+
'contract requires a JSON wire shape, and ' +
|
|
220
242
|
'add_file_to_column is multipart-only.',
|
|
221
243
|
},
|
|
222
244
|
});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"raw-write.js","sourceRoot":"","sources":["../../src/api/raw-write.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"raw-write.js","sourceRoot":"","sources":["../../src/api/raw-write.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAuEG;AAEH,OAAO,EAAE,QAAQ,EAAE,UAAU,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AACxE,OAAO,EACL,iBAAiB,EACjB,qBAAqB,GACtB,MAAM,mBAAmB,CAAC;AAkB3B;;;;;;;;;;;;;;;;;GAiBG;AACH,MAAM,CAAC,MAAM,qBAAqB,GAAG,CAAC,GAAW,EAA0B,EAAE;IAC3E,MAAM,GAAG,GAAG,GAAG,CAAC,OAAO,CAAC,GAAG,CAAC,CAAC;IAC7B,IAAI,GAAG,IAAI,CAAC,EAAE,CAAC;QACb,MAAM,IAAI,UAAU,CAClB,yCAAyC,IAAI,CAAC,SAAS,CAAC,GAAG,CAAC,KAAK;YAC/D,8DAA8D;YAC9D,oBAAoB,EACtB,EAAE,OAAO,EAAE,EAAE,KAAK,EAAE,GAAG,EAAE,EAAE,CAC5B,CAAC;IACJ,CAAC;IACD,MAAM,KAAK,GAAG,GAAG,CAAC,KAAK,CAAC,CAAC,EAAE,GAAG,CAAC,CAAC;IAChC,MAAM,OAAO,GAAG,GAAG,CAAC,KAAK,CAAC,GAAG,GAAG,CAAC,CAAC,CAAC;IACnC,IAAI,OAAO,CAAC,MAAM,KAAK,CAAC,EAAE,CAAC;QACzB,MAAM,IAAI,UAAU,CAClB,0CAA0C,IAAI,CAAC,SAAS,CAAC,GAAG,CAAC,KAAK;YAChE,uEAAuE,EACzE,EAAE,OAAO,EAAE,EAAE,KAAK,EAAE,GAAG,EAAE,KAAK,EAAE,EAAE,CACnC,CAAC;IACJ,CAAC;IACD,IAAI,MAAe,CAAC;IACpB,IAAI,CA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