@treasuredata/tdx 0.28.2 → 0.28.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/bin.js +1 -1
- package/dist/build-info.json +3 -3
- package/dist/cli-categories.js +1 -1
- package/dist/cli.js +1 -1
- package/dist/commands/activations.js +1 -1
- package/dist/commands/agent-command.js +1 -1
- package/dist/commands/agent-test-command.js +1 -1
- package/dist/commands/api-command.js +1 -1
- package/dist/commands/auth-command.js +1 -1
- package/dist/commands/chat-command.js +1 -1
- package/dist/commands/claude-command.js +1 -1
- package/dist/commands/claude-statusline-command.js +1 -1
- package/dist/commands/claude-usage-command.js +1 -1
- package/dist/commands/command.js +1 -1
- package/dist/commands/connection-command.js +1 -1
- package/dist/commands/databases.js +1 -1
- package/dist/commands/delivery-command.js +1 -1
- package/dist/commands/describe.js +1 -1
- package/dist/commands/engage-campaign-pull-command.js +1 -1
- package/dist/commands/engage-campaign-push-command.js +1 -1
- package/dist/commands/engage-campaign-validate-command.js +1 -1
- package/dist/commands/engage-command.js +1 -1
- package/dist/commands/job-command.js +1 -1
- package/dist/commands/journey-command.js +1 -1
- package/dist/commands/journey-validate-command.js +1 -1
- package/dist/commands/llm-command.js +1 -1
- package/dist/commands/mcp-command.js +1 -1
- package/dist/commands/parent-segment-command.js +1 -1
- package/dist/commands/profile-command.js +1 -1
- package/dist/commands/profiles-command.js +1 -1
- package/dist/commands/query-command.js +1 -1
- package/dist/commands/schedule-command.js +1 -1
- package/dist/commands/segment-command.js +1 -1
- package/dist/commands/segment-create-command.js +1 -1
- package/dist/commands/segment-fields-command.js +1 -1
- package/dist/commands/segment-pull-command.js +1 -1
- package/dist/commands/segment-push-command.js +1 -1
- package/dist/commands/segment-update-command.js +1 -1
- package/dist/commands/segment-use-command.js +1 -1
- package/dist/commands/segment-validate-command.js +1 -1
- package/dist/commands/segments.js +1 -1
- package/dist/commands/show.js +1 -1
- package/dist/commands/status-command.js +1 -1
- package/dist/commands/tables.js +1 -1
- package/dist/commands/unset-command.js +1 -1
- package/dist/commands/use-command.js +1 -1
- package/dist/commands/user-command.js +1 -1
- package/dist/commands/workflow-command.js +1 -1
- package/dist/core/auth.js +1 -1
- package/dist/core/command-output.js +1 -1
- package/dist/core/config.js +1 -1
- package/dist/core/connection-cache.js +1 -1
- package/dist/core/constants.js +1 -1
- package/dist/core/credential-cache.js +1 -1
- package/dist/core/global-context.js +1 -1
- package/dist/core/keychain.js +1 -1
- package/dist/core/profile.js +1 -1
- package/dist/core/project-config.js +1 -1
- package/dist/core/session.js +1 -1
- package/dist/core/user-cache.js +1 -1
- package/dist/core/version.js +1 -1
- package/dist/index.js +1 -1
- package/dist/mcp/server.js +1 -1
- package/dist/mcp/tools/index.js +1 -1
- package/dist/mcp/tools/tdx-run.js +1 -1
- package/dist/mcp/tools/tdx-search.js +1 -1
- package/dist/mcp/utils.js +1 -1
- package/dist/proxy/claude-usage-tracker.js +1 -1
- package/dist/proxy/passthrough-server.js +1 -1
- package/dist/proxy/sse-usage-parser.js +1 -1
- package/dist/sdk/agent/agent-config.js +1 -1
- package/dist/sdk/agent/agent-ref-parser.js +1 -1
- package/dist/sdk/agent/agent-yaml.js +1 -1
- package/dist/sdk/agent/test/evaluator.js +1 -1
- package/dist/sdk/agent/test/executor.js +1 -1
- package/dist/sdk/agent/test/index.js +1 -1
- package/dist/sdk/agent/test/output.js +1 -1
- package/dist/sdk/agent/test/parser.js +1 -1
- package/dist/sdk/agent/tool-target-registry.js +1 -1
- package/dist/sdk/api.js +1 -1
- package/dist/sdk/client/cdp-api-client.js +1 -1
- package/dist/sdk/client/delivery-api-client.js +1 -1
- package/dist/sdk/client/endpoints.js +1 -1
- package/dist/sdk/client/engage-api-client.js +1 -1
- package/dist/sdk/client/http-client.js +1 -1
- package/dist/sdk/client/llm-api-client.js +1 -1
- package/dist/sdk/client/rate-limiter.js +1 -1
- package/dist/sdk/client/td-api-client.js +1 -1
- package/dist/sdk/client/trino-api-client.js +1 -1
- package/dist/sdk/client/workflow-client.js +1 -1
- package/dist/sdk/connection-validator.js +1 -1
- package/dist/sdk/connection.js +1 -1
- package/dist/sdk/delivery.js +1 -1
- package/dist/sdk/engage/campaign-pull.js +1 -1
- package/dist/sdk/engage/campaign-push.js +1 -1
- package/dist/sdk/engage/campaign-validator.js +1 -1
- package/dist/sdk/engage/campaign-yaml.js +1 -1
- package/dist/sdk/engage/types/campaign-def.js +1 -1
- package/dist/sdk/engage/types/campaign-schema.js +1 -1
- package/dist/sdk/engage.js +1 -1
- package/dist/sdk/errors.js +1 -1
- package/dist/sdk/index.js +1 -1
- package/dist/sdk/io/index.js +1 -1
- package/dist/sdk/io/node-filesystem.js +1 -1
- package/dist/sdk/job.js +1 -1
- package/dist/sdk/journey.js +1 -1
- package/dist/sdk/llm/chat-cache.js +1 -1
- package/dist/sdk/llm/index.js +1 -1
- package/dist/sdk/llm/llm-backup-utils.js +1 -1
- package/dist/sdk/llm/model-factors.js +1 -1
- package/dist/sdk/personalization.js +1 -1
- package/dist/sdk/query/index.js +1 -1
- package/dist/sdk/query/sql-parser.js +1 -1
- package/dist/sdk/realtime.js +1 -1
- package/dist/sdk/schedule.js +1 -1
- package/dist/sdk/segment/child-segment-yaml.js +1 -1
- package/dist/sdk/segment/fields-display.js +1 -1
- package/dist/sdk/segment/file-discovery.js +1 -1
- package/dist/sdk/segment/journey-utils.js +1 -1
- package/dist/sdk/segment/journey-validator.js +1 -1
- package/dist/sdk/segment/journey-yaml.js +1 -1
- package/dist/sdk/segment/parent-segment-preview.js +1 -1
- package/dist/sdk/segment/parent-segment-yaml.js +1 -1
- package/dist/sdk/segment/pull-workflow.js +1 -1
- package/dist/sdk/segment/push-recovery.js +1 -1
- package/dist/sdk/segment/push-workflow.js +1 -1
- package/dist/sdk/segment/resolution-context.js +1 -1
- package/dist/sdk/segment/segment-path-parser.js +1 -1
- package/dist/sdk/segment/segment-ref-parser.js +1 -1
- package/dist/sdk/segment/target-resolution.js +1 -1
- package/dist/sdk/segment/tdx-config.js +1 -1
- package/dist/sdk/segment/validate-files.js +1 -1
- package/dist/sdk/segment/yaml-validator.js +1 -1
- package/dist/sdk/segment.js +1 -1
- package/dist/sdk/types/index.js +1 -1
- package/dist/sdk/types/progress.js +1 -1
- package/dist/sdk/user.js +1 -1
- package/dist/sdk/util/format-detector.js +1 -1
- package/dist/sdk/util/formatters.js +1 -1
- package/dist/sdk/util/index.js +1 -1
- package/dist/sdk/util/tree-formatter.js +1 -1
- package/dist/sdk/workflow/archive-validation.js +1 -1
- package/dist/sdk/workflow/clone-workflow.js +1 -1
- package/dist/sdk/workflow/index.js +1 -1
- package/dist/sdk/workflow/pull-workflow.js +1 -1
- package/dist/sdk/workflow/push-workflow.js +1 -1
- package/dist/sdk/workflow/tdx-config.js +1 -1
- package/dist/sdk/workflow/workflow-utils.js +1 -1
- package/dist/test-utils/command-runner.js +1 -1
- package/dist/test-utils/factories.js +1 -1
- package/dist/test-utils/fixtures.js +1 -1
- package/dist/test-utils/http-mock.js +1 -1
- package/dist/test-utils/index.js +1 -1
- package/dist/utils/async.js +1 -1
- package/dist/utils/colors.js +1 -1
- package/dist/utils/diff.js +1 -1
- package/dist/utils/file-permissions.js +1 -1
- package/dist/utils/global-cache.js +1 -1
- package/dist/utils/json-loader.js +1 -1
- package/dist/utils/local-cache.js +1 -1
- package/dist/utils/logger/formatters/default-formatter.js +1 -1
- package/dist/utils/logger/formatters/index.js +1 -1
- package/dist/utils/logger/handlers/console-handler.js +1 -1
- package/dist/utils/logger/handlers/file-handler.js +1 -1
- package/dist/utils/logger/handlers/index.js +1 -1
- package/dist/utils/logger/handlers/null-handler.js +1 -1
- package/dist/utils/logger/index.js +1 -1
- package/dist/utils/logger/logger.js +1 -1
- package/dist/utils/logger/types.js +1 -1
- package/dist/utils/option-validation.js +1 -1
- package/dist/utils/process.js +1 -1
- package/dist/utils/prompt.js +1 -1
- package/dist/utils/spinner.js +1 -1
- package/dist/utils/sse-parser.js +1 -1
- package/dist/utils/string-utils.js +1 -1
- package/dist/utils/table-ref-parser.js +1 -1
- package/dist/utils/tdx-logger.js +1 -1
- package/dist/utils/version-check.js +1 -1
- package/package.json +1 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
(function(_0x5b5258,_0x38bd94){const _0x5e5de5=a119_0x1f26,_0x29e862=_0x5b5258();while(!![]){try{const _0x308362=parseInt(_0x5e5de5(0xff))/0x1*(parseInt(_0x5e5de5(0x102))/0x2)+parseInt(_0x5e5de5(0xfd))/0x3*(parseInt(_0x5e5de5(0x10d))/0x4)+-parseInt(_0x5e5de5(0x10c))/0x5+-parseInt(_0x5e5de5(0x103))/0x6+parseInt(_0x5e5de5(0x10e))/0x7*(-parseInt(_0x5e5de5(0x100))/0x8)+parseInt(_0x5e5de5(0x106))/0x9*(parseInt(_0x5e5de5(0x10b))/0xa)+-parseInt(_0x5e5de5(0x108))/0xb*(-parseInt(_0x5e5de5(0x10a))/0xc);if(_0x308362===_0x38bd94)break;else _0x29e862['push'](_0x29e862['shift']());}catch(_0x4737fc){_0x29e862['push'](_0x29e862['shift']());}}}(a119_0x2fb8,0x4f594));import{readdirSync,statSync}from'fs';import a119_0xa0eac from'path';export function findYamlFiles(_0x426579){const _0x4d23bc=[];function _0x3d069f(_0x332099){const _0x4cab0d=a119_0x1f26,_0x2bec81=readdirSync(_0x332099,{'withFileTypes':!![]});for(const _0x2ef19a of _0x2bec81){const _0x1d16ec=a119_0xa0eac[_0x4cab0d(0x107)](_0x332099,_0x2ef19a[_0x4cab0d(0x111)]);if(_0x2ef19a[_0x4cab0d(0x114)]())_0x3d069f(_0x1d16ec);else(_0x2ef19a['name']['endsWith'](_0x4cab0d(0x109))||_0x2ef19a[_0x4cab0d(0x111)][_0x4cab0d(0x105)]('.yaml'))&&_0x4d23bc['push'](_0x1d16ec);}}return _0x3d069f(_0x426579),_0x4d23bc;}export function discoverYamlFiles(_0x34e1b4){const _0x42db61=a119_0x1f26,_0x5dea6e=findYamlFiles(_0x34e1b4);return _0x5dea6e[_0x42db61(0x113)](_0x4dd6ea=>{const _0x1977e7=_0x42db61,_0x3b7a72=a119_0xa0eac[_0x1977e7(0x110)](_0x34e1b4,_0x4dd6ea),_0x4c84eb=a119_0xa0eac[_0x1977e7(0x10f)](_0x3b7a72);return{'absolutePath':_0x4dd6ea,'relativePath':_0x3b7a72,'folderPath':_0x4c84eb==='.'?'':_0x4c84eb};});}export function isYamlFile(_0x5448a5){const _0x3795bc=a119_0x1f26;try{const _0x3676bf=statSync(_0x5448a5);if(!_0x3676bf[_0x3795bc(0xfe)]())return![];const _0x5e4e14=a119_0xa0eac[_0x3795bc(0x112)](_0x5448a5)[_0x3795bc(0x101)]();return _0x5e4e14==='.yml'||_0x5e4e14===_0x3795bc(0x104);}catch{return![];}}function a119_0x1f26(_0x2f0a9b,_0x3ef395){_0x2f0a9b=_0x2f0a9b-0xfd;const _0x2fb89b=a119_0x2fb8();let _0x1f2630=_0x2fb89b[_0x2f0a9b];return _0x1f2630;}function a119_0x2fb8(){const _0x238e4a=['27444KerjQD','190gYOBjs','1296270hlrYyX','736LUtgdn','1124683UHyFCW','dirname','relative','name','extname','map','isDirectory','5565KAnYRp','isFile','107782KFOcOE','24KeJobW','toLowerCase','6VitgGP','1542714OJrZsh','.yaml','endsWith','215613inlcll','join','979SwtJna','.yml'];a119_0x2fb8=function(){return _0x238e4a;};return a119_0x2fb8();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(_0x4433d2,_0x11dac4){const _0x11e047=a120_0x4781,_0x2f6ab6=_0x4433d2();while(!![]){try{const _0x51a4d4=parseInt(_0x11e047(0x1ba))/0x1+parseInt(_0x11e047(0x1a6))/0x2*(parseInt(_0x11e047(0x19e))/0x3)+parseInt(_0x11e047(0x1a8))/0x4+-parseInt(_0x11e047(0x1a0))/0x5+parseInt(_0x11e047(0x1c8))/0x6+parseInt(_0x11e047(0x1db))/0x7*(-parseInt(_0x11e047(0x1b2))/0x8)+-parseInt(_0x11e047(0x1b0))/0x9*(parseInt(_0x11e047(0x1c6))/0xa);if(_0x51a4d4===_0x11dac4)break;else _0x2f6ab6['push'](_0x2f6ab6['shift']());}catch(_0x5b5ce0){_0x2f6ab6['push'](_0x2f6ab6['shift']());}}}(a120_0x2e4f,0x4ea8f));import{serializeRule,deepSortObject}from'./child-segment-yaml.js';export const SEGMENT_KIND_JOURNEY=0x3;const MAX_MAPPING_CHAIN_DEPTH=0xa;export function sanitizeYamlKey(_0x12340d){const _0x43812e=a120_0x4781;return _0x12340d[_0x43812e(0x1c2)]()[_0x43812e(0x19d)](/\s+/g,'_')[_0x43812e(0x19d)](/[^a-z0-9_]/g,'')[_0x43812e(0x19d)](/_+/g,'_')[_0x43812e(0x19d)](/^_|_$/g,'');}export function generateJourneyLocalName(_0xf119d5){const _0x5a1ffa=a120_0x4781,_0x2edd51=_0xf119d5['match'](/^journey_([a-z_]+)_([0-9a-f-]+)$/i);if(_0x2edd51){const _0x50d1c4=_0x2edd51[0x1][_0x5a1ffa(0x1c2)](),_0x4246f6=_0x2edd51[0x2],_0x456c22=_0x4246f6[_0x5a1ffa(0x19d)](/-/g,'')[_0x5a1ffa(0x1de)](0x0,0x4)['toLowerCase']();return _0x50d1c4+'_'+_0x456c22;}const _0x2e53dd=_0xf119d5['match'](/^journey_\d+_stage_\d+_step_([0-9a-f-]+)_([a-z_]+)$/i);if(_0x2e53dd){const _0x103628=_0x2e53dd[0x1],_0x3f459d=_0x2e53dd[0x2]['toLowerCase'](),_0x2a6837=_0x103628[_0x5a1ffa(0x19d)](/-/g,'')['slice'](0x0,0x4)['toLowerCase']();return _0x3f459d+'_'+_0x2a6837;}return undefined;}function stableStringify(_0x227af8){const _0x717dcc=a120_0x4781;if(Array[_0x717dcc(0x1d1)](_0x227af8))return'['+_0x227af8['map'](_0x55ecf0=>stableStringify(_0x55ecf0))[_0x717dcc(0x1ec)](',')+']';if(_0x227af8&&typeof _0x227af8==='object'){const _0x3de9a0=_0x227af8,_0x1516fd=Object[_0x717dcc(0x1b8)](_0x3de9a0)[_0x717dcc(0x1d8)](),_0x41e95=_0x1516fd[_0x717dcc(0x1b9)](_0x3e24cf=>'\x22'+_0x3e24cf+'\x22:'+stableStringify(_0x3de9a0[_0x3e24cf]));return'{'+_0x41e95['join'](',')+'}';}const _0x3c74b3=JSON[_0x717dcc(0x1d7)](_0x227af8);return _0x3c74b3===undefined?_0x717dcc(0x1ee):_0x3c74b3;}export function consolidateActivationsByContent(_0x518226){const _0x520b98=a120_0x4781,_0x13aa5d={},_0x36a437=new Map(),_0x1b25ac=new Map();for(const _0x6b8d4d of _0x518226){if(!_0x6b8d4d)continue;for(const [_0x3f976c,_0x2eab33]of Object[_0x520b98(0x1c3)](_0x6b8d4d)){const _0x45aca6={'connection':_0x2eab33['connection'],..._0x2eab33[_0x520b98(0x1d5)]!==undefined&&{'all_columns':_0x2eab33['all_columns']},..._0x2eab33[_0x520b98(0x19f)]!==undefined&&{'columns':_0x2eab33[_0x520b98(0x19f)]},..._0x2eab33[_0x520b98(0x1ab)]!==undefined&&{'behavior':_0x2eab33[_0x520b98(0x1ab)]},..._0x2eab33[_0x520b98(0x1a2)]!==undefined&&{'schedule':_0x2eab33[_0x520b98(0x1a2)]},..._0x2eab33[_0x520b98(0x1cc)]!==undefined&&{'notification':_0x2eab33[_0x520b98(0x1cc)]},..._0x2eab33[_0x520b98(0x1ad)]!==undefined&&{'connector_config':_0x2eab33['connector_config']},..._0x2eab33['activation_template_id']!==undefined&&{'activation_template_id':_0x2eab33[_0x520b98(0x1a4)]}},_0x247580=stableStringify(_0x45aca6),_0x300801=_0x1b25ac[_0x520b98(0x1dd)](_0x247580);_0x300801?_0x36a437[_0x520b98(0x1f0)](_0x3f976c,_0x300801):(_0x13aa5d[_0x3f976c]=_0x2eab33,_0x36a437['set'](_0x3f976c,_0x3f976c),_0x1b25ac[_0x520b98(0x1f0)](_0x247580,_0x3f976c));}}return{'merged':_0x13aa5d,'nameMapping':_0x36a437};}function a120_0x2e4f(){const _0x170f6e=['description','launched','max','version','isArray','wait','entry_criteria','steps','all_columns','push','stringify','sort','segment','conditions','574Idswyq','with','get','slice','attributes','some','from','segments','bundle_id','reentry','nameMapping','branches','merged','journeyBundleName','exclude','object','journey','join','bundle_name','null','type','set','item','journeyStages','replace','33LJFYlC','columns','1339055GgoFMA','versionNumber','schedule','activation','activation_template_id','values','47746VKeizC','index','2080528UQYNqI','string','rule','behavior','trim','connector_config','activations','condition','234VMqHdn','version_number','32304CUQJqO','.yaml','milestone','latest','exit_criteria','endsWith','keys','map','357760UVfNyu','find','has','yaml','.yml','include','startsWith','versions','toLowerCase','entries','goal','decision_point','303020WvcGQc','length','3410850TPPtGp','name','stages','journeys','notification'];a120_0x2e4f=function(){return _0x170f6e;};return a120_0x2e4f();}export function updateActivationReferences(_0x2b7700,_0x34c50b){const _0x2eada4=a120_0x4781;if(!_0x2b7700)return;for(const _0x1cb292 of _0x2b7700){if(!_0x1cb292[_0x2eada4(0x1d4)])continue;for(const _0x32ee83 of _0x1cb292[_0x2eada4(0x1d4)]){if(_0x32ee83['type']==='activation'&&_0x32ee83['with']?.[_0x2eada4(0x1a3)]){const _0x4f8777=_0x34c50b[_0x2eada4(0x1dd)](_0x32ee83['with'][_0x2eada4(0x1a3)]);_0x4f8777&&_0x4f8777!==_0x32ee83[_0x2eada4(0x1dc)][_0x2eada4(0x1a3)]&&(_0x32ee83[_0x2eada4(0x1dc)]['activation']=_0x4f8777);}}}}export function consolidateSegmentsByContent(_0x5b0049,_0x4799a9){const _0x1bf47b=a120_0x4781,_0xe215c5={},_0x49e58e=new Map(),_0x1f301d=new Map();for(const _0x1bd374 of _0x5b0049){if(!_0x1bd374)continue;for(const [_0x4f7f2e,_0x520b34]of Object['entries'](_0x1bd374)){if(!_0x520b34[_0x1bf47b(0x1aa)]){_0xe215c5[_0x4f7f2e]=_0x520b34,_0x49e58e['set'](_0x4f7f2e,_0x4f7f2e);continue;}const _0x1c96bb=_0x520b34['description']&&_0x520b34[_0x1bf47b(0x1cd)][_0x1bf47b(0x1ac)]()?_0x520b34['description']:undefined,_0x1c349c=JSON[_0x1bf47b(0x1d7)]({'description':_0x1c96bb,'rule':deepSortObject(_0x520b34['rule'])}),_0x2f9fef=_0x1f301d[_0x1bf47b(0x1dd)](_0x1c349c);if(_0x2f9fef){const _0x253aaa={..._0x520b34[_0x1bf47b(0x1cd)]!==undefined&&{'description':_0x520b34[_0x1bf47b(0x1cd)]},'rule':_0x520b34['rule']?deepSortObject(_0x520b34['rule']):_0x520b34[_0x1bf47b(0x1aa)]};if(_0x4f7f2e<_0x2f9fef){_0xe215c5[_0x4f7f2e]=_0x253aaa,delete _0xe215c5[_0x2f9fef];for(const [_0xb29483,_0x1fd9ac]of _0x49e58e[_0x1bf47b(0x1c3)]()){_0x1fd9ac===_0x2f9fef&&_0x49e58e['set'](_0xb29483,_0x4f7f2e);}_0x49e58e['set'](_0x4f7f2e,_0x4f7f2e),_0x1f301d['set'](_0x1c349c,_0x4f7f2e);}else _0xe215c5[_0x2f9fef]=_0x253aaa,_0x49e58e[_0x1bf47b(0x1f0)](_0x4f7f2e,_0x2f9fef);}else{let _0x56d00b=_0x4f7f2e;if(_0x4799a9){const _0x4020b5=_0x4799a9[_0x1bf47b(0x1dd)](_0x1c349c);_0x4020b5&&_0x4020b5[_0x1bf47b(0x1c7)]>0x0&&(_0x56d00b=_0x4020b5[_0x1bf47b(0x1de)]()['sort']()[0x0]);}const _0x1e4de4={..._0x520b34['description']!==undefined&&{'description':_0x520b34[_0x1bf47b(0x1cd)]},'rule':_0x520b34['rule']?deepSortObject(_0x520b34[_0x1bf47b(0x1aa)]):_0x520b34[_0x1bf47b(0x1aa)]};_0xe215c5[_0x56d00b]=_0x1e4de4,_0x49e58e[_0x1bf47b(0x1f0)](_0x4f7f2e,_0x56d00b),_0x1f301d[_0x1bf47b(0x1f0)](_0x1c349c,_0x56d00b);}}}return{'merged':_0xe215c5,'nameMapping':_0x49e58e};}export function updateSegmentReferences(_0x214f17,_0x50d4fa){const _0x2bf582=a120_0x4781;if(!_0x214f17)return;for(const _0x899e6a of _0x214f17){if(_0x899e6a[_0x2bf582(0x1d3)]?.[_0x2bf582(0x1d9)]){const _0x41a639=_0x50d4fa[_0x2bf582(0x1dd)](_0x899e6a[_0x2bf582(0x1d3)][_0x2bf582(0x1d9)]);_0x41a639&&(_0x899e6a['entry_criteria']['segment']=_0x41a639);}if(_0x899e6a[_0x2bf582(0x1b6)])for(const _0x21fa98 of _0x899e6a[_0x2bf582(0x1b6)]){if(_0x21fa98[_0x2bf582(0x1d9)]){const _0x46001b=_0x50d4fa[_0x2bf582(0x1dd)](_0x21fa98[_0x2bf582(0x1d9)]);_0x46001b&&(_0x21fa98[_0x2bf582(0x1d9)]=_0x46001b);}}if(_0x899e6a['milestone']?.[_0x2bf582(0x1d9)]){const _0x5becaf=_0x50d4fa[_0x2bf582(0x1dd)](_0x899e6a['milestone'][_0x2bf582(0x1d9)]);_0x5becaf&&(_0x899e6a[_0x2bf582(0x1b4)]['segment']=_0x5becaf);}if(_0x899e6a['steps'])for(const _0x1f38b8 of _0x899e6a[_0x2bf582(0x1d4)]){if(_0x1f38b8[_0x2bf582(0x1ef)]===_0x2bf582(0x1c5)&&_0x1f38b8[_0x2bf582(0x1dc)]?.[_0x2bf582(0x1e6)])for(const _0x229064 of _0x1f38b8['with'][_0x2bf582(0x1e6)]){if(_0x229064['segment']){const _0x47ae82=_0x50d4fa['get'](_0x229064[_0x2bf582(0x1d9)]);_0x47ae82&&(_0x229064['segment']=_0x47ae82);}}if(_0x1f38b8[_0x2bf582(0x1ef)]==='wait'&&_0x1f38b8[_0x2bf582(0x1dc)]?.[_0x2bf582(0x1af)]?.[_0x2bf582(0x1d9)]){const _0x92f244=_0x50d4fa[_0x2bf582(0x1dd)](_0x1f38b8[_0x2bf582(0x1dc)][_0x2bf582(0x1af)][_0x2bf582(0x1d9)]);_0x92f244&&(_0x1f38b8[_0x2bf582(0x1dc)][_0x2bf582(0x1af)][_0x2bf582(0x1d9)]=_0x92f244);}}}}export function updateSegmentRefsInSegments(_0x2a5e75,_0xaf7304){const _0x50d0a5=a120_0x4781;for(const _0x5c507d of Object[_0x50d0a5(0x1a5)](_0x2a5e75)){_0x5c507d[_0x50d0a5(0x1aa)]&&updateSegmentRefsInRule(_0x5c507d[_0x50d0a5(0x1aa)],_0xaf7304);}}function updateSegmentRefsInRule(_0x553fed,_0x294236){const _0xf3ef16=a120_0x4781;if(_0x553fed===null||typeof _0x553fed!==_0xf3ef16(0x1ea))return;if(Array[_0xf3ef16(0x1d1)](_0x553fed)){for(const _0x296326 of _0x553fed){updateSegmentRefsInRule(_0x296326,_0x294236);}return;}const _0x204802=_0x553fed;if((_0x204802[_0xf3ef16(0x1ef)]===_0xf3ef16(0x1bf)||_0x204802[_0xf3ef16(0x1ef)]===_0xf3ef16(0x1e9))&&typeof _0x204802[_0xf3ef16(0x1d9)]===_0xf3ef16(0x1a9)){const _0x4b4b43=_0x294236[_0xf3ef16(0x1dd)](_0x204802['segment']);_0x4b4b43&&(_0x204802[_0xf3ef16(0x1d9)]=_0x4b4b43);}if(_0x204802[_0xf3ef16(0x1da)]&&Array[_0xf3ef16(0x1d1)](_0x204802[_0xf3ef16(0x1da)]))for(const _0x4a3797 of _0x204802[_0xf3ef16(0x1da)]){updateSegmentRefsInRule(_0x4a3797,_0x294236);}}export function buildJourneysArray(_0x172685){const _0x5d4d78=a120_0x4781,_0x3f5071=Math[_0x5d4d78(0x1cf)](..._0x172685[_0x5d4d78(0x1b9)](_0x6fcc06=>_0x6fcc06[_0x5d4d78(0x1f1)][_0x5d4d78(0x1a1)]||0x0));return _0x172685[_0x5d4d78(0x1b9)](_0x3a585b=>{const _0x35ce0c=_0x5d4d78,_0x16bd77=(_0x3a585b[_0x35ce0c(0x1f1)][_0x35ce0c(0x1a1)]||0x0)===_0x3f5071,_0x312513=_0x3a585b['yaml'][_0x35ce0c(0x1cb)]?.[0x0],_0xd39370={'version':_0x312513?.[_0x35ce0c(0x1d0)]||_0x3a585b[_0x35ce0c(0x1bd)][_0x35ce0c(0x1d0)]||_0x3a585b[_0x35ce0c(0x1f1)][_0x35ce0c(0x1c9)],'state':_0x3a585b[_0x35ce0c(0x1f1)]['state']===_0x35ce0c(0x1ce)?'launched':'draft','stages':_0x312513?.[_0x35ce0c(0x1ca)]||_0x3a585b[_0x35ce0c(0x1bd)][_0x35ce0c(0x1ca)]||[],'id':_0x312513?.['id']||_0x3a585b['yaml']['id'],'version_number':_0x312513?.[_0x35ce0c(0x1b1)]||_0x3a585b[_0x35ce0c(0x1bd)][_0x35ce0c(0x1b1)]};return _0x16bd77&&(_0xd39370[_0x35ce0c(0x1b5)]=!![]),_0xd39370;});}export function buildMergedJourneyDef(_0x2ef41d,_0x1fd1de){const _0x1ef759=a120_0x4781,_0x3ed762=_0x2ef41d[0x0]['yaml'],_0x4a0699=buildJourneysArray(_0x2ef41d),{merged:_0x1f61b7,nameMapping:_0x135cb4}=consolidateSegmentsByContent(_0x2ef41d[_0x1ef759(0x1b9)](_0x1d1a11=>_0x1d1a11[_0x1ef759(0x1bd)][_0x1ef759(0x1e2)]),_0x1fd1de);updateSegmentRefsInSegments(_0x1f61b7,_0x135cb4);const _0x3c89d7=Array[_0x1ef759(0x1e1)](_0x135cb4['entries']())[_0x1ef759(0x1e0)](([_0x2bfb3f,_0x3f0ace])=>_0x2bfb3f!==_0x3f0ace&&_0x2bfb3f[_0x1ef759(0x1c0)](_0x1ef759(0x1d3)));let _0x1ea2fe=_0x1f61b7,_0x5f0da4=new Map();if(_0x3c89d7){const _0x423bce=consolidateSegmentsByContent([_0x1f61b7],_0x1fd1de);_0x1ea2fe=_0x423bce[_0x1ef759(0x1e7)],_0x5f0da4=_0x423bce[_0x1ef759(0x1e5)];}const _0x6ce0c3=new Map(_0x135cb4);for(const [_0x26d3f6,_0x1755e0]of _0x5f0da4['entries']()){_0x6ce0c3['set'](_0x26d3f6,_0x1755e0);}for(const [_0x1ad083,_0x3247fa]of _0x6ce0c3[_0x1ef759(0x1c3)]()){let _0x4ed707=_0x3247fa,_0x2a0447=0x0;while(_0x6ce0c3[_0x1ef759(0x1bc)](_0x4ed707)&&_0x6ce0c3[_0x1ef759(0x1dd)](_0x4ed707)!==_0x4ed707&&_0x2a0447<MAX_MAPPING_CHAIN_DEPTH){_0x4ed707=_0x6ce0c3[_0x1ef759(0x1dd)](_0x4ed707),_0x2a0447++;}_0x4ed707!==_0x3247fa&&_0x6ce0c3[_0x1ef759(0x1f0)](_0x1ad083,_0x4ed707);}for(const _0x121329 of _0x4a0699){updateSegmentReferences(_0x121329[_0x1ef759(0x1ca)],_0x6ce0c3);}const {merged:_0x54c3e0,nameMapping:_0x405f05}=consolidateActivationsByContent(_0x2ef41d['map'](_0x3abfbf=>_0x3abfbf[_0x1ef759(0x1bd)][_0x1ef759(0x1ae)]));for(const _0x3477c0 of _0x4a0699){updateActivationReferences(_0x3477c0[_0x1ef759(0x1ca)],_0x405f05);}let _0x103e80=_0x3ed762[_0x1ef759(0x1c4)];if(_0x103e80?.[_0x1ef759(0x1d9)]){const _0x585167=_0x6ce0c3['get'](_0x103e80['segment']);_0x585167&&(_0x103e80={..._0x103e80,'segment':_0x585167});}for(const _0x54da01 of _0x4a0699){if(_0x54da01['goal']?.[_0x1ef759(0x1d9)]){const _0x3a5744=_0x6ce0c3[_0x1ef759(0x1dd)](_0x54da01[_0x1ef759(0x1c4)]['segment']);_0x3a5744&&(_0x54da01[_0x1ef759(0x1c4)]={..._0x54da01['goal'],'segment':_0x3a5744});}}return{'type':_0x1ef759(0x1eb),'name':_0x3ed762[_0x1ef759(0x1c9)],'description':_0x3ed762[_0x1ef759(0x1cd)],'goal':_0x103e80,'reentry':_0x3ed762[_0x1ef759(0x1e4)],'segments':Object['keys'](_0x1ea2fe)[_0x1ef759(0x1c7)]>0x0?_0x1ea2fe:undefined,'activations':Object[_0x1ef759(0x1b8)](_0x54c3e0)[_0x1ef759(0x1c7)]>0x0?_0x54c3e0:undefined,'journeys':_0x4a0699,'bundle_id':_0x3ed762[_0x1ef759(0x1e3)],'bundle_name':_0x3ed762[_0x1ef759(0x1ed)]};}export function createJumpTargetCache(){return new Map();}export async function resolveJumpTarget(_0x280d5d,_0x4952a3,_0x1229c9,_0x4d0c97){const _0x3e44ae=a120_0x4781,_0x17b9a3=_0x280d5d+':'+_0x4952a3,_0x4695af=_0x1229c9[_0x3e44ae(0x1dd)](_0x17b9a3);if(_0x4695af)return _0x4695af;const _0x172d9f=await _0x4d0c97(_0x280d5d),_0x3e5fee=_0x172d9f[_0x3e44ae(0x1df)][_0x3e44ae(0x1e8)]||_0x172d9f['attributes'][_0x3e44ae(0x1c9)],_0x4ae6b7=_0x172d9f[_0x3e44ae(0x1df)][_0x3e44ae(0x19c)][_0x3e44ae(0x1bb)](_0x465193=>String(_0x465193['id'])===String(_0x4952a3)),_0x198109=_0x4ae6b7?.[_0x3e44ae(0x1c9)]||_0x4952a3,_0x5b7f83={'journeyName':_0x3e5fee,'stageName':_0x198109};return _0x1229c9[_0x3e44ae(0x1f0)](_0x17b9a3,_0x5b7f83),_0x5b7f83;}export function formatApiJourneyName(_0x37b052,_0x33d4b1){return _0x33d4b1+'\x20('+_0x37b052+')';}export function isLocalJourneyRef(_0x1ad554){const _0x5bd5c2=a120_0x4781;return _0x1ad554[_0x5bd5c2(0x1b7)](_0x5bd5c2(0x1be))||_0x1ad554[_0x5bd5c2(0x1b7)](_0x5bd5c2(0x1b3));}export function buildLocalRuleToNameMapping(_0x8c221a){const _0x16d66e=a120_0x4781,_0xee5b42=new Map();if(!_0x8c221a)return _0xee5b42;for(const [_0x4ced0d,_0x2f30ba]of Object[_0x16d66e(0x1c3)](_0x8c221a)){if(_0x2f30ba[_0x16d66e(0x1aa)]){const _0x12cc38=serializeRule(_0x2f30ba['rule']),_0x5294c3=_0xee5b42[_0x16d66e(0x1dd)](_0x12cc38)||[];_0x5294c3[_0x16d66e(0x1d6)](_0x4ced0d),_0xee5b42['set'](_0x12cc38,_0x5294c3);}}return _0xee5b42;}function a120_0x4781(_0x28e09c,_0x4325f2){_0x28e09c=_0x28e09c-0x19c;const _0x2e4fab=a120_0x2e4f();let _0x4781fd=_0x2e4fab[_0x28e09c];return _0x4781fd;}export function buildLocalRuleToNameMappingFromJourney(_0x269c92){const _0x98ee9c=a120_0x4781,_0x1751dc=_0x269c92[_0x98ee9c(0x1e2)];if(!_0x1751dc)return new Map();const _0x32d1c8=collectSegmentUsageCounts(_0x269c92),_0x565559=new Map();let _0x345b73=0x0;for(const [_0x3d2208,_0x593ef9]of Object['entries'](_0x1751dc)){if(!_0x593ef9[_0x98ee9c(0x1aa)]){_0x345b73++;continue;}const _0x5c58f5=serializeRule(_0x593ef9[_0x98ee9c(0x1aa)]),_0x26b3d1=_0x565559['get'](_0x5c58f5)||[];_0x26b3d1[_0x98ee9c(0x1d6)]({'name':_0x3d2208,'index':_0x345b73}),_0x565559['set'](_0x5c58f5,_0x26b3d1),_0x345b73++;}const _0x23b4eb=new Map();for(const [_0x4118f3,_0x13a559]of _0x565559){const _0x18f000=_0x13a559[_0x98ee9c(0x1de)]()['sort']((_0x518aaf,_0x35c965)=>{const _0x3502a9=_0x98ee9c,_0x304477=_0x32d1c8['get'](_0x518aaf['name'])||0x0,_0xc00f24=_0x32d1c8[_0x3502a9(0x1dd)](_0x35c965[_0x3502a9(0x1c9)])||0x0;if(_0x304477!==_0xc00f24)return _0xc00f24-_0x304477;return _0x518aaf['index']-_0x35c965[_0x3502a9(0x1a7)];})[_0x98ee9c(0x1b9)](_0x1324ec=>_0x1324ec['name']);_0x23b4eb['set'](_0x4118f3,_0x18f000);}return _0x23b4eb;}export function collectSegmentUsageCounts(_0x40a895){const _0x477786=a120_0x4781,_0x3a283a=new Map(),_0x2d0766=_0x3a05bc=>{const _0x3c77eb=a120_0x4781;if(!_0x3a05bc)return;_0x3a283a[_0x3c77eb(0x1f0)](_0x3a05bc,(_0x3a283a[_0x3c77eb(0x1dd)](_0x3a05bc)||0x0)+0x1);},_0x2a5ae4=_0x1f4d5d=>{const _0x2acab4=a120_0x4781;for(const _0x5c87e0 of _0x1f4d5d){_0x2d0766(_0x5c87e0[_0x2acab4(0x1d3)]?.[_0x2acab4(0x1d9)]);if(_0x5c87e0['exit_criteria'])for(const _0x5567d0 of _0x5c87e0[_0x2acab4(0x1b6)]){_0x2d0766(_0x5567d0[_0x2acab4(0x1d9)]);}_0x2d0766(_0x5c87e0[_0x2acab4(0x1b4)]?.[_0x2acab4(0x1d9)]);if(_0x5c87e0[_0x2acab4(0x1d4)])for(const _0x3965b9 of _0x5c87e0[_0x2acab4(0x1d4)]){if(_0x3965b9[_0x2acab4(0x1ef)]===_0x2acab4(0x1c5))for(const _0xf19efb of _0x3965b9[_0x2acab4(0x1dc)][_0x2acab4(0x1e6)]){_0x2d0766(_0xf19efb['segment']);}else _0x3965b9['type']===_0x2acab4(0x1d2)&&_0x2d0766(_0x3965b9[_0x2acab4(0x1dc)][_0x2acab4(0x1af)]?.[_0x2acab4(0x1d9)]);}}};_0x2d0766(_0x40a895['goal']?.[_0x477786(0x1d9)]);if(_0x40a895['journeys'])for(const _0x1f9e9a of _0x40a895[_0x477786(0x1cb)]){_0x2d0766(_0x1f9e9a['goal']?.['segment']),_0x2a5ae4(_0x1f9e9a['stages']);}_0x40a895[_0x477786(0x1ca)]&&_0x2a5ae4(_0x40a895[_0x477786(0x1ca)]);if(_0x40a895[_0x477786(0x1c1)])for(const _0x3cc93c of _0x40a895['versions']){_0x2a5ae4(_0x3cc93c[_0x477786(0x1ca)]);}return _0x3a283a;}
|
|
1
|
+
(function(_0x118615,_0x103666){const _0x15d7df=a120_0x9cd4,_0x44cfea=_0x118615();while(!![]){try{const _0x2f6e17=parseInt(_0x15d7df(0x8b))/0x1*(parseInt(_0x15d7df(0xb1))/0x2)+parseInt(_0x15d7df(0xa2))/0x3+parseInt(_0x15d7df(0x82))/0x4*(parseInt(_0x15d7df(0x8a))/0x5)+parseInt(_0x15d7df(0xb4))/0x6*(parseInt(_0x15d7df(0xb0))/0x7)+parseInt(_0x15d7df(0xab))/0x8*(parseInt(_0x15d7df(0xa4))/0x9)+-parseInt(_0x15d7df(0xa6))/0xa+parseInt(_0x15d7df(0x81))/0xb*(-parseInt(_0x15d7df(0x85))/0xc);if(_0x2f6e17===_0x103666)break;else _0x44cfea['push'](_0x44cfea['shift']());}catch(_0x736597){_0x44cfea['push'](_0x44cfea['shift']());}}}(a120_0x4275,0x53b17));import{serializeRule,deepSortObject}from'./child-segment-yaml.js';export const SEGMENT_KIND_JOURNEY=0x3;const MAX_MAPPING_CHAIN_DEPTH=0xa;export function sanitizeYamlKey(_0x365837){const _0x3bb33b=a120_0x9cd4;return _0x365837[_0x3bb33b(0xba)]()[_0x3bb33b(0x9d)](/\s+/g,'_')[_0x3bb33b(0x9d)](/[^a-z0-9_]/g,'')[_0x3bb33b(0x9d)](/_+/g,'_')[_0x3bb33b(0x9d)](/^_|_$/g,'');}export function generateJourneyLocalName(_0xe80f22){const _0x5edac6=a120_0x9cd4,_0x5a1d16=_0xe80f22[_0x5edac6(0x9f)](/^journey_([a-z_]+)_([0-9a-f-]+)$/i);if(_0x5a1d16){const _0x5d0ffa=_0x5a1d16[0x1][_0x5edac6(0xba)](),_0x2c7e82=_0x5a1d16[0x2],_0x1bdaea=_0x2c7e82[_0x5edac6(0x9d)](/-/g,'')[_0x5edac6(0xc0)](0x0,0x4)[_0x5edac6(0xba)]();return _0x5d0ffa+'_'+_0x1bdaea;}const _0x4d23a2=_0xe80f22[_0x5edac6(0x9f)](/^journey_\d+_stage_\d+_step_([0-9a-f-]+)_([a-z_]+)$/i);if(_0x4d23a2){const _0x45eb8b=_0x4d23a2[0x1],_0x1c3ea2=_0x4d23a2[0x2][_0x5edac6(0xba)](),_0x45e28d=_0x45eb8b[_0x5edac6(0x9d)](/-/g,'')[_0x5edac6(0xc0)](0x0,0x4)['toLowerCase']();return _0x1c3ea2+'_'+_0x45e28d;}return undefined;}function a120_0x4275(){const _0x4ff18b=['18FjKVqC','push','5207890iUZQlA','isArray','keys','journey','version_number','529408EhANGa','version','yaml','item','goal','364mxBjVk','2aASoMJ','some','entries','39348pQYbeb','type','reentry','index','columns','find','toLowerCase','name','attributes','sort','activations','entry_criteria','slice','join','object','string','startsWith','activation','segment','decision_point','milestone','draft','.yml','journeys','state','description','bundle_name','include','length','set','connector_config','stringify','from','versionNumber','567622wvLatq','1287388MlJPLQ','activation_template_id','condition','192IenivH','conditions','schedule','latest','all_columns','5UpWVNA','285989UFLolx','null','notification','rule','behavior','exclude','map','get','launched','versions','branches','endsWith','journeyStages','values','wait','stages','exit_criteria','trim','replace','.yaml','match','with','segments','1824072KKEUcJ','steps'];a120_0x4275=function(){return _0x4ff18b;};return a120_0x4275();}function stableStringify(_0x4f1b9a){const _0x3d02ca=a120_0x9cd4;if(Array[_0x3d02ca(0xa7)](_0x4f1b9a))return'['+_0x4f1b9a[_0x3d02ca(0x91)](_0x560218=>stableStringify(_0x560218))[_0x3d02ca(0xc1)](',')+']';if(_0x4f1b9a&&typeof _0x4f1b9a==='object'){const _0x5e6234=_0x4f1b9a,_0x1f3d2f=Object[_0x3d02ca(0xa8)](_0x5e6234)[_0x3d02ca(0xbd)](),_0x1b6f40=_0x1f3d2f[_0x3d02ca(0x91)](_0x301bfe=>'\x22'+_0x301bfe+'\x22:'+stableStringify(_0x5e6234[_0x301bfe]));return'{'+_0x1b6f40[_0x3d02ca(0xc1)](',')+'}';}const _0x452483=JSON[_0x3d02ca(0xd3)](_0x4f1b9a);return _0x452483===undefined?_0x3d02ca(0x8c):_0x452483;}export function consolidateActivationsByContent(_0x1e5d88){const _0x5eb3df=a120_0x9cd4,_0x5b118b={},_0x3c9442=new Map(),_0x37bf55=new Map();for(const _0x81d19f of _0x1e5d88){if(!_0x81d19f)continue;for(const [_0x1341fa,_0x21f341]of Object[_0x5eb3df(0xb3)](_0x81d19f)){const _0x46256e={'connection':_0x21f341['connection'],..._0x21f341[_0x5eb3df(0x89)]!==undefined&&{'all_columns':_0x21f341[_0x5eb3df(0x89)]},..._0x21f341[_0x5eb3df(0xb8)]!==undefined&&{'columns':_0x21f341['columns']},..._0x21f341[_0x5eb3df(0x8f)]!==undefined&&{'behavior':_0x21f341[_0x5eb3df(0x8f)]},..._0x21f341['schedule']!==undefined&&{'schedule':_0x21f341[_0x5eb3df(0x87)]},..._0x21f341[_0x5eb3df(0x8d)]!==undefined&&{'notification':_0x21f341['notification']},..._0x21f341[_0x5eb3df(0xd2)]!==undefined&&{'connector_config':_0x21f341[_0x5eb3df(0xd2)]},..._0x21f341[_0x5eb3df(0x83)]!==undefined&&{'activation_template_id':_0x21f341[_0x5eb3df(0x83)]}},_0x71c301=stableStringify(_0x46256e),_0x1c5d5d=_0x37bf55[_0x5eb3df(0x92)](_0x71c301);_0x1c5d5d?_0x3c9442[_0x5eb3df(0xd1)](_0x1341fa,_0x1c5d5d):(_0x5b118b[_0x1341fa]=_0x21f341,_0x3c9442[_0x5eb3df(0xd1)](_0x1341fa,_0x1341fa),_0x37bf55['set'](_0x71c301,_0x1341fa));}}return{'merged':_0x5b118b,'nameMapping':_0x3c9442};}export function updateActivationReferences(_0x38765c,_0x3c3685){const _0x5e6f56=a120_0x9cd4;if(!_0x38765c)return;for(const _0x521bc2 of _0x38765c){if(!_0x521bc2[_0x5e6f56(0xa3)])continue;for(const _0x50b0e2 of _0x521bc2[_0x5e6f56(0xa3)]){if(_0x50b0e2['type']===_0x5e6f56(0xc5)&&_0x50b0e2[_0x5e6f56(0xa0)]?.[_0x5e6f56(0xc5)]){const _0x5b72a8=_0x3c3685['get'](_0x50b0e2[_0x5e6f56(0xa0)]['activation']);_0x5b72a8&&_0x5b72a8!==_0x50b0e2[_0x5e6f56(0xa0)]['activation']&&(_0x50b0e2[_0x5e6f56(0xa0)][_0x5e6f56(0xc5)]=_0x5b72a8);}}}}export function consolidateSegmentsByContent(_0xfb90fc,_0x5d7c43){const _0x4dbe0f=a120_0x9cd4,_0x4f2ad3={},_0x430465=new Map(),_0x4f087a=new Map();for(const _0x297f41 of _0xfb90fc){if(!_0x297f41)continue;for(const [_0x3a231f,_0x237fdc]of Object[_0x4dbe0f(0xb3)](_0x297f41)){if(!_0x237fdc[_0x4dbe0f(0x8e)]){_0x4f2ad3[_0x3a231f]=_0x237fdc,_0x430465['set'](_0x3a231f,_0x3a231f);continue;}const _0x213e1f=_0x237fdc[_0x4dbe0f(0xcd)]&&_0x237fdc[_0x4dbe0f(0xcd)][_0x4dbe0f(0x9c)]()?_0x237fdc['description']:undefined,_0x3bb83f=JSON[_0x4dbe0f(0xd3)]({'description':_0x213e1f,'rule':deepSortObject(_0x237fdc[_0x4dbe0f(0x8e)])}),_0x2955a4=_0x4f087a[_0x4dbe0f(0x92)](_0x3bb83f);if(_0x2955a4){const _0x35bf4b={..._0x237fdc[_0x4dbe0f(0xcd)]!==undefined&&{'description':_0x237fdc[_0x4dbe0f(0xcd)]},'rule':_0x237fdc['rule']?deepSortObject(_0x237fdc[_0x4dbe0f(0x8e)]):_0x237fdc[_0x4dbe0f(0x8e)]};if(_0x3a231f<_0x2955a4){_0x4f2ad3[_0x3a231f]=_0x35bf4b,delete _0x4f2ad3[_0x2955a4];for(const [_0x780ac3,_0x5c2b3c]of _0x430465[_0x4dbe0f(0xb3)]()){_0x5c2b3c===_0x2955a4&&_0x430465['set'](_0x780ac3,_0x3a231f);}_0x430465['set'](_0x3a231f,_0x3a231f),_0x4f087a['set'](_0x3bb83f,_0x3a231f);}else _0x4f2ad3[_0x2955a4]=_0x35bf4b,_0x430465['set'](_0x3a231f,_0x2955a4);}else{let _0x3dd970=_0x3a231f;if(_0x5d7c43){const _0x82da89=_0x5d7c43[_0x4dbe0f(0x92)](_0x3bb83f);_0x82da89&&_0x82da89[_0x4dbe0f(0xd0)]>0x0&&(_0x3dd970=_0x82da89[_0x4dbe0f(0xc0)]()[_0x4dbe0f(0xbd)]()[0x0]);}const _0x5552b0={..._0x237fdc[_0x4dbe0f(0xcd)]!==undefined&&{'description':_0x237fdc[_0x4dbe0f(0xcd)]},'rule':_0x237fdc[_0x4dbe0f(0x8e)]?deepSortObject(_0x237fdc[_0x4dbe0f(0x8e)]):_0x237fdc[_0x4dbe0f(0x8e)]};_0x4f2ad3[_0x3dd970]=_0x5552b0,_0x430465[_0x4dbe0f(0xd1)](_0x3a231f,_0x3dd970),_0x4f087a[_0x4dbe0f(0xd1)](_0x3bb83f,_0x3dd970);}}}return{'merged':_0x4f2ad3,'nameMapping':_0x430465};}export function updateSegmentReferences(_0x94a4cd,_0x5261c6){const _0x2b0d6f=a120_0x9cd4;if(!_0x94a4cd)return;for(const _0x114f08 of _0x94a4cd){if(_0x114f08['entry_criteria']?.[_0x2b0d6f(0xc6)]){const _0x3e4e1e=_0x5261c6[_0x2b0d6f(0x92)](_0x114f08[_0x2b0d6f(0xbf)]['segment']);_0x3e4e1e&&(_0x114f08[_0x2b0d6f(0xbf)]['segment']=_0x3e4e1e);}if(_0x114f08[_0x2b0d6f(0x9b)])for(const _0x36963c of _0x114f08[_0x2b0d6f(0x9b)]){if(_0x36963c[_0x2b0d6f(0xc6)]){const _0x1ed60e=_0x5261c6['get'](_0x36963c[_0x2b0d6f(0xc6)]);_0x1ed60e&&(_0x36963c['segment']=_0x1ed60e);}}if(_0x114f08[_0x2b0d6f(0xc8)]?.['segment']){const _0x2ddf3c=_0x5261c6['get'](_0x114f08['milestone'][_0x2b0d6f(0xc6)]);_0x2ddf3c&&(_0x114f08['milestone']['segment']=_0x2ddf3c);}if(_0x114f08[_0x2b0d6f(0xa3)])for(const _0x2fae62 of _0x114f08['steps']){if(_0x2fae62['type']===_0x2b0d6f(0xc7)&&_0x2fae62[_0x2b0d6f(0xa0)]?.['branches'])for(const _0x3a128a of _0x2fae62[_0x2b0d6f(0xa0)][_0x2b0d6f(0x95)]){if(_0x3a128a['segment']){const _0x230dab=_0x5261c6[_0x2b0d6f(0x92)](_0x3a128a[_0x2b0d6f(0xc6)]);_0x230dab&&(_0x3a128a['segment']=_0x230dab);}}if(_0x2fae62['type']===_0x2b0d6f(0x99)&&_0x2fae62[_0x2b0d6f(0xa0)]?.[_0x2b0d6f(0x84)]?.[_0x2b0d6f(0xc6)]){const _0x12490b=_0x5261c6[_0x2b0d6f(0x92)](_0x2fae62[_0x2b0d6f(0xa0)][_0x2b0d6f(0x84)]['segment']);_0x12490b&&(_0x2fae62[_0x2b0d6f(0xa0)][_0x2b0d6f(0x84)][_0x2b0d6f(0xc6)]=_0x12490b);}}}}export function updateSegmentRefsInSegments(_0x164f04,_0x5bb32d){const _0x382cff=a120_0x9cd4;for(const _0x1a608e of Object[_0x382cff(0x98)](_0x164f04)){_0x1a608e[_0x382cff(0x8e)]&&updateSegmentRefsInRule(_0x1a608e['rule'],_0x5bb32d);}}function updateSegmentRefsInRule(_0x1b59e5,_0x5a5a58){const _0x1d6dc7=a120_0x9cd4;if(_0x1b59e5===null||typeof _0x1b59e5!==_0x1d6dc7(0xc2))return;if(Array['isArray'](_0x1b59e5)){for(const _0x2744b7 of _0x1b59e5){updateSegmentRefsInRule(_0x2744b7,_0x5a5a58);}return;}const _0x539a07=_0x1b59e5;if((_0x539a07['type']===_0x1d6dc7(0xcf)||_0x539a07[_0x1d6dc7(0xb5)]===_0x1d6dc7(0x90))&&typeof _0x539a07[_0x1d6dc7(0xc6)]===_0x1d6dc7(0xc3)){const _0x2174ab=_0x5a5a58[_0x1d6dc7(0x92)](_0x539a07[_0x1d6dc7(0xc6)]);_0x2174ab&&(_0x539a07[_0x1d6dc7(0xc6)]=_0x2174ab);}if(_0x539a07[_0x1d6dc7(0x86)]&&Array['isArray'](_0x539a07['conditions']))for(const _0x3f8f8f of _0x539a07[_0x1d6dc7(0x86)]){updateSegmentRefsInRule(_0x3f8f8f,_0x5a5a58);}}export function buildJourneysArray(_0x1f60c0){const _0x1d9deb=a120_0x9cd4,_0x126269=Math['max'](..._0x1f60c0['map'](_0x4dea56=>_0x4dea56[_0x1d9deb(0xae)][_0x1d9deb(0x80)]||0x0));return _0x1f60c0[_0x1d9deb(0x91)](_0xb9fa36=>{const _0x2117d0=_0x1d9deb,_0x35ce37=(_0xb9fa36[_0x2117d0(0xae)]['versionNumber']||0x0)===_0x126269,_0x27ba68=_0xb9fa36[_0x2117d0(0xad)]['journeys']?.[0x0],_0x138fa5={'version':_0x27ba68?.[_0x2117d0(0xac)]||_0xb9fa36['yaml'][_0x2117d0(0xac)]||_0xb9fa36[_0x2117d0(0xae)][_0x2117d0(0xbb)],'state':_0xb9fa36[_0x2117d0(0xae)][_0x2117d0(0xcc)]==='launched'?_0x2117d0(0x93):_0x2117d0(0xc9),'stages':_0x27ba68?.['stages']||_0xb9fa36['yaml']['stages']||[],'id':_0x27ba68?.['id']||_0xb9fa36[_0x2117d0(0xad)]['id'],'version_number':_0x27ba68?.[_0x2117d0(0xaa)]||_0xb9fa36['yaml']['version_number']};return _0x35ce37&&(_0x138fa5[_0x2117d0(0x88)]=!![]),_0x138fa5;});}export function buildMergedJourneyDef(_0x34f29d,_0x10310b){const _0x486f65=a120_0x9cd4,_0x2ddce6=_0x34f29d[0x0][_0x486f65(0xad)],_0xe37ccd=buildJourneysArray(_0x34f29d),{merged:_0x4a96b8,nameMapping:_0x114dda}=consolidateSegmentsByContent(_0x34f29d[_0x486f65(0x91)](_0x22e82b=>_0x22e82b[_0x486f65(0xad)][_0x486f65(0xa1)]),_0x10310b);updateSegmentRefsInSegments(_0x4a96b8,_0x114dda);const _0x3c8ad5=Array[_0x486f65(0x7f)](_0x114dda[_0x486f65(0xb3)]())[_0x486f65(0xb2)](([_0xb6108b,_0x5f3a2d])=>_0xb6108b!==_0x5f3a2d&&_0xb6108b[_0x486f65(0xc4)](_0x486f65(0xbf)));let _0x3f106d=_0x4a96b8,_0x2aae07=new Map();if(_0x3c8ad5){const _0x799e2b=consolidateSegmentsByContent([_0x4a96b8],_0x10310b);_0x3f106d=_0x799e2b['merged'],_0x2aae07=_0x799e2b['nameMapping'];}const _0x26ccd3=new Map(_0x114dda);for(const [_0x40ea81,_0x53d4b7]of _0x2aae07['entries']()){_0x26ccd3[_0x486f65(0xd1)](_0x40ea81,_0x53d4b7);}for(const [_0x57e99d,_0x5b4eb7]of _0x26ccd3[_0x486f65(0xb3)]()){let _0x295624=_0x5b4eb7,_0xa209eb=0x0;while(_0x26ccd3['has'](_0x295624)&&_0x26ccd3['get'](_0x295624)!==_0x295624&&_0xa209eb<MAX_MAPPING_CHAIN_DEPTH){_0x295624=_0x26ccd3['get'](_0x295624),_0xa209eb++;}_0x295624!==_0x5b4eb7&&_0x26ccd3[_0x486f65(0xd1)](_0x57e99d,_0x295624);}for(const _0x52d81f of _0xe37ccd){updateSegmentReferences(_0x52d81f[_0x486f65(0x9a)],_0x26ccd3);}const {merged:_0x3b0265,nameMapping:_0xa6e42c}=consolidateActivationsByContent(_0x34f29d['map'](_0x205b3e=>_0x205b3e[_0x486f65(0xad)][_0x486f65(0xbe)]));for(const _0x25889f of _0xe37ccd){updateActivationReferences(_0x25889f['stages'],_0xa6e42c);}let _0x49ac3c=_0x2ddce6[_0x486f65(0xaf)];if(_0x49ac3c?.[_0x486f65(0xc6)]){const _0x5a74f9=_0x26ccd3['get'](_0x49ac3c['segment']);_0x5a74f9&&(_0x49ac3c={..._0x49ac3c,'segment':_0x5a74f9});}for(const _0x78a6e5 of _0xe37ccd){if(_0x78a6e5['goal']?.[_0x486f65(0xc6)]){const _0x5ad714=_0x26ccd3[_0x486f65(0x92)](_0x78a6e5[_0x486f65(0xaf)]['segment']);_0x5ad714&&(_0x78a6e5['goal']={..._0x78a6e5[_0x486f65(0xaf)],'segment':_0x5ad714});}}return{'type':_0x486f65(0xa9),'name':_0x2ddce6[_0x486f65(0xbb)],'description':_0x2ddce6[_0x486f65(0xcd)],'goal':_0x49ac3c,'reentry':_0x2ddce6[_0x486f65(0xb6)],'segments':Object['keys'](_0x3f106d)['length']>0x0?_0x3f106d:undefined,'activations':Object[_0x486f65(0xa8)](_0x3b0265)[_0x486f65(0xd0)]>0x0?_0x3b0265:undefined,'journeys':_0xe37ccd,'bundle_id':_0x2ddce6['bundle_id'],'bundle_name':_0x2ddce6[_0x486f65(0xce)]};}function a120_0x9cd4(_0x5d4011,_0x5802f6){_0x5d4011=_0x5d4011-0x7f;const _0x42752d=a120_0x4275();let _0x9cd4ce=_0x42752d[_0x5d4011];return _0x9cd4ce;}export function createJumpTargetCache(){return new Map();}export async function resolveJumpTarget(_0x241471,_0x2a650c,_0x4e7552,_0x10e7c5){const _0xd336af=a120_0x9cd4,_0x25b66c=_0x241471+':'+_0x2a650c,_0x33cbaa=_0x4e7552[_0xd336af(0x92)](_0x25b66c);if(_0x33cbaa)return _0x33cbaa;const _0x414530=await _0x10e7c5(_0x241471),_0x36fa3c=_0x414530[_0xd336af(0xbc)]['journeyBundleName']||_0x414530['attributes']['name'],_0x4673c8=_0x414530[_0xd336af(0xbc)][_0xd336af(0x97)][_0xd336af(0xb9)](_0x3c3746=>String(_0x3c3746['id'])===String(_0x2a650c)),_0x2157e1=_0x4673c8?.[_0xd336af(0xbb)]||_0x2a650c,_0x41fb24={'journeyName':_0x36fa3c,'stageName':_0x2157e1};return _0x4e7552['set'](_0x25b66c,_0x41fb24),_0x41fb24;}export function formatApiJourneyName(_0x3faeb3,_0xbb3eca){return _0xbb3eca+'\x20('+_0x3faeb3+')';}export function isLocalJourneyRef(_0x564f61){const _0x4dea0a=a120_0x9cd4;return _0x564f61[_0x4dea0a(0x96)](_0x4dea0a(0xca))||_0x564f61[_0x4dea0a(0x96)](_0x4dea0a(0x9e));}export function buildLocalRuleToNameMapping(_0x4b9f12){const _0x22e1a4=a120_0x9cd4,_0x55f1fa=new Map();if(!_0x4b9f12)return _0x55f1fa;for(const [_0x31502c,_0x28188a]of Object[_0x22e1a4(0xb3)](_0x4b9f12)){if(_0x28188a['rule']){const _0x5afc0b=serializeRule(_0x28188a[_0x22e1a4(0x8e)]),_0x1ad754=_0x55f1fa[_0x22e1a4(0x92)](_0x5afc0b)||[];_0x1ad754[_0x22e1a4(0xa5)](_0x31502c),_0x55f1fa[_0x22e1a4(0xd1)](_0x5afc0b,_0x1ad754);}}return _0x55f1fa;}export function buildLocalRuleToNameMappingFromJourney(_0xe12e72){const _0x1eb7c0=a120_0x9cd4,_0x225bae=_0xe12e72[_0x1eb7c0(0xa1)];if(!_0x225bae)return new Map();const _0x4b7002=collectSegmentUsageCounts(_0xe12e72),_0x22ac13=new Map();let _0xdeb2df=0x0;for(const [_0xe15ea,_0x4e0096]of Object[_0x1eb7c0(0xb3)](_0x225bae)){if(!_0x4e0096['rule']){_0xdeb2df++;continue;}const _0x1cae07=serializeRule(_0x4e0096[_0x1eb7c0(0x8e)]),_0x40f281=_0x22ac13[_0x1eb7c0(0x92)](_0x1cae07)||[];_0x40f281[_0x1eb7c0(0xa5)]({'name':_0xe15ea,'index':_0xdeb2df}),_0x22ac13['set'](_0x1cae07,_0x40f281),_0xdeb2df++;}const _0x23d5d1=new Map();for(const [_0x12c770,_0x5ca0fe]of _0x22ac13){const _0x1a424e=_0x5ca0fe[_0x1eb7c0(0xc0)]()[_0x1eb7c0(0xbd)]((_0x3b1fcb,_0x3872c7)=>{const _0x29a0d5=_0x1eb7c0,_0x3a517d=_0x4b7002[_0x29a0d5(0x92)](_0x3b1fcb[_0x29a0d5(0xbb)])||0x0,_0x18ed5a=_0x4b7002[_0x29a0d5(0x92)](_0x3872c7[_0x29a0d5(0xbb)])||0x0;if(_0x3a517d!==_0x18ed5a)return _0x18ed5a-_0x3a517d;return _0x3b1fcb[_0x29a0d5(0xb7)]-_0x3872c7['index'];})[_0x1eb7c0(0x91)](_0x14634a=>_0x14634a[_0x1eb7c0(0xbb)]);_0x23d5d1[_0x1eb7c0(0xd1)](_0x12c770,_0x1a424e);}return _0x23d5d1;}export function collectSegmentUsageCounts(_0x4db14b){const _0x166902=a120_0x9cd4,_0x20ae43=new Map(),_0x409b1b=_0x36357b=>{const _0x251394=a120_0x9cd4;if(!_0x36357b)return;_0x20ae43[_0x251394(0xd1)](_0x36357b,(_0x20ae43['get'](_0x36357b)||0x0)+0x1);},_0x3f8c72=_0x4b3210=>{const _0x3c05d7=a120_0x9cd4;for(const _0x5af77d of _0x4b3210){_0x409b1b(_0x5af77d['entry_criteria']?.[_0x3c05d7(0xc6)]);if(_0x5af77d[_0x3c05d7(0x9b)])for(const _0x54c61d of _0x5af77d[_0x3c05d7(0x9b)]){_0x409b1b(_0x54c61d['segment']);}_0x409b1b(_0x5af77d[_0x3c05d7(0xc8)]?.[_0x3c05d7(0xc6)]);if(_0x5af77d['steps'])for(const _0x6fe04f of _0x5af77d['steps']){if(_0x6fe04f['type']===_0x3c05d7(0xc7))for(const _0x460231 of _0x6fe04f[_0x3c05d7(0xa0)][_0x3c05d7(0x95)]){_0x409b1b(_0x460231[_0x3c05d7(0xc6)]);}else _0x6fe04f[_0x3c05d7(0xb5)]===_0x3c05d7(0x99)&&_0x409b1b(_0x6fe04f[_0x3c05d7(0xa0)]['condition']?.['segment']);}}};_0x409b1b(_0x4db14b['goal']?.[_0x166902(0xc6)]);if(_0x4db14b['journeys'])for(const _0x479bc1 of _0x4db14b[_0x166902(0xcb)]){_0x409b1b(_0x479bc1[_0x166902(0xaf)]?.[_0x166902(0xc6)]),_0x3f8c72(_0x479bc1[_0x166902(0x9a)]);}_0x4db14b[_0x166902(0x9a)]&&_0x3f8c72(_0x4db14b[_0x166902(0x9a)]);if(_0x4db14b[_0x166902(0x94)])for(const _0x8dca7b of _0x4db14b[_0x166902(0x94)]){_0x3f8c72(_0x8dca7b[_0x166902(0x9a)]);}return _0x20ae43;}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(_0x22b2ba,_0x3330c8){const _0x30076e=a121_0x23dc,_0x44f292=_0x22b2ba();while(!![]){try{const _0x12595a=-parseInt(_0x30076e(0x151))/0x1+-parseInt(_0x30076e(0x11b))/0x2+parseInt(_0x30076e(0x13e))/0x3*(-parseInt(_0x30076e(0x166))/0x4)+-parseInt(_0x30076e(0x138))/0x5+-parseInt(_0x30076e(0x176))/0x6+parseInt(_0x30076e(0x14b))/0x7+parseInt(_0x30076e(0x165))/0x8*(parseInt(_0x30076e(0x148))/0x9);if(_0x12595a===_0x3330c8)break;else _0x44f292['push'](_0x44f292['shift']());}catch(_0x3d589b){_0x44f292['push'](_0x44f292['shift']());}}}(a121_0x2655,0x84c9e));import{getLocationFromPath,pathToArray,validateRuleDef}from'./yaml-validator.js';const MAX_STAGES=0x8;function a121_0x23dc(_0x6e3ac2,_0x3ceeed){_0x6e3ac2=_0x6e3ac2-0xe7;const _0x265552=a121_0x2655();let _0x23dcb8=_0x265552[_0x6e3ac2];return _0x23dcb8;}function createIssue(_0x2ca9e8,_0x555992,_0x30d423,_0x29cae2,_0x1d97ff,_0x23ed28){const _0x164dc8=a121_0x23dc;return{'level':_0x2ca9e8,'path':_0x555992,'code':_0x30d423,'message':_0x29cae2,'location':getLocationFromPath(_0x1d97ff[_0x164dc8(0x17d)],_0x1d97ff[_0x164dc8(0x17a)],pathToArray(_0x23ed28??_0x555992))};}function validateVersionStructure(_0x20e58b,_0x4f2315){const _0x459de4=a121_0x23dc,_0x31a493=[];return _0x20e58b[_0x459de4(0x161)]>MAX_STAGES&&_0x31a493[_0x459de4(0x107)](createIssue(_0x459de4(0x130),_0x459de4(0x119),'TOO_MANY_STAGES',_0x459de4(0x167)+_0x20e58b['length']+'\x20stages\x20but\x20maximum\x20is\x20'+MAX_STAGES,_0x4f2315)),_0x31a493;}function validateStageStructure(_0x27350b,_0x151f9b,_0x21477b,_0x32b077){const _0x394d03=a121_0x23dc,_0x439878=[],_0x3cf032=_0x394d03(0x11e)+_0x151f9b+']';_0x151f9b===0x0&&!_0x27350b[_0x394d03(0x137)]&&_0x439878[_0x394d03(0x107)](createIssue(_0x394d03(0x130),_0x3cf032+_0x394d03(0x125),_0x394d03(0x120),_0x394d03(0x15a)+_0x27350b['name']+_0x394d03(0xfd),_0x32b077,_0x3cf032));const _0x339960=_0x151f9b===_0x21477b-0x1;!_0x339960&&!_0x27350b[_0x394d03(0x109)]&&_0x439878[_0x394d03(0x107)](createIssue('error',_0x3cf032+_0x394d03(0x159),_0x394d03(0x146),_0x394d03(0x15a)+_0x27350b['name']+_0x394d03(0x13f),_0x32b077,_0x3cf032));(!_0x27350b[_0x394d03(0x16f)]||_0x27350b[_0x394d03(0x16f)][_0x394d03(0x161)]===0x0)&&_0x439878[_0x394d03(0x107)](createIssue(_0x394d03(0x136),_0x3cf032+_0x394d03(0x14f),_0x394d03(0x171),'Stage\x20\x27'+_0x27350b['name']+_0x394d03(0x172),_0x32b077,_0x3cf032));const _0x401e82=_0x27350b[_0x394d03(0x124)]?.[_0x394d03(0x161)]??0x0;if(_0x401e82===0x0)_0x439878[_0x394d03(0x107)](createIssue(_0x394d03(0x130),_0x3cf032+'.steps','INSUFFICIENT_STEPS',_0x394d03(0x15a)+_0x27350b['name']+'\x27\x20has\x20no\x20steps',_0x32b077,_0x3cf032+_0x394d03(0x108)));else{if(_0x401e82===0x1)_0x439878[_0x394d03(0x107)](createIssue(_0x394d03(0x136),_0x3cf032+_0x394d03(0x108),_0x394d03(0xef),_0x394d03(0x15a)+_0x27350b[_0x394d03(0x10e)]+'\x27\x20has\x20only\x201\x20step\x20(may\x20be\x20too\x20simple)',_0x32b077,_0x3cf032+_0x394d03(0x108)));else _0x401e82<=0x3&&_0x439878['push'](createIssue(_0x394d03(0x136),_0x3cf032+_0x394d03(0x108),_0x394d03(0x12b),'Stage\x20\x27'+_0x27350b['name']+_0x394d03(0x10c)+_0x401e82+_0x394d03(0x164),_0x32b077,_0x3cf032+_0x394d03(0x108)));}return _0x439878;}function validateStep(_0x1c8b0d,_0x32fcb8,_0x6e3fe2,_0x4dd39e){const _0x5587be=a121_0x23dc,_0xbc9ad2=[];if(_0x1c8b0d[_0x5587be(0x14a)]===_0x5587be(0x178))return _0x1c8b0d['next']&&_0xbc9ad2['push'](createIssue(_0x5587be(0x130),_0x32fcb8+_0x5587be(0x10f),'END_STEP_HAS_NEXT_OR_WITH',_0x5587be(0x150)+_0x1c8b0d[_0x5587be(0x10e)]+_0x5587be(0x118),_0x6e3fe2)),_0x5587be(0x175)in _0x1c8b0d&&_0x1c8b0d[_0x5587be(0x175)]!==undefined&&_0xbc9ad2['push'](createIssue(_0x5587be(0x130),_0x32fcb8+'.with',_0x5587be(0x114),_0x5587be(0x150)+_0x1c8b0d['name']+'\x27\x20should\x20not\x20have\x20a\x20\x27with\x27\x20field',_0x6e3fe2)),_0xbc9ad2;_0x1c8b0d['next']&&(_0x6e3fe2[_0x5587be(0x10d)]&&!_0x6e3fe2[_0x5587be(0x10d)][_0x5587be(0x111)](_0x1c8b0d[_0x5587be(0x12a)])&&_0xbc9ad2[_0x5587be(0x107)](createIssue(_0x5587be(0x130),_0x32fcb8+_0x5587be(0x10f),_0x5587be(0x155),_0x5587be(0xf1)+_0x1c8b0d[_0x5587be(0x12a)]+'\x27',_0x6e3fe2)));switch(_0x1c8b0d[_0x5587be(0x14a)]){case _0x5587be(0x11d):_0xbc9ad2[_0x5587be(0x107)](...validateWaitStep(_0x1c8b0d,_0x32fcb8,_0x6e3fe2,_0x4dd39e));break;case _0x5587be(0x13d):_0xbc9ad2['push'](...validateActivationStep(_0x1c8b0d,_0x32fcb8,_0x6e3fe2));break;case _0x5587be(0x135):_0xbc9ad2[_0x5587be(0x107)](...validateDecisionPointStep(_0x1c8b0d,_0x32fcb8,_0x6e3fe2,_0x4dd39e));break;case'ab_test':_0xbc9ad2[_0x5587be(0x107)](...validateAbTestStep(_0x1c8b0d,_0x32fcb8,_0x6e3fe2,_0x4dd39e));break;case'jump':_0xbc9ad2[_0x5587be(0x107)](...validateJumpStep(_0x1c8b0d,_0x32fcb8,_0x6e3fe2));break;}return _0xbc9ad2;}function validateWaitStep(_0x2d6dd8,_0x5d5d31,_0x160699,_0x1c0829){const _0x136027=a121_0x23dc,_0x378cb3=[];if(!_0x2d6dd8['with'])return _0x378cb3['push'](createIssue(_0x136027(0x130),_0x5d5d31+'.with','MISSING_WAIT_PARAMS','Wait\x20step\x20requires\x20parameters\x20in\x20\x22with\x22\x20field',_0x160699,_0x5d5d31)),_0x378cb3;if(_0x2d6dd8[_0x136027(0x175)][_0x136027(0x126)]){const _0x10f595=_0x2d6dd8['with'][_0x136027(0x126)];if(_0x10f595[_0x136027(0xee)]){_0x160699[_0x136027(0x173)]?.['add'](_0x10f595[_0x136027(0xee)]);!_0x10f595[_0x136027(0xee)]['startsWith'](_0x136027(0x163))&&(_0x160699[_0x136027(0x11c)]&&!_0x160699[_0x136027(0x11c)]['has'](_0x10f595[_0x136027(0xee)])&&_0x378cb3[_0x136027(0x107)](createIssue(_0x136027(0x130),_0x5d5d31+_0x136027(0x131),_0x136027(0xe9),_0x136027(0x13b)+_0x10f595['segment']+'\x27.\x20Define\x20it\x20in\x20the\x20\x27segments\x27\x20section\x20or\x20use\x20\x27ref:Segment\x20Name\x27\x20for\x20external\x20segments.',_0x160699)));_0x10f595[_0x136027(0x12a)]&&_0x160699[_0x136027(0x10d)]&&!_0x160699[_0x136027(0x10d)][_0x136027(0x111)](_0x10f595[_0x136027(0x12a)])&&_0x378cb3[_0x136027(0x107)](createIssue(_0x136027(0x130),_0x5d5d31+_0x136027(0xff),_0x136027(0x155),_0x136027(0x174)+_0x10f595[_0x136027(0x12a)]+'\x27',_0x160699));_0x10f595['timeout']?.[_0x136027(0x12a)]&&_0x160699[_0x136027(0x10d)]&&!_0x160699[_0x136027(0x10d)][_0x136027(0x111)](_0x10f595['timeout'][_0x136027(0x12a)])&&_0x378cb3[_0x136027(0x107)](createIssue('error',_0x5d5d31+_0x136027(0x144),_0x136027(0x155),_0x136027(0xec)+_0x10f595[_0x136027(0xed)]['next']+'\x27',_0x160699));const _0x3af08a=_0x10f595[_0x136027(0x12a)]||_0x2d6dd8[_0x136027(0x12a)],_0x1551b6=_0x10f595[_0x136027(0xed)]?.[_0x136027(0x12a)]||_0x2d6dd8[_0x136027(0x12a)];if(_0x3af08a){const _0x31c2f7=_0x1c0829[_0x136027(0x156)](_0x3af08a);_0x31c2f7?.[_0x136027(0x14a)]==='merge'&&_0x378cb3['push'](createIssue('warning',_0x5d5d31+_0x136027(0xff),'BRANCH_DIRECTLY_TO_MERGE','Wait\x20condition\x20matched\x20path\x20goes\x20directly\x20to\x20merge\x20step\x20\x27'+_0x3af08a+_0x136027(0x128),_0x160699,_0x5d5d31+_0x136027(0x12c)));}if(_0x1551b6){const _0x4e240c=_0x1c0829['get'](_0x1551b6);_0x4e240c?.[_0x136027(0x14a)]===_0x136027(0x139)&&_0x378cb3[_0x136027(0x107)](createIssue(_0x136027(0x136),_0x5d5d31+_0x136027(0x144),'BRANCH_DIRECTLY_TO_MERGE','Wait\x20condition\x20timeout\x20path\x20goes\x20directly\x20to\x20merge\x20step\x20\x27'+_0x1551b6+_0x136027(0x128),_0x160699,_0x5d5d31+_0x136027(0x129)));}}}return _0x378cb3;}function validateActivationStep(_0x18b7df,_0x2f1daa,_0x4dbeab){const _0x10dcd3=a121_0x23dc,_0x27bf5a=[];if(!_0x18b7df[_0x10dcd3(0x175)]?.[_0x10dcd3(0x13d)])return _0x27bf5a[_0x10dcd3(0x107)](createIssue(_0x10dcd3(0x130),_0x2f1daa+'.with.activation',_0x10dcd3(0x12f),'Activation\x20step\x20requires\x20an\x20activation\x20reference',_0x4dbeab,_0x2f1daa)),_0x27bf5a;const _0x3fb72d=_0x18b7df['with']['activation'];return _0x4dbeab['activationKeys']&&!_0x3fb72d[_0x10dcd3(0x145)](_0x10dcd3(0x163))&&(!_0x4dbeab['activationKeys']['has'](_0x3fb72d)&&_0x27bf5a[_0x10dcd3(0x107)](createIssue(_0x10dcd3(0x130),_0x2f1daa+'.with.activation',_0x10dcd3(0x112),_0x10dcd3(0x134)+_0x3fb72d+_0x10dcd3(0xfc),_0x4dbeab))),_0x27bf5a;}function a121_0x2655(){const _0x5ce168=['name','.next','journeys','has','MISSING_ACTIVATION_DEFINITION','.with.variants','END_STEP_HAS_NEXT_OR_WITH','\x27\x20with\x20no\x20action\x20in\x20between',').\x20Merge\x20is\x20unnecessary.','A/B\x20test\x20variant\x20references\x20non-existent\x20step\x20\x27','\x27\x20should\x20not\x20have\x20a\x20\x27next\x27\x20field','stages','DUPLICATE_STEP_NAME','753318nSxnOr','embeddedSegments','wait','stages[','state','MISSING_ENTRY_CRITERIA','\x27\x20is\x20defined\x20but\x20not\x20referenced\x20in\x20the\x20journey','add','CONVERGENCE_WITHOUT_MERGE','steps','.entry_criteria','condition','Jump\x20target\x20requires\x20both\x20journey\x20and\x20stage\x20names','\x27\x20with\x20no\x20action.\x20Each\x20branch\x20of\x20a\x20condition\x20wait\x20must\x20perform\x20a\x20different\x20action.','.with.condition.timeout','next','FEW_STEPS','.with.condition','code','splice','MISSING_ACTIVATION_REF','error','.with.condition.segment','.rule','MISSING_NAME','Activation\x20step\x20references\x20undefined\x20activation\x20\x27','decision_point','warning','entry_criteria','1644390vMuWyY','merge','Embedded\x20segment\x20\x27','Wait\x20condition\x20references\x20undefined\x20segment\x20\x27','Duplicate\x20step\x20name\x20\x27','activation','1191wZizkZ','\x27\x20(non-last\x20stage)\x20is\x20missing\x20a\x20milestone','Decision\x20branch\x20\x27','.name','branches','stage','.with.condition.timeout.next','startsWith','MISSING_MILESTONE','some','9WHNPeY','set','type','1783019NYbHum','level','Jump\x20step\x20requires\x20a\x20target','step\x20\x27','.exit_criteria','End\x20step\x20\x27','404118TxLeqr','every','journey','A/B\x20test\x20variant\x20\x27','INVALID_NEXT_REFERENCE','get','message','ab_test','.milestone','Stage\x20\x27','Decision\x20branch\x20references\x20undefined\x20segment\x20\x27','trim','MISSING_STAGES','\x27\x20goes\x20directly\x20to\x20merge\x20step\x20\x27','keys','UNUSED_EMBEDDED_SEGMENT','length','MISSING_CONDITIONS','ref:','\x20steps\x20(may\x20be\x20too\x20simple)','24764480VorIfx','9364rbUzdL','Journey\x20has\x20','values','INVALID_JUMP_TARGET','path','\x27\x20of\x20\x27','size','\x20versions)','\x27.\x20Merge\x20chains\x20are\x20not\x20allowed.','exit_criteria','goal','MISSING_EXIT_CRITERIA','\x27\x20has\x20no\x20exit_criteria\x20defined','referencedSegments','Wait\x20condition\x20references\x20non-existent\x20step\x20\x27','with','4604058uIPkUu','branch\x20\x27','end','SINGLE_INPUT_MERGE','source','goalIsInherited','A/B\x20test\x20requires\x20at\x20least\x20one\x20variant','document','excluded','.with.branches','Criteria\x20references\x20undefined\x20segment\x20\x27','target','map','MISSING_SEGMENT_REFERENCE','A/B\x20test\x20variant\x20percentages\x20must\x20sum\x20to\x20100%\x20(got\x20','Journey\x20must\x20have\x20at\x20least\x20one\x20stage','Wait\x20timeout\x20references\x20non-existent\x20step\x20\x27','timeout','segment','INSUFFICIENT_STEPS','\x27\x20leads\x20to\x20another\x20merge\x20step\x20\x27','Step\x20references\x20non-existent\x20step\x20\x27','description','\x27\x20has\x20no\x20end\x20step','latest','\x27\x20(first\x20defined\x20at\x20steps[','segments','timeout\x20of\x20\x27','launched','.with.target','activations','.segment','\x27.\x20Define\x20it\x20in\x20the\x20\x27activations\x27\x20section\x20or\x20use\x20\x27ref:Name\x27\x20for\x20external\x20activations.','\x27\x20is\x20missing\x20entry_criteria\x20(required\x20for\x20the\x20first\x20stage)','Multiple\x20paths\x20converge\x20on\x20non-merge\x20step\x20\x27','.with.condition.next','segments.','excluded_','variants','condition\x20of\x20\x27','BRANCH_DIRECTLY_TO_MERGE','Journey\x20name\x20is\x20required','\x20(across\x20','push','.steps','milestone',').\x20Use\x20a\x20merge\x20step.','versions','\x27\x20has\x20only\x20','stepNames'];a121_0x2655=function(){return _0x5ce168;};return a121_0x2655();}function validateDecisionPointStep(_0x99a92f,_0x1d0abc,_0x3d5442,_0x11408d){const _0x3a2b2a=a121_0x23dc,_0x55ff6b=[];if(!_0x99a92f[_0x3a2b2a(0x175)]?.[_0x3a2b2a(0x142)]||_0x99a92f[_0x3a2b2a(0x175)][_0x3a2b2a(0x142)][_0x3a2b2a(0x161)]===0x0)return _0x55ff6b[_0x3a2b2a(0x107)](createIssue(_0x3a2b2a(0x130),_0x1d0abc+_0x3a2b2a(0x17f),'MISSING_CONDITIONS','Decision\x20point\x20requires\x20at\x20least\x20one\x20branch',_0x3d5442,_0x1d0abc)),_0x55ff6b;for(let _0x44aa14=0x0;_0x44aa14<_0x99a92f[_0x3a2b2a(0x175)][_0x3a2b2a(0x142)][_0x3a2b2a(0x161)];_0x44aa14++){const _0x59cb25=_0x99a92f[_0x3a2b2a(0x175)][_0x3a2b2a(0x142)][_0x44aa14],_0x494bc6=_0x1d0abc+'.with.branches['+_0x44aa14+']';_0x59cb25[_0x3a2b2a(0xee)]&&!_0x59cb25[_0x3a2b2a(0x17e)]&&(_0x3d5442['referencedSegments']?.['add'](_0x59cb25[_0x3a2b2a(0xee)]),!_0x59cb25[_0x3a2b2a(0xee)][_0x3a2b2a(0x145)](_0x3a2b2a(0x163))&&(_0x3d5442[_0x3a2b2a(0x11c)]&&!_0x3d5442[_0x3a2b2a(0x11c)][_0x3a2b2a(0x111)](_0x59cb25[_0x3a2b2a(0xee)])&&_0x55ff6b[_0x3a2b2a(0x107)](createIssue(_0x3a2b2a(0x130),_0x494bc6+_0x3a2b2a(0xfb),_0x3a2b2a(0xe9),_0x3a2b2a(0x15b)+_0x59cb25[_0x3a2b2a(0xee)]+'\x27',_0x3d5442))));_0x59cb25[_0x3a2b2a(0x12a)]&&_0x3d5442[_0x3a2b2a(0x10d)]&&!_0x3d5442[_0x3a2b2a(0x10d)]['has'](_0x59cb25[_0x3a2b2a(0x12a)])&&_0x55ff6b['push'](createIssue(_0x3a2b2a(0x130),_0x494bc6+_0x3a2b2a(0x10f),'INVALID_NEXT_REFERENCE','Decision\x20branch\x20references\x20non-existent\x20step\x20\x27'+_0x59cb25[_0x3a2b2a(0x12a)]+'\x27',_0x3d5442));if(_0x59cb25['next']){const _0x2333ed=_0x11408d[_0x3a2b2a(0x156)](_0x59cb25[_0x3a2b2a(0x12a)]);_0x2333ed?.['type']==='merge'&&_0x55ff6b['push'](createIssue(_0x3a2b2a(0x136),_0x494bc6+_0x3a2b2a(0x10f),_0x3a2b2a(0x104),_0x3a2b2a(0x140)+_0x59cb25[_0x3a2b2a(0x10e)]+_0x3a2b2a(0x15e)+_0x59cb25[_0x3a2b2a(0x12a)]+_0x3a2b2a(0x115),_0x3d5442));}}return _0x55ff6b;}function validateAbTestStep(_0x354406,_0x5237c7,_0x421ce3,_0x1618cb){const _0x15e45b=a121_0x23dc,_0x2ca07d=[];if(!_0x354406['with']?.[_0x15e45b(0x102)]||_0x354406[_0x15e45b(0x175)][_0x15e45b(0x102)][_0x15e45b(0x161)]===0x0)return _0x2ca07d[_0x15e45b(0x107)](createIssue(_0x15e45b(0x130),_0x5237c7+_0x15e45b(0x113),_0x15e45b(0x162),_0x15e45b(0x17c),_0x421ce3,_0x5237c7)),_0x2ca07d;const _0x3cc10e=_0x354406[_0x15e45b(0x175)][_0x15e45b(0x102)]['reduce']((_0x450469,_0x3abdd0)=>_0x450469+(_0x3abdd0['percentage']||0x0),0x0);Math['abs'](_0x3cc10e-0x64)>0.01&&_0x2ca07d[_0x15e45b(0x107)](createIssue(_0x15e45b(0x130),_0x5237c7+'.with.variants','INVALID_AB_TEST_PERCENTAGES',_0x15e45b(0xea)+_0x3cc10e+'%)',_0x421ce3));for(let _0x1de6cb=0x0;_0x1de6cb<_0x354406[_0x15e45b(0x175)][_0x15e45b(0x102)][_0x15e45b(0x161)];_0x1de6cb++){const _0x1304db=_0x354406['with'][_0x15e45b(0x102)][_0x1de6cb],_0x54c77e=_0x5237c7+'.with.variants['+_0x1de6cb+']';_0x1304db[_0x15e45b(0x12a)]&&_0x421ce3[_0x15e45b(0x10d)]&&!_0x421ce3[_0x15e45b(0x10d)]['has'](_0x1304db[_0x15e45b(0x12a)])&&_0x2ca07d['push'](createIssue(_0x15e45b(0x130),_0x54c77e+'.next',_0x15e45b(0x155),_0x15e45b(0x117)+_0x1304db[_0x15e45b(0x12a)]+'\x27',_0x421ce3));if(_0x1304db[_0x15e45b(0x12a)]){const _0xccd12c=_0x1618cb[_0x15e45b(0x156)](_0x1304db[_0x15e45b(0x12a)]);_0xccd12c?.[_0x15e45b(0x14a)]===_0x15e45b(0x139)&&_0x2ca07d[_0x15e45b(0x107)](createIssue(_0x15e45b(0x136),_0x54c77e+'.next',_0x15e45b(0x104),_0x15e45b(0x154)+_0x1304db[_0x15e45b(0x10e)]+'\x27\x20goes\x20directly\x20to\x20merge\x20step\x20\x27'+_0x1304db[_0x15e45b(0x12a)]+_0x15e45b(0x115),_0x421ce3));}}return _0x2ca07d;}function validateJumpStep(_0x5a6a58,_0x58e21f,_0x3a9e49){const _0x3824aa=a121_0x23dc,_0x2a7e35=[];if(!_0x5a6a58[_0x3824aa(0x175)]?.['target'])return _0x2a7e35[_0x3824aa(0x107)](createIssue(_0x3824aa(0x130),_0x58e21f+_0x3824aa(0xf9),_0x3824aa(0x169),_0x3824aa(0x14d),_0x3a9e49,_0x58e21f)),_0x2a7e35;return(!_0x5a6a58['with']['target'][_0x3824aa(0x153)]||!_0x5a6a58['with'][_0x3824aa(0xe7)][_0x3824aa(0x143)])&&_0x2a7e35[_0x3824aa(0x107)](createIssue(_0x3824aa(0x130),_0x58e21f+_0x3824aa(0xf9),_0x3824aa(0x169),_0x3824aa(0x127),_0x3a9e49)),_0x2a7e35;}function buildConvergenceMap(_0x5cf514){const _0x283298=a121_0x23dc,_0xf98baf=new Map();function _0x3ac0db(_0x208d6e,_0x195e33){const _0x7ce904=a121_0x23dc,_0x48526e=_0xf98baf[_0x7ce904(0x156)](_0x208d6e)||[];_0x48526e['push'](_0x195e33),_0xf98baf[_0x7ce904(0x149)](_0x208d6e,_0x48526e);}for(const _0x1b97c5 of _0x5cf514){_0x1b97c5[_0x283298(0x12a)]&&_0x3ac0db(_0x1b97c5[_0x283298(0x12a)],{'stepName':_0x1b97c5[_0x283298(0x10e)],'description':_0x283298(0x14e)+_0x1b97c5[_0x283298(0x10e)]+'\x27'});if(_0x1b97c5['type']===_0x283298(0x135)&&_0x1b97c5[_0x283298(0x175)]?.['branches'])for(const _0x5f755b of _0x1b97c5[_0x283298(0x175)][_0x283298(0x142)]){_0x5f755b[_0x283298(0x12a)]&&_0x3ac0db(_0x5f755b['next'],{'stepName':_0x1b97c5['name'],'description':_0x283298(0x177)+_0x5f755b[_0x283298(0x10e)]+_0x283298(0x16b)+_0x1b97c5[_0x283298(0x10e)]+'\x27'});}if(_0x1b97c5[_0x283298(0x14a)]===_0x283298(0x158)&&_0x1b97c5[_0x283298(0x175)]?.[_0x283298(0x102)])for(const _0x186f20 of _0x1b97c5[_0x283298(0x175)][_0x283298(0x102)]){_0x186f20[_0x283298(0x12a)]&&_0x3ac0db(_0x186f20[_0x283298(0x12a)],{'stepName':_0x1b97c5[_0x283298(0x10e)],'description':'variant\x20\x27'+_0x186f20[_0x283298(0x10e)]+'\x27\x20of\x20\x27'+_0x1b97c5[_0x283298(0x10e)]+'\x27'});}_0x1b97c5[_0x283298(0x14a)]==='wait'&&_0x1b97c5['with']?.[_0x283298(0x126)]&&(_0x1b97c5[_0x283298(0x175)]['condition']['next']&&_0x3ac0db(_0x1b97c5['with'][_0x283298(0x126)][_0x283298(0x12a)],{'stepName':_0x1b97c5[_0x283298(0x10e)],'description':_0x283298(0x103)+_0x1b97c5[_0x283298(0x10e)]+'\x27'}),_0x1b97c5[_0x283298(0x175)][_0x283298(0x126)][_0x283298(0xed)]?.[_0x283298(0x12a)]&&_0x3ac0db(_0x1b97c5[_0x283298(0x175)][_0x283298(0x126)]['timeout'][_0x283298(0x12a)],{'stepName':_0x1b97c5[_0x283298(0x10e)],'description':_0x283298(0xf7)+_0x1b97c5[_0x283298(0x10e)]+'\x27'}));}return _0xf98baf;}function validateFlowControl(_0x1e824b,_0x555b62,_0x21f55e){const _0x313870=a121_0x23dc,_0x33b476=[],_0x598aa4='stages['+_0x555b62+']',_0x41fc9c=_0x1e824b[_0x313870(0x124)]||[];if(_0x41fc9c[_0x313870(0x161)]===0x0)return _0x33b476;const _0x49b016=new Map();for(const _0x57441d of _0x41fc9c){_0x57441d[_0x313870(0x10e)]&&_0x49b016['set'](_0x57441d[_0x313870(0x10e)],_0x57441d);}const _0x23306b=buildConvergenceMap(_0x41fc9c),_0x224193=_0x41fc9c[_0x313870(0x147)](_0x37bfab=>_0x37bfab['type']===_0x313870(0x178));!_0x224193&&_0x33b476[_0x313870(0x107)](createIssue(_0x313870(0x130),_0x598aa4+_0x313870(0x108),'MISSING_END_STEP',_0x313870(0x15a)+_0x1e824b[_0x313870(0x10e)]+_0x313870(0xf3),_0x21f55e));for(const [_0x2659f8,_0x5dfd3b]of _0x23306b){const _0x8432b4=_0x49b016[_0x313870(0x156)](_0x2659f8);if(!_0x8432b4)continue;if(_0x5dfd3b[_0x313870(0x161)]>0x1&&_0x8432b4['type']!==_0x313870(0x139)){const _0x138fc6=_0x5dfd3b[_0x313870(0xe8)](_0x8e0a3e=>_0x8e0a3e[_0x313870(0xf2)])['join'](',\x20');_0x33b476[_0x313870(0x107)](createIssue(_0x313870(0x130),_0x598aa4+'.steps',_0x313870(0x123),_0x313870(0xfe)+_0x2659f8+'\x27\x20(from:\x20'+_0x138fc6+_0x313870(0x10a),_0x21f55e));}_0x5dfd3b[_0x313870(0x161)]===0x1&&_0x8432b4[_0x313870(0x14a)]==='merge'&&_0x33b476[_0x313870(0x107)](createIssue(_0x313870(0x136),_0x598aa4+_0x313870(0x108),_0x313870(0x179),'Merge\x20step\x20\x27'+_0x2659f8+'\x27\x20has\x20only\x20one\x20input\x20(from:\x20'+_0x5dfd3b[0x0][_0x313870(0xf2)]+_0x313870(0x116),_0x21f55e));}for(const _0x43f113 of _0x41fc9c){if(_0x43f113[_0x313870(0x14a)]===_0x313870(0x139)&&_0x43f113[_0x313870(0x12a)]){const _0x10af2f=_0x49b016[_0x313870(0x156)](_0x43f113[_0x313870(0x12a)]);_0x10af2f?.[_0x313870(0x14a)]===_0x313870(0x139)&&_0x33b476[_0x313870(0x107)](createIssue('error',_0x598aa4+'.steps','MERGE_TO_MERGE_CHAIN','Merge\x20step\x20\x27'+_0x43f113[_0x313870(0x10e)]+_0x313870(0xf0)+_0x43f113['next']+_0x313870(0x16e),_0x21f55e));}}return _0x33b476;}function validateCriteria(_0x4f06af,_0x72684d,_0x18803f){const _0x1dc359=a121_0x23dc,_0xfaed2d=[];return _0x4f06af[_0x1dc359(0xee)]&&(_0x18803f[_0x1dc359(0x173)]?.[_0x1dc359(0x122)](_0x4f06af['segment']),!_0x4f06af[_0x1dc359(0xee)][_0x1dc359(0x145)]('ref:')&&(_0x18803f[_0x1dc359(0x11c)]&&!_0x18803f['embeddedSegments'][_0x1dc359(0x111)](_0x4f06af[_0x1dc359(0xee)])&&_0xfaed2d['push'](createIssue(_0x1dc359(0x130),_0x72684d+_0x1dc359(0xfb),_0x1dc359(0xe9),_0x1dc359(0x180)+_0x4f06af[_0x1dc359(0xee)]+'\x27',_0x18803f)))),_0xfaed2d;}function validateEmbeddedSegment(_0x53f9d4,_0x31a8dd,_0x44fe70){const _0x49a085=a121_0x23dc,_0x522579=[];return _0x53f9d4['rule']&&_0x522579[_0x49a085(0x107)](...validateRuleDef(_0x53f9d4['rule'],_0x31a8dd+_0x49a085(0x132),_0x44fe70)),_0x522579;}function validateStage(_0x40ce6f,_0xcf161e,_0x20780c,_0x9f66e6){const _0x1bf4f1=a121_0x23dc,_0x3b032a=[],_0x5dee59='stages['+_0xcf161e+']',_0x53176f=new Map(),_0x1c5ff2=new Map();if(_0x40ce6f[_0x1bf4f1(0x124)]){for(let _0x1001ce=0x0;_0x1001ce<_0x40ce6f['steps']['length'];_0x1001ce++){const _0x2371b8=_0x40ce6f[_0x1bf4f1(0x124)][_0x1001ce];_0x2371b8[_0x1bf4f1(0x10e)]&&_0x53176f[_0x1bf4f1(0x149)](_0x2371b8[_0x1bf4f1(0x10e)],_0x2371b8);}for(let _0x4e0a11=0x0;_0x4e0a11<_0x40ce6f[_0x1bf4f1(0x124)]['length'];_0x4e0a11++){const _0x2fd861=_0x40ce6f[_0x1bf4f1(0x124)][_0x4e0a11],_0x2fd48d=_0x5dee59+'.steps['+_0x4e0a11+']';if(_0x2fd861[_0x1bf4f1(0x10e)]){if(_0x1c5ff2['has'](_0x2fd861['name'])){const _0x3891e2=_0x1c5ff2['get'](_0x2fd861[_0x1bf4f1(0x10e)]);_0x3b032a[_0x1bf4f1(0x107)](createIssue('error',_0x2fd48d+_0x1bf4f1(0x141),_0x1bf4f1(0x11a),_0x1bf4f1(0x13c)+_0x2fd861[_0x1bf4f1(0x10e)]+_0x1bf4f1(0xf5)+_0x3891e2+'])',_0x9f66e6));}else _0x1c5ff2[_0x1bf4f1(0x149)](_0x2fd861[_0x1bf4f1(0x10e)],_0x4e0a11);}_0x3b032a[_0x1bf4f1(0x107)](...validateStep(_0x2fd861,_0x2fd48d,_0x9f66e6,_0x53176f));}}_0x40ce6f[_0x1bf4f1(0x137)]&&_0x3b032a[_0x1bf4f1(0x107)](...validateCriteria(_0x40ce6f['entry_criteria'],_0x5dee59+_0x1bf4f1(0x125),_0x9f66e6));if(_0x40ce6f[_0x1bf4f1(0x16f)])for(let _0x8f8684=0x0;_0x8f8684<_0x40ce6f[_0x1bf4f1(0x16f)][_0x1bf4f1(0x161)];_0x8f8684++){_0x3b032a[_0x1bf4f1(0x107)](...validateCriteria(_0x40ce6f[_0x1bf4f1(0x16f)][_0x8f8684],_0x5dee59+'.exit_criteria['+_0x8f8684+']',_0x9f66e6));}return _0x40ce6f[_0x1bf4f1(0x109)]&&_0x3b032a[_0x1bf4f1(0x107)](...validateCriteria(_0x40ce6f['milestone'],_0x5dee59+_0x1bf4f1(0x159),_0x9f66e6)),_0x3b032a[_0x1bf4f1(0x107)](...validateStageStructure(_0x40ce6f,_0xcf161e,_0x20780c,_0x9f66e6)),_0x3b032a[_0x1bf4f1(0x107)](...validateFlowControl(_0x40ce6f,_0xcf161e,_0x9f66e6)),_0x3b032a;}function validateStagesForVersion(_0x17ad5b,_0x5151f6,_0x1d840a,_0x48feeb,_0x5c2eb2,_0x34881f,_0x2a837b){const _0x31cccf=a121_0x23dc;if(_0x17ad5b[_0x31cccf(0x161)]===0x0){_0x5c2eb2[_0x31cccf(0x107)]({'level':_0x31cccf(0x130),'path':_0x48feeb+_0x31cccf(0x119),'code':_0x31cccf(0x15d),'message':_0x31cccf(0xeb),'location':getLocationFromPath(_0x1d840a[_0x31cccf(0x17d)],_0x1d840a[_0x31cccf(0x17a)],[_0x31cccf(0x119)])});return;}const _0x2d0074=new Set();for(const _0x4679e3 of _0x17ad5b){if(_0x4679e3[_0x31cccf(0x124)])for(const _0x4975d7 of _0x4679e3[_0x31cccf(0x124)]){_0x4975d7['name']&&_0x2d0074[_0x31cccf(0x122)](_0x4975d7['name']);}}const _0x283bf6={..._0x1d840a,'stepNames':_0x2d0074},_0x4b41f9=validateVersionStructure(_0x17ad5b,_0x283bf6);for(const _0x4d38ad of _0x4b41f9){const _0x356542=_0x48feeb?{..._0x4d38ad,'path':''+_0x48feeb+_0x4d38ad[_0x31cccf(0x16a)]}:_0x4d38ad;if(_0x356542[_0x31cccf(0x14c)]===_0x31cccf(0x130))_0x5c2eb2[_0x31cccf(0x107)](_0x356542);else _0x34881f[_0x31cccf(0x107)](_0x356542);}for(let _0x341a65=0x0;_0x341a65<_0x17ad5b[_0x31cccf(0x161)];_0x341a65++){const _0x247465=validateStage(_0x17ad5b[_0x341a65],_0x341a65,_0x17ad5b[_0x31cccf(0x161)],_0x283bf6);for(const _0x47b344 of _0x247465){const _0x50a2e7=_0x48feeb?{..._0x47b344,'path':''+_0x48feeb+_0x47b344[_0x31cccf(0x16a)]}:_0x47b344;if(_0x50a2e7[_0x31cccf(0x14c)]==='error')_0x5c2eb2['push'](_0x50a2e7);else _0x34881f['push'](_0x50a2e7);}}if(_0x5151f6[_0x31cccf(0x170)]){const _0x5ea5db=_0x2a837b?.[_0x31cccf(0x17b)]?_0x31cccf(0x170):_0x48feeb+_0x31cccf(0x170),_0x35094e=validateCriteria(_0x5151f6['goal'],_0x5ea5db,_0x283bf6);for(const _0x5b2c4e of _0x35094e){if(_0x5b2c4e[_0x31cccf(0x14c)]===_0x31cccf(0x130))_0x5c2eb2['push'](_0x5b2c4e);else _0x34881f[_0x31cccf(0x107)](_0x5b2c4e);}}}function extractVersionIndex(_0x4295dc){const _0x3928e6=_0x4295dc['match'](/^journeys\[(\d+)\]\./);return _0x3928e6?_0x3928e6[0x1]:undefined;}function deduplicateAcrossVersions(_0x2187a1){const _0x312eac=a121_0x23dc,_0x3aece2=new Map();for(let _0x1d9c77=0x0;_0x1d9c77<_0x2187a1['length'];_0x1d9c77++){const _0x5d89b7=_0x2187a1[_0x1d9c77][_0x312eac(0x12d)]+':'+_0x2187a1[_0x1d9c77]['message'],_0x1f8685=extractVersionIndex(_0x2187a1[_0x1d9c77][_0x312eac(0x16a)]),_0x4a6872=_0x3aece2[_0x312eac(0x156)](_0x5d89b7);if(_0x4a6872){_0x4a6872['indices'][_0x312eac(0x107)](_0x1d9c77);if(_0x1f8685)_0x4a6872['versions'][_0x312eac(0x122)](_0x1f8685);}else _0x3aece2['set'](_0x5d89b7,{'indices':[_0x1d9c77],'versions':new Set(_0x1f8685?[_0x1f8685]:[])});}const _0x42b943=new Set();for(const {indices:_0x456dce,versions:_0x1a451b}of _0x3aece2[_0x312eac(0x168)]()){if(_0x1a451b[_0x312eac(0x16c)]<=0x1)continue;const _0x3c3d50=_0x2187a1[_0x456dce[0x0]];_0x3c3d50['path']=_0x3c3d50[_0x312eac(0x16a)]['replace'](/^journeys\[\d+\]\./,''),_0x3c3d50[_0x312eac(0x157)]=_0x3c3d50[_0x312eac(0x157)]+_0x312eac(0x106)+_0x1a451b[_0x312eac(0x16c)]+_0x312eac(0x16d);for(let _0x621a91=0x1;_0x621a91<_0x456dce['length'];_0x621a91++){_0x42b943['add'](_0x456dce[_0x621a91]);}}const _0x4c0c5b=[..._0x42b943]['sort']((_0x4fdb35,_0x4fdfe8)=>_0x4fdfe8-_0x4fdb35);for(const _0x4f42bc of _0x4c0c5b){_0x2187a1[_0x312eac(0x12e)](_0x4f42bc,0x1);}}export function validateJourneyDef(_0x2a0514,_0x473fa0={}){const _0x5cec40=a121_0x23dc,_0xad26b8=[],_0xea908=[];(!_0x2a0514[_0x5cec40(0x10e)]||_0x2a0514[_0x5cec40(0x10e)][_0x5cec40(0x15c)]()==='')&&_0xad26b8['push']({'level':_0x5cec40(0x130),'path':_0x5cec40(0x10e),'code':_0x5cec40(0x133),'message':_0x5cec40(0x105),'location':getLocationFromPath(_0x473fa0[_0x5cec40(0x17d)],_0x473fa0[_0x5cec40(0x17a)],[_0x5cec40(0x10e)])});const _0x89246f=new Set();if(_0x2a0514[_0x5cec40(0xf6)])for(const _0x300891 of Object[_0x5cec40(0x15f)](_0x2a0514[_0x5cec40(0xf6)])){_0x89246f[_0x5cec40(0x122)](_0x300891);}const _0x40c094=new Set();if(_0x2a0514[_0x5cec40(0xfa)])for(const _0x3b1a75 of Object[_0x5cec40(0x15f)](_0x2a0514[_0x5cec40(0xfa)])){_0x40c094[_0x5cec40(0x122)](_0x3b1a75);}const _0x51ffed=new Set(),_0x13d6f4={..._0x473fa0,'embeddedSegments':_0x89246f,'referencedSegments':_0x51ffed,'activationKeys':_0x40c094[_0x5cec40(0x16c)]>0x0?_0x40c094:undefined};if(_0x2a0514[_0x5cec40(0xf6)])for(const [_0x590bad,_0xaf76db]of Object['entries'](_0x2a0514[_0x5cec40(0xf6)])){const _0x1db8e5=validateEmbeddedSegment(_0xaf76db,_0x5cec40(0x100)+_0x590bad,_0x13d6f4);for(const _0x13b9b9 of _0x1db8e5){if(_0x13b9b9[_0x5cec40(0x14c)]===_0x5cec40(0x130))_0xad26b8['push'](_0x13b9b9);else _0xea908['push'](_0x13b9b9);}}const _0x514686=!!_0x2a0514['goal'],_0x125b76=_0x2a0514[_0x5cec40(0x110)]?.[_0x5cec40(0x152)](_0x3ae088=>!!_0x3ae088[_0x5cec40(0x170)])??![];!_0x514686&&!_0x125b76&&_0xea908[_0x5cec40(0x107)]({'level':_0x5cec40(0x136),'path':_0x5cec40(0x170),'code':'MISSING_GOAL','message':'Journey\x20has\x20no\x20goal\x20defined','location':getLocationFromPath(_0x473fa0[_0x5cec40(0x17d)],_0x473fa0['source'],[_0x5cec40(0x170)])});if(_0x2a0514[_0x5cec40(0x110)]&&_0x2a0514[_0x5cec40(0x110)][_0x5cec40(0x161)]>0x0)for(let _0x527486=0x0;_0x527486<_0x2a0514[_0x5cec40(0x110)]['length'];_0x527486++){const _0x2edf89=_0x2a0514[_0x5cec40(0x110)][_0x527486];if(_0x2a0514[_0x5cec40(0x110)][_0x5cec40(0x161)]>0x1&&_0x2edf89['state']===_0x5cec40(0xf8)&&!_0x2edf89[_0x5cec40(0xf4)])continue;const _0x4a9865=_0x2edf89['stages']||[],_0x4446e3='journeys['+_0x527486+'].',_0x3a9562=!!_0x2edf89[_0x5cec40(0x170)],_0x7fbd73=_0x3a9562?{..._0x2a0514,'goal':_0x2edf89[_0x5cec40(0x170)]}:_0x2a0514;validateStagesForVersion(_0x4a9865,_0x7fbd73,_0x13d6f4,_0x4446e3,_0xad26b8,_0xea908,{'goalIsInherited':!_0x3a9562});}else{if(_0x2a0514['versions']&&_0x2a0514['versions'][_0x5cec40(0x161)]>0x0)for(let _0x369fdc=0x0;_0x369fdc<_0x2a0514[_0x5cec40(0x10b)][_0x5cec40(0x161)];_0x369fdc++){const _0x4e4884=_0x2a0514[_0x5cec40(0x10b)][_0x369fdc];if(_0x2a0514[_0x5cec40(0x10b)][_0x5cec40(0x161)]>0x1&&_0x4e4884[_0x5cec40(0x11f)]===_0x5cec40(0xf8)&&!_0x4e4884[_0x5cec40(0xf4)])continue;const _0x29032d=_0x4e4884[_0x5cec40(0x119)]||[],_0x223c11='versions['+_0x369fdc+'].';validateStagesForVersion(_0x29032d,_0x2a0514,_0x13d6f4,_0x223c11,_0xad26b8,_0xea908);}else{const _0x5ae36b=_0x2a0514['stages']||[];validateStagesForVersion(_0x5ae36b,_0x2a0514,_0x13d6f4,'',_0xad26b8,_0xea908);}}_0x2a0514[_0x5cec40(0x110)]&&_0x2a0514['journeys'][_0x5cec40(0x161)]>0x1&&(deduplicateAcrossVersions(_0xad26b8),deduplicateAcrossVersions(_0xea908));for(const _0x379642 of _0x89246f){!_0x51ffed['has'](_0x379642)&&!_0x379642[_0x5cec40(0x145)](_0x5cec40(0x101))&&_0xea908[_0x5cec40(0x107)]({'level':_0x5cec40(0x136),'path':_0x5cec40(0x100)+_0x379642,'code':_0x5cec40(0x160),'message':_0x5cec40(0x13a)+_0x379642+_0x5cec40(0x121),'location':getLocationFromPath(_0x473fa0[_0x5cec40(0x17d)],_0x473fa0[_0x5cec40(0x17a)],[_0x5cec40(0xf6),_0x379642])});}return{'valid':_0xad26b8[_0x5cec40(0x161)]===0x0,'errors':_0xad26b8,'warnings':_0xea908};}
|
|
1
|
+
(function(_0x41e826,_0x3f31bb){const _0x206b97=a121_0x4b8b,_0x3723c8=_0x41e826();while(!![]){try{const _0x347741=-parseInt(_0x206b97(0x1b8))/0x1*(-parseInt(_0x206b97(0x1b4))/0x2)+-parseInt(_0x206b97(0x18a))/0x3*(parseInt(_0x206b97(0x1dd))/0x4)+-parseInt(_0x206b97(0x144))/0x5+-parseInt(_0x206b97(0x18b))/0x6*(parseInt(_0x206b97(0x140))/0x7)+parseInt(_0x206b97(0x1a5))/0x8*(parseInt(_0x206b97(0x1c9))/0x9)+-parseInt(_0x206b97(0x13b))/0xa*(-parseInt(_0x206b97(0x1ce))/0xb)+parseInt(_0x206b97(0x135))/0xc*(parseInt(_0x206b97(0x147))/0xd);if(_0x347741===_0x3f31bb)break;else _0x3723c8['push'](_0x3723c8['shift']());}catch(_0x1df35a){_0x3723c8['push'](_0x3723c8['shift']());}}}(a121_0x20ca,0x2f408));import{getLocationFromPath,pathToArray,validateRuleDef}from'./yaml-validator.js';const MAX_STAGES=0x8;function createIssue(_0x5792a4,_0x51cf40,_0x49e089,_0x20cbef,_0x15f2cb,_0x22cbf0){const _0x107dc6=a121_0x4b8b;return{'level':_0x5792a4,'path':_0x51cf40,'code':_0x49e089,'message':_0x20cbef,'location':getLocationFromPath(_0x15f2cb[_0x107dc6(0x182)],_0x15f2cb['source'],pathToArray(_0x22cbf0??_0x51cf40))};}function validateVersionStructure(_0x249770,_0x11ba50){const _0x39e0d0=a121_0x4b8b,_0x5e712e=[];return _0x249770['length']>MAX_STAGES&&_0x5e712e[_0x39e0d0(0x17b)](createIssue('error','stages',_0x39e0d0(0x184),'Journey\x20has\x20'+_0x249770[_0x39e0d0(0x14b)]+'\x20stages\x20but\x20maximum\x20is\x20'+MAX_STAGES,_0x11ba50)),_0x5e712e;}function validateStageStructure(_0x5637a1,_0x2a9aa1,_0x348154,_0x1fcb09){const _0x4696ce=a121_0x4b8b,_0x487de4=[],_0x3c2341=_0x4696ce(0x14f)+_0x2a9aa1+']';_0x2a9aa1===0x0&&!_0x5637a1['entry_criteria']&&_0x487de4[_0x4696ce(0x17b)](createIssue(_0x4696ce(0x1be),_0x3c2341+_0x4696ce(0x1c2),_0x4696ce(0x192),_0x4696ce(0x1ab)+_0x5637a1['name']+_0x4696ce(0x163),_0x1fcb09,_0x3c2341));const _0x3e63f1=_0x2a9aa1===_0x348154-0x1;!_0x3e63f1&&!_0x5637a1['milestone']&&_0x487de4[_0x4696ce(0x17b)](createIssue(_0x4696ce(0x1be),_0x3c2341+_0x4696ce(0x1d7),_0x4696ce(0x19d),_0x4696ce(0x1ab)+_0x5637a1[_0x4696ce(0x16a)]+_0x4696ce(0x1bc),_0x1fcb09,_0x3c2341));(!_0x5637a1['exit_criteria']||_0x5637a1[_0x4696ce(0x165)][_0x4696ce(0x14b)]===0x0)&&_0x487de4[_0x4696ce(0x17b)](createIssue(_0x4696ce(0x1d1),_0x3c2341+'.exit_criteria',_0x4696ce(0x14a),_0x4696ce(0x1ab)+_0x5637a1[_0x4696ce(0x16a)]+_0x4696ce(0x1d9),_0x1fcb09,_0x3c2341));const _0x2cd002=_0x5637a1[_0x4696ce(0x1a2)]?.[_0x4696ce(0x14b)]??0x0;if(_0x2cd002===0x0)_0x487de4[_0x4696ce(0x17b)](createIssue(_0x4696ce(0x1be),_0x3c2341+_0x4696ce(0x179),_0x4696ce(0x155),_0x4696ce(0x1ab)+_0x5637a1[_0x4696ce(0x16a)]+'\x27\x20has\x20no\x20steps',_0x1fcb09,_0x3c2341+_0x4696ce(0x179)));else{if(_0x2cd002===0x1)_0x487de4[_0x4696ce(0x17b)](createIssue(_0x4696ce(0x1d1),_0x3c2341+_0x4696ce(0x179),'INSUFFICIENT_STEPS',_0x4696ce(0x1ab)+_0x5637a1[_0x4696ce(0x16a)]+'\x27\x20has\x20only\x201\x20step\x20(may\x20be\x20too\x20simple)',_0x1fcb09,_0x3c2341+'.steps'));else _0x2cd002<=0x3&&_0x487de4[_0x4696ce(0x17b)](createIssue(_0x4696ce(0x1d1),_0x3c2341+_0x4696ce(0x179),'FEW_STEPS',_0x4696ce(0x1ab)+_0x5637a1[_0x4696ce(0x16a)]+'\x27\x20has\x20only\x20'+_0x2cd002+_0x4696ce(0x1b9),_0x1fcb09,_0x3c2341+'.steps'));}return _0x487de4;}function validateStep(_0xf8574a,_0x535f8c,_0x35f723,_0x2e1ed2){const _0x1edabb=a121_0x4b8b,_0x164d55=[];if(_0xf8574a['type']===_0x1edabb(0x15e))return _0xf8574a[_0x1edabb(0x1d8)]&&_0x164d55[_0x1edabb(0x17b)](createIssue('error',_0x535f8c+'.next',_0x1edabb(0x1b1),_0x1edabb(0x18e)+_0xf8574a['name']+_0x1edabb(0x1a8),_0x35f723)),_0x1edabb(0x17a)in _0xf8574a&&_0xf8574a[_0x1edabb(0x17a)]!==undefined&&_0x164d55[_0x1edabb(0x17b)](createIssue(_0x1edabb(0x1be),_0x535f8c+'.with','END_STEP_HAS_NEXT_OR_WITH',_0x1edabb(0x18e)+_0xf8574a[_0x1edabb(0x16a)]+_0x1edabb(0x146),_0x35f723)),_0x164d55;_0xf8574a[_0x1edabb(0x1d8)]&&(_0x35f723[_0x1edabb(0x183)]&&!_0x35f723[_0x1edabb(0x183)][_0x1edabb(0x19f)](_0xf8574a['next'])&&_0x164d55[_0x1edabb(0x17b)](createIssue('error',_0x535f8c+_0x1edabb(0x14c),_0x1edabb(0x148),_0x1edabb(0x168)+_0xf8574a['next']+'\x27',_0x35f723)));switch(_0xf8574a[_0x1edabb(0x151)]){case'wait':_0x164d55['push'](...validateWaitStep(_0xf8574a,_0x535f8c,_0x35f723,_0x2e1ed2));break;case'activation':_0x164d55[_0x1edabb(0x17b)](...validateActivationStep(_0xf8574a,_0x535f8c,_0x35f723));break;case'decision_point':_0x164d55['push'](...validateDecisionPointStep(_0xf8574a,_0x535f8c,_0x35f723,_0x2e1ed2));break;case _0x1edabb(0x13d):_0x164d55['push'](...validateAbTestStep(_0xf8574a,_0x535f8c,_0x35f723,_0x2e1ed2));break;case _0x1edabb(0x16b):_0x164d55[_0x1edabb(0x17b)](...validateJumpStep(_0xf8574a,_0x535f8c,_0x35f723));break;}return _0x164d55;}function a121_0x4b8b(_0x5b790f,_0x503deb){_0x5b790f=_0x5b790f-0x134;const _0x20ca84=a121_0x20ca();let _0x4b8b45=_0x20ca84[_0x5b790f];return _0x4b8b45;}function validateWaitStep(_0x127991,_0x131399,_0x212c2d,_0x29c54c){const _0x52da90=a121_0x4b8b,_0x20eed6=[];if(!_0x127991[_0x52da90(0x17a)])return _0x20eed6[_0x52da90(0x17b)](createIssue('error',_0x131399+_0x52da90(0x1e0),_0x52da90(0x169),'Wait\x20step\x20requires\x20parameters\x20in\x20\x22with\x22\x20field',_0x212c2d,_0x131399)),_0x20eed6;if(_0x127991[_0x52da90(0x17a)][_0x52da90(0x1cf)]){const _0x10d9b1=_0x127991[_0x52da90(0x17a)][_0x52da90(0x1cf)];if(_0x10d9b1[_0x52da90(0x1d2)]){_0x212c2d[_0x52da90(0x15b)]?.[_0x52da90(0x1d4)](_0x10d9b1[_0x52da90(0x1d2)]);!_0x10d9b1[_0x52da90(0x1d2)]['startsWith'](_0x52da90(0x176))&&(_0x212c2d[_0x52da90(0x1da)]&&!_0x212c2d[_0x52da90(0x1da)][_0x52da90(0x19f)](_0x10d9b1['segment'])&&_0x20eed6['push'](createIssue('error',_0x131399+_0x52da90(0x157),_0x52da90(0x134),_0x52da90(0x18c)+_0x10d9b1[_0x52da90(0x1d2)]+_0x52da90(0x177),_0x212c2d)));_0x10d9b1[_0x52da90(0x1d8)]&&_0x212c2d['stepNames']&&!_0x212c2d['stepNames'][_0x52da90(0x19f)](_0x10d9b1[_0x52da90(0x1d8)])&&_0x20eed6['push'](createIssue(_0x52da90(0x1be),_0x131399+'.with.condition.next',_0x52da90(0x148),'Wait\x20condition\x20references\x20non-existent\x20step\x20\x27'+_0x10d9b1[_0x52da90(0x1d8)]+'\x27',_0x212c2d));_0x10d9b1[_0x52da90(0x1cc)]?.[_0x52da90(0x1d8)]&&_0x212c2d[_0x52da90(0x183)]&&!_0x212c2d[_0x52da90(0x183)][_0x52da90(0x19f)](_0x10d9b1['timeout'][_0x52da90(0x1d8)])&&_0x20eed6[_0x52da90(0x17b)](createIssue('error',_0x131399+_0x52da90(0x1c3),_0x52da90(0x148),'Wait\x20timeout\x20references\x20non-existent\x20step\x20\x27'+_0x10d9b1[_0x52da90(0x1cc)]['next']+'\x27',_0x212c2d));const _0x2876b0=_0x10d9b1['next']||_0x127991['next'],_0x3d8b6a=_0x10d9b1['timeout']?.['next']||_0x127991[_0x52da90(0x1d8)];if(_0x2876b0){const _0xa5b015=_0x29c54c[_0x52da90(0x145)](_0x2876b0);_0xa5b015?.[_0x52da90(0x151)]===_0x52da90(0x1c6)&&_0x20eed6[_0x52da90(0x17b)](createIssue(_0x52da90(0x1d1),_0x131399+_0x52da90(0x17f),_0x52da90(0x138),'Wait\x20condition\x20matched\x20path\x20goes\x20directly\x20to\x20merge\x20step\x20\x27'+_0x2876b0+_0x52da90(0x14e),_0x212c2d,_0x131399+_0x52da90(0x162)));}if(_0x3d8b6a){const _0x1a384f=_0x29c54c[_0x52da90(0x145)](_0x3d8b6a);_0x1a384f?.[_0x52da90(0x151)]===_0x52da90(0x1c6)&&_0x20eed6[_0x52da90(0x17b)](createIssue(_0x52da90(0x1d1),_0x131399+_0x52da90(0x1c3),_0x52da90(0x138),_0x52da90(0x1a3)+_0x3d8b6a+_0x52da90(0x14e),_0x212c2d,_0x131399+_0x52da90(0x178)));}}}return _0x20eed6;}function validateActivationStep(_0x20cda1,_0x4adb23,_0x100420){const _0x49eae0=a121_0x4b8b,_0x315bc8=[];if(!_0x20cda1[_0x49eae0(0x17a)]?.['activation'])return _0x315bc8['push'](createIssue(_0x49eae0(0x1be),_0x4adb23+_0x49eae0(0x1c8),_0x49eae0(0x181),_0x49eae0(0x18f),_0x100420,_0x4adb23)),_0x315bc8;const _0x48b551=_0x20cda1['with'][_0x49eae0(0x167)];return _0x100420[_0x49eae0(0x152)]&&!_0x48b551[_0x49eae0(0x16d)](_0x49eae0(0x176))&&(!_0x100420['activationKeys'][_0x49eae0(0x19f)](_0x48b551)&&_0x315bc8['push'](createIssue(_0x49eae0(0x1be),_0x4adb23+'.with.activation',_0x49eae0(0x174),_0x49eae0(0x1a4)+_0x48b551+_0x49eae0(0x1a9),_0x100420))),_0x315bc8;}function a121_0x20ca(){const _0x28da94=['\x27\x20is\x20missing\x20entry_criteria\x20(required\x20for\x20the\x20first\x20stage)','\x20versions)','exit_criteria','UNUSED_EMBEDDED_SEGMENT','activation','Step\x20references\x20non-existent\x20step\x20\x27','MISSING_WAIT_PARAMS','name','jump','size','startsWith','Embedded\x20segment\x20\x27','source','INVALID_AB_TEST_PERCENTAGES','Journey\x20must\x20have\x20at\x20least\x20one\x20stage','journeys','excluded_','MISSING_ACTIVATION_DEFINITION','\x27\x20has\x20no\x20end\x20step','ref:','\x27.\x20Define\x20it\x20in\x20the\x20\x27segments\x27\x20section\x20or\x20use\x20\x27ref:Segment\x20Name\x27\x20for\x20external\x20segments.','.with.condition.timeout','.steps','with','push','sort','SINGLE_INPUT_MERGE','timeout\x20of\x20\x27','.with.condition.next','\x27.\x20Merge\x20chains\x20are\x20not\x20allowed.','MISSING_ACTIVATION_REF','document','stepNames','TOO_MANY_STAGES','target','condition\x20of\x20\x27','\x27\x20(first\x20defined\x20at\x20steps[','Duplicate\x20step\x20name\x20\x27','\x27\x20of\x20\x27','545988fEGjuT','105564hgINdq','Wait\x20condition\x20references\x20undefined\x20segment\x20\x27','MISSING_STAGES','End\x20step\x20\x27','Activation\x20step\x20requires\x20an\x20activation\x20reference','goal','abs','MISSING_ENTRY_CRITERIA','\x27\x20goes\x20directly\x20to\x20merge\x20step\x20\x27','Jump\x20target\x20requires\x20both\x20journey\x20and\x20stage\x20names','journeys[','.with.variants[','CONVERGENCE_WITHOUT_MERGE','excluded','MISSING_END_STEP','variants','level','Criteria\x20references\x20undefined\x20segment\x20\x27','MISSING_MILESTONE','\x27\x20with\x20no\x20action\x20in\x20between','has',').\x20Merge\x20is\x20unnecessary.','trim','steps','Wait\x20condition\x20timeout\x20path\x20goes\x20directly\x20to\x20merge\x20step\x20\x27','Activation\x20step\x20references\x20undefined\x20activation\x20\x27','150624eoUTJR','.with.variants','Journey\x20has\x20no\x20goal\x20defined','\x27\x20should\x20not\x20have\x20a\x20\x27next\x27\x20field','\x27.\x20Define\x20it\x20in\x20the\x20\x27activations\x27\x20section\x20or\x20use\x20\x27ref:Name\x27\x20for\x20external\x20activations.','latest','Stage\x20\x27','activations','segments','versions[','.exit_criteria[','.steps[','END_STEP_HAS_NEXT_OR_WITH','.with.target','set','554dUBBjD','MISSING_GOAL','.segment','path','271MuuAyp','\x20steps\x20(may\x20be\x20too\x20simple)','versions','Decision\x20branch\x20\x27','\x27\x20(non-last\x20stage)\x20is\x20missing\x20a\x20milestone','milestone','error','state','journey','entry_criteria','.entry_criteria','.with.condition.timeout.next','message','Jump\x20step\x20requires\x20a\x20target','merge','keys','.with.activation','18veAQAd','INVALID_JUMP_TARGET','Decision\x20point\x20requires\x20at\x20least\x20one\x20branch','timeout','.with.branches[','99toBJFf','condition','.name','warning','segment','Decision\x20branch\x20references\x20undefined\x20segment\x20\x27','add','\x27\x20leads\x20to\x20another\x20merge\x20step\x20\x27','Merge\x20step\x20\x27','.milestone','next','\x27\x20has\x20no\x20exit_criteria\x20defined','embeddedSegments','indices','splice','8MWrmsN','A/B\x20test\x20variant\x20\x27','MISSING_NAME','.with','MISSING_SEGMENT_REFERENCE','34212uJdTTc','MERGE_TO_MERGE_CHAIN','description','BRANCH_DIRECTLY_TO_MERGE','goalIsInherited',').\x20Use\x20a\x20merge\x20step.','82310odlhzK','some','ab_test','code','A/B\x20test\x20requires\x20at\x20least\x20one\x20variant','42bYHKqR','rule','\x27\x20(from:\x20','\x27\x20is\x20defined\x20but\x20not\x20referenced\x20in\x20the\x20journey','626315qzynAl','get','\x27\x20should\x20not\x20have\x20a\x20\x27with\x27\x20field','2743eLHZLk','INVALID_NEXT_REFERENCE','branch\x20\x27','MISSING_EXIT_CRITERIA','length','.next','stages','\x27\x20with\x20no\x20action.\x20Each\x20branch\x20of\x20a\x20condition\x20wait\x20must\x20perform\x20a\x20different\x20action.','stages[','segments.','type','activationKeys','branches','launched','INSUFFICIENT_STEPS','values','.with.condition.segment','A/B\x20test\x20variant\x20references\x20non-existent\x20step\x20\x27','map','decision_point','referencedSegments','MISSING_CONDITIONS','every','end','stage','Decision\x20branch\x20references\x20non-existent\x20step\x20\x27','Multiple\x20paths\x20converge\x20on\x20non-merge\x20step\x20\x27','.with.condition'];a121_0x20ca=function(){return _0x28da94;};return a121_0x20ca();}function validateDecisionPointStep(_0x3d4faa,_0x328411,_0x4bd5c7,_0x15e90d){const _0x188ea0=a121_0x4b8b,_0x19ab96=[];if(!_0x3d4faa[_0x188ea0(0x17a)]?.['branches']||_0x3d4faa[_0x188ea0(0x17a)][_0x188ea0(0x153)]['length']===0x0)return _0x19ab96[_0x188ea0(0x17b)](createIssue(_0x188ea0(0x1be),_0x328411+'.with.branches',_0x188ea0(0x15c),_0x188ea0(0x1cb),_0x4bd5c7,_0x328411)),_0x19ab96;for(let _0x5978b5=0x0;_0x5978b5<_0x3d4faa[_0x188ea0(0x17a)][_0x188ea0(0x153)][_0x188ea0(0x14b)];_0x5978b5++){const _0x3e0451=_0x3d4faa[_0x188ea0(0x17a)][_0x188ea0(0x153)][_0x5978b5],_0x30b91f=_0x328411+_0x188ea0(0x1cd)+_0x5978b5+']';_0x3e0451['segment']&&!_0x3e0451[_0x188ea0(0x198)]&&(_0x4bd5c7[_0x188ea0(0x15b)]?.[_0x188ea0(0x1d4)](_0x3e0451[_0x188ea0(0x1d2)]),!_0x3e0451['segment']['startsWith']('ref:')&&(_0x4bd5c7[_0x188ea0(0x1da)]&&!_0x4bd5c7[_0x188ea0(0x1da)][_0x188ea0(0x19f)](_0x3e0451[_0x188ea0(0x1d2)])&&_0x19ab96[_0x188ea0(0x17b)](createIssue(_0x188ea0(0x1be),_0x30b91f+_0x188ea0(0x1b6),_0x188ea0(0x134),_0x188ea0(0x1d3)+_0x3e0451[_0x188ea0(0x1d2)]+'\x27',_0x4bd5c7))));_0x3e0451[_0x188ea0(0x1d8)]&&_0x4bd5c7[_0x188ea0(0x183)]&&!_0x4bd5c7['stepNames']['has'](_0x3e0451['next'])&&_0x19ab96[_0x188ea0(0x17b)](createIssue(_0x188ea0(0x1be),_0x30b91f+_0x188ea0(0x14c),'INVALID_NEXT_REFERENCE',_0x188ea0(0x160)+_0x3e0451['next']+'\x27',_0x4bd5c7));if(_0x3e0451[_0x188ea0(0x1d8)]){const _0x217436=_0x15e90d[_0x188ea0(0x145)](_0x3e0451[_0x188ea0(0x1d8)]);_0x217436?.[_0x188ea0(0x151)]==='merge'&&_0x19ab96[_0x188ea0(0x17b)](createIssue('warning',_0x30b91f+_0x188ea0(0x14c),_0x188ea0(0x138),_0x188ea0(0x1bb)+_0x3e0451[_0x188ea0(0x16a)]+'\x27\x20goes\x20directly\x20to\x20merge\x20step\x20\x27'+_0x3e0451['next']+_0x188ea0(0x19e),_0x4bd5c7));}}return _0x19ab96;}function validateAbTestStep(_0xd3a348,_0x2bc976,_0x573399,_0x12e3f7){const _0x26f0a6=a121_0x4b8b,_0x315b8e=[];if(!_0xd3a348[_0x26f0a6(0x17a)]?.[_0x26f0a6(0x19a)]||_0xd3a348[_0x26f0a6(0x17a)]['variants'][_0x26f0a6(0x14b)]===0x0)return _0x315b8e[_0x26f0a6(0x17b)](createIssue(_0x26f0a6(0x1be),_0x2bc976+_0x26f0a6(0x1a6),_0x26f0a6(0x15c),_0x26f0a6(0x13f),_0x573399,_0x2bc976)),_0x315b8e;const _0x341fcf=_0xd3a348[_0x26f0a6(0x17a)][_0x26f0a6(0x19a)]['reduce']((_0x5a9acb,_0x11dfa4)=>_0x5a9acb+(_0x11dfa4['percentage']||0x0),0x0);Math[_0x26f0a6(0x191)](_0x341fcf-0x64)>0.01&&_0x315b8e[_0x26f0a6(0x17b)](createIssue(_0x26f0a6(0x1be),_0x2bc976+_0x26f0a6(0x1a6),_0x26f0a6(0x170),'A/B\x20test\x20variant\x20percentages\x20must\x20sum\x20to\x20100%\x20(got\x20'+_0x341fcf+'%)',_0x573399));for(let _0x16cd19=0x0;_0x16cd19<_0xd3a348[_0x26f0a6(0x17a)]['variants'][_0x26f0a6(0x14b)];_0x16cd19++){const _0x17a1f4=_0xd3a348[_0x26f0a6(0x17a)][_0x26f0a6(0x19a)][_0x16cd19],_0x47a3ef=_0x2bc976+_0x26f0a6(0x196)+_0x16cd19+']';_0x17a1f4[_0x26f0a6(0x1d8)]&&_0x573399[_0x26f0a6(0x183)]&&!_0x573399[_0x26f0a6(0x183)]['has'](_0x17a1f4['next'])&&_0x315b8e[_0x26f0a6(0x17b)](createIssue(_0x26f0a6(0x1be),_0x47a3ef+_0x26f0a6(0x14c),_0x26f0a6(0x148),_0x26f0a6(0x158)+_0x17a1f4[_0x26f0a6(0x1d8)]+'\x27',_0x573399));if(_0x17a1f4[_0x26f0a6(0x1d8)]){const _0x51bfd8=_0x12e3f7[_0x26f0a6(0x145)](_0x17a1f4[_0x26f0a6(0x1d8)]);_0x51bfd8?.[_0x26f0a6(0x151)]==='merge'&&_0x315b8e[_0x26f0a6(0x17b)](createIssue(_0x26f0a6(0x1d1),_0x47a3ef+_0x26f0a6(0x14c),'BRANCH_DIRECTLY_TO_MERGE',_0x26f0a6(0x1de)+_0x17a1f4[_0x26f0a6(0x16a)]+_0x26f0a6(0x193)+_0x17a1f4[_0x26f0a6(0x1d8)]+'\x27\x20with\x20no\x20action\x20in\x20between',_0x573399));}}return _0x315b8e;}function validateJumpStep(_0x3b9491,_0x5ab8a1,_0x5245a5){const _0x32f6ad=a121_0x4b8b,_0x38fad7=[];if(!_0x3b9491[_0x32f6ad(0x17a)]?.[_0x32f6ad(0x185)])return _0x38fad7[_0x32f6ad(0x17b)](createIssue(_0x32f6ad(0x1be),_0x5ab8a1+_0x32f6ad(0x1b2),'INVALID_JUMP_TARGET',_0x32f6ad(0x1c5),_0x5245a5,_0x5ab8a1)),_0x38fad7;return(!_0x3b9491['with'][_0x32f6ad(0x185)][_0x32f6ad(0x1c0)]||!_0x3b9491['with'][_0x32f6ad(0x185)][_0x32f6ad(0x15f)])&&_0x38fad7[_0x32f6ad(0x17b)](createIssue(_0x32f6ad(0x1be),_0x5ab8a1+'.with.target',_0x32f6ad(0x1ca),_0x32f6ad(0x194),_0x5245a5)),_0x38fad7;}function buildConvergenceMap(_0x345048){const _0x239af0=a121_0x4b8b,_0x2af7e2=new Map();function _0x4cb8af(_0x369a53,_0x4032d5){const _0x395254=a121_0x4b8b,_0x37b637=_0x2af7e2[_0x395254(0x145)](_0x369a53)||[];_0x37b637[_0x395254(0x17b)](_0x4032d5),_0x2af7e2[_0x395254(0x1b3)](_0x369a53,_0x37b637);}for(const _0x539d2 of _0x345048){_0x539d2[_0x239af0(0x1d8)]&&_0x4cb8af(_0x539d2['next'],{'stepName':_0x539d2['name'],'description':'step\x20\x27'+_0x539d2[_0x239af0(0x16a)]+'\x27'});if(_0x539d2[_0x239af0(0x151)]===_0x239af0(0x15a)&&_0x539d2[_0x239af0(0x17a)]?.[_0x239af0(0x153)])for(const _0x290128 of _0x539d2[_0x239af0(0x17a)]['branches']){_0x290128[_0x239af0(0x1d8)]&&_0x4cb8af(_0x290128[_0x239af0(0x1d8)],{'stepName':_0x539d2[_0x239af0(0x16a)],'description':_0x239af0(0x149)+_0x290128[_0x239af0(0x16a)]+_0x239af0(0x189)+_0x539d2[_0x239af0(0x16a)]+'\x27'});}if(_0x539d2['type']===_0x239af0(0x13d)&&_0x539d2[_0x239af0(0x17a)]?.[_0x239af0(0x19a)])for(const _0x4e11e0 of _0x539d2[_0x239af0(0x17a)][_0x239af0(0x19a)]){_0x4e11e0['next']&&_0x4cb8af(_0x4e11e0[_0x239af0(0x1d8)],{'stepName':_0x539d2[_0x239af0(0x16a)],'description':'variant\x20\x27'+_0x4e11e0[_0x239af0(0x16a)]+_0x239af0(0x189)+_0x539d2[_0x239af0(0x16a)]+'\x27'});}_0x539d2[_0x239af0(0x151)]==='wait'&&_0x539d2['with']?.[_0x239af0(0x1cf)]&&(_0x539d2[_0x239af0(0x17a)][_0x239af0(0x1cf)]['next']&&_0x4cb8af(_0x539d2[_0x239af0(0x17a)]['condition'][_0x239af0(0x1d8)],{'stepName':_0x539d2[_0x239af0(0x16a)],'description':_0x239af0(0x186)+_0x539d2[_0x239af0(0x16a)]+'\x27'}),_0x539d2[_0x239af0(0x17a)][_0x239af0(0x1cf)][_0x239af0(0x1cc)]?.[_0x239af0(0x1d8)]&&_0x4cb8af(_0x539d2[_0x239af0(0x17a)][_0x239af0(0x1cf)][_0x239af0(0x1cc)][_0x239af0(0x1d8)],{'stepName':_0x539d2[_0x239af0(0x16a)],'description':_0x239af0(0x17e)+_0x539d2['name']+'\x27'}));}return _0x2af7e2;}function validateFlowControl(_0x27a75f,_0x286c32,_0x407ac9){const _0xee2639=a121_0x4b8b,_0x1768d5=[],_0x2ef0b3=_0xee2639(0x14f)+_0x286c32+']',_0x5622e4=_0x27a75f[_0xee2639(0x1a2)]||[];if(_0x5622e4[_0xee2639(0x14b)]===0x0)return _0x1768d5;const _0x173bbd=new Map();for(const _0x4da88 of _0x5622e4){_0x4da88[_0xee2639(0x16a)]&&_0x173bbd[_0xee2639(0x1b3)](_0x4da88[_0xee2639(0x16a)],_0x4da88);}const _0x305367=buildConvergenceMap(_0x5622e4),_0x544430=_0x5622e4[_0xee2639(0x13c)](_0x276281=>_0x276281['type']===_0xee2639(0x15e));!_0x544430&&_0x1768d5['push'](createIssue(_0xee2639(0x1be),_0x2ef0b3+_0xee2639(0x179),_0xee2639(0x199),_0xee2639(0x1ab)+_0x27a75f[_0xee2639(0x16a)]+_0xee2639(0x175),_0x407ac9));for(const [_0x3205c0,_0x5a1ead]of _0x305367){const _0x75414a=_0x173bbd[_0xee2639(0x145)](_0x3205c0);if(!_0x75414a)continue;if(_0x5a1ead[_0xee2639(0x14b)]>0x1&&_0x75414a[_0xee2639(0x151)]!==_0xee2639(0x1c6)){const _0x36d049=_0x5a1ead[_0xee2639(0x159)](_0x3b21d5=>_0x3b21d5[_0xee2639(0x137)])['join'](',\x20');_0x1768d5[_0xee2639(0x17b)](createIssue(_0xee2639(0x1be),_0x2ef0b3+_0xee2639(0x179),_0xee2639(0x197),_0xee2639(0x161)+_0x3205c0+_0xee2639(0x142)+_0x36d049+_0xee2639(0x13a),_0x407ac9));}_0x5a1ead[_0xee2639(0x14b)]===0x1&&_0x75414a[_0xee2639(0x151)]===_0xee2639(0x1c6)&&_0x1768d5[_0xee2639(0x17b)](createIssue('warning',_0x2ef0b3+_0xee2639(0x179),_0xee2639(0x17d),_0xee2639(0x1d6)+_0x3205c0+'\x27\x20has\x20only\x20one\x20input\x20(from:\x20'+_0x5a1ead[0x0][_0xee2639(0x137)]+_0xee2639(0x1a0),_0x407ac9));}for(const _0x21a882 of _0x5622e4){if(_0x21a882[_0xee2639(0x151)]===_0xee2639(0x1c6)&&_0x21a882[_0xee2639(0x1d8)]){const _0x5670c7=_0x173bbd[_0xee2639(0x145)](_0x21a882['next']);_0x5670c7?.[_0xee2639(0x151)]===_0xee2639(0x1c6)&&_0x1768d5[_0xee2639(0x17b)](createIssue('error',_0x2ef0b3+'.steps',_0xee2639(0x136),_0xee2639(0x1d6)+_0x21a882[_0xee2639(0x16a)]+_0xee2639(0x1d5)+_0x21a882[_0xee2639(0x1d8)]+_0xee2639(0x180),_0x407ac9));}}return _0x1768d5;}function validateCriteria(_0x2d6883,_0x5d3ae6,_0xa5bd7){const _0x4fde50=a121_0x4b8b,_0x5215c0=[];return _0x2d6883[_0x4fde50(0x1d2)]&&(_0xa5bd7[_0x4fde50(0x15b)]?.[_0x4fde50(0x1d4)](_0x2d6883[_0x4fde50(0x1d2)]),!_0x2d6883[_0x4fde50(0x1d2)][_0x4fde50(0x16d)]('ref:')&&(_0xa5bd7[_0x4fde50(0x1da)]&&!_0xa5bd7[_0x4fde50(0x1da)][_0x4fde50(0x19f)](_0x2d6883[_0x4fde50(0x1d2)])&&_0x5215c0[_0x4fde50(0x17b)](createIssue(_0x4fde50(0x1be),_0x5d3ae6+_0x4fde50(0x1b6),'MISSING_SEGMENT_REFERENCE',_0x4fde50(0x19c)+_0x2d6883[_0x4fde50(0x1d2)]+'\x27',_0xa5bd7)))),_0x5215c0;}function validateEmbeddedSegment(_0x1b51bc,_0x256a4e,_0x55e353){const _0x20aded=a121_0x4b8b,_0x3c9c70=[];return _0x1b51bc[_0x20aded(0x141)]&&_0x3c9c70[_0x20aded(0x17b)](...validateRuleDef(_0x1b51bc[_0x20aded(0x141)],_0x256a4e+'.rule',_0x55e353)),_0x3c9c70;}function validateStage(_0x7bf841,_0x4912c1,_0x3dc1c5,_0x35a699){const _0x114168=a121_0x4b8b,_0x2a839f=[],_0x562256=_0x114168(0x14f)+_0x4912c1+']',_0x1bcf87=new Map(),_0x5c1a78=new Map();if(_0x7bf841[_0x114168(0x1a2)]){for(let _0x2235de=0x0;_0x2235de<_0x7bf841['steps'][_0x114168(0x14b)];_0x2235de++){const _0x2a7ac3=_0x7bf841[_0x114168(0x1a2)][_0x2235de];_0x2a7ac3[_0x114168(0x16a)]&&_0x1bcf87[_0x114168(0x1b3)](_0x2a7ac3[_0x114168(0x16a)],_0x2a7ac3);}for(let _0xbb3fc0=0x0;_0xbb3fc0<_0x7bf841['steps']['length'];_0xbb3fc0++){const _0x5318eb=_0x7bf841[_0x114168(0x1a2)][_0xbb3fc0],_0x4a6c48=_0x562256+_0x114168(0x1b0)+_0xbb3fc0+']';if(_0x5318eb[_0x114168(0x16a)]){if(_0x5c1a78[_0x114168(0x19f)](_0x5318eb['name'])){const _0x4b27e5=_0x5c1a78[_0x114168(0x145)](_0x5318eb[_0x114168(0x16a)]);_0x2a839f[_0x114168(0x17b)](createIssue(_0x114168(0x1be),_0x4a6c48+_0x114168(0x1d0),'DUPLICATE_STEP_NAME',_0x114168(0x188)+_0x5318eb[_0x114168(0x16a)]+_0x114168(0x187)+_0x4b27e5+'])',_0x35a699));}else _0x5c1a78['set'](_0x5318eb[_0x114168(0x16a)],_0xbb3fc0);}_0x2a839f[_0x114168(0x17b)](...validateStep(_0x5318eb,_0x4a6c48,_0x35a699,_0x1bcf87));}}_0x7bf841[_0x114168(0x1c1)]&&_0x2a839f['push'](...validateCriteria(_0x7bf841[_0x114168(0x1c1)],_0x562256+_0x114168(0x1c2),_0x35a699));if(_0x7bf841['exit_criteria'])for(let _0x550377=0x0;_0x550377<_0x7bf841[_0x114168(0x165)]['length'];_0x550377++){_0x2a839f[_0x114168(0x17b)](...validateCriteria(_0x7bf841[_0x114168(0x165)][_0x550377],_0x562256+_0x114168(0x1af)+_0x550377+']',_0x35a699));}return _0x7bf841[_0x114168(0x1bd)]&&_0x2a839f['push'](...validateCriteria(_0x7bf841[_0x114168(0x1bd)],_0x562256+_0x114168(0x1d7),_0x35a699)),_0x2a839f['push'](...validateStageStructure(_0x7bf841,_0x4912c1,_0x3dc1c5,_0x35a699)),_0x2a839f[_0x114168(0x17b)](...validateFlowControl(_0x7bf841,_0x4912c1,_0x35a699)),_0x2a839f;}function validateStagesForVersion(_0xeab761,_0x1c4de2,_0x18b1d0,_0x1f62d4,_0x3b99a5,_0x442982,_0x252aec){const _0x3d499b=a121_0x4b8b;if(_0xeab761[_0x3d499b(0x14b)]===0x0){_0x3b99a5[_0x3d499b(0x17b)]({'level':_0x3d499b(0x1be),'path':_0x1f62d4+_0x3d499b(0x14d),'code':_0x3d499b(0x18d),'message':_0x3d499b(0x171),'location':getLocationFromPath(_0x18b1d0[_0x3d499b(0x182)],_0x18b1d0[_0x3d499b(0x16f)],[_0x3d499b(0x14d)])});return;}const _0x13814c=new Set();for(const _0x5523c3 of _0xeab761){if(_0x5523c3[_0x3d499b(0x1a2)])for(const _0x4c451a of _0x5523c3[_0x3d499b(0x1a2)]){_0x4c451a[_0x3d499b(0x16a)]&&_0x13814c[_0x3d499b(0x1d4)](_0x4c451a[_0x3d499b(0x16a)]);}}const _0x493897={..._0x18b1d0,'stepNames':_0x13814c},_0x3b7715=validateVersionStructure(_0xeab761,_0x493897);for(const _0x4c0015 of _0x3b7715){const _0x43ac05=_0x1f62d4?{..._0x4c0015,'path':''+_0x1f62d4+_0x4c0015['path']}:_0x4c0015;if(_0x43ac05[_0x3d499b(0x19b)]===_0x3d499b(0x1be))_0x3b99a5[_0x3d499b(0x17b)](_0x43ac05);else _0x442982[_0x3d499b(0x17b)](_0x43ac05);}for(let _0x58775c=0x0;_0x58775c<_0xeab761['length'];_0x58775c++){const _0x215f3e=validateStage(_0xeab761[_0x58775c],_0x58775c,_0xeab761['length'],_0x493897);for(const _0x2ba7f3 of _0x215f3e){const _0x28fba7=_0x1f62d4?{..._0x2ba7f3,'path':''+_0x1f62d4+_0x2ba7f3[_0x3d499b(0x1b7)]}:_0x2ba7f3;if(_0x28fba7[_0x3d499b(0x19b)]==='error')_0x3b99a5[_0x3d499b(0x17b)](_0x28fba7);else _0x442982[_0x3d499b(0x17b)](_0x28fba7);}}if(_0x1c4de2[_0x3d499b(0x190)]){const _0x2785c2=_0x252aec?.[_0x3d499b(0x139)]?_0x3d499b(0x190):_0x1f62d4+_0x3d499b(0x190),_0x3fd6b6=validateCriteria(_0x1c4de2[_0x3d499b(0x190)],_0x2785c2,_0x493897);for(const _0xe5028c of _0x3fd6b6){if(_0xe5028c[_0x3d499b(0x19b)]===_0x3d499b(0x1be))_0x3b99a5[_0x3d499b(0x17b)](_0xe5028c);else _0x442982[_0x3d499b(0x17b)](_0xe5028c);}}}function extractVersionIndex(_0x2a3c24){const _0x37f0a5=_0x2a3c24['match'](/^journeys\[(\d+)\]\./);return _0x37f0a5?_0x37f0a5[0x1]:undefined;}function deduplicateAcrossVersions(_0x42b21f){const _0x543207=a121_0x4b8b,_0x1bd915=new Map();for(let _0x4d740e=0x0;_0x4d740e<_0x42b21f['length'];_0x4d740e++){const _0x330a35=_0x42b21f[_0x4d740e][_0x543207(0x13e)]+':'+_0x42b21f[_0x4d740e][_0x543207(0x1c4)],_0x311d89=extractVersionIndex(_0x42b21f[_0x4d740e][_0x543207(0x1b7)]),_0x4e78f7=_0x1bd915['get'](_0x330a35);if(_0x4e78f7){_0x4e78f7[_0x543207(0x1db)]['push'](_0x4d740e);if(_0x311d89)_0x4e78f7[_0x543207(0x1ba)][_0x543207(0x1d4)](_0x311d89);}else _0x1bd915[_0x543207(0x1b3)](_0x330a35,{'indices':[_0x4d740e],'versions':new Set(_0x311d89?[_0x311d89]:[])});}const _0x4adf1c=new Set();for(const {indices:_0x339be7,versions:_0xc9f7fe}of _0x1bd915[_0x543207(0x156)]()){if(_0xc9f7fe['size']<=0x1)continue;const _0xa06a58=_0x42b21f[_0x339be7[0x0]];_0xa06a58[_0x543207(0x1b7)]=_0xa06a58[_0x543207(0x1b7)]['replace'](/^journeys\[\d+\]\./,''),_0xa06a58[_0x543207(0x1c4)]=_0xa06a58[_0x543207(0x1c4)]+'\x20(across\x20'+_0xc9f7fe[_0x543207(0x16c)]+_0x543207(0x164);for(let _0x5e128b=0x1;_0x5e128b<_0x339be7[_0x543207(0x14b)];_0x5e128b++){_0x4adf1c[_0x543207(0x1d4)](_0x339be7[_0x5e128b]);}}const _0x48b214=[..._0x4adf1c][_0x543207(0x17c)]((_0x49e5c6,_0x4c8511)=>_0x4c8511-_0x49e5c6);for(const _0x583136 of _0x48b214){_0x42b21f[_0x543207(0x1dc)](_0x583136,0x1);}}export function validateJourneyDef(_0x5490c9,_0xb5db0f={}){const _0x37fab3=a121_0x4b8b,_0x35906b=[],_0x136e34=[];(!_0x5490c9[_0x37fab3(0x16a)]||_0x5490c9['name'][_0x37fab3(0x1a1)]()==='')&&_0x35906b[_0x37fab3(0x17b)]({'level':_0x37fab3(0x1be),'path':'name','code':_0x37fab3(0x1df),'message':'Journey\x20name\x20is\x20required','location':getLocationFromPath(_0xb5db0f[_0x37fab3(0x182)],_0xb5db0f[_0x37fab3(0x16f)],[_0x37fab3(0x16a)])});const _0x382c16=new Set();if(_0x5490c9[_0x37fab3(0x1ad)])for(const _0x5d2833 of Object['keys'](_0x5490c9[_0x37fab3(0x1ad)])){_0x382c16[_0x37fab3(0x1d4)](_0x5d2833);}const _0x2e0808=new Set();if(_0x5490c9['activations'])for(const _0x29b57d of Object[_0x37fab3(0x1c7)](_0x5490c9[_0x37fab3(0x1ac)])){_0x2e0808[_0x37fab3(0x1d4)](_0x29b57d);}const _0x531bd1=new Set(),_0x4abb5d={..._0xb5db0f,'embeddedSegments':_0x382c16,'referencedSegments':_0x531bd1,'activationKeys':_0x2e0808[_0x37fab3(0x16c)]>0x0?_0x2e0808:undefined};if(_0x5490c9[_0x37fab3(0x1ad)])for(const [_0x9e98a1,_0x2edab7]of Object['entries'](_0x5490c9[_0x37fab3(0x1ad)])){const _0x36d032=validateEmbeddedSegment(_0x2edab7,_0x37fab3(0x150)+_0x9e98a1,_0x4abb5d);for(const _0x470bec of _0x36d032){if(_0x470bec[_0x37fab3(0x19b)]===_0x37fab3(0x1be))_0x35906b[_0x37fab3(0x17b)](_0x470bec);else _0x136e34[_0x37fab3(0x17b)](_0x470bec);}}const _0x35a8ec=!!_0x5490c9[_0x37fab3(0x190)],_0x2e7afa=_0x5490c9[_0x37fab3(0x172)]?.[_0x37fab3(0x15d)](_0x28d3ff=>!!_0x28d3ff[_0x37fab3(0x190)])??![];!_0x35a8ec&&!_0x2e7afa&&_0x136e34['push']({'level':'warning','path':'goal','code':_0x37fab3(0x1b5),'message':_0x37fab3(0x1a7),'location':getLocationFromPath(_0xb5db0f[_0x37fab3(0x182)],_0xb5db0f[_0x37fab3(0x16f)],['goal'])});if(_0x5490c9['journeys']&&_0x5490c9[_0x37fab3(0x172)][_0x37fab3(0x14b)]>0x0)for(let _0x49f8eb=0x0;_0x49f8eb<_0x5490c9[_0x37fab3(0x172)][_0x37fab3(0x14b)];_0x49f8eb++){const _0x35e0e1=_0x5490c9[_0x37fab3(0x172)][_0x49f8eb];if(_0x5490c9[_0x37fab3(0x172)][_0x37fab3(0x14b)]>0x1&&_0x35e0e1[_0x37fab3(0x1bf)]===_0x37fab3(0x154)&&!_0x35e0e1[_0x37fab3(0x1aa)])continue;const _0x24f302=_0x35e0e1['stages']||[],_0x5606df=_0x37fab3(0x195)+_0x49f8eb+'].',_0x39f8bf=!!_0x35e0e1['goal'],_0x346979=_0x39f8bf?{..._0x5490c9,'goal':_0x35e0e1['goal']}:_0x5490c9;validateStagesForVersion(_0x24f302,_0x346979,_0x4abb5d,_0x5606df,_0x35906b,_0x136e34,{'goalIsInherited':!_0x39f8bf});}else{if(_0x5490c9[_0x37fab3(0x1ba)]&&_0x5490c9[_0x37fab3(0x1ba)][_0x37fab3(0x14b)]>0x0)for(let _0xfd769d=0x0;_0xfd769d<_0x5490c9[_0x37fab3(0x1ba)][_0x37fab3(0x14b)];_0xfd769d++){const _0x43617b=_0x5490c9[_0x37fab3(0x1ba)][_0xfd769d];if(_0x5490c9[_0x37fab3(0x1ba)][_0x37fab3(0x14b)]>0x1&&_0x43617b[_0x37fab3(0x1bf)]===_0x37fab3(0x154)&&!_0x43617b['latest'])continue;const _0x13274d=_0x43617b[_0x37fab3(0x14d)]||[],_0x46a356=_0x37fab3(0x1ae)+_0xfd769d+'].';validateStagesForVersion(_0x13274d,_0x5490c9,_0x4abb5d,_0x46a356,_0x35906b,_0x136e34);}else{const _0x298c3a=_0x5490c9[_0x37fab3(0x14d)]||[];validateStagesForVersion(_0x298c3a,_0x5490c9,_0x4abb5d,'',_0x35906b,_0x136e34);}}_0x5490c9[_0x37fab3(0x172)]&&_0x5490c9[_0x37fab3(0x172)][_0x37fab3(0x14b)]>0x1&&(deduplicateAcrossVersions(_0x35906b),deduplicateAcrossVersions(_0x136e34));for(const _0x4eda87 of _0x382c16){!_0x531bd1[_0x37fab3(0x19f)](_0x4eda87)&&!_0x4eda87[_0x37fab3(0x16d)](_0x37fab3(0x173))&&_0x136e34[_0x37fab3(0x17b)]({'level':_0x37fab3(0x1d1),'path':'segments.'+_0x4eda87,'code':_0x37fab3(0x166),'message':_0x37fab3(0x16e)+_0x4eda87+_0x37fab3(0x143),'location':getLocationFromPath(_0xb5db0f[_0x37fab3(0x182)],_0xb5db0f[_0x37fab3(0x16f)],[_0x37fab3(0x1ad),_0x4eda87])});}return{'valid':_0x35906b[_0x37fab3(0x14b)]===0x0,'errors':_0x35906b,'warnings':_0x136e34};}
|