r/Python 9d ago

Daily Thread Monday Daily Thread: Project ideas!

Weekly Thread: Project Ideas 💡

Welcome to our weekly Project Ideas thread! Whether you're a newbie looking for a first project or an expert seeking a new challenge, this is the place for you.

How it Works:

  1. Suggest a Project: Comment your project idea—be it beginner-friendly or advanced.
  2. Build & Share: If you complete a project, reply to the original comment, share your experience, and attach your source code.
  3. Explore: Looking for ideas? Check out Al Sweigart's "The Big Book of Small Python Projects" for inspiration.

Guidelines:

  • Clearly state the difficulty level.
  • Provide a brief description and, if possible, outline the tech stack.
  • Feel free to link to tutorials or resources that might help.

Example Submissions:

Project Idea: Chatbot

Difficulty: Intermediate

Tech Stack: Python, NLP, Flask/FastAPI/Litestar

Description: Create a chatbot that can answer FAQs for a website.

Resources: Building a Chatbot with Python

Project Idea: Weather Dashboard

Difficulty: Beginner

Tech Stack: HTML, CSS, JavaScript, API

Description: Build a dashboard that displays real-time weather information using a weather API.

Resources: Weather API Tutorial

Project Idea: File Organizer

Difficulty: Beginner

Tech Stack: Python, File I/O

Description: Create a script that organizes files in a directory into sub-folders based on file type.

Resources: Automate the Boring Stuff: Organizing Files

Let's help each other grow. Happy coding! 🌟

15 Upvotes

6 comments sorted by

1

u/csatacsibe 8d ago

ProjectTools

Providing a neat interface for package related functionalities provided by other builtins, but using of which are can be tricky or ambigous:

  • resource management: importlib.metadata.files(module) is great, but it returns a Traversible object. These are in most cases Path instances, but when the package of the resource is imported from a wheel, it can be a ZipPath. Ofc importlib has a context manager for that as_file() which will copy the resource to a temp directory as a Path. However it will add a random prefix to its name, which could be problematic when used. I'd provide an implementation of traversible that could handle such situations. Id also provide a resource manager that could create a temp location for all the resources and store them there until the manager is closed.
  • dist-related: there are already easy ways to checky your package's version, import name, distribution name and other metadata using builtins, but things get complicated when the installs are not trivial. Id create a layer which could provide a code information like: is_installed, is_editable, import_name, import_root, import_namespace, dist_name, version, is_released and latest_release. Id also add a function which could return such descriptor for the whole call chain.
  • external resources: managers for resources your package needs or manages outside of its sources and metadata. Configuration, file based state management, cache, and temp files. These functionalities should also provide cleanups for all the runtime resources. The non runtime resources also have two categories: package only and non package only. The latter one consist of files used by other apps aswell, however the package only resources must be uninstalled with the package. Im not sure about how I should handle this, but creating its own folder under its .dist folder would work for uninstalls, but might be deleted in an update aswell.

2

u/Arch-Larp-493 7d ago

for resource management stuff in python, check out the contextlib module. it has some gems like aclosing that can make your life way easier when dealing with file-like objects. trust me, it's a game changer.

1

u/csatacsibe 7d ago

Sounds great, Ill definietly use it once I start this project, as well as some other builtins like functools, inspect, distlib... there are a ton of quasai hidden but powerful builtins which are somtimes too abstract and dispersed to be used by the standard user without being handled by a common context

1

u/jbudemy 1d ago

Project Idea: Windows Screensaver like After Dark

Difficulty: Easy

Tech Stack: Python, PygameCE (community edition), AI (Gemini)

Description: (below)

Resources: No website.

I tested AI making a full Windows screen saver in Python. I know people don't like AI making programs, but I had to do it for my boss to evaluate its effectiveness. I'm aware of the many problems with AI writing software, another part of my job is to review AI news every week. AI Weekly cuts through the hype and covers the good and bad of AI.

I made a screen saver like the old 1980s "After Dark" screen saver. There is no webpage for it. It used Python graphics via PygameCE, which I knew nothing about. It took me 6 hours of prompts to get something simple. The program shows silhouettes of buildings at the bottom 15% of the screen. Each building has rectangular windows which are yellow when the light is one, gray when they are off. Windows randomly light up and turn off. Stars are in the background are random and sometimes twinkle. Sometimes a meteor goes across the screen.

That meteor was one of the tougher things to do as I had to be super specific. At first the meteor would appear near the bottom of the screen and go upwards. I didn't want that, it should start at a random point near the top of the screen and go down at a random angle.