apigee / apigee/apigeetool-node
API errors not reported?
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 91
- Forks
- 91
- PR merge metrics
- No merged PRs in 30d
Description
@theganyo or who else this concerns
It looks like the -V or --debug -D flags don't return errors from the API itself. Here's what I'm getting back:
Please report a bug if this causes problems.
Error: Error: Error uploading policy: 400
Error: Error uploading policy: 400
at Request._callback (/usr/local/lib/node_modules/apigeetool/lib/commands/deployproxy.js:376:18)
at Request.self.callback (/usr/local/lib/node_modules/apigeetool/node_modules/request/request.js:123:22)
at emitTwo (events.js:87:13)
at Request.emit (events.js:172:7)
at Request.<anonymous> (/usr/local/lib/node_modules/apigeetool/node_modules/request/request.js:1047:14)
at emitOne (events.js:82:20)
at Request.emit (events.js:169:7)
at IncomingMessage.<anonymous> (/usr/local/lib/node_modules/apigeetool/node_modules/request/request.js:998:12)
at emitNone (events.js:72:20)
at IncomingMessage.emit (events.js:166:7)
Is there an option I'm missing here? At first glance, the error messages don't seem to be printed out the console:
Though I haven't done a deep-dive into the code yet. Let me know how I can help. Thanks!
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start in lib/commands/deployproxy.js around lines 369-377 and reproduce the API failure using the -V or --debug -D flags. Trace how the API response is handled during policy upload and verify that the API's error details are reported in the console rather than only the status code and stack trace.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript
- Domain
- api, cli
- Issue type
- Bug
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100