-
Notifications
You must be signed in to change notification settings - Fork 764
Closed
Milestone
Description
With swagger-client@3.6.0 if a transport-level HTTP error occurs (e.g. host/port unreachable) it causes an internal error in swagger-client which suppresses the original HTTP error. The problem can be demonstrated with the following command:
node -e "require('swagger-client').http({url: 'http://localhost:1/'}).catch(console.error)"
With swagger-client@3.6.0 this will print TypeError: Cannot read property 'statusText' of undefined along with a stack trace. This is far less useful than the error produced by swagger-client@3.5.2, FetchError: request to http://localhost:1/ failed, reason: connect ECONNREFUSED 127.0.0.1:1.
I bisected the regression to commit 1e9f8f0 from #1261.
Thanks,
Kevin
Metadata
Metadata
Assignees
Labels
No labels