Open spw-dhurran opened 1 month ago
Sorry wrong repo
This is the good repo, as this is the command called from VsCode sfdx-hardis :)
I'll have a look :)
@spw-dhurran I did not succeed to reproduce the issue
Do you have on all orgs or just a single one ?
The error seems to be with Bulk API:
Hi @nvuillam, yes it doesn't fail if I try and delete say 5 flows. I have it on all orgs. My colleague also installed and had the same issue, we are both sys admins. I wonder if something is being blocked by the company. When it fails it actually deletes some, then blows up coming back for the next batch. This is a recent thing.
@spw-dhurran when you say "recent", does it mean "since the beginning of june", or later ?
We published an update to dramatically improve the execution time for the command in https://github.com/hardisgroupcom/sfdx-hardis/pull/617
Hi @nvuillam he installed the start of August, after I had this issue.
@spw-dhurran please can you have a look in Bulk Data Load Jobs in the setup to check if you see any errors ?
https://help.salesforce.com/s/articleView?id=sf.monitoring_async_api_jobs_details.htm&type=5
Hi @nvuillam I just ran it again, with 14 obsolete flows, no new record in bulk jobs. This is the last one, not me.
Lightning URI event is a table from event monitoring, so indeed it's something else...
@masaner did you see such issues when you implemented the refactoring of the command ?
Lightning URI event is a table from event monitoring, so indeed it's something else...
@masaner did you see such issues when you implemented the refactoring of the command ?
Hey @nvuillam i did not see any issues while i was doing the refactoring. I did some tests and confirmed that the changes were functioning correctly. I can take another look at it if need be.
@spw-dhurran the problem has been declared to jsforce and is in current investigation -> https://github.com/jsforce/jsforce/issues/1571
I added a failsafe that runs the deletion one by one in casse the bulk delete fails: it's longer but it works :)
It will be released in sfdx-hardis v5, but you can already test it using sf plugins install sfdx-hardis@alpha
:)
Note: I also added an enhancement that also deletes (after prompting user) the FlowInterviews that would prevent Flow Versions deletions
? 🦙 Do you confirm you want to delete these 46 flow versions ? ✅ Yes [sfdx-hardis] Error deleting Flow records:[object Object] SfdxError: Error deleting Flow records:[object Object] at handleCallback (/Users/firstname.lastname/.local/share/sf/node_modules/sfdx-hardis/lib/common/utils/apiUtils.js:122:23) at /Users/firstname.lastname/.local/share/sf/node_modules/sfdx-hardis/node_modules/jsforce/lib/promise.js:76:9 at process.processTicksAndRejections (node:internal/process/task_queues:77:11) { cause: undefined, actions: undefined, exitCode: 1 } ERROR running hardis:org:purge:flow: Cannot read properties of undefined (reading '_toRecordResult') [sfdx-hardis] hardis:org:purge:flow execution time 0:00:44.509
Node Version v20.8.0 git version 2.39.3 (Apple Git-146)