{"id":348463,"date":"2023-06-07T15:09:26","date_gmt":"2023-06-07T15:09:26","guid":{"rendered":"http:\/\/savepearlharbor.com\/?p=348463"},"modified":"-0001-11-30T00:00:00","modified_gmt":"-0001-11-29T21:00:00","slug":"","status":"publish","type":"post","link":"https:\/\/savepearlharbor.com\/?p=348463","title":{"rendered":"<span>Poetry: from zero to hero<\/span>"},"content":{"rendered":"<div><\/div>\n<div id=\"post-content-body\">\n<div>\n<div class=\"article-formatted-body article-formatted-body article-formatted-body_version-2\">\n<p>\u041f\u0440\u0438\u0432\u0435\u0442, \u0425\u0430\u0431\u0440! \u041c\u0435\u043d\u044f \u0437\u043e\u0432\u0443\u0442 \u0422\u0438\u043c\u0443\u0440, \u044f \u0442\u0440\u0443\u0436\u0443\u0441\u044c ML-\u0438\u043d\u0436\u0435\u043d\u0435\u0440\u043e\u043c \u0432 \u043e\u0434\u043d\u043e\u0439 \u0441\u0438\u0431\u0438\u0440\u0441\u043a\u043e\u0439 IT-\u043a\u043e\u043c\u043f\u0430\u043d\u0438\u0438.<\/p>\n<p>\u0414\u0430\u043d\u043d\u0430\u044f \u0441\u0442\u0430\u0442\u044c\u044f \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u044f\u0435\u0442 \u0441\u043e\u0431\u043e\u0439 \u0440\u0443\u043a\u043e\u0432\u043e\u0434\u0441\u0442\u0432\u043e \u043f\u043e Poetry. \u042f \u043f\u043e\u0441\u0442\u0430\u0440\u0430\u043b\u0441\u044f \u043f\u043e\u043a\u0440\u044b\u0442\u044c \u0432\u0441\u0435 \u043e\u0441\u043d\u043e\u0432\u043d\u044b\u0435 \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0438 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u044f \u0438 \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e\u0441\u0442\u0438 \u0434\u0430\u043d\u043d\u043e\u0433\u043e \u0438\u043d\u0441\u0442\u0440\u0443\u043c\u0435\u043d\u0442\u0430: \u0441\u043e\u0437\u0434\u0430\u043d\u0438\u0435 \u043f\u0440\u043e\u0435\u043a\u0442\u0430, \u0440\u0430\u0431\u043e\u0442\u0430 \u0441 \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u044f\u043c\u0438 \u0438\u0437 \u0440\u0430\u0437\u043b\u0438\u0447\u043d\u044b\u0445 \u0438\u0441\u0442\u043e\u0447\u043d\u0438\u043a\u043e\u0432, \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u0435 \u0432\u0438\u0440\u0442\u0443\u0430\u043b\u044c\u043d\u044b\u043c\u0438 \u043e\u043a\u0440\u0443\u0436\u0435\u043d\u0438\u044f\u043c\u0438, \u0441\u0431\u043e\u0440\u043a\u0430 \u0438 \u043f\u0443\u0431\u043b\u0438\u043a\u0430\u0446\u0438\u044f.<\/p>\n<p>\u0412 \u043a\u0430\u0447\u0435\u0441\u0442\u0432\u0435 \u0431\u043e\u043d\u0443\u0441\u043e\u0432 &#8212; \u0433\u043e\u0442\u043e\u0432\u0430\u044f GitLab CI \u0434\u0436\u043e\u0431\u0430 \u0434\u043b\u044f \u0441\u0431\u043e\u0440\u043a\u0438 \u0438 \u043f\u0443\u0431\u043b\u0438\u043a\u0430\u0446\u0438\u0438 \u043f\u0430\u043a\u0435\u0442\u043e\u0432, \u0430 \u0442\u0430\u043a\u0436\u0435 \u0448\u0430\u0431\u043b\u043e\u043d Dockerfile \u0434\u043b\u044f multi-stage \u0441\u0431\u043e\u0440\u043a\u0438 \u043e\u0431\u0440\u0430\u0437\u043e\u0432 \u0432 \u043f\u0440\u043e\u0435\u043a\u0442\u0430\u0445 \u0441 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435\u043c Poetry.<\/p>\n<p>\u0414\u043e\u0431\u0440\u043e \u043f\u043e\u0436\u0430\u043b\u043e\u0432\u0430\u0442\u044c \u043f\u043e\u0434 \u043a\u0430\u0442!<\/p>\n<h2>\u0427\u0442\u043e \u0442\u0430\u043a\u043e\u0435 Poetry?<\/h2>\n<p>Poetry &#8212; \u044d\u0442\u043e \u0438\u043d\u0441\u0442\u0440\u0443\u043c\u0435\u043d\u0442 \u0434\u043b\u044f \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u044f \u043f\u0440\u043e\u0435\u043a\u0442\u0430\u043c\u0438 \u043d\u0430 Python, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043f\u0440\u0435\u0434\u043e\u0441\u0442\u0430\u0432\u043b\u044f\u0435\u0442 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u0435 \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e\u0441\u0442\u0438:<\/p>\n<ul>\n<li>\n<p>\u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u0435 \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u044f\u043c\u0438 \u0441 \u0432\u043e\u0441\u043f\u0440\u043e\u0438\u0437\u0432\u043e\u0434\u0438\u043c\u044b\u043c\u0438 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0430\u043c\u0438 \u0438 \u0440\u0435\u0437\u043e\u043b\u0432\u0435\u0440\u043e\u043c \u043a\u043e\u043d\u0444\u043b\u0438\u043a\u0442\u043e\u0432<\/p>\n<\/li>\n<li>\n<p>\u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u043e\u0435 \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u0435 \u0432\u0438\u0440\u0442\u0443\u0430\u043b\u044c\u043d\u044b\u043c\u0438 \u043e\u043a\u0440\u0443\u0436\u0435\u043d\u0438\u044f\u043c\u0438<\/p>\n<\/li>\n<li>\n<p>\u0441\u0431\u043e\u0440\u043a\u0430 \u0438 \u043f\u0443\u0431\u043b\u0438\u043a\u0430\u0446\u0438\u044f.<\/p>\n<\/li>\n<\/ul>\n<h2>\u0423\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0430<\/h2>\n<p>\u0423\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0430 Poetry \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0435\u0442\u0441\u044f \u043e\u0447\u0435\u043d\u044c \u043f\u0440\u043e\u0441\u0442\u043e \u043a\u0430\u043a \u043d\u0430 Unix-\u0441\u0438\u0441\u0442\u0435\u043c\u0430\u0445:<\/p>\n<pre><code class=\"bash\">curl -sSL https:\/\/install.python-poetry.org | python3 -<\/code><\/pre>\n<p>\u0422\u0430\u043a \u0438 \u043d\u0430 Windows:<\/p>\n<pre><code class=\"bash\">(Invoke-WebRequest -Uri https:\/\/install.python-poetry.org -UseBasicParsing).Content | py -<\/code><\/pre>\n<p>\u0414\u0430\u043b\u0435\u0435, \u0432 \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u0438 \u043e\u0442 \u0432\u0430\u0448\u0435\u0439 \u0441\u0438\u0441\u0442\u0435\u043c\u044b, \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u0434\u043e\u0431\u0430\u0432\u0438\u0442\u044c \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0443\u044e\u0449\u0443\u044e \u0434\u0438\u0440\u0435\u043a\u0442\u043e\u0440\u0438\u044e \u0432 PATH:<\/p>\n<pre><code class=\"bash\"># Linux, MacOS, WSL $HOME\/.local\/bin    # Windows %APPDATA%\\Python\\Scripts<\/code><\/pre>\n<p>\u041f\u0435\u0440\u0435\u0437\u0430\u0433\u0440\u0443\u0436\u0430\u0435\u043c \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0443 \u0438 \u043f\u0440\u043e\u0432\u0435\u0440\u044f\u0435\u043c \u043a\u043e\u0440\u0440\u0435\u043a\u0442\u043d\u043e\u0441\u0442\u044c \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0438:<\/p>\n<pre><code class=\"bash\">poetry --version   # \u0412\u044b\u0432\u043e\u0434 \u0434\u043e\u043b\u0436\u0435\u043d \u0431\u044b\u0442\u044c \u043f\u0440\u0438\u043c\u0435\u0440\u043d\u043e \u0442\u0430\u043a\u0438\u043c # Poetry (version 1.4.2)<\/code><\/pre>\n<h2>\u0418\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435<\/h2>\n<h3>\u0421\u043e\u0437\u0434\u0430\u043d\u0438\u0435 \u043f\u0440\u043e\u0435\u043a\u0442\u0430<\/h3>\n<h4>\u041a\u0430\u043a \u0441\u043e\u0437\u0434\u0430\u0442\u044c \u043f\u0440\u043e\u0435\u043a\u0442 \u0447\u0435\u0440\u0435\u0437 \u0442\u0435\u0440\u043c\u0438\u043d\u0430\u043b<\/h4>\n<p>\u0414\u043b\u044f \u0441\u043e\u0437\u0434\u0430\u043d\u0438\u044f \u043f\u0440\u043e\u0435\u043a\u0442\u0430 \u0441 \u043d\u0443\u043b\u044f \u0432\u043e\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u043c\u0441\u044f \u043a\u043e\u043c\u0430\u043d\u0434\u043e\u0439&nbsp;<strong>new<\/strong>:<\/p>\n<pre><code class=\"bash\">poetry new my-project<\/code><\/pre>\n<p>\u041f\u0440\u0438 \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u0438 \u044d\u0442\u043e\u0439 \u043a\u043e\u043c\u0430\u043d\u0434\u044b Poetry \u0441\u043e\u0437\u0434\u0430\u0441\u0442 \u043f\u0430\u043f\u043a\u0443 \u0441\u043e \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0435\u0439 \u0441\u0442\u0440\u0443\u043a\u0442\u0443\u0440\u043e\u0439. \u041d\u0430\u0438\u0431\u043e\u043b\u0435\u0435 \u0438\u043d\u0442\u0435\u0440\u0435\u0441\u0435\u043d \u0437\u0434\u0435\u0441\u044c \u0444\u0430\u0439\u043b&nbsp;<strong>pyproject.toml<\/strong>, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043c\u044b \u0440\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0438\u043c \u0432 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0435\u0439 \u0441\u0435\u043a\u0446\u0438\u0438:<\/p>\n<pre><code class=\"bash\">my-project\/ \u251c\u2500\u2500 README.md \u251c\u2500\u2500 my_project \u2502   \u2514\u2500\u2500 __init__.py \u251c\u2500\u2500 pyproject.toml \u2514\u2500\u2500 tests     \u2514\u2500\u2500 __init__.py   2 directories, 4 files<\/code><\/pre>\n<p>\u0415\u0441\u043b\u0438 \u0436\u0435 \u043c\u044b \u0445\u043e\u0442\u0438\u043c \u043d\u0430\u0447\u0430\u0442\u044c \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c Poetry \u0432 \u0443\u0436\u0435 \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u044e\u0449\u0435\u043c \u043f\u0440\u043e\u0435\u043a\u0442\u0435, \u0442\u043e \u043d\u0430\u043c \u043f\u043e\u043c\u043e\u0436\u0435\u0442 \u043a\u043e\u043c\u0430\u043d\u0434\u0430&nbsp;<strong>init<\/strong>:<\/p>\n<pre><code class=\"bash\">cd my-project2 poetry init<\/code><\/pre>\n<p>\u0414\u0430\u043b\u0435\u0435, Poetry \u0437\u0430\u0434\u0430\u0441\u0442 \u043d\u0430\u043c \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u0432\u043e\u043f\u0440\u043e\u0441\u043e\u0432 \u043e \u043d\u0430\u0448\u0435\u043c \u043f\u0440\u043e\u0435\u043a\u0442\u0435 (\u0438\u043c\u044f \u043f\u0430\u043a\u0435\u0442\u0430, \u0432\u0435\u0440\u0441\u0438\u044f, \u043e\u043f\u0438\u0441\u0430\u043d\u0438\u0435, \u043b\u0438\u0446\u0435\u043d\u0437\u0438\u044f \u0438 \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u0438\u0432\u0430\u0435\u043c\u044b\u0435 \u0432\u0435\u0440\u0441\u0438\u0438 Python), \u0430 \u0442\u0430\u043a\u0436\u0435 \u043f\u0440\u0435\u0434\u043b\u043e\u0436\u0438\u0442 \u0432 \u0438\u043d\u0442\u0435\u0440\u0430\u043a\u0442\u0438\u0432\u043d\u043e\u043c \u0440\u0435\u0436\u0438\u043c\u0435 \u0443\u043a\u0430\u0437\u0430\u0442\u044c \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u0438 (\u0447\u0442\u043e, \u043a\u0430\u043a \u043f\u043e \u043c\u043d\u0435, \u043d\u0435 \u043e\u0447\u0435\u043d\u044c \u0443\u0434\u043e\u0431\u043d\u043e):<\/p>\n<pre><code class=\"bash\">This command will guide you through creating your pyproject.toml config.   Package name [my-project2]:  Version [0.1.0]:  Description []:  My Project, but second    Author [None, n to skip]:  Timur Kasimov License []:  MIT Compatible Python versions [^3.8]:    Would you like to define your main dependencies interactively? (yes\/no) [yes] no Would you like to define your development dependencies interactively? (yes\/no) [yes] no Generated file   [tool.poetry] name = \"my-project2\" version = \"0.1.0\" description = \"My Project, but second\" authors = [\"Timur Kasimov\"] license = \"MIT\" readme = \"README.md\" packages = [{include = \"my_project2\"}]   [tool.poetry.dependencies] python = \"^3.8\"     [build-system] requires = [\"poetry-core\"] build-backend = \"poetry.core.masonry.api\"     Do you confirm generation? (yes\/no) [yes] yes<\/code><\/pre>\n<h4>\u041f\u043e\u0434\u0433\u043e\u0442\u043e\u0432\u043a\u0430 \u0432\u0438\u0440\u0442\u0443\u0430\u043b\u044c\u043d\u043e\u0433\u043e \u043e\u043a\u0440\u0443\u0436\u0435\u043d\u0438\u044f<\/h4>\n<p>\u041a\u043e\u043c\u0430\u043d\u0434\u044b&nbsp;<strong>new<\/strong>&nbsp;\u0438&nbsp;<strong>init<\/strong>&nbsp;\u043d\u0435 \u0441\u043e\u0437\u0434\u0430\u044e\u0442 \u0432\u0438\u0440\u0442\u0443\u0430\u043b\u044c\u043d\u044b\u0445 \u043e\u043a\u0440\u0443\u0436\u0435\u043d\u0438\u0439. \u041f\u0440\u0438 \u043f\u0435\u0440\u0432\u043e\u043c \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u0438 \u043a\u043e\u043c\u0430\u043d\u0434, \u0441\u0432\u044f\u0437\u0430\u043d\u043d\u044b\u0445 \u0441 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u043e\u0439 \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u0435\u0439, Poetry \u0441\u043e\u0437\u0434\u0430\u0435\u0442 \u0432\u0438\u0440\u0442\u0443\u0430\u043b\u044c\u043d\u043e\u0435 \u043e\u043a\u0440\u0443\u0436\u0435\u043d\u0438\u0435, \u0432\u044b\u0431\u0440\u0430\u0432 \u0431\u0430\u0437\u043e\u0432\u044b\u0439 \u0438\u043d\u0442\u0435\u0440\u043f\u0440\u0435\u0442\u0430\u0442\u043e\u0440 \u043f\u043e \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0435\u0439 \u043b\u043e\u0433\u0438\u043a\u0435:<\/p>\n<ol>\n<li>\n<p>Poetry \u043f\u0440\u043e\u0432\u0435\u0440\u044f\u0435\u0442, \u0430\u043a\u0442\u0438\u0432\u0438\u0440\u043e\u0432\u0430\u043d\u043e \u043b\u0438 \u0443\u0436\u0435 \u043a\u0430\u043a\u043e\u0435-\u0442\u043e \u0432\u0438\u0440\u0442\u0443\u0430\u043b\u044c\u043d\u043e\u0435 \u043e\u043a\u0440\u0443\u0436\u0435\u043d\u0438\u0435. \u0415\u0441\u043b\u0438 \u0434\u0430, \u0442\u043e \u043e\u043d\u043e \u0431\u0443\u0434\u0435\u0442 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u043e<\/p>\n<\/li>\n<li>\n<p>\u0415\u0441\u043b\u0438 \u043d\u0438\u043a\u0430\u043a\u043e\u0435 \u0432\u0438\u0440\u0442\u0443\u0430\u043b\u044c\u043d\u043e\u0435 \u043e\u043a\u0440\u0443\u0436\u0435\u043d\u0438\u0435 \u043d\u0435 \u0430\u043a\u0442\u0438\u0432\u0438\u0440\u043e\u0432\u0430\u043d\u043e, \u0442\u043e Poetry \u043f\u043e\u043f\u044b\u0442\u0430\u0435\u0442\u0441\u044f \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c Python, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0431\u044b\u043b \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d \u043f\u0440\u0438 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0435 Poetry<\/p>\n<\/li>\n<li>\n<p>\u0415\u0441\u043b\u0438 \u0432\u0435\u0440\u0441\u0438\u044f Python \u0441 \u043f\u0440\u0435\u0434\u044b\u0434\u0443\u0449\u0435\u0433\u043e \u0448\u0430\u0433\u0430 \u043d\u0435\u0441\u043e\u0432\u043c\u0435\u0441\u0442\u0438\u043c\u0430 \u0441 \u0432\u0435\u0440\u0441\u0438\u0435\u0439, \u0443\u043a\u0430\u0437\u0430\u043d\u043d\u043e\u0439 \u0432&nbsp;<strong>pyproject.toml<\/strong>, \u0442\u043e Poetry \u043f\u043e\u043f\u0440\u043e\u0441\u0438\u0442 \u044f\u0432\u043d\u043e \u0430\u043a\u0442\u0438\u0432\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u043d\u0443\u0436\u043d\u0443\u044e \u0432\u0435\u0440\u0441\u0438\u044e<\/p>\n<\/li>\n<\/ol>\n<p>\u0421\u043e\u0432\u0435\u0442\u0443\u044e \u0441\u0440\u0430\u0437\u0443 \u0443\u043a\u0430\u0437\u0430\u0442\u044c \u043a\u043e\u0440\u0440\u0435\u043a\u0442\u043d\u044b\u0439 \u0431\u0430\u0437\u043e\u0432\u044b\u0439 \u0438\u043d\u0442\u0435\u0440\u043f\u0440\u0435\u0442\u0430\u0442\u043e\u0440, \u0432\u044b\u043f\u043e\u043b\u043d\u0438\u0432 \u0432 \u043f\u0430\u043f\u043a\u0435 \u043f\u0440\u043e\u0435\u043a\u0442\u0430 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0443\u044e \u043a\u043e\u043c\u0430\u043d\u0434\u0443:<\/p>\n<pre><code class=\"bash\">poetry env use python3.8  # \u0415\u0441\u043b\u0438 python3.8 \u0435\u0441\u0442\u044c \u0432 PATH poetry env use \/path\/to\/python  # \u041c\u043e\u0436\u043d\u043e \u0443\u043a\u0430\u0437\u0430\u0442\u044c \u0438 \u043f\u043e\u043b\u043d\u044b\u0439 \u043f\u0443\u0442\u044c<\/code><\/pre>\n<p>\u0415\u0441\u043b\u0438 \u0432\u044b \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0435 pyenv, \u043c\u043e\u0436\u043d\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u044d\u043a\u0441\u043f\u0435\u0440\u0438\u043c\u0435\u043d\u0442\u0430\u043b\u044c\u043d\u0443\u044e \u0444\u0438\u0447\u0443 Poetry:<\/p>\n<pre><code class=\"bash\">poetry config virtualenvs.prefer-active-python true pyenv install 3.9.8 pyenv local 3.9.8<\/code><\/pre>\n<p>\u041f\u043e \u0443\u043c\u043e\u043b\u0447\u0430\u043d\u0438\u044e, Poetry \u0441\u043e\u0437\u0434\u0430\u0435\u0442 \u0432\u0438\u0440\u0442\u0443\u0430\u043b\u044c\u043d\u044b\u0435 \u043e\u043a\u0440\u0443\u0436\u0435\u043d\u0438\u044f \u0432 \u043f\u0430\u043f\u043a\u0435&nbsp;<strong>{cache_dir}\/virtualenvs<\/strong>. \u0415\u0441\u043b\u0438 \u0432\u044b \u0445\u043e\u0442\u0438\u0442\u0435, \u0447\u0442\u043e\u0431\u044b \u0432\u0438\u0440\u0442\u0443\u0430\u043b\u044c\u043d\u043e\u0435 \u043e\u043a\u0440\u0443\u0436\u0435\u043d\u0438\u0435 \u043d\u0430\u0445\u043e\u0434\u0438\u043b\u043e\u0441\u044c \u0432 \u043f\u0430\u043f\u043a\u0435 \u043f\u0440\u043e\u0435\u043a\u0442\u0430, \u043c\u043e\u0436\u043d\u043e \u0432\u044b\u043f\u043e\u043b\u043d\u0438\u0442\u044c \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0443\u044e \u043a\u043e\u043c\u0430\u043d\u0434\u0443:<\/p>\n<pre><code class=\"bash\">poetry config virtualenvs.in-project true<\/code><\/pre>\n<p>\u0422\u0435\u043f\u0435\u0440\u044c \u0441\u043e\u0437\u0434\u0430\u0432\u0430\u0435\u043c\u043e\u0435 \u0432\u0438\u0440\u0442\u0443\u0430\u043b\u044c\u043d\u043e\u0435 \u043e\u043a\u0440\u0443\u0436\u0435\u043d\u0438\u0435 \u0431\u0443\u0434\u0435\u0442 \u043d\u0430\u0445\u043e\u0434\u0438\u0442\u044c\u0441\u044f \u0432 \u043f\u0430\u043f\u043a\u0435&nbsp;<strong>.venv<\/strong>&nbsp;\u0432 \u043a\u043e\u0440\u043d\u0435 \u043f\u0440\u043e\u0435\u043a\u0442\u0430.<\/p>\n<h4>\u041a\u0430\u043a \u0441\u043e\u0437\u0434\u0430\u0442\u044c \u043f\u0440\u043e\u0435\u043a\u0442 \u0447\u0435\u0440\u0435\u0437 PyCharm<\/h4>\n<p>PyCharm \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u0438\u0432\u0430\u0435\u0442 \u0438\u043d\u0442\u0435\u0433\u0440\u0430\u0446\u0438\u044e \u0441 Poetry. \u041c\u043e\u0436\u043d\u043e \u0432\u044b\u0431\u0440\u0430\u0442\u044c Poetry \u043a\u0430\u043a \u043f\u0440\u0438 \u0441\u043e\u0437\u0434\u0430\u043d\u0438\u0438 \u043d\u043e\u0432\u043e\u0433\u043e \u043f\u0440\u043e\u0435\u043a\u0442\u0430:<\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/3bc\/c56\/9f4\/3bcc569f409eaa756b754e5bb5bcf438.png\" width=\"804\" height=\"691\"><\/figure>\n<p>\u0422\u0430\u043a \u0438 \u0432 \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u044e\u0449\u0435\u043c \u043f\u0440\u043e\u0435\u043a\u0442\u0435. \u0414\u043b\u044f \u044d\u0442\u043e\u0433\u043e \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u0432 \u043f\u0440\u0430\u0432\u043e\u043c \u043d\u0438\u0436\u043d\u0435\u043c \u0443\u0433\u043b\u0443 \u043d\u0430\u0436\u0430\u0442\u044c &#171;No Interpreter&#187; (\u0435\u0441\u043b\u0438 \u0443 \u0432\u0430\u0441 \u0434\u043e \u044d\u0442\u043e\u0433\u043e \u043d\u0435 \u0431\u044b\u043b \u043d\u0430\u0441\u0442\u0440\u043e\u0435\u043d \u0438\u043d\u0442\u0435\u0440\u043f\u0440\u0435\u0442\u0430\u0442\u043e\u0440 \u0432 \u043f\u0440\u043e\u0435\u043a\u0442\u0435) \u0438\u043b\u0438 \u043d\u0430 \u0438\u043c\u044f \u0438\u043d\u0442\u0435\u0440\u043f\u0440\u0435\u0442\u0430\u0442\u043e\u0440\u0430, \u0434\u0430\u043b\u0435\u0435 &#171;Add New Interpreter&#187; \u2192 &#171;Add Local Interpreter&#187;, \u0438 \u0432 \u043e\u0442\u043a\u0440\u044b\u0432\u0448\u0435\u043c\u0441\u044f \u043e\u043a\u043d\u0435 \u0432\u044b\u0431\u0440\u0430\u0442\u044c &#171;Poetry environment&#187;:<\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/c5e\/4de\/b85\/c5e4deb85a80a976a9b9a927b761e3ed.png\" width=\"1031\" height=\"571\"><\/figure>\n<h3>pyproject.toml \u0438 poetry.lock<\/h3>\n<p><strong>pyproject.toml <\/strong>&#8212; \u044d\u0442\u043e \u0444\u0430\u0439\u043b, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u0442 \u0432 \u0441\u0435\u0431\u0435 \u0432\u0441\u044e \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u044e \u043e \u043f\u0440\u043e\u0435\u043a\u0442\u0435: \u043c\u0435\u0442\u0430\u0434\u0430\u043d\u043d\u044b\u0435 (\u0438\u043c\u044f, \u0432\u0435\u0440\u0441\u0438\u044f \u0438 \u0442.\u043f.) \u0438 \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u0438, \u0430 \u0442\u0430\u043a\u0436\u0435 \u0432 \u043d\u0435\u043c \u043c\u043e\u0433\u0443\u0442 \u043f\u0440\u0438\u0441\u0443\u0442\u0441\u0442\u0432\u043e\u0432\u0430\u0442\u044c \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0438 \u0434\u0440\u0443\u0433\u0438\u0445 \u0438\u043d\u0441\u0442\u0440\u0443\u043c\u0435\u043d\u0442\u043e\u0432.<\/p>\n<p>\u0424\u0430\u0439\u043b <strong>poetry.lock <\/strong>\u0436\u0435 \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u0442 \u0432 \u0441\u0435\u0431\u0435 \u0432\u0441\u0435 \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u0438 \u043f\u0440\u043e\u0435\u043a\u0442\u0430 \u0441 \u0437\u0430\u0444\u0438\u043a\u0441\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u043c\u0438 \u0432\u0435\u0440\u0441\u0438\u044f\u043c\u0438 \u0438 \u0444\u043e\u0440\u043c\u0438\u0440\u0443\u0435\u0442\u0441\u044f \u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u0438 (\u043f\u043e\u0436\u0430\u043b\u0443\u0439\u0441\u0442\u0430, \u043d\u0435 \u0440\u0435\u0434\u0430\u043a\u0442\u0438\u0440\u0443\u0439\u0442\u0435 \u0435\u0433\u043e \u0432\u0440\u0443\u0447\u043d\u0443\u044e).<\/p>\n<p><strong>[tool.poetry]<\/strong> \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u0442 \u0432 \u0441\u0435\u0431\u0435 \u043c\u0435\u0442\u0430\u0434\u0430\u043d\u043d\u044b\u0435:<\/p>\n<ul>\n<li>\n<p>name &#8212; \u0438\u043c\u044f \u043f\u0440\u043e\u0435\u043a\u0442\u0430. \u0414\u043e\u043b\u0436\u043d\u043e \u0431\u044b\u0442\u044c <a href=\"https:\/\/peps.python.org\/pep-0508\/#names\" rel=\"noopener noreferrer nofollow\">\u0432\u0430\u043b\u0438\u0434\u043d\u044b\u043c \u043f\u043e PEP 508<\/a>;<\/p>\n<\/li>\n<li>\n<p>version &#8212; \u0432\u0435\u0440\u0441\u0438\u044f \u043f\u0440\u043e\u0435\u043a\u0442\u0430. \u0414\u043e\u043b\u0436\u043d\u0430 \u0431\u044b\u0442\u044c <a href=\"https:\/\/peps.python.org\/pep-0440\/\" rel=\"noopener noreferrer nofollow\">\u0432\u0430\u043b\u0438\u0434\u043d\u043e\u0439 \u043f\u043e PEP 440<\/a>;<\/p>\n<\/li>\n<li>\n<p>description &#8212; \u043a\u043e\u0440\u043e\u0442\u043a\u043e\u0435 \u043e\u043f\u0438\u0441\u0430\u043d\u0438\u0435 \u043f\u0440\u043e\u0435\u043a\u0442\u0430;<\/p>\n<\/li>\n<li>\n<p>license &#8212; \u043b\u0438\u0446\u0435\u043d\u0437\u0438\u044f;<\/p>\n<\/li>\n<li>\n<p>authors &#8212; \u0430\u0432\u0442\u043e\u0440\u044b \u043f\u0440\u043e\u0435\u043a\u0442\u0430 \u0432 \u0444\u043e\u0440\u043c\u0430\u0442\u0435 &#171;name &lt;email&gt;&#187;. \u0414\u043e\u043b\u0436\u0435\u043d \u043f\u0440\u0438\u0441\u0443\u0442\u0441\u0442\u0432\u043e\u0432\u0430\u0442\u044c \u043a\u0430\u043a \u043c\u0438\u043d\u0438\u043c\u0443\u043c \u043e\u0434\u0438\u043d \u0430\u0432\u0442\u043e\u0440.<\/p>\n<\/li>\n<\/ul>\n<p>\u041e\u0441\u0442\u0430\u043b\u044c\u043d\u044b\u0435 \u0441\u043f\u0435\u0446\u0438\u0444\u0438\u043a\u0430\u0442\u043e\u0440\u044b \u043c\u043e\u0436\u043d\u043e \u043d\u0430\u0439\u0442\u0438 \u0432 \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u0430\u0446\u0438\u0438, \u043e\u043d\u0438 \u043d\u0435 \u044f\u0432\u043b\u044f\u044e\u0442\u0441\u044f \u043e\u0431\u044f\u0437\u0430\u0442\u0435\u043b\u044c\u043d\u044b\u043c\u0438.<\/p>\n<p><strong>[tool.poetry.dependencies]<\/strong> \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u0442 \u0432 \u0441\u0435\u0431\u0435 \u0432\u0435\u0440\u0441\u0438\u044e Python \u0438 \u043e\u0441\u043d\u043e\u0432\u043d\u044b\u0435 \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u0438 \u043f\u0440\u043e\u0435\u043a\u0442\u0430 (\u0442\u0430\u043a \u043d\u0430\u0437\u044b\u0432\u0430\u0435\u043c\u0443\u044e main-\u0433\u0440\u0443\u043f\u043f\u0443).<\/p>\n<p>\u0412 <a href=\"https:\/\/peps.python.org\/pep-0517\/\" rel=\"noopener noreferrer nofollow\">PEP-517<\/a> \u0431\u044b\u043b \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u0435\u043d \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u043d\u044b\u0439 \u0441\u043f\u043e\u0441\u043e\u0431 \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u044f\u0442\u044c \u0430\u043b\u044c\u0442\u0435\u0440\u043d\u0430\u0442\u0438\u0432\u043d\u044b\u0435 \u0441\u0438\u0441\u0442\u0435\u043c\u044b \u0441\u0431\u043e\u0440\u043a\u0438 \u0434\u043b\u044f Python-\u043f\u0440\u043e\u0435\u043a\u0442\u043e\u0432. Poetry \u0441\u043e\u0432\u043c\u0435\u0441\u0442\u0438\u043c \u0441 PEP-517 \u0438 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442 poetry-core \u0434\u043b\u044f \u0441\u0431\u043e\u0440\u043a\u0438, \u0447\u0442\u043e \u0438 \u043e\u0431\u043e\u0437\u043d\u0430\u0447\u0435\u043d\u043e \u0432 \u0441\u0435\u043a\u0446\u0438\u0438 <strong>build-system<\/strong>:<\/p>\n<pre><code class=\"bash\">[build-system] requires = [\"poetry-core&gt;=1.0.0\"] build-backend = \"poetry.core.masonry.api\"<\/code><\/pre>\n<p>\u041c\u043d\u043e\u0433\u0438\u0435 \u043f\u0438\u0442\u043e\u043d\u043e\u0432\u0441\u043a\u0438\u0435 \u0438\u043d\u0441\u0442\u0440\u0443\u043c\u0435\u043d\u0442\u044b \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u0438\u0432\u0430\u044e\u0442 \u043a\u043e\u043d\u0444\u0438\u0433\u0443\u0440\u0430\u0446\u0438\u044e \u0447\u0435\u0440\u0435\u0437 <strong>pyproject.toml<\/strong>. \u041d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u0432 \u043c\u043e\u0438\u0445 \u043f\u0440\u043e\u0435\u043a\u0442\u0430\u0445 \u0432 \u043d\u0435\u043c \u0443\u044e\u0442\u043d\u043e \u0440\u0430\u0441\u043f\u043e\u043b\u043e\u0436\u0438\u043b\u0438\u0441\u044c \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0438 isort \u0438 mypy:<\/p>\n<pre><code class=\"bash\">[tool.isort] line_length = 120 ... force_grid_wrap = 2  [tool.mypy] python_version = 3.9 ... follow_imports = \"skip\"<\/code><\/pre>\n<h3>\u0423\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0430 \u0438 \u0443\u0434\u0430\u043b\u0435\u043d\u0438\u0435 \u043f\u0430\u043a\u0435\u0442\u043e\u0432<\/h3>\n<h4>\u0421\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u043d\u0430\u044f \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0430 + \u0432\u0435\u0440\u0441\u0438\u043e\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435<\/h4>\n<p>\u041a\u043e\u043c\u0430\u043d\u0434\u0430 add \u0434\u043e\u0431\u0430\u0432\u043b\u044f\u0435\u0442 \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u044c \u0432 <strong>pyproject.toml<\/strong>, \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0435\u0442 \u0440\u0430\u0437\u0440\u0435\u0448\u0435\u043d\u0438\u0435 \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u0435\u0439 \u0438 \u0443\u0441\u0442\u0430\u043d\u0430\u0432\u043b\u0438\u0432\u0430\u0435\u0442 \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u044c:<\/p>\n<pre><code class=\"bash\">poetry add fastapi<\/code><\/pre>\n<p>\u0412 \u0441\u0435\u043a\u0446\u0438\u0438 <strong>[tool.poetry.dependencies]<\/strong> \u043f\u043e\u044f\u0432\u0438\u043b\u0430\u0441\u044c \u043d\u0430\u0448\u0430 \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u044c:<\/p>\n<pre><code class=\"bash\">[tool.poetry.dependencies] python = \"^3.8\" fastapi = \"^0.95.2\"<\/code><\/pre>\n<p>\u0420\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0438\u043c, \u043a\u0430\u043a \u0443\u043a\u0430\u0437\u044b\u0432\u0430\u0442\u044c \u0432\u0435\u0440\u0441\u0438\u0438 \u043f\u0440\u0438 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0435. \u041f\u0435\u0440\u0432\u044b\u0439 \u0432\u0430\u0440\u0438\u0430\u043d\u0442 &#8212; \u044d\u0442\u043e Caret Requirements:<\/p>\n<div>\n<div class=\"table\">\n<table>\n<tbody>\n<tr>\n<th>\n<p align=\"center\">\u0422\u0440\u0435\u0431\u043e\u0432\u0430\u043d\u0438\u0435<\/p>\n<\/th>\n<th>\n<p align=\"center\">\u0414\u043e\u043f\u0443\u0441\u0442\u0438\u043c\u044b\u0435 \u0432\u0435\u0440\u0441\u0438\u0438<\/p>\n<\/th>\n<\/tr>\n<tr>\n<td>\n<p align=\"center\">^1.2.3<\/p>\n<\/td>\n<td>\n<p align=\"center\">&gt;=1.2.3, &lt;2.0.0<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td>\n<p align=\"center\">^1.2<\/p>\n<\/td>\n<td>\n<p align=\"center\">&gt;=1.2.0, &lt;2.0.0<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td>\n<p align=\"center\">^1<\/p>\n<\/td>\n<td>\n<p align=\"center\">&gt;=1.0.0, &lt;2.0.0<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td>\n<p align=\"center\">^0.2.3<\/p>\n<\/td>\n<td>\n<p align=\"center\">&gt;=0.2.3, &lt;0.3.0<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td>\n<p align=\"center\">^0.0.3<\/p>\n<\/td>\n<td>\n<p align=\"center\">&gt;=0.0.3, &lt;0.0.4<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td>\n<p align=\"center\">^0.0<\/p>\n<\/td>\n<td>\n<p align=\"center\">&gt;=0.0.0, &lt;0.1.0<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td>\n<p align=\"center\">^0<\/p>\n<\/td>\n<td>\n<p align=\"center\">&gt;=0.0.0, &lt;1.0.0<\/p>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<p>\u0412\u0442\u043e\u0440\u043e\u0439 \u0432\u0430\u0440\u0438\u0430\u043d\u0442 &#8212; \u044d\u0442\u043e Tilde requirements, \u0447\u0442\u043e \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u0435\u0442 \u0443\u043a\u0430\u0437\u044b\u0432\u0430\u0442\u044c \u043c\u0438\u043d\u0438\u043c\u0430\u043b\u044c\u043d\u0443\u044e \u0434\u043e\u043f\u0443\u0441\u0442\u0438\u043c\u0443\u044e \u0432\u0435\u0440\u0441\u0438\u044e \u0441 \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u043e\u0439 \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e\u0441\u0442\u044c\u044e \u043e\u0431\u043d\u043e\u0432\u043b\u0435\u043d\u0438\u044f:<\/p>\n<div>\n<div class=\"table\">\n<table>\n<tbody>\n<tr>\n<th>\n<p align=\"center\">\u0422\u0440\u0435\u0431\u043e\u0432\u0430\u043d\u0438\u0435<\/p>\n<\/th>\n<th>\n<p align=\"center\">\u0414\u043e\u043f\u0443\u0441\u0442\u0438\u043c\u044b\u0435 \u0432\u0435\u0440\u0441\u0438\u0438<\/p>\n<\/th>\n<\/tr>\n<tr>\n<td>\n<p align=\"center\">~1.2.3<\/p>\n<\/td>\n<td>\n<p align=\"center\">&gt;=1.2.3,&lt;1.3.0<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td>\n<p align=\"center\">~1.2<\/p>\n<\/td>\n<td>\n<p align=\"center\">&gt;=1.2.0,&lt;1.3.0<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td>\n<p align=\"center\">~1<\/p>\n<\/td>\n<td>\n<p align=\"center\">&gt;=1.0.0,&lt;2.0.0<\/p>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<p>Wildcard requirements \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u044e\u0442 \u043e\u0431\u043d\u043e\u0432\u043b\u0435\u043d\u0438\u0435 \u0434\u043e \u043f\u043e\u0441\u043b\u0435\u0434\u043d\u0435\u0439 \u0432\u0435\u0440\u0441\u0438\u0438 \u0432 \u043f\u043e\u0437\u0438\u0446\u0438\u0438, \u0433\u0434\u0435 \u0440\u0430\u0441\u043f\u043e\u043b\u043e\u0436\u0435\u043d \u0441\u0438\u043c\u0432\u043e\u043b &#171;*&#187;:<\/p>\n<div>\n<div class=\"table\">\n<table>\n<tbody>\n<tr>\n<th>\n<p align=\"center\">\u0422\u0440\u0435\u0431\u043e\u0432\u0430\u043d\u0438\u0435<\/p>\n<\/th>\n<th>\n<p align=\"center\">\u0414\u043e\u043f\u0443\u0441\u0442\u0438\u043c\u044b\u0435 \u0432\u0435\u0440\u0441\u0438\u0438<\/p>\n<\/th>\n<\/tr>\n<tr>\n<td>\n<p align=\"center\">*<\/p>\n<\/td>\n<td>\n<p align=\"center\">&gt;=0.0.0<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td>\n<p align=\"center\">1.*<\/p>\n<\/td>\n<td>\n<p align=\"center\">&gt;=1.0.0,&lt;2.0.0<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td>\n<p align=\"center\">1.2.*<\/p>\n<\/td>\n<td>\n<p align=\"center\">&gt;=1.2.0,&lt;1.3.0<\/p>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<p>Inequality requirements \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u044e\u0442 \u0432\u0440\u0443\u0447\u043d\u0443\u044e \u0443\u043a\u0430\u0437\u0430\u0442\u044c \u0434\u0438\u0430\u043f\u0430\u0437\u043e\u043d \u0434\u043e\u043f\u0443\u0441\u0442\u0438\u043c\u044b\u0445 \u0432\u0435\u0440\u0441\u0438\u0439, \u0438\u043b\u0438 \u0436\u0435 \u0442\u043e\u0447\u043d\u0443\u044e \u0432\u0435\u0440\u0441\u0438\u044e:<\/p>\n<pre><code class=\"bash\">&gt;=1.2.0 &gt;1 &lt;2 !=1.2.3 ==1.5.2  # \u041c\u043e\u0436\u043d\u043e \u043a\u043e\u043c\u0431\u0438\u043d\u0438\u0440\u043e\u0432\u0430\u0442\u044c &gt;=1.2,&lt;1.5<\/code><\/pre>\n<p>\u0421\u0442\u043e\u0438\u0442 \u043e\u0431\u0440\u0430\u0442\u0438\u0442\u044c \u0432\u043d\u0438\u043c\u0430\u043d\u0438\u0435 \u043d\u0430 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u0439 \u043c\u043e\u043c\u0435\u043d\u0442: \u0435\u0441\u043b\u0438 \u0432\u044b \u0443\u043a\u0430\u0437\u044b\u0432\u0430\u0435\u0442\u0435 \u0442\u043e\u0447\u043d\u0443\u044e \u0432\u0435\u0440\u0441\u0438\u044e, \u0438 \u0434\u0440\u0443\u0433\u0438\u043c \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u044f\u043c \u0442\u0440\u0435\u0431\u0443\u0435\u0442\u0441\u044f \u0434\u0440\u0443\u0433\u0430\u044f \u0432\u0435\u0440\u0441\u0438\u044f, \u0442\u043e \u0440\u0435\u0437\u043e\u043b\u0432\u0435\u0440 \u043d\u0435 \u0441\u043c\u043e\u0436\u0435\u0442 \u0440\u0430\u0437\u0440\u0435\u0448\u0438\u0442\u044c \u0432\u0441\u0435 \u043a\u043e\u043d\u0444\u043b\u0438\u043a\u0442\u044b \u0438 \u043f\u0440\u043e\u0446\u0435\u0434\u0443\u0440\u0430 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0438 (\u0438\u043b\u0438 \u043e\u0431\u043d\u043e\u0432\u043b\u0435\u043d\u0438\u044f) \u043d\u0435 \u0431\u0443\u0434\u0435\u0442 \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0430.<\/p>\n<h4>Extras \u0438 groups<\/h4>\n<p>\u041f\u0440\u0435\u0436\u0434\u0435 \u0447\u0435\u043c \u0438\u0434\u0442\u0438 \u0434\u0430\u043b\u044c\u0448\u0435, \u0445\u043e\u0447\u0435\u0442\u0441\u044f \u0432\u0432\u0435\u0441\u0442\u0438 2 \u043f\u043e\u043d\u044f\u0442\u0438\u044f &#8212; extras \u0438 groups. \u041e\u043d\u0438 \u0434\u043e\u0432\u043e\u043b\u044c\u043d\u043e \u0441\u0445\u043e\u0436\u0438, \u043d\u043e \u043d\u0430 \u0434\u0435\u043b\u0435 \u0441\u043b\u0443\u0436\u0430\u0442 \u0434\u043b\u044f \u0440\u0430\u0437\u043d\u044b\u0445 \u0446\u0435\u043b\u0435\u0439.<\/p>\n<p>Dependency groups (\u0434\u0430\u043b\u0435\u0435 \u043f\u0440\u043e\u0441\u0442\u043e \u0433\u0440\u0443\u043f\u043f\u044b) \u0441\u043e\u0434\u0435\u0440\u0436\u0430\u0442 \u0432 \u0441\u0435\u0431\u0435 \u043e\u043f\u0446\u0438\u043e\u043d\u0430\u043b\u044c\u043d\u044b\u0435 \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u0438, \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u043c\u044b\u0435 <strong>\u0442\u043e\u043b\u044c\u043a\u043e \u043f\u0440\u0438 \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u043a\u0435.&nbsp;<\/strong>\u0423\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u044c \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u0438 \u0438\u0437 \u0433\u0440\u0443\u043f\u043f \u043c\u043e\u0436\u043d\u043e \u0442\u043e\u043b\u044c\u043a\u043e \u0447\u0435\u0440\u0435\u0437 Poetry. \u041a\u0430\u0436\u0434\u044b\u0439 \u043f\u0440\u043e\u0435\u043a\u0442 \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u0442 \u0432 \u0441\u0435\u0431\u0435 \u043e\u0434\u043d\u0443 \u043d\u0435\u044f\u0432\u043d\u0443\u044e \u043e\u0431\u044f\u0437\u0430\u0442\u0435\u043b\u044c\u043d\u0443\u044e \u0433\u0440\u0443\u043f\u043f\u0443 &#8212; main, \u043a\u043e\u0442\u043e\u0440\u0430\u044f \u043d\u0430\u0445\u043e\u0434\u0438\u0442\u0441\u044f \u0432 \u0441\u0435\u043a\u0446\u0438\u0438 <strong>[tool.poetry.dependencies]<\/strong>.<\/p>\n<p>\u0423\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0430 \u0432 \u0433\u0440\u0443\u043f\u043f\u0443 \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0435\u0442\u0441\u044f \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c:<\/p>\n<pre><code class=\"bash\">poetry add --group test pytest<\/code><\/pre>\n<p>\u0413\u0440\u0443\u043f\u043f\u0430 \u0432\u043c\u0435\u0441\u0442\u0435 \u0441 \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u044c\u044e \u043f\u043e\u044f\u0432\u0438\u043b\u0430\u0441\u044c \u0432 pyproject.toml:<\/p>\n<pre><code class=\"bash\">[tool.poetry.group.test.dependencies] pytest = \"^7.3.1\"<\/code><\/pre>\n<p>Extras \u0436\u0435 \u043f\u0440\u0435\u0434\u043d\u0430\u0437\u043d\u0430\u0447\u0435\u043d\u044b \u0434\u043b\u044f \u0432\u0432\u0435\u0434\u0435\u043d\u0438\u044f \u0434\u043e\u043f\u043e\u043b\u043d\u0438\u0442\u0435\u043b\u044c\u043d\u044b\u0445 \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u0435\u0439, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0432\u043a\u043b\u044e\u0447\u0430\u044e\u0442 \u043a\u0430\u043a\u0443\u044e-\u043b\u0438\u0431\u043e \u0444\u0443\u043d\u043a\u0446\u0438\u043e\u043d\u0430\u043b\u044c\u043d\u043e\u0441\u0442\u044c \u0432 \u0432\u0430\u0448\u0435\u043c \u043f\u0440\u043e\u0435\u043a\u0442\u0435. \u0423\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u044c \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u044c \u043a\u0430\u043a extra \u043c\u043e\u0436\u043d\u043e \u0432\u043e\u0442 \u0442\u0430\u043a:<\/p>\n<pre><code class=\"bash\">poetry add --extras postgres psycopg2-binary poetry add --extras mysql --extras database mysql-connector-python  # \u041c\u043e\u0436\u043d\u043e \u043f\u0435\u0440\u0435\u0447\u0438\u0441\u043b\u044f\u0442\u044c \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e extras<\/code><\/pre>\n<p>\u0417\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u0438 \u043f\u043e\u044f\u0432\u0438\u043b\u0438\u0441\u044c \u0432 <strong>[tool.poetry.dependencies]&nbsp;<\/strong>\u0441 \u043f\u043e\u043c\u0435\u0442\u043a\u043e\u0439 extras:<\/p>\n<pre><code class=\"bash\">[tool.poetry.dependencies] python = \"^3.8\" psycopg2-binary = {version = \"^2.9.6\", extras = [\"postgres\"]} mysql-connector-python = {version = \"^8.0.33\", extras = [\"mysql\", \"database\"]}<\/code><\/pre>\n<p>\u041f\u043e\u0441\u043b\u0435 \u0441\u0431\u043e\u0440\u043a\u0438 \u0438 \u043f\u0443\u0431\u043b\u0438\u043a\u0430\u0446\u0438\u0438 \u043c\u043e\u0436\u043d\u043e \u0431\u0443\u0434\u0435\u0442 \u0443\u0441\u0442\u0430\u043d\u0430\u0432\u043b\u0438\u0432\u0430\u0442\u044c \u0432\u0430\u0448 \u043f\u0430\u043a\u0435\u0442 \u043a\u0430\u043a \u043e\u0431\u044b\u0447\u043d\u043e:<\/p>\n<pre><code class=\"bash\">poetry add \"my-project[postgres,database]\" poetry add \"my-project[mysql]<\/code><\/pre>\n<h4>\u0423\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0430 \u0441 Git \u0438 \u043f\u0440\u0438\u0432\u0430\u0442\u043d\u044b\u0445 package registries<\/h4>\n<p>\u0423\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0430 \u0438\u0437 \u043f\u0443\u0431\u043b\u0438\u0447\u043d\u044b\u0445 \u0440\u0435\u043f\u043e\u0437\u0438\u0442\u043e\u0440\u0438\u0435\u0432 \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0435\u0442\u0441\u044f \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c:<\/p>\n<pre><code class=\"bash\">poetry add \"git+https:\/\/github.com\/psf\/requests\"  # \u0431\u0443\u0434\u0435\u0442 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d \u043f\u043e\u0441\u043b\u0435\u0434\u043d\u0438\u0439 \u043a\u043e\u043c\u043c\u0438\u0442 \u0441 \u043e\u0441\u043d\u043e\u0432\u043d\u043e\u0439 \u0432\u0435\u0442\u043a\u0438 poetry add \"git+https:\/\/github.com\/psf\/requests#update-3.0\"  # \u0431\u0443\u0434\u0435\u0442 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d \u043f\u043e\u0441\u043b\u0435\u0434\u043d\u0438\u0439 \u043a\u043e\u043c\u043c\u0438\u0442 \u0441 \u0432\u0435\u0442\u043a\u0438 update 3.0  # \u0412\u0441\u0435 \u0442\u043e \u0436\u0435 \u0441\u0430\u043c\u043e\u0435, \u043d\u043e \u0447\u0435\u0440\u0435\u0437 SSH poetry add \"git+ssh:\/\/git@github.com:requests\/requests.git\" poetry add \"git+ssh:\/\/git@github.com:requests\/requests.git#update-3.0\"<\/code><\/pre>\n<p>\u0414\u043b\u044f \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0438 \u0438\u0437 \u043f\u0440\u0438\u0432\u0430\u0442\u043d\u044b\u0445 git-\u0440\u0435\u043f\u043e\u0437\u0438\u0442\u043e\u0440\u0438\u0435\u0432 \u043c\u043e\u0436\u043d\u043e \u0432\u043e\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c\u0441\u044f SSH, \u043d\u043e \u0432 \u0442\u0430\u043a\u043e\u043c \u0441\u043b\u0443\u0447\u0430\u0435 \u0431\u0443\u0434\u0435\u0442 \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0442\u044c\u0441\u044f \u0441\u0431\u043e\u0440\u043a\u0430.<\/p>\n<p>\u0415\u0441\u043b\u0438 \u0436\u0435 \u0443 \u0432\u0430\u0441 \u0435\u0441\u0442\u044c \u043f\u0440\u0438\u0432\u0430\u0442\u043d\u044b\u0439 package registry, \u043f\u043e\u0441\u043b\u0435\u0434\u043e\u0432\u0430\u0442\u0435\u043b\u044c\u043d\u043e\u0441\u0442\u044c \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u044f \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0430\u044f (\u0440\u0430\u0441\u0441\u043c\u0430\u0442\u0440\u0438\u0432\u0430\u0442\u044c \u0431\u0443\u0434\u0435\u043c \u043d\u0430 \u043f\u0440\u0438\u043c\u0435\u0440\u0435 GitLab). \u0414\u043e\u0431\u0430\u0432\u043b\u044f\u0435\u043c \u0438\u0441\u0442\u043e\u0447\u043d\u0438\u043a:<\/p>\n<pre><code class=\"bash\">poetry source add my-repo \"https:\/\/my.gitlab.com\/projects\/1\/packages\/pypi\/simple\"<\/code><\/pre>\n<p>\u0414\u043e\u0431\u0430\u0432\u043b\u0435\u043d\u043d\u044b\u0439 \u0438\u0441\u0442\u043e\u0447\u043d\u0438\u043a \u043f\u043e\u044f\u0432\u0438\u043b\u0441\u044f \u0432 \u0444\u0430\u0439\u043b\u0435 <strong>pyproject.toml<\/strong>:<\/p>\n<pre><code class=\"bash\">[[tool.poetry.source]] name = \"my-repo\" url = \"https:\/\/my.gitlab.com\/projects\/1\/packages\/pypi\/simple\" default = false secondary = false<\/code><\/pre>\n<p>\u041d\u0430\u0441\u0442\u0440\u0430\u0438\u0432\u0430\u0435\u043c \u0430\u0443\u0442\u0435\u043d\u0442\u0438\u0444\u0438\u043a\u0430\u0446\u0438\u044e (\u0434\u043b\u044f GitLab Package Registry \u0440\u0435\u043a\u043e\u043c\u0435\u043d\u0434\u0443\u044e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c <a href=\"https:\/\/docs.gitlab.com\/ee\/user\/profile\/personal_access_tokens.html\" rel=\"noopener noreferrer nofollow\">Personal Access Token<\/a>):<\/p>\n<pre><code class=\"bash\">poetry config http-basic.my-repo &lt;token-name&gt; &lt;secret-token&gt;<\/code><\/pre>\n<p>\u0412\u044b\u043f\u043e\u043b\u043d\u044f\u0435\u043c \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0443, \u0443\u043a\u0430\u0437\u0430\u0432 \u0438\u0441\u0442\u043e\u0447\u043d\u0438\u043a:<\/p>\n<pre><code class=\"bash\">poetry add --source my-repo my-package<\/code><\/pre>\n<p>\u041d\u0435 \u0437\u0430\u0431\u0443\u0434\u044c\u0442\u0435 \u0438\u0437\u043c\u0435\u043d\u0438\u0442\u044c <a href=\"http:\/\/my.gitlab.com\" rel=\"noopener noreferrer nofollow\">my.gitlab.com<\/a> \u043d\u0430 \u0430\u0434\u0440\u0435\u0441 \u0432\u0430\u0448\u0435\u0433\u043e GitLab, \u0430 \u0442\u0430\u043a\u0436\u0435 \u0443\u043a\u0430\u0437\u0430\u0442\u044c \u043a\u043e\u0440\u0440\u0435\u043a\u0442\u043d\u044b\u0439 ID \u043f\u0440\u043e\u0435\u043a\u0442\u0430. \u0418\u043c\u044f \u0438\u0441\u0442\u043e\u0447\u043d\u0438\u043a\u0430 \u0432 \u043f\u0440\u0438\u043c\u0435\u0440\u0435 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0441\u044f my-repo, \u043d\u043e \u043c\u043e\u0436\u043d\u043e \u0432\u044b\u0431\u0440\u0430\u0442\u044c \u043b\u044e\u0431\u043e\u0435 \u0434\u0440\u0443\u0433\u043e\u0435 \u043d\u0430 \u0432\u0430\u0448\u0435 \u0443\u0441\u043c\u043e\u0442\u0440\u0435\u043d\u0438\u0435.<\/p>\n<h4>\u0423\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0430 \u0438\u0437 \u0444\u0430\u0439\u043b\u043e\u0432<\/h4>\n<p>Poetry \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u0435\u0442 \u0443\u0441\u0442\u0430\u043d\u0430\u0432\u043b\u0438\u0432\u0430\u0442\u044c \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u0438 \u043a\u0430\u043a \u0438\u0437 \u043b\u043e\u043a\u0430\u043b\u044c\u043d\u044b\u0445 \u0444\u0430\u0439\u043b\u043e\u0432 \u0438 \u043f\u0430\u043f\u043e\u043a:<\/p>\n<pre><code class=\"bash\">poetry add package-1.0.0.tar.gz poetry add package-1.0.0.whl poetry add ~\/my\/local\/package<\/code><\/pre>\n<p>\u0422\u0430\u043a \u0438 \u0441 \u0443\u0434\u0430\u043b\u0435\u043d\u043d\u044b\u0445 \u0441\u0435\u0440\u0432\u0435\u0440\u043e\u0432:<\/p>\n<pre><code class=\"bash\">poetry add https:\/\/download.pytorch.org\/whl\/cpu\/torch-2.0.0%2Bcpu-cp39-cp39-linux_x86_64.whl<\/code><\/pre>\n<h4>\u041e\u043f\u0446\u0438\u0438 \u043f\u0440\u0438 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0435<\/h4>\n<p>\u0412 \u044d\u0442\u043e\u043c \u0440\u0430\u0437\u0434\u0435\u043b\u0435 \u043a\u0440\u0430\u0442\u043a\u043e \u043f\u0440\u043e\u0431\u0435\u0436\u0438\u043c\u0441\u044f \u043f\u043e \u043e\u0441\u043d\u043e\u0432\u043d\u044b\u043c \u043e\u043f\u0446\u0438\u044f\u043c, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043c\u043e\u0436\u043d\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u043f\u0440\u0438 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0435 \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u0435\u0439:<\/p>\n<div>\n<div class=\"table\">\n<table>\n<tbody>\n<tr>\n<th data-colwidth=\"148\" width=\"148\">\n<p>\u041e\u043f\u0446\u0438\u044f<\/p>\n<\/th>\n<th>\n<p>\u041f\u043e\u044f\u0441\u043d\u0435\u043d\u0438\u0435<\/p>\n<\/th>\n<\/tr>\n<tr>\n<td data-colwidth=\"148\" width=\"148\">\n<p align=\"left\">&#8212;group (-G)<\/p>\n<\/td>\n<td>\n<p align=\"left\">\u0413\u0440\u0443\u043f\u043f\u0430, \u0432 \u043a\u043e\u0442\u043e\u0440\u0443\u044e \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u0434\u043e\u0431\u0430\u0432\u0438\u0442\u044c \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u044c. \u0415\u0441\u043b\u0438 \u0442\u0430\u043a\u043e\u0439 \u0433\u0440\u0443\u043f\u043f\u044b \u043d\u0435 \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u0435\u0442, \u043e\u043d\u0430 \u0431\u0443\u0434\u0435\u0442 \u0441\u043e\u0437\u0434\u0430\u043d\u0430<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"148\" width=\"148\">\n<p align=\"left\">&#8212;editable<\/p>\n<\/td>\n<td>\n<p align=\"left\">\u0423\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u044c \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u044c \u0432 editable \u0440\u0435\u0436\u0438\u043c\u0435<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"148\" width=\"148\">\n<p align=\"left\">&#8212;extras<\/p>\n<\/td>\n<td>\n<p align=\"left\">Extras \u0434\u043b\u044f \u0430\u043a\u0442\u0438\u0432\u0430\u0446\u0438\u0438 \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u0438<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"148\" width=\"148\">\n<p align=\"left\">&#8212;optional<\/p>\n<\/td>\n<td>\n<p align=\"left\">\u0414\u043e\u0431\u0430\u0432\u0438\u0442\u044c \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u044c \u043a\u0430\u043a \u043e\u043f\u0446\u0438\u043e\u043d\u0430\u043b\u044c\u043d\u0443\u044e<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"148\" width=\"148\">\n<p align=\"left\">&#8212;python<\/p>\n<\/td>\n<td>\n<p align=\"left\">\u0412\u0435\u0440\u0441\u0438\u044f Python, \u0434\u043b\u044f \u043a\u043e\u0442\u043e\u0440\u043e\u0439 \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u044c \u0434\u043e\u043b\u0436\u043d\u0430 \u0431\u044b\u0442\u044c \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043b\u0435\u043d\u0430<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"148\" width=\"148\">\n<p align=\"left\">&#8212;platform<\/p>\n<\/td>\n<td>\n<p align=\"left\">\u041f\u043b\u0430\u0442\u0444\u043e\u0440\u043c\u0430, \u0434\u043b\u044f \u043a\u043e\u0442\u043e\u0440\u043e\u0439 \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u044c \u0434\u043e\u043b\u0436\u043d\u0430 \u0431\u044b\u0442\u044c \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043b\u0435\u043d\u0430 (linux, darwin \u0438\u043b\u0438 win32)<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"148\" width=\"148\">\n<p align=\"left\">&#8212;source<\/p>\n<\/td>\n<td>\n<p align=\"left\">\u0418\u043c\u044f \u0438\u0441\u0442\u043e\u0447\u043d\u0438\u043a\u0430, \u0438\u0437 \u043a\u043e\u0442\u043e\u0440\u043e\u0433\u043e \u0431\u0443\u0434\u0435\u0442 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043b\u0435\u043d\u0430 \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u044c. \u041f\u043e \u0443\u043c\u043e\u043b\u0447\u0430\u043d\u0438\u044e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0441\u044f PyPI, \u043e \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0435 \u0441\u043e\u0431\u0441\u0442\u0432\u0435\u043d\u043d\u044b\u0445 \u0438\u0441\u0442\u043e\u0447\u043d\u0438\u043a\u043e\u0432 \u043d\u0438\u0436\u0435<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"148\" width=\"148\">\n<p align=\"left\">&#8212;allow-prereleases<\/p>\n<\/td>\n<td>\n<p align=\"left\">\u0420\u0430\u0437\u0440\u0435\u0448\u0438\u0442\u044c \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0443 \u043f\u0440\u0435\u0440\u0435\u043b\u0438\u0437\u043e\u0432<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"148\" width=\"148\">\n<p align=\"left\">&#8212;dry-run<\/p>\n<\/td>\n<td>\n<p align=\"left\">\u0412\u044b\u0432\u0435\u0441\u0442\u0438 \u043f\u043e\u0441\u043b\u0435\u0434\u043e\u0432\u0430\u0442\u0435\u043b\u044c\u043d\u043e\u0441\u0442\u044c \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0439, \u043d\u043e \u043d\u0435 \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0442\u044c \u043d\u0438\u043a\u0430\u043a\u0438\u0445 \u043e\u043f\u0435\u0440\u0430\u0446\u0438\u0439<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"148\" width=\"148\">\n<p align=\"left\">&#8212;lock<\/p>\n<\/td>\n<td>\n<p align=\"left\">\u041d\u0435 \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0442\u044c \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0443, \u0442\u043e\u043b\u044c\u043a\u043e \u043e\u0431\u043d\u043e\u0432\u0438\u0442\u044c lock-\u0444\u0430\u0439\u043b<\/p>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<h4>poetry install<\/h4>\n<p>\u041a\u043e\u043c\u0430\u043d\u0434\u0430 install \u043f\u0440\u0438 \u0437\u0430\u043f\u0443\u0441\u043a\u0435 \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0435\u0442 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0443\u044e \u043f\u043e\u0441\u043b\u0435\u0434\u043e\u0432\u0430\u0442\u0435\u043b\u044c\u043d\u043e\u0441\u0442\u044c \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0439:<\/p>\n<ul>\n<li>\n<p>\u0447\u0438\u0442\u0430\u0435\u0442 \u0444\u0430\u0439\u043b <strong>pyproject.toml<\/strong><\/p>\n<\/li>\n<li>\n<p>\u0435\u0441\u043b\u0438 \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u0435\u0442 \u0444\u0430\u0439\u043b <strong>poetry.lock<\/strong>, \u0442\u043e \u0432\u0435\u0440\u0441\u0438\u0438 \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u0435\u0439 \u0431\u0435\u0440\u0443\u0442\u0441\u044f \u0438\u0437 \u043d\u0435\u0433\u043e. \u0415\u0441\u043b\u0438 \u0435\u0433\u043e \u043d\u0435 \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u0435\u0442, Poetry \u0432\u044b\u043f\u043e\u043b\u043d\u0438\u0442 \u0440\u0430\u0437\u0440\u0435\u0448\u0435\u043d\u0438\u0435 \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u0435\u0439 \u0438 \u0441\u043e\u0437\u0434\u0430\u0441\u0442 \u0435\u0433\u043e<\/p>\n<\/li>\n<li>\n<p>\u0443\u0441\u0442\u0430\u043d\u0430\u0432\u043b\u0438\u0432\u0430\u0435\u0442 \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u0438<\/p>\n<\/li>\n<\/ul>\n<p>\u0420\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0438\u043c \u043e\u0441\u043d\u043e\u0432\u043d\u044b\u0435 \u043e\u043f\u0446\u0438\u0438:<\/p>\n<div>\n<div class=\"table\">\n<table>\n<tbody>\n<tr>\n<th data-colwidth=\"100\" width=\"100\">\n<p>\u041e\u043f\u0446\u0438\u044f<\/p>\n<\/th>\n<th>\n<p>\u041f\u043e\u044f\u0441\u043d\u0435\u043d\u0438\u0435<\/p>\n<\/th>\n<\/tr>\n<tr>\n<td data-colwidth=\"100\" width=\"100\">\n<p align=\"left\">&#8212;without<\/p>\n<\/td>\n<td>\n<p align=\"left\">\u0413\u0440\u0443\u043f\u043f\u044b, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0431\u0443\u0434\u0443\u0442 \u043f\u0440\u043e\u0438\u0433\u043d\u043e\u0440\u0438\u0440\u043e\u0432\u0430\u043d\u044b \u043f\u0440\u0438 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0435<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"100\" width=\"100\">\n<p align=\"left\">&#8212;with<\/p>\n<\/td>\n<td>\n<p align=\"left\">\u0413\u0440\u0443\u043f\u043f\u044b, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0431\u0443\u0434\u0443\u0442 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043b\u0435\u043d\u044b<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"100\" width=\"100\">\n<p align=\"left\">&#8212;only<\/p>\n<\/td>\n<td>\n<p align=\"left\">\u0423\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u044c \u0442\u043e\u043b\u044c\u043a\u043e \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u043d\u044b\u0435 \u0433\u0440\u0443\u043f\u043f\u044b (\u0432 \u044d\u0442\u043e\u043c \u0441\u043b\u0443\u0447\u0430\u0435 &#8212;without \u0438 &#8212;with \u0431\u0443\u0434\u0443\u0442 \u043f\u0440\u043e\u0438\u0433\u043d\u043e\u0440\u0438\u0440\u043e\u0432\u0430\u043d\u044b)<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"100\" width=\"100\">\n<p align=\"left\">&#8212;only-root<\/p>\n<\/td>\n<td>\n<p align=\"left\">\u0423\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u044c \u0442\u043e\u043b\u044c\u043a\u043e \u043f\u0440\u043e\u0435\u043a\u0442, \u043f\u0440\u043e\u0438\u0433\u043d\u043e\u0440\u0438\u0440\u043e\u0432\u0430\u0432 \u0432\u0441\u0435 \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u0438<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"100\" width=\"100\">\n<p align=\"left\">&#8212;sync<\/p>\n<\/td>\n<td>\n<p align=\"left\">\u0421\u0438\u043d\u0445\u0440\u043e\u043d\u0438\u0437\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0432\u0438\u0440\u0442\u0443\u0430\u043b\u044c\u043d\u043e\u0435 \u043e\u043a\u0440\u0443\u0436\u0435\u043d\u0438\u0435 \u0441 lock-\u0444\u0430\u0439\u043b\u043e\u043c<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"100\" width=\"100\">\n<p align=\"left\">&#8212;no-root<\/p>\n<\/td>\n<td>\n<p align=\"left\">\u041d\u0435 \u0443\u0441\u0442\u0430\u043d\u0430\u0432\u043b\u0438\u0432\u0430\u0442\u044c \u0441\u0430\u043c \u043f\u0440\u043e\u0435\u043a\u0442<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"100\" width=\"100\">\n<p align=\"left\">&#8212;dry-run<\/p>\n<\/td>\n<td>\n<p align=\"left\">\u0412\u044b\u0432\u0435\u0441\u0442\u0438 \u043f\u043e\u0441\u043b\u0435\u0434\u043e\u0432\u0430\u0442\u0435\u043b\u044c\u043d\u043e\u0441\u0442\u044c \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0439, \u043d\u043e \u043d\u0435 \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0442\u044c \u043d\u0438\u043a\u0430\u043a\u0438\u0445 \u043e\u043f\u0435\u0440\u0430\u0446\u0438\u0439<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"100\" width=\"100\">\n<p align=\"left\">&#8212;extras (-E)<\/p>\n<\/td>\n<td>\n<p align=\"left\">Extras, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u044c<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"100\" width=\"100\">\n<p align=\"left\">&#8212;all-extras<\/p>\n<\/td>\n<td>\n<p align=\"left\">\u0412\u043a\u043b\u044e\u0447\u0438\u0442\u044c \u0432\u0441\u0435 extras \u0432 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0443<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"100\" width=\"100\">\n<p align=\"left\">&#8212;compile<\/p>\n<\/td>\n<td>\n<p align=\"left\">\u0422\u0440\u0430\u043d\u0441\u043b\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0438\u0441\u0445\u043e\u0434\u043d\u0438\u043a\u0438 \u0432 \u0431\u0430\u0439\u0442-\u043a\u043e\u0434<\/p>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<h4>\u0423\u0434\u0430\u043b\u0435\u043d\u0438\u0435 \u043f\u0430\u043a\u0435\u0442\u043e\u0432<\/h4>\n<p>\u0414\u043b\u044f \u0443\u0434\u0430\u043b\u0435\u043d\u0438\u044f \u043a\u0430\u043a\u043e\u0439-\u043b\u0438\u0431\u043e \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u0438 \u043c\u043e\u0436\u043d\u043e \u0432\u043e\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c\u0441\u044f \u043a\u043e\u043c\u0430\u043d\u0434\u043e\u0439 remove:<\/p>\n<pre><code class=\"bash\">poetry remove requests<\/code><\/pre>\n<p>\u0415\u0441\u043b\u0438 \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u044c \u043d\u0430\u0445\u043e\u0434\u0438\u0442\u0441\u044f \u0432 \u043a\u0430\u043a\u043e\u0439-\u0442\u043e \u0433\u0440\u0443\u043f\u043f\u0435, \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0439\u0442\u0435 \u043e\u043f\u0446\u0438\u044e &#8212;group:<\/p>\n<pre><code>poetry remove --group my-group requests<\/code><\/pre>\n<h4>\u0424\u0438\u043a\u0441\u0430\u0446\u0438\u044f \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u0435\u0439<\/h4>\n<p>\u041a\u043e\u043c\u0430\u043d\u0434\u0430 lock \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u0435\u0442 \u0437\u0430\u0444\u0438\u043a\u0441\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u0438, \u043e\u0431\u043d\u043e\u0432\u0438\u0432 \u0444\u0430\u0439\u043b <strong>poetry.lock<\/strong>:<\/p>\n<pre><code>poetry lock<\/code><\/pre>\n<p>\u0411\u0443\u0434\u044c\u0442\u0435 \u0432\u043d\u0438\u043c\u0430\u0442\u0435\u043b\u044c\u043d\u044b! \u041f\u043e \u0443\u043c\u043e\u043b\u0447\u0430\u043d\u0438\u044e, <strong>poetry lock<\/strong> \u043f\u043e\u043f\u044b\u0442\u0430\u0435\u0442\u0441\u044f \u0432\u044b\u043f\u043e\u043b\u043d\u0438\u0442\u044c \u043e\u0431\u043d\u043e\u0432\u043b\u0435\u043d\u0438\u0435 \u0432\u0441\u0435\u0445 \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u0435\u0439 \u0434\u043e \u043f\u043e\u0441\u043b\u0435\u0434\u043d\u0438\u0445 \u0434\u043e\u043f\u0443\u0441\u0442\u0438\u043c\u044b\u0445 \u0432\u0435\u0440\u0441\u0438\u0439. \u0427\u0442\u043e\u0431\u044b \u044d\u0442\u043e\u0433\u043e \u0438\u0437\u0431\u0435\u0436\u0430\u0442\u044c, \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0439\u0442\u0435 \u043e\u043f\u0446\u0438\u044e &#8212;no-update.<\/p>\n<h3>\u0417\u0430\u043f\u0443\u0441\u043a \u043a\u043e\u043c\u0430\u043d\u0434 \u0447\u0435\u0440\u0435\u0437 Poetry<\/h3>\n<h4>poetry shell<\/h4>\n<p>\u0421 \u043f\u043e\u043c\u043e\u0449\u044c\u044e <strong>poetry shell<\/strong> \u043c\u043e\u0436\u043d\u043e \u0437\u0430\u043f\u0443\u0441\u0442\u0438\u0442\u044c \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0443 \u0441 \u0430\u043a\u0442\u0438\u0432\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u043c \u0432\u0438\u0440\u0442\u0443\u0430\u043b\u044c\u043d\u044b\u043c \u043e\u043a\u0440\u0443\u0436\u0435\u043d\u0438\u0435\u043c. \u0415\u0441\u043b\u0438 \u0435\u0433\u043e \u043d\u0435 \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u0435\u0442, \u0442\u043e \u043e\u043d\u043e \u0431\u0443\u0434\u0435\u0442 \u0441\u043e\u0437\u0434\u0430\u043d\u043e.<\/p>\n<p>\u0422.\u043a. <strong>poetry shell<\/strong> \u043d\u0435 \u043f\u0440\u043e\u0441\u0442\u043e \u0430\u043a\u0442\u0438\u0432\u0438\u0440\u0443\u0435\u0442 \u0432\u0438\u0440\u0442\u0443\u0430\u043b\u044c\u043d\u043e\u0435 \u043e\u043a\u0440\u0443\u0436\u0435\u043d\u0438\u0435, \u0430 \u0438\u043c\u0435\u043d\u043d\u043e \u0441\u043e\u0437\u0434\u0430\u0435\u0442 \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0443, \u0442\u043e \u0441\u0442\u043e\u0438\u0442 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0434\u043b\u044f \u0432\u044b\u0445\u043e\u0434\u0430 <strong>exit<\/strong>, \u0430 \u043d\u0435 <strong>deactivate<\/strong>.<\/p>\n<h4>\u0421\u043a\u0440\u0438\u043f\u0442\u044b \u0432 pyproject.toml<\/h4>\n<p>\u0412 \u0444\u0430\u0439\u043b <strong>pyproject.toml<\/strong> \u043c\u043e\u0436\u043d\u043e \u0432\u043a\u043b\u044e\u0447\u0438\u0442\u044c \u0441\u0435\u043a\u0446\u0438\u044e <strong>[tool.poetry.scripts]<\/strong>, \u043a\u043e\u0442\u043e\u0440\u0430\u044f \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u0442 \u0432 \u0441\u0435\u0431\u0435 \u043e\u043f\u0438\u0441\u0430\u043d\u0438\u0435 \u0441\u043a\u0440\u0438\u043f\u0442\u043e\u0432, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0431\u0443\u0434\u0443\u0442 \u0434\u043e\u0441\u0442\u0443\u043f\u043d\u044b \u043a \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u044e \u043f\u0440\u0438 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0435 \u043f\u0440\u043e\u0435\u043a\u0442\u0430:<\/p>\n<pre><code class=\"bash\">[tool.poetry.scripts] my-script = \"my_package.console:run\"<\/code><\/pre>\n<p>\u0417\u0434\u0435\u0441\u044c \u043c\u044b \u043e\u043f\u0438\u0441\u044b\u0432\u0430\u0435\u043c \u0441\u043a\u0440\u0438\u043f\u0442 my-script, \u043f\u0440\u0438 \u0437\u0430\u043f\u0443\u0441\u043a\u0435 \u043a\u043e\u0442\u043e\u0440\u043e\u0433\u043e \u0432\u044b\u043f\u043e\u043b\u043d\u0438\u0442\u0441\u044f \u0444\u0443\u043d\u043a\u0446\u0438\u044f run \u0438\u0437 \u043c\u043e\u0434\u0443\u043b\u044f console \u0438\u0437 \u043f\u0430\u043a\u0435\u0442\u0430 my_package. \u041f\u0440\u0438 \u043e\u0431\u043d\u043e\u0432\u043b\u0435\u043d\u0438\u0438 \u0438\u043b\u0438 \u0434\u043e\u0431\u0430\u0432\u043b\u0435\u043d\u0438\u0438 \u0441\u043a\u0440\u0438\u043f\u0442\u043e\u0432 \u043d\u0435 \u0437\u0430\u0431\u044b\u0432\u0430\u0439\u0442\u0435 \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0442\u044c \u043a\u043e\u043c\u0430\u043d\u0434\u0443 <strong>poetry install<\/strong>, \u0447\u0442\u043e\u0431\u044b \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u0438\u0445 \u0434\u043e\u0441\u0442\u0443\u043f\u043d\u044b\u043c\u0438 \u0432 \u0432\u0438\u0440\u0442\u0443\u0430\u043b\u044c\u043d\u043e\u043c \u043e\u043a\u0440\u0443\u0436\u0435\u043d\u0438\u0438 \u043f\u0440\u043e\u0435\u043a\u0442\u0430.<\/p>\n<h4>poetry run<\/h4>\n<p>\u041a\u043e\u043c\u0430\u043d\u0434\u0430 <strong>run<\/strong>&nbsp;\u043f\u043e\u0437\u0432\u043e\u043b\u044f\u0435\u0442 \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u0442\u044c \u043a\u043e\u043c\u0430\u043d\u0434\u044b \u0432 \u0432\u0438\u0440\u0442\u0443\u0430\u043b\u044c\u043d\u043e\u043c \u043e\u043a\u0440\u0443\u0436\u0435\u043d\u0438\u0438 \u043f\u0440\u043e\u0435\u043a\u0442\u0430. \u041d\u0430\u043f\u0440\u0438\u043c\u0435\u0440:<\/p>\n<pre><code class=\"bash\">poetry run python --version<\/code><\/pre>\n<p>\u0427\u0442\u043e \u0431\u043e\u043b\u0435\u0435 \u0438\u043d\u0442\u0435\u0440\u0435\u0441\u043d\u043e, \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e <strong>run<\/strong> \u043c\u043e\u0436\u043d\u043e \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u0442\u044c \u0441\u043a\u0440\u0438\u043f\u0442\u044b, \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u043d\u044b\u0435 \u0432 <strong>pyproject.toml<\/strong>:<\/p>\n<pre><code class=\"bash\">poetry run my-script<\/code><\/pre>\n<h3>\u0421\u0431\u043e\u0440\u043a\u0430 \u0438 \u043f\u0443\u0431\u043b\u0438\u043a\u0430\u0446\u0438\u044f \u043f\u0440\u043e\u0435\u043a\u0442\u0430<\/h3>\n<p>\u041f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u0438\u043c, \u0447\u0442\u043e \u0432\u044b \u0440\u0430\u0437\u0440\u0430\u0431\u0430\u0442\u044b\u0432\u0430\u0435\u0442\u0435 \u043a\u0430\u043a\u0443\u044e-\u0442\u043e \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0443, \u0438 \u043d\u0430\u0441\u0442\u0430\u043b \u0442\u043e\u0440\u0436\u0435\u0441\u0442\u0432\u0435\u043d\u043d\u044b\u0439 \u043c\u043e\u043c\u0435\u043d\u0442 \u0441\u0431\u043e\u0440\u043a\u0438 \u0438 \u043f\u0443\u0431\u043b\u0438\u043a\u0430\u0446\u0438\u0438. \u0418\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u044f Poetry, \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u044d\u0442\u043e \u043c\u043e\u0436\u043d\u043e \u0432\u043e\u0442 \u0442\u0430\u043a.<\/p>\n<p>\u0421\u043e\u0431\u0438\u0440\u0430\u0435\u043c \u043d\u0430\u0448 \u043f\u0430\u043a\u0435\u0442:<\/p>\n<pre><code class=\"bash\">poetry build  # \u0441\u043e\u0431\u0438\u0440\u0430\u0435\u043c \u043a\u0430\u043a sdist, \u0442\u0430\u043a \u0438 wheel poetry build --format sdist  # \u0441\u043e\u0431\u0438\u0440\u0430\u0435\u043c \u0442\u043e\u043b\u044c\u043a\u043e sdist poetry build --format wheel  # \u0441\u043e\u0431\u0438\u0440\u0430\u0435\u043c \u0442\u043e\u043b\u044c\u043a\u043e wheel<\/code><\/pre>\n<p>\u0414\u043b\u044f \u043f\u0443\u0431\u043b\u0438\u043a\u0430\u0446\u0438\u0438 \u043d\u0430 PyPI \u043f\u0440\u0435\u0434\u0432\u0430\u0440\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u043f\u043e\u043b\u0443\u0447\u0430\u0435\u043c <a href=\"https:\/\/pypi.org\/help\/#apitoken\" rel=\"noopener noreferrer nofollow\">API token<\/a> \u0438 \u0443\u0441\u0442\u0430\u043d\u0430\u0432\u043b\u0438\u0432\u0430\u0435\u043c \u0435\u0433\u043e:<\/p>\n<pre><code>poetry config pypi-token.pypi &lt;my-token&gt;<\/code><\/pre>\n<p>\u0418, \u043d\u0430\u043a\u043e\u043d\u0435\u0446, \u043f\u0443\u0431\u043b\u0438\u043a\u0443\u0435\u043c:<\/p>\n<pre><code class=\"bash\">poetry publish<\/code><\/pre>\n<p>\u0415\u0441\u043b\u0438 \u0436\u0435 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u043e\u043f\u0443\u0431\u043b\u0438\u043a\u043e\u0432\u0430\u0442\u044c \u043f\u0430\u043a\u0435\u0442 \u0432 \u043f\u0440\u0438\u0432\u0430\u0442\u043d\u044b\u0439 registry (\u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u0432 GitLab), \u0442\u043e \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0430 \u0440\u0435\u043f\u043e\u0437\u0438\u0442\u043e\u0440\u0438\u044f \u043d\u0435\u043c\u043d\u043e\u0433\u043e \u0443\u0441\u043b\u043e\u0436\u043d\u044f\u0435\u0442\u0441\u044f. \u041f\u0440\u0435\u0434\u0432\u0430\u0440\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u043d\u0435 \u0437\u0430\u0431\u044b\u0432\u0430\u0435\u043c \u0441\u0433\u0435\u043d\u0435\u0440\u0438\u0440\u043e\u0432\u0430\u0442\u044c <a href=\"https:\/\/docs.gitlab.com\/ee\/user\/profile\/personal_access_tokens.html\" rel=\"noopener noreferrer nofollow\">Personal Access Token<\/a>:<\/p>\n<pre><code class=\"bash\">poetry config repositories.gitlab \"my.gitlab.com\/projects\/1\/packages\/pypi\" poetry config http-basic.gitlab &lt;token-name&gt; &lt;secret-token&gt;  # \u0437\u0434\u0435\u0441\u044c token-name \u0438 secret-token - \u0432\u0430\u0448 Personal Access Token<\/code><\/pre>\n<p>\u041d\u0435 \u0437\u0430\u0431\u0443\u0434\u044c\u0442\u0435 \u0438\u0437\u043c\u0435\u043d\u0438\u0442\u044c <a href=\"http:\/\/my.gitlab.com\" rel=\"noopener noreferrer nofollow\">my.gitlab.com<\/a> \u043d\u0430 \u0430\u0434\u0440\u0435\u0441 \u0432\u0430\u0448\u0435\u0433\u043e GitLab, \u0430 \u0442\u0430\u043a\u0436\u0435 \u0443\u043a\u0430\u0437\u0430\u0442\u044c \u043a\u043e\u0440\u0440\u0435\u043a\u0442\u043d\u044b\u0439 ID \u043f\u0440\u043e\u0435\u043a\u0442\u0430. \u0417\u0434\u0435\u0441\u044c \u0438\u043c\u044f \u0440\u0435\u043f\u043e\u0437\u0438\u0442\u043e\u0440\u0438\u044f \u0432 Poetry \u0432\u044b\u0431\u0440\u0430\u043d\u043e gitlab, \u043c\u043e\u0436\u043d\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0434\u0440\u0443\u0433\u043e\u0435 \u043d\u0430 \u0432\u0430\u0448\u0435 \u0443\u0441\u043c\u043e\u0442\u0440\u0435\u043d\u0438\u0435. \u041f\u043e\u0440\u0430 \u043f\u0443\u0431\u043b\u0438\u043a\u043e\u0432\u0430\u0442\u044c:<\/p>\n<pre><code class=\"bash\">poetry publish --repository gitlab<\/code><\/pre>\n<p>\u0412 \u043a\u0430\u0447\u0435\u0441\u0442\u0432\u0435 \u0431\u043e\u043d\u0443\u0441\u0430 &#8212; \u043f\u0440\u0438\u043c\u0435\u0440 \u043f\u0443\u0431\u043b\u0438\u043a\u0430\u0446\u0438\u0438 \u043f\u0440\u0438 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0438 GitLab CI:<\/p>\n<pre><code class=\"yaml\">build_and_publish:   stage: build_and_publish   script:     - poetry install --without dev     - poetry build     - poetry config repositories.gitlab \"${CI_API_V4_URL}\/projects\/${CI_PROJECT_ID}\/packages\/pypi\"     - poetry config http-basic.gitlab gitlab-ci-token \"$CI_JOB_TOKEN\"     - poetry publish --repository gitlab<\/code><\/pre>\n<h3>\u041d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0430 poetry<\/h3>\n<p>\u0412 \u044d\u0442\u043e\u043c \u0440\u0430\u0437\u0434\u0435\u043b\u0435 \u043a\u0440\u0430\u0442\u043a\u043e \u043f\u0440\u043e\u0431\u0435\u0436\u0438\u043c\u0441\u044f \u043f\u043e \u043e\u0441\u043d\u043e\u0432\u043d\u044b\u043c \u043a\u043e\u043c\u0430\u043d\u0434\u0430\u043c \u0434\u043b\u044f \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0438 \u0438 \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u044f \u043d\u0435\u043f\u043e\u0441\u0440\u0435\u0434\u0441\u0442\u0432\u0435\u043d\u043d\u043e Poetry.<\/p>\n<h4>\u041e\u0431\u043d\u043e\u0432\u043b\u0435\u043d\u0438\u0435 Poetry<\/h4>\n<p>\u041e\u0431\u043d\u043e\u0432\u0438\u0442\u044c\u0441\u044f \u043c\u043e\u0436\u043d\u043e \u043a\u0430\u043a \u043d\u0430 \u0431\u043e\u043b\u0435\u0435 \u043d\u043e\u0432\u0443\u044e, \u0442\u0430\u043a \u0438 \u043d\u0430 \u0431\u043e\u043b\u0435\u0435 \u0441\u0442\u0430\u0440\u0443\u044e \u0432\u0435\u0440\u0441\u0438\u044e.<strong> \u0411\u0443\u0434\u044c\u0442\u0435 \u0430\u043a\u043a\u0443\u0440\u0430\u0442\u043d\u044b<\/strong> &#8212; \u0435\u0441\u043b\u0438 \u043e\u0431\u043d\u043e\u0432\u0438\u0442\u044c\u0441\u044f \u043d\u0430 \u0432\u0435\u0440\u0441\u0438\u044e \u043d\u0438\u0436\u0435 1.2, \u0442\u043e \u043e\u0431\u043d\u043e\u0432\u043b\u0435\u043d\u0438\u0435 \u043d\u0430 \u0431\u043e\u043b\u0435\u0435 \u0432\u044b\u0441\u043e\u043a\u0443\u044e \u0432\u0435\u0440\u0441\u0438\u044e \u0431\u0443\u0434\u0435\u0442 \u043d\u0435\u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e \u0438 \u043f\u0440\u0438\u0434\u0435\u0442\u0441\u044f \u043f\u0435\u0440\u0435\u0443\u0441\u0442\u0430\u043d\u0430\u0432\u043b\u0438\u0432\u0430\u0442\u044c Poetry:<\/p>\n<pre><code class=\"bash\">poetry self update 1.3.2<\/code><\/pre>\n<h4>\u0423\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u0435 \u043f\u043b\u0430\u0433\u0438\u043d\u0430\u043c\u0438<\/h4>\n<p>\u0414\u043b\u044f \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0438, \u0443\u0434\u0430\u043b\u0435\u043d\u0438\u044f \u0438 \u043e\u0431\u043d\u043e\u0432\u043b\u0435\u043d\u0438\u044f \u043f\u043b\u0430\u0433\u0438\u043d\u043e\u0432 \u043c\u043e\u0436\u043d\u043e \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c\u0441\u044f \u043a\u043e\u043c\u0430\u043d\u0434\u0430\u043c\u0438 <strong>self add<\/strong>, <strong>self remove<\/strong> \u0438 <strong>self update<\/strong> \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0435\u043d\u043d\u043e. \u041c\u0435\u0445\u0430\u043d\u0438\u0437\u043c \u0440\u0430\u0431\u043e\u0442\u044b \u044d\u0442\u0438\u0445 \u043a\u043e\u043c\u0430\u043d\u0434 \u0430\u043d\u0430\u043b\u043e\u0433\u0438\u0447\u0435\u043d \u043c\u0435\u0445\u0430\u043d\u0438\u0437\u043c\u0443 \u0440\u0430\u0431\u043e\u0442\u044b \u043a\u043e\u043c\u0430\u043d\u0434 <strong>add<\/strong>, <strong>remove<\/strong>, <strong>update<\/strong> \u0437\u0430 \u0438\u0441\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0435\u043c \u0442\u043e\u0433\u043e, \u0447\u0442\u043e \u043a\u043e\u043c\u0430\u043d\u0434\u044b \u0432 \u043f\u0440\u043e\u0441\u0442\u0440\u0430\u043d\u0441\u0442\u0432\u0435 \u0438\u043c\u0435\u043d <strong>self<\/strong> \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0435\u0442\u0441\u044f \u0432 \u0432\u0438\u0440\u0442\u0443\u0430\u043b\u044c\u043d\u043e\u043c \u043e\u043a\u0440\u0443\u0436\u0435\u043d\u0438\u0438 \u0441\u0430\u043c\u043e\u0433\u043e Poetry.&nbsp;<\/p>\n<p>\u041f\u0440\u0438 \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u0438 \u043f\u043b\u0430\u0433\u0438\u043d\u0430\u043c\u0438 \u043d\u0430\u043c \u0442\u0430\u043a\u0436\u0435 \u0434\u043e\u0441\u0442\u0443\u043f\u043d\u044b \u043a\u043e\u043c\u0430\u043d\u0434\u044b <strong>self lock<\/strong> \u0438 <strong>self install<\/strong>. \u0420\u0430\u0431\u043e\u0442\u0430\u044e\u0442 \u043e\u043d\u0438 \u0430\u043d\u0430\u043b\u043e\u0433\u0438\u0447\u043d\u043e \u0432\u044b\u0448\u0435\u0443\u043f\u043e\u043c\u044f\u043d\u0443\u0442\u044b\u043c \u043a\u043e\u043c\u0430\u043d\u0434\u0430\u043c.<\/p>\n<h4>\u041d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0430 Poetry<\/h4>\n<p>\u041a\u043e\u043c\u0430\u043d\u0434\u0430 <strong>config<\/strong>, \u043f\u043e\u043c\u0438\u043c\u043e \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u044f \u0440\u0435\u043f\u043e\u0437\u0438\u0442\u043e\u0440\u0438\u044f\u043c\u0438, \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u0435\u0442 \u0440\u0435\u0434\u0430\u043a\u0442\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0438 Poetry:<\/p>\n<pre><code class=\"bash\"># [setting-key] - \u0438\u043c\u044f \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0438 # [setting-value] - \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 poetry config [options] [setting-key] [setting-value1] ... [setting-valueN]<\/code><\/pre>\n<p>\u0427\u0430\u0449\u0435 \u0432\u0441\u0435\u0433\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u044e\u0442\u0441\u044f \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u0435 \u043e\u043f\u0446\u0438\u0438:<\/p>\n<ul>\n<li>\n<p><strong>cache-dir<\/strong> (\u0441\u0442\u0440\u043e\u043a\u0430) &#8212; \u0434\u0438\u0440\u0435\u043a\u0442\u043e\u0440\u0438\u044f \u0434\u043b\u044f \u043a\u044d\u0448\u0430 Poetry<\/p>\n<\/li>\n<li>\n<p><strong>virtualenvs.create<\/strong> (true \/ false) &#8212; \u0441\u043e\u0437\u0434\u0430\u0432\u0430\u0442\u044c \u043b\u0438 \u0432\u0438\u0440\u0442\u0443\u0430\u043b\u044c\u043d\u044b\u0435 \u043e\u043a\u0440\u0443\u0436\u0435\u043d\u0438\u044f \u0434\u043b\u044f \u043f\u0440\u043e\u0435\u043a\u0442\u043e\u0432 (\u0435\u0441\u043b\u0438 \u043d\u0435 \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u044e\u0442). \u0411\u0443\u0434\u044c\u0442\u0435 \u0432\u043d\u0438\u043c\u0430\u0442\u0435\u043b\u044c\u043d\u044b: \u0435\u0441\u043b\u0438 \u0432\u044b \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u0435 \u0434\u0430\u043d\u043d\u0443\u044e \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0443 \u0432 false \u0438 Poetry \u043d\u0435 \u043e\u0431\u043d\u0430\u0440\u0443\u0436\u0438\u0442 \u0432\u0438\u0440\u0442\u0443\u0430\u043b\u044c\u043d\u043e\u0435 \u043e\u043a\u0440\u0443\u0436\u0435\u043d\u0438\u0435 \u0432 \u043f\u0430\u043f\u043a\u0430\u0445 {cache-dir}\/virtualenvs \u0438\u043b\u0438 {project-dir}\/.venv, \u0442\u043e \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0430 \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u0435\u0439 \u0431\u0443\u0434\u0435\u0442 \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0442\u044c\u0441\u044f \u0432 \u0441\u0438\u0441\u0442\u0435\u043c\u043d\u044b\u0439 Python.<\/p>\n<\/li>\n<li>\n<p><strong>virtualenvs.in-project<\/strong> (true \/ false) &#8212;&nbsp;\u0441\u043e\u0437\u0434\u0430\u0432\u0430\u0442\u044c \u0432\u0438\u0440\u0442\u0443\u0430\u043b\u044c\u043d\u044b\u0435 \u043e\u043a\u0440\u0443\u0436\u0435\u043d\u0438\u044f \u0432 \u043a\u043e\u0440\u043d\u0435 \u043f\u0440\u043e\u0435\u043a\u0442\u0430. \u041f\u043e \u0443\u043c\u043e\u043b\u0447\u0430\u043d\u0438\u044e, Poetry \u0441\u043e\u0437\u0434\u0430\u0435\u0442 \u0432\u0438\u0440\u0442\u0443\u0430\u043b\u044c\u043d\u044b\u0435 \u043e\u043a\u0440\u0443\u0436\u0435\u043d\u0438\u044f \u0432 \u043f\u0430\u043f\u043a\u0435&nbsp;{cache-dir}\/virtualenvs.<\/p>\n<\/li>\n<\/ul>\n<p>\u041e\u0441\u0442\u0430\u043b\u044c\u043d\u044b\u0435 \u043e\u043f\u0446\u0438\u0438 \u043c\u043e\u0436\u043d\u043e \u043d\u0430\u0439\u0442\u0438 \u0432 <a href=\"https:\/\/python-poetry.org\/docs\/configuration\/#available-settings\" rel=\"noopener noreferrer nofollow\">\u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u0430\u0446\u0438\u0438<\/a>.<\/p>\n<h3>\u0411\u043e\u043d\u0443\u0441 &#8212; Docker-\u043e\u0431\u0440\u0430\u0437 \u0432 \u043f\u0440\u043e\u0435\u043a\u0442\u0430\u0445 \u0441 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435\u043c Poetry<\/h3>\n<p>\u0414\u0430\u0432\u0430\u0439\u0442\u0435 \u0440\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0438\u043c, \u043a\u0430\u043a \u0441\u043e\u0431\u0440\u0430\u0442\u044c \u043c\u0430\u043a\u0441\u0438\u043c\u0430\u043b\u044c\u043d\u043e \u043a\u043e\u043c\u043f\u0430\u043a\u0442\u043d\u044b\u0439 Docker-\u043e\u0431\u0440\u0430\u0437, \u0435\u0441\u043b\u0438 \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u043a\u0443 \u043d\u0430\u0448\u0435\u0433\u043e \u043f\u0440\u043e\u0435\u043a\u0442\u0430 \u043c\u044b \u0432\u0435\u043b\u0438 \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e Poetry. \u0418\u043c\u0435\u0435\u043c \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u0439 <strong>pyproject.toml<\/strong>:<\/p>\n<pre><code class=\"bash\">[tool.poetry] name = \"my-project\" version = \"0.1.0\" description = \"\" authors = [\"Your Name &lt;you@example.com&gt;\"] readme = \"README.md\"  [tool.poetry.dependencies] python = \"&gt;=3.8.1,&lt;4.0\" fastapi = \"^0.95.2\" sqlalchemy = \"^2.0.15\" uvicorn = \"^0.22.0\"  [tool.poetry.group.test.dependencies] pytest = \"^7.3.1\"   [tool.poetry.group.dev.dependencies] flake8 = \"^6.0.0\"  [build-system] requires = [\"poetry-core\"] build-backend = \"poetry.core.masonry.api\"<\/code><\/pre>\n<p>\u041d\u0430\u0448\u0435 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0435 &#8212; \u044d\u0442\u043e \u0432\u043e\u0442 \u0442\u0430\u043a\u043e\u0435 \u0437\u0430\u043c\u0435\u0447\u0430\u0442\u0435\u043b\u044c\u043d\u043e\u0435 REST API:<\/p>\n<pre><code class=\"python\">from fastapi import FastAPI  app = FastAPI()   @app.get('\/hello') def hello():     return 'hello, world!'<\/code><\/pre>\n<p>\u041f\u0435\u0440\u0432\u044b\u0439 \u0441\u043f\u043e\u0441\u043e\u0431, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0441\u0440\u0430\u0437\u0443 \u043f\u0440\u0438\u0445\u043e\u0434\u0438\u0442 \u0432 \u0433\u043e\u043b\u043e\u0432\u0443 &#8212; \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u043c Poetry \u0432 \u043e\u0431\u0440\u0430\u0437, \u0447\u0435\u0440\u0435\u0437 \u043d\u0435\u0433\u043e \u043f\u043e\u0441\u0442\u0430\u0432\u0438\u043c \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u0438 \u0438 \u0437\u0430\u043f\u0443\u0441\u0442\u0438\u043c \u043d\u0430\u0448 \u0441\u0435\u0440\u0432\u0438\u0441. Dockerfile \u0432 \u0442\u0430\u043a\u043e\u043c \u0441\u043b\u0443\u0447\u0430\u0435 \u0432\u044b\u0433\u043b\u044f\u0434\u0438\u0442 \u043f\u0440\u0438\u043c\u0435\u0440\u043d\u043e \u0432\u043e\u0442 \u0442\u0430\u043a:<\/p>\n<pre><code class=\"bash\">FROM python:3.8.16-slim-bullseye  WORKDIR \/app  COPY poetry.lock pyproject.toml .\/  RUN python -m pip install --no-cache-dir poetry==1.4.2 \\     &amp;&amp; poetry config virtualenvs.create false \\     &amp;&amp; poetry install --without dev,test --no-interaction --no-ansi \\     &amp;&amp; rm -rf $(poetry config cache-dir)\/{cache,artifacts}  COPY app.py .\/  CMD [\"uvicorn\", \"app:app\", \"--host\", \"0.0.0.0\", \"--port\", \"80\"]<\/code><\/pre>\n<p>\u0421\u043e\u0431\u0438\u0440\u0430\u0435\u043c \u043e\u0431\u0440\u0430\u0437:<\/p>\n<pre><code class=\"bash\">docker image build -t poetry-tutorial-naive:latest -f Dockerfile.naive .<\/code><\/pre>\n<p>\u041f\u043e\u043b\u0443\u0447\u0430\u0435\u043c \u043e\u0431\u0440\u0430\u0437 \u0440\u0430\u0437\u043c\u0435\u0440\u043e\u043c 225MB. \u041d\u0435\u043f\u043b\u043e\u0445\u043e, \u043d\u043e \u043c\u043e\u0436\u043d\u043e \u0438 \u043c\u0435\u043d\u044c\u0448\u0435. \u0414\u0430\u0432\u0430\u0439\u0442\u0435 \u043f\u043e\u043f\u0440\u043e\u0431\u0443\u0435\u043c \u043f\u0440\u0438\u043c\u0435\u043d\u0438\u0442\u044c multi-stage \u0441\u0431\u043e\u0440\u043a\u0443. \u041d\u0430 \u043f\u0435\u0440\u0432\u043e\u043c \u044d\u0442\u0430\u043f\u0435 \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e Poetry \u043f\u043e\u0434\u0433\u043e\u0442\u043e\u0432\u0438\u043c \u0432\u0438\u0440\u0442\u0443\u0430\u043b\u044c\u043d\u043e\u0435 \u043e\u043a\u0440\u0443\u0436\u0435\u043d\u0438\u0435, \u0430 \u043f\u043e\u0442\u043e\u043c \u0441\u043a\u043e\u043f\u0438\u0440\u0443\u0435\u043c \u0435\u0433\u043e \u0432 \u043d\u0430\u0448 \u0438\u0442\u043e\u0433\u043e\u0432\u044b\u0439 \u043e\u0431\u0440\u0430\u0437. \u0418\u0442\u0430\u043a, Dockerfile:<\/p>\n<pre><code class=\"bash\">FROM python:3.8.16-slim-bullseye AS builder  WORKDIR \/app COPY poetry.lock pyproject.toml .\/  RUN python -m pip install --no-cache-dir poetry==1.4.2 \\     &amp;&amp; poetry config virtualenvs.in-project true \\     &amp;&amp; poetry install --without dev,test --no-interaction --no-ansi  FROM python:3.8.16-slim-bullseye  COPY --from=builder \/app \/app COPY app.py .\/  CMD [\"\/app\/.venv\/bin\/uvicorn\", \"app:app\", \"--host\", \"0.0.0.0\", \"--port\", \"80\"]<\/code><\/pre>\n<p>\u0421\u043e\u0431\u0438\u0440\u0430\u0435\u043c:<\/p>\n<pre><code class=\"bash\">docker image build -t poetry-tutorial-copy:latest -f Dockerfile.copy .<\/code><\/pre>\n<p>\u041f\u043e\u043b\u0443\u0447\u0430\u0435\u043c \u043e\u0431\u0440\u0430\u0437 \u0440\u0430\u0437\u043c\u0435\u0440\u043e\u043c 159MB. \u0423\u0436\u0435 \u0433\u043e\u0440\u0430\u0437\u0434\u043e \u043b\u0443\u0447\u0448\u0435!<\/p>\n<p>\u041c\u043e\u0436\u0435\u0442 \u0431\u044b\u0442\u044c, \u0435\u0441\u043b\u0438 \u044d\u043a\u0441\u043f\u043e\u0440\u0442\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0432\u0441\u0435 \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u0438 \u0432 \u043f\u0440\u0438\u0432\u044b\u0447\u043d\u044b\u0439 requirements.txt \u0438 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u044c \u0447\u0435\u0440\u0435\u0437 pip, \u0442\u043e \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u0441\u044f \u0435\u0449\u0435 \u043a\u043e\u043c\u043f\u0430\u043a\u0442\u043d\u0435\u0435? \u041f\u043e\u043f\u0440\u043e\u0431\u0443\u0435\u043c:<\/p>\n<pre><code class=\"bash\">FROM python:3.8.16-slim-bullseye AS builder  COPY poetry.lock pyproject.toml .\/ RUN python -m pip install --no-cache-dir poetry==1.4.2 \\     &amp;&amp; poetry export --without-hashes --without dev,test -f requirements.txt -o requirements.txt  FROM python:3.8.16-slim-bullseye  WORKDIR \/app  COPY --from=builder requirements.txt .\/ RUN python -m pip install --no-cache-dir -r requirements.txt  COPY app.py .\/  CMD [\"uvicorn\", \"app:app\", \"--host\", \"0.0.0.0\", \"--port\", \"80\"]<\/code><\/pre>\n<p>\u0421\u043e\u0431\u0438\u0440\u0430\u0435\u043c \u043e\u0431\u0440\u0430\u0437:<\/p>\n<pre><code class=\"bash\">docker image build --no-cache -t poetry-tutorial-requirements:latest -f Dockerfile.requirements<\/code><\/pre>\n<p>\u041f\u043e\u043b\u0443\u0447\u0438\u043b\u043e\u0441\u044c 163MB, \u0447\u0442\u043e \u043d\u0435\u043c\u043d\u043e\u0433\u043e \u0431\u043e\u043b\u044c\u0448\u0435, \u0447\u0435\u043c \u0443 \u043f\u0440\u0435\u0434\u044b\u0434\u0443\u0449\u0435\u0433\u043e \u0441\u043f\u043e\u0441\u043e\u0431\u0430, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0438 \u0432\u044b\u0448\u0435\u043b \u043f\u043e\u0431\u0435\u0434\u0438\u0442\u0435\u043b\u0435\u043c.<\/p>\n<p>\u0418\u0442\u043e\u0433\u043e\u0432\u0430\u044f \u0442\u0430\u0431\u043b\u0438\u0446\u0430:<\/p>\n<div>\n<div class=\"table\">\n<table>\n<tbody>\n<tr>\n<th data-colwidth=\"372\" width=\"372\">\n<p align=\"center\">\u0421\u043f\u043e\u0441\u043e\u0431<\/p>\n<\/th>\n<th>\n<p align=\"center\">\u0420\u0430\u0437\u043c\u0435\u0440 \u043e\u0431\u0440\u0430\u0437\u0430<\/p>\n<\/th>\n<\/tr>\n<tr>\n<td data-colwidth=\"372\" width=\"372\">\n<p align=\"center\">\u041d\u0430\u0438\u0432\u043d\u044b\u0439<\/p>\n<\/td>\n<td>\n<p align=\"center\">225MB (-0.0%)<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"372\" width=\"372\">\n<p align=\"center\">\u042d\u043a\u0441\u043f\u043e\u0440\u0442 requirements.txt \u0438 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0430 \u0447\u0435\u0440\u0435\u0437 pip<\/p>\n<\/td>\n<td>\n<p align=\"center\">163MB (-27.5%)<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"372\" width=\"372\">\n<p align=\"center\">\u041a\u043e\u043f\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435 venv<\/p>\n<\/td>\n<td>\n<p align=\"center\">159MB (-29.3%)<\/p>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<p>\u041e\u0431\u0440\u0430\u0442\u0438\u0442\u0435 \u0432\u043d\u0438\u043c\u0430\u043d\u0438\u0435 \u043d\u0430 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u0435 \u0432\u0435\u0449\u0438:<\/p>\n<ul>\n<li>\n<p>\u0436\u0435\u0441\u0442\u043a\u043e \u0444\u0438\u043a\u0441\u0438\u0440\u0443\u0439\u0442\u0435 \u0432\u0435\u0440\u0441\u0438\u044e Poetry \u0432 \u0432\u0430\u0448\u0438\u0445 Dockerfile&#8217;\u0430\u0445. \u0420\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u0447\u0438\u043a\u0438 Poetry \u043e\u0447\u0435\u043d\u044c \u043b\u044e\u0431\u044f\u0442 \u0447\u0442\u043e-\u0442\u043e \u043b\u043e\u043c\u0430\u0442\u044c \u043e\u0442 \u0440\u0435\u043b\u0438\u0437\u0430 \u043a \u0440\u0435\u043b\u0438\u0437\u0443, \u0438\u043b\u0438 \u043e\u0431\u044a\u044f\u0432\u043b\u044f\u0442\u044c \u0441\u0442\u0430\u0432\u0448\u0438\u0435 \u043f\u0440\u0438\u0432\u044b\u0447\u043d\u044b\u043c\u0438 \u0432\u0435\u0449\u0438 deprecated.<\/p>\n<\/li>\n<li>\n<p>\u043d\u0435 \u0442\u0430\u0449\u0438\u0442\u0435 \u043b\u0438\u0448\u043d\u0438\u0435 \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u0438 \u0432 \u0432\u0430\u0448\u0438 \u043e\u0431\u0440\u0430\u0437\u044b. \u0418\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0439\u0442\u0435 \u0444\u043b\u0430\u0433 &#8212;without.<\/p>\n<\/li>\n<\/ul>\n<p>\u041d\u0430 \u044d\u0442\u043e\u043c \u0443 \u043c\u0435\u043d\u044f \u0432\u0441\u0435.<\/p>\n<p>\u0414\u0435\u043b\u0438\u0442\u0435\u0441\u044c \u0441\u0432\u043e\u0438\u043c\u0438 \u0432\u043f\u0435\u0447\u0430\u0442\u043b\u0435\u043d\u0438\u044f\u043c\u0438 \u043e\u0442 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u044f Poetry \u0432 \u0432\u0430\u0448\u0438\u0445 \u043f\u0440\u043e\u0435\u043a\u0442\u0430\u0445, \u0441 \u043a\u0430\u043a\u0438\u043c\u0438 \u0442\u0440\u0443\u0434\u043d\u043e\u0441\u0442\u044f\u043c\u0438 \u0441\u0442\u043e\u043b\u043a\u043d\u0443\u043b\u0438\u0441\u044c \u0438 \u043a\u0430\u043a \u0438\u0445 \u043f\u0440\u0435\u043e\u0434\u043e\u043b\u0435\u0432\u0430\u043b\u0438. \u041c\u043e\u0436\u0435\u0442 \u0431\u044b\u0442\u044c, \u0432\u044b \u0432\u043e\u043e\u0431\u0449\u0435 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0435 \u043a\u0430\u043a\u043e\u0439-\u0442\u043e \u0431\u043e\u043b\u0435\u0435 \u043a\u0440\u0443\u0442\u043e\u0439 \u0438\u043d\u0441\u0442\u0440\u0443\u043c\u0435\u043d\u0442?&nbsp;&nbsp;<\/p>\n<p>\u0421\u043f\u0430\u0441\u0438\u0431\u043e \u0437\u0430 \u0432\u043d\u0438\u043c\u0430\u043d\u0438\u0435, \u0438 \u0431\u0443\u0434\u0443 \u0440\u0430\u0434 \u043e\u0442\u0432\u0435\u0442\u0438\u0442\u044c \u043d\u0430 \u0432\u0430\u0448\u0438 \u0432\u043e\u043f\u0440\u043e\u0441\u044b \u0432 \u043a\u043e\u043c\u043c\u0435\u043d\u0442\u0430\u0440\u0438\u044f\u0445!<\/p>\n<\/p>\n<\/div>\n<\/div>\n<p> <!----> <!----><\/div>\n<p> <!----> <!----><br \/> \u0441\u0441\u044b\u043b\u043a\u0430 \u043d\u0430 \u043e\u0440\u0438\u0433\u0438\u043d\u0430\u043b \u0441\u0442\u0430\u0442\u044c\u0438 <a href=\"https:\/\/habr.com\/ru\/articles\/740376\/\"> https:\/\/habr.com\/ru\/articles\/740376\/<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<div><\/div>\n<div id=\"post-content-body\">\n<div>\n<div class=\"article-formatted-body article-formatted-body article-formatted-body_version-2\">\n<p>\u041f\u0440\u0438\u0432\u0435\u0442, \u0425\u0430\u0431\u0440! \u041c\u0435\u043d\u044f \u0437\u043e\u0432\u0443\u0442 \u0422\u0438\u043c\u0443\u0440, \u044f \u0442\u0440\u0443\u0436\u0443\u0441\u044c ML-\u0438\u043d\u0436\u0435\u043d\u0435\u0440\u043e\u043c \u0432 \u043e\u0434\u043d\u043e\u0439 \u0441\u0438\u0431\u0438\u0440\u0441\u043a\u043e\u0439 IT-\u043a\u043e\u043c\u043f\u0430\u043d\u0438\u0438.<\/p>\n<p>\u0414\u0430\u043d\u043d\u0430\u044f \u0441\u0442\u0430\u0442\u044c\u044f \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u044f\u0435\u0442 \u0441\u043e\u0431\u043e\u0439 \u0440\u0443\u043a\u043e\u0432\u043e\u0434\u0441\u0442\u0432\u043e \u043f\u043e Poetry. \u042f \u043f\u043e\u0441\u0442\u0430\u0440\u0430\u043b\u0441\u044f \u043f\u043e\u043a\u0440\u044b\u0442\u044c \u0432\u0441\u0435 \u043e\u0441\u043d\u043e\u0432\u043d\u044b\u0435 \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0438 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u044f \u0438 \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e\u0441\u0442\u0438 \u0434\u0430\u043d\u043d\u043e\u0433\u043e \u0438\u043d\u0441\u0442\u0440\u0443\u043c\u0435\u043d\u0442\u0430: \u0441\u043e\u0437\u0434\u0430\u043d\u0438\u0435 \u043f\u0440\u043e\u0435\u043a\u0442\u0430, \u0440\u0430\u0431\u043e\u0442\u0430 \u0441 \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u044f\u043c\u0438 \u0438\u0437 \u0440\u0430\u0437\u043b\u0438\u0447\u043d\u044b\u0445 \u0438\u0441\u0442\u043e\u0447\u043d\u0438\u043a\u043e\u0432, \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u0435 \u0432\u0438\u0440\u0442\u0443\u0430\u043b\u044c\u043d\u044b\u043c\u0438 \u043e\u043a\u0440\u0443\u0436\u0435\u043d\u0438\u044f\u043c\u0438, \u0441\u0431\u043e\u0440\u043a\u0430 \u0438 \u043f\u0443\u0431\u043b\u0438\u043a\u0430\u0446\u0438\u044f.<\/p>\n<p>\u0412 \u043a\u0430\u0447\u0435\u0441\u0442\u0432\u0435 \u0431\u043e\u043d\u0443\u0441\u043e\u0432 &#8212; \u0433\u043e\u0442\u043e\u0432\u0430\u044f GitLab CI \u0434\u0436\u043e\u0431\u0430 \u0434\u043b\u044f \u0441\u0431\u043e\u0440\u043a\u0438 \u0438 \u043f\u0443\u0431\u043b\u0438\u043a\u0430\u0446\u0438\u0438 \u043f\u0430\u043a\u0435\u0442\u043e\u0432, \u0430 \u0442\u0430\u043a\u0436\u0435 \u0448\u0430\u0431\u043b\u043e\u043d Dockerfile \u0434\u043b\u044f multi-stage \u0441\u0431\u043e\u0440\u043a\u0438 \u043e\u0431\u0440\u0430\u0437\u043e\u0432 \u0432 \u043f\u0440\u043e\u0435\u043a\u0442\u0430\u0445 \u0441 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435\u043c Poetry.<\/p>\n<p>\u0414\u043e\u0431\u0440\u043e \u043f\u043e\u0436\u0430\u043b\u043e\u0432\u0430\u0442\u044c \u043f\u043e\u0434 \u043a\u0430\u0442!<\/p>\n<h2>\u0427\u0442\u043e \u0442\u0430\u043a\u043e\u0435 Poetry?<\/h2>\n<p>Poetry &#8212; \u044d\u0442\u043e \u0438\u043d\u0441\u0442\u0440\u0443\u043c\u0435\u043d\u0442 \u0434\u043b\u044f \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u044f \u043f\u0440\u043e\u0435\u043a\u0442\u0430\u043c\u0438 \u043d\u0430 Python, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043f\u0440\u0435\u0434\u043e\u0441\u0442\u0430\u0432\u043b\u044f\u0435\u0442 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u0435 \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e\u0441\u0442\u0438:<\/p>\n<ul>\n<li>\n<p>\u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u0435 \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u044f\u043c\u0438 \u0441 \u0432\u043e\u0441\u043f\u0440\u043e\u0438\u0437\u0432\u043e\u0434\u0438\u043c\u044b\u043c\u0438 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0430\u043c\u0438 \u0438 \u0440\u0435\u0437\u043e\u043b\u0432\u0435\u0440\u043e\u043c \u043a\u043e\u043d\u0444\u043b\u0438\u043a\u0442\u043e\u0432<\/p>\n<\/li>\n<li>\n<p>\u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u043e\u0435 \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u0435 \u0432\u0438\u0440\u0442\u0443\u0430\u043b\u044c\u043d\u044b\u043c\u0438 \u043e\u043a\u0440\u0443\u0436\u0435\u043d\u0438\u044f\u043c\u0438<\/p>\n<\/li>\n<li>\n<p>\u0441\u0431\u043e\u0440\u043a\u0430 \u0438 \u043f\u0443\u0431\u043b\u0438\u043a\u0430\u0446\u0438\u044f.<\/p>\n<\/li>\n<\/ul>\n<h2>\u0423\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0430<\/h2>\n<p>\u0423\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0430 Poetry \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0435\u0442\u0441\u044f \u043e\u0447\u0435\u043d\u044c \u043f\u0440\u043e\u0441\u0442\u043e \u043a\u0430\u043a \u043d\u0430 Unix-\u0441\u0438\u0441\u0442\u0435\u043c\u0430\u0445:<\/p>\n<pre><code class=\"bash\">curl -sSL https:\/\/install.python-poetry.org | python3 -<\/code><\/pre>\n<p>\u0422\u0430\u043a \u0438 \u043d\u0430 Windows:<\/p>\n<pre><code class=\"bash\">(Invoke-WebRequest -Uri https:\/\/install.python-poetry.org -UseBasicParsing).Content | py -<\/code><\/pre>\n<p>\u0414\u0430\u043b\u0435\u0435, \u0432 \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u0438 \u043e\u0442 \u0432\u0430\u0448\u0435\u0439 \u0441\u0438\u0441\u0442\u0435\u043c\u044b, \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u0434\u043e\u0431\u0430\u0432\u0438\u0442\u044c \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0443\u044e\u0449\u0443\u044e \u0434\u0438\u0440\u0435\u043a\u0442\u043e\u0440\u0438\u044e \u0432 PATH:<\/p>\n<pre><code class=\"bash\"># Linux, MacOS, WSL $HOME\/.local\/bin    # Windows %APPDATA%\\Python\\Scripts<\/code><\/pre>\n<p>\u041f\u0435\u0440\u0435\u0437\u0430\u0433\u0440\u0443\u0436\u0430\u0435\u043c \u043e\u0431\u043e\u043b\u043e\u0447\u043a\u0443 \u0438 \u043f\u0440\u043e\u0432\u0435\u0440\u044f\u0435\u043c \u043a\u043e\u0440\u0440\u0435\u043a\u0442\u043d\u043e\u0441\u0442\u044c \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0438:<\/p>\n<pre><code class=\"bash\">poetry --version   # \u0412\u044b\u0432\u043e\u0434 \u0434\u043e\u043b\u0436\u0435\u043d \u0431\u044b\u0442\u044c \u043f\u0440\u0438\u043c\u0435\u0440\u043d\u043e \u0442\u0430\u043a\u0438\u043c # Poetry (version 1.4.2)<\/code><\/pre>\n<h2>\u0418\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435<\/h2>\n<h3>\u0421\u043e\u0437\u0434\u0430\u043d\u0438\u0435 \u043f\u0440\u043e\u0435\u043a\u0442\u0430<\/h3>\n<h4>\u041a\u0430\u043a \u0441\u043e\u0437\u0434\u0430\u0442\u044c \u043f\u0440\u043e\u0435\u043a\u0442 \u0447\u0435\u0440\u0435\u0437 \u0442\u0435\u0440\u043c\u0438\u043d\u0430\u043b<\/h4>\n<p>\u0414\u043b\u044f \u0441\u043e\u0437\u0434\u0430\u043d\u0438\u044f \u043f\u0440\u043e\u0435\u043a\u0442\u0430 \u0441 \u043d\u0443\u043b\u044f \u0432\u043e\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u043c\u0441\u044f \u043a\u043e\u043c\u0430\u043d\u0434\u043e\u0439&nbsp;<strong>new<\/strong>:<\/p>\n<pre><code class=\"bash\">poetry new my-project<\/code><\/pre>\n<p>\u041f\u0440\u0438 \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u0438 \u044d\u0442\u043e\u0439 \u043a\u043e\u043c\u0430\u043d\u0434\u044b Poetry \u0441\u043e\u0437\u0434\u0430\u0441\u0442 \u043f\u0430\u043f\u043a\u0443 \u0441\u043e \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0435\u0439 \u0441\u0442\u0440\u0443\u043a\u0442\u0443\u0440\u043e\u0439. \u041d\u0430\u0438\u0431\u043e\u043b\u0435\u0435 \u0438\u043d\u0442\u0435\u0440\u0435\u0441\u0435\u043d \u0437\u0434\u0435\u0441\u044c \u0444\u0430\u0439\u043b&nbsp;<strong>pyproject.toml<\/strong>, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043c\u044b \u0440\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0438\u043c \u0432 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0435\u0439 \u0441\u0435\u043a\u0446\u0438\u0438:<\/p>\n<pre><code class=\"bash\">my-project\/ \u251c\u2500\u2500 README.md \u251c\u2500\u2500 my_project \u2502   \u2514\u2500\u2500 __init__.py \u251c\u2500\u2500 pyproject.toml \u2514\u2500\u2500 tests     \u2514\u2500\u2500 __init__.py   2 directories, 4 files<\/code><\/pre>\n<p>\u0415\u0441\u043b\u0438 \u0436\u0435 \u043c\u044b \u0445\u043e\u0442\u0438\u043c \u043d\u0430\u0447\u0430\u0442\u044c \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c Poetry \u0432 \u0443\u0436\u0435 \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u044e\u0449\u0435\u043c \u043f\u0440\u043e\u0435\u043a\u0442\u0435, \u0442\u043e \u043d\u0430\u043c \u043f\u043e\u043c\u043e\u0436\u0435\u0442 \u043a\u043e\u043c\u0430\u043d\u0434\u0430&nbsp;<strong>init<\/strong>:<\/p>\n<pre><code class=\"bash\">cd my-project2 poetry init<\/code><\/pre>\n<p>\u0414\u0430\u043b\u0435\u0435, Poetry \u0437\u0430\u0434\u0430\u0441\u0442 \u043d\u0430\u043c \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u0432\u043e\u043f\u0440\u043e\u0441\u043e\u0432 \u043e \u043d\u0430\u0448\u0435\u043c \u043f\u0440\u043e\u0435\u043a\u0442\u0435 (\u0438\u043c\u044f \u043f\u0430\u043a\u0435\u0442\u0430, \u0432\u0435\u0440\u0441\u0438\u044f, \u043e\u043f\u0438\u0441\u0430\u043d\u0438\u0435, \u043b\u0438\u0446\u0435\u043d\u0437\u0438\u044f \u0438 \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u0438\u0432\u0430\u0435\u043c\u044b\u0435 \u0432\u0435\u0440\u0441\u0438\u0438 Python), \u0430 \u0442\u0430\u043a\u0436\u0435 \u043f\u0440\u0435\u0434\u043b\u043e\u0436\u0438\u0442 \u0432 \u0438\u043d\u0442\u0435\u0440\u0430\u043a\u0442\u0438\u0432\u043d\u043e\u043c \u0440\u0435\u0436\u0438\u043c\u0435 \u0443\u043a\u0430\u0437\u0430\u0442\u044c \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u0438 (\u0447\u0442\u043e, \u043a\u0430\u043a \u043f\u043e \u043c\u043d\u0435, \u043d\u0435 \u043e\u0447\u0435\u043d\u044c \u0443\u0434\u043e\u0431\u043d\u043e):<\/p>\n<pre><code class=\"bash\">This command will guide you through creating your pyproject.toml config.   Package name [my-project2]:  Version [0.1.0]:  Description []:  My Project, but second    Author [None, n to skip]:  Timur Kasimov License []:  MIT Compatible Python versions [^3.8]:    Would you like to define your main dependencies interactively? (yes\/no) [yes] no Would you like to define your development dependencies interactively? (yes\/no) [yes] no Generated file   [tool.poetry] name = \"my-project2\" version = \"0.1.0\" description = \"My Project, but second\" authors = [\"Timur Kasimov\"] license = \"MIT\" readme = \"README.md\" packages = [{include = \"my_project2\"}]   [tool.poetry.dependencies] python = \"^3.8\"     [build-system] requires = [\"poetry-core\"] build-backend = \"poetry.core.masonry.api\"     Do you confirm generation? (yes\/no) [yes] yes<\/code><\/pre>\n<h4>\u041f\u043e\u0434\u0433\u043e\u0442\u043e\u0432\u043a\u0430 \u0432\u0438\u0440\u0442\u0443\u0430\u043b\u044c\u043d\u043e\u0433\u043e \u043e\u043a\u0440\u0443\u0436\u0435\u043d\u0438\u044f<\/h4>\n<p>\u041a\u043e\u043c\u0430\u043d\u0434\u044b&nbsp;<strong>new<\/strong>&nbsp;\u0438&nbsp;<strong>init<\/strong>&nbsp;\u043d\u0435 \u0441\u043e\u0437\u0434\u0430\u044e\u0442 \u0432\u0438\u0440\u0442\u0443\u0430\u043b\u044c\u043d\u044b\u0445 \u043e\u043a\u0440\u0443\u0436\u0435\u043d\u0438\u0439. \u041f\u0440\u0438 \u043f\u0435\u0440\u0432\u043e\u043c \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u0438 \u043a\u043e\u043c\u0430\u043d\u0434, \u0441\u0432\u044f\u0437\u0430\u043d\u043d\u044b\u0445 \u0441 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u043e\u0439 \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u0435\u0439, Poetry \u0441\u043e\u0437\u0434\u0430\u0435\u0442 \u0432\u0438\u0440\u0442\u0443\u0430\u043b\u044c\u043d\u043e\u0435 \u043e\u043a\u0440\u0443\u0436\u0435\u043d\u0438\u0435, \u0432\u044b\u0431\u0440\u0430\u0432 \u0431\u0430\u0437\u043e\u0432\u044b\u0439 \u0438\u043d\u0442\u0435\u0440\u043f\u0440\u0435\u0442\u0430\u0442\u043e\u0440 \u043f\u043e \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0435\u0439 \u043b\u043e\u0433\u0438\u043a\u0435:<\/p>\n<ol>\n<li>\n<p>Poetry \u043f\u0440\u043e\u0432\u0435\u0440\u044f\u0435\u0442, \u0430\u043a\u0442\u0438\u0432\u0438\u0440\u043e\u0432\u0430\u043d\u043e \u043b\u0438 \u0443\u0436\u0435 \u043a\u0430\u043a\u043e\u0435-\u0442\u043e \u0432\u0438\u0440\u0442\u0443\u0430\u043b\u044c\u043d\u043e\u0435 \u043e\u043a\u0440\u0443\u0436\u0435\u043d\u0438\u0435. \u0415\u0441\u043b\u0438 \u0434\u0430, \u0442\u043e \u043e\u043d\u043e \u0431\u0443\u0434\u0435\u0442 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u043e<\/p>\n<\/li>\n<li>\n<p>\u0415\u0441\u043b\u0438 \u043d\u0438\u043a\u0430\u043a\u043e\u0435 \u0432\u0438\u0440\u0442\u0443\u0430\u043b\u044c\u043d\u043e\u0435 \u043e\u043a\u0440\u0443\u0436\u0435\u043d\u0438\u0435 \u043d\u0435 \u0430\u043a\u0442\u0438\u0432\u0438\u0440\u043e\u0432\u0430\u043d\u043e, \u0442\u043e Poetry \u043f\u043e\u043f\u044b\u0442\u0430\u0435\u0442\u0441\u044f \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c Python, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0431\u044b\u043b \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d \u043f\u0440\u0438 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0435 Poetry<\/p>\n<\/li>\n<li>\n<p>\u0415\u0441\u043b\u0438 \u0432\u0435\u0440\u0441\u0438\u044f Python \u0441 \u043f\u0440\u0435\u0434\u044b\u0434\u0443\u0449\u0435\u0433\u043e \u0448\u0430\u0433\u0430 \u043d\u0435\u0441\u043e\u0432\u043c\u0435\u0441\u0442\u0438\u043c\u0430 \u0441 \u0432\u0435\u0440\u0441\u0438\u0435\u0439, \u0443\u043a\u0430\u0437\u0430\u043d\u043d\u043e\u0439 \u0432&nbsp;<strong>pyproject.toml<\/strong>, \u0442\u043e Poetry \u043f\u043e\u043f\u0440\u043e\u0441\u0438\u0442 \u044f\u0432\u043d\u043e \u0430\u043a\u0442\u0438\u0432\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u043d\u0443\u0436\u043d\u0443\u044e \u0432\u0435\u0440\u0441\u0438\u044e<\/p>\n<\/li>\n<\/ol>\n<p>\u0421\u043e\u0432\u0435\u0442\u0443\u044e \u0441\u0440\u0430\u0437\u0443 \u0443\u043a\u0430\u0437\u0430\u0442\u044c \u043a\u043e\u0440\u0440\u0435\u043a\u0442\u043d\u044b\u0439 \u0431\u0430\u0437\u043e\u0432\u044b\u0439 \u0438\u043d\u0442\u0435\u0440\u043f\u0440\u0435\u0442\u0430\u0442\u043e\u0440, \u0432\u044b\u043f\u043e\u043b\u043d\u0438\u0432 \u0432 \u043f\u0430\u043f\u043a\u0435 \u043f\u0440\u043e\u0435\u043a\u0442\u0430 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0443\u044e \u043a\u043e\u043c\u0430\u043d\u0434\u0443:<\/p>\n<pre><code class=\"bash\">poetry env use python3.8  # \u0415\u0441\u043b\u0438 python3.8 \u0435\u0441\u0442\u044c \u0432 PATH poetry env use \/path\/to\/python  # \u041c\u043e\u0436\u043d\u043e \u0443\u043a\u0430\u0437\u0430\u0442\u044c \u0438 \u043f\u043e\u043b\u043d\u044b\u0439 \u043f\u0443\u0442\u044c<\/code><\/pre>\n<p>\u0415\u0441\u043b\u0438 \u0432\u044b \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0435 pyenv, \u043c\u043e\u0436\u043d\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u044d\u043a\u0441\u043f\u0435\u0440\u0438\u043c\u0435\u043d\u0442\u0430\u043b\u044c\u043d\u0443\u044e \u0444\u0438\u0447\u0443 Poetry:<\/p>\n<pre><code class=\"bash\">poetry config virtualenvs.prefer-active-python true pyenv install 3.9.8 pyenv local 3.9.8<\/code><\/pre>\n<p>\u041f\u043e \u0443\u043c\u043e\u043b\u0447\u0430\u043d\u0438\u044e, Poetry \u0441\u043e\u0437\u0434\u0430\u0435\u0442 \u0432\u0438\u0440\u0442\u0443\u0430\u043b\u044c\u043d\u044b\u0435 \u043e\u043a\u0440\u0443\u0436\u0435\u043d\u0438\u044f \u0432 \u043f\u0430\u043f\u043a\u0435&nbsp;<strong>{cache_dir}\/virtualenvs<\/strong>. \u0415\u0441\u043b\u0438 \u0432\u044b \u0445\u043e\u0442\u0438\u0442\u0435, \u0447\u0442\u043e\u0431\u044b \u0432\u0438\u0440\u0442\u0443\u0430\u043b\u044c\u043d\u043e\u0435 \u043e\u043a\u0440\u0443\u0436\u0435\u043d\u0438\u0435 \u043d\u0430\u0445\u043e\u0434\u0438\u043b\u043e\u0441\u044c \u0432 \u043f\u0430\u043f\u043a\u0435 \u043f\u0440\u043e\u0435\u043a\u0442\u0430, \u043c\u043e\u0436\u043d\u043e \u0432\u044b\u043f\u043e\u043b\u043d\u0438\u0442\u044c \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0443\u044e \u043a\u043e\u043c\u0430\u043d\u0434\u0443:<\/p>\n<pre><code class=\"bash\">poetry config virtualenvs.in-project true<\/code><\/pre>\n<p>\u0422\u0435\u043f\u0435\u0440\u044c \u0441\u043e\u0437\u0434\u0430\u0432\u0430\u0435\u043c\u043e\u0435 \u0432\u0438\u0440\u0442\u0443\u0430\u043b\u044c\u043d\u043e\u0435 \u043e\u043a\u0440\u0443\u0436\u0435\u043d\u0438\u0435 \u0431\u0443\u0434\u0435\u0442 \u043d\u0430\u0445\u043e\u0434\u0438\u0442\u044c\u0441\u044f \u0432 \u043f\u0430\u043f\u043a\u0435&nbsp;<strong>.venv<\/strong>&nbsp;\u0432 \u043a\u043e\u0440\u043d\u0435 \u043f\u0440\u043e\u0435\u043a\u0442\u0430.<\/p>\n<h4>\u041a\u0430\u043a \u0441\u043e\u0437\u0434\u0430\u0442\u044c \u043f\u0440\u043e\u0435\u043a\u0442 \u0447\u0435\u0440\u0435\u0437 PyCharm<\/h4>\n<p>PyCharm \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u0438\u0432\u0430\u0435\u0442 \u0438\u043d\u0442\u0435\u0433\u0440\u0430\u0446\u0438\u044e \u0441 Poetry. \u041c\u043e\u0436\u043d\u043e \u0432\u044b\u0431\u0440\u0430\u0442\u044c Poetry \u043a\u0430\u043a \u043f\u0440\u0438 \u0441\u043e\u0437\u0434\u0430\u043d\u0438\u0438 \u043d\u043e\u0432\u043e\u0433\u043e \u043f\u0440\u043e\u0435\u043a\u0442\u0430:<\/p>\n<figure class=\"full-width\"><\/figure>\n<p>\u0422\u0430\u043a \u0438 \u0432 \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u044e\u0449\u0435\u043c \u043f\u0440\u043e\u0435\u043a\u0442\u0435. \u0414\u043b\u044f \u044d\u0442\u043e\u0433\u043e \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u0432 \u043f\u0440\u0430\u0432\u043e\u043c \u043d\u0438\u0436\u043d\u0435\u043c \u0443\u0433\u043b\u0443 \u043d\u0430\u0436\u0430\u0442\u044c &#171;No Interpreter&#187; (\u0435\u0441\u043b\u0438 \u0443 \u0432\u0430\u0441 \u0434\u043e \u044d\u0442\u043e\u0433\u043e \u043d\u0435 \u0431\u044b\u043b \u043d\u0430\u0441\u0442\u0440\u043e\u0435\u043d \u0438\u043d\u0442\u0435\u0440\u043f\u0440\u0435\u0442\u0430\u0442\u043e\u0440 \u0432 \u043f\u0440\u043e\u0435\u043a\u0442\u0435) \u0438\u043b\u0438 \u043d\u0430 \u0438\u043c\u044f \u0438\u043d\u0442\u0435\u0440\u043f\u0440\u0435\u0442\u0430\u0442\u043e\u0440\u0430, \u0434\u0430\u043b\u0435\u0435 &#171;Add New Interpreter&#187; \u2192 &#171;Add Local Interpreter&#187;, \u0438 \u0432 \u043e\u0442\u043a\u0440\u044b\u0432\u0448\u0435\u043c\u0441\u044f \u043e\u043a\u043d\u0435 \u0432\u044b\u0431\u0440\u0430\u0442\u044c &#171;Poetry environment&#187;:<\/p>\n<figure class=\"full-width\"><\/figure>\n<h3>pyproject.toml \u0438 poetry.lock<\/h3>\n<p><strong>pyproject.toml <\/strong>&#8212; \u044d\u0442\u043e \u0444\u0430\u0439\u043b, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u0442 \u0432 \u0441\u0435\u0431\u0435 \u0432\u0441\u044e \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u044e \u043e \u043f\u0440\u043e\u0435\u043a\u0442\u0435: \u043c\u0435\u0442\u0430\u0434\u0430\u043d\u043d\u044b\u0435 (\u0438\u043c\u044f, \u0432\u0435\u0440\u0441\u0438\u044f \u0438 \u0442.\u043f.) \u0438 \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u0438, \u0430 \u0442\u0430\u043a\u0436\u0435 \u0432 \u043d\u0435\u043c \u043c\u043e\u0433\u0443\u0442 \u043f\u0440\u0438\u0441\u0443\u0442\u0441\u0442\u0432\u043e\u0432\u0430\u0442\u044c \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0438 \u0434\u0440\u0443\u0433\u0438\u0445 \u0438\u043d\u0441\u0442\u0440\u0443\u043c\u0435\u043d\u0442\u043e\u0432.<\/p>\n<p>\u0424\u0430\u0439\u043b <strong>poetry.lock <\/strong>\u0436\u0435 \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u0442 \u0432 \u0441\u0435\u0431\u0435 \u0432\u0441\u0435 \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u0438 \u043f\u0440\u043e\u0435\u043a\u0442\u0430 \u0441 \u0437\u0430\u0444\u0438\u043a\u0441\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u043c\u0438 \u0432\u0435\u0440\u0441\u0438\u044f\u043c\u0438 \u0438 \u0444\u043e\u0440\u043c\u0438\u0440\u0443\u0435\u0442\u0441\u044f \u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u0438 (\u043f\u043e\u0436\u0430\u043b\u0443\u0439\u0441\u0442\u0430, \u043d\u0435 \u0440\u0435\u0434\u0430\u043a\u0442\u0438\u0440\u0443\u0439\u0442\u0435 \u0435\u0433\u043e \u0432\u0440\u0443\u0447\u043d\u0443\u044e).<\/p>\n<p><strong>[tool.poetry]<\/strong> \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u0442 \u0432 \u0441\u0435\u0431\u0435 \u043c\u0435\u0442\u0430\u0434\u0430\u043d\u043d\u044b\u0435:<\/p>\n<ul>\n<li>\n<p>name &#8212; \u0438\u043c\u044f \u043f\u0440\u043e\u0435\u043a\u0442\u0430. \u0414\u043e\u043b\u0436\u043d\u043e \u0431\u044b\u0442\u044c <a href=\"https:\/\/peps.python.org\/pep-0508\/#names\" rel=\"noopener noreferrer nofollow\">\u0432\u0430\u043b\u0438\u0434\u043d\u044b\u043c \u043f\u043e PEP 508<\/a>;<\/p>\n<\/li>\n<li>\n<p>version &#8212; \u0432\u0435\u0440\u0441\u0438\u044f \u043f\u0440\u043e\u0435\u043a\u0442\u0430. \u0414\u043e\u043b\u0436\u043d\u0430 \u0431\u044b\u0442\u044c <a href=\"https:\/\/peps.python.org\/pep-0440\/\" rel=\"noopener noreferrer nofollow\">\u0432\u0430\u043b\u0438\u0434\u043d\u043e\u0439 \u043f\u043e PEP 440<\/a>;<\/p>\n<\/li>\n<li>\n<p>description &#8212; \u043a\u043e\u0440\u043e\u0442\u043a\u043e\u0435 \u043e\u043f\u0438\u0441\u0430\u043d\u0438\u0435 \u043f\u0440\u043e\u0435\u043a\u0442\u0430;<\/p>\n<\/li>\n<li>\n<p>license &#8212; \u043b\u0438\u0446\u0435\u043d\u0437\u0438\u044f;<\/p>\n<\/li>\n<li>\n<p>authors &#8212; \u0430\u0432\u0442\u043e\u0440\u044b \u043f\u0440\u043e\u0435\u043a\u0442\u0430 \u0432 \u0444\u043e\u0440\u043c\u0430\u0442\u0435 &#171;name &lt;email&gt;&#187;. \u0414\u043e\u043b\u0436\u0435\u043d \u043f\u0440\u0438\u0441\u0443\u0442\u0441\u0442\u0432\u043e\u0432\u0430\u0442\u044c \u043a\u0430\u043a \u043c\u0438\u043d\u0438\u043c\u0443\u043c \u043e\u0434\u0438\u043d \u0430\u0432\u0442\u043e\u0440.<\/p>\n<\/li>\n<\/ul>\n<p>\u041e\u0441\u0442\u0430\u043b\u044c\u043d\u044b\u0435 \u0441\u043f\u0435\u0446\u0438\u0444\u0438\u043a\u0430\u0442\u043e\u0440\u044b \u043c\u043e\u0436\u043d\u043e \u043d\u0430\u0439\u0442\u0438 \u0432 \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u0430\u0446\u0438\u0438, \u043e\u043d\u0438 \u043d\u0435 \u044f\u0432\u043b\u044f\u044e\u0442\u0441\u044f \u043e\u0431\u044f\u0437\u0430\u0442\u0435\u043b\u044c\u043d\u044b\u043c\u0438.<\/p>\n<p><strong>[tool.poetry.dependencies]<\/strong> \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u0442 \u0432 \u0441\u0435\u0431\u0435 \u0432\u0435\u0440\u0441\u0438\u044e Python \u0438 \u043e\u0441\u043d\u043e\u0432\u043d\u044b\u0435 \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u0438 \u043f\u0440\u043e\u0435\u043a\u0442\u0430 (\u0442\u0430\u043a \u043d\u0430\u0437\u044b\u0432\u0430\u0435\u043c\u0443\u044e main-\u0433\u0440\u0443\u043f\u043f\u0443).<\/p>\n<p>\u0412 <a href=\"https:\/\/peps.python.org\/pep-0517\/\" rel=\"noopener noreferrer nofollow\">PEP-517<\/a> \u0431\u044b\u043b \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u0435\u043d \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u043d\u044b\u0439 \u0441\u043f\u043e\u0441\u043e\u0431 \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u044f\u0442\u044c \u0430\u043b\u044c\u0442\u0435\u0440\u043d\u0430\u0442\u0438\u0432\u043d\u044b\u0435 \u0441\u0438\u0441\u0442\u0435\u043c\u044b \u0441\u0431\u043e\u0440\u043a\u0438 \u0434\u043b\u044f Python-\u043f\u0440\u043e\u0435\u043a\u0442\u043e\u0432. Poetry \u0441\u043e\u0432\u043c\u0435\u0441\u0442\u0438\u043c \u0441 PEP-517 \u0438 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442 poetry-core \u0434\u043b\u044f \u0441\u0431\u043e\u0440\u043a\u0438, \u0447\u0442\u043e \u0438 \u043e\u0431\u043e\u0437\u043d\u0430\u0447\u0435\u043d\u043e \u0432 \u0441\u0435\u043a\u0446\u0438\u0438 <strong>build-system<\/strong>:<\/p>\n<pre><code class=\"bash\">[build-system] requires = [\"poetry-core&gt;=1.0.0\"] build-backend = \"poetry.core.masonry.api\"<\/code><\/pre>\n<p>\u041c\u043d\u043e\u0433\u0438\u0435 \u043f\u0438\u0442\u043e\u043d\u043e\u0432\u0441\u043a\u0438\u0435 \u0438\u043d\u0441\u0442\u0440\u0443\u043c\u0435\u043d\u0442\u044b \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u0438\u0432\u0430\u044e\u0442 \u043a\u043e\u043d\u0444\u0438\u0433\u0443\u0440\u0430\u0446\u0438\u044e \u0447\u0435\u0440\u0435\u0437 <strong>pyproject.toml<\/strong>. \u041d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u0432 \u043c\u043e\u0438\u0445 \u043f\u0440\u043e\u0435\u043a\u0442\u0430\u0445 \u0432 \u043d\u0435\u043c \u0443\u044e\u0442\u043d\u043e \u0440\u0430\u0441\u043f\u043e\u043b\u043e\u0436\u0438\u043b\u0438\u0441\u044c \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0438 isort \u0438 mypy:<\/p>\n<pre><code class=\"bash\">[tool.isort] line_length = 120 ... force_grid_wrap = 2  [tool.mypy] python_version = 3.9 ... follow_imports = \"skip\"<\/code><\/pre>\n<h3>\u0423\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0430 \u0438 \u0443\u0434\u0430\u043b\u0435\u043d\u0438\u0435 \u043f\u0430\u043a\u0435\u0442\u043e\u0432<\/h3>\n<h4>\u0421\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u043d\u0430\u044f \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0430 + \u0432\u0435\u0440\u0441\u0438\u043e\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435<\/h4>\n<p>\u041a\u043e\u043c\u0430\u043d\u0434\u0430 add \u0434\u043e\u0431\u0430\u0432\u043b\u044f\u0435\u0442 \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u044c \u0432 <strong>pyproject.toml<\/strong>, \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0435\u0442 \u0440\u0430\u0437\u0440\u0435\u0448\u0435\u043d\u0438\u0435 \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u0435\u0439 \u0438 \u0443\u0441\u0442\u0430\u043d\u0430\u0432\u043b\u0438\u0432\u0430\u0435\u0442 \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u044c:<\/p>\n<pre><code class=\"bash\">poetry add fastapi<\/code><\/pre>\n<p>\u0412 \u0441\u0435\u043a\u0446\u0438\u0438 <strong>[tool.poetry.dependencies]<\/strong> \u043f\u043e\u044f\u0432\u0438\u043b\u0430\u0441\u044c \u043d\u0430\u0448\u0430 \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u044c:<\/p>\n<pre><code class=\"bash\">[tool.poetry.dependencies] python = \"^3.8\" fastapi = \"^0.95.2\"<\/code><\/pre>\n<p>\u0420\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0438\u043c, \u043a\u0430\u043a \u0443\u043a\u0430\u0437\u044b\u0432\u0430\u0442\u044c \u0432\u0435\u0440\u0441\u0438\u0438 \u043f\u0440\u0438 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0435. \u041f\u0435\u0440\u0432\u044b\u0439 \u0432\u0430\u0440\u0438\u0430\u043d\u0442 &#8212; \u044d\u0442\u043e Caret Requirements:<\/p>\n<div>\n<div class=\"table\">\n<table>\n<tbody>\n<tr>\n<th>\n<p align=\"center\">\u0422\u0440\u0435\u0431\u043e\u0432\u0430\u043d\u0438\u0435<\/p>\n<\/th>\n<th>\n<p align=\"center\">\u0414\u043e\u043f\u0443\u0441\u0442\u0438\u043c\u044b\u0435 \u0432\u0435\u0440\u0441\u0438\u0438<\/p>\n<\/th>\n<\/tr>\n<tr>\n<td>\n<p align=\"center\">^1.2.3<\/p>\n<\/td>\n<td>\n<p align=\"center\">&gt;=1.2.3, &lt;2.0.0<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td>\n<p align=\"center\">^1.2<\/p>\n<\/td>\n<td>\n<p align=\"center\">&gt;=1.2.0, &lt;2.0.0<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td>\n<p align=\"center\">^1<\/p>\n<\/td>\n<td>\n<p align=\"center\">&gt;=1.0.0, &lt;2.0.0<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td>\n<p align=\"center\">^0.2.3<\/p>\n<\/td>\n<td>\n<p align=\"center\">&gt;=0.2.3, &lt;0.3.0<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td>\n<p align=\"center\">^0.0.3<\/p>\n<\/td>\n<td>\n<p align=\"center\">&gt;=0.0.3, &lt;0.0.4<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td>\n<p align=\"center\">^0.0<\/p>\n<\/td>\n<td>\n<p align=\"center\">&gt;=0.0.0, &lt;0.1.0<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td>\n<p align=\"center\">^0<\/p>\n<\/td>\n<td>\n<p align=\"center\">&gt;=0.0.0, &lt;1.0.0<\/p>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<p>\u0412\u0442\u043e\u0440\u043e\u0439 \u0432\u0430\u0440\u0438\u0430\u043d\u0442 &#8212; \u044d\u0442\u043e Tilde requirements, \u0447\u0442\u043e \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u0435\u0442 \u0443\u043a\u0430\u0437\u044b\u0432\u0430\u0442\u044c \u043c\u0438\u043d\u0438\u043c\u0430\u043b\u044c\u043d\u0443\u044e \u0434\u043e\u043f\u0443\u0441\u0442\u0438\u043c\u0443\u044e \u0432\u0435\u0440\u0441\u0438\u044e \u0441 \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u043e\u0439 \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e\u0441\u0442\u044c\u044e \u043e\u0431\u043d\u043e\u0432\u043b\u0435\u043d\u0438\u044f:<\/p>\n<div>\n<div class=\"table\">\n<table>\n<tbody>\n<tr>\n<th>\n<p align=\"center\">\u0422\u0440\u0435\u0431\u043e\u0432\u0430\u043d\u0438\u0435<\/p>\n<\/th>\n<th>\n<p align=\"center\">\u0414\u043e\u043f\u0443\u0441\u0442\u0438\u043c\u044b\u0435 \u0432\u0435\u0440\u0441\u0438\u0438<\/p>\n<\/th>\n<\/tr>\n<tr>\n<td>\n<p align=\"center\">~1.2.3<\/p>\n<\/td>\n<td>\n<p align=\"center\">&gt;=1.2.3,&lt;1.3.0<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td>\n<p align=\"center\">~1.2<\/p>\n<\/td>\n<td>\n<p align=\"center\">&gt;=1.2.0,&lt;1.3.0<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td>\n<p align=\"center\">~1<\/p>\n<\/td>\n<td>\n<p align=\"center\">&gt;=1.0.0,&lt;2.0.0<\/p>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<p>Wildcard requirements \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u044e\u0442 \u043e\u0431\u043d\u043e\u0432\u043b\u0435\u043d\u0438\u0435 \u0434\u043e \u043f\u043e\u0441\u043b\u0435\u0434\u043d\u0435\u0439 \u0432\u0435\u0440\u0441\u0438\u0438 \u0432 \u043f\u043e\u0437\u0438\u0446\u0438\u0438, \u0433\u0434\u0435 \u0440\u0430\u0441\u043f\u043e\u043b\u043e\u0436\u0435\u043d \u0441\u0438\u043c\u0432\u043e\u043b &#171;*&#187;:<\/p>\n<div>\n<div class=\"table\">\n<table>\n<tbody>\n<tr>\n<th>\n<p align=\"center\">\u0422\u0440\u0435\u0431\u043e\u0432\u0430\u043d\u0438\u0435<\/p>\n<\/th>\n<th>\n<p align=\"center\">\u0414\u043e\u043f\u0443\u0441\u0442\u0438\u043c\u044b\u0435 \u0432\u0435\u0440\u0441\u0438\u0438<\/p>\n<\/th>\n<\/tr>\n<tr>\n<td>\n<p align=\"center\">*<\/p>\n<\/td>\n<td>\n<p align=\"center\">&gt;=0.0.0<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td>\n<p align=\"center\">1.*<\/p>\n<\/td>\n<td>\n<p align=\"center\">&gt;=1.0.0,&lt;2.0.0<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td>\n<p align=\"center\">1.2.*<\/p>\n<\/td>\n<td>\n<p align=\"center\">&gt;=1.2.0,&lt;1.3.0<\/p>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<p>Inequality requirements \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u044e\u0442 \u0432\u0440\u0443\u0447\u043d\u0443\u044e \u0443\u043a\u0430\u0437\u0430\u0442\u044c \u0434\u0438\u0430\u043f\u0430\u0437\u043e\u043d \u0434\u043e\u043f\u0443\u0441\u0442\u0438\u043c\u044b\u0445 \u0432\u0435\u0440\u0441\u0438\u0439, \u0438\u043b\u0438 \u0436\u0435 \u0442\u043e\u0447\u043d\u0443\u044e \u0432\u0435\u0440\u0441\u0438\u044e:<\/p>\n<pre><code class=\"bash\">&gt;=1.2.0 &gt;1 &lt;2 !=1.2.3 ==1.5.2  # \u041c\u043e\u0436\u043d\u043e \u043a\u043e\u043c\u0431\u0438\u043d\u0438\u0440\u043e\u0432\u0430\u0442\u044c &gt;=1.2,&lt;1.5<\/code><\/pre>\n<p>\u0421\u0442\u043e\u0438\u0442 \u043e\u0431\u0440\u0430\u0442\u0438\u0442\u044c \u0432\u043d\u0438\u043c\u0430\u043d\u0438\u0435 \u043d\u0430 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u0439 \u043c\u043e\u043c\u0435\u043d\u0442: \u0435\u0441\u043b\u0438 \u0432\u044b \u0443\u043a\u0430\u0437\u044b\u0432\u0430\u0435\u0442\u0435 \u0442\u043e\u0447\u043d\u0443\u044e \u0432\u0435\u0440\u0441\u0438\u044e, \u0438 \u0434\u0440\u0443\u0433\u0438\u043c \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u044f\u043c \u0442\u0440\u0435\u0431\u0443\u0435\u0442\u0441\u044f \u0434\u0440\u0443\u0433\u0430\u044f \u0432\u0435\u0440\u0441\u0438\u044f, \u0442\u043e \u0440\u0435\u0437\u043e\u043b\u0432\u0435\u0440 \u043d\u0435 \u0441\u043c\u043e\u0436\u0435\u0442 \u0440\u0430\u0437\u0440\u0435\u0448\u0438\u0442\u044c \u0432\u0441\u0435 \u043a\u043e\u043d\u0444\u043b\u0438\u043a\u0442\u044b \u0438 \u043f\u0440\u043e\u0446\u0435\u0434\u0443\u0440\u0430 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0438 (\u0438\u043b\u0438 \u043e\u0431\u043d\u043e\u0432\u043b\u0435\u043d\u0438\u044f) \u043d\u0435 \u0431\u0443\u0434\u0435\u0442 \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0430.<\/p>\n<h4>Extras \u0438 groups<\/h4>\n<p>\u041f\u0440\u0435\u0436\u0434\u0435 \u0447\u0435\u043c \u0438\u0434\u0442\u0438 \u0434\u0430\u043b\u044c\u0448\u0435, \u0445\u043e\u0447\u0435\u0442\u0441\u044f \u0432\u0432\u0435\u0441\u0442\u0438 2 \u043f\u043e\u043d\u044f\u0442\u0438\u044f &#8212; extras \u0438 groups. \u041e\u043d\u0438 \u0434\u043e\u0432\u043e\u043b\u044c\u043d\u043e \u0441\u0445\u043e\u0436\u0438, \u043d\u043e \u043d\u0430 \u0434\u0435\u043b\u0435 \u0441\u043b\u0443\u0436\u0430\u0442 \u0434\u043b\u044f \u0440\u0430\u0437\u043d\u044b\u0445 \u0446\u0435\u043b\u0435\u0439.<\/p>\n<p>Dependency groups (\u0434\u0430\u043b\u0435\u0435 \u043f\u0440\u043e\u0441\u0442\u043e \u0433\u0440\u0443\u043f\u043f\u044b) \u0441\u043e\u0434\u0435\u0440\u0436\u0430\u0442 \u0432 \u0441\u0435\u0431\u0435 \u043e\u043f\u0446\u0438\u043e\u043d\u0430\u043b\u044c\u043d\u044b\u0435 \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u0438, \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u043c\u044b\u0435 <strong>\u0442\u043e\u043b\u044c\u043a\u043e \u043f\u0440\u0438 \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u043a\u0435.&nbsp;<\/strong>\u0423\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u044c \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u0438 \u0438\u0437 \u0433\u0440\u0443\u043f\u043f \u043c\u043e\u0436\u043d\u043e \u0442\u043e\u043b\u044c\u043a\u043e \u0447\u0435\u0440\u0435\u0437 Poetry. \u041a\u0430\u0436\u0434\u044b\u0439 \u043f\u0440\u043e\u0435\u043a\u0442 \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u0442 \u0432 \u0441\u0435\u0431\u0435 \u043e\u0434\u043d\u0443 \u043d\u0435\u044f\u0432\u043d\u0443\u044e \u043e\u0431\u044f\u0437\u0430\u0442\u0435\u043b\u044c\u043d\u0443\u044e \u0433\u0440\u0443\u043f\u043f\u0443 &#8212; main, \u043a\u043e\u0442\u043e\u0440\u0430\u044f \u043d\u0430\u0445\u043e\u0434\u0438\u0442\u0441\u044f \u0432 \u0441\u0435\u043a\u0446\u0438\u0438 <strong>[tool.poetry.dependencies]<\/strong>.<\/p>\n<p>\u0423\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0430 \u0432 \u0433\u0440\u0443\u043f\u043f\u0443 \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0435\u0442\u0441\u044f \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c:<\/p>\n<pre><code class=\"bash\">poetry add --group test pytest<\/code><\/pre>\n<p>\u0413\u0440\u0443\u043f\u043f\u0430 \u0432\u043c\u0435\u0441\u0442\u0435 \u0441 \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u044c\u044e \u043f\u043e\u044f\u0432\u0438\u043b\u0430\u0441\u044c \u0432 pyproject.toml:<\/p>\n<pre><code class=\"bash\">[tool.poetry.group.test.dependencies] pytest = \"^7.3.1\"<\/code><\/pre>\n<p>Extras \u0436\u0435 \u043f\u0440\u0435\u0434\u043d\u0430\u0437\u043d\u0430\u0447\u0435\u043d\u044b \u0434\u043b\u044f \u0432\u0432\u0435\u0434\u0435\u043d\u0438\u044f \u0434\u043e\u043f\u043e\u043b\u043d\u0438\u0442\u0435\u043b\u044c\u043d\u044b\u0445 \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u0435\u0439, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0432\u043a\u043b\u044e\u0447\u0430\u044e\u0442 \u043a\u0430\u043a\u0443\u044e-\u043b\u0438\u0431\u043e \u0444\u0443\u043d\u043a\u0446\u0438\u043e\u043d\u0430\u043b\u044c\u043d\u043e\u0441\u0442\u044c \u0432 \u0432\u0430\u0448\u0435\u043c \u043f\u0440\u043e\u0435\u043a\u0442\u0435. \u0423\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u044c \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u044c \u043a\u0430\u043a extra \u043c\u043e\u0436\u043d\u043e \u0432\u043e\u0442 \u0442\u0430\u043a:<\/p>\n<pre><code class=\"bash\">poetry add --extras postgres psycopg2-binary poetry add --extras mysql --extras database mysql-connector-python  # \u041c\u043e\u0436\u043d\u043e \u043f\u0435\u0440\u0435\u0447\u0438\u0441\u043b\u044f\u0442\u044c \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e extras<\/code><\/pre>\n<p>\u0417\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u0438 \u043f\u043e\u044f\u0432\u0438\u043b\u0438\u0441\u044c \u0432 <strong>[tool.poetry.dependencies]&nbsp;<\/strong>\u0441 \u043f\u043e\u043c\u0435\u0442\u043a\u043e\u0439 extras:<\/p>\n<pre><code class=\"bash\">[tool.poetry.dependencies] python = \"^3.8\" psycopg2-binary = {version = \"^2.9.6\", extras = [\"postgres\"]} mysql-connector-python = {version = \"^8.0.33\", extras = [\"mysql\", \"database\"]}<\/code><\/pre>\n<p>\u041f\u043e\u0441\u043b\u0435 \u0441\u0431\u043e\u0440\u043a\u0438 \u0438 \u043f\u0443\u0431\u043b\u0438\u043a\u0430\u0446\u0438\u0438 \u043c\u043e\u0436\u043d\u043e \u0431\u0443\u0434\u0435\u0442 \u0443\u0441\u0442\u0430\u043d\u0430\u0432\u043b\u0438\u0432\u0430\u0442\u044c \u0432\u0430\u0448 \u043f\u0430\u043a\u0435\u0442 \u043a\u0430\u043a \u043e\u0431\u044b\u0447\u043d\u043e:<\/p>\n<pre><code class=\"bash\">poetry add \"my-project[postgres,database]\" poetry add \"my-project[mysql]<\/code><\/pre>\n<h4>\u0423\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0430 \u0441 Git \u0438 \u043f\u0440\u0438\u0432\u0430\u0442\u043d\u044b\u0445 package registries<\/h4>\n<p>\u0423\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0430 \u0438\u0437 \u043f\u0443\u0431\u043b\u0438\u0447\u043d\u044b\u0445 \u0440\u0435\u043f\u043e\u0437\u0438\u0442\u043e\u0440\u0438\u0435\u0432 \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0435\u0442\u0441\u044f \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c:<\/p>\n<pre><code class=\"bash\">poetry add \"git+https:\/\/github.com\/psf\/requests\"  # \u0431\u0443\u0434\u0435\u0442 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d \u043f\u043e\u0441\u043b\u0435\u0434\u043d\u0438\u0439 \u043a\u043e\u043c\u043c\u0438\u0442 \u0441 \u043e\u0441\u043d\u043e\u0432\u043d\u043e\u0439 \u0432\u0435\u0442\u043a\u0438 poetry add \"git+https:\/\/github.com\/psf\/requests#update-3.0\"  # \u0431\u0443\u0434\u0435\u0442 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d \u043f\u043e\u0441\u043b\u0435\u0434\u043d\u0438\u0439 \u043a\u043e\u043c\u043c\u0438\u0442 \u0441 \u0432\u0435\u0442\u043a\u0438 update 3.0  # \u0412\u0441\u0435 \u0442\u043e \u0436\u0435 \u0441\u0430\u043c\u043e\u0435, \u043d\u043e \u0447\u0435\u0440\u0435\u0437 SSH poetry add \"git+ssh:\/\/git@github.com:requests\/requests.git\" poetry add \"git+ssh:\/\/git@github.com:requests\/requests.git#update-3.0\"<\/code><\/pre>\n<p>\u0414\u043b\u044f \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0438 \u0438\u0437 \u043f\u0440\u0438\u0432\u0430\u0442\u043d\u044b\u0445 git-\u0440\u0435\u043f\u043e\u0437\u0438\u0442\u043e\u0440\u0438\u0435\u0432 \u043c\u043e\u0436\u043d\u043e \u0432\u043e\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c\u0441\u044f SSH, \u043d\u043e \u0432 \u0442\u0430\u043a\u043e\u043c \u0441\u043b\u0443\u0447\u0430\u0435 \u0431\u0443\u0434\u0435\u0442 \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0442\u044c\u0441\u044f \u0441\u0431\u043e\u0440\u043a\u0430.<\/p>\n<p>\u0415\u0441\u043b\u0438 \u0436\u0435 \u0443 \u0432\u0430\u0441 \u0435\u0441\u0442\u044c \u043f\u0440\u0438\u0432\u0430\u0442\u043d\u044b\u0439 package registry, \u043f\u043e\u0441\u043b\u0435\u0434\u043e\u0432\u0430\u0442\u0435\u043b\u044c\u043d\u043e\u0441\u0442\u044c \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u044f \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0430\u044f (\u0440\u0430\u0441\u0441\u043c\u0430\u0442\u0440\u0438\u0432\u0430\u0442\u044c \u0431\u0443\u0434\u0435\u043c \u043d\u0430 \u043f\u0440\u0438\u043c\u0435\u0440\u0435 GitLab). \u0414\u043e\u0431\u0430\u0432\u043b\u044f\u0435\u043c \u0438\u0441\u0442\u043e\u0447\u043d\u0438\u043a:<\/p>\n<pre><code class=\"bash\">poetry source add my-repo \"https:\/\/my.gitlab.com\/projects\/1\/packages\/pypi\/simple\"<\/code><\/pre>\n<p>\u0414\u043e\u0431\u0430\u0432\u043b\u0435\u043d\u043d\u044b\u0439 \u0438\u0441\u0442\u043e\u0447\u043d\u0438\u043a \u043f\u043e\u044f\u0432\u0438\u043b\u0441\u044f \u0432 \u0444\u0430\u0439\u043b\u0435 <strong>pyproject.toml<\/strong>:<\/p>\n<pre><code class=\"bash\">[[tool.poetry.source]] name = \"my-repo\" url = \"https:\/\/my.gitlab.com\/projects\/1\/packages\/pypi\/simple\" default = false secondary = false<\/code><\/pre>\n<p>\u041d\u0430\u0441\u0442\u0440\u0430\u0438\u0432\u0430\u0435\u043c \u0430\u0443\u0442\u0435\u043d\u0442\u0438\u0444\u0438\u043a\u0430\u0446\u0438\u044e (\u0434\u043b\u044f GitLab Package Registry \u0440\u0435\u043a\u043e\u043c\u0435\u043d\u0434\u0443\u044e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c <a href=\"https:\/\/docs.gitlab.com\/ee\/user\/profile\/personal_access_tokens.html\" rel=\"noopener noreferrer nofollow\">Personal Access Token<\/a>):<\/p>\n<pre><code class=\"bash\">poetry<\/code><\/pre>\n<\/div>\n<\/div>\n<\/div>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[],"tags":[],"class_list":["post-348463","post","type-post","status-publish","format-standard","hentry"],"_links":{"self":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/348463","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=348463"}],"version-history":[{"count":0,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/348463\/revisions"}],"wp:attachment":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=348463"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=348463"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=348463"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}