Included only step id into check point key.

Signed-off-by: bnechyporenko <bnechyporenko@bol.com>
This commit is contained in:
bnechyporenko
2024-09-26 08:17:12 +02:00
parent a7837873d6
commit be88239ea0
2 changed files with 3 additions and 3 deletions
@@ -601,11 +601,11 @@ describe('NunjucksWorkflowRunner', () => {
return Promise.resolve({
state: {
checkpoints: {
['v1.task.checkpoint.name.test.key1']: {
['v1.task.checkpoint.test.key1']: {
status: 'success',
value: 'initial',
},
['v1.task.checkpoint.name.test2.key2']: {
['v1.task.checkpoint.test2.key2']: {
status: 'failed',
reason: 'fatal error',
},
@@ -375,7 +375,7 @@ export class NunjucksWorkflowRunner implements WorkflowRunner {
keySuffix: string,
fn: () => Promise<U>,
) {
const key = `v1.task.checkpoint.${step.name}.${step.id}.${keySuffix}`;
const key = `v1.task.checkpoint.${step.id}.${keySuffix}`;
try {
let prevValue: U | undefined;
if (prevTaskState) {