Home Cd software Programming languages: this major update for Python has just arrived

Programming languages: this major update for Python has just arrived



Python, the most popular programming language today, has reached version 3.10, marking the next major release since the decade-long transition from Python 2.7.

Tiobe, the language popularity index compiler, this week crowned Python as the most popular programming language, placing it ahead of Java, C and JavaScript for the first time in 20 years. The appeal of Python, a 30-year-old language, is that it’s easy to learn, popular for machine learning, and supported by a large ecosystem of third-party software libraries that make it more useful in artificial intelligence, like TensorFlow from Google and Facebook’s PyTorch.

Python 3.10 is the successor to Python 3.9 and has been in the works for over a year as leading Python (CPython) developers continued to work on backward compatibility. CPython is the primary implementation of Python, upon which other data science-driven distributions like Anaconda are built.

“Python 3.10.0 is the last major version of the Python programming language, and it contains many new features and enhancements,” CPython maintainers announced in blog post.

SEE: Programming languages: Python just took a big step forward

The upgrade includes dozens of additions known as Python Improvement Proposals (PEP). One of the main features is “structural pattern matching” in Python 3.10 – a data processing technique already available in C, Java, JavaScript, Scala, and Elixir.

“Structural model mapping has been added in the form of a correspondence statement and model case statements with associated actions. Models consist of sequences, mappings, primitive data types as well as Class instances. Pattern matching allows programs to extract information from complex data types, plug into the data structure, and apply specific actions based on different forms of data, ” the project explains in the notes of version 3.10.

“While structural pattern matching can be used in its simplest form to compare a variable to a literal in a case statement, its real value to Python lies in its handling of the subject type and form,” adds. he does.

Major Python contributors introduced the update in a see you this week. Pablo Galindo Salgado, physicist and lead contributor to Python, explained how the project uses Microsoft’s GitHub Actions DevOps (CI / CD) tools to test Python changes on Windows, Linux, and macOS systems.

“When you merge something with Python, there is a CI in GitHub Actions and we have other providers although we mainly use GitHub Actions now. It tests your commits on every commit on Linux, Windows and macOS,” said Salgado.

“We know that Python works on more platforms, things like FreeBSD, PowerPC and other architectures instead of Intel, like Arm chips or [Apple’s] M1. There are a lot of different architectures, ”he says.

“So once the commit lands in the master branch, there are a lot of machines called ‘bulletin boards’ that test commits… some of which test CPython in normal mode.”

“There are also tests of display panels in special configurations such as checking for invalid memory addresses using Clang and CCG disinfectants or race conditions, which break all the time because those checks aren’t run on every comment as they normally take hours. “

SEE: Developers wanted: companies are hiring and these are the skills they are looking for

The group also noted that PEP 563 was supposed to arrive but was postponed after debate at the Python Language Summit 2020 in April. The problem was the support of the proposal by third party software libraries and an associated PEP 649.

“It is possible that third-party libraries and users did not plan to respond within the current timeframe because they were not aware of this change in schedule,” the Python Steering Council wrote.

“There isn’t enough time to properly discuss PEP 649 or any of the alternatives before the beta 1 deadline, and we really need to make sure that we don’t make the errors worse here. long-term solution, which is not possible while meeting the Python 3.10 release timelines, which means we are defering PEP 649 to Python 3.11 as well.

SEE: Another reason developers give up: to escape your bad code

Language creator Guido van Rossum assures us that the switch to Python 4.0 – if and when it does happen – won’t be as traumatic as the decade-long switch from Python 2 to Python 3.

“If ever there is a version 4, the passage from 3 to 4 will look more like that from 1 to 2 rather than from 2 to 3”, he noted last year, adding that “we still have 2-3 PTSD.”

Van Rossum announced Python 3 13 years ago, but the project did not stop supporting Python 2 until last April due to the amount of legacy code that would have been broken by upgrading to 3. Today , he is employed as a Distinguished Engineer at Microsoft where he works to improve the performance of the language, which currently limits it to high-end hardware and prevents it from accessing mobile devices and browsers.



Please enter your comment!
Please enter your name here