google-cloud-platformgoogle-cloud-datalab

Invalid arguments when creating new datalab instance


I am following the quickstart tutorial for datalab here, within the GCP console. When I try to run

datalab beta create-gpu datalab-instance-name

In step 3 I receive the following error

write() argument must be str, not bytes 

Can anyone help explain why this is the case and how to fix it?

Thanks


Solution

  • Referring to the official documentation, before running Datalab instance, the corresponding APIs should be enabled: Google Compute Engine and Cloud Source Repositories APIs. To do so, visit Products -> APIs and Services -> Library and search for the APIs. Additionally, make sure that billing is enabled for your Google Cloud project.

    You can also enabling the APIs by typing the following command, which will give you a prompt to enable the API:

    datalab list
    

    I made some research and found that the same issue has been reported on the Github page. If enabling API's wouldn't work, the best option would be to contribute (add a comment) in the mentioned Github topic to make it more visible to the Datalab Engineering team.