style: improve cancellation string#111
Conversation
bigframes/formatting_helpers.py
Outdated
| query_job.cancel() | ||
| print(f"Requested cancelation for {query_job.job_type} {query_job.job_id}...") | ||
| print( | ||
| f"Requested cancellation for {query_job.job_type.capitalize()} job {query_job.job_id}..." |
There was a problem hiding this comment.
Nit: we should also include the job location. It's common for folks to give support this job ID but without the location it's not easy to look up where this job's logs are.
There was a problem hiding this comment.
It looks like https://cloud.google.com/python/docs/reference/bigquery/latest/google.cloud.bigquery.job.QueryJob#google_cloud_bigquery_job_QueryJob_location is not very specific (for example: "US"). Do you think that's sufficient? Thanks.
There was a problem hiding this comment.
Yes, that's correct. "US" means our US-multi-region. For other regions in the US, it'll be a string specific to that region, such as "us-central1"
There was a problem hiding this comment.
Nice, I hoped that was the case but the documentation was very minimal
"
location
str: Location where the job runs.
"
Ha.
Thanks.
Thank you for opening a Pull Request! Before submitting your PR, there are a few things you can do to make sure it goes smoothly:
Fixes #<issue_number_goes_here> 🦕