A lighthearted Python package for exploring and discovering movies from the IMDB Top 250 list with fun utilities for movie selection and analysis.
Project description
Arctic Fox Movies
Arctic Fox Movies is a lighthearted Python package for exploring the IMDB Top 250 dataset and discovering what to watch next.
It includes tools to:
- pick a movie based on your constraints,
- generate a movie quiz from random clues,
- search by lead actor,
- find collaboration movies between two people,
- list movies by a director, and
- spin a random pick by genre.
Dataset source: IMDB Top 250 Movies (Kaggle)
PyPI
- Package page: https://pypi.org/project/arctic-fox-movies/
- Install command:
pip install arctic-fox-movies
Example Program
A complete example that uses all package features is available in:
Run it locally:
pipenv run python examples/example_program.py
Run with interactive quiz enabled:
pipenv run python examples/example_program.py --play-quiz
Run with dataframe preview enabled:
pipenv run python examples/example_program.py --show-dataframe-shape
Function Reference
Import path:
from arcticfoxmovies.movies import (
movie_night_picker,
quiz,
play_quiz,
lead_actor,
find_collabs,
find_movie_by_director,
genre_roulette,
find_shape_of_dataframe,
)
movie_night_picker(genres_to_avoid=None, runtime_max=150, minimum_rating=8.0)
Returns either a movie dictionary or the fallback string "No movies match your criteria!".
movie = movie_night_picker(
genres_to_avoid=["Horror", "War"],
runtime_max=180,
minimum_rating=8.3,
)
print(movie)
quiz(attributes)
Builds a quiz question and returns quiz metadata.
Allowed values in attributes are "director", "runtime", and "year".
q = quiz(["director", "year"])
print(q["question"])
print("Answer:", q["answer"])
play_quiz(attributes)
Interactive wrapper around quiz(...).
play_quiz(["director", "runtime", "year"])
lead_actor(actor)
Returns movies where actor appears as the first listed cast member.
tom_hanks_movies = lead_actor("Tom Hanks")
print(tom_hanks_movies[:5])
find_collabs(person1, person2)
Returns movies where both people appear among directors, writers, or cast.
shared = find_collabs("Morgan Freeman", "Tim Robbins")
print(shared)
find_movie_by_director(director)
Returns all dataset movies directed by director.
nolan_movies = find_movie_by_director("Christopher Nolan")
print(nolan_movies)
genre_roulette(genre, avoid_year=None)
Returns one random movie title for genre, optionally skipping one year.
pick = genre_roulette("Drama", avoid_year=1994)
print(pick)
find_shape_of_dataframe(path=None)
Debug helper that prints a head/tail preview of the movie dataframe.
find_shape_of_dataframe()
CLI Usage
The package also exposes a CLI entry point.
python -m arcticfoxmovies --help
python -m arcticfoxmovies lead_actor "Tom Hanks"
python -m arcticfoxmovies quiz director runtime year
If installed from PyPI, you can also use the script command:
arcticfoxmovies --help
Developer Setup (Any Platform)
1. Prerequisites
- Python 3.9+ (CI currently validates 3.9, 3.10, 3.11)
pippipenv
Install pipenv if needed:
python -m pip install --user pipenv
2. Clone and install dependencies
git clone https://github.com/swe-students-spring2026/3-package-arctic_fox.git
cd 3-package-arctic_fox
pipenv install --dev
pipenv run pip install -e .
3. Run tests
pipenv run pytest
4. Build package artifacts
pipenv run python -m build
Artifacts are produced in dist/.
5. Validate artifacts and upload to PyPI
pipenv run twine check dist/*
pipenv run twine upload dist/*
Continuous Integration
GitHub Actions workflow: python-package.yml
On every push and PR to main, the workflow:
- sets up a matrix for Python 3.9, 3.10, and 3.11,
- installs dependencies with
pipenv, - runs lint checks with
flake8, - runs unit tests with
pytest.
Team Workflow
Use feature branches and pull requests for all changes:
- Create a feature branch from
main. - Open a PR into
main. - Request teammate review.
- Reviewer runs tests and validates behavior.
- Merge once approved.
- Delete the feature branch.
- Pull latest
mainlocally.
Configuration and Data
- No local
.envfile is required to run this package. - The dataset ships in the repository at
data/IMDB Top 250 Movies.csv. - No database setup or seed/import step is required.
Optional CI secret:
COMMIT_LOG_APIis used only by.github/workflows/event-logger.yml.- If that workflow is enabled in your fork, configure this GitHub Actions secret in your repository settings.
Teammates
License
Licensed under the MIT License. See LICENSE.
Course Exercise
This repository is part of the package engineering exercise documented in instructions.md.
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
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file arctic_fox_movies-0.1.1.tar.gz.
File metadata
- Download URL: arctic_fox_movies-0.1.1.tar.gz
- Upload date:
- Size: 8.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
4201e7e579e85fd1b6d7f842b91e652de9cb48dc3b9a5d9b7adbe8b2a6d009f3
|
|
| MD5 |
8d78e3af4a6574367c8f6bc2d725283f
|
|
| BLAKE2b-256 |
74479804ca766fd0bbae902745e43af6e140812ac95a22384e898e26c07d84c2
|
Provenance
The following attestation bundles were made for arctic_fox_movies-0.1.1.tar.gz:
Publisher:
python-package.yml on swe-students-spring2026/3-package-arctic_fox
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
arctic_fox_movies-0.1.1.tar.gz -
Subject digest:
4201e7e579e85fd1b6d7f842b91e652de9cb48dc3b9a5d9b7adbe8b2a6d009f3 - Sigstore transparency entry: 1201795868
- Sigstore integration time:
-
Permalink:
swe-students-spring2026/3-package-arctic_fox@a0fd34f945fb80f0fe06dc9be471a27fca945cbc -
Branch / Tag:
refs/heads/main - Owner: https://github.com/swe-students-spring2026
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
python-package.yml@a0fd34f945fb80f0fe06dc9be471a27fca945cbc -
Trigger Event:
push
-
Statement type:
File details
Details for the file arctic_fox_movies-0.1.1-py3-none-any.whl.
File metadata
- Download URL: arctic_fox_movies-0.1.1-py3-none-any.whl
- Upload date:
- Size: 8.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
5008d12acd5e5cf7f2e4ae82311a47981252860cc6a5994bbfc5238d877d17d9
|
|
| MD5 |
feba92cff7fab45431dfe49180a66172
|
|
| BLAKE2b-256 |
811c23d436f0ca0afeebef9605c9912186f6b49a75b8d82f898b30fc83ac26a1
|
Provenance
The following attestation bundles were made for arctic_fox_movies-0.1.1-py3-none-any.whl:
Publisher:
python-package.yml on swe-students-spring2026/3-package-arctic_fox
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
arctic_fox_movies-0.1.1-py3-none-any.whl -
Subject digest:
5008d12acd5e5cf7f2e4ae82311a47981252860cc6a5994bbfc5238d877d17d9 - Sigstore transparency entry: 1201795871
- Sigstore integration time:
-
Permalink:
swe-students-spring2026/3-package-arctic_fox@a0fd34f945fb80f0fe06dc9be471a27fca945cbc -
Branch / Tag:
refs/heads/main - Owner: https://github.com/swe-students-spring2026
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
python-package.yml@a0fd34f945fb80f0fe06dc9be471a27fca945cbc -
Trigger Event:
push
-
Statement type: