Skip to main content

CloudEnv deprecation

Answered

Comments

6 comments

  • Official comment
    Ronald van der Velden
    Gurobi Staff Gurobi Staff

    Hi Paul,

    The parameter names to use are slightly different than the parameters to the original `CloudEnv` function. The syntax looks like this:

    params = {
    'CloudAccessID': '...',
    'CloudSecretKey': '...',
    'CloudPool': '...'
    }
    e = gp.Env(params=params)

    Best regards,
    Ronald

  • Paul Costache
    Gurobi-versary
    First Comment
    First Question

    Thank you sooo much Ronald ! Have been digging in your manual and API reference for ages now !!

    0
  • Ronald van der Velden
    Gurobi Staff Gurobi Staff

    Sorry about that... the parameter names to be used as dictionary keys with this syntax are basically the official parameter names listed here. But I understand it can be confusing in the context of this deprecation message!

    0
  • Paul Costache
    Gurobi-versary
    First Comment
    First Question

    Additionally, are there any other changes to the API ? That's because a previously working model now spits 'the JSON object must be str, bytes or bytearray, not tuple'. Thank you !

    0
  • Ronald van der Velden
    Gurobi Staff Gurobi Staff

    Not sure... could you post a code snippet that illustrates the error?

    0
  • Paul Costache
    Gurobi-versary
    First Comment
    First Question

    It comes from a seemingly unrelated variable declaration. It's a bit weird because it worked a few days ago:

    list_materials=json.loads(list_materials)['data'].
    It probably is a mistake of mine so I will look further into each data structure !  Thanks !
    0

Please sign in to leave a comment.