Google Colab - Certs setup

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • conr
    Junior Member
    • Aug 2019
    • 2

    #1

    Google Colab - Certs setup

    Working with Google Colab and trying to connect to an external API.

    I have created a set of SSL certs and would like to deploy them, I have mounted my drive and referred the correct folder, but it is failing.
    import betfairlightweight
    from google.colab import drive
    from google.colab import files

    drive.mount('content')

    # Change this certs path to wherever you're storing your certificates
    certs_path = 'content/My Drive/betfair/'

    # Change these login details to your own
    my_username = XXXXX my_password = XXXXX my_app_key = XXXXX

    trading = betfairlightweight.APIClient(username=my_username, password=my_password, app_key=my_app_key ,certs=certs_path)

    The certs exist, however when I

    certs_path ='content/My Drive/betfair' !ls certs_path

    I get the error


    ls: cannot access 'certs_path': No such file or directory


    How do I point to the correct certs folder in my google drive using Colab?
  • LiamP
    Junior Member
    • Oct 2015
    • 284

    #2
    Sorry just seen this, difficult to work this out, can you try passing the full path of where your certs are?

    Comment

    Working...
    X