"Error: Request contains an invalid argument" on push and deploy
See original GitHub issueExpected Behavior
Push code to script project
Actual Behavior
Request fails on clasp push
and on clasp redeploy
. Redeploy has a more verbose error report:
at new RequestError (/usr/lib/node_modules/@google/clasp/node_modules/google-auth-library/lib/transporters.js:34:42)
at Request._callback (/usr/lib/node_modules/@google/clasp/node_modules/google-auth-library/lib/transporters.js:96:27)
at Request.self.callback (/usr/lib/node_modules/@google/clasp/node_modules/request/request.js:186:22)
at Request.emit (events.js:159:13)
at Request.<anonymous> (/usr/lib/node_modules/@google/clasp/node_modules/request/request.js:1163:10)
at Request.emit (events.js:159:13)
at IncomingMessage.<anonymous> (/usr/lib/node_modules/@google/clasp/node_modules/request/request.js:1085:12)
at Object.onceWrapper (events.js:254:19)
at IncomingMessage.emit (events.js:164:20)
at endReadableNT (_stream_readable.js:1062:12)
code: 400,
errors:
[ { message: 'Request contains an invalid argument.',
domain: 'global',
reason: 'badRequest' } ] }
The auth library fails, so i tried logging back in and out and into another account to no avail
Steps to Reproduce the Problem
- My current project directory looks like:
├── appsscript.json
├── build
├── node_modules
├── package.json
├── package-lock.json
├── README.md
└── src
With src and build as directories. The main apps script in my project is called build/Main.gs
and should be pushed from the build directory.
2. My build system is currently just using babel to transpile syntax and perform a simple bundle of the src
directory.
Besides that, I don’t know what’s out of the ordinary with my project. My Google account is personal, not organizational, so the auth issues don’t come from that…
Specifications
- Node version (
node -v
): v9.3.0 - Version (
npm list | grep clasp
): @google/clasp@1.0.7 - OS (Mac/Linux/Windows): Windows 10, WSL running Ubuntu 16.04
Issue Analytics
- State:
- Created 6 years ago
- Comments:17 (13 by maintainers)
Top Results From Across the Web
Google Cloud Error: ERROR: INVALID_ARGUMENT: Request ...
I get this: ERROR: (gcloud.projects.add-iam-policy-binding) INVALID_ARGUMENT: Request contains an invalid argument. Can anybody ...
Read more >Supplemental Nest terms request contains an invalid argument
Hello, I'm trying to add a Nest doorbell (battery). But when I accept the "Supplemental Nest terms" I get the error: "request contains....
Read more >"Request contains an invalid argument" - how to see what ...
I am using mutateCampaignCriteria to try to remove some IPs from a campaign's IP Exclusions List. This code in general works fine (it...
Read more >google cloud container registry error: "Failed to trigger build ...
... question google cloud container registry error: "Failed to trigger build: Request contains an invalid argument. ... When I push , it builds...
Read more >code=invalid_argument | The AI Search Engine You Control
this error type "Error: invalid BigNumber value(value=undefined)" indicates that you are passing "undefined", a wrong argument. And the error stack ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Per https://github.com/google/clasp/issues/21#issuecomment-394829151, I created a basic
appsscript.json
JSON validator in https://github.com/google/clasp/commit/80f3f7c1acae4171c00af4ec97356bf0d5ff4abf.It looks like this:
It only detects JSON errors like a trailing comma.
If anyone else looks through this thread for the mysterious “Error: Request contains an invalid argument” , the issue that caused me recently to get this same error was that I did not have my .git file entered in the .claspignore file. If you have a .git file in that directory, you’ll want to place it in your .claspignore file.