Python Development

-
Custom PyQt5/PySide2 PasswordEdit field with Show/Hide toggle
When building applications which require a password (or some other secret) from a user you should use fields that hide the input. This prevents shoulder surfing passers by from being able to read off the user's secret and gain access to accounts.
-
Consistent Onboarding - Building SaaS #52
In this episode, we glued together some of the onboarding steps. I added data validation so that future steps depend on data existing from previous steps. Then we added page messaging to direct users to a proper page.
We reviewed the way that the form validates certain data from the form submission so that data is kept safe between users. I showed how I switched from the model and fields attributes of CreateView to a form_class containing the form that does the necessary validation.
-
How to port 100,000 lines of Python 2 to Python 3
Last summer I led the conversion of a 77KLOC Python 2 web application to Python 3, and that was my guide.
First, we did the Stage 1 conversion, which makes the whole codebase compatible with Python 2 and Python 3. As the docs say, “the goal for this stage is to create most of the diff for the entire porting process, but without introducing any bugs.”
(Note that this doesn’t mean the result works in Python 3; it probably won’t. But syntax and library issues are taken care of, and nothing is broken for Python 2.)
Then we did Stage 2; the end result of that is “Python 3-style code that [also] runs on Python 2 with the help of the appropriate builtins and utilities in future.”
-
Python Docstrings
In this tutorial, we will learn about Python docstrings. More specifically, we will learn how and why docstrings are used with the help of examples.
Python docstrings are the string literals that appear right after the definition of a function, method, class, or module. Let's take an example.
-
Stefan Behnel: My responses to a Cython dev interview
I recently received a request for an online interview by Jonathan Ruiz, a CS student in Berlin. He's implementing graph algorithms as part of his final Bachelor thesis, and was evaluating and using Cython to get performance improvements. During his work, he thought it'd be nice to get some comments from a Cython core dev and sent me a couple of questions. Here's what I answered.
-

- Login or register to post comments
Printer-friendly version- 2037 reads
PDF version
More in Tux Machines
- Highlights
- Front Page
- Latest Headlines
- Archive
- Recent comments
- All-Time Popular Stories
- Hot Topics
- New Members
digiKam 7.7.0 is released
After three months of active maintenance and another bug triage, the digiKam team is proud to present version 7.7.0 of its open source digital photo manager. See below the list of most important features coming with this release.
|
Dilution and Misuse of the "Linux" Brand
|
Samsung, Red Hat to Work on Linux Drivers for Future Tech
The metaverse is expected to uproot system design as we know it, and Samsung is one of many hardware vendors re-imagining data center infrastructure in preparation for a parallel 3D world.
Samsung is working on new memory technologies that provide faster bandwidth inside hardware for data to travel between CPUs, storage and other computing resources. The company also announced it was partnering with Red Hat to ensure these technologies have Linux compatibility.
|
today's howtos
|








.svg_.png)
Content (where original) is available under CC-BY-SA, copyrighted by original author/s.

Recent comments
1 year 11 weeks ago
1 year 11 weeks ago
1 year 11 weeks ago
1 year 11 weeks ago
1 year 11 weeks ago
1 year 11 weeks ago
1 year 11 weeks ago
1 year 11 weeks ago
1 year 11 weeks ago
1 year 11 weeks ago