Dmitriy
09/09/2019, 4:46 PMValueError('Could not deserialize key data.')
when trying to create a BQ table with CreateBigQueryTable
task? I've got my credentials in a GOOGLE_APPLICATION_CREDENTIALS
environment variable as a JSON string and my ~/.prefect/config.toml
as:
[cloud]
use_local_secrets = true
[context.secrets]
GOOGLE_APPLICATION_CREDENTIALS = "$GOOGLE_APPLICATION_CREDENTIALS"
I'm not passing anything for credentials
to the task itself (since it already defaults to GOOGLE_APPLICATION_CREDENTIALS
). I'm using Python 3.7.4 and prefect==0.6.1
. Below is the exact output.
[2019-09-09 16:42:23,995] INFO - prefect.TaskRunner | Task 'Create Table': Starting task run...
[2019-09-09 16:42:23,996] INFO - prefect.TaskRunner | Unexpected error: ValueError('Could not deserialize key data.')
[2019-09-09 16:42:23,996] INFO - prefect.TaskRunner | Task 'Create Table': finished task run for task with final state: 'Failed'
If anyone has any suggestions it's much appreciated.Chris White
\\n
newline values in the JSON blobjson.dumps(my_credentials_dictionary)
and paste that exact value in for my secret, and it usually solves itDmitriy
09/09/2019, 5:41 PMjson.dumps()
adds escapes and is what appears to be creating the \\n
in the blob. What I did was pasted the blob into a text file, replaced \\n
with \n
and pasted that value into my secret and it worked! Thank you for the quick response.Chris White
Marvin
09/09/2019, 5:44 PMChris White