You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the Bug
IER12 job fails if application(s) do not contain at least 1 grant.
Expected Behaviour
IER12 job should be able to pick up an application and create a record in the file even if there are no grants.
Actual Behaviour
When running the IER12 job with applications that contain no grants, the job fails and fails with the following error:
TypeError: Reduce of empty array with no initial value
at Array.reduce ()
at IER12IntegrationService.getSumOfAwards (/opt/app-root/src/dist/apps/queue-consumers/main.js:14723:14)
at /opt/app-root/src/dist/apps/queue-consumers/main.js:14599:43
at Array.map ()
at IER12IntegrationService.createIER12FileContent (/opt/app-root/src/dist/apps/queue-consumers/main.js:14556:42)
at IER12ProcessingService.uploadIER12Content (/opt/app-root/src/dist/apps/queue-consumers/main.js:14354:62)
at IER12ProcessingService.processIER12File (/opt/app-root/src/dist/apps/queue-consumers/main.js:14342:52)
at runMicrotasks ()
at processTicksAndRejections (node:internal/process/task_queues:96:5)
at async IER12IntegrationScheduler.processIER12File (/opt/app-root/src/dist/apps/queue-consumers/main.js:13993:31)
** Steps To Reproduce**
Steps to reproduce the behaviour:
Create application with no grant award types. (Use income over $100,000 and no disability for single independent student) and submitted for any non BC Public institution.
Describe the Bug
IER12 job fails if application(s) do not contain at least 1 grant.
Expected Behaviour
IER12 job should be able to pick up an application and create a record in the file even if there are no grants.
Actual Behaviour
When running the IER12 job with applications that contain no grants, the job fails and fails with the following error:
TypeError: Reduce of empty array with no initial value
at Array.reduce ()
at IER12IntegrationService.getSumOfAwards (/opt/app-root/src/dist/apps/queue-consumers/main.js:14723:14)
at /opt/app-root/src/dist/apps/queue-consumers/main.js:14599:43
at Array.map ()
at IER12IntegrationService.createIER12FileContent (/opt/app-root/src/dist/apps/queue-consumers/main.js:14556:42)
at IER12ProcessingService.uploadIER12Content (/opt/app-root/src/dist/apps/queue-consumers/main.js:14354:62)
at IER12ProcessingService.processIER12File (/opt/app-root/src/dist/apps/queue-consumers/main.js:14342:52)
at runMicrotasks ()
at processTicksAndRejections (node:internal/process/task_queues:96:5)
at async IER12IntegrationScheduler.processIER12File (/opt/app-root/src/dist/apps/queue-consumers/main.js:13993:31)
** Steps To Reproduce**
Steps to reproduce the behaviour:
Acceptance Criteria
The text was updated successfully, but these errors were encountered: