파이썬(Python)

파이썬 3.6

파이썬 3.6은 페도라 26에서 기본설정 파이썬 3 스택이 됩니다. 이는 페도라 25에서 포함된 3.5에서 향상된 것입니다. 파이썬 3에서 의존하는 모든 꾸러미는 다시 제작해야 합니다. 사용자-작성 파이썬 3 스크립트와 응용 프로그램에는 약간의 이식이 필요 할 수도 있습니다; 아무튼, 파이썬 3.5는 대부분 파이썬 3.6과 호환됩니다.

주목 할만한 새로운 기능은 다음을 포함합니다:

  • Formatted string literals (f-strings): f"This will be evaluated to foo’s value: {foo}"

  • The order of elements in **kwargs: keyword arguments now preserve their order

  • The new secrets module provides handy helpers for secure token generation in various formats

  • Underscores in numeric literals let you break up magic constants to make them easier to read: 1_000_000

  • File system path protocol: Many more standard library APIs, including the builtin open(), now support pathlib.Path and pathlib.PurePath objects

  • A range of performance improvements.

For more detailed information see the Fedora Magazine announcement article or the upstream release notes. Note the Porting to Python 3.6 section, which lists important information for developers who need to port their Python 3.5 applications.

파이썬 학급 랩

Fedora 26 brings in a new Python Classroom Lab. A variant of Fedora targeted at teachers and students of the Python programming langugae. A ready to use environment with Python, PyPy 3, virtualenv, tox, git, Jupyter Notebook and more. It’s ready in three variants: as a GNOME powered desktop or headless for Vagrant and Docker.

Find out more about the Python Classroom Lab on the Fedora Labs website.

Python 3 C.UTF-8 locale

An ongoing challenge within the Python 3 series has been determining a sensible default strategy for handling the “7-bit ASCII” text encoding assumption currently implied by the use of the default C locale.

Starting with Fedora 26, the Fedora system Python includes a backport of Python 3.7’s upcoming locale coercion feature, which means the Python 3 stack will automatically coerce the C locale to C.UTF-8 by setting the LC_CTYPE environment variable (if neither it nor LC_ALL are already set) before configuring the process locale. Automatically setting LC_CTYPE this way means that both the core interpreter and locale-aware C extensions (such as readline) will assume the use of UTF-8 as the default text encoding, rather than ASCII.

Full details of this new Python feature are contained in PEP 538 — Coercing the legacy C locale to a UTF-8 based local.