Skip to content

fix metros URL with correct prefix path#123

Merged
matoszz merged 1 commit intomasterfrom
fix-metros-path
Sep 20, 2021
Merged

fix metros URL with correct prefix path#123
matoszz merged 1 commit intomasterfrom
fix-metros-path

Conversation

@displague
Copy link
Member

Fixes #122

Signed-off-by: Marques Johansson mjohansson@equinix.com

@displague
Copy link
Member Author

Before:

$ python3
Python 3.9.6 (default, Jun 29 2021, 05:25:02)
[Clang 12.0.5 (clang-1205.0.22.9)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> import packet
>>> c = packet.Manager(auth_token="secret")
>>> c.list_metros()
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/Users/marques/src/packet-python/packet/Manager.py", line 46, in list_metros
    data = self.call_api("metros", params=params)
  File "/Users/marques/src/packet-python/packet/Manager.py", line 32, in call_api
    return super(Manager, self).call_api(method, type, params)
  File "/Users/marques/src/packet-python/packet/baseapi.py", line 116, in call_api
    raise ResponseError(resp, data)
packet.baseapi.ResponseError: Error 404: Not found
>>>

After:

...
>>> c.list_metros()[0].code
'dc'

Signed-off-by: Marques Johansson <mjohansson@equinix.com>
@displague
Copy link
Member Author

I'm not sure how we can disable the Drone builds. Any thoughts, @mmlb?

@matoszz matoszz merged commit 9029c01 into master Sep 20, 2021
@matoszz matoszz deleted the fix-metros-path branch September 20, 2021 21:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Metro endpoint is 404

3 participants