View Stackdriver logs
See original GitHub issueExpected Behavior
clasp logs
(DEBUG) {foo:42} – myFunction [2018-02-21T16:08:06.364Z]
clasp logs --json
[{
"jsonPayload": {foo:42},
...
}, {...}]
Views StackDriver logs (console.log
).
Actual Behavior
Command doesn’t exist yet.
Notes
Example Stackdriver API result
{
"insertId": "13oj0ajfyb6tdx",
"jsonPayload": {foo:42},
"labels": {…},
"logName": "projects/project-id-4088669541713651222/logs/script.googleapis.com%2Fconsole_logs",
"receiveTimestamp": "2018-02-21T16:08:07.370458993Z",
"resource": {
"labels": {
"function_name": "myFunction",
"invocation_type": "editor",
"project_id": "project-id-4088669541713651222",
},
"type": "app_script_function"
},
"severity": "DEBUG",
"timestamp": "2018-02-21T16:08:06.364Z",
}
Please 👍 if you’d like this feature.
Issue Analytics
- State:
- Created 6 years ago
- Reactions:4
- Comments:7 (3 by maintainers)
Top Results From Across the Web
Viewing Stackdriver logs - Migrate for Compute Engine
Sign in to your Manager · Click System Settings · Click the Logs tab · Copy the System ID (for example QWEX1234) on...
Read more >Stackdriver Logging and Monitoring Usage | by Tarun Manrai
Stackdriver Logging provides detailed list of logs, current log volume and projected monthly volume. This makes it easy to see which logs have...
Read more >Stackdriver logs | Google Maps Booking API
To view the log history, follow these steps: In the Google Cloud Platform Console, go to Stackdriver > Logging > Logs. Select your...
Read more >Google Cloud Logging - Stackdriver
Cloud Logging is a service for storing, viewing and interacting with logs. Answers the questions “Who did what, where and when” within the...
Read more >Cloud logging - YouTube
30K views 2 years ago Google Cloud Essentials ... to learn more about our products → https://goo.gle/GCP Product: Stackdriver Logging ; ...
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
Ok, I’ll assume for now that it’s already in the .clasp.json file, with instructions to the user to modify that file.
In the README instructions, we should mention that you can find your projectId by following these instructions: https://developers.google.com/apps-script/guides/cloud-platform-projects#accessing_an_apps_script_cloud_platform_project
However, it’s important to note that this is a hidden GCP project, and is only used for the Apps Script. If they want to connect it to another project they can follow the instructions a little lower on that page as well.
+1 to “Ideally, the API would give us the Cloud projectId for the Project”. Since it doesn’t for now, I think updating the README with how to find it and where to put it would be best.
Fixed with #101.