
Security News
MCP Community Begins Work on Official MCP Metaregistry
The MCP community is launching an official registry to standardize AI tool discovery and let agents dynamically find and install MCP servers.
This is a Python library to use in conjunction with the Google Maps API (at least for now) in order to plan trips and much more! It tries to bring a less JSON-oriented way of using the API.
googlemaps
dependency.These instructions will get you a copy of the project up and running on your local machine for development and testing purposes.
You will need the following:
For a local installation, just clone this repository inside the parent directory of your project.
git clone https://github.com/diagmatrix/py-travel.git
git checkout main
Then install the dependencies of py-travel.
pip install -r requirements.txt
And there you have it! You can now use this library freely.
This project is available in PyPy, so you can install it using pip.
pip install py-travel
There are currently two ways of using the classes provided in the package: by using the built-in
Google Maps API clients or by using the googlemaps
client directly. The first method will initialize an API client for
each of the classes of py-travel that use them, while the second approach will give you more control on which ones
can access it.
from py_travel import init_clients
from py_travel.trip import Trip
init_clients(api_key="<API KEY>") # Initialize all API clients
my_trip = Trip(origin=(39.25, -4.47), destination="Aveiro, Portugal", config={'mode': 'walking'})
# Get the kms between the points
kms = my_trip.distance
googlemaps
directlyfrom py_travel.trip import Trip
import googlemaps
cli = googlemaps.Client(key="<API KEY>")
Trip.set_client(cli) # Initialize client for the trip class
my_trip = Trip(origin=(39.25, -4.47), destination="Aveiro, Portugal", config={'mode': 'walking'})
# Get the kms between the points
kms = my_trip.distance
In order to run the tests you will first need to install the python package pytest
. Then, place yourself in the parent
branch of the repository and run the following command:
pytest
For linting tests, this project uses the default ruff
configuration.
Work in progress
FAQs
Plan trips using the Google Maps API
We found that py-travel demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
The MCP community is launching an official registry to standardize AI tool discovery and let agents dynamically find and install MCP servers.
Research
Security News
Socket uncovers an npm Trojan stealing crypto wallets and BullX credentials via obfuscated code and Telegram exfiltration.
Research
Security News
Malicious npm packages posing as developer tools target macOS Cursor IDE users, stealing credentials and modifying files to gain persistent backdoor access.