andykingking / axios-debug Goto Github PK
View Code? Open in Web Editor NEWView debug output when using axios.
View debug output when using axios.
I used axios-debug in an integration test and got this:
Request:
{
"url": "http://localhost:8080/api/user/login/",
"method": "post",
"data": {
"email": "[email protected]",
"password": "***"
},
"headers": {
"common": {
"Accept": "application/json, text/plain, */*"
},
"delete": {},
"get": {},
"head": {},
"post": {
"Content-Type": "application/x-www-form-urlencoded"
},
"put": {
"Content-Type": "application/x-www-form-urlencoded"
},
"patch": {
"Content-Type": "application/x-www-form-urlencoded"
}
},
"transformRequest": [
null
],
"transformResponse": [
null
],
"timeout": 0,
"xsrfCookieName": "XSRF-TOKEN",
"xsrfHeaderName": "X-XSRF-TOKEN",
"maxContentLength": -1
}
Response:
1) "before all" hook in "{root}"
0 passing (374ms)
1 failing
1) "before all" hook in "{root}":
TypeError: Converting circular structure to JSON
--> starting at object with constructor 'ClientRequest'
| property 'socket' -> object with constructor 'Socket'
--- property '_httpMessage' closes the circle
at JSON.stringify (<anonymous>)
at Object.debug (node_modules/axios-debug/lib/index.js:4:67)
at /path/to/project/e2e-test/node_modules/axios-debug/lib/index.js:31:9
at processTicksAndRejections (internal/process/task_queues.js:97:5)
It seems like axios-debug does not expect circular JSON at certain points. Let me know if you are interested in more information:
axios: 0.19.2
axios-debug: 0.0.4
node: 13.7.0
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.