Digest Amount does not exist on a digest job
I'm seeing this quite a bit in our logs
{
"level": 40,
"time": 1699023328422,
"pid": 17,
"serviceName": "@novu/worker",
"serviceVersion": "0.17.1",
"platform": "Docker",
"tenant": "OS",
"transactionId": "017425c5-2225-413b-8fdc-a0ef35a9b073",
"environmentId": "64c7dbbd0b825551a56889d7",
"organizationId": "64c7dbbc0b825551a56889ab",
"jobId": "654509cff7875593d0377b9f",
"msg": "Digest Amount does not exist on a digest job"
}
What does it mean? Is there an action on us for these?22 Replies
Is amount set up correctly on digest ?
Yes. I can see in the app and also in the database that the template referred to in the job has the digest amount, e, g.
But interestingly, the job document in question doesn't seem to have persisted this data, it shows blank
Is this a bug? Can I patch the document records with digest data to fix this?
@Engineering
Are you using multiple digest in the workflow?
@David no
if you could share some more about how the workflow looks because I fixed a bug for this yesterday so it should be fixed in next release but I would like to make sure that it fix your case as well
So this is the associated notification template (workflow)
I'm seeing other errors with other workflows too, not just this one. What was the fix you alluded to?
Any ideas? still seeing this a lot
So the fix I did was that the digest object was changed when we save the digested events and with my fix we only save the events on the current digest object and not change hte whole object
so I'd need to upgrade to fix?
when the fix is released you will have to update yes
or if you are running it locally in main it should work for you now
so what effect will this have? Does it mean that these jobs are failing and not sending anything?
your stop on fail is false it should do next step but I am guessing that you are using the digested data in your in app notification?
yes
so then the in app notification will fail as well I think
I'm checking for
step.total_count
in the in-app with a control statement so I'm assuming that will still work... but it's going to be a huge problem for us if we're not digesting and sending loads of individual notifications.@dmgarland, you just advanced to level 4!
Sounds like it's important to set 'stop on fail' to false for digests? What's the behaviour? We're using the digest to stop poeple being flooded...
that if the digest step fails it will continue to next step but your message may not look as intended because all the digested information is not there and the events that was supposed to be digest will not be sent.
@Paweł T. @Dima Grossman maybe we should patch out my fix for this?
But could you confirm that unless I manually set 'stop on fail' we're effectively not digesting and spamming in-apps?
I don't see 'stop on fail' for digest step in the app, so I'd need to do this at the DB level?
You will not spam them because the other events will still think they will be digested.