Skip to main content

A fun NYC weekend plan recommender for developers

Project description

pynyc

CI/CD

Description

A python package that returns fun NYC plans and recommendations!

Github

Github Link

Developers

Albert Chen Blake Chang Valeria Chang Vincent Campanaro Sasha Cartagena


Installing the Package

Install pynyc directly from PyPI:

pip install pynyc

Then import it in your Python code:

import pynyc

find_restaurant(cuisine, michelin=False)

Returns a restaurant name in New York City for a given cuisine type.

Parameter Type Required Description
cuisine str Yes The type of food you want (e.g. "italian", "japanese")
michelin bool No Set to True to get a Michelin-listed restaurant. Default is False

Example usage

import pynyc

# Generate any Italian restaurant
restaurant = pynyc.find_restaurant("italian")
print(f"Go to {restaurant}")

# Help you to pick a Michelin-listed Japanese restaurant
restaurant = pynyc.find_restaurant("japanese", michelin=True)
print(f"Go to {restaurant}")

Input is case-insensitive for better efficiency— "ITALIAN", "Italian", and "italian" all work the same.

find_activity(weather)

Returns an activity recommendation in NYC based on the weather.

Parameter Type Required Description
weather str Yes The weather outside (e.g. "hot", "freezing", "perfect", "rainy")

Input is case-insensitive - "sunny", "Sunny", and "SUNNY" all work the same.

See the full working example in example.py.

Example usage

import pynyc

#Prints an actvity suitable for sunny weather
activity = pynyc.find_activity("sunny")
print(activity)

find_nightlife_activity(vibe)

Returns one nightlife recommendation in New York City for a given vibe.

Parameter Type Required Description
vibe str Yes The nightlife vibe you want (e.g. "dancing", "singing", "laughing", "music and vibes")

Example usage

import pynyc

# Get one random dancing recommendation
activity = pynyc.find_nightlife_activity("dancing")
print(f"Go to {activity['name']} for {activity['activity_type']}")
print(f"Website: {activity['website']}")

# Aliases also work
activity = pynyc.find_nightlife_activity("karaoke")
print(activity)

# Invalid vibes raise a helpful error instead of crashing silently
try:
    pynyc.find_nightlife_activity("quiet reading")
except ValueError as error:
    print(error)

Input is case-insensitive - "DANCING", "Dancing", and "dancing" all work the same.

See the full working example in example.py.


list_nightlife_places(vibe)

Returns a list of nightlife places in New York City for a given vibe.

Parameter Type Required Description
vibe str Yes The nightlife vibe you want (e.g. "dancing", "singing", "laughing", "music and vibes")

Example usage

import pynyc

# Get all nightlife places for a dancing vibe
places = pynyc.list_nightlife_places("dancing")
for place in places:
    print(f"{place['name']}: {place['website']}")

# Aliases also work
places = pynyc.list_nightlife_places("club")
print(places[0])

# Invalid vibes raise a helpful error instead of crashing silently
try:
    pynyc.list_nightlife_places("quiet reading")
except ValueError as error:
    print(error)

Input is case-insensitive - "DANCING", "Dancing", and "dancing" all work the same.

See the full working example in example.py.



get_cafe(time)

Returns a recommended cafe in New York City based on the time of day.

Parameter Type Required Description
time str Yes Time of day ("morning", "afternoon", "evening")

Example usage

import pynyc

cafe = pynyc.get_cafe("morning")
print(f"You should check out {cafe}")

Input is case-insensitive - "MORNING", "Morning", and "morning" all work the same.

If the input is invalid, the function returns a helpful error message.

See the full working example in example.py.


find_excursion(category)

Returns one excursion recommendation in New York City for a given category.

Parameter Type Required Description
category str Yes The excursion category you want (e.g. "nature", "historic", "coastal")

Example usage

import pynyc

# Get one random nature excursion
excursion = pynyc.find_excursion("nature")
print(f"Go to {excursion['name']} in {excursion['location']}")
print(f"Website: {excursion['website']}")

# Aliases also work
excursion = pynyc.find_excursion("beach")
print(excursion)

# Invalid categories raise a helpful error instead of crashing silently
try:
    pynyc.find_excursion("underwater")
except ValueError as error:
    print(error)

Input is case-insensitive - "NATURE", "Nature", and "nature" all work the same.

See the full working example in example.py.


list_excursions(category)

Returns a list of excursion places in New York City for a given category.

Parameter Type Required Description
category str Yes The excursion category you want (e.g. "nature", "historic", "coastal")

Example usage

import pynyc

# Get all excursion places for a nature category
places = pynyc.list_excursions("nature")
for place in places:
    print(f"{place['name']}: {place['website']}")

# Aliases also work
places = pynyc.list_excursions("outdoors")
print(places[0])

# Invalid categories raise a helpful error instead of crashing silently
try:
    pynyc.list_excursions("underwater")
except ValueError as error:
    print(error)

Input is case-insensitive - "NATURE", "Nature", and "nature" all work the same.

See the full working example in example.py.


Setting Up for Development

Prerequisites

  • Python 3.10 or later
  • pipenv — install it with:
pip install pipenv

1. Clone the repository

git clone https://github.com/swe-students-spring2026/3-package-sea_otter.git
cd 3-package-sea_otter

2. Create the virtual environment and install dependencies

pipenv install --dev

3. Activate the virtual environment

pipenv shell

4. Run the tests

pipenv run python -m pytest

All tests should pass. If they don't, check that you are using Python 3.10 or later.

5. Build the package

pipenv run python -m build

Environment Variables

This package does not require any environment variables or external database setup. All data is bundled with the package in the pynyc/data/ directory.

No .env file is needed.


Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pynyc-0.1.1.tar.gz (57.8 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

pynyc-0.1.1-py3-none-any.whl (42.1 kB view details)

Uploaded Python 3

File details

Details for the file pynyc-0.1.1.tar.gz.

File metadata

  • Download URL: pynyc-0.1.1.tar.gz
  • Upload date:
  • Size: 57.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.15

File hashes

Hashes for pynyc-0.1.1.tar.gz
Algorithm Hash digest
SHA256 1a25c40b73da093e1e080c770aada4c593319df736d836e548615c29c5c50db1
MD5 bbe8b87dde7abc10cfcbe33c89de1ff4
BLAKE2b-256 f5b59168217c530c2c327fe84aae8fb8671664f243469a2ca7f39a397d2ac096

See more details on using hashes here.

File details

Details for the file pynyc-0.1.1-py3-none-any.whl.

File metadata

  • Download URL: pynyc-0.1.1-py3-none-any.whl
  • Upload date:
  • Size: 42.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.15

File hashes

Hashes for pynyc-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 07cb70c08f15df6d63c1181d73a888883bbaddbe0ea315a6ba37a826a319a4e9
MD5 dbaacc61a12e349907779c794ae11633
BLAKE2b-256 2791346424835a62b8745cf4f5c6cbed8f3fc525fa4766fcd80de925ea526b55

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page