Opensearch dashboards report is being generated intermittently

Versions (relevant - OpenSearch/Dashboard/Server OS/Browser):
2.18.0

Describe the issue:
when i am clicking on the reporting option then at times report is generated successfully and at times it getting failed with download error but difference in my situation is that when its successful then generate report url is different and when its failing then its different.

Configuration:

Relevant Logs or Screenshots:

url in case of success:
http://10.198.140.222:5601/api/reporting/generateReport?timezone=Asia%2FKuala_Lumpur&dateFormat=YYYY-MM-DD+HH%3Amm%3Ass.SSS&csvSeparator=%2C&allowLeadingWildcards=true

url in case of Failure:

url: “http://10.198.140.222:5601/app/api/reporting/generateReport?timezone=Asia%2FKuala_Lumpur&dateFormat=YYYY-MM-DD+HH%3Amm%3Ass.SSS&csvSeparator=%2C&allowLeadingWildcards=true

when i was googling then i found that the below fix which was done long back seems to be having a link with this issue as it was touching the same piece of code where i am having the error.

Fix reporting discover #190 ( not able to put the full link as being a new user, i can only put two links in at max )

Can anyone please guide if we are still looking at a bug or i am having some local conf or environmental issue.

Hi, anyone has any idea on this? appreciate your help