locust 2.24.1.dev21__py3-none-any.whl → 2.24.2.dev3__py3-none-any.whl

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.
locust/_version.py CHANGED
@@ -12,5 +12,5 @@ __version__: str
12
12
  __version_tuple__: VERSION_TUPLE
13
13
  version_tuple: VERSION_TUPLE
14
14
 
15
- __version__ = version = '2.24.1.dev21'
16
- __version_tuple__ = version_tuple = (2, 24, 1, 'dev21')
15
+ __version__ = version = '2.24.2.dev3'
16
+ __version_tuple__ = version_tuple = (2, 24, 2, 'dev3')
@@ -580,7 +580,10 @@ class ResponseContextManager(FastResponse):
580
580
  def __init__(self, response, environment, request_meta):
581
581
  # copy data from response to this object
582
582
  self.__dict__ = response.__dict__
583
- self._cached_content = response.content
583
+ try:
584
+ self._cached_content = response._cached_content
585
+ except AttributeError:
586
+ pass
584
587
  # store reference to locust Environment
585
588
  self._environment = environment
586
589
  self.request_meta = request_meta
@@ -71,6 +71,28 @@ class TestFastHttpSession(WebserverTestCase):
71
71
  # download the content of the streaming response (so we don't get an ugly exception in the log)
72
72
  _ = r.content
73
73
 
74
+ def test_streaming_response_catch_response(self):
75
+ """
76
+ Test a request to an endpoint that returns a streaming response, and uses catch_response
77
+ """
78
+ s = self.get_client()
79
+
80
+ with s.get("/streaming/30", stream=True, catch_response=True) as r:
81
+ # typical usage of r when stream=True is to read the stream as desired,
82
+ # with the possibility to "fail fast" when some things are read early on
83
+ response_content = str(r.stream.read())
84
+ r.failure("some error")
85
+
86
+ self.assertRegex(response_content, "streaming response")
87
+
88
+ stats = self.runner.stats.get("/streaming/30", "GET")
89
+ self.assertEqual(1, stats.num_requests)
90
+ self.assertEqual(1, stats.num_failures)
91
+
92
+ # verify that response time does NOT include whole download time, when using stream=True
93
+ self.assertGreaterEqual(stats.avg_response_time, 0)
94
+ self.assertLess(stats.avg_response_time, 250)
95
+
74
96
  def test_slow_redirect(self):
75
97
  s = self.get_client()
76
98
  url = "/redirect?url=/redirect&delay=0.5"
@@ -168,7 +168,7 @@ ${W.current.stack}
168
168
  `});++n<e.length;)n&&r.push({type:"text",value:`
169
169
  `}),r.push(e[n]);return t&&e.length>0&&r.push({type:"text",value:`
170
170
  `}),r}function tE(e){let t=0,r=e.charCodeAt(t);for(;r===9||r===32;)t++,r=e.charCodeAt(t);return e.slice(t)}function rE(e,t){const r=ive(e,t),n=r.one(e,void 0),i=qpe(r),a=Array.isArray(n)?{type:"root",children:n}:n||{type:"root",children:[]};return i&&a.children.push({type:"text",value:`
171
- `},i),a}function uve(e,t){return e&&"run"in e?async function(r,n){const i=rE(r,t);await e.run(i,n)}:function(r){return rE(r,t||e)}}function nE(e){if(e)throw e}var Ym=Object.prototype.hasOwnProperty,F6=Object.prototype.toString,iE=Object.defineProperty,aE=Object.getOwnPropertyDescriptor,oE=function(t){return typeof Array.isArray=="function"?Array.isArray(t):F6.call(t)==="[object Array]"},sE=function(t){if(!t||F6.call(t)!=="[object Object]")return!1;var r=Ym.call(t,"constructor"),n=t.constructor&&t.constructor.prototype&&Ym.call(t.constructor.prototype,"isPrototypeOf");if(t.constructor&&!r&&!n)return!1;var i;for(i in t);return typeof i>"u"||Ym.call(t,i)},lE=function(t,r){iE&&r.name==="__proto__"?iE(t,r.name,{enumerable:!0,configurable:!0,value:r.newValue,writable:!0}):t[r.name]=r.newValue},uE=function(t,r){if(r==="__proto__")if(Ym.call(t,r)){if(aE)return aE(t,r).value}else return;return t[r]},cve=function e(){var t,r,n,i,a,o,s=arguments[0],l=1,u=arguments.length,c=!1;for(typeof s=="boolean"&&(c=s,s=arguments[1]||{},l=2),(s==null||typeof s!="object"&&typeof s!="function")&&(s={});l<u;++l)if(t=arguments[l],t!=null)for(r in t)n=uE(s,r),i=uE(t,r),s!==i&&(c&&i&&(sE(i)||(a=oE(i)))?(a?(a=!1,o=n&&oE(n)?n:[]):o=n&&sE(n)?n:{},lE(s,{name:r,newValue:e(c,o,i)})):typeof i<"u"&&lE(s,{name:r,newValue:i}));return s};const lb=dv(cve);function oT(e){if(typeof e!="object"||e===null)return!1;const t=Object.getPrototypeOf(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(Symbol.toStringTag in e)&&!(Symbol.iterator in e)}function fve(){const e=[],t={run:r,use:n};return t;function r(...i){let a=-1;const o=i.pop();if(typeof o!="function")throw new TypeError("Expected function as last argument, not "+o);s(null,...i);function s(l,...u){const c=e[++a];let f=-1;if(l){o(l);return}for(;++f<i.length;)(u[f]===null||u[f]===void 0)&&(u[f]=i[f]);i=u,c?dve(c,s)(...u):o(null,...u)}}function n(i){if(typeof i!="function")throw new TypeError("Expected `middelware` to be a function, not "+i);return e.push(i),t}}function dve(e,t){let r;return n;function n(...o){const s=e.length>o.length;let l;s&&o.push(i);try{l=e.apply(this,o)}catch(u){const c=u;if(s&&r)throw c;return i(c)}s||(l instanceof Promise?l.then(a,i):l instanceof Error?i(l):a(l))}function i(o,...s){r||(r=!0,t(o,...s))}function a(o){i(null,o)}}const da={basename:hve,dirname:pve,extname:vve,join:gve,sep:"/"};function hve(e,t){if(t!==void 0&&typeof t!="string")throw new TypeError('"ext" argument must be a string');Mv(e);let r=0,n=-1,i=e.length,a;if(t===void 0||t.length===0||t.length>e.length){for(;i--;)if(e.codePointAt(i)===47){if(a){r=i+1;break}}else n<0&&(a=!0,n=i+1);return n<0?"":e.slice(r,n)}if(t===e)return"";let o=-1,s=t.length-1;for(;i--;)if(e.codePointAt(i)===47){if(a){r=i+1;break}}else o<0&&(a=!0,o=i+1),s>-1&&(e.codePointAt(i)===t.codePointAt(s--)?s<0&&(n=i):(s=-1,n=o));return r===n?n=o:n<0&&(n=e.length),e.slice(r,n)}function pve(e){if(Mv(e),e.length===0)return".";let t=-1,r=e.length,n;for(;--r;)if(e.codePointAt(r)===47){if(n){t=r;break}}else n||(n=!0);return t<0?e.codePointAt(0)===47?"/":".":t===1&&e.codePointAt(0)===47?"//":e.slice(0,t)}function vve(e){Mv(e);let t=e.length,r=-1,n=0,i=-1,a=0,o;for(;t--;){const s=e.codePointAt(t);if(s===47){if(o){n=t+1;break}continue}r<0&&(o=!0,r=t+1),s===46?i<0?i=t:a!==1&&(a=1):i>-1&&(a=-1)}return i<0||r<0||a===0||a===1&&i===r-1&&i===n+1?"":e.slice(i,r)}function gve(...e){let t=-1,r;for(;++t<e.length;)Mv(e[t]),e[t]&&(r=r===void 0?e[t]:r+"/"+e[t]);return r===void 0?".":mve(r)}function mve(e){Mv(e);const t=e.codePointAt(0)===47;let r=yve(e,!t);return r.length===0&&!t&&(r="."),r.length>0&&e.codePointAt(e.length-1)===47&&(r+="/"),t?"/"+r:r}function yve(e,t){let r="",n=0,i=-1,a=0,o=-1,s,l;for(;++o<=e.length;){if(o<e.length)s=e.codePointAt(o);else{if(s===47)break;s=47}if(s===47){if(!(i===o-1||a===1))if(i!==o-1&&a===2){if(r.length<2||n!==2||r.codePointAt(r.length-1)!==46||r.codePointAt(r.length-2)!==46){if(r.length>2){if(l=r.lastIndexOf("/"),l!==r.length-1){l<0?(r="",n=0):(r=r.slice(0,l),n=r.length-1-r.lastIndexOf("/")),i=o,a=0;continue}}else if(r.length>0){r="",n=0,i=o,a=0;continue}}t&&(r=r.length>0?r+"/..":"..",n=2)}else r.length>0?r+="/"+e.slice(i+1,o):r=e.slice(i+1,o),n=o-i-1;i=o,a=0}else s===46&&a>-1?a++:a=-1}return r}function Mv(e){if(typeof e!="string")throw new TypeError("Path must be a string. Received "+JSON.stringify(e))}const xve={cwd:Sve};function Sve(){return"/"}function sT(e){return!!(e!==null&&typeof e=="object"&&"href"in e&&e.href&&"protocol"in e&&e.protocol&&e.auth===void 0)}function bve(e){if(typeof e=="string")e=new URL(e);else if(!sT(e)){const t=new TypeError('The "path" argument must be of type string or an instance of URL. Received `'+e+"`");throw t.code="ERR_INVALID_ARG_TYPE",t}if(e.protocol!=="file:"){const t=new TypeError("The URL must be of scheme file");throw t.code="ERR_INVALID_URL_SCHEME",t}return _ve(e)}function _ve(e){if(e.hostname!==""){const n=new TypeError('File URL host must be "localhost" or empty on darwin');throw n.code="ERR_INVALID_FILE_URL_HOST",n}const t=e.pathname;let r=-1;for(;++r<t.length;)if(t.codePointAt(r)===37&&t.codePointAt(r+1)===50){const n=t.codePointAt(r+2);if(n===70||n===102){const i=new TypeError("File URL path must not include encoded / characters");throw i.code="ERR_INVALID_FILE_URL_PATH",i}}return decodeURIComponent(t)}const ub=["history","path","basename","stem","extname","dirname"];class V6{constructor(t){let r;t?sT(t)?r={path:t}:typeof t=="string"||wve(t)?r={value:t}:r=t:r={},this.cwd=xve.cwd(),this.data={},this.history=[],this.messages=[],this.value,this.map,this.result,this.stored;let n=-1;for(;++n<ub.length;){const a=ub[n];a in r&&r[a]!==void 0&&r[a]!==null&&(this[a]=a==="history"?[...r[a]]:r[a])}let i;for(i in r)ub.includes(i)||(this[i]=r[i])}get basename(){return typeof this.path=="string"?da.basename(this.path):void 0}set basename(t){fb(t,"basename"),cb(t,"basename"),this.path=da.join(this.dirname||"",t)}get dirname(){return typeof this.path=="string"?da.dirname(this.path):void 0}set dirname(t){cE(this.basename,"dirname"),this.path=da.join(t||"",this.basename)}get extname(){return typeof this.path=="string"?da.extname(this.path):void 0}set extname(t){if(cb(t,"extname"),cE(this.dirname,"extname"),t){if(t.codePointAt(0)!==46)throw new Error("`extname` must start with `.`");if(t.includes(".",1))throw new Error("`extname` cannot contain multiple dots")}this.path=da.join(this.dirname,this.stem+(t||""))}get path(){return this.history[this.history.length-1]}set path(t){sT(t)&&(t=bve(t)),fb(t,"path"),this.path!==t&&this.history.push(t)}get stem(){return typeof this.path=="string"?da.basename(this.path,this.extname):void 0}set stem(t){fb(t,"stem"),cb(t,"stem"),this.path=da.join(this.dirname||"",t+(this.extname||""))}fail(t,r,n){const i=this.message(t,r,n);throw i.fatal=!0,i}info(t,r,n){const i=this.message(t,r,n);return i.fatal=void 0,i}message(t,r,n){const i=new pn(t,r,n);return this.path&&(i.name=this.path+":"+i.name,i.file=this.path),i.fatal=!1,this.messages.push(i),i}toString(t){return this.value===void 0?"":typeof this.value=="string"?this.value:new TextDecoder(t||void 0).decode(this.value)}}function cb(e,t){if(e&&e.includes(da.sep))throw new Error("`"+t+"` cannot be a path: did not expect `"+da.sep+"`")}function fb(e,t){if(!e)throw new Error("`"+t+"` cannot be empty")}function cE(e,t){if(!e)throw new Error("Setting `"+t+"` requires `path` to be set too")}function wve(e){return!!(e&&typeof e=="object"&&"byteLength"in e&&"byteOffset"in e)}const Cve=function(e){const n=this.constructor.prototype,i=n[e],a=function(){return i.apply(a,arguments)};Object.setPrototypeOf(a,n);const o=Object.getOwnPropertyNames(i);for(const s of o){const l=Object.getOwnPropertyDescriptor(i,s);l&&Object.defineProperty(a,s,l)}return a},Tve={}.hasOwnProperty;class sk extends Cve{constructor(){super("copy"),this.Compiler=void 0,this.Parser=void 0,this.attachers=[],this.compiler=void 0,this.freezeIndex=-1,this.frozen=void 0,this.namespace={},this.parser=void 0,this.transformers=fve()}copy(){const t=new sk;let r=-1;for(;++r<this.attachers.length;){const n=this.attachers[r];t.use(...n)}return t.data(lb(!0,{},this.namespace)),t}data(t,r){return typeof t=="string"?arguments.length===2?(pb("data",this.frozen),this.namespace[t]=r,this):Tve.call(this.namespace,t)&&this.namespace[t]||void 0:t?(pb("data",this.frozen),this.namespace=t,this):this.namespace}freeze(){if(this.frozen)return this;const t=this;for(;++this.freezeIndex<this.attachers.length;){const[r,...n]=this.attachers[this.freezeIndex];if(n[0]===!1)continue;n[0]===!0&&(n[0]=void 0);const i=r.call(t,...n);typeof i=="function"&&this.transformers.use(i)}return this.frozen=!0,this.freezeIndex=Number.POSITIVE_INFINITY,this}parse(t){this.freeze();const r=Ag(t),n=this.parser||this.Parser;return db("parse",n),n(String(r),r)}process(t,r){const n=this;return this.freeze(),db("process",this.parser||this.Parser),hb("process",this.compiler||this.Compiler),r?i(void 0,r):new Promise(i);function i(a,o){const s=Ag(t),l=n.parse(s);n.run(l,s,function(c,f,d){if(c||!f||!d)return u(c);const h=f,p=n.stringify(h,d);kve(p)?d.value=p:d.result=p,u(c,d)});function u(c,f){c||!f?o(c):a?a(f):r(void 0,f)}}}processSync(t){let r=!1,n;return this.freeze(),db("processSync",this.parser||this.Parser),hb("processSync",this.compiler||this.Compiler),this.process(t,i),dE("processSync","process",r),n;function i(a,o){r=!0,nE(a),n=o}}run(t,r,n){fE(t),this.freeze();const i=this.transformers;return!n&&typeof r=="function"&&(n=r,r=void 0),n?a(void 0,n):new Promise(a);function a(o,s){const l=Ag(r);i.run(t,l,u);function u(c,f,d){const h=f||t;c?s(c):o?o(h):n(void 0,h,d)}}}runSync(t,r){let n=!1,i;return this.run(t,r,a),dE("runSync","run",n),i;function a(o,s){nE(o),i=s,n=!0}}stringify(t,r){this.freeze();const n=Ag(r),i=this.compiler||this.Compiler;return hb("stringify",i),fE(t),i(t,n)}use(t,...r){const n=this.attachers,i=this.namespace;if(pb("use",this.frozen),t!=null)if(typeof t=="function")l(t,r);else if(typeof t=="object")Array.isArray(t)?s(t):o(t);else throw new TypeError("Expected usable value, not `"+t+"`");return this;function a(u){if(typeof u=="function")l(u,[]);else if(typeof u=="object")if(Array.isArray(u)){const[c,...f]=u;l(c,f)}else o(u);else throw new TypeError("Expected usable value, not `"+u+"`")}function o(u){if(!("plugins"in u)&&!("settings"in u))throw new Error("Expected usable value but received an empty preset, which is probably a mistake: presets typically come with `plugins` and sometimes with `settings`, but this has neither");s(u.plugins),u.settings&&(i.settings=lb(!0,i.settings,u.settings))}function s(u){let c=-1;if(u!=null)if(Array.isArray(u))for(;++c<u.length;){const f=u[c];a(f)}else throw new TypeError("Expected a list of plugins, not `"+u+"`")}function l(u,c){let f=-1,d=-1;for(;++f<n.length;)if(n[f][0]===u){d=f;break}if(d===-1)n.push([u,...c]);else if(c.length>0){let[h,...p]=c;const v=n[d][1];oT(v)&&oT(h)&&(h=lb(!0,v,h)),n[d]=[u,h,...p]}}}}const Ave=new sk().freeze();function db(e,t){if(typeof t!="function")throw new TypeError("Cannot `"+e+"` without `parser`")}function hb(e,t){if(typeof t!="function")throw new TypeError("Cannot `"+e+"` without `compiler`")}function pb(e,t){if(t)throw new Error("Cannot call `"+e+"` on a frozen processor.\nCreate a new processor first, by calling it: use `processor()` instead of `processor`.")}function fE(e){if(!oT(e)||typeof e.type!="string")throw new TypeError("Expected node, got `"+e+"`")}function dE(e,t,r){if(!r)throw new Error("`"+e+"` finished async. Use `"+t+"` instead")}function Ag(e){return Mve(e)?e:new V6(e)}function Mve(e){return!!(e&&typeof e=="object"&&"message"in e&&"messages"in e)}function kve(e){return typeof e=="string"||Ive(e)}function Ive(e){return!!(e&&typeof e=="object"&&"byteLength"in e&&"byteOffset"in e)}const hE={}.hasOwnProperty,Pve="https://github.com/remarkjs/react-markdown/blob/main/changelog.md",pE=[],vE={allowDangerousHtml:!0},Dve=/^(https?|ircs?|mailto|xmpp)$/i,Rve=[{from:"astPlugins",id:"remove-buggy-html-in-markdown-parser"},{from:"allowDangerousHtml",id:"remove-buggy-html-in-markdown-parser"},{from:"allowNode",id:"replace-allownode-allowedtypes-and-disallowedtypes",to:"allowElement"},{from:"allowedTypes",id:"replace-allownode-allowedtypes-and-disallowedtypes",to:"allowedElements"},{from:"disallowedTypes",id:"replace-allownode-allowedtypes-and-disallowedtypes",to:"disallowedElements"},{from:"escapeHtml",id:"remove-buggy-html-in-markdown-parser"},{from:"includeElementIndex",id:"#remove-includeelementindex"},{from:"includeNodeIndex",id:"change-includenodeindex-to-includeelementindex"},{from:"linkTarget",id:"remove-linktarget"},{from:"plugins",id:"change-plugins-to-remarkplugins",to:"remarkPlugins"},{from:"rawSourcePos",id:"#remove-rawsourcepos"},{from:"renderers",id:"change-renderers-to-components",to:"components"},{from:"source",id:"change-source-to-children",to:"children"},{from:"sourcePos",id:"#remove-sourcepos"},{from:"transformImageUri",id:"#add-urltransform",to:"urlTransform"},{from:"transformLinkUri",id:"#add-urltransform",to:"urlTransform"}];function Lve(e){const t=e.allowedElements,r=e.allowElement,n=e.children||"",i=e.className,a=e.components,o=e.disallowedElements,s=e.rehypePlugins||pE,l=e.remarkPlugins||pE,u=e.remarkRehypeOptions?{...e.remarkRehypeOptions,...vE}:vE,c=e.skipHtml,f=e.unwrapDisallowed,d=e.urlTransform||Eve,h=Ave().use(ppe).use(l).use(uve,u).use(s),p=new V6;typeof n=="string"&&(p.value=n);for(const y of Rve)Object.hasOwn(e,y.from)&&(""+y.from+(y.to?"use `"+y.to+"` instead":"remove it")+Pve+y.id,void 0);const v=h.parse(p);let g=h.runSync(v,p);return i&&(g={type:"element",tagName:"div",properties:{className:i},children:g.type==="root"?g.children:[g]}),$6(g,m),Zfe(g,{Fragment:D.Fragment,components:a,ignoreInvalidStyle:!0,jsx:D.jsx,jsxs:D.jsxs,passKeys:!0,passNode:!0});function m(y,x,S){if(y.type==="raw"&&S&&typeof x=="number")return c?S.children.splice(x,1):S.children[x]={type:"text",value:y.value},x;if(y.type==="element"){let _;for(_ in ab)if(hE.call(ab,_)&&hE.call(y.properties,_)){const b=y.properties[_],w=ab[_];(w===null||w.includes(y.tagName))&&(y.properties[_]=d(String(b||""),_,y))}}if(y.type==="element"){let _=t?!t.includes(y.tagName):o?o.includes(y.tagName):!1;if(!_&&r&&typeof x=="number"&&(_=!r(y,x,S)),_&&S&&typeof x=="number")return f&&y.children?S.children.splice(x,1,...y.children):S.children.splice(x,1),x}}}function Eve(e){return pde(e,Dve)}function Ove(e,t){const r=t?-1:1;return function(n,i){const a=n[e],o=i[e];return a<o?r*-1:a>o?r*1:0}}function Nve(e,{hasTotalRow:t=!1,defaultSortKey:r="name"}={hasTotalRow:!1,defaultSortKey:"name"}){const[n,i]=O.useState(e),[a,o]=O.useState(!1),s=O.useRef(),l=c=>{const d=(t?e.slice(0,-1):[...e]).sort(Ove(c,c===s.current&&!a));i(t?[...d,...e.slice(-1)]:d)},u=O.useCallback(c=>{s.current||(s.current=r);const f=c.target.getAttribute("data-sortkey");if(f===s.current)if(a){o(!1),s.current=void 0,l(r);return}else o(!0);else a&&o(!1);l(f),s.current=f},[s,e,a]);return O.useEffect(()=>{e.length&&l(s.current||r)},[e]),{onTableHeadClick:u,sortedRows:n,currentSortField:s.current}}const dh=(e,t=0)=>{const r=Math.pow(10,t);return Math.round(e*r)/r};function zve({content:e,formatter:t,round:r,markdown:n}){return t?t(e):r?dh(e,r):n?D.jsx(Lve,{skipHtml:!1,children:e}):e}function qf({rows:e,structure:t,hasTotalRow:r,defaultSortKey:n}){const{onTableHeadClick:i,sortedRows:a,currentSortField:o}=Nve(e,{hasTotalRow:r,defaultSortKey:n});return D.jsx(RG,{component:Wf,children:D.jsxs(PG,{children:[D.jsx(LG,{children:D.jsx(Qy,{children:t.map(({title:s,key:l})=>D.jsx(zl,{"data-sortkey":l,onClick:i,sx:{cursor:"pointer",color:o===l?"primary.main":"text.primary"},children:s},`table-head-${l}`))})}),D.jsx(DG,{children:a.map((s,l)=>D.jsx(Qy,{children:t.map(({key:u,...c},f)=>D.jsx(zl,{children:D.jsx(zve,{content:s[u],...c})},`table-row=${f}`))},`${s.name}-${l}`))})]})})}function Bve({rows:e,tableStructure:t}){return t?D.jsx(qf,{rows:e,structure:t}):null}const $ve=({swarm:{extendedTables:e},ui:{extendedStats:t},url:{query:r}})=>{const n=r&&r.tab&&e&&e.find(({key:a})=>a===r.tab),i=r&&r.tab&&t&&t.find(({key:a})=>a===r.tab);return{tableStructure:n?n.structure.map(({key:a,...o})=>({key:vV(a),...o})):null,rows:i?i.data:[]}},Fve=Ln($ve)(Bve),Vve=[{key:"count",title:"# occurrences"},{key:"msg",title:"Message"},{key:"traceback",title:"Traceback"}];function G6({exceptions:e}){return D.jsx(qf,{rows:e,structure:Vve})}const Gve=({ui:{exceptions:e}})=>({exceptions:e}),Hve=Ln(Gve)(G6),Wve=[{key:"occurrences",title:"# Failures"},{key:"method",title:"Method"},{key:"name",title:"Name"},{key:"error",title:"Message",markdown:!0}];function H6({errors:e}){return D.jsx(qf,{rows:e,structure:Wve})}const jve=({ui:{errors:e}})=>({errors:e}),Uve=Ln(jve)(H6);function qve(){const e=Ys(({logViewer:{logs:t}})=>t);return D.jsxs(it,{children:[D.jsx(qe,{component:"h2",variant:"h4",children:"Logs"}),D.jsx("ul",{children:e.map((t,r)=>D.jsx("li",{children:t},`log-${r}`))})]})}function Yve({extendedCsvFiles:e,statsHistoryEnabled:t}){const r=Ys(({theme:{isDarkMode:n}})=>n);return D.jsxs(yG,{sx:{display:"flex",flexDirection:"column"},children:[D.jsx(tc,{children:D.jsx(on,{href:"/stats/requests/csv",children:"Download requests CSV"})}),t&&D.jsx(tc,{children:D.jsx(on,{href:"/stats/requests_full_history/csv",children:"Download full request statistics history CSV"})}),D.jsx(tc,{children:D.jsx(on,{href:"/stats/failures/csv",children:"Download failures CSV"})}),D.jsx(tc,{children:D.jsx(on,{href:"/exceptions/csv",children:"Download exceptions CSV"})}),D.jsx(tc,{children:D.jsx(on,{href:`/stats/report?theme=${r?Si.DARK:Si.LIGHT}`,target:"_blank",children:"Download Report"})}),e&&e.map(({href:n,title:i},a)=>D.jsx(tc,{children:D.jsx(on,{href:n,children:i})},`extended-csv-${a}`))]})}const Xve=({swarm:{extendedCsvFiles:e,statsHistoryEnabled:t}})=>({extendedCsvFiles:e,statsHistoryEnabled:t}),Zve=Ln(Xve)(Yve);var lk={},Kve=Ou;Object.defineProperty(lk,"__esModule",{value:!0});var W6=lk.default=void 0,Qve=Kve(Nu()),Jve=D,ege=(0,Qve.default)((0,Jve.jsx)("path",{d:"M14.67 5v14H9.33V5h5.34zm1 14H21V5h-5.33v14zm-7.34 0V5H3v14h5.33z"}),"ViewColumn");W6=lk.default=ege;function tge({structure:e,selectedColumns:t,addColumn:r,removeColumn:n}){const[i,a]=O.useState(null);return D.jsxs(fG,{direction:"row",justifyContent:"end",my:2,spacing:1,children:[D.jsx(qa,{onClick:o=>a(o.currentTarget),variant:"outlined",children:D.jsx(W6,{})}),D.jsx(_G,{anchorEl:i,anchorOrigin:{vertical:"bottom",horizontal:"left"},onClose:()=>a(null),open:!!i,children:D.jsx(hG,{sx:{p:2},children:e.map(({key:o,title:s})=>D.jsx(dG,{control:D.jsx(Ise,{checked:t.includes(o),onChange:()=>{t.includes(o)?n(o):r(o)}}),label:s},o))})})]})}function rge(e){const[t,r]=O.useState(e.map(o=>o.key));return{selectedColumns:t,addColumn:o=>{r([...t,o])},removeColumn:o=>{r(t.filter(s=>s!==o))},filteredStructure:(o=>o.filter(s=>t.includes(s.key)))(e)}}const nge=Ra.percentilesToStatistics?Ra.percentilesToStatistics.map(e=>({title:`${e*100}%ile (ms)`,key:`responseTimePercentile${e}`})):[],gE=[{key:"method",title:"Type"},{key:"name",title:"Name"},{key:"numRequests",title:"# Requests"},{key:"numFailures",title:"# Fails"},{key:"medianResponseTime",title:"Median (ms)",round:2},...nge,{key:"avgResponseTime",title:"Average (ms)",round:2},{key:"minResponseTime",title:"Min (ms)"},{key:"maxResponseTime",title:"Max (ms)"},{key:"avgContentLength",title:"Average size (bytes)",round:2},{key:"currentRps",title:"Current RPS",round:2},{key:"currentFailPerSec",title:"Current Failures/s",round:2}];function j6({stats:e}){const{selectedColumns:t,addColumn:r,removeColumn:n,filteredStructure:i}=rge(gE);return D.jsxs(D.Fragment,{children:[D.jsx(tge,{addColumn:r,removeColumn:n,selectedColumns:t,structure:gE}),D.jsx(qf,{hasTotalRow:!0,rows:e,structure:i})]})}const ige=({ui:{stats:e}})=>({stats:e}),age=Ln(ige)(j6);/*! *****************************************************************************
171
+ `},i),a}function uve(e,t){return e&&"run"in e?async function(r,n){const i=rE(r,t);await e.run(i,n)}:function(r){return rE(r,t||e)}}function nE(e){if(e)throw e}var Ym=Object.prototype.hasOwnProperty,F6=Object.prototype.toString,iE=Object.defineProperty,aE=Object.getOwnPropertyDescriptor,oE=function(t){return typeof Array.isArray=="function"?Array.isArray(t):F6.call(t)==="[object Array]"},sE=function(t){if(!t||F6.call(t)!=="[object Object]")return!1;var r=Ym.call(t,"constructor"),n=t.constructor&&t.constructor.prototype&&Ym.call(t.constructor.prototype,"isPrototypeOf");if(t.constructor&&!r&&!n)return!1;var i;for(i in t);return typeof i>"u"||Ym.call(t,i)},lE=function(t,r){iE&&r.name==="__proto__"?iE(t,r.name,{enumerable:!0,configurable:!0,value:r.newValue,writable:!0}):t[r.name]=r.newValue},uE=function(t,r){if(r==="__proto__")if(Ym.call(t,r)){if(aE)return aE(t,r).value}else return;return t[r]},cve=function e(){var t,r,n,i,a,o,s=arguments[0],l=1,u=arguments.length,c=!1;for(typeof s=="boolean"&&(c=s,s=arguments[1]||{},l=2),(s==null||typeof s!="object"&&typeof s!="function")&&(s={});l<u;++l)if(t=arguments[l],t!=null)for(r in t)n=uE(s,r),i=uE(t,r),s!==i&&(c&&i&&(sE(i)||(a=oE(i)))?(a?(a=!1,o=n&&oE(n)?n:[]):o=n&&sE(n)?n:{},lE(s,{name:r,newValue:e(c,o,i)})):typeof i<"u"&&lE(s,{name:r,newValue:i}));return s};const lb=dv(cve);function oT(e){if(typeof e!="object"||e===null)return!1;const t=Object.getPrototypeOf(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(Symbol.toStringTag in e)&&!(Symbol.iterator in e)}function fve(){const e=[],t={run:r,use:n};return t;function r(...i){let a=-1;const o=i.pop();if(typeof o!="function")throw new TypeError("Expected function as last argument, not "+o);s(null,...i);function s(l,...u){const c=e[++a];let f=-1;if(l){o(l);return}for(;++f<i.length;)(u[f]===null||u[f]===void 0)&&(u[f]=i[f]);i=u,c?dve(c,s)(...u):o(null,...u)}}function n(i){if(typeof i!="function")throw new TypeError("Expected `middelware` to be a function, not "+i);return e.push(i),t}}function dve(e,t){let r;return n;function n(...o){const s=e.length>o.length;let l;s&&o.push(i);try{l=e.apply(this,o)}catch(u){const c=u;if(s&&r)throw c;return i(c)}s||(l instanceof Promise?l.then(a,i):l instanceof Error?i(l):a(l))}function i(o,...s){r||(r=!0,t(o,...s))}function a(o){i(null,o)}}const da={basename:hve,dirname:pve,extname:vve,join:gve,sep:"/"};function hve(e,t){if(t!==void 0&&typeof t!="string")throw new TypeError('"ext" argument must be a string');Mv(e);let r=0,n=-1,i=e.length,a;if(t===void 0||t.length===0||t.length>e.length){for(;i--;)if(e.codePointAt(i)===47){if(a){r=i+1;break}}else n<0&&(a=!0,n=i+1);return n<0?"":e.slice(r,n)}if(t===e)return"";let o=-1,s=t.length-1;for(;i--;)if(e.codePointAt(i)===47){if(a){r=i+1;break}}else o<0&&(a=!0,o=i+1),s>-1&&(e.codePointAt(i)===t.codePointAt(s--)?s<0&&(n=i):(s=-1,n=o));return r===n?n=o:n<0&&(n=e.length),e.slice(r,n)}function pve(e){if(Mv(e),e.length===0)return".";let t=-1,r=e.length,n;for(;--r;)if(e.codePointAt(r)===47){if(n){t=r;break}}else n||(n=!0);return t<0?e.codePointAt(0)===47?"/":".":t===1&&e.codePointAt(0)===47?"//":e.slice(0,t)}function vve(e){Mv(e);let t=e.length,r=-1,n=0,i=-1,a=0,o;for(;t--;){const s=e.codePointAt(t);if(s===47){if(o){n=t+1;break}continue}r<0&&(o=!0,r=t+1),s===46?i<0?i=t:a!==1&&(a=1):i>-1&&(a=-1)}return i<0||r<0||a===0||a===1&&i===r-1&&i===n+1?"":e.slice(i,r)}function gve(...e){let t=-1,r;for(;++t<e.length;)Mv(e[t]),e[t]&&(r=r===void 0?e[t]:r+"/"+e[t]);return r===void 0?".":mve(r)}function mve(e){Mv(e);const t=e.codePointAt(0)===47;let r=yve(e,!t);return r.length===0&&!t&&(r="."),r.length>0&&e.codePointAt(e.length-1)===47&&(r+="/"),t?"/"+r:r}function yve(e,t){let r="",n=0,i=-1,a=0,o=-1,s,l;for(;++o<=e.length;){if(o<e.length)s=e.codePointAt(o);else{if(s===47)break;s=47}if(s===47){if(!(i===o-1||a===1))if(i!==o-1&&a===2){if(r.length<2||n!==2||r.codePointAt(r.length-1)!==46||r.codePointAt(r.length-2)!==46){if(r.length>2){if(l=r.lastIndexOf("/"),l!==r.length-1){l<0?(r="",n=0):(r=r.slice(0,l),n=r.length-1-r.lastIndexOf("/")),i=o,a=0;continue}}else if(r.length>0){r="",n=0,i=o,a=0;continue}}t&&(r=r.length>0?r+"/..":"..",n=2)}else r.length>0?r+="/"+e.slice(i+1,o):r=e.slice(i+1,o),n=o-i-1;i=o,a=0}else s===46&&a>-1?a++:a=-1}return r}function Mv(e){if(typeof e!="string")throw new TypeError("Path must be a string. Received "+JSON.stringify(e))}const xve={cwd:Sve};function Sve(){return"/"}function sT(e){return!!(e!==null&&typeof e=="object"&&"href"in e&&e.href&&"protocol"in e&&e.protocol&&e.auth===void 0)}function bve(e){if(typeof e=="string")e=new URL(e);else if(!sT(e)){const t=new TypeError('The "path" argument must be of type string or an instance of URL. Received `'+e+"`");throw t.code="ERR_INVALID_ARG_TYPE",t}if(e.protocol!=="file:"){const t=new TypeError("The URL must be of scheme file");throw t.code="ERR_INVALID_URL_SCHEME",t}return _ve(e)}function _ve(e){if(e.hostname!==""){const n=new TypeError('File URL host must be "localhost" or empty on darwin');throw n.code="ERR_INVALID_FILE_URL_HOST",n}const t=e.pathname;let r=-1;for(;++r<t.length;)if(t.codePointAt(r)===37&&t.codePointAt(r+1)===50){const n=t.codePointAt(r+2);if(n===70||n===102){const i=new TypeError("File URL path must not include encoded / characters");throw i.code="ERR_INVALID_FILE_URL_PATH",i}}return decodeURIComponent(t)}const ub=["history","path","basename","stem","extname","dirname"];class V6{constructor(t){let r;t?sT(t)?r={path:t}:typeof t=="string"||wve(t)?r={value:t}:r=t:r={},this.cwd=xve.cwd(),this.data={},this.history=[],this.messages=[],this.value,this.map,this.result,this.stored;let n=-1;for(;++n<ub.length;){const a=ub[n];a in r&&r[a]!==void 0&&r[a]!==null&&(this[a]=a==="history"?[...r[a]]:r[a])}let i;for(i in r)ub.includes(i)||(this[i]=r[i])}get basename(){return typeof this.path=="string"?da.basename(this.path):void 0}set basename(t){fb(t,"basename"),cb(t,"basename"),this.path=da.join(this.dirname||"",t)}get dirname(){return typeof this.path=="string"?da.dirname(this.path):void 0}set dirname(t){cE(this.basename,"dirname"),this.path=da.join(t||"",this.basename)}get extname(){return typeof this.path=="string"?da.extname(this.path):void 0}set extname(t){if(cb(t,"extname"),cE(this.dirname,"extname"),t){if(t.codePointAt(0)!==46)throw new Error("`extname` must start with `.`");if(t.includes(".",1))throw new Error("`extname` cannot contain multiple dots")}this.path=da.join(this.dirname,this.stem+(t||""))}get path(){return this.history[this.history.length-1]}set path(t){sT(t)&&(t=bve(t)),fb(t,"path"),this.path!==t&&this.history.push(t)}get stem(){return typeof this.path=="string"?da.basename(this.path,this.extname):void 0}set stem(t){fb(t,"stem"),cb(t,"stem"),this.path=da.join(this.dirname||"",t+(this.extname||""))}fail(t,r,n){const i=this.message(t,r,n);throw i.fatal=!0,i}info(t,r,n){const i=this.message(t,r,n);return i.fatal=void 0,i}message(t,r,n){const i=new pn(t,r,n);return this.path&&(i.name=this.path+":"+i.name,i.file=this.path),i.fatal=!1,this.messages.push(i),i}toString(t){return this.value===void 0?"":typeof this.value=="string"?this.value:new TextDecoder(t||void 0).decode(this.value)}}function cb(e,t){if(e&&e.includes(da.sep))throw new Error("`"+t+"` cannot be a path: did not expect `"+da.sep+"`")}function fb(e,t){if(!e)throw new Error("`"+t+"` cannot be empty")}function cE(e,t){if(!e)throw new Error("Setting `"+t+"` requires `path` to be set too")}function wve(e){return!!(e&&typeof e=="object"&&"byteLength"in e&&"byteOffset"in e)}const Cve=function(e){const n=this.constructor.prototype,i=n[e],a=function(){return i.apply(a,arguments)};Object.setPrototypeOf(a,n);const o=Object.getOwnPropertyNames(i);for(const s of o){const l=Object.getOwnPropertyDescriptor(i,s);l&&Object.defineProperty(a,s,l)}return a},Tve={}.hasOwnProperty;class sk extends Cve{constructor(){super("copy"),this.Compiler=void 0,this.Parser=void 0,this.attachers=[],this.compiler=void 0,this.freezeIndex=-1,this.frozen=void 0,this.namespace={},this.parser=void 0,this.transformers=fve()}copy(){const t=new sk;let r=-1;for(;++r<this.attachers.length;){const n=this.attachers[r];t.use(...n)}return t.data(lb(!0,{},this.namespace)),t}data(t,r){return typeof t=="string"?arguments.length===2?(pb("data",this.frozen),this.namespace[t]=r,this):Tve.call(this.namespace,t)&&this.namespace[t]||void 0:t?(pb("data",this.frozen),this.namespace=t,this):this.namespace}freeze(){if(this.frozen)return this;const t=this;for(;++this.freezeIndex<this.attachers.length;){const[r,...n]=this.attachers[this.freezeIndex];if(n[0]===!1)continue;n[0]===!0&&(n[0]=void 0);const i=r.call(t,...n);typeof i=="function"&&this.transformers.use(i)}return this.frozen=!0,this.freezeIndex=Number.POSITIVE_INFINITY,this}parse(t){this.freeze();const r=Ag(t),n=this.parser||this.Parser;return db("parse",n),n(String(r),r)}process(t,r){const n=this;return this.freeze(),db("process",this.parser||this.Parser),hb("process",this.compiler||this.Compiler),r?i(void 0,r):new Promise(i);function i(a,o){const s=Ag(t),l=n.parse(s);n.run(l,s,function(c,f,d){if(c||!f||!d)return u(c);const h=f,p=n.stringify(h,d);kve(p)?d.value=p:d.result=p,u(c,d)});function u(c,f){c||!f?o(c):a?a(f):r(void 0,f)}}}processSync(t){let r=!1,n;return this.freeze(),db("processSync",this.parser||this.Parser),hb("processSync",this.compiler||this.Compiler),this.process(t,i),dE("processSync","process",r),n;function i(a,o){r=!0,nE(a),n=o}}run(t,r,n){fE(t),this.freeze();const i=this.transformers;return!n&&typeof r=="function"&&(n=r,r=void 0),n?a(void 0,n):new Promise(a);function a(o,s){const l=Ag(r);i.run(t,l,u);function u(c,f,d){const h=f||t;c?s(c):o?o(h):n(void 0,h,d)}}}runSync(t,r){let n=!1,i;return this.run(t,r,a),dE("runSync","run",n),i;function a(o,s){nE(o),i=s,n=!0}}stringify(t,r){this.freeze();const n=Ag(r),i=this.compiler||this.Compiler;return hb("stringify",i),fE(t),i(t,n)}use(t,...r){const n=this.attachers,i=this.namespace;if(pb("use",this.frozen),t!=null)if(typeof t=="function")l(t,r);else if(typeof t=="object")Array.isArray(t)?s(t):o(t);else throw new TypeError("Expected usable value, not `"+t+"`");return this;function a(u){if(typeof u=="function")l(u,[]);else if(typeof u=="object")if(Array.isArray(u)){const[c,...f]=u;l(c,f)}else o(u);else throw new TypeError("Expected usable value, not `"+u+"`")}function o(u){if(!("plugins"in u)&&!("settings"in u))throw new Error("Expected usable value but received an empty preset, which is probably a mistake: presets typically come with `plugins` and sometimes with `settings`, but this has neither");s(u.plugins),u.settings&&(i.settings=lb(!0,i.settings,u.settings))}function s(u){let c=-1;if(u!=null)if(Array.isArray(u))for(;++c<u.length;){const f=u[c];a(f)}else throw new TypeError("Expected a list of plugins, not `"+u+"`")}function l(u,c){let f=-1,d=-1;for(;++f<n.length;)if(n[f][0]===u){d=f;break}if(d===-1)n.push([u,...c]);else if(c.length>0){let[h,...p]=c;const v=n[d][1];oT(v)&&oT(h)&&(h=lb(!0,v,h)),n[d]=[u,h,...p]}}}}const Ave=new sk().freeze();function db(e,t){if(typeof t!="function")throw new TypeError("Cannot `"+e+"` without `parser`")}function hb(e,t){if(typeof t!="function")throw new TypeError("Cannot `"+e+"` without `compiler`")}function pb(e,t){if(t)throw new Error("Cannot call `"+e+"` on a frozen processor.\nCreate a new processor first, by calling it: use `processor()` instead of `processor`.")}function fE(e){if(!oT(e)||typeof e.type!="string")throw new TypeError("Expected node, got `"+e+"`")}function dE(e,t,r){if(!r)throw new Error("`"+e+"` finished async. Use `"+t+"` instead")}function Ag(e){return Mve(e)?e:new V6(e)}function Mve(e){return!!(e&&typeof e=="object"&&"message"in e&&"messages"in e)}function kve(e){return typeof e=="string"||Ive(e)}function Ive(e){return!!(e&&typeof e=="object"&&"byteLength"in e&&"byteOffset"in e)}const hE={}.hasOwnProperty,Pve="https://github.com/remarkjs/react-markdown/blob/main/changelog.md",pE=[],vE={allowDangerousHtml:!0},Dve=/^(https?|ircs?|mailto|xmpp)$/i,Rve=[{from:"astPlugins",id:"remove-buggy-html-in-markdown-parser"},{from:"allowDangerousHtml",id:"remove-buggy-html-in-markdown-parser"},{from:"allowNode",id:"replace-allownode-allowedtypes-and-disallowedtypes",to:"allowElement"},{from:"allowedTypes",id:"replace-allownode-allowedtypes-and-disallowedtypes",to:"allowedElements"},{from:"disallowedTypes",id:"replace-allownode-allowedtypes-and-disallowedtypes",to:"disallowedElements"},{from:"escapeHtml",id:"remove-buggy-html-in-markdown-parser"},{from:"includeElementIndex",id:"#remove-includeelementindex"},{from:"includeNodeIndex",id:"change-includenodeindex-to-includeelementindex"},{from:"linkTarget",id:"remove-linktarget"},{from:"plugins",id:"change-plugins-to-remarkplugins",to:"remarkPlugins"},{from:"rawSourcePos",id:"#remove-rawsourcepos"},{from:"renderers",id:"change-renderers-to-components",to:"components"},{from:"source",id:"change-source-to-children",to:"children"},{from:"sourcePos",id:"#remove-sourcepos"},{from:"transformImageUri",id:"#add-urltransform",to:"urlTransform"},{from:"transformLinkUri",id:"#add-urltransform",to:"urlTransform"}];function Lve(e){const t=e.allowedElements,r=e.allowElement,n=e.children||"",i=e.className,a=e.components,o=e.disallowedElements,s=e.rehypePlugins||pE,l=e.remarkPlugins||pE,u=e.remarkRehypeOptions?{...e.remarkRehypeOptions,...vE}:vE,c=e.skipHtml,f=e.unwrapDisallowed,d=e.urlTransform||Eve,h=Ave().use(ppe).use(l).use(uve,u).use(s),p=new V6;typeof n=="string"&&(p.value=n);for(const y of Rve)Object.hasOwn(e,y.from)&&(""+y.from+(y.to?"use `"+y.to+"` instead":"remove it")+Pve+y.id,void 0);const v=h.parse(p);let g=h.runSync(v,p);return i&&(g={type:"element",tagName:"div",properties:{className:i},children:g.type==="root"?g.children:[g]}),$6(g,m),Zfe(g,{Fragment:D.Fragment,components:a,ignoreInvalidStyle:!0,jsx:D.jsx,jsxs:D.jsxs,passKeys:!0,passNode:!0});function m(y,x,S){if(y.type==="raw"&&S&&typeof x=="number")return c?S.children.splice(x,1):S.children[x]={type:"text",value:y.value},x;if(y.type==="element"){let _;for(_ in ab)if(hE.call(ab,_)&&hE.call(y.properties,_)){const b=y.properties[_],w=ab[_];(w===null||w.includes(y.tagName))&&(y.properties[_]=d(String(b||""),_,y))}}if(y.type==="element"){let _=t?!t.includes(y.tagName):o?o.includes(y.tagName):!1;if(!_&&r&&typeof x=="number"&&(_=!r(y,x,S)),_&&S&&typeof x=="number")return f&&y.children?S.children.splice(x,1,...y.children):S.children.splice(x,1),x}}}function Eve(e){return pde(e,Dve)}function Ove(e,t){const r=t?-1:1;return function(n,i){const a=n[e],o=i[e];return a<o?r*-1:a>o?r*1:0}}function Nve(e,{hasTotalRow:t=!1,defaultSortKey:r="name"}={hasTotalRow:!1,defaultSortKey:"name"}){const[n,i]=O.useState(e),[a,o]=O.useState(!1),s=O.useRef(),l=c=>{const d=(t?e.slice(0,-1):[...e]).sort(Ove(c,c===s.current&&!a));i(t?[...d,...e.slice(-1)]:d)},u=O.useCallback(c=>{s.current||(s.current=r);const f=c.target.getAttribute("data-sortkey");if(f===s.current)if(a){o(!1),s.current=void 0,l(r);return}else o(!0);else a&&o(!1);l(f),s.current=f},[s,e,a]);return O.useEffect(()=>{e.length&&l(s.current||r)},[e]),{onTableHeadClick:u,sortedRows:n,currentSortField:s.current}}const dh=(e,t=0)=>{const r=Math.pow(10,t);return Math.round(e*r)/r};function zve({content:e,formatter:t,round:r,markdown:n}){return t?t(e):r?dh(e,r):n?D.jsx(Lve,{skipHtml:!1,children:e}):e}function qf({rows:e,structure:t,hasTotalRow:r,defaultSortKey:n}){const{onTableHeadClick:i,sortedRows:a,currentSortField:o}=Nve(e,{hasTotalRow:r,defaultSortKey:n});return D.jsx(RG,{component:Wf,children:D.jsxs(PG,{children:[D.jsx(LG,{children:D.jsx(Qy,{children:t.map(({title:s,key:l})=>D.jsx(zl,{"data-sortkey":l,onClick:i,sx:{cursor:"pointer",color:o===l?"primary.main":"text.primary"},children:s},`table-head-${l}`))})}),D.jsx(DG,{children:a.map((s,l)=>D.jsx(Qy,{children:t.map(({key:u,...c},f)=>D.jsx(zl,{children:D.jsx(zve,{content:s[u],...c})},`table-row=${f}`))},`${s.name}-${l}`))})]})})}function Bve({rows:e,tableStructure:t}){return t?D.jsx(qf,{rows:e,structure:t}):null}const $ve=({swarm:{extendedTables:e},ui:{extendedStats:t},url:{query:r}})=>{const n=r&&r.tab&&e&&e.find(({key:a})=>a===r.tab),i=r&&r.tab&&t&&t.find(({key:a})=>a===r.tab);return{tableStructure:n?n.structure.map(({key:a,...o})=>({key:vV(a),...o})):null,rows:i?i.data:[]}},Fve=Ln($ve)(Bve),Vve=[{key:"count",title:"# occurrences"},{key:"msg",title:"Message",markdown:!0},{key:"traceback",title:"Traceback",markdown:!0}];function G6({exceptions:e}){return D.jsx(qf,{rows:e,structure:Vve})}const Gve=({ui:{exceptions:e}})=>({exceptions:e}),Hve=Ln(Gve)(G6),Wve=[{key:"occurrences",title:"# Failures"},{key:"method",title:"Method"},{key:"name",title:"Name"},{key:"error",title:"Message",markdown:!0}];function H6({errors:e}){return D.jsx(qf,{rows:e,structure:Wve})}const jve=({ui:{errors:e}})=>({errors:e}),Uve=Ln(jve)(H6);function qve(){const e=Ys(({logViewer:{logs:t}})=>t);return D.jsxs(it,{children:[D.jsx(qe,{component:"h2",variant:"h4",children:"Logs"}),D.jsx("ul",{children:e.map((t,r)=>D.jsx("li",{children:t},`log-${r}`))})]})}function Yve({extendedCsvFiles:e,statsHistoryEnabled:t}){const r=Ys(({theme:{isDarkMode:n}})=>n);return D.jsxs(yG,{sx:{display:"flex",flexDirection:"column"},children:[D.jsx(tc,{children:D.jsx(on,{href:"/stats/requests/csv",children:"Download requests CSV"})}),t&&D.jsx(tc,{children:D.jsx(on,{href:"/stats/requests_full_history/csv",children:"Download full request statistics history CSV"})}),D.jsx(tc,{children:D.jsx(on,{href:"/stats/failures/csv",children:"Download failures CSV"})}),D.jsx(tc,{children:D.jsx(on,{href:"/exceptions/csv",children:"Download exceptions CSV"})}),D.jsx(tc,{children:D.jsx(on,{href:`/stats/report?theme=${r?Si.DARK:Si.LIGHT}`,target:"_blank",children:"Download Report"})}),e&&e.map(({href:n,title:i},a)=>D.jsx(tc,{children:D.jsx(on,{href:n,children:i})},`extended-csv-${a}`))]})}const Xve=({swarm:{extendedCsvFiles:e,statsHistoryEnabled:t}})=>({extendedCsvFiles:e,statsHistoryEnabled:t}),Zve=Ln(Xve)(Yve);var lk={},Kve=Ou;Object.defineProperty(lk,"__esModule",{value:!0});var W6=lk.default=void 0,Qve=Kve(Nu()),Jve=D,ege=(0,Qve.default)((0,Jve.jsx)("path",{d:"M14.67 5v14H9.33V5h5.34zm1 14H21V5h-5.33v14zm-7.34 0V5H3v14h5.33z"}),"ViewColumn");W6=lk.default=ege;function tge({structure:e,selectedColumns:t,addColumn:r,removeColumn:n}){const[i,a]=O.useState(null);return D.jsxs(fG,{direction:"row",justifyContent:"end",my:2,spacing:1,children:[D.jsx(qa,{onClick:o=>a(o.currentTarget),variant:"outlined",children:D.jsx(W6,{})}),D.jsx(_G,{anchorEl:i,anchorOrigin:{vertical:"bottom",horizontal:"left"},onClose:()=>a(null),open:!!i,children:D.jsx(hG,{sx:{p:2},children:e.map(({key:o,title:s})=>D.jsx(dG,{control:D.jsx(Ise,{checked:t.includes(o),onChange:()=>{t.includes(o)?n(o):r(o)}}),label:s},o))})})]})}function rge(e){const[t,r]=O.useState(e.map(o=>o.key));return{selectedColumns:t,addColumn:o=>{r([...t,o])},removeColumn:o=>{r(t.filter(s=>s!==o))},filteredStructure:(o=>o.filter(s=>t.includes(s.key)))(e)}}const nge=Ra.percentilesToStatistics?Ra.percentilesToStatistics.map(e=>({title:`${e*100}%ile (ms)`,key:`responseTimePercentile${e}`})):[],gE=[{key:"method",title:"Type"},{key:"name",title:"Name"},{key:"numRequests",title:"# Requests"},{key:"numFailures",title:"# Fails"},{key:"medianResponseTime",title:"Median (ms)",round:2},...nge,{key:"avgResponseTime",title:"Average (ms)",round:2},{key:"minResponseTime",title:"Min (ms)"},{key:"maxResponseTime",title:"Max (ms)"},{key:"avgContentLength",title:"Average size (bytes)",round:2},{key:"currentRps",title:"Current RPS",round:2},{key:"currentFailPerSec",title:"Current Failures/s",round:2}];function j6({stats:e}){const{selectedColumns:t,addColumn:r,removeColumn:n,filteredStructure:i}=rge(gE);return D.jsxs(D.Fragment,{children:[D.jsx(tge,{addColumn:r,removeColumn:n,selectedColumns:t,structure:gE}),D.jsx(qf,{hasTotalRow:!0,rows:e,structure:i})]})}const ige=({ui:{stats:e}})=>({stats:e}),age=Ln(ige)(j6);/*! *****************************************************************************
172
172
  Copyright (c) Microsoft Corporation.
173
173
 
174
174
  Permission to use, copy, modify, and/or distribute this software for any
@@ -7,7 +7,7 @@
7
7
  <meta name="theme-color" content="#000000" />
8
8
 
9
9
  <title>Locust</title>
10
- <script type="module" crossorigin src="./assets/index-fd3e763b.js"></script>
10
+ <script type="module" crossorigin src="./assets/index-941b6e82.js"></script>
11
11
  </head>
12
12
  <body>
13
13
  <div id="root"></div>
@@ -7,7 +7,7 @@
7
7
  <meta name="theme-color" content="#000000" />
8
8
 
9
9
  <title>Locust</title>
10
- <script type="module" crossorigin src="./assets/index-fd3e763b.js"></script>
10
+ <script type="module" crossorigin src="./assets/index-941b6e82.js"></script>
11
11
  </head>
12
12
  <body>
13
13
  <div id="root"></div>
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: locust
3
- Version: 2.24.1.dev21
3
+ Version: 2.24.2.dev3
4
4
  Summary: Developer friendly load testing framework
5
5
  License: MIT
6
6
  Project-URL: Homepage, https://github.com/locustio/locust
@@ -1,6 +1,6 @@
1
1
  locust/__init__.py,sha256=g6oA-Ba_hs3gLWVf5MKJ1mvfltI8MFnDWG8qslqm8yg,1402
2
2
  locust/__main__.py,sha256=vBQ82334kX06ImDbFlPFgiBRiLIinwNk3z8Khs6hd74,31
3
- locust/_version.py,sha256=t59rG58w4ySF_V-Aned63H6_xR_gccAQ3sepagXCQmk,428
3
+ locust/_version.py,sha256=NHViSFVW9L7CfGPaz76_fBgRI3EyAS6poSBDAyLU_rk,426
4
4
  locust/argument_parser.py,sha256=iDnCJNs9ySKOrIn6xZjZXN3YIelOPC1FSR2MK5nEHP4,31973
5
5
  locust/clients.py,sha256=o3G9welWb-zhgDUM5TKnMVFMJckr_m0FI8Dxn3OtBUA,14810
6
6
  locust/debug.py,sha256=We6Z9W0btkKSc7PxWmrZx-xMynvOOsKhG6jmDgQin0g,5134
@@ -18,7 +18,7 @@ locust/shape.py,sha256=t-lwBS8LOjWcKXNL7j2U3zroIXJ1b0fazUwpRYQOKXw,1973
18
18
  locust/stats.py,sha256=BXvAybKiqI6QF5THdnk-fWkL-FiZKwrAm2W8KzkTchg,46118
19
19
  locust/web.py,sha256=DVcx53VXApAc6kFfG7so2_kB_qqcw7ojKpBd-dJoijU,28267
20
20
  locust/contrib/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
21
- locust/contrib/fasthttp.py,sha256=9_0S5hqV2P6rU-NWzsV5Nx9urgj7Ib7xar0BigkQS0k,26734
21
+ locust/contrib/fasthttp.py,sha256=CcYgLLLJHH_NIE5cuk8dy3YE8ELLSmslhY96rBHzzWQ,26807
22
22
  locust/rpc/__init__.py,sha256=nVGoHWFQxZjnhCDWjbgXIbmFbN9sizAjkhvSs9_642c,58
23
23
  locust/rpc/protocol.py,sha256=oHR1yHdg_OysxZ2os3HS5Rf5hRi7I0d-3LIvWAn2QF0,1298
24
24
  locust/rpc/zmqrpc.py,sha256=7DLIXzkQr7992zmZwAqNgcqzm7LOQAOQtz0tUGv5-Gg,2637
@@ -55,7 +55,7 @@ locust/test/mock_logging.py,sha256=dvfXaY2eb0ZHx7Bjn7R69BarnRq9uu0z4HD8hCiRNmU,8
55
55
  locust/test/test_debugging.py,sha256=w5Lx6h101novinKjTJJDg5AqqY28U2Wg1W4hgCk6Sx8,1069
56
56
  locust/test/test_dispatch.py,sha256=SdnPFdyW0eRj7Bp4mAI8JRkmcwah6Z_b6oaZ_D98QPE,166009
57
57
  locust/test/test_env.py,sha256=jsX9tY_WShYefxro1lBemCSSzoKR6hnqLkbWgJ2z6WA,7489
58
- locust/test/test_fasthttp.py,sha256=3lpKiQ9DaOMdRvD1pTrwdL-IfGqr1-PrudJOibRxR-0,29887
58
+ locust/test/test_fasthttp.py,sha256=-UyGdz2Po1wOjcSHs2xPqBtMoJWMaaVrqbx6SaQNAac,30864
59
59
  locust/test/test_http.py,sha256=R23BWBNLjU3OOWCAgIAW8F9H5kqtBx43gPaXC-hhM2g,12570
60
60
  locust/test/test_interruptable_task.py,sha256=HqStHxtdZPT7WtytBiqTpKeNPg9upXzV7UI4QgFdUoU,1408
61
61
  locust/test/test_load_locustfile.py,sha256=v-muHoM-CYu8t7DXm4AQtFP2q8RYfnTTUBqj7uVqhig,8494
@@ -89,15 +89,15 @@ locust/util/exception_handler.py,sha256=jTMyBq2a0O07fRjmqGkheyaPj58tUgnbbcjoesKG
89
89
  locust/util/load_locustfile.py,sha256=hn70KcIG8jHmZyuKv2pcEmwgWtOEu24Efeji1KRYNUE,2964
90
90
  locust/util/rounding.py,sha256=5haxR8mKhATqag6WvPby-MSRRgIw5Ob6thbyvMYZM7o,92
91
91
  locust/util/timespan.py,sha256=rrMk4AR5t9HA59GktWCvOsYBDhkKAwLkk0Orj-l2EGY,997
92
- locust/webui/dist/auth.html,sha256=h9IM0pftOpXYo2v_5DS5T7y3qPC9R6CSc8tV1TfiVjY,501
93
- locust/webui/dist/index.html,sha256=RrPEvP5SQQKf-UQv92ugmgEtMwoX_bzd941lnDcNnI4,901
92
+ locust/webui/dist/auth.html,sha256=xDquX2awbYPO0FHo0SUTeylBjwbwUWpu2_blXKD0J5s,501
93
+ locust/webui/dist/index.html,sha256=7LG5sNTcH3Hu07hxAdlpSRTy5fCHq1tNekJo-ZfaWxI,901
94
94
  locust/webui/dist/report.html,sha256=sOdZZVgZbqgu86BBCSQf3uQUYXgmgSnXF32JpnyAII8,513
95
95
  locust/webui/dist/assets/favicon.ico,sha256=IUl-rYqfpHdV38e-s0bkmFIeLS-n3Ug0DQxk-h202hI,8348
96
- locust/webui/dist/assets/index-fd3e763b.js,sha256=n8qy95UxWB9i0OHsu3_mNxakF1gzablbwprGmvkoLoA,1645590
96
+ locust/webui/dist/assets/index-941b6e82.js,sha256=G3n5R81Svt0HzbWaV3AV20jLWGLr4X50UZ-Adu2KcxU,1645614
97
97
  locust/webui/dist/assets/logo.png,sha256=EIVPqr6wE_yqguHaqFHIsH0ZACLSrvNWyYO7PbyIj4w,19299
98
- locust-2.24.1.dev21.dist-info/LICENSE,sha256=78XGpIn3fHVBfaxlPNUfjVufSN7QsdhpJMRJHv2AFpo,1095
99
- locust-2.24.1.dev21.dist-info/METADATA,sha256=EUWEGentT36XK1TA7mkFTCk2xI2ou5ECb1wzJwQ8UMI,7212
100
- locust-2.24.1.dev21.dist-info/WHEEL,sha256=GJ7t_kWBFywbagK5eo9IoUwLW6oyOeTKmQ-9iHFVNxQ,92
101
- locust-2.24.1.dev21.dist-info/entry_points.txt,sha256=RAdt8Ku-56m7bFjmdj-MBhbF6h4NX7tVODR9QNnOg0E,44
102
- locust-2.24.1.dev21.dist-info/top_level.txt,sha256=XSsjgPA8Ggf9TqKVbkwSqZFuPlZ085X13M9orDycE20,7
103
- locust-2.24.1.dev21.dist-info/RECORD,,
98
+ locust-2.24.2.dev3.dist-info/LICENSE,sha256=78XGpIn3fHVBfaxlPNUfjVufSN7QsdhpJMRJHv2AFpo,1095
99
+ locust-2.24.2.dev3.dist-info/METADATA,sha256=13iXXPXRHYeP2rrBEgWZmrQCzWoKE3O3cyU90RuK41Q,7211
100
+ locust-2.24.2.dev3.dist-info/WHEEL,sha256=GJ7t_kWBFywbagK5eo9IoUwLW6oyOeTKmQ-9iHFVNxQ,92
101
+ locust-2.24.2.dev3.dist-info/entry_points.txt,sha256=RAdt8Ku-56m7bFjmdj-MBhbF6h4NX7tVODR9QNnOg0E,44
102
+ locust-2.24.2.dev3.dist-info/top_level.txt,sha256=XSsjgPA8Ggf9TqKVbkwSqZFuPlZ085X13M9orDycE20,7
103
+ locust-2.24.2.dev3.dist-info/RECORD,,