Skip to content

Commit 8fbcf82

Browse files
authored
fix: Fix RunCollectionListOptions status type (#681)
Fixes the problem with invalid type `RunCollectionListOptions` of `RunCollectionClient.list` parameter `options` `'TIMING_OUT' | 'TIMED_OUT'` -> `'TIMING-OUT' | 'TIMED-OUT'` effectively changes it from `'READY' | 'RUNNING' | 'SUCCEEDED' | 'FAILED' | 'ABORTING' | 'ABORTED' | 'TIMING_OUT' | 'TIMED_OUT'` to `'READY' | 'RUNNING' | 'SUCCEEDED' | 'FAILED' | 'ABORTING' | 'ABORTED' | 'TIMING-OUT' | 'TIMED-OUT'` The reason for the bug is simple — `ACT_JOB_STATUSES` has super misleading key names :) see [ACT_JOB_STATUSES](https://github.com/apify/apify-shared-js/blob/37169fcbbd013ee45a6484adcf83ce1135057b4b/packages/consts/src/consts.ts#L30)
1 parent 744bce8 commit 8fbcf82

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/resource_clients/run_collection.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,5 +40,5 @@ export interface RunCollectionListOptions {
4040
limit?: number;
4141
offset?: number;
4242
desc?: boolean;
43-
status?: keyof typeof ACT_JOB_STATUSES;
43+
status?: (typeof ACT_JOB_STATUSES)[keyof typeof ACT_JOB_STATUSES];
4444
}

0 commit comments

Comments
 (0)