chore: mqsrv backend

This commit is contained in:
Chen Gu committed 2026-05-09 00:52:04 +08:00
commit 6985ac64bd
2164 files changed
+904469

No files matched your search

Generated Vendored Executable
+1
View File
@@ -0,0 +1 @@
"use strict";var m=Object.defineProperty;var a=(r,e)=>m(r,"name",{value:e,configurable:!0});var q=require("../../register-2sWVXuRQ.cjs");require("../../get-pipe-path-BoR10qr8.cjs");var t=require("../../register-D46fvsV_.cjs");require("../../require-D4F1Lv60.cjs");var n=require("../../node-features-roYmp9jK.cjs");require("node:module"),require("node:worker_threads"),require("node:url"),require("module"),require("node:path"),require("../../temporary-directory-B83uKxJF.cjs"),require("node:os"),require("get-tsconfig"),require("node:fs"),require("../../index-gckBtVBf.cjs"),require("esbuild"),require("node:crypto"),require("../../client-D6NvIMSC.cjs"),require("node:net"),require("node:util"),require("../../index-BWFBUo6r.cjs");const c=a((r,e)=>{if(!e||typeof e=="object"&&!e.parentURL)throw new Error("The current file path (import.meta.url) must be provided in the second argument of tsImport()");const i=typeof e=="string",u=i?e:e.parentURL,s=Date.now().toString(),o=t.register({namespace:s});return!n.isFeatureSupported(n.esmLoadReadFile)&&!t.isBarePackageNamePattern.test(r)&&t.cjsExtensionPattern.test(r)?Promise.resolve(o.require(r,u)):q.register({namespace:s,...i?{}:e}).import(r,u)},"tsImport");exports.register=q.register,exports.tsImport=c;
+35
View File
@@ -0,0 +1,35 @@
import { MessagePort } from 'node:worker_threads';
import { R as RequiredProperty } from '../../types-Cxp8y2TL.js';
type ScopedImport = (specifier: string, parent: string) => Promise<any>;
type TsconfigOptions = false | string;
type InitializationOptions = {
namespace?: string;
port?: MessagePort;
tsconfig?: TsconfigOptions;
};
type RegisterOptions = {
namespace?: string;
onImport?: (url: string) => void;
tsconfig?: TsconfigOptions;
};
type Unregister = () => Promise<void>;
type NamespacedUnregister = Unregister & {
import: ScopedImport;
unregister: Unregister;
};
type Register = {
(options: RequiredProperty<RegisterOptions, 'namespace'>): NamespacedUnregister;
(options?: RegisterOptions): Unregister;
};
declare const register: Register;
type Options = {
parentURL: string;
onImport?: (url: string) => void;
tsconfig?: TsconfigOptions;
};
declare const tsImport: (specifier: string, options: string | Options) => Promise<any>;
export { type InitializationOptions, type NamespacedUnregister, type Register, type RegisterOptions, type ScopedImport, type Unregister, register, tsImport };
+35
View File
@@ -0,0 +1,35 @@
import { MessagePort } from 'node:worker_threads';
import { R as RequiredProperty } from '../../types-Cxp8y2TL.js';
type ScopedImport = (specifier: string, parent: string) => Promise<any>;
type TsconfigOptions = false | string;
type InitializationOptions = {
namespace?: string;
port?: MessagePort;
tsconfig?: TsconfigOptions;
};
type RegisterOptions = {
namespace?: string;
onImport?: (url: string) => void;
tsconfig?: TsconfigOptions;
};
type Unregister = () => Promise<void>;
type NamespacedUnregister = Unregister & {
import: ScopedImport;
unregister: Unregister;
};
type Register = {
(options: RequiredProperty<RegisterOptions, 'namespace'>): NamespacedUnregister;
(options?: RegisterOptions): Unregister;
};
declare const register: Register;
type Options = {
parentURL: string;
onImport?: (url: string) => void;
tsconfig?: TsconfigOptions;
};
declare const tsImport: (specifier: string, options: string | Options) => Promise<any>;
export { type InitializationOptions, type NamespacedUnregister, type Register, type RegisterOptions, type ScopedImport, type Unregister, register, tsImport };
Generated Vendored Executable
+1
View File
@@ -0,0 +1 @@
var s=Object.defineProperty;var i=(r,t)=>s(r,"name",{value:t,configurable:!0});import{r as p}from"../../register-B7jrtLTO.mjs";import"../../get-pipe-path-BHW2eJdv.mjs";import{r as n,i as c,c as u}from"../../register-CFH5oNdT.mjs";import"../../require-DQxpCAr4.mjs";import{i as g,e as d}from"../../node-features-_8ZFwP_x.mjs";import"node:module";import"node:worker_threads";import"node:url";import"module";import"node:path";import"../../temporary-directory-CwHp0_NW.mjs";import"node:os";import"get-tsconfig";import"node:fs";import"../../index-7AaEi15b.mjs";import"esbuild";import"node:crypto";import"../../client-BQVF1NaW.mjs";import"node:net";import"node:util";import"../../index-gbaejti9.mjs";const f=i((r,t)=>{if(!t||typeof t=="object"&&!t.parentURL)throw new Error("The current file path (import.meta.url) must be provided in the second argument of tsImport()");const e=typeof t=="string",o=e?t:t.parentURL,m=Date.now().toString(),a=n({namespace:m});return!g(d)&&!c.test(r)&&u.test(r)?Promise.resolve(a.require(r,o)):p({namespace:m,...e?{}:t}).import(r,o)},"tsImport");export{p as register,f as tsImport};
Generated Vendored Executable
+2
View File
@@ -0,0 +1,2 @@
"use strict";var S=Object.defineProperty;var l=(e,t)=>S(e,"name",{value:t,configurable:!0});var _=require("node:worker_threads"),d=require("../node-features-roYmp9jK.cjs"),L=require("../register-2sWVXuRQ.cjs");require("../get-pipe-path-BoR10qr8.cjs"),require("node:module");var p=require("node:path"),g=require("node:url");require("get-tsconfig");var s=require("../register-D46fvsV_.cjs"),E=require("node:fs");require("esbuild"),require("node:crypto");var f=require("../index-gckBtVBf.cjs"),v=require("../client-D6NvIMSC.cjs");require("../require-D4F1Lv60.cjs");var F=require("node:fs/promises");require("module"),require("../temporary-directory-B83uKxJF.cjs"),require("node:os"),require("node:util"),require("../index-BWFBUo6r.cjs"),require("node:net");const u={active:!0},b=l(async e=>{if(!e)throw new Error(`tsx must be loaded with --import instead of --loader
The --loader flag was deprecated in Node v20.6.0 and v18.19.0`);u.namespace=e.namespace,e.tsconfig!==!1&&s.loadTsconfig(e.tsconfig??process.env.TSX_TSCONFIG_PATH),e.port&&(u.port=e.port,e.port.on("message",t=>{t==="deactivate"&&(u.active=!1,e.port.postMessage({type:"deactivated"}))}))},"initialize"),J=l(()=>(s.loadTsconfig(process.env.TSX_TSCONFIG_PATH),"process.setSourceMapsEnabled(true);"),"globalPreload"),h=new Map,M=l(async e=>{if(h.has(e))return h.get(e);if(!await E.promises.access(e).then(()=>!0,()=>!1)){h.set(e,void 0);return}const n=await E.promises.readFile(e,"utf8");try{const r=JSON.parse(n);return h.set(e,r),r}catch{throw new Error(`Error parsing: ${e}`)}},"readPackageJson"),j=l(async e=>{let t=new URL("package.json",e);for(;!t.pathname.endsWith("/node_modules/package.json");){const n=g.fileURLToPath(t),r=await M(n);if(r)return r;const a=t;if(t=new URL("../package.json",t),t.pathname===a.pathname)break}},"findPackageJson"),N=l(async e=>(await j(e))?.type??"commonjs","getPackageType"),O=l(e=>{const{pathname:t}=new URL(e),n=p.extname(t);if(n===".mts"||n===".mjs")return"module";if(n===".cts"||n===".cjs")return"commonjs";if(n===".js"||s.tsExtensions.includes(n))return N(e)},"getFormatFromFileUrl"),P="tsx-namespace=",w=l(e=>{const t=e.indexOf(P);if(t===-1)return;const n=e[t-1];if(n!=="?"&&n!=="&")return;const r=t+P.length,a=e.indexOf("&",r);return a===-1?e.slice(r):e.slice(r,a)},"getNamespace"),U=d.isFeatureSupported(d.importAttributes)?"importAttributes":"importAssertions";if(exports.load=async(e,t,n)=>{if(!u.active)return n(e,t);const r=w(e);if(u.namespace&&u.namespace!==r)return n(e,t);if(u.port){const o=new URL(e);o.searchParams.delete("tsx-namespace"),u.port.postMessage({type:"load",url:o.toString()})}if(v.parent.send&&v.parent.send({type:"dependency",path:e}),s.isJsonPattern.test(e)){let o=t[U];o||(o={},t[U]=o),o.type||(o.type="json")}const a=await n(e,t);s.logEsm(3,"loaded by next loader",{url:e,loaded:a});const c=e.startsWith(s.fileUrlPrefix)?g.fileURLToPath(e):e;if(a.format==="commonjs"&&d.isFeatureSupported(d.esmLoadReadFile)&&a.responseURL?.startsWith("file:")&&!c.endsWith(".cjs")){const o=await F.readFile(new URL(e),"utf8");if(!c.endsWith(".js")||f.isESM(o)){const m=f.transformSync(o,c,{tsconfigRaw:s.fileMatcher?.(c)}),T=r?`${c}?namespace=${encodeURIComponent(r)}`:c;return a.responseURL=`data:text/javascript,${encodeURIComponent(m.code)}?filePath=${encodeURIComponent(T)}`,s.logEsm(3,"returning CJS export annotation",a),a}}if(!a.source)return a;const i=a.source.toString();if(a.format==="json"||s.tsExtensionsPattern.test(e)){const o=await f.transform(i,c,{tsconfigRaw:p.isAbsolute(c)?s.fileMatcher?.(c):void 0});return{format:"module",source:s.inlineSourceMap(o)}}if(a.format==="module"){const o=f.transformDynamicImport(c,i);o&&(a.source=s.inlineSourceMap(o))}return a},s.debugEnabled){const e=exports.load;exports.load=async(t,n,r)=>{s.logEsm(2,"load",{url:t,context:n});const a=await e(t,n,r);return s.logEsm(1,"loaded",{url:t,result:a}),a}}const R=l(e=>{if(e.url)return e.url;const t=e.message.match(/^Cannot find module '([^']+)'/);if(t){const[,r]=t;return r}const n=e.message.match(/^Cannot find package '([^']+)'/);if(n){const[,r]=n;if(!p.isAbsolute(r))return;const a=g.pathToFileURL(r);if(a.pathname.endsWith("/")&&(a.pathname+="package.json"),a.pathname.endsWith("/package.json")){const c=f.readJsonFile(a);if(c?.main)return new URL(c.main,a).toString()}else return a.toString()}},"getMissingPathFromNotFound"),y=l(async(e,t,n,r)=>{const a=s.mapTsExtensions(e);if(s.logEsm(3,"resolveExtensions",{url:e,context:t,throwError:r,tryPaths:a}),!a)return;let c;for(const i of a)try{return await n(i,t)}catch(o){const{code:m}=o;if(m!=="ERR_MODULE_NOT_FOUND"&&m!=="ERR_PACKAGE_PATH_NOT_EXPORTED")throw o;c=o}if(r)throw c},"resolveExtensions"),A=l(async(e,t,n)=>{if(s.logEsm(3,"resolveBase",{specifier:e,context:t,specifierStartsWithFileUrl:e.startsWith(s.fileUrlPrefix),isRelativePath:s.isRelativePath(e),tsExtensionsPattern:s.tsExtensionsPattern.test(t.parentURL),allowJs:s.allowJs}),(e.startsWith(s.fileUrlPrefix)||s.isRelativePath(e))&&(s.tsExtensionsPattern.test(t.parentURL)||s.allowJs)){const r=await y(e,t,n);if(s.logEsm(3,"resolveBase resolved",{specifier:e,context:t,resolved:r}),r)return r}try{return await n(e,t)}catch(r){if(s.logEsm(3,"resolveBase error",{specifier:e,context:t,error:r}),r instanceof Error){const a=r;if(a.code==="ERR_MODULE_NOT_FOUND"){const c=R(a);if(c){const i=await y(c,t,n);if(i)return i}}}throw r}},"resolveBase"),q=l(async(e,t,n)=>{if(s.logEsm(3,"resolveDirectory",{specifier:e,context:t,isDirectory:s.isDirectoryPattern.test(e)}),(e==="."||e===".."||e.endsWith("/.."))&&(e+="/"),s.isDirectoryPattern.test(e)){const r=new URL(e,t.parentURL);return r.pathname=p.join(r.pathname,"index"),await y(r.toString(),t,n,!0)}try{return await A(e,t,n)}catch(r){if(r instanceof Error){s.logEsm(3,"resolveDirectory error",{specifier:e,context:t,error:r});const a=r;if(a.code==="ERR_UNSUPPORTED_DIR_IMPORT"){const c Line truncated
Generated Vendored Executable
+2
View File
@@ -0,0 +1,2 @@
var C=Object.defineProperty;var c=(t,e)=>C(t,"name",{value:e,configurable:!0});import{isMainThread as $}from"node:worker_threads";import{i as y,a as q,e as B,m as G}from"../node-features-_8ZFwP_x.mjs";import{r as H}from"../register-B7jrtLTO.mjs";import"../get-pipe-path-BHW2eJdv.mjs";import"node:module";import l from"node:path";import{fileURLToPath as k,pathToFileURL as E}from"node:url";import"get-tsconfig";import{l as T,t as Q,b as X,d as m,f,e as w,g as S,h as _,j as L,k as b,m as P,n as j,o as z,p as F,q as J}from"../register-CFH5oNdT.mjs";import N from"node:fs";import"esbuild";import"node:crypto";import{i as K,a as V,t as Y,b as Z,r as x}from"../index-7AaEi15b.mjs";import{p as O}from"../client-BQVF1NaW.mjs";import"../require-DQxpCAr4.mjs";import{readFile as tt}from"node:fs/promises";import"module";import"../temporary-directory-CwHp0_NW.mjs";import"node:os";import"node:util";import"../index-gbaejti9.mjs";import"node:net";const p={active:!0},et=c(async t=>{if(!t)throw new Error(`tsx must be loaded with --import instead of --loader
The --loader flag was deprecated in Node v20.6.0 and v18.19.0`);p.namespace=t.namespace,t.tsconfig!==!1&&T(t.tsconfig??process.env.TSX_TSCONFIG_PATH),t.port&&(p.port=t.port,t.port.on("message",e=>{e==="deactivate"&&(p.active=!1,t.port.postMessage({type:"deactivated"}))}))},"initialize"),at=c(()=>(T(process.env.TSX_TSCONFIG_PATH),"process.setSourceMapsEnabled(true);"),"globalPreload"),u=new Map,st=c(async t=>{if(u.has(t))return u.get(t);if(!await N.promises.access(t).then(()=>!0,()=>!1)){u.set(t,void 0);return}const r=await N.promises.readFile(t,"utf8");try{const a=JSON.parse(r);return u.set(t,a),a}catch{throw new Error(`Error parsing: ${t}`)}},"readPackageJson"),rt=c(async t=>{let e=new URL("package.json",t);for(;!e.pathname.endsWith("/node_modules/package.json");){const r=k(e),a=await st(r);if(a)return a;const s=e;if(e=new URL("../package.json",e),e.pathname===s.pathname)break}},"findPackageJson"),ot=c(async t=>(await rt(t))?.type??"commonjs","getPackageType"),nt=c(t=>{const{pathname:e}=new URL(t),r=l.extname(e);if(r===".mts"||r===".mjs")return"module";if(r===".cts"||r===".cjs")return"commonjs";if(r===".js"||Q.includes(r))return ot(t)},"getFormatFromFileUrl"),h="tsx-namespace=",R=c(t=>{const e=t.indexOf(h);if(e===-1)return;const r=t[e-1];if(r!=="?"&&r!=="&")return;const a=e+h.length,s=t.indexOf("&",a);return s===-1?t.slice(a):t.slice(a,s)},"getNamespace"),W=y(q)?"importAttributes":"importAssertions";let U=c(async(t,e,r)=>{if(!p.active)return r(t,e);const a=R(t);if(p.namespace&&p.namespace!==a)return r(t,e);if(p.port){const o=new URL(t);o.searchParams.delete("tsx-namespace"),p.port.postMessage({type:"load",url:o.toString()})}if(O.send&&O.send({type:"dependency",path:t}),X.test(t)){let o=e[W];o||(o={},e[W]=o),o.type||(o.type="json")}const s=await r(t,e);m(3,"loaded by next loader",{url:t,loaded:s});const i=t.startsWith(f)?k(t):t;if(s.format==="commonjs"&&y(B)&&s.responseURL?.startsWith("file:")&&!i.endsWith(".cjs")){const o=await tt(new URL(t),"utf8");if(!i.endsWith(".js")||K(o)){const d=V(o,i,{tsconfigRaw:S?.(i)}),I=a?`${i}?namespace=${encodeURIComponent(a)}`:i;return s.responseURL=`data:text/javascript,${encodeURIComponent(d.code)}?filePath=${encodeURIComponent(I)}`,m(3,"returning CJS export annotation",s),s}}if(!s.source)return s;const n=s.source.toString();if(s.format==="json"||w.test(t)){const o=await Y(n,i,{tsconfigRaw:l.isAbsolute(i)?S?.(i):void 0});return{format:"module",source:_(o)}}if(s.format==="module"){const o=Z(i,n);o&&(s.source=_(o))}return s},"load");if(L){const t=U;U=c(async(e,r,a)=>{m(2,"load",{url:e,context:r});const s=await t(e,r,a);return m(1,"loaded",{url:e,result:s}),s},"load")}const A=c(t=>{if(t.url)return t.url;const e=t.message.match(/^Cannot find module '([^']+)'/);if(e){const[,a]=e;return a}const r=t.message.match(/^Cannot find package '([^']+)'/);if(r){const[,a]=r;if(!l.isAbsolute(a))return;const s=E(a);if(s.pathname.endsWith("/")&&(s.pathname+="package.json"),s.pathname.endsWith("/package.json")){const i=x(s);if(i?.main)return new URL(i.main,s).toString()}else return s.toString()}},"getMissingPathFromNotFound"),g=c(async(t,e,r,a)=>{const s=z(t);if(m(3,"resolveExtensions",{url:t,context:e,throwError:a,tryPaths:s}),!s)return;let i;for(const n of s)try{return await r(n,e)}catch(o){const{code:d}=o;if(d!=="ERR_MODULE_NOT_FOUND"&&d!=="ERR_PACKAGE_PATH_NOT_EXPORTED")throw o;i=o}if(a)throw i},"resolveExtensions"),it=c(async(t,e,r)=>{if(m(3,"resolveBase",{specifier:t,context:e,specifierStartsWithFileUrl:t.startsWith(f),isRelativePath:F(t),tsExtensionsPattern:w.test(e.parentURL),allowJs:J}),(t.startsWith(f)||F(t))&&(w.test(e.parentURL)||J)){const a=await g(t,e,r);if(m(3,"resolveBase resolved",{specifier:t,context:e,resolved:a}),a)return a}try{return await r(t,e)}catch(a){if(m(3,"resolveBase error",{specifier:t,context:e,error:a}),a instanceof Error){const s=a;if(s.code==="ERR_MODULE_NOT_FOUND"){const i=A(s);if(i){const n=await g(i,e,r);if(n)return n}}}throw a}},"resolveBase"),M=c(async(t,e,r)=>{if(m(3,"resolveDirectory",{specifier:t,context:e,isDirectory:j.test(t)}),(t==="."||t===".."||t.endsWith("/.."))&&(t+="/"),j.test(t)){const a=new URL(t,e.parentURL);return a.pathname=l.join(a.pathname,"index"),await g(a.toString(),e,r,!0)}try{return await it(t,e,r)}catch(a){if(a instanceof Error){m(3,"resolveDirectory error",{specifier:t,context:e,error:a});const s=a;if(s.code==="ERR_UNSUPPORTED_DIR_IMPORT"){const i=A(s);if(i)try{return await g(`${i}/index`,e,r,!0)}catch(n){const o=n,{message:d}=o;throw o.message=o.message.replace(`${"/index".replace("/",l.sep)}'`,"'"),o.stack=o.stack.replace(d,o.message),o}}}throw a}},"resolveDirectory"),ct=c(async(t,e,r)=>{if(m(3,"resolveTsPaths",{specifier:t,context:e,requestAcceptsQuery:b(t),tsconfigPathsMatcher:P,fromNodeModules:e.parentURL?.includes("/node_modules/")}),!b(t)&&P&&!e.parentURL?.includes("/node_modules/")){const a=P(t);m(3,"resolveTsPaths",{possiblePaths:a});for(const s of a)try{return await M(E(s).toString(),e,r)}catch{}}return M(t,e,r)},"resolLine truncated