r/Python • • Jun 20 '25

Showcase I just built the fastest Python-based SSG in the world

0 Upvotes

I wanted to share a project I’ve been working on over the last year: Stattic, a static site generator written in Python.

It started as a single script to convert Markdown into HTML, mainly because I wanted something fast, SEO-friendly, and simple enough to understand in one sitting.

And today, I released v1.0, which is a big leap.

What My Project Does

Stattic is a static site generator built in Python. It takes Markdown files with front matter and turns them into a full HTML site using Jinja2 templates.

You can use it to build blogs, documentation, landing pages, portfolios, or simple sites — without relying on JavaScript-heavy frameworks or platform lock-in.

Features in v1.0:

  • Fully modular Python package (pip install stattic)

  • New CLI (stattic --init, stattic build, etc.)

  • Project scaffolding with base templates and config

  • Clean HTML output (SEO-friendly, no client-side JS required)

  • YAML or JSON config (stattic.yml or stattic.json)

  • Built-in SSRF and path sanitization for better security

  • Template theming with Alpine.js-powered mobile nav by default

Target Audience

This is a production-ready tool aimed at:

  • Developers who want full control over their site

  • WordPress/PHP devs transitioning to Python

  • Technical folks building documentation, blogs, or landing pages

  • Indie hackers, educators, and minimalists who don’t want React/Vue-based SSGs

It’s not a toy or proof of concept - it's installable via PyPI, well-documented, and being used in real-world projects (including my own site and course platform).

Comparison

Compared to other SSGs:


r/Python • • May 14 '13

It's time to migrate to Python 3.x guys, seriously.

0 Upvotes

Enough of this "I'm still waiting for Python 3 to be good." It is good. Use a migration tool and upgrade to 3.3 (as of 2013)


r/Python • • Apr 21 '19

Windows Desktop Notifications in 3 lines of Code | Python 3.6

Thumbnail
youtube.com
49 Upvotes

r/Python • • Oct 05 '16

Python Cheat Sheet

Thumbnail
cheatography.com
79 Upvotes

r/Python • • Sep 27 '18

Stop writing lambda expressions in Python

Thumbnail
treyhunner.com
0 Upvotes

r/Python • • Jul 22 '11

Apparently Quentin Tarantino is making a movie about Python web programming

Thumbnail
imdb.com
11 Upvotes

r/Python • • Apr 18 '24

Discussion Why Jupyter notebook

0 Upvotes

I did a search and read previous discussions in this sub about why Jupyter labs exists. From what I understand it is for quick code to try things out especially in data science …. Thing is, can’t you get the same thing via a decent IDE with autocomplete and quality debug tools in some quick Python code like in VSCODE? I do that all the time….

I develop RNA computational software in Python and I abandoned Jupyter labs very early on as it just was not well suited to the job of bespoke data science. So many limitations and don’t get me started with widgets… I’ve been developing code for decades and I have spent 3 days trying to understand widgets and I think I finally understand how to modify a text box and get a value from it…. You have to observe (why?), then act on, then route through some output and then you can get the info? It’s like someone was drunk while trying to emulate visual C#.

Edit: before anyone else tells me to read vscode docs like I’m an idiot… I am unable to remote into the repo I’m using now for reasons. Not everyone can remote in and the question is not about remoting in. It’s still garbage in VSCODE… just use regular python.

Edit2: for everyone who says they use it to do chunks of code work… I developed my own data management system for that kind of stuff that provides a wrapper over serialization that essentially creates pythonic pointers to data on any network drive. I just grab my data that I want to grab. Provides autocomplete and C# like attributes. I can dynamically build any data storage class using UML formatted infrastructure-as-code to build the front end. The back end is completely dynamic. Here is the pypi link. Note that I developed this to handle genomic data that was generated over the course of a week of 24/7 computation.

https://pypi.org/project/data-nut-squirrel/


r/Python • • Mar 17 '25

Showcase I built a pre-commit hook that enforces code coverage thresholds

0 Upvotes

What My Project Does

coverage-pre-commit is a Python pre-commit hook that automatically runs your tests with coverage analysis and fails commits that don't meet your specified threshold. It prevents code with insufficient test coverage from even making it to your repository, letting you catch coverage issues earlier than CI pipelines.

The hook integrates directly with the popular pre-commit framework and provides a simple command-line interface with customizable options.

Target Audience

This tool is designed for Python developers who:

  • Take test coverage seriously in production code

  • Use pre-commit hooks in their workflow

  • Want to enforce consistent coverage standards across their team

  • Need flexibility with different testing frameworks

It's production-ready and stable, with a focus on reliability and ease of integration into existing projects.

Comparison with Alternatives

Unlike custom scripts that you might write yourself, coverage-pre-commit:

  • Works immediately without boilerplate

  • Handles dependency management automatically

  • Supports multiple test providers with a unified interface

  • Is maintained and updated regularly

Key Features:

  • Works with unittest and pytest out of the box (with plans to add more frameworks)

  • Configurable threshold - set your own standards (default: 80%)

  • Automatic dependency management - installs what it needs

  • Customizable test commands - use your own if needed

  • Super easy setup - just add it to your pre-commit config

How to set it up:

Add this to your .pre-commit-config.yaml:

-   repo: https://github.com/gtkacz/coverage-pre-commit
    rev: v0.1.1  # Latest version
    hooks:
    -   id: coverage-pre-commit
        args: [--fail-under=95]  # If you want to set your own threshold

More examples:

Using pytest:

-   repo: https://github.com/gtkacz/coverage-pre-commit
    rev: v0.1.1
    hooks:
    -   id: coverage-pre-commit
        args: [--provider=pytest, --extra-dependencies=pytest-xdist]

Custom command:

-   repo: https://github.com/gtkacz/coverage-pre-commit
    rev: v0.1.1
    hooks:
    -   id: coverage-pre-commit
        args: [--command="coverage run --branch manage.py test"]

Any feedback, bug reports, or feature requests are always welcome! You can find the project on GitHub.

What do you all think? Any features you'd like to see added?


r/Python • • Dec 25 '17

Python Programming Tutorial File handling part 18

Thumbnail
youtube.com
0 Upvotes

r/Python • • Mar 28 '17

Kite, the copilot for programmers, available today for Python

Thumbnail
kite.com
26 Upvotes

r/Python • • Dec 01 '16

It’s Python, Not Python 2, Not Python 3!

Thumbnail
medium.com
0 Upvotes

r/Python • • Feb 28 '18

[TIL] CPython is mostly written in Python (not C)

Post image
0 Upvotes

r/Python • • Oct 10 '24

Discussion Petition for Python 3.14 to be called 'PiThon or 'πthon'

0 Upvotes

Since python 3.13 was released this year, and 3.14 releasing next year, it would be very splendid to mark Python 3.14 to be called PiThon or πthon, just for the fun of it. no need to change the language. If the devs want, they can make python 3.14 respond to 'pithon --version' too


r/Python • • Feb 09 '18

I was having way too much fun with a script and decided it needed an appropriate logo. Hope you enjoy!

Post image
19 Upvotes

r/Python • • Apr 25 '22

Resource 10% of the 666 most popular Python GitHub repos have f-string bugs (so 68 pull requests were made in 24 hours to fix them all)

Thumbnail
codereviewdoctor.medium.com
350 Upvotes

r/Python • • Jun 03 '25

Discussion So tired of python

0 Upvotes

I've been working with python for roughly 10 years, and I think I've hated the language for the last five. Since I work in AI/ML I'm kind of stuck with it since it's basically industry standard and my company's entire tech stack revolves around it. I used to have good reasons (pure python is too slow for anything which discourages any kind of algorithm analysis because just running a for loop is too much overhead even for simple matrix multiplication, as one such example) but lately I just hate it. I'm reminded of posts by people searching for reasons to leave their SO. I don't like interpreted white space. I hate dynamic typing. Pass by object reference is the worst way to pass variables. Everything is a dictionary. I can't stand name == main.

I guess I'm hoping someone here can break my negative thought spiral and get me to enjoy python again. I'm sure the grass is always greener, but I took a C++ course and absolutely loved the language. Wrote a few programs for fun in it. Lately everything but JS looks appealing, but I love my work so I'm still stuck for now. Even a simple "I've worked in X language, they all have problems" from a few folks would be nice.


r/Python • • Sep 07 '24

News Python 3.13 RC2 Available Today - Python 3.13 available October 1st

21 Upvotes

Python 3.13 will drop on October 1st.

The second release candidate just dropped today.

Don't be afraid to upgrade.

Install the RC2 from here and run your regression tests for your applications, and be ready to upgrade to Python 3.13 the moment it becomes available on October 1st.

If any of your dependencies fail when running your application on the RC2, immediately raise an issue on their github and complain loudly that they need to make the changes to make it compatible as well as publish binary wheels.

https://www.python.org/downloads/release/python-3130rc2/


r/Python • • Jan 22 '12

Python packaging cat jumps out of bag

Thumbnail mail.python.org
3 Upvotes

r/Python • • Dec 07 '21

Tutorial Why we choose FastAPI over Flask for building ML applications

25 Upvotes

Hi guys, our team has recently decided to adopt FastAPI and this is our experience:

The project-Milvus Bootcamp is where people can use Milvus, a vector database, to build and experience vector similarity search applications like reverse image search systems and chatbots. Before making the final decision, we researched several mainstream frameworks including Django, Flask, Tornado, and FastAPI. And since our priority is to choose the one that’s most lightweight and agile, we narrowed it down to Flask and FastAPI.

Here are some comparisons we made between FastAPI and Flask:

While there are no silver bullets, we choose FastAPI because of several reasons listed below:

1. Performance

Most of the projects in Milvus Bootcamp are built around reverse image search systems, QA chatbots, text search engines, which all have high demands for real-time data processing. Accordingly, we need a framework with outstanding performance, which is exactly a highlight of FastAPI.

2. Efficiency

Milvus Bootcamp is positioned as a type of training resource. This means that the code and components we use must be intuitive and highly efficient. In this regard, we chose FastAPI to improve system efficiency and enhance user experience.

3. Asynchronous framework

In the demos we made, one can upload datasets and will be immediately prompted "request received". And when the data is uploaded to the demo system, you will receive another prompt "data upload successfully". This is an asynchronous process that requires a framework that supports this feature. FastAPI is itself an asynchronous framework, that's why we changed the framework from Flask to FastAPI.

4. Automatic interactive documents

Most of our users just want to quickly get started with the server-side development part of the projects in Milvus Bootcamp without writing additional code to create an interface. By providing an OpenAPI document, FastAPI can save one the trouble of testing or debugging APIs and collaborating with front-end teams to develop a user interface.

If you are interested, there are more details provided in this article.


r/Python • • Dec 03 '24

Showcase How I Automated My Tech Job Applications Using Python, Apify, and AI

0 Upvotes

Hi everyone!

I’ve found job hunting to be one of the most time-consuming and repetitive tasks. Manually searching for job listings, crafting cover letters, and sending applications felt like an endless loop of frustration. So, I decided to build a solution!

What My Project Does:

I developed a Python script that automates the entire job application process. Here's how it works:

  • Scrapes job listings using Apify’s Seek Job Scraper.

  • Uses Meta AI to generate personalized cover letters and email content.

  • Sends tailored applications with resumes attached via SMTP.

  • Logs every application to avoid duplicates.

Target Audience:

This tool is designed for anyone who wants to streamline their job search process. Whether you're a career changer, or an experienced developer looking to save time, this script will help you automate the most repetitive parts of applying to jobs.

Comparison:

While there are some job application automation tools available, most are either too complex or not customizable enough. My script stands out because it offers:

  • Smart filtering for roles in specific regions, salary ranges, and work types.

  • AI-powered personalized cover letter generation using Meta AI.

  • A simple, customizable workflow with easy integration to your job boards and email system.

Would love to hear your thoughts or any tips you have for automating job searches!

Repo: https://github.com/Jacob1802/seek-automation


r/Python • • Mar 12 '26

Resource I built a dual-layer memory system for local LLM agents – 91% recall vs 80% RAG, no API calls

0 Upvotes

Been running persistent AI agents locally and kept hitting the same memory problem: flat files are cheap but agents forget things, full RAG retrieves facts but loses cross-references, MemGPT is overkill for most use cases.

Built zer0dex — two layers:

Layer 1: A compressed markdown index (~800 tokens, always in context). Acts as a semantic table of contents — the agent knows what categories of knowledge exist without loading everything.

Layer 2: Local vector store (chromadb) with a pre-message HTTP hook. Every inbound message triggers a semantic query (70ms warm), top results injected automatically.

Benchmarked on 97 test cases:

• Flat file only: 52.2% recall

• Full RAG: 80.3% recall

• zer0dex: 91.2% recall

No cloud, no API calls, runs on any local LLM via ollama. Apache 2.0.

pip install zer0dex

https://github.com/roli-lpci/zer0dex


r/Python • • May 01 '18

My biggest struggle while helping newcomers with Python

Thumbnail
medium.com
3 Upvotes

r/Python • • Feb 14 '12

Python Performance Tips, Part 1

Thumbnail
blog.monitis.com
20 Upvotes

r/Python • • Jun 18 '13

Creating python command-line applications

Thumbnail pauloortins.com
0 Upvotes