{"version":3,"file":"executor-CEYC5o85-CJQF3CRg.mjs","names":[],"sources":["../../adapter-evm-core/dist/executor-CEYC5o85.mjs"],"sourcesContent":["import { d as WriteCompletionDisagreementError } from \"./helpers-CYDHdjrw.mjs\";\nimport { logger } from \"@openzeppelin/ui-utils\";\n\n//#region src/shared/executor.ts\nconst LOG_SYSTEM = \"CapabilityWrite\";\n/**\n* Run a capability write: submit `action` via `executor`, returning its\n* {@link WriteExecutionResult}; on failure, log and rethrow the result of `mapError`.\n*\n* {@link WriteCompletionDisagreementError} is rethrown unchanged (INV-11) so IRS\n* (and other) mappers never wrap a wiring bug as an identity-domain failure.\n*\n* Centralizes the shared control flow so each capability only supplies its\n* error-mapping policy.\n*/\nasync function runCapabilityWrite(params, mapError) {\n\tconst { operation, action, executor, executionConfig, onStatusChange, runtimeApiKey } = params;\n\ttry {\n\t\treturn await executor(action, executionConfig, onStatusChange, runtimeApiKey);\n\t} catch (error) {\n\t\tif (error instanceof WriteCompletionDisagreementError) throw error;\n\t\tlogger.error(LOG_SYSTEM, `${operation} failed:`, error);\n\t\tthrow mapError(error, operation, action.address);\n\t}\n}\n\n//#endregion\nexport { runCapabilityWrite as t };\n//# sourceMappingURL=executor-CEYC5o85.mjs.map"],"mappings":";;;;AAIA,MAAM,aAAa;;;;;;;;;;;AAWnB,eAAe,mBAAmB,QAAQ,UAAU;CACnD,MAAM,EAAE,WAAW,QAAQ,UAAU,iBAAiB,gBAAgB,kBAAkB;AACxF,KAAI;AACH,SAAO,MAAM,SAAS,QAAQ,iBAAiB,gBAAgB,cAAc;UACrE,OAAO;AACf,MAAI,iBAAiB,iCAAkC,OAAM;AAC7D,SAAO,MAAM,YAAY,GAAG,UAAU,WAAW,MAAM;AACvD,QAAM,SAAS,OAAO,WAAW,OAAO,QAAQ"}