Post data & return word stats #140
Annotations
2 errors and 1 warning
Run Vitest:
wordle-web/scripts/game.ts#L123
AxiosError: Network Error
❯ XMLHttpRequest.handleError [as onerror] node_modules/axios/lib/adapters/xhr.js:162:14
❯ XMLHttpRequest.dispatchEvent node_modules/happy-dom/src/event/EventTarget.ts:176:24
❯ XMLHttpRequest.dispatchEvent node_modules/happy-dom/src/event/EventTarget.ts:132:9
❯ onError node_modules/happy-dom/src/xml-http-request/XMLHttpRequest.ts:368:10
❯ XMLHttpRequest._XMLHttpRequest_sendAsync node_modules/happy-dom/src/xml-http-request/XMLHttpRequest.ts:385:4
❯ Axios.request node_modules/axios/lib/core/Axios.js:45:41
❯ Game.submitGuess scripts/game.ts:123:20
⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯
Serialized Error: { code: 'ERR_NETWORK', config: { transitional: { silentJSONParsing: true, forcedJSONParsing: true, clarifyTimeoutError: false }, adapter: [ 'xhr', 'http' ], transformRequest: [ 'Function<transformRequest>' ], transformResponse: [ 'Function<transformResponse>' ], timeout: +0, xsrfCookieName: 'XSRF-TOKEN', xsrfHeaderName: 'X-XSRF-TOKEN', maxContentLength: -1, maxBodyLength: -1, env: { FormData: 'Function<FormData>', Blob: 'Function<Blob>' }, validateStatus: 'Function<validateStatus>', headers: { Accept: 'application/json, text/plain, */*', 'Content-Type': 'application/json', constructor: 'Function<AxiosHeaders>', set: 'Function<set>', get: 'Function<get>', has: 'Function<has>', delete: 'Function<delete>', clear: 'Function<clear>', normalize: 'Function<normalize>', concat: 'Function<concat>', toJSON: 'Function<toJSON>', toString: 'Function<toString>', getContentType: 'Function<value>', setContentType: 'Function<value>', hasContentType: 'Function<value>', getContentLength: 'Function<value>', setContentLength: 'Function<value>', hasContentLength: 'Function<value>', getAccept: 'Function<value>', setAccept: 'Function<value>', hasAccept: 'Function<value>', getAcceptEncoding: 'Function<value>', setAcceptEncoding: 'Function<value>', hasAcceptEncoding: 'Function<value>', getUserAgent: 'Function<value>', setUserAgent: 'Function<value>', hasUserAgent: 'Function<value>', getAuthorization: 'Function<value>', setAuthorization: 'Function<value>', hasAuthorization: 'Function<value>' }, baseURL: 'https://localhost:7266/', method: 'post', url: 'game/result', data: '{"attempts":2,"isWin":true,"word":"AUTOS"}' }, request: { onloadstart: null, onprogress: null, onabort: 'Function<handleAbort>', onerror: 'Function<handleError>', onload: null, ontimeout: 'Function<handleTimeout>', onloadend: 'Function<onloadend>', upload: { onloadstart: null, onprogress: null, onabort: null, onerror: null, onload: null, ontimeout: null, onloadend: null, constructor: 'Function<XMLHttpRequestUpload>', addEventListener: 'Function<addEventListener>', removeEventListener: 'Function<removeEventListener>', dispatchEvent: 'Function<dispatchEvent>', attachEvent: 'Function<attachEvent>', detachEvent: 'Function<detachEvent>' }, withCredentials: false, timeout: +0, constructor: 'Function<XMLHttpRequest>', status: +0, statusText: '', response: '', responseText: '', responseXML: null, responseURL: '', readyState: 4, responseType: '', open: 'Function<open>', setRequestHeader: 'Function<setRequestHeader>', getResponseHeader: 'Function<getResponseHeader>', getAllResponseHeaders: 'Function<getAllResponseHeaders>', send: 'Function<send>', abort: 'Function<abort>', addEventListener: 'Function<addEventListener>', removeEventListener: 'Function<removeEventListener>', dispatchEvent: 'Function<dispatchEvent>', attachEvent: 'Function<attachEvent>', detachEvent: 'Function<detachEvent>' }, toJSON: 'Function<toJSON>', isAxiosError: true }
This error originated in "tests/game.test.ts" test file. It doesn't mean the error was thrown inside the file itself, but while it was running.
|
Run Vitest
Process completed with exit code 1.
|
Node.js 16 actions are deprecated. Please update the following actions to use Node.js 20: actions/checkout@v3. For more information see: https://github.blog/changelog/2023-09-22-github-actions-transitioning-from-node-16-to-node-20/.
|
Loading