@treasuredata/tdx 0.26.1 → 0.26.2
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/describe.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/api.js +1 -1
- package/dist/sdk/client/cdp-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/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/port.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
|
-
const
|
|
1
|
+
const a170_0x423581=a170_0xc545;(function(_0x7c70bd,_0x3b22cf){const _0x3d31ff=a170_0xc545,_0x5d8c8f=_0x7c70bd();while(!![]){try{const _0xf5b137=parseInt(_0x3d31ff(0x13c))/0x1*(parseInt(_0x3d31ff(0x13f))/0x2)+-parseInt(_0x3d31ff(0x125))/0x3*(parseInt(_0x3d31ff(0x13a))/0x4)+-parseInt(_0x3d31ff(0x124))/0x5+-parseInt(_0x3d31ff(0x136))/0x6*(parseInt(_0x3d31ff(0x149))/0x7)+-parseInt(_0x3d31ff(0x141))/0x8*(parseInt(_0x3d31ff(0x13d))/0x9)+-parseInt(_0x3d31ff(0x156))/0xa*(-parseInt(_0x3d31ff(0x132))/0xb)+parseInt(_0x3d31ff(0x14b))/0xc*(parseInt(_0x3d31ff(0x159))/0xd);if(_0xf5b137===_0x3b22cf)break;else _0x5d8c8f['push'](_0x5d8c8f['shift']());}catch(_0x153cb7){_0x5d8c8f['push'](_0x5d8c8f['shift']());}}}(a170_0x621b,0x1d478));import{LogLevel as a170_0x58a420,logLevelToString}from'./types.js';const MAX_PENDING_RECORDS=0x3e8,state={'initialized':![],'defaultLevel':a170_0x58a420[a170_0x423581(0x130)],'levelOverrides':new Map(),'handlers':[],'formatter':null,'loggers':new Map(),'pendingRecords':[]};function a170_0x621b(){const _0x1342df=['name','WARN','handlers','initialized','trace','close','map','isInitialized','shouldLog','INFO','push','22308VtfyLW','stack','loggers','init','18yJQdfu','split','set','addHandler','371384NrBaRf','handle','25NNBwbo','1254843PRlYcz','debug','11410XDUaVJ','formatter','8wMZXQc','dispatch','entries','clearHandlers','timestamp','levelOverrides','slice','clear','268996SLNOgK','stringify','10908yjoUXh','message','getFormatter','pendingRecords','join','DEBUG','log','format','ERROR','shutdown','info','340OjfHzV','TRACE','component','7033hOXEml','setLogLevel','get','defaultLevel','warn','level','has','1179305ivoQFm','3kDcQuX','length'];a170_0x621b=function(){return _0x1342df;};return a170_0x621b();}function safeStringify(_0x451545){const _0x52da12=a170_0x423581;if(typeof _0x451545==='string')return _0x451545;if(_0x451545 instanceof Error)return _0x451545[_0x52da12(0x133)]||_0x451545[_0x52da12(0x127)]+':\x20'+_0x451545[_0x52da12(0x14c)];try{return JSON[_0x52da12(0x14a)](_0x451545,(_0x4f5a23,_0x5c3757)=>{const _0x150a91=_0x52da12;if(_0x5c3757 instanceof Error)return{'name':_0x5c3757[_0x150a91(0x127)],'message':_0x5c3757[_0x150a91(0x14c)],'stack':_0x5c3757[_0x150a91(0x133)],'cause':_0x5c3757['cause']};return _0x5c3757;});}catch{return String(_0x451545);}}function a170_0xc545(_0x32f714,_0x22d1ae){_0x32f714=_0x32f714-0x11e;const _0x621ba7=a170_0x621b();let _0xc54529=_0x621ba7[_0x32f714];return _0xc54529;}export class Logger{[a170_0x423581(0x158)];constructor(_0x371793){const _0x595458=a170_0x423581;this[_0x595458(0x158)]=_0x371793;}static['of'](_0x34c4a8){const _0x49b1b4=a170_0x423581,_0xe50675=typeof _0x34c4a8==='string'?_0x34c4a8:_0x34c4a8[_0x49b1b4(0x127)];let _0x411ad4=state[_0x49b1b4(0x134)][_0x49b1b4(0x11f)](_0xe50675);return!_0x411ad4&&(_0x411ad4=new Logger(_0xe50675),state['loggers']['set'](_0xe50675,_0x411ad4)),_0x411ad4;}static async[a170_0x423581(0x135)](_0x1c9a26={}){const _0x1b048c=a170_0x423581;state[_0x1b048c(0x120)]=_0x1c9a26[_0x1b048c(0x120)]??a170_0x58a420[_0x1b048c(0x130)],state[_0x1b048c(0x129)]=_0x1c9a26[_0x1b048c(0x129)]??[],state[_0x1b048c(0x140)]=_0x1c9a26[_0x1b048c(0x140)]??null,state['levelOverrides']['clear']();if(_0x1c9a26[_0x1b048c(0x146)])for(const [_0x1fa7a7,_0x22402f]of Object[_0x1b048c(0x143)](_0x1c9a26[_0x1b048c(0x146)])){state[_0x1b048c(0x146)][_0x1b048c(0x138)](_0x1fa7a7,_0x22402f);}for(const _0x472387 of state[_0x1b048c(0x129)]){_0x472387[_0x1b048c(0x135)]&&await _0x472387['init']();}state['initialized']=!![];for(const _0x426a1b of state[_0x1b048c(0x14e)]){Logger[_0x1b048c(0x142)](_0x426a1b);}state[_0x1b048c(0x14e)]=[];}static[a170_0x423581(0x11e)](_0x98e65c,_0x233ec5){const _0x4ada8d=a170_0x423581;state[_0x4ada8d(0x146)]['set'](_0x98e65c,_0x233ec5);}static['setDefaultLevel'](_0x5077ec){state['defaultLevel']=_0x5077ec;}static[a170_0x423581(0x139)](_0x16d5ff){const _0x59e98c=a170_0x423581;state[_0x59e98c(0x129)][_0x59e98c(0x131)](_0x16d5ff),state[_0x59e98c(0x12a)]&&_0x16d5ff[_0x59e98c(0x135)]&&_0x16d5ff[_0x59e98c(0x135)]();}static[a170_0x423581(0x144)](){const _0x35afcc=a170_0x423581;state[_0x35afcc(0x129)]=[];}static async[a170_0x423581(0x154)](){const _0x2c4c8a=a170_0x423581;for(const _0x2e2d64 of state[_0x2c4c8a(0x129)]){_0x2e2d64['close']&&await _0x2e2d64[_0x2c4c8a(0x12c)]();}state[_0x2c4c8a(0x129)]=[],state[_0x2c4c8a(0x12a)]=![],state[_0x2c4c8a(0x134)]['clear'](),state['pendingRecords']=[];}static['reset'](){const _0xf053f0=a170_0x423581;state[_0xf053f0(0x12a)]=![],state[_0xf053f0(0x120)]=a170_0x58a420[_0xf053f0(0x130)],state[_0xf053f0(0x146)]['clear'](),state[_0xf053f0(0x129)]=[],state[_0xf053f0(0x140)]=null,state[_0xf053f0(0x134)][_0xf053f0(0x148)](),state[_0xf053f0(0x14e)]=[];}static[a170_0x423581(0x12e)](){const _0x571e93=a170_0x423581;return state[_0x571e93(0x12a)];}static['getEffectiveLevel'](_0x56dbf2){const _0x46887f=a170_0x423581;if(state[_0x46887f(0x146)][_0x46887f(0x123)](_0x56dbf2))return state['levelOverrides']['get'](_0x56dbf2);const _0xa16dee=_0x56dbf2[_0x46887f(0x137)]('.');for(let _0x31707c=_0xa16dee[_0x46887f(0x126)]-0x1;_0x31707c>0x0;_0x31707c--){const _0x3f4a17=_0xa16dee[_0x46887f(0x147)](0x0,_0x31707c)[_0x46887f(0x14f)]('.');if(state[_0x46887f(0x146)][_0x46887f(0x123)](_0x3f4a17))return state[_0x46887f(0x146)][_0x46887f(0x11f)](_0x3f4a17);}return state[_0x46887f(0x120)];}[a170_0x423581(0x12f)](_0x57ac15){const _0x28755f=a170_0x423581,_0x279d9c=Logger['getEffectiveLevel'](this[_0x28755f(0x158)]);return _0x57ac15>=_0x279d9c;}static[a170_0x423581(0x142)](_0x237a1b){const _0x36d56e=a170_0x423581;for(const _0x102c4f of state[_0x36d56e(0x129)]){_0x102c4f[_0x36d56e(0x13b)](_0x237a1b);}}['log'](_0x2f0082,_0x3ff239){const _0x51818b=a170_0x423581;if(!this['shouldLog'](_0x2f0082))return;const _0x27f7b1=_0x3ff239[_0x51818b(0x12d)](_0x216def=>typeof _0x216def==='function'?_0x216def():_0x216def),_0x32b89d=_0x27f7b1[_0x51818b(0x12d)](safeStringify)[_0x51818b(0x14f)]('\x20'),_0x44257e={'timestamp':new Date(),'level':_0x2f0082,'component':this[_0x51818b(0x158)],'message':_0x32b89d};if(!state['initialized']){state[_0x51818b(0x14e)]['length']<MAX_PENDING_RECORDS&&state[_0x51818b(0x14e)][_0x51818b(0x131)](_0x44257e);return;}Logger[_0x51818b(0x142)](_0x44257e);}[a170_0x423581(0x12b)](..._0x9656df){const _0x5bd7d8=a170_0x423581;this['log'](a170_0x58a420[_0x5bd7d8(0x157)],_0x9656df);}[a170_0x423581(0x13e)](..._0x12583c){const _0x236169=a170_0x423581;this[_0x236169(0x151)](a170_0x58a420[_0x236169(0x150)],_0x12583c);}[a170_0x423581(0x155)](..._0x3db6b5){const _0x48107e=a170_0x423581;this[_0x48107e(0x151)](a170_0x58a420['INFO'],_0x3db6b5);}[a170_0x423581(0x121)](..._0x40c236){const _0x14e1f9=a170_0x423581;this[_0x14e1f9(0x151)](a170_0x58a420[_0x14e1f9(0x128)],_0x40c236);}['error'](..._0x21c9e1){const _0x1cb0af=a170_0x423581;this[_0x1cb0af(0x151)](a170_0x58a420[_0x1cb0af(0x153)],_0x21c9e1);}static[a170_0x423581(0x14d)](){const _0x1d6210=a170_0x423581;return state[_0x1d6210(0x140)];}static[a170_0x423581(0x152)](_0x106a6d){const _0x381280=a170_0x423581;if(state['formatter'])return state['formatter'][_0x381280(0x152)](_0x106a6d);return _0x106a6d[_0x381280(0x145)]['toISOString']()+'\x20['+logLevelToString(_0x106a6d[_0x381280(0x122)])+']\x20['+_0x106a6d['component']+']\x20'+_0x106a6d[_0x381280(0x14c)];}}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x124045,_0x299768){const _0x18c106=a171_0x1b3c,_0x2c3b20=_0x124045();while(!![]){try{const _0x20d0b7=-parseInt(_0x18c106(0xc1))/0x1*(parseInt(_0x18c106(0xc0))/0x2)+parseInt(_0x18c106(0xc8))/0x3*(parseInt(_0x18c106(0xc5))/0x4)+-parseInt(_0x18c106(0xd3))/0x5+parseInt(_0x18c106(0xcc))/0x6+parseInt(_0x18c106(0xda))/0x7*(-parseInt(_0x18c106(0xde))/0x8)+-parseInt(_0x18c106(0xcd))/0x9*(parseInt(_0x18c106(0xce))/0xa)+parseInt(_0x18c106(0xc4))/0xb*(parseInt(_0x18c106(0xd6))/0xc);if(_0x20d0b7===_0x299768)break;else _0x2c3b20['push'](_0x2c3b20['shift']());}catch(_0x4c41ea){_0x2c3b20['push'](_0x2c3b20['shift']());}}}(a171_0x4229,0x48bc7));export var LogLevel;(function(_0x54cb44){const _0x2df085=a171_0x1b3c;_0x54cb44[_0x54cb44[_0x2df085(0xc9)]=-0x2]=_0x2df085(0xc9),_0x54cb44[_0x54cb44['DEBUG']=-0x1]=_0x2df085(0xd8),_0x54cb44[_0x54cb44['INFO']=0x0]=_0x2df085(0xd4),_0x54cb44[_0x54cb44['WARN']=0x1]='WARN',_0x54cb44[_0x54cb44[_0x2df085(0xcf)]=0x2]=_0x2df085(0xcf);}(LogLevel||(LogLevel={})));export function parseLogLevel(_0x24aa5c){const _0x3229bd=a171_0x1b3c;switch(_0x24aa5c[_0x3229bd(0xdb)]()){case _0x3229bd(0xc9):return LogLevel[_0x3229bd(0xc9)];case'DEBUG':return LogLevel[_0x3229bd(0xd8)];case _0x3229bd(0xd4):return LogLevel[_0x3229bd(0xd4)];case _0x3229bd(0xbf):case _0x3229bd(0xca):return LogLevel[_0x3229bd(0xbf)];case'ERROR':return LogLevel[_0x3229bd(0xcf)];default:return LogLevel[_0x3229bd(0xd4)];}}function a171_0x1b3c(_0x1ce918,_0x2155fb){_0x1ce918=_0x1ce918-0xbf;const _0x422990=a171_0x4229();let _0x1b3c83=_0x422990[_0x1ce918];return _0x1b3c83;}export function logLevelToString(_0xa2ad80){const _0xbfae0e=a171_0x1b3c;switch(_0xa2ad80){case LogLevel[_0xbfae0e(0xc9)]:return _0xbfae0e(0xd0);case LogLevel['DEBUG']:return _0xbfae0e(0xd7);case LogLevel['INFO']:return _0xbfae0e(0xc3);case LogLevel[_0xbfae0e(0xbf)]:return _0xbfae0e(0xc7);case LogLevel[_0xbfae0e(0xcf)]:return _0xbfae0e(0xd5);default:return _0xbfae0e(0xc3);}}export function formatTimestamp(_0x1583c6){const _0x2bc8eb=a171_0x1b3c,_0x281a56=_0x1583c6[_0x2bc8eb(0xdc)](),_0x1a5bf1=(_0x1583c6[_0x2bc8eb(0xc2)]()+0x1)[_0x2bc8eb(0xc6)]()[_0x2bc8eb(0xcb)](0x2,'0'),_0x3239e8=_0x1583c6['getDate']()['toString']()[_0x2bc8eb(0xcb)](0x2,'0'),_0x499e83=_0x1583c6['getHours']()['toString']()[_0x2bc8eb(0xcb)](0x2,'0'),_0x5c141f=_0x1583c6[_0x2bc8eb(0xd9)]()[_0x2bc8eb(0xc6)]()[_0x2bc8eb(0xcb)](0x2,'0'),_0x5e0a17=_0x1583c6[_0x2bc8eb(0xdd)]()['toString']()[_0x2bc8eb(0xcb)](0x2,'0'),_0x278f08=_0x1583c6['getMilliseconds']()['toString']()[_0x2bc8eb(0xcb)](0x3,'0'),_0x38e7ad=-_0x1583c6['getTimezoneOffset'](),_0x2a0a2d=Math[_0x2bc8eb(0xd1)](Math[_0x2bc8eb(0xd2)](_0x38e7ad)/0x3c),_0x33a04c=Math[_0x2bc8eb(0xd2)](_0x38e7ad)%0x3c,_0x592bca=_0x38e7ad>=0x0?'+':'-',_0x4b853f=''+_0x592bca+_0x2a0a2d[_0x2bc8eb(0xc6)]()[_0x2bc8eb(0xcb)](0x2,'0')+_0x33a04c[_0x2bc8eb(0xc6)]()[_0x2bc8eb(0xcb)](0x2,'0');return _0x281a56+'-'+_0x1a5bf1+'-'+_0x3239e8+'\x20'+_0x499e83+':'+_0x5c141f+':'+_0x5e0a17+'.'+_0x278f08+_0x4b853f;}function a171_0x4229(){const _0x30d09e=['1048998GmXOgd','TRACE','WARNING','padStart','1661694zuaDPU','3150PenRET','13880yRpfOn','ERROR','trace','floor','abs','2085630bHcPsf','INFO','error','57072UXuRJo','debug','DEBUG','getMinutes','2006557OsAoNn','toUpperCase','getFullYear','getSeconds','16dBicdP','WARN','4qlnRjM','263286oYVcWU','getMonth','info','3872mGPxEQ','4hLNWQP','toString','warn'];a171_0x4229=function(){return _0x30d09e;};return a171_0x4229();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
function
|
|
1
|
+
function a172_0x45fa(){const _0x4d19a3=['10GXpXCE','68024052rFmCia','8128ikgOdV','Invalid\x20limit\x20value:\x20','.\x20Must\x20be\x20a\x20positive\x20number.','1992KCTimg','isInteger','79010HdpGGn','Invalid\x20timeout\x20value:\x20','642tsHmgU','15975146JXklpS','6153yNYxGE','.\x20Must\x20be\x20a\x20positive\x20integer.','7146lyEJIi','.\x20Must\x20be\x20a\x20number.','number','3497404PxKjyq','11860100khIZBu','1Jdmjjg'];a172_0x45fa=function(){return _0x4d19a3;};return a172_0x45fa();}function a172_0x524d(_0x50c697,_0x2cce9e){_0x50c697=_0x50c697-0x13d;const _0x45fabb=a172_0x45fa();let _0x524d47=_0x45fabb[_0x50c697];return _0x524d47;}(function(_0xa93383,_0x5bb0eb){const _0x3190d3=a172_0x524d,_0x54d112=_0xa93383();while(!![]){try{const _0x23c91c=-parseInt(_0x3190d3(0x14f))/0x1*(parseInt(_0x3190d3(0x14d))/0x2)+parseInt(_0x3190d3(0x148))/0x3*(parseInt(_0x3190d3(0x142))/0x4)+-parseInt(_0x3190d3(0x144))/0x5*(parseInt(_0x3190d3(0x146))/0x6)+-parseInt(_0x3190d3(0x14e))/0x7+parseInt(_0x3190d3(0x13f))/0x8*(parseInt(_0x3190d3(0x14a))/0x9)+-parseInt(_0x3190d3(0x13d))/0xa*(parseInt(_0x3190d3(0x147))/0xb)+parseInt(_0x3190d3(0x13e))/0xc;if(_0x23c91c===_0x5bb0eb)break;else _0x54d112['push'](_0x54d112['shift']());}catch(_0x35076c){_0x54d112['push'](_0x54d112['shift']());}}}(a172_0x45fa,0xde54f));export function validateLimitOption(_0x573ddd){const _0x506d8f=a172_0x524d;if(!Number[_0x506d8f(0x143)](_0x573ddd))return{'isValid':![],'error':_0x506d8f(0x140)+_0x573ddd+'.\x20Must\x20be\x20an\x20integer.'};if(_0x573ddd<=0x0)return{'isValid':![],'error':_0x506d8f(0x140)+_0x573ddd+_0x506d8f(0x149)};return{'isValid':!![],'value':_0x573ddd};}export function validateTimeoutOption(_0x928830,_0x30ab44=0x1e){const _0x52c75d=a172_0x524d;if(_0x928830===undefined)return{'isValid':!![],'value':_0x30ab44};const _0x5b04fb=typeof _0x928830===_0x52c75d(0x14c)?_0x928830:parseFloat(_0x928830);if(isNaN(_0x5b04fb))return{'isValid':![],'error':_0x52c75d(0x145)+_0x928830+_0x52c75d(0x14b)};if(_0x5b04fb<=0x0)return{'isValid':![],'error':_0x52c75d(0x145)+_0x5b04fb+_0x52c75d(0x141)};return{'isValid':!![],'value':_0x5b04fb};}
|
package/dist/utils/port.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x22aeaf,_0xb1ed79){const _0x49bbac=a173_0x21eb,_0x33e254=_0x22aeaf();while(!![]){try{const _0x3465d3=parseInt(_0x49bbac(0x9d))/0x1*(parseInt(_0x49bbac(0xa1))/0x2)+-parseInt(_0x49bbac(0xa0))/0x3+-parseInt(_0x49bbac(0x95))/0x4*(parseInt(_0x49bbac(0x99))/0x5)+-parseInt(_0x49bbac(0x97))/0x6*(-parseInt(_0x49bbac(0x9f))/0x7)+parseInt(_0x49bbac(0x8f))/0x8*(parseInt(_0x49bbac(0x8d))/0x9)+-parseInt(_0x49bbac(0x9a))/0xa+-parseInt(_0x49bbac(0x90))/0xb*(-parseInt(_0x49bbac(0x9c))/0xc);if(_0x3465d3===_0xb1ed79)break;else _0x33e254['push'](_0x33e254['shift']());}catch(_0x52cf0d){_0x33e254['push'](_0x33e254['shift']());}}}(a173_0x14bc,0x8594a));function a173_0x21eb(_0x38fba3,_0x2a015e){_0x38fba3=_0x38fba3-0x8d;const _0x14bc43=a173_0x14bc();let _0x21ebac=_0x14bc43[_0x38fba3];return _0x21ebac;}import{createServer}from'node:net';export async function isPortAvailable(_0x41f8ff){return new Promise(_0x1515e0=>{const _0x2adb0c=a173_0x21eb,_0x3bd663=createServer();_0x3bd663[_0x2adb0c(0x9b)](_0x2adb0c(0x9e),_0x3b47ab=>{const _0x7d243=_0x2adb0c;_0x3b47ab[_0x7d243(0x8e)]===_0x7d243(0x98)?_0x1515e0(![]):_0x1515e0(![]);}),_0x3bd663[_0x2adb0c(0x9b)](_0x2adb0c(0x96),()=>{const _0x11e145=_0x2adb0c;_0x3bd663[_0x11e145(0x93)](),_0x1515e0(!![]);}),_0x3bd663[_0x2adb0c(0x94)](_0x41f8ff,'0.0.0.0');});}function a173_0x14bc(){const _0xfa769e=['code','99184IpNGOU','869nSdZPb','No\x20available\x20port\x20found\x20between\x20','\x20and\x20','close','listen','7988ruLAFA','listening','9774wodgZB','EADDRINUSE','1435KazmqX','7678080FXCGua','once','155112JKalxB','1fBEbup','error','2310swNLzY','2993325cCmQxL','844180lcCvCu','657JltluF'];a173_0x14bc=function(){return _0xfa769e;};return a173_0x14bc();}export async function findAvailablePort(_0x6b7236=0xfa0,_0xced5d9=0x64){const _0x165bad=a173_0x21eb;for(let _0x6897cf=0x0;_0x6897cf<_0xced5d9;_0x6897cf++){const _0x1dde1e=_0x6b7236+_0x6897cf;if(await isPortAvailable(_0x1dde1e))return _0x1dde1e;}throw new Error(_0x165bad(0x91)+_0x6b7236+_0x165bad(0x92)+(_0x6b7236+_0xced5d9-0x1));}
|
package/dist/utils/process.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a174_0x4c2b76=a174_0x2bc6;(function(_0x491372,_0x3b507e){const _0x556f21=a174_0x2bc6,_0x266117=_0x491372();while(!![]){try{const _0x33272d=parseInt(_0x556f21(0x13b))/0x1*(-parseInt(_0x556f21(0x165))/0x2)+parseInt(_0x556f21(0x13f))/0x3*(-parseInt(_0x556f21(0x14f))/0x4)+-parseInt(_0x556f21(0x146))/0x5*(parseInt(_0x556f21(0x14c))/0x6)+-parseInt(_0x556f21(0x171))/0x7*(-parseInt(_0x556f21(0x161))/0x8)+parseInt(_0x556f21(0x152))/0x9+-parseInt(_0x556f21(0x13c))/0xa*(parseInt(_0x556f21(0x14a))/0xb)+-parseInt(_0x556f21(0x16b))/0xc*(-parseInt(_0x556f21(0x149))/0xd);if(_0x33272d===_0x3b507e)break;else _0x266117['push'](_0x266117['shift']());}catch(_0x3519b6){_0x266117['push'](_0x266117['shift']());}}}(a174_0x1325,0x62603));function a174_0x2bc6(_0x272354,_0x473b52){_0x272354=_0x272354-0x13a;const _0x132521=a174_0x1325();let _0x2bc6c6=_0x132521[_0x272354];return _0x2bc6c6;}import{execSync,spawn}from'node:child_process';const SHELL_NAMES=new Set([a174_0x4c2b76(0x145),'zsh','sh',a174_0x4c2b76(0x140),a174_0x4c2b76(0x175),'tcsh',a174_0x4c2b76(0x14d),a174_0x4c2b76(0x174),a174_0x4c2b76(0x150),'powershell','nu',a174_0x4c2b76(0x15c),'elvish',a174_0x4c2b76(0x173)]),EPHEMERAL_SHELL_SPAWNERS=new Set([a174_0x4c2b76(0x154),a174_0x4c2b76(0x156),a174_0x4c2b76(0x166),a174_0x4c2b76(0x155),a174_0x4c2b76(0x169)]);function getProcessInfoWindows(_0x59015e){const _0x22b739=a174_0x4c2b76;try{if(!Number[_0x22b739(0x157)](_0x59015e)||_0x59015e<=0x0)return null;const _0x116357=_0x22b739(0x172)+_0x59015e+'\x22\x20|\x20Select-Object\x20-Property\x20ParentProcessId,Name\x20|\x20ForEach-Object\x20{\x20\x22$($_.ParentProcessId),$($_.Name)\x22\x20}',_0x3f504a=execSync(_0x22b739(0x16a)+_0x116357+'\x22',{'encoding':_0x22b739(0x15d),'windowsHide':!![],'stdio':[_0x22b739(0x14b),_0x22b739(0x14b),_0x22b739(0x14b)]})[_0x22b739(0x148)]();if(!_0x3f504a)return null;const [_0x48891d,..._0x58e180]=_0x3f504a[_0x22b739(0x158)](','),_0x409ed5=parseInt(_0x48891d,0xa),_0x38175c=_0x58e180['join'](',')[_0x22b739(0x148)]();if(isNaN(_0x409ed5)||!_0x38175c)return null;return{'pid':_0x59015e,'ppid':_0x409ed5,'comm':_0x38175c[_0x22b739(0x14e)](/\.exe$/i,'')};}catch{return null;}}function getProcessInfoPosix(_0xcde972){const _0x1d6bda=a174_0x4c2b76;try{const _0x444086=0x400000;if(!Number[_0x1d6bda(0x157)](_0xcde972)||_0xcde972<=0x0||_0xcde972>_0x444086)return null;const _0x59a5e5=execSync(_0x1d6bda(0x151)+_0xcde972+_0x1d6bda(0x170),{'encoding':_0x1d6bda(0x15d),'stdio':_0x1d6bda(0x14b)})[_0x1d6bda(0x148)](),[_0x2bebfb,..._0x2b2218]=_0x59a5e5['split'](/\s+/),_0x55b9ba=parseInt(_0x2bebfb,0xa),_0x26972c=_0x2b2218['join']('\x20');if(isNaN(_0x55b9ba))return null;return{'pid':_0xcde972,'ppid':_0x55b9ba,'comm':_0x26972c};}catch{return null;}}function getProcessInfo(_0x536cbe){if(process['platform']==='win32')return getProcessInfoWindows(_0x536cbe);return getProcessInfoPosix(_0x536cbe);}function getBasename(_0x40796e){const _0x4ca762=a174_0x4c2b76;return _0x40796e[_0x4ca762(0x14e)](/^-/,'')['split']('/')['pop']()?.[_0x4ca762(0x163)]()||'';}function a174_0x1325(){const _0x3eb62d=['platform','toLowerCase','which','164hmvMUA','cursor','kill','pid','treasure\x20studio','powershell.exe\x20-NoProfile\x20-NonInteractive\x20-Command\x20\x22','24ATXyVZ','ignore','href','unref','data','\x20-o\x20ppid=,comm=','7LwlIdq','Get-CimInstance\x20Win32_Process\x20-Filter\x20\x22ProcessId=','xonsh','dash','ksh','where.exe','Unsupported\x20protocol:\x20','5883RjxGhB','4950ZTOqSt','xdg-open','toString','3KQSaGO','fish','error','http:','ppid','comm','bash','1355hAmcLW','map','trim','4313413acoqdD','7249wAsisu','pipe','1608WpDiLG','csh','replace','134644qNhhmH','pwsh','ps\x20-p\x20','2604663izrETh','darwin','claude','electron','code','isInteger','split','Invalid\x20URL:\x20','join','exit','ion','utf-8','protocol','has','win32','2918704ENhQVx'];a174_0x1325=function(){return _0x3eb62d;};return a174_0x1325();}function isShell(_0x5ca42d){const _0x2f0341=a174_0x4c2b76;return SHELL_NAMES[_0x2f0341(0x15f)](getBasename(_0x5ca42d));}function isEphemeralShellSpawner(_0x26838f){const _0x4db4e3=a174_0x4c2b76;return EPHEMERAL_SHELL_SPAWNERS[_0x4db4e3(0x15f)](getBasename(_0x26838f));}let cachedShellPID;function findShellPID(){const _0x2afe02=a174_0x4c2b76;if(process['ppid']===undefined)return process[_0x2afe02(0x168)];let _0x345664=process[_0x2afe02(0x143)];const _0x5bd8f0=0xa;let _0x2c6618=0x0;while(_0x2c6618<_0x5bd8f0){const _0x2e3c96=getProcessInfo(_0x345664);if(!_0x2e3c96)break;if(isShell(_0x2e3c96['comm'])){const _0xfe45f1=getProcessInfo(_0x2e3c96[_0x2afe02(0x143)]);if(_0xfe45f1&&isEphemeralShellSpawner(_0xfe45f1[_0x2afe02(0x144)])){_0x345664=_0x2e3c96['ppid'],_0x2c6618++;continue;}return _0x2e3c96[_0x2afe02(0x168)];}if(_0x2e3c96[_0x2afe02(0x143)]===0x0||_0x2e3c96[_0x2afe02(0x143)]===0x1){if(isShell(_0x2e3c96[_0x2afe02(0x144)]))return _0x2e3c96[_0x2afe02(0x168)];break;}_0x345664=_0x2e3c96[_0x2afe02(0x143)],_0x2c6618++;}return process[_0x2afe02(0x143)]!==undefined?process[_0x2afe02(0x143)]:process[_0x2afe02(0x168)];}export function getPPID(){return cachedShellPID===undefined&&(cachedShellPID=findShellPID()),cachedShellPID;}export function clearPPIDCache(){cachedShellPID=undefined;}export function isProcessRunning(_0x302e09){const _0x3457fd=a174_0x4c2b76;if(!Number[_0x3457fd(0x157)](_0x302e09)||_0x302e09<=0x0)return![];try{return process['kill'](_0x302e09,0x0),!![];}catch{return![];}}export function openBrowser(_0x306e55){const _0x37d9a3=a174_0x4c2b76;let _0x1f3102;try{_0x1f3102=new URL(_0x306e55);}catch{throw new Error(_0x37d9a3(0x159)+_0x306e55);}if(_0x1f3102[_0x37d9a3(0x15e)]!==_0x37d9a3(0x142)&&_0x1f3102[_0x37d9a3(0x15e)]!=='https:')throw new Error(_0x37d9a3(0x13a)+_0x1f3102[_0x37d9a3(0x15e)]);const _0x4174a2=_0x1f3102[_0x37d9a3(0x16d)],_0x51e610=process[_0x37d9a3(0x162)];if(_0x51e610===_0x37d9a3(0x160))spawn('cmd.exe',['/c','start','',_0x4174a2],{'detached':!![],'stdio':'ignore'})[_0x37d9a3(0x16e)]();else{const _0x2af3ad=_0x51e610===_0x37d9a3(0x153)?'open':_0x37d9a3(0x13d);spawn(_0x2af3ad,[_0x4174a2],{'detached':!![],'stdio':_0x37d9a3(0x16c)})['unref']();}}export function isWindows(){const _0x41e0f3=a174_0x4c2b76;return process['platform']===_0x41e0f3(0x160);}export function getCrossSpawnOptions(_0x2d194f){return{..._0x2d194f??{},'shell':isWindows()};}export function escapeWindowsArg(_0x56e534){const _0x142de8=a174_0x4c2b76;if(!/[ \t"&|<>^%!`\r\n]/['test'](_0x56e534))return _0x56e534;const _0x3cf66d=_0x56e534[_0x142de8(0x14e)](/"/g,'\x22\x22');return'\x22'+_0x3cf66d+'\x22';}export function crossSpawn(_0x44fd4f,_0x10b03e,_0x18e277){const _0xb44d0d=a174_0x4c2b76;if(isWindows()){const _0xb0ab6d=escapeWindowsArg(_0x44fd4f),_0x201bf3=_0x10b03e[_0xb44d0d(0x147)](escapeWindowsArg),_0x7c5d01=[_0xb0ab6d,..._0x201bf3][_0xb44d0d(0x15a)]('\x20');return spawn(_0x7c5d01,[],{..._0x18e277,'shell':!![]});}return spawn(_0x44fd4f,_0x10b03e,{..._0x18e277,'shell':![]});}export function gracefulExit(_0x2c9653=0x0){const _0x4ac643=a174_0x4c2b76;isWindows()?setImmediate(()=>process['exit'](_0x2c9653)):process[_0x4ac643(0x15b)](_0x2c9653);}export function findExecutable(_0x4fc347,_0x51c944=0x1388){return new Promise(_0x12593a=>{const _0x47a7c0=a174_0x2bc6,_0x545275=isWindows()?_0x47a7c0(0x176):_0x47a7c0(0x164);let _0x536f65=![];const _0x59b512=crossSpawn(_0x545275,[_0x4fc347],{'stdio':_0x47a7c0(0x14b),'shell':isWindows()}),_0x327f57=setTimeout(()=>{const _0x2e03b8=_0x47a7c0;!_0x536f65&&(_0x536f65=!![],_0x59b512[_0x2e03b8(0x167)](),_0x12593a(null));},_0x51c944);let _0x17d878='';_0x59b512['stdout']?.['on'](_0x47a7c0(0x16f),_0x51732b=>{const _0x3f8f08=_0x47a7c0;_0x17d878+=_0x51732b[_0x3f8f08(0x13e)]();}),_0x59b512['stderr']?.['on'](_0x47a7c0(0x16f),()=>{}),_0x59b512['on'](_0x47a7c0(0x15b),_0x430bab=>{const _0x94d187=_0x47a7c0;if(_0x536f65)return;_0x536f65=!![],clearTimeout(_0x327f57);if(_0x430bab===0x0&&_0x17d878['trim']()){const _0x20b61e=_0x17d878[_0x94d187(0x148)]()[_0x94d187(0x158)](/\r?\n/)[0x0];_0x12593a(_0x20b61e);}else _0x12593a(null);}),_0x59b512['on'](_0x47a7c0(0x141),()=>{if(_0x536f65)return;_0x536f65=!![],clearTimeout(_0x327f57),_0x12593a(null);});});}
|
package/dist/utils/prompt.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x4d1dae,_0x17b428){const _0x4a7256=a175_0x11ec,_0x4da774=_0x4d1dae();while(!![]){try{const _0x135e39=parseInt(_0x4a7256(0x1cc))/0x1+parseInt(_0x4a7256(0x1c7))/0x2+parseInt(_0x4a7256(0x1c3))/0x3+parseInt(_0x4a7256(0x1c9))/0x4+parseInt(_0x4a7256(0x1cd))/0x5+parseInt(_0x4a7256(0x1ca))/0x6*(parseInt(_0x4a7256(0x1b9))/0x7)+parseInt(_0x4a7256(0x1c5))/0x8*(-parseInt(_0x4a7256(0x1ba))/0x9);if(_0x135e39===_0x17b428)break;else _0x4da774['push'](_0x4da774['shift']());}catch(_0x49ae85){_0x4da774['push'](_0x4da774['shift']());}}}(a175_0xa1dd,0x9a6ce));function a175_0x11ec(_0x243f8d,_0x3020c7){_0x243f8d=_0x243f8d-0x1b7;const _0xa1dd74=a175_0xa1dd();let _0x11ec67=_0xa1dd74[_0x243f8d];return _0x11ec67;}import*as a175_0x2094af from'readline';function a175_0xa1dd(){const _0xa34540=['yes','isTTY','exit','stdout','close','\x20(y/N):\x20','createInterface','utf8','2611437LTECln','question','469504dhUOtF','stdin','1182948WyajiQ','resume','4789152mChMGq','18GDDCQC','data','431735JHtgWd','4931340ShpEpl','pause','stderr','toLowerCase','write','2095786cqfjAI','666qtNBJP'];a175_0xa1dd=function(){return _0xa34540;};return a175_0xa1dd();}export function isInteractive(){const _0x5576a5=a175_0x11ec;return process[_0x5576a5(0x1c6)][_0x5576a5(0x1bc)]===!![];}export async function confirm(_0x515e52){const _0x2660f7=a175_0x11ec,_0x17f021=a175_0x2094af[_0x2660f7(0x1c1)]({'input':process['stdin'],'output':process[_0x2660f7(0x1be)]});return new Promise(_0x20179d=>{const _0x88fefc=_0x2660f7;_0x17f021[_0x88fefc(0x1c4)](_0x515e52+_0x88fefc(0x1c0),_0x1f45a2=>{const _0x2df9e3=_0x88fefc;_0x17f021[_0x2df9e3(0x1bf)](),_0x20179d(_0x1f45a2[_0x2df9e3(0x1b7)]()==='y'||_0x1f45a2['toLowerCase']()===_0x2df9e3(0x1bb));});});}export async function confirmKey(_0x231eda){const _0x486bb7=a175_0x11ec;if(!process[_0x486bb7(0x1c6)]['isTTY'])return![];return process['stderr'][_0x486bb7(0x1b8)](_0x231eda+'\x20[y/N]\x20'),new Promise(_0xe04fec=>{const _0x10a98f=_0x486bb7,_0x214d65=process[_0x10a98f(0x1c6)];_0x214d65['setRawMode'](!![]),_0x214d65[_0x10a98f(0x1c8)](),_0x214d65['setEncoding'](_0x10a98f(0x1c2));const _0x5b1b50=_0x267e4b=>{const _0x17241d=_0x10a98f;_0x214d65['setRawMode'](![]),_0x214d65[_0x17241d(0x1ce)](),_0x214d65['removeListener'](_0x17241d(0x1cb),_0x5b1b50);if(_0x267e4b==='\x1b'){process['stderr']['write']('\x0a'),_0xe04fec(![]);return;}_0x267e4b==='\x03'&&(process[_0x17241d(0x1cf)][_0x17241d(0x1b8)]('\x0a'),process[_0x17241d(0x1bd)](0x82));if(_0x267e4b[_0x17241d(0x1b7)]()==='y'){process[_0x17241d(0x1cf)][_0x17241d(0x1b8)]('y\x0a'),_0xe04fec(!![]);return;}process[_0x17241d(0x1cf)][_0x17241d(0x1b8)]('\x0a'),_0xe04fec(![]);};_0x214d65['on'](_0x10a98f(0x1cb),_0x5b1b50);});}
|
package/dist/utils/spinner.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x10244d,_0x2a9dea){const _0x12f9ff=a176_0x44b3,_0x2a3b49=_0x10244d();while(!![]){try{const _0x36ed3b=-parseInt(_0x12f9ff(0xae))/0x1+-parseInt(_0x12f9ff(0xb1))/0x2*(-parseInt(_0x12f9ff(0x9f))/0x3)+-parseInt(_0x12f9ff(0x98))/0x4+-parseInt(_0x12f9ff(0xb3))/0x5+parseInt(_0x12f9ff(0xab))/0x6+-parseInt(_0x12f9ff(0xac))/0x7*(parseInt(_0x12f9ff(0xa4))/0x8)+parseInt(_0x12f9ff(0xa7))/0x9*(parseInt(_0x12f9ff(0xad))/0xa);if(_0x36ed3b===_0x2a9dea)break;else _0x2a3b49['push'](_0x2a3b49['shift']());}catch(_0x5a2586){_0x2a3b49['push'](_0x2a3b49['shift']());}}}(a176_0x332b,0xe864e));import a176_0xb37189 from'ora';import{isWindows}from'./process.js';const windowsSpinner={'interval':0x3e8,'frames':['•']};export function createCommandSpinner(_0x1e0c18,_0x401b45={}){const _0x4bd572=a176_0x44b3,{verbose:verbose=![],forceEnabled:forceEnabled=![]}=_0x401b45;return a176_0xb37189({'text':_0x1e0c18,'color':_0x4bd572(0xaa),'stream':process[_0x4bd572(0xaf)],'isEnabled':forceEnabled||process['stderr']['isTTY']&&!verbose,...isWindows()&&{'spinner':windowsSpinner}});}function a176_0x44b3(_0x5ec63f,_0x5c8bfc){_0x5ec63f=_0x5ec63f-0x98;const _0x332b46=a176_0x332b();let _0x44b359=_0x332b46[_0x5ec63f];return _0x44b359;}export async function withSpinner(_0x452981,_0x23ef8b,_0xdbaf46={}){const _0x56284d=a176_0x44b3,_0x4f1358=_0xdbaf46[_0x56284d(0xa2)]??(()=>Date[_0x56284d(0xa3)]()),_0x409b69=createCommandSpinner(_0x452981,_0xdbaf46);_0x409b69[_0x56284d(0xa8)]();const _0x5669c8=_0x4f1358();try{const _0x454687=await _0x23ef8b(),_0x143128=_0x4f1358()-_0x5669c8;return _0x409b69[_0x56284d(0x99)](),{'data':_0x454687,'elapsedMs':_0x143128};}catch(_0x159f99){_0x409b69[_0x56284d(0x99)]();throw _0x159f99;}}export async function withProgressSpinner(_0x3e09fd,_0x15e357,_0x13a74e={}){const _0x5110df=a176_0x44b3,_0x3a4357=_0x13a74e[_0x5110df(0xa2)]??(()=>Date[_0x5110df(0xa3)]()),_0x43ac8c=_0x13a74e['intervalFactory']??setInterval,_0xc600b8=createCommandSpinner(_0x3e09fd,_0x13a74e);_0xc600b8[_0x5110df(0xa8)]();const _0x41b100=_0x3a4357(),_0x3cd54a=_0x3e09fd[_0x5110df(0xa5)](_0x5110df(0xa0),'')[_0x5110df(0x9c)]()||_0x5110df(0x9b),_0xdb7153={};let _0x325fab=_0x3e09fd;const _0x28a946=()=>{const _0x48dccd=_0x5110df;if(!_0xc600b8[_0x48dccd(0xa9)])return;const _0x5b0be0=_0x3a4357()-_0x41b100,_0x5aba0f=formatElapsed(_0x5b0be0),_0x121c99=_0xdb7153[_0x48dccd(0xb0)]?.[_0x48dccd(0x9c)]()||_0x3cd54a,_0x360d5f=_0xdb7153[_0x48dccd(0xa6)]?_0x48dccd(0xa1)+_0xdb7153[_0x48dccd(0xa6)]+']':'',_0x34ef80=_0xdb7153['extra']?'\x20'+_0xdb7153[_0x48dccd(0x9a)]:'',_0x321858=_0x121c99+'\x20'+_0x5aba0f+_0x34ef80+_0x360d5f;_0x321858!==_0x325fab&&_0x321858[_0x48dccd(0x9c)]()&&(_0xc600b8['text']=_0x321858,_0x325fab=_0x321858);},_0x1a25bc=_0x43ac8c(()=>{_0x28a946();},0x3e8),_0x6b69fd={'setPhase':_0x380c27=>{const _0x5b21fd=_0x5110df;_0xdb7153[_0x5b21fd(0xb0)]=_0x380c27;const _0xb42ae4=_0x380c27?.[_0x5b21fd(0x9c)]()||_0x3cd54a,_0x5d0fa9=_0x3a4357()-_0x41b100,_0x4c4616=formatElapsed(_0x5d0fa9),_0xf19401=_0xdb7153[_0x5b21fd(0xa6)]?'\x20[Job\x20ID:\x20'+_0xdb7153[_0x5b21fd(0xa6)]+']':'',_0x1b24fb=_0xdb7153[_0x5b21fd(0x9a)]?'\x20'+_0xdb7153[_0x5b21fd(0x9a)]:'',_0x511cd2=_0xb42ae4+'\x20'+_0x4c4616+_0x1b24fb+_0xf19401;_0xc600b8[_0x5b21fd(0xa9)]&&_0x511cd2[_0x5b21fd(0x9c)]()&&(_0xc600b8[_0x5b21fd(0x9d)]=_0x511cd2,_0x325fab=_0x511cd2);},'setJobId':_0x259f1e=>{const _0x284e7d=_0x5110df;_0xdb7153[_0x284e7d(0xa6)]=_0x259f1e,_0x28a946();},'setExtra':_0x1da022=>{const _0x390731=_0x5110df;_0xdb7153[_0x390731(0x9a)]=_0x1da022,_0x28a946();}};_0x28a946();try{const _0x1cb1e5=await _0x15e357(_0x6b69fd),_0x5d92ac=_0x3a4357()-_0x41b100;return{'data':_0x1cb1e5,'elapsedMs':_0x5d92ac};}finally{clearInterval(_0x1a25bc),_0xc600b8['stop']();}}export function formatElapsed(_0x35bb00){const _0x6b78ba=a176_0x44b3,_0x55340a=Math[_0x6b78ba(0xb2)](_0x35bb00/0x3e8);if(_0x55340a<0x3c)return(_0x35bb00/0x3e8)[_0x6b78ba(0x9e)](0x1)+'s';const _0x589bda=Math[_0x6b78ba(0xb2)](_0x55340a/0x3c),_0x5d9427=_0x55340a%0x3c;if(_0x589bda<0x3c)return _0x589bda+'m\x20'+_0x5d9427+'s';const _0x8ed926=Math[_0x6b78ba(0xb2)](_0x589bda/0x3c),_0x540c54=_0x589bda%0x3c;return _0x8ed926+'h\x20'+_0x540c54+'m';}function a176_0x332b(){const _0x4613ab=['4903704LQVagz','7ZoNXVE','631710ECqwSd','846930UPZFcR','stderr','phase','173858gavrai','floor','720445xZPxZZ','1449708dzIzPA','stop','extra','Processing','trim','text','toFixed','3ANeNQJ','...','\x20[Job\x20ID:\x20','clock','now','2435984BePAOt','replace','jobId','243iaTdlg','start','isSpinning','cyan'];a176_0x332b=function(){return _0x4613ab;};return a176_0x332b();}
|
package/dist/utils/sse-parser.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x148898,_0x2e101d){const _0x4cc316=a177_0x5d1d,_0x4b4b9e=_0x148898();while(!![]){try{const _0x23c8bf=parseInt(_0x4cc316(0x69))/0x1+parseInt(_0x4cc316(0x7b))/0x2*(-parseInt(_0x4cc316(0x6f))/0x3)+parseInt(_0x4cc316(0x6e))/0x4+-parseInt(_0x4cc316(0x6a))/0x5*(-parseInt(_0x4cc316(0x72))/0x6)+-parseInt(_0x4cc316(0x7c))/0x7*(-parseInt(_0x4cc316(0x74))/0x8)+parseInt(_0x4cc316(0x6c))/0x9+parseInt(_0x4cc316(0x68))/0xa*(-parseInt(_0x4cc316(0x73))/0xb);if(_0x23c8bf===_0x2e101d)break;else _0x4b4b9e['push'](_0x4b4b9e['shift']());}catch(_0x4f5ea){_0x4b4b9e['push'](_0x4b4b9e['shift']());}}}(a177_0x453c,0x1aed4));function a177_0x5d1d(_0x239adc,_0x48ed3f){_0x239adc=_0x239adc-0x68;const _0x453c34=a177_0x453c();let _0x5d1d11=_0x453c34[_0x239adc];return _0x5d1d11;}export async function*parseSSEStream(_0x37cf50,_0x27d20e){const _0x576e1d=a177_0x5d1d;if(!_0x37cf50[_0x576e1d(0x7d)])throw new Error(_0x576e1d(0x80));const _0x322c87=_0x37cf50[_0x576e1d(0x7d)][_0x576e1d(0x6b)](),_0x546033=new TextDecoder();let _0x3f8c98='',_0x20a1bd={};try{while(!![]){const {done:_0x457f08,value:_0x20bd5d}=await _0x322c87[_0x576e1d(0x77)]();if(_0x457f08){if(_0x20a1bd[_0x576e1d(0x7f)]){_0x27d20e?.['debug'](_0x576e1d(0x7e)+_0x20a1bd[_0x576e1d(0x7f)]);const _0x2837d9=parseSSEData(_0x20a1bd[_0x576e1d(0x7f)]);yield _0x2837d9;}break;}_0x3f8c98+=_0x546033[_0x576e1d(0x75)](_0x20bd5d,{'stream':!![]});const _0x2e73b9=_0x3f8c98['split']('\x0a');_0x3f8c98=_0x2e73b9['pop']()||'';for(const _0x33bf9f of _0x2e73b9){if(_0x33bf9f['trim']()===''){if(_0x20a1bd[_0x576e1d(0x7f)]){_0x27d20e?.[_0x576e1d(0x7a)](_0x576e1d(0x7e)+_0x20a1bd[_0x576e1d(0x7f)]);const _0x48b4d4=parseSSEData(_0x20a1bd[_0x576e1d(0x7f)]);yield _0x48b4d4,_0x20a1bd={};}continue;}if(_0x33bf9f[_0x576e1d(0x71)](':'))continue;const _0x53742c=_0x33bf9f['indexOf'](':');if(_0x53742c===-0x1)continue;const _0x3f734f=_0x33bf9f[_0x576e1d(0x70)](0x0,_0x53742c);let _0x39b5db=_0x33bf9f[_0x576e1d(0x70)](_0x53742c+0x1);_0x39b5db[_0x576e1d(0x71)]('\x20')&&(_0x39b5db=_0x39b5db['slice'](0x1));switch(_0x3f734f){case'event':_0x20a1bd[_0x576e1d(0x78)]=_0x39b5db;break;case'data':_0x20a1bd[_0x576e1d(0x7f)]=_0x20a1bd['data']?_0x20a1bd['data']+'\x0a'+_0x39b5db:_0x39b5db;break;case'id':_0x20a1bd['id']=_0x39b5db;break;}}}}finally{_0x322c87[_0x576e1d(0x76)]();}}function a177_0x453c(){const _0x1b71f9=['6149JgfScD','1456808skZtqX','decode','releaseLock','read','event','Failed\x20to\x20parse\x20SSE\x20data\x20as\x20JSON:\x20','debug','71546rVnxvm','7BRjaZO','body','[LLM\x20API\x20SSE]\x20','data','Response\x20body\x20is\x20null','7850fEzWsV','33472ZsgjRU','5eSTqEr','getReader','1577889aehLYB','parse','662556RQLhSI','15pVDVeW','slice','startsWith','1028634xmBmiC'];a177_0x453c=function(){return _0x1b71f9;};return a177_0x453c();}function parseSSEData(_0x2692af){const _0x5435b5=a177_0x5d1d;try{return JSON[_0x5435b5(0x6d)](_0x2692af);}catch(_0x227c0e){throw new Error(_0x5435b5(0x79)+_0x2692af,{'cause':_0x227c0e});}}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x33060c,_0x3c17ba){const _0x4d3b0e=a178_0x4f03,_0x9c7b4e=_0x33060c();while(!![]){try{const _0x4c7a49=-parseInt(_0x4d3b0e(0x1ca))/0x1+-parseInt(_0x4d3b0e(0x1b6))/0x2+-parseInt(_0x4d3b0e(0x1c3))/0x3+-parseInt(_0x4d3b0e(0x1c4))/0x4*(parseInt(_0x4d3b0e(0x1c7))/0x5)+parseInt(_0x4d3b0e(0x1bb))/0x6*(-parseInt(_0x4d3b0e(0x1bf))/0x7)+-parseInt(_0x4d3b0e(0x1c5))/0x8*(-parseInt(_0x4d3b0e(0x1c8))/0x9)+parseInt(_0x4d3b0e(0x1bd))/0xa;if(_0x4c7a49===_0x3c17ba)break;else _0x9c7b4e['push'](_0x9c7b4e['shift']());}catch(_0x1989bd){_0x9c7b4e['push'](_0x9c7b4e['shift']());}}}(a178_0x2e8a,0x28c7b));import a178_0x400168 from'string-width';export function stringWidth(_0x2fc8e8){return a178_0x400168(_0x2fc8e8);}function a178_0x2e8a(){const _0x5a2386=['trim','test','Cannot\x20build\x20LIKE\x20pattern\x20from\x20empty\x20string','length','350904fflhka','padStart','8360810zCDoSH','substring','35lPDQbt','toString','floor','slice','327417GYtqZI','1340WPDRha','1563232AxDJPF','random','485XXfFsq','9lRbacZ','toLowerCase','296114oFLhnC','repeat','replace','unknown','\x5c$&','268564hEFXEQ'];a178_0x2e8a=function(){return _0x5a2386;};return a178_0x2e8a();}export function padEnd(_0x1b8da2,_0x3c54c3){const _0x3d9599=a178_0x4f03,_0x1dcaa6=stringWidth(_0x1b8da2);if(_0x1dcaa6>=_0x3c54c3)return _0x1b8da2;return _0x1b8da2+'\x20'[_0x3d9599(0x1cb)](_0x3c54c3-_0x1dcaa6);}export function padStart(_0x19130c,_0x2a6110){const _0x133ec1=stringWidth(_0x19130c);if(_0x133ec1>=_0x2a6110)return _0x19130c;return'\x20'['repeat'](_0x2a6110-_0x133ec1)+_0x19130c;}export function centerAlign(_0x31ee37,_0x272adf){const _0x12f145=a178_0x4f03,_0x4e8045=stringWidth(_0x31ee37);if(_0x4e8045>_0x272adf){if(_0x272adf<=0x1)return'…'[_0x12f145(0x1be)](0x0,_0x272adf);let _0xb9c027=_0x31ee37;while(stringWidth(_0xb9c027+'…')>_0x272adf){_0xb9c027=_0xb9c027[_0x12f145(0x1c2)](0x0,-0x1);}return _0xb9c027+'…';}if(_0x4e8045===_0x272adf)return _0x31ee37;const _0x24984a=_0x272adf-_0x4e8045,_0x3e362f=Math[_0x12f145(0x1c1)](_0x24984a/0x2),_0x50bf76=_0x24984a-_0x3e362f;return'\x20'[_0x12f145(0x1cb)](_0x3e362f)+_0x31ee37+'\x20'[_0x12f145(0x1cb)](_0x50bf76);}export function escapeStringLiteral(_0x34e061){const _0x3c1b5d=a178_0x4f03;if(!_0x34e061||_0x34e061[_0x3c1b5d(0x1b7)]()[_0x3c1b5d(0x1ba)]===0x0)throw new Error('Cannot\x20escape\x20empty\x20string\x20literal');const _0xe3a02b=_0x34e061['replace'](/'/g,'\x27\x27');return'\x27'+_0xe3a02b+'\x27';}export function globToLike(_0x180450){const _0x3e6e56=a178_0x4f03;let _0xc4dacf=_0x180450['replace'](/\\/g,'\x5c\x5c')[_0x3e6e56(0x1cc)](/%/g,'\x5c%')[_0x3e6e56(0x1cc)](/_/g,'\x5c_');return _0xc4dacf=_0xc4dacf[_0x3e6e56(0x1cc)](/\*/g,'%')['replace'](/\?/g,'_'),_0xc4dacf;}export function buildLikePattern(_0x399bf2){const _0x1165b1=a178_0x4f03;if(!_0x399bf2||_0x399bf2[_0x1165b1(0x1b7)]()[_0x1165b1(0x1ba)]===0x0)throw new Error(_0x1165b1(0x1b9));const _0x325fe4=globToLike(_0x399bf2),_0x32bc03=_0x325fe4[_0x1165b1(0x1cc)](/'/g,'\x27\x27');return'\x27'+_0x32bc03+'\x27';}export function matchGlobPattern(_0x19bba4,_0x73092d){const _0x5b05f3=a178_0x4f03,_0x1cb36e=_0x73092d[_0x5b05f3(0x1cc)](/[.+^${}()|[\]\\]/g,_0x5b05f3(0x1b5))[_0x5b05f3(0x1cc)](/\*/g,'.*')[_0x5b05f3(0x1cc)](/\?/g,'.'),_0x47f4f0=new RegExp('^'+_0x1cb36e+'$');return _0x47f4f0[_0x5b05f3(0x1b8)](_0x19bba4);}export function getSanitizedUsername(){const _0x12fabf=a178_0x4f03,_0x210718=process.env.USER||process.env.USERNAME||_0x12fabf(0x1b4);return _0x210718[_0x12fabf(0x1cc)](/[^a-zA-Z0-9]/g,'')[_0x12fabf(0x1c9)]();}function a178_0x4f03(_0x3dc896,_0x78e6cd){_0x3dc896=_0x3dc896-0x1b4;const _0x2e8a61=a178_0x2e8a();let _0x4f0339=_0x2e8a61[_0x3dc896];return _0x4f0339;}export function generateRandomHex(){const _0x11df8e=a178_0x4f03,_0x59b350=Math[_0x11df8e(0x1c1)](Math[_0x11df8e(0x1c6)]()*0xfffff);return _0x59b350[_0x11df8e(0x1c0)](0x10)[_0x11df8e(0x1bc)](0x5,'0');}export function sanitizeFileName(_0x483f4a){const _0x44dc01=a178_0x4f03;return _0x483f4a[_0x44dc01(0x1c9)]()['replace'](/[/\\:*?"<>|]/g,'-')['replace'](/\s+/g,'-')[_0x44dc01(0x1cc)](/-+/g,'-')[_0x44dc01(0x1cc)](/^-|-$/g,'');}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
(function(_0x45ef5f,_0x4254a4){const _0x3a927a=a179_0xa81d,_0x324e38=_0x45ef5f();while(!![]){try{const _0x3b742d=parseInt(_0x3a927a(0xe7))/0x1*(parseInt(_0x3a927a(0xdd))/0x2)+-parseInt(_0x3a927a(0xd7))/0x3*(parseInt(_0x3a927a(0xd5))/0x4)+parseInt(_0x3a927a(0xe5))/0x5+parseInt(_0x3a927a(0xe1))/0x6*(-parseInt(_0x3a927a(0xda))/0x7)+-parseInt(_0x3a927a(0xea))/0x8+parseInt(_0x3a927a(0xe8))/0x9+-parseInt(_0x3a927a(0xeb))/0xa*(parseInt(_0x3a927a(0xd9))/0xb);if(_0x3b742d===_0x4254a4)break;else _0x324e38['push'](_0x324e38['shift']());}catch(_0x3059b0){_0x324e38['push'](_0x324e38['shift']());}}}(a179_0x2797,0x64e01));function hasWildcard(_0xa456ea){return _0xa456ea['includes']('*')||_0xa456ea['includes']('?');}export function parseTableReference(_0x4686be){const _0x6d91bf=a179_0xa81d;if(!_0x4686be||_0x4686be['trim']()[_0x6d91bf(0xe0)]===0x0)throw new Error(_0x6d91bf(0xe6));const _0x4616b4=_0x4686be[_0x6d91bf(0xe3)](),_0x4814d9={'original':_0x4616b4},_0x275641=_0x4616b4[_0x6d91bf(0xde)]('.');if(_0x275641[_0x6d91bf(0xe0)]===0x1){const _0x2f5ff9=_0x275641[0x0];if(!_0x2f5ff9)throw new Error(_0x6d91bf(0xdc));_0x4814d9[_0x6d91bf(0xdf)]=_0x2f5ff9;}else{if(_0x275641[_0x6d91bf(0xe0)]===0x2){const [_0xb5117b,_0x5a5999]=_0x275641;if(!_0xb5117b)throw new Error('Database\x20part\x20cannot\x20be\x20empty\x20-\x20use\x20\x22*\x22\x20for\x20all\x20databases\x20(e.g.,\x20\x22*.mytable\x22)');if(!_0x5a5999)throw new Error(_0x6d91bf(0xdb));_0x4814d9[_0x6d91bf(0xe2)]=_0xb5117b,_0x4814d9[_0x6d91bf(0xdf)]=_0x5a5999;}else{if(_0x275641['length']===0x3){const [_0x12ec78,_0x5a8f71,_0x4c9721]=_0x275641;if(!_0x12ec78||!_0x5a8f71||!_0x4c9721)throw new Error(_0x6d91bf(0xd8));_0x4814d9[_0x6d91bf(0xe9)]=_0x12ec78,_0x4814d9[_0x6d91bf(0xe2)]=_0x5a8f71,_0x4814d9[_0x6d91bf(0xdf)]=_0x4c9721;}else throw new Error(_0x6d91bf(0xd6));}}return _0x4814d9;}export function formatTableReference(_0x26a6bf){const _0x5298dd=a179_0xa81d,_0x296a00=[];return _0x26a6bf[_0x5298dd(0xe9)]&&_0x296a00['push'](_0x26a6bf[_0x5298dd(0xe9)]),_0x26a6bf[_0x5298dd(0xe2)]&&_0x296a00['push'](_0x26a6bf[_0x5298dd(0xe2)]),_0x26a6bf[_0x5298dd(0xdf)]&&_0x296a00['push'](_0x26a6bf[_0x5298dd(0xdf)]),_0x296a00[_0x5298dd(0xec)]('.');}export function validateTableListReference(_0x55ea88){return undefined;}function a179_0xa81d(_0x419032,_0x17ba7f){_0x419032=_0x419032-0xd4;const _0x27972=a179_0x2797();let _0xa81d5e=_0x27972[_0x419032];return _0xa81d5e;}export function validateTableDescribeReference(_0x3ce5c3){const _0x594d97=a179_0xa81d;if(!_0x3ce5c3['table'])return _0x594d97(0xe4);if(_0x3ce5c3[_0x594d97(0xe2)]&&hasWildcard(_0x3ce5c3[_0x594d97(0xe2)]))return'Wildcards\x20are\x20not\x20allowed\x20in\x20database\x20name\x20for\x20describe\x20operation';if(hasWildcard(_0x3ce5c3['table']))return _0x594d97(0xd4);return undefined;}function a179_0x2797(){const _0x368ba2=['8Nglwcm','Invalid\x20pattern\x20format\x20-\x20too\x20many\x20dots\x20(max:\x20catalog.database.table)','62859LMWkfD','Invalid\x20catalog.database.table\x20format\x20-\x20all\x20parts\x20must\x20be\x20non-empty','2992AjlGzc','2188914gQvALJ','Table\x20part\x20cannot\x20be\x20empty\x20-\x20use\x20\x22*\x22\x20for\x20all\x20tables\x20(e.g.,\x20\x22mydb.*\x22)','Pattern\x20cannot\x20be\x20just\x20a\x20dot','1493522hYNTsZ','split','table','length','6qDEAAF','database','trim','Table\x20name\x20is\x20required\x20for\x20describe\x20operation','139495ozXPaF','Pattern\x20cannot\x20be\x20empty\x20or\x20whitespace-only','1FcTZBQ','2713482aklDoM','catalog','1544296foCiqr','4240veMcds','join','Wildcards\x20are\x20not\x20allowed\x20in\x20table\x20name\x20for\x20describe\x20operation'];a179_0x2797=function(){return _0x368ba2;};return a179_0x2797();}
|
package/dist/utils/tdx-logger.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
function a180_0x5f39(_0x5e27ff,_0x3408f7){_0x5e27ff=_0x5e27ff-0x9f;const _0x43032a=a180_0x4303();let _0x5f39c7=_0x43032a[_0x5e27ff];return _0x5f39c7;}const a180_0xbde5e0=a180_0x5f39;(function(_0x59bfcc,_0x4b5760){const _0xc827b6=a180_0x5f39,_0xbc3a59=_0x59bfcc();while(!![]){try{const _0x55b807=-parseInt(_0xc827b6(0xa0))/0x1+parseInt(_0xc827b6(0xaa))/0x2+parseInt(_0xc827b6(0xa3))/0x3*(parseInt(_0xc827b6(0xb3))/0x4)+parseInt(_0xc827b6(0xa4))/0x5+-parseInt(_0xc827b6(0xbc))/0x6+-parseInt(_0xc827b6(0xab))/0x7+parseInt(_0xc827b6(0xa8))/0x8;if(_0x55b807===_0x4b5760)break;else _0xbc3a59['push'](_0xbc3a59['shift']());}catch(_0x5d620e){_0xbc3a59['push'](_0xbc3a59['shift']());}}}(a180_0x4303,0x86e89));function a180_0x4303(){const _0x1ab49b=['trace','logs','fileOnly','info','logFileName','getLogPath','logDir','6506808BsyOlT','tdx.log','872976dmBcck','logLevel','tdx','6lZJxKL','2771865DQHwKK','consoleHandler','Session\x20ended','isInitialized','9610744RZJivR','init','636424eOCyJi','773521hVtkUY','warn','close','fileHandler','INFO','addHandler','error','debug','1093208dlzaPR','logger'];a180_0x4303=function(){return _0x1ab49b;};return a180_0x4303();}import{join}from'path';import{Logger,LogLevel,FileHandler,ConsoleHandler,DefaultLogFormatter}from'./logger/index.js';import{getGlobalCacheDir}from'./global-cache.js';export{LogLevel}from'./logger/index.js';export class TDXLogger{[a180_0xbde5e0(0xa1)];['fileOnly'];[a180_0xbde5e0(0xbb)];[a180_0xbde5e0(0xb9)];[a180_0xbde5e0(0xb4)];[a180_0xbde5e0(0xae)]=null;[a180_0xbde5e0(0xa5)]=null;constructor(_0x23dbe4=LogLevel[a180_0xbde5e0(0xaf)],_0x42f307=![],_0x2f6fc8,_0x2105a7=a180_0xbde5e0(0x9f)){const _0x235775=a180_0xbde5e0;this[_0x235775(0xa1)]=_0x23dbe4,this[_0x235775(0xb7)]=_0x42f307,this[_0x235775(0xbb)]=_0x2f6fc8||join(getGlobalCacheDir(),_0x235775(0xb6)),this[_0x235775(0xb9)]=_0x2105a7,this[_0x235775(0xb4)]=Logger['of'](_0x235775(0xa2));}async[a180_0xbde5e0(0xa9)](){const _0x5d526c=a180_0xbde5e0,_0x23ca1c=join(this[_0x5d526c(0xbb)],this[_0x5d526c(0xb9)]);if(Logger[_0x5d526c(0xa7)]()){!this[_0x5d526c(0xb7)]&&(this['consoleHandler']=new ConsoleHandler({'minLevel':LogLevel[_0x5d526c(0xaf)],'colors':!![]}),Logger[_0x5d526c(0xb0)](this[_0x5d526c(0xa5)]));return;}this[_0x5d526c(0xae)]=new FileHandler({'filePath':_0x23ca1c});const _0x164841=[this[_0x5d526c(0xae)]];!this[_0x5d526c(0xb7)]&&(this[_0x5d526c(0xa5)]=new ConsoleHandler({'minLevel':LogLevel[_0x5d526c(0xaf)],'colors':!![]}),_0x164841['push'](this['consoleHandler'])),await Logger[_0x5d526c(0xa9)]({'defaultLevel':this[_0x5d526c(0xa1)],'handlers':_0x164841,'formatter':new DefaultLogFormatter({'colors':!![]})});}['debug'](..._0x750b3f){const _0x375fe8=a180_0xbde5e0;this['logger'][_0x375fe8(0xb2)](..._0x750b3f);}[a180_0xbde5e0(0xb5)](..._0x521191){const _0x2217a8=a180_0xbde5e0;this[_0x2217a8(0xb4)]['trace'](..._0x521191);}[a180_0xbde5e0(0xb8)](..._0x3bbc9a){const _0x3fd983=a180_0xbde5e0;this[_0x3fd983(0xb4)][_0x3fd983(0xb8)](..._0x3bbc9a);}[a180_0xbde5e0(0xac)](..._0x4266e4){const _0x1462d2=a180_0xbde5e0;this[_0x1462d2(0xb4)][_0x1462d2(0xac)](..._0x4266e4);}[a180_0xbde5e0(0xb1)](..._0xfb3fbd){const _0x55cbda=a180_0xbde5e0;this[_0x55cbda(0xb4)]['error'](..._0xfb3fbd);}async[a180_0xbde5e0(0xad)](){const _0xf61196=a180_0xbde5e0;this[_0xf61196(0xb4)][_0xf61196(0xb8)](_0xf61196(0xa6)),await Logger['shutdown']();}[a180_0xbde5e0(0xba)](){const _0x407b41=a180_0xbde5e0;return join(this[_0x407b41(0xbb)],this[_0x407b41(0xb9)]);}}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a181_0x161987=a181_0x54e1;(function(_0x4b9f93,_0x4625aa){const _0x263204=a181_0x54e1,_0x27ccde=_0x4b9f93();while(!![]){try{const _0x4ed07d=-parseInt(_0x263204(0x1c0))/0x1*(-parseInt(_0x263204(0x1d1))/0x2)+parseInt(_0x263204(0x1d4))/0x3+-parseInt(_0x263204(0x1c3))/0x4+-parseInt(_0x263204(0x1e1))/0x5*(parseInt(_0x263204(0x1d9))/0x6)+parseInt(_0x263204(0x1bf))/0x7*(parseInt(_0x263204(0x1cf))/0x8)+parseInt(_0x263204(0x1bd))/0x9+parseInt(_0x263204(0x1dd))/0xa*(-parseInt(_0x263204(0x1e0))/0xb);if(_0x4ed07d===_0x4625aa)break;else _0x27ccde['push'](_0x27ccde['shift']());}catch(_0x2caea4){_0x27ccde['push'](_0x27ccde['shift']());}}}(a181_0x3be3,0x90ae0));import{get}from'https';import{gt,valid}from'semver';import a181_0x5ba19c from'chalk';import{createGlobalCache}from'./global-cache.js';function a181_0x54e1(_0x3f3425,_0x5eb3b3){_0x3f3425=_0x3f3425-0x1bc;const _0x3be3ed=a181_0x3be3();let _0x54e1ce=_0x3be3ed[_0x3f3425];return _0x54e1ce;}const CACHE_DURATION_MS=0x18*0x3c*0x3c*0x3e8,NPM_REGISTRY_BASE=a181_0x161987(0x1d6),TIMEOUT_MS=0x7d0,stableVersionCache=createGlobalCache(a181_0x161987(0x1c8),'utils/version-check'),nextVersionCache=createGlobalCache('last_version_check_next',a181_0x161987(0x1c4));function getCacheForChannel(_0x4f62bf){const _0x2f497b=a181_0x161987;return _0x4f62bf===_0x2f497b(0x1d8)?nextVersionCache:stableVersionCache;}function a181_0x3be3(){const _0x367185=['next','5645226cppXGc','channel','toISOString','latest','1600710cucgro','currentVersion','stderr','44KayYFX','5JnTzzA','getTime','read','Invalid\x20version\x20format','green','Update\x20available:','latestVersion','10228977MkkGmu','yellow','687043bqEeNW','2jTRRNy','lastCheck','gray','3290448ewYCiA','utils/version-check-next','Run:','parse','error','last_version_check','write','dim','isTTY','\x0aUpdate\x20available:\x20','updateAvailable','statusCode','32RZxTLr','npm\x20install\x20-g\x20@treasuredata/tdx@','630862SbAmIN','stable','cyan','2509092DYCsND','data','https://registry.npmjs.org/@treasuredata/tdx','version'];a181_0x3be3=function(){return _0x367185;};return a181_0x3be3();}function readCache(_0x5e09dd){const _0x1220df=a181_0x161987;return getCacheForChannel(_0x5e09dd)[_0x1220df(0x1e3)]()??null;}function writeCache(_0x51d8f1,_0x531b5f){const _0x5a6f44=a181_0x161987;try{getCacheForChannel(_0x531b5f)[_0x5a6f44(0x1c9)]({'lastCheck':new Date()[_0x5a6f44(0x1db)](),'latestVersion':_0x51d8f1});}catch{}}function isCacheValid(_0xd85fc3){const _0xabf444=a181_0x161987;if(!_0xd85fc3)return![];const _0x2516a9=new Date(_0xd85fc3[_0xabf444(0x1c1)])[_0xabf444(0x1e2)](),_0x2226a4=Date['now']();return _0x2226a4-_0x2516a9<CACHE_DURATION_MS;}function fetchLatestVersion(_0x3fa70e='stable'){const _0x57312c=a181_0x161987,_0x22bbdb=_0x3fa70e==='next'?_0x57312c(0x1d8):_0x57312c(0x1dc),_0x5506fc=NPM_REGISTRY_BASE+'/'+_0x22bbdb;return new Promise((_0xa52ef,_0x264f90)=>{const _0x469eca=_0x57312c,_0x3e5282=get(_0x5506fc,_0x59de05=>{const _0xe179e7=a181_0x54e1;if(_0x59de05['statusCode']!==0xc8){clearTimeout(_0x4c03b2),_0x264f90(new Error('HTTP\x20'+_0x59de05[_0xe179e7(0x1ce)]));return;}let _0x52007e='';_0x59de05['on'](_0xe179e7(0x1d5),_0x23882b=>{_0x52007e+=_0x23882b;}),_0x59de05['on']('end',()=>{const _0x67e279=_0xe179e7;clearTimeout(_0x4c03b2);try{const _0x1337fb=JSON[_0x67e279(0x1c6)](_0x52007e);if(!valid(_0x1337fb[_0x67e279(0x1d7)])){_0x264f90(new Error(_0x67e279(0x1e4)));return;}_0xa52ef(_0x1337fb[_0x67e279(0x1d7)]);}catch(_0x229bca){_0x264f90(_0x229bca);}});})['on'](_0x469eca(0x1c7),_0x40c08e=>{clearTimeout(_0x4c03b2),_0x264f90(_0x40c08e);}),_0x4c03b2=setTimeout(()=>{_0x3e5282['destroy'](),_0x264f90(new Error('Request\x20timeout'));},TIMEOUT_MS);});}export async function checkForUpdate(_0x1c90e8,_0x20faca=a181_0x161987(0x1d2)){const _0x205115=a181_0x161987;try{const _0x3653f9=readCache(_0x20faca);if(isCacheValid(_0x3653f9)){const _0x1b79ea=gt(_0x3653f9[_0x205115(0x1bc)],_0x1c90e8);return{'updateAvailable':_0x1b79ea,'currentVersion':_0x1c90e8,'latestVersion':_0x3653f9[_0x205115(0x1bc)],'channel':_0x20faca};}const _0x1b40f8=await fetchLatestVersion(_0x20faca);writeCache(_0x1b40f8,_0x20faca);const _0x2a10bc=gt(_0x1b40f8,_0x1c90e8);return{'updateAvailable':_0x2a10bc,'currentVersion':_0x1c90e8,'latestVersion':_0x1b40f8,'channel':_0x20faca};}catch{return null;}}export function displayUpdateNotification(_0x3b260b){const _0x21fdf4=a181_0x161987;if(!_0x3b260b[_0x21fdf4(0x1cd)])return;const _0x5e6df8=_0x3b260b[_0x21fdf4(0x1da)]===_0x21fdf4(0x1d8)?_0x21fdf4(0x1d8):_0x21fdf4(0x1dc),_0x3ece3b=process['stderr'][_0x21fdf4(0x1cb)]&&!process.env.NO_COLOR,_0x15f4db=_0x3ece3b?a181_0x5ba19c[_0x21fdf4(0x1c2)]('→'):'→',_0x20581c=_0x3ece3b?a181_0x5ba19c[_0x21fdf4(0x1ca)](_0x3b260b[_0x21fdf4(0x1de)]):_0x3b260b['currentVersion'],_0x4a9b3c=_0x3ece3b?a181_0x5ba19c[_0x21fdf4(0x1e5)](_0x3b260b[_0x21fdf4(0x1bc)]):_0x3b260b[_0x21fdf4(0x1bc)],_0x3a1fa8=_0x3ece3b?a181_0x5ba19c[_0x21fdf4(0x1d3)](_0x21fdf4(0x1d0)+_0x5e6df8):_0x21fdf4(0x1d0)+_0x5e6df8,_0x2c5e49=_0x3ece3b?'\x0a'+a181_0x5ba19c[_0x21fdf4(0x1be)](_0x21fdf4(0x1e6))+'\x20'+_0x20581c+'\x20'+_0x15f4db+'\x20'+_0x4a9b3c+'\x0a'+a181_0x5ba19c[_0x21fdf4(0x1ca)](_0x21fdf4(0x1c5))+'\x20'+_0x3a1fa8+'\x0a':_0x21fdf4(0x1cc)+_0x20581c+'\x20'+_0x15f4db+'\x20'+_0x4a9b3c+'\x0aRun:\x20'+_0x3a1fa8+'\x0a';process[_0x21fdf4(0x1df)][_0x21fdf4(0x1c9)](_0x2c5e49);}
|