Practice debugging, by intentionally introducing bugs into an existing codebase.
https://github.com/ehmatthes/py-bugger
https://github.com/ehmatthes/py-bugger
GitHub
GitHub - ehmatthes/py-bugger: An intentional way to practice debugging in Python.
An intentional way to practice debugging in Python. - ehmatthes/py-bugger
👍1
This walkthrough, noscriptd "Web Scraping with Python: Learn It Fast!", demonstrates how to automate data collection from websites using Python, focusing on the BeautifulSoup and requests libraries. It covers the essential steps from fetching webpage HTML and extracting specific elements like headlines or prices to saving the data and checking robots.txt for legality.
https://dev.to/0x3d_site/web-scraping-with-python-learn-it-fast-4c6b
https://dev.to/0x3d_site/web-scraping-with-python-learn-it-fast-4c6b
This essay dissects troubleshooting as a fundamental, domain-agnostic skill, defining it as the systematic process of determining and fixing the cause of unwanted system behavior. It outlines a detailed framework for effective troubleshooting, covering aspects like adopting the right mindset, understanding system flows, isolating problems, gathering information, assessing risks, and the importance of patience and detailed observation.
https://www.autodidacts.io/troubleshooting/
https://www.autodidacts.io/troubleshooting/
The Autodidacts
Troubleshooting: The Skill That Never Goes Obsolete
Much of what I do, in multiple fields, could be reduced to one skill: troubleshooting.
I’ll define troubleshooting as systematically determining the cause of unwanted behaviour in a system, and fixing it.
Troubleshooting is often learned tacitly, in…
I’ll define troubleshooting as systematically determining the cause of unwanted behaviour in a system, and fixing it.
Troubleshooting is often learned tacitly, in…
👍1
"The Python Debugging Playbook" outlines a systematic approach to fixing Python code, framing effective debugging as a learned skill rather than innate talent. This playbook presents a five-step process covering interpreting errors, using breakpoint(), isolating bugs, searching effectively, and structuring requests for help.
https://dev.to/0x3d_site/the-python-debugging-playbook-fix-your-code-4nbb
https://dev.to/0x3d_site/the-python-debugging-playbook-fix-your-code-4nbb
👍1
isd (interactive systemd) – a better way to work with systemd units
https://github.com/isd-project/isd
https://github.com/isd-project/isd
GitHub
GitHub - kainctl/isd: isd (interactive systemd) – a better way to work with systemd units
isd (interactive systemd) – a better way to work with systemd units - kainctl/isd
👍1
coredumpy saves your crash site for post-mortem debugging
https://github.com/gaogaotiantian/coredumpy
https://github.com/gaogaotiantian/coredumpy
GitHub
GitHub - gaogaotiantian/coredumpy: coredumpy saves your crash site for post-mortem debugging
coredumpy saves your crash site for post-mortem debugging - gaogaotiantian/coredumpy
👍1
This comparison evaluates Python and JavaScript for web development, examining their respective strengths and weaknesses through framework matchups like Flask vs. Node.js and Django vs. Express. It provides code samples, performance insights, and guidance to help developers select the appropriate technology stack based on project requirements.
https://dev.to/resource_bunk_1077cab07da/python-vs-javanoscript-which-wins-for-web-dev-1gbk
https://dev.to/resource_bunk_1077cab07da/python-vs-javanoscript-which-wins-for-web-dev-1gbk
👍1
This Talk Python episode features Brett Kennedy, author of Outlier Detection with Python, exploring how to identify significant anomalies in data using various Python tools and techniques. The discussion covers real-world applications from finance to astronomy, key libraries like PyOD and scikit-learn, handling large datasets, and the importance of interpretability when dealing with outliers.
https://talkpython.fm/episodes/show/497/outlier-detection-with-python
https://talkpython.fm/episodes/show/497/outlier-detection-with-python
talkpython.fm
Outlier Detection with Python
Have you ever wondered why certain data points stand out so dramatically? They might hold the key to everything from fraud detection to groundbreaking discoveries. This week on Talk Python to Me, we dive into the world of outlier detection with Python with…
👍2
System-wide Python package discovery, validation, and allow-listing
https://github.com/fetter-io/fetter-rs
https://github.com/fetter-io/fetter-rs
GitHub
GitHub - fetter-io/fetter-rs: System-wide Python package discovery, validation, and allow-listing
System-wide Python package discovery, validation, and allow-listing - fetter-io/fetter-rs
👍3
This feature dives into actionable techniques for improving Python code quality, addressing common issues like nested loops, long functions, and unclear conditionals. It provides practical refactoring examples using list comprehensions, modular functions, ternary operators, type hints, and the Loguru library for better logging.
https://dev.to/resource_bunk_1077cab07da/your-python-code-is-ugly-heres-how-to-fix-it-40dm
https://dev.to/resource_bunk_1077cab07da/your-python-code-is-ugly-heres-how-to-fix-it-40dm
👍1
This recounting by Max Bernstein details a real-world performance optimization saga from developing a custom Python runtime, where a seemingly innocuous string function bottlenecked Django performance. The analysis reveals how a naive Python implementation of str.rpartition led to excessive, costly UTF-8 indexing operations, emphasizing the need to look beyond surface-level profiler results to find the true cause of slowdowns.
https://bernsteinbear.com/blog/silly-perf/
https://bernsteinbear.com/blog/silly-perf/
Max Bernstein
Optimizing Django by not being silly
I just saw this post and it reminded me of a time when we had a similar situation, but with string operations in our VM. The project is now defunct but the code is open. Let’s go back in time.
Use Typer (type hints) to define the interface for your Django management commands.
https://github.com/django-commons/django-typer
https://github.com/django-commons/django-typer
GitHub
GitHub - django-commons/django-typer: Use Typer (type hints) to define the interface for your Django management commands.
Use Typer (type hints) to define the interface for your Django management commands. - django-commons/django-typer
This demonstration walks through creating a functional Python compiler using Python, explaining the core steps from source code to execution. It breaks down tokenization, Abstract Syntax Tree (AST) generation, bytecode compilation, and interpretation with a simple virtual machine.
https://dev.to/resource_bunk_1077cab07da/how-i-built-a-python-compiler-yes-really-1dgp
https://dev.to/resource_bunk_1077cab07da/how-i-built-a-python-compiler-yes-really-1dgp
DEV Community
How I Built a Python Compiler (Yes, Really!)
Take this as an GIFT 🎁: Build a Hyper-Simple Website and Charge $500+ And this: Launch Your First...
This Pybites exploration delves into Python generators, explaining how the yield statement enables memory-efficient, on-demand value production crucial for large datasets. It details the mechanics of generator functions, the conciseness of generator expressions, and the advantages of their lazy evaluation and state preservation capabilities.
https://pybit.es/articles/generator-mechanics-expressions-and-efficiency/
https://pybit.es/articles/generator-mechanics-expressions-and-efficiency/
Pybites
Optimizing Python: Understanding Generator Mechanics, Expressions, And Efficiency - Pybites
Python generators provide an elegant mechanism for handling iteration, particularly for large datasets where traditional approaches may be memory-intensive.
👍1
Phil Eaton’s recent blogpost explores how to embed Python within Rust for the purpose of running tests, offering a hands-on guide to setting up a Rust-based test runner that can execute Python noscripts and even expose Rust functions to Python code. This practical walkthrough highlights the flexibility of combining Rust’s performance with Python’s noscripting capabilities for more dynamic and parallel test scenarios.
https://www.enterprisedb.com/blog/embedding-python-rust-tests
https://www.enterprisedb.com/blog/embedding-python-rust-tests
EDB
Embedding Python in Rust (for tests)
The latest generation of pr
A Self-adaptation Framework🐙 that adapts LLMs for unseen tasks in real-time!
https://github.com/SakanaAI/self-adaptive-llms
https://github.com/SakanaAI/self-adaptive-llms
GitHub
GitHub - SakanaAI/self-adaptive-llms: A Self-adaptation Framework🐙 that adapts LLMs for unseen tasks in real-time!
A Self-adaptation Framework🐙 that adapts LLMs for unseen tasks in real-time! - SakanaAI/self-adaptive-llms
👍2
Installing Python dependencies with pip can be frustratingly slow, especially in CI pipelines or when building Docker images. This guide discusses how to speed up the process by focusing on using pre-built wheels instead of source distributions, leveraging package caching, disabling bytecode compilation when appropriate, and considering faster alternatives like uv, a Rust-based package installer that parallelizes downloads and skips bytecode compilation by default.
https://pythonspeed.com/articles/faster-pip-installs
https://pythonspeed.com/articles/faster-pip-installs
Python⇒Speed
Faster pip installs: caching, bytecode compilation, and uv
Installing packages with pip can be slow. Learn some ways to speed it up.
OpenTelemetry is an open source, vendor-neutral observability framework that provides standardized APIs, libraries, and tools to collect telemetry data-such as metrics, logs, and traces-from your application, allowing you to monitor different systems and platforms seamlessly and future-proof your monitoring setup. To add OpenTelemetry to a Django application, you can use either automatic or manual instrumentation: automatic instrumentation involves installing packages like opentelemetry-instrumentation-django and configuring environment variables and your Django settings to export data to an observability backend (such as Elastic), while manual instrumentation gives you finer control by adding tracing and metrics code directly to your views and models, enabling custom monitoring of application behavior and performance.
https://allthingsopen.org/articles/what-is-opentelemetry-add-django-application
https://allthingsopen.org/articles/what-is-opentelemetry-add-django-application
All Things Open
What is OpenTelemetry and how to add it to your Django application | We Love Open Source • All Things Open
OpenTelemetry is an open source, vendor-neutral way to add monitoring features to your application. It is designed to allow you to monitor different systems using different backends in a standardized... Read More
👍2
David Guillot’s experiment investigates how web push notifications, when combined with Progressive Web Apps (PWAs), can offer a compelling alternative to traditional mobile apps for user engagement. By leveraging Django and packages like django-webpush and django-pwa, the article demonstrates a practical approach to implementing reliable, native-feeling notifications on both desktop and mobile-highlighting UX design considerations, technical constraints (such as iOS requiring PWA installation for notifications), and offering a live demo to gather community feedback on usability and device impact.
https://david.guillot.me/en/posts/tech/web-push-notifications-an-experiment/
https://david.guillot.me/en/posts/tech/web-push-notifications-an-experiment/
David Guillot
Push notifications without a mobile app: an experiment (with Django)
Today I want to talk to you about a combination of technologies that I don’t see often implemented, yet I wonder why: Web Push Notifications and Progressive Web Apps.
And I’d like you to try it, with kittens 😸
🔔 Why?
Say you have a small news website, or…
And I’d like you to try it, with kittens 😸
🔔 Why?
Say you have a small news website, or…