gis-ops / routingpy

🌎 Python library to access all public routing, isochrones and matrix APIs in a consistent manner.
https://routingpy.readthedocs.io/en/latest/?badge=latest
Apache License 2.0
252 stars 26 forks source link

Add kwargs to public methods #57

Closed nurikk closed 2 years ago

nurikk commented 2 years ago

add kwargs to public methods. so we wouldn't get errors when using object spreading ex: TypeError: matrix() got an unexpected keyword argument 'extra_param1'

https://github.com/gis-ops/routing-py/pull/55 https://github.com/gis-ops/routing-py/pull/49

nilsnolde commented 2 years ago

@nurikk actually this doesn't do anything as far as I can see.. you don't use the kwargs in the methods so they're accepted, yes, but the request won't use them right?

that's not really consistent with how the library works for other providers (ie the PRs you linked), so I'd ask to please implement using the kwargs as well. could you also copy/paste some test lines from those PRs?

TimMcCauley commented 2 years ago

True, they are not being used in the request itself. @nurikk I'm assuming these are some custom set parameters that are being used to keep a mapping of the request and response itself? Or what was your intention here?

TimMcCauley commented 2 years ago

Reverted the changes for now.

nurikk commented 2 years ago

Created a new PR https://github.com/gis-ops/routing-py/pull/59