r/Python • • Nov 15 '18

Flask app to extract palette of dominating colors from image

Post image
1.5k Upvotes

r/Python • • Aug 13 '19

Made a racing game that runs in Terminal. 100% Python

1.5k Upvotes

r/Python • • Nov 17 '18

Python in the new NASA going to the Moon video.

Post image
1.5k Upvotes

r/Python • • Oct 27 '25

News The PSF has withdrawn $1.5 million proposal to US government grant program

1.5k Upvotes

In January 2025, the PSF submitted a proposal to the US government National Science Foundation under the Safety, Security, and Privacy of Open Source Ecosystems program to address structural vulnerabilities in Python and PyPI. It was the PSF’s first time applying for government funding, and navigating the intensive process was a steep learning curve for our small team to climb. Seth Larson, PSF Security Developer in Residence, serving as Principal Investigator (PI) with Loren Crary, PSF Deputy Executive Director, as co-PI, led the multi-round proposal writing process as well as the months-long vetting process. We invested our time and effort because we felt the PSF’s work is a strong fit for the program and that the benefit to the community if our proposal were accepted was considerable.  

We were honored when, after many months of work, our proposal was recommended for funding, particularly as only 36% of new NSF grant applicants are successful on their first attempt. We became concerned, however, when we were presented with the terms and conditions we would be required to agree to if we accepted the grant. These terms included affirming the statement that we “do not, and will not during the term of this financial assistance award, operate any programs that advance or promote DEI, or discriminatory equity ideology in violation of Federal anti-discrimination laws.” This restriction would apply not only to the security work directly funded by the grant, but to any and all activity of the PSF as a whole. Further, violation of this term gave the NSF the right to “claw back” previously approved and transferred funds. This would create a situation where money we’d already spent could be taken back, which would be an enormous, open-ended financial risk.   

Diversity, equity, and inclusion are core to the PSF’s values, as committed to in our mission statement: 

The mission of the Python Software Foundation is to promote, protect, and advance the Python programming language, and to support and facilitate the growth of a diverse and international community of Python programmers.

Given the value of the grant to the community and the PSF, we did our utmost to get clarity on the terms and to find a way to move forward in concert with our values. We consulted our NSF contacts and reviewed decisions made by other organizations in similar circumstances, particularly The Carpentries.  

In the end, however, the PSF simply can’t agree to a statement that we won’t operate any programs that “advance or promote” diversity, equity, and inclusion, as it would be a betrayal of our mission and our community. 

We’re disappointed to have been put in the position where we had to make this decision, because we believe our proposed project would offer invaluable advances to the Python and greater open source community, protecting millions of PyPI users from attempted supply-chain attacks. The proposed project would create new tools for automated proactive review of all packages uploaded to PyPI, rather than the current process of reactive-only review. These novel tools would rely on capability analysis, designed based on a dataset of known malware. Beyond just protecting PyPI users, the outputs of this work could be transferable for all open source software package registries, such as NPM and Crates.io, improving security across multiple open source ecosystems.

In addition to the security benefits, the grant funds would have made a big difference to the PSF’s budget. The PSF is a relatively small organization, operating with an annual budget of around $5 million per year, with a staff of just 14. $1.5 million over two years would have been quite a lot of money for us, and easily the largest grant we’d ever received. Ultimately, however, the value of the work and the size of the grant were not more important than practicing our values and retaining the freedom to support every part of our community. The PSF Board voted unanimously to withdraw our application. 

Giving up the NSF grant opportunity—along with inflation, lower sponsorship, economic pressure in the tech sector, and global/local uncertainty and conflict—means the PSF needs financial support now more than ever. We are incredibly grateful for any help you can offer. If you're already a PSF member or regular donor, you have our deep appreciation, and we urge you to share your story about why you support the PSF. Your stories make all the difference in spreading awareness about the mission and work of the PSF. In January 2025, the PSF submitted a proposal to the US government National Science Foundation under the Safety, Security, and Privacy of Open Source Ecosystems program
to address structural vulnerabilities in Python and PyPI. It was the
PSF’s first time applying for government funding, and navigating the
intensive process was a steep learning curve for our small team to
climb. Seth Larson, PSF Security Developer in Residence, serving as
Principal Investigator (PI) with Loren Crary, PSF Deputy Executive
Director, as co-PI, led the multi-round proposal writing process as well
as the months-long vetting process. We invested our time and effort
because we felt the PSF’s work is a strong fit for the program and that
the benefit to the community if our proposal were accepted was
considerable.  We were honored when, after many months of work, our proposal was recommended for funding, particularly as only 36% of
new NSF grant applicants are successful on their first attempt. We
became concerned, however, when we were presented with the terms and
conditions we would be required to agree to if we accepted the grant.
These terms included affirming the statement that we “do not, and will
not during the term of this financial assistance award, operate any
programs that advance or promote DEI, or discriminatory equity ideology
in violation of Federal anti-discrimination laws.” This restriction
would apply not only to the security work directly funded by the grant, but to any and all activity of the PSF as a whole.
Further, violation of this term gave the NSF the right to “claw back”
previously approved and transferred funds. This would create a situation
where money we’d already spent could be taken back, which would be an
enormous, open-ended financial risk.   
Diversity, equity, and inclusion are core to the PSF’s values, as committed to in our mission statement: The
mission of the Python Software Foundation is to promote, protect, and
advance the Python programming language, and to support and facilitate
the growth of a diverse and international community of Python programmers.Given
the value of the grant to the community and the PSF, we did our utmost
to get clarity on the terms and to find a way to move forward in concert
with our values. We consulted our NSF contacts and reviewed decisions
made by other organizations in similar circumstances, particularly The Carpentries.  
In
the end, however, the PSF simply can’t agree to a statement that we
won’t operate any programs that “advance or promote” diversity, equity,
and inclusion, as it would be a betrayal of our mission and our
community. 
We’re disappointed to
have been put in the position where we had to make this decision,
because we believe our proposed project would offer invaluable advances
to the Python and greater open source community, protecting millions of
PyPI users from attempted supply-chain attacks. The proposed project
would create new tools for automated proactive review of all packages
uploaded to PyPI, rather than the current process of reactive-only
review. These novel tools would rely on capability analysis, designed
based on a dataset of known malware. Beyond just protecting PyPI users,
the outputs of this work could be transferable for all open source
software package registries, such as NPM and Crates.io, improving
security across multiple open source ecosystems.
In
addition to the security benefits, the grant funds would have made a
big difference to the PSF’s budget. The PSF is a relatively small
organization, operating with an annual budget of around $5 million per
year, with a staff of just 14. $1.5 million over two years would have
been quite a lot of money for us, and easily the largest grant we’d ever
received. Ultimately, however, the value of the work and the size of
the grant were not more important than practicing our values and
retaining the freedom to support every part of our community. The PSF
Board voted unanimously to withdraw our application. 
Giving
up the NSF grant opportunity—along with inflation, lower sponsorship,
economic pressure in the tech sector, and global/local uncertainty and
conflict—means the PSF needs financial support now more than ever. We
are incredibly grateful for any help you can offer. If you're already a
PSF member or regular donor, you have our deep appreciation, and we urge
you to share your story about why you support the PSF. Your stories
make all the difference in spreading awareness about the mission and
work of the PSF. 

https://pyfound.blogspot.com/2025/10/NSF-funding-statement.html


r/Python • • Jul 22 '19

For those of you made uncomfortable by yesterdays simulation. No phones were harmed in the making of this simulation

1.5k Upvotes

r/Python • • Mar 06 '20

News Prof. Gilbert Strang a mathematician and professor at MIT mentioning Python while teaching a course on Computational Science and Engineering in Fall 2008

Post image
1.5k Upvotes

r/Python • • Aug 21 '19

I created a python script that can (technically) play videos inside of the terminal!

1.5k Upvotes

r/Python • • May 28 '20

I Made This 2D Raycasting along with Rendered view - Visualization was done using Pygame! People who love games would definitely love this! Link to the Github repository in the comments!

1.5k Upvotes

r/Python • • Aug 07 '21

Intermediate Showcase Wrote this program to skip Spotify Ads using Spotify API

1.5k Upvotes

No one likes interruptions! right? So i wrote this program that detects when an advertisement plays by monitoring the type of the track that is currently playing, using the Spotipy API. When an ad is detected, the program restarts Spotify by the os module and plays it via pynput, which skips the ad and starts right where you left off. Its kinda cool and i am proud of it.

Here is the repo- https://github.com/daspartho/SpotiByeAds

I would love to get some thoughts and feedback on the project.


r/Python • • Sep 26 '22

Resource How I deploy my bootstrapped Python webapp with 150k monthly users

1.5k Upvotes

I am a one-man show building a web-based software product. Some quick facts about my app:

  • Written in Python Flask

  • 150k visitors per month

  • 15k registered users

  • 3k US$ revenue per month

  • 70 requests per second at peak-time

This is a technical post looking at the infrastructure that runs my app with a focus on how I deploy it.

Summary

  • I use 2 VPS (virtual private servers) running on DigitalOcean

  • The database is Postgres and is fully managed by DigitalOcean

  • I use a blue-green deployment

  • Deployment is done via git and ssh.

  • No CI/CD

  • No containers

  • Absolutely no Kubernetes

I am a strong advocate of using "boring technology". I am also the only developer of the app, which makes many things simpler.

The application infrastructure

The app is a CRUD monolith that is deployed as one artefact. I use nginx and gunicorn to serve the app.

The app runs on 2 virtual private servers, one of which is the production server, the other of which is the staging server. During deployment, they switch roles. This is a so-called blue-green deployment, more on that later.

I'm using a DigitalOcean droplet with 8 shared CPUs, 16GB of memory and 80 GB of storage for each server. They both run Ubuntu which I have to administrate.

There is a single Postgres database, which is always in production. It is fully managed by DigitalOcean, which means I have to do no house-keeping. Currently, it has 4 shared CPUs, 8 GB of memory and 115 GB of storage.

Overall, the setup is absolutely rock solid. Also, all my technology is older than 10 years (OK, not 100% sure about this, but probably true).

Why I chose blue-green deployment

Before I switched, my deployments worked as follows:

  • There was one app server running on DigitalOcean, plus the hosted Postgres database.

  • To deploy, I used a script that SSHed into that server and did a git pull

This was fine to begin with, however there were several issues:

  1. My setup compiles and minifies CSS and Javascript on the server. This resulted in up to 10 seconds for the server to respond after a deployment. Some users ran into Bad Gateway errors 💥.

  2. A bug in production could be fixed by checking out the previous commit. However, this invariably took too long and always involved frenzied googling of the correct git commands.

  3. There was no way of testing the production setup, other than in production.

What is blue-green deployment?

Here's how I would explain blue-green deployment:

  1. There are two identical and independent servers hosting the application. One is called "green", the other "blue".

  2. There is a shared production database that both servers can access.

  3. There is a quick and painless way of routing traffic to the green or the blue server.

One of the 2 servers is serving production traffic (the live server), the other is idle. When a new release is ready, it gets deployed to the idle server. Here it can be tested and issues fixed. Remember, the idle server is still accessing the production database, so the application can be tested with real data.

Once you're satisfied that you're ready, you switch traffic from the live server to the idle server. If any problems occur, you can simply switch back within seconds, effectively doing a roll-back.

Simple, no?

How I do blue-green deployment

I've already mentioned my 2 application servers. But the magic thing that makes it all possible is a floating IP address from DigitalOcean.

This is a publicly-accessible static IP addresses that you can assign to a server and instantly remap between other servers in the same datacenter. My app domain (keepthescore.com) resolves to this static IP address. Internally, however, the IP is pointing to either the green or the blue server.

Both of my servers expose their hostname via a publicly accessible route: https://keepthescore.com/hostname/. Give it a try by clicking on the link!

So now it's possible for a human or a machine (using curl) to discover which the current live server is (blue or green).

The deployment script can use this information to always automatically deploy to the idle server. Here's my (simplified) BASH deployment script:

# Get the current production server and 
# set TARGET to the other server 
CURRENT=$(curl -s https://keepthescore.com/hostname)
if [ "$CURRENT" = "blue-production" ]; then
  TARGET="green.keepthescore.com"
else 
  TARGET="blue.keepthescore.com"

echo "Current deployment is " $CURRENT
echo "Deploying to " $TARGET

# Do deployment
ssh -q root@$TARGET "git pull"
echo "Deploy to " $TARGET " complete"

After I've run the script I can test the deployment on my laptop by simply pointing my browser to blue.keepthescore.com or green.keepthescore.com. Once I'm sure that everything's working I route traffic to the newly deployed idle server using DigitalOceans's web interface. (I could do this via script too, but haven't got round to it yet).

Result: My users get routed to the newly deployed software without noticing (hopefully).

Voilá! ✨

What about continuous integration / continuous deployment?

I have no CI/CD pipeline. I do have a bunch of integration tests, but I run them manually. I will eventually get round to setting up some kind of automated testing, but so far there's been no need.

Just to be clear: when I run my integration tests, they happen on my laptop and use a test instance of the database. It's only when I do manual high-level testing on the idle staging server that the production database is used.

What about the database?

There is only one database instance, so you might think this could be a problem. Martin Fowler, who wrote a great article about blue-green deployments says the following:

Databases can often be a challenge with this technique, particularly when you need to change the schema to support a new version of the software. The trick is to separate the deployment of schema changes from application upgrades. So first apply a database refactoring to change the schema to support both the new and old version of the application, deploy that, check everything is working fine so you have a rollback point, then deploy the new version of the application. (And when the upgrade has bedded down remove the database support for the old version.)"

I've been using this method so far. In fact, I have never done an automated schema migration of my database. It's worked great so far, so why do it differently?

That's all

Thanks for reading my article! You can follow my journey as a bootstrapped one-man startup on Twitter. See you in the next post!

One more thing: if you want to share this post, please consider using this link (which points to my blog)


r/Python • • Oct 16 '19

My previous post on the algorithm i made to create these images blew up, so here is another! WITH a Github link: https://github.com/TyperOfCode/image_algorithm

Post image
1.5k Upvotes

r/Python • • Apr 11 '19

Just Found the Best Python Book...Cover NSFW

Post image
1.5k Upvotes

r/Python • • May 26 '21

News Python is now the second most popular language in the world according to TIOBE. This is the highest position that Python reaches since 2001.

Thumbnail
tiobe.com
1.5k Upvotes

r/Python • • Jun 21 '20

I Made This Here's a very simple Python wallpaper

Post image
1.5k Upvotes

r/Python • • Aug 03 '20

Machine Learning I Made Snakes With Neural Networks! Here were the four best ones.

1.5k Upvotes

r/Python • • Nov 24 '22

Tutorial Detailed Python developer roadmap

1.5k Upvotes

Hello! My name is Mikhail Emelyanov, I am embedded software engineer, and I was inspired to write this little roadmap on the capabilities of Python language by a certain commonality among the existing Python tutorials found on the web.

The usual suggestions to study, say, “Algorithms and Data Structures” or “Databases” are especially jarring. You can spend years studying these topics, and even after decades you'd still be able to find something you didn't know yet even without ever venturing outside the scope of Algorithms!

Using video game analogies, we can say that novice programmers often stand on the shore of the lake of boiling lava with an island with the ever-coveted jobs in the center, while the islands in between, which you have to jump on, gradually increasing your skills in successive mini-quests, are either missing, or arranged haphazardly, or their fairly smooth sequence breaks off, never having managed to get you any farther from the shore. Let's try to build a path of hint islands, a number of which, although not without effort, will finally allow us to reach our goal.

The roadmap is very easy to use. Just as you would in a normal text, go from left to right and from top to bottom. If you're just starting to learn Python, follow the green sections of the roadmap. If your accumulated experience, curiosity, or necessity pushes you deeper, start exploring the sections marked in gray. Orange marks the topics that require in-depth study, those are better to tackle (at least without digging especially deep to begin with) on the third pass.

This article definitely contains mistakes and inaccuracies of different calibers, and of course, many required subsections are missing; so, if you notice any of these, feel free to comment, and if you feel the Force, you're welcome to fork the GitHub repository with the roadmap's source code and contribute whatever you feel is necessary; all corrections and additions are strongly encouraged. It also contains all the parts of the map in Mermaid diagram format, as well as png/svg illustrations.

When diving into Python, don't forget the excellent official documentation at docs.python.org. By studying it, at least in brief, and gradually reading deeper into the right sections, you will be able to see that many of the “hacks”, “findings” and other obscure matters have long since been considered, described and have detailed examples of use.

I would also recommend leetcode.com for learning basic Python syntax to the fullest extent. If you filter the tasks by “Easy” level, and then add an additional sorting by the “Acceptance” column, you'll be presented with a straightforward primer with smoothly increasing task difficulty, rather than the intimidating competitive platform.

Well, that’s enough stalling for the moment. Let's get started!

Data Structures

As a reminder, if you are a novice developer, go from left to right through the entries marked in green. Create instances of each type, try adding and removing elements, and experiment with them via the debugger. See how big the resulting objects are, and try to figure out why list and array containing the same data are different in size. Study the features of each type, read and figure out which data structure will work best for which tasks.

Don't forget that this is just a guide, a table of contents for a book that you will have to write yourself. Actively seek information on the web, consult sources and official documentation. Dive Stackoverflow just for fun, there's plenty of exciting reading there!

If you start to make progress, move on to the next section, and don't feel bad if you can't. Don't envision your mind as the sword of Alexander the Great cutting the Gordian knot in one fluid, precise move, worthy of Instagram's front page. Be as a carpenter’s plane, stripping away one thin layer at a time, and sooner or later the misunderstanding will go away, even if this seems to you to be a chasm ten thousand leagues deep.

Data Management

Try to manipulate your data, feel how you can mold anything you want out of this malleable clay. Try creating a data structure with many elements (a million, for example), sort them, quickly find the values you want with bisect, and write the results in a JSON file.

If everything goes according to plan, try to dig into the less obvious topics: apply regex to solve some simple task or save previously obtained data in Pickle format, understanding the reason for binary file formats after observing the size of the resulting files.

This is where you will find the first entries marked in orange. Google what TensorFlow and Keras are and what tasks they solve. Perhaps, this could be your future job, your vocation!

Data Flows

Add more specific capabilities to your data management skills. All of the topics covered are essential in the practical programming process and are present in all modern languages in one form or another. That way, if you eventually switch from Python to Java, C# or C++, the knowledge you've acquired won't become dead weight.

Object-Oriented Programming

Dive into the subject of object-oriented programming. Understand that objects are your friends, and all their features and properties, even if they are not quite intuitive at first glance, have purely utilitarian reasons for existing.

OOP makes it much easier to partition, develop and maintain code, not just making very complex tasks feasible for average programmers, but making the world around us more manageable, predictable and generally better.

Language Skeleton

Perfect, a bit deeper now. Studying how GIL or GC works will give you an understanding of why things go awry in one case or another, not at all the way you planned. You are likely to use exceptions all the time, given that they can occur in some operations with data structures, so study them further.

Multithreading and Multiprocessing

Before you dive into multithreading and multiprocessing, be sure to study their typical use cases. There may be situations in which the gain is minimal or non-existent.

Try to implement simultaneous fast data processing and waiting for user input, which changes the input data for calculations, so you understand the capabilities, pros and cons of different approaches.

Don't try to use all the features provided by Python at once, stick to the task at hand.

Common Practices

Description of common methods used in almost all software projects, not just in Python. I/O, profiling, and logging apply universally.

Testing in general constitutes a separate profession, and often the quality of a software product can be judged by the test coverage of the source code. For example, the code of the SQLite database is 100% covered by tests, while one line of "combative" code requires 608 lines of tests.Jokes aside, projects with 100% coverage are not common, but pytest used wisely is the best guarantor of your sound sleep at night!

Algorithms

One of those areas of human knowledge that you can delve into endlessly. On the other hand, the learning curve of this discipline for covering the practical needs of the average programmer has long been known, so the initial stages shouldn't be too difficult for you. Who knows, maybe you'll enjoy it so much and drag it out that in time you might even be able to contribute a new robust argument in the discussion of “Equality of P and NP classes”!

Databases

Learn the general concepts first, and then the specifics of working with specific database management systems. Try working with SQLite, even if you're planning to switch to PostgreSQL later. SQLite is a very popular database, used in Android, Chromium and dozens of other popular projects. You can use SQLite as a convenient local storage alternative to working with files directly.

By the way, try to briefly return to chapter one, Data Structures, to understand how and why the inner workings of databases are structured.

This also provides yet another door into a "another world". Perhaps you would like to tie your future to databases by becoming a DBA?

Net

Try to create a client and a server, poke some popular website or an open API. Here you might as well experiment with HTML, CSS, and even Java(Type)Script. Who knows, perhaps your choice would be to become a full-stack programmer, combining back- and frontend development.

Architecture

Please try not to memorize architectural principles by heart; they are not Shakespeare's timeless poems. The rambling about how “Liskov's substitution principle means that if S is a subtype of T, then objects of type T in a program can be...” offers no advantage to anyone. Just try applying the same LSP to the program you are writing. What benefit would compliance with this principle give you? What problems will result from not following it? What price will you have to pay for its implementation and support?

Try messing around with the functional paradigm. Applying the functional approach and using it in practice is possible not only in Haskell or F#, but also in Python, and it doesn't have to be done only within functools.

Figure out the reasoning behind the job interviewer's request to “say the three main words” (it's not “I love you”, by the way, it’s “inheritance, encapsulation, polymorphism”) and why this triad should be supplemented with the “abstraction”.

Try to understand what specific, tangible problems of the old paradigms the developers of Agile or the popularizers of microservice architecture faced. Figure out what's wrong with main(), which calls all the other procedures, since this is common practice in embedded programming. Weigh the cost of additional layers of abstraction between the root business logic and the outside world.

Deployment and Administration

Despite the fact that git and especially Linux are quite complicated and extensive topics, the beginning of their learning curve isn't very steep, so I highly recommend starting your DevOps mastering with git (at least the add-commit-push part, so you at least have a revision history, flawed as it is) and Linux (PuTTY + WinSCP, for example; copy your Python scripts via SSH and run them on a remote Linux machine). Fortunately, these days good text and video tutorials covering these topics are about as rare as grains of sand on the beach. Take it from me, the Linux console that looks so strange and inconvenient at first sight will seem much more familiar once you start learning vim. Cognition comes through comparison!

Well, this is where our map ends. Try to reach the last green section, GitHub Actions; run a linter on your open source project, for example (GitHub Actions is free for open source projects).

Overall Roadmap

The overall roadmap can be obtained by simply mechanically adding up the previous entries, just so we can see what we've ended up with. Overall Mermaid, svg, png.

That’s all for now

As you may have noticed, there is no mention of control constructs, IDE installation or virtualenv in this guide. In my opinion, all these topics are very important, but do not constitute the essence of the language, representing something like a binding solution, while the topics discussed in the article, from list to Kubernetes, serve as the full-fledged “bricks”.

As a reminder, all the diagrams are made in Mermaid format (you can change the picture just by correcting the text), all the sources are available on GitHub, correct as much as you want, or, of course, leave comments directly in the comments section.

Separately, I welcome all beginner programmers. You will come to realize that working 8 hours in a row using your head and not your hands is hard, too. But, no matter what languages you plan to code in and no matter how far you've come in this difficult task, you will definitely upgrade your brain, improve your understanding of the world around you and start to recognize secret passages where you have seen only impenetrable walls before. So it's time to start the IDE, focus a little bit, and start practicing.

And remember: “This is my Python. There are many like it, but this one is mine. My Python is my best friend. It is my life. I must master it as I must master my life. Without me, my Python is useless. Without my Python, I am useless. My Python and I know that what counts in life is not the words we say, the lines of our code, nor the time we spend at the office. We know that it is the completed tasks that count. We will complete them... My Python is human, even as I'm human, because it is my Python. Thus, I will learn it as a brother. I will learn its weaknesses, its strength, its parts and accessories, its standard library and its infrastructure. I will keep my Python from dangerous misunderstanding or suboptimal use, even as I do my legs and arms, my eyes and heart from any harm. I will keep my Python clean and ready. We will become part of each other. So be it.”


r/Python • • Jan 24 '19

Simulated herbivores and carnivores on an island using Python

1.5k Upvotes

r/Python • • Dec 31 '19

Today is the last day of Python 2 support!

1.5k Upvotes

r/Python • • Apr 01 '17

Python Helped me Write Again

1.5k Upvotes

A letter in my own handwriting.

I learned Python in 1998, and I used it pretty much daily through my working life. Its connectivity with everything has allowed me to do all kinds of interesting and fun things. When I discovered that the AxiDraw pen plotter has a Python binding, I decided to try writing in my own handwriting with my own pen. Something I've been unable to do for years.

It has taken a lot, mostly because I can't type, so I've been limited to voice recognition and copy and paste, but the letter linked above is where I got to this evening.

I thought I would share my mini triumph.

I've learned and programmed in a lot of different languages over the years. I have written several languages myself. And even though Python wasn't my first language, it is the first language I consider for any new project. I'd have to have a compelling reason to use something else. So thank you, Python, for making this possible.

</ shameless preaching to the choir> ;)


Edit: In the comments a couple of people asked for a video. I will make a proper video with the AxiDraw as soon as I can. We just did a quick test on my wife's Cricut craft cutter. It works there too, though you can't tilt the pen or change the pressure. So apologies it's not the proper plotter, but you can see how the paths are traced on this video.


r/Python • • Mar 28 '20

I Made This I made a python script to download and save your favorite Facebook videos.

1.5k Upvotes

r/Python • • Mar 05 '25

Discussion Petition to rename Python 3.14 to Pithon!

1.5k Upvotes

Is this a dumb joke? Yes. Is this the only shot we'll have at a joke like this? Yes. And is this a great way to celebrate what Pi's done for us Python developers? Totally.

I mean Python is heavily built around the magic number we know as 3.14, from games, charts and music, to even just screwing around with arithmetic functions! So why not appreciate pi's work with a special Python version?

The petition can be found here:
https://www.change.org/p/rename-python-3-14-to-pithon

Please sign it and share when you can!

Edit: yeah, renaming it just for v3.14 is probably a bad thought, but i mean it would still be funny as a nickname!


r/Python • • Jul 01 '20

Resource My Python regex ebook with hundreds of examples and exercises is currently free

1.4k Upvotes

Hello!

I finally published my updated version of Python regular expressions ebook. My initial motivation was to add epub format and separate out third-party regex module content into a separate chapter. An email exchange with a reader, a look at feedback from the past year and my own improvements as a writer resulted in a significant overhaul. It took me about 6 weeks to complete the revision instead of 1-2 weeks that I estimated. Sounds familiar right? I’m definitely pleased with the changes, but along the way I added a long list of TODOs that will probably need months of work. Future me is not going to be pleased.

To get pdf/epub versions, use any of these links:

As a bundle (Python/Ruby/JS regex and grep/sed/awk cli tools):

I made all my books free at the end of March when the pandemic hit my country. The virus doesn’t seem to be going away anytime soon, so I’ll probably start charging again after I finish updating the Ruby and JS regex books. You can still pay if you wish.

You can read the entire book from the GitHub repo - https://github.com/learnbyexample/py_regular_expressions. The repo also contains the code snippets used in the book and a handy way to access all the exercises in a single file. You can also find the solutions there.

Edit (Aug 2020): Web version of the book - https://learnbyexample.github.io/py_regular_expressions/

I’d highly appreciate your feedback. That’s been a major motivating factor to keep writing as well as for improving the content.

Happy learning :)


r/Python • • Mar 20 '20

I Made This Made a fluid simulation for my engineering exams

1.4k Upvotes

r/Python • • Jan 12 '21

Resource Learn something new about Python every day in less than 1 minute

1.4k Upvotes

I'm running a channel, where I am publishing a Python mini-tutorial every day. I thought some of you might find it useful:

https://www.youtube.com/c/PythonIn1Minute/videos

I try to keep it beginner-friendly, my goal is to teach something useful or show a neat trick or solve a common pain-point in under 60 seconds.

I am quite new to this youtube thing, so I'd love to hear your feedback. Is this kind of thing a good idea? Do you find it helpful? Any suggestions on what could be improved?

Edit: I am overwhelmed by the amount of positive and constructive feedback, you guys are awesome, thank you so much! You gave me a lot of great ideas, and the motivation to keep creating videos.

Edit2: If you can afford it and you wish to support my work you can buy me a coffee or become a patron.