Commit 254e33b
Incorporate CLI that supports all
* first stab at merging in transloadify
* use cli subdir. more re-use of code
* fix e2e
* apply stricter biome & tsconfig rules
* abort assemblies
* Improve types, make replay clearer, roll test for it
* stronger types
* wip
* fix version
* format
* run e2e for own PRs
* dotenv
* cli docs
* add missing docs
* merge CI
* add node 24
* e2e only on 24
* test: use unique template names to avoid CI conflicts
Use a unique testId (timestamp + random string) for all template names
in e2e tests to prevent conflicts when tests run in parallel or when
previous runs didn't clean up properly.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>
* feat: honor abort signal during awaitAssemblyCompletion polling
Previously, the abort signal passed to createAssembly was only honored
during the initial HTTP POST and TUS uploads. Now it's also honored
during the polling loop in awaitAssemblyCompletion, allowing users to
cancel long-running assembly operations at any point.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>
* add browser
* fix bug
* fix: address code review feedback
- JobsPromise now throws if error handler not set before adding promises
- Added clarifying comment explaining orphaned promise pattern in createAssembly
- WatchJobEmitter now properly cleans up file watchers on SIGINT/SIGTERM and errors
- Expanded --verbose/--quiet documentation with output level table
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>
* feat: replace --verbose/--quiet with --log-level (-l)
Use syslog-style severity levels inspired by @transloadit/sev-logger:
- err (3): Error conditions
- warn (4): Warning conditions
- notice (5): Normal but significant (default)
- info (6): Informational messages
- debug (7): Debug-level messages
Example: `npx transloadit assemblies list -l debug`
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>
* feat: allow numeric values for --log-level
Now accepts both level names and numeric values:
-l warn OR -l 4
-l debug OR -l 7
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>
* feat: add trace log level (8)
Most verbose level for detailed tracing, matching sev-logger.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>
* add onPoll
* fix
* format
* fix: CLI exits with code 1 when jobs fail, fix AbortSignal listener leak
- Add hasFailures tracking to JobsPromise so CLI can detect failures
- CLI assemblies create now returns exit code 1 when any job fails
- Fix memory leak in awaitAssemblyCompletion: remove abort listener
when sleep timeout resolves normally
- Update CHANGELOG with better onPoll description
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>
* feat(cli): add --endpoint option and --single-assembly flag
- Add --endpoint option to all commands for custom API endpoint
(also reads from TRANSLOADIT_ENDPOINT env var)
- Add --single-assembly flag to assemblies create command
Passes all input files to a single assembly instead of creating
one assembly per file. Cannot be used with --watch.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>
* docs: document --endpoint and --single-assembly CLI options
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>
* fix: handle templates with no steps in sync download
When downloading a template that has no steps defined, `result.content.steps`
is undefined. JSON.stringify strips undefined values, so after writing and
reading the file back, the `steps` property would be missing.
Use nullish coalescing to default to empty object: `steps ?? {}`
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>
* refactor: use tryCatch utility for cleaner error handling
Replace try-catch blocks with tryCatch() in assemblies-create.ts for
simple "stat file, use default on error" patterns. This reduces
boilerplate and improves readability.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>
* fix: remove non-functional notifications list, add download abort signal
- Remove assembly-notifications list command (Transloadit API doesn't
have a list notifications endpoint, only replay)
- Remove the stub implementation and test
- Update README to remove the non-existent list command
- Add AbortSignal to https.get downloads so they can be cancelled
when errors occur or the process is aborted
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>
* refactor: use got.stream + pipeline for downloads
Replace http/https.get with got.stream() and Node's pipeline().
This is cleaner, more consistent with the rest of the SDK (which uses got),
and reduces callback nesting.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>
* test: add e2e test verifying download integrity via md5 hash
- Add test that verifies downloaded file md5 matches the md5hash
from the assembly result
- Return assembly status from job promises so tests can access
result metadata like md5hash
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>
* fix: prevent file descriptor exhaustion with concurrency limiting
Add --concurrency option and fix file handle leaks:
1. Default mode: Queue job metadata and process up to N at a time
(default: 5). Creates fresh streams only when job slots available.
2. Single-assembly mode: Close streams immediately after collecting
paths, create fresh streams only when uploading.
Both fixes prevent EMFILE errors when processing many files.
Tests verify:
- "PROCESSING JOB" messages emitted with concurrency limiting
- "STREAM CLOSED" messages emitted in single-assembly mode
- Max concurrent jobs respects the concurrency limit
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>
* perf: split assemblies e2e tests for parallel execution
Split assemblies.test.ts into three files to leverage vitest's
file-level parallelism:
- assemblies.test.ts: get, delete, replay tests
- assemblies-create.test.ts: create tests
- assemblies-list.test.ts: list test (slowest at ~30s)
This reduces e2e test wall time from ~73s to ~40s (~45% faster).
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>
* upgrade yarn, add p-queue
* upgrade yarn
* use p-queue instead of JobPromise
* natives
* no esnureDir
* unify cli files
* format
---------
Co-authored-by: Claude <noreply@anthropic.com>transloadify commands (#268)1 parent 5307302 commit 254e33b
File tree
47 files changed
+5016
-579
lines changed- .gemini
- .github/workflows
- examples
- src
- cli
- commands
- test
- e2e
- cli
- fixtures
- unit
- cli
Some content is hidden
Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
47 files changed
+5016
-579
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | 3 | | |
| 4 | + | |
4 | 5 | | |
5 | 6 | | |
6 | 7 | | |
7 | 8 | | |
8 | 9 | | |
9 | 10 | | |
| 11 | + | |
| 12 | + | |
10 | 13 | | |
11 | 14 | | |
12 | 15 | | |
| 16 | + | |
13 | 17 | | |
14 | 18 | | |
15 | 19 | | |
| |||
24 | 28 | | |
25 | 29 | | |
26 | 30 | | |
| 31 | + | |
27 | 32 | | |
28 | 33 | | |
29 | 34 | | |
| |||
34 | 39 | | |
35 | 40 | | |
36 | 41 | | |
| 42 | + | |
37 | 43 | | |
38 | 44 | | |
39 | 45 | | |
| |||
43 | 49 | | |
44 | 50 | | |
45 | 51 | | |
46 | | - | |
| 52 | + | |
| 53 | + | |
47 | 54 | | |
48 | 55 | | |
49 | 56 | | |
50 | 57 | | |
51 | 58 | | |
52 | 59 | | |
| 60 | + | |
53 | 61 | | |
54 | 62 | | |
55 | 63 | | |
| |||
58 | 66 | | |
59 | 67 | | |
60 | 68 | | |
61 | | - | |
| 69 | + | |
62 | 70 | | |
63 | 71 | | |
64 | 72 | | |
65 | 73 | | |
66 | 74 | | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
| 100 | + | |
| 101 | + | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
| 106 | + | |
| 107 | + | |
| 108 | + | |
| 109 | + | |
| 110 | + | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
| 115 | + | |
| 116 | + | |
| 117 | + | |
| 118 | + | |
| 119 | + | |
| 120 | + | |
| 121 | + | |
| 122 | + | |
| 123 | + | |
| 124 | + | |
| 125 | + | |
| 126 | + | |
| 127 | + | |
| 128 | + | |
| 129 | + | |
| 130 | + | |
| 131 | + | |
| 132 | + | |
| 133 | + | |
| 134 | + | |
67 | 135 | | |
68 | | - | |
| 136 | + | |
| 137 | + | |
69 | 138 | | |
70 | 139 | | |
71 | 140 | | |
| |||
83 | 152 | | |
84 | 153 | | |
85 | 154 | | |
| 155 | + | |
| 156 | + | |
| 157 | + | |
| 158 | + | |
| 159 | + | |
| 160 | + | |
| 161 | + | |
| 162 | + | |
| 163 | + | |
| 164 | + | |
| 165 | + | |
| 166 | + | |
86 | 167 | | |
| 168 | + | |
87 | 169 | | |
88 | 170 | | |
89 | 171 | | |
90 | 172 | | |
91 | 173 | | |
92 | | - | |
| 174 | + | |
93 | 175 | | |
94 | 176 | | |
95 | 177 | | |
| |||
This file was deleted.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2 | 2 | | |
3 | 3 | | |
4 | 4 | | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
5 | 17 | | |
6 | 18 | | |
7 | 19 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
50 | 50 | | |
51 | 51 | | |
52 | 52 | | |
53 | | - | |
| 53 | + | |
54 | 54 | | |
55 | | - | |
| 55 | + | |
56 | 56 | | |
57 | 57 | | |
58 | 58 | | |
| |||
63 | 63 | | |
64 | 64 | | |
65 | 65 | | |
66 | | - | |
| 66 | + | |
67 | 67 | | |
68 | 68 | | |
69 | | - | |
| 69 | + | |
70 | 70 | | |
71 | 71 | | |
72 | 72 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
19 | 19 | | |
20 | 20 | | |
21 | 21 | | |
22 | | - | |
| 22 | + | |
23 | 23 | | |
24 | | - | |
25 | | - | |
26 | | - | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
27 | 27 | | |
28 | 28 | | |
29 | 29 | | |
| |||
48 | 48 | | |
49 | 49 | | |
50 | 50 | | |
51 | | - | |
52 | | - | |
| 51 | + | |
| 52 | + | |
53 | 53 | | |
54 | 54 | | |
55 | 55 | | |
56 | 56 | | |
57 | 57 | | |
58 | | - | |
| 58 | + | |
59 | 59 | | |
60 | | - | |
| 60 | + | |
61 | 61 | | |
62 | 62 | | |
63 | 63 | | |
| |||
82 | 82 | | |
83 | 83 | | |
84 | 84 | | |
85 | | - | |
| 85 | + | |
86 | 86 | | |
87 | 87 | | |
88 | 88 | | |
89 | | - | |
| 89 | + | |
90 | 90 | | |
91 | | - | |
| 91 | + | |
92 | 92 | | |
93 | | - | |
| 93 | + | |
94 | 94 | | |
95 | 95 | | |
96 | 96 | | |
| |||
103 | 103 | | |
104 | 104 | | |
105 | 105 | | |
106 | | - | |
| 106 | + | |
107 | 107 | | |
108 | 108 | | |
109 | 109 | | |
110 | 110 | | |
111 | 111 | | |
112 | 112 | | |
113 | | - | |
114 | | - | |
115 | | - | |
116 | | - | |
117 | | - | |
| 113 | + | |
| 114 | + | |
| 115 | + | |
| 116 | + | |
| 117 | + | |
118 | 118 | | |
119 | 119 | | |
120 | 120 | | |
| |||
135 | 135 | | |
136 | 136 | | |
137 | 137 | | |
138 | | - | |
| 138 | + | |
139 | 139 | | |
140 | 140 | | |
141 | 141 | | |
| |||
0 commit comments