A fun owl-themed package!
Project description
barn-owl
A fun owl-themed package!
PyPI page: https://pypi.org/project/barn-owl/
Installation
Install the barn_owl module with pip:
pip install barn-owl
Usage
A full runnable demo that calls every public function is in examples/demo.py. From the repo root after pip install barn-owl or pipenv install --dev:
python examples/demo.py
Owl wisdom
owl_wisdom(topic="life") -> str returns a random owl-themed quip for a given theme. Pass topic as one of "life" (default), "coding", "friendship", "nature", or "food". Any other value raises ValueError with a hint listing valid topics.
from barn_owl import owl_wisdom
print(owl_wisdom())
print(owl_wisdom(topic="coding"))
Owl Latin
to_owl_latin(text) -> str
returns a string containing the translation of the input into owl latin; that is, appends 'hoo' to words starting with a non-consonant, otherwise, moves leading consonants to the end and appends 'oo'. In both cases, the translation keeps all leading and trailing punctuation as-is.
from barn_owl import to_owl_latin
print(to_owl_latin("hello world"))
# Prints "ellohoo orldwoo"
Owl Drawing
owl_drawing(style) -> str returns a string representation of an ASCII emoji illustration of an owl based on the chosen style. Choose a style from either "wise", "cute", "spooky", "funny", "large", "duo", or "emoji". Any invalid parameters will raise a ValueError.
from barn_owl import owl_drawing
print(owl_drawing("cute"))
# prints a cute owl drawing from the database
Owl Jokes
owl_jokes(category="python") -> str returns a random owl-themed joke from the specified category. Choose a category from "python" (default), "programming", or "cold". Any other value raises ValueError with a hint listing valid categories.
from barn_owl import owl_jokes
print(owl_jokes()) # defaults to "python"
print(owl_jokes(category="programming"))
# prints a programming-related owl joke
Owl Name Generator
owl_name_generator(style="wise") -> str returns a randomly generated owl name for the given style. Choose from "wise" (default), "spooky", "cute", or "funny". Any other value raises ValueError with a hint listing valid styles.
from barn_owl import owl_name_generator
print(owl_name_generator()) # defaults to "wise"
print(owl_name_generator(style="spooky"))
# prints a spooky owl name
Contributing
Prerequisites
- Python 3.11+
- pipenv
Set up the development environment
git clone https://github.com/swe-students-spring2026/3-package-barn_owl.git
cd 3-package-barn_owl
pipenv install --dev
This installs all dependencies and the package itself in editable mode.
Run tests
python -m pytest
Build the package
python -m build
Publish to PyPI (maintainers only)
twine upload -r testpypi dist/*
Developer workflow
- Create a feature branch off
main. - Make your changes and add tests.
- Open a pull request to
mainand ask a teammate to review. - After approval and passing CI, merge and delete the feature branch.
Team
Project details
Release history Release notifications | RSS feed
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 barn_owl-0.0.1.tar.gz.
File metadata
- Download URL: barn_owl-0.0.1.tar.gz
- Upload date:
- Size: 56.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.14.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
d4720d7693f324ec95935086d82428f4c8b2b3723bd6e492f9c1755b94e87c30
|
|
| MD5 |
a2562bbf9cccf1f4e1fad17abb1c2b5a
|
|
| BLAKE2b-256 |
c299dda874864b40540616bc0a2ef5259712327ffe46dd3f11a20c9044aad10b
|
File details
Details for the file barn_owl-0.0.1-py3-none-any.whl.
File metadata
- Download URL: barn_owl-0.0.1-py3-none-any.whl
- Upload date:
- Size: 41.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.14.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
c58fb9e1bbdc1d9ae4477c99d6a049a88a34c0d1bbb171e348fc859c79fbc4ca
|
|
| MD5 |
0048d053a258831dedd127b10688a6c4
|
|
| BLAKE2b-256 |
5ead9d5e9c3d822a3cdd1c3ff502405522e6011ae2b33f20ad0f7b66ce67fe82
|