PyCharm: PyCharm 2022.2: Support for Python 3.11, Improved HTTP Client, and UX Enhancements :
by:
blow post content copied from Planet Python
click here to view original post
Working with new and rapidly evolving technologies can be challenging as you often find yourself reading documentation and getting used to new syntax, APIs, and protocols. PyCharm 2022.2 will help you in this journey by providing support for Python 3.11 language features and the new PyScript framework.
Let’s look at what’s inside!
You can download the new version from our website, update directly from the IDE, update via the free Toolbox App, or use snaps for Ubuntu.
Python 3.11
PyCharm 2022.2 is already equipped with code insight for some major Python 3.11 features, such as exception groups and the except* operator (PEP 654), and the new Required[]and NotRequired[]notations for individual TypedDict keys (PEP 655).
exception groups and except* operator Required[ ] and NotRequired[ ] notationsHTTP Client
PyCharm 2022.2 supports WebSocket connections. With this API, you can send messages to a server and receive event-driven responses without having to poll the server for a reply. PyCharm can now send queries over HTTP and WebSocket protocols out of the box. ws:// and wss:// are now delegated to the WebSocket executor.
In addition, there’s an easier way to select a run environment – by using an icon on the gutter. To enable this feature, choose the Select Environment Before Run option from the Run with combo box.
A new UI for setting up remote interpreters
PyCharm 2022.2 introduces a new wizard for setting up interpreters at remote targets (such as WSL, SSH, Docker, Docker Compose, or Vagrant). It makes the setup process more structured and easy to follow. To access the new wizard, go to Settings | Preferences / Python Interpreter and click the Add Interpreter link in the top right-hand corner of the window, or click on the interpreter in the bottom right-hand corner of the editor and select Add New Interpreter.
Run current file
To instantly run and debug a single file without a dedicated run configuration, use Run Current File, which is available from the Run/Debug widget. It features a secondary menu that offers applicable runners along with the Run with Parameters action, which lets you tune the run configuration parameters before running the file.
Initial support for PyScript
PyScript is a framework for creating rich Python applications in the browser using an HTML interface and the power of Pyodide, WASM, and modern web technologies.
The <py-script> tag lets you execute multiline Python scripts and interact with the page. PyCharm 2022.2 recognizes Python syntax, including NumPy and Matplotlib libraries, for code inside <py-script> tags in HTML files and provides proper code completion and highlighting for it.
Code completion and syntax highlighting are now available for PyScript tags such as <py-env> for declaring dependencies and <py-repl> for creating REPL components.
Jupyter Notebooks
PyCharm 2022.2 enhances your user experience with Jupyter notebooks. You can now cut, copy, and paste cells more easily by using the corresponding buttons and icons in the Jupyter editor toolbar.
You can also resize image outputs by simply dragging the output’s bottom border. This should improve the readability of such outputs.
Database management
PyCharm 2022.2 lets you import multiple CSVs into new or existing database tables. To do so, select multiple files in the Project View and drag them to a database schema.
There are two resolve modes for your SQL scripts in PyCharm 2022.2. In Playground mode, objects are resolved according to the context. It is now the default for query consoles. In Script mode, the beginning of the file is resolved to the context, but any SET CURRENT SCHEMA statements in the script change the context for the resolve. Script mode is now the default for local files. To switch between the modes, just use the drop-down on the toolbar.
Docker
You can now easily copy images from one Docker daemon to another using the new Copy Docker Image action that saves the image to a file and then pushes it to the chosen connection. PyCharm also integrates with Colima and Racher to support more options for establishing connections to a Docker daemon.
In addition, PyCharm 2022.2 automatically connects to Docker after you restart the IDE. This new setting is enabled by default and can be switched in Settings / Preferences | Advanced Settings | Docker.
These are the most notable new features and usability improvements available in this release. For more details, visit the What’s New in PyCharm web page or read the release notes.
We are looking forward to your feedback in the comments below, our issue tracker, or on Twitter.
The PyCharm team
July 28, 2022 at 06:17PM
Click here for more details...
=============================
The original post is available in Planet Python by
this post has been published as it is through automation. Automation script brings all the top bloggers post under a single umbrella.
The purpose of this blog, Follow the top Salesforce bloggers and collect all blogs in a single place through automation.
============================
Post a Comment