{"id":14832,"date":"2020-09-30T21:58:27","date_gmt":"2020-09-30T21:58:27","guid":{"rendered":"https:\/\/holypython.com\/?p=14832"},"modified":"2021-03-28T13:26:50","modified_gmt":"2021-03-28T13:26:50","slug":"python-packaging-quick-tutorial-checklist","status":"publish","type":"post","link":"https:\/\/holypython.com\/python-packaging-quick-tutorial-checklist\/","title":{"rendered":"Python Packaging: Quick Tutorial &#038; Checklist"},"content":{"rendered":"\t\t<div data-elementor-type=\"wp-post\" data-elementor-id=\"14832\" class=\"elementor elementor-14832\">\n\t\t\t\t\t\t<section class=\"elementor-section elementor-top-section elementor-element elementor-element-3c5422d elementor-section-boxed elementor-section-height-default elementor-section-height-default\" data-id=\"3c5422d\" data-element_type=\"section\">\n\t\t\t\t\t\t<div class=\"elementor-container elementor-column-gap-default\">\n\t\t\t\t\t<div class=\"elementor-column elementor-col-100 elementor-top-column elementor-element elementor-element-ee936db\" data-id=\"ee936db\" data-element_type=\"column\">\n\t\t\t<div class=\"elementor-widget-wrap elementor-element-populated\">\n\t\t\t\t\t\t<section class=\"elementor-section elementor-inner-section elementor-element elementor-element-0ff9062 elementor-section-boxed elementor-section-height-default elementor-section-height-default\" data-id=\"0ff9062\" data-element_type=\"section\">\n\t\t\t\t\t\t<div class=\"elementor-container elementor-column-gap-default\">\n\t\t\t\t\t<div class=\"elementor-column elementor-col-50 elementor-inner-column elementor-element elementor-element-5fc4034\" data-id=\"5fc4034\" data-element_type=\"column\">\n\t\t\t<div class=\"elementor-widget-wrap elementor-element-populated\">\n\t\t\t\t\t\t<div class=\"elementor-element elementor-element-7a5cab0 elementor-widget elementor-widget-image\" data-id=\"7a5cab0\" data-element_type=\"widget\" data-widget_type=\"image.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t<img fetchpriority=\"high\" decoding=\"async\" width=\"477\" height=\"578\" src=\"https:\/\/holypython.com\/wp-content\/uploads\/2020\/09\/3cx_txgg4h9oI-Custom.jpg\" class=\"attachment-full size-full wp-image-15259\" alt=\"\" srcset=\"https:\/\/holypython.com\/wp-content\/uploads\/2020\/09\/3cx_txgg4h9oI-Custom.jpg 477w, https:\/\/holypython.com\/wp-content\/uploads\/2020\/09\/3cx_txgg4h9oI-Custom-248x300.jpg 248w\" sizes=\"(max-width: 477px) 100vw, 477px\" \/>\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-8ef483d elementor-widget elementor-widget-text-editor\" data-id=\"8ef483d\" data-element_type=\"widget\" data-widget_type=\"text-editor.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t\t\t<p>Packaging is a very exciting process for the coder. Packaging allows you to share your work with the world and step into a structured, real developer position rather than dealing with bits and pieces of code here and there. And I don&#8217;t mean position in a corporate sense here, after all you know your position better than everyone else.<\/p><p><span style=\"color: var( --e-global-color-text ); font-family: var( --e-global-typography-text-font-family );\">So, this tutorial is about packaging and it can help you navigate the pretty standardized steps of Python packaging and all the intricacies that come with it.<\/span><\/p>\t\t\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/div>\n\t\t\t\t<div class=\"elementor-column elementor-col-50 elementor-inner-column elementor-element elementor-element-d2d0a29\" data-id=\"d2d0a29\" data-element_type=\"column\">\n\t\t\t<div class=\"elementor-widget-wrap elementor-element-populated\">\n\t\t\t\t\t\t<div class=\"elementor-element elementor-element-1077019 elementor-position-left elementor-view-default elementor-mobile-position-top elementor-vertical-align-top elementor-widget elementor-widget-icon-box\" data-id=\"1077019\" data-element_type=\"widget\" data-widget_type=\"icon-box.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t<div class=\"elementor-icon-box-wrapper\">\n\n\t\t\t\t\t\t<div class=\"elementor-icon-box-icon\">\n\t\t\t\t<span  class=\"elementor-icon\">\n\t\t\t\t<i aria-hidden=\"true\" class=\"far fa-clock\"><\/i>\t\t\t\t<\/span>\n\t\t\t<\/div>\n\t\t\t\n\t\t\t\t\t\t<div class=\"elementor-icon-box-content\">\n\n\t\t\t\t\t\t\t\t\t<h4 class=\"elementor-icon-box-title\">\n\t\t\t\t\t\t<span  >\n\t\t\t\t\t\t\tEstimated Time\t\t\t\t\t\t<\/span>\n\t\t\t\t\t<\/h4>\n\t\t\t\t\n\t\t\t\t\t\t\t\t\t<p class=\"elementor-icon-box-description\">\n\t\t\t\t\t\t10 mins\t\t\t\t\t<\/p>\n\t\t\t\t\n\t\t\t<\/div>\n\t\t\t\n\t\t<\/div>\n\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-b1be7ee elementor-widget elementor-widget-raven-divider\" data-id=\"b1be7ee\" data-element_type=\"widget\" data-widget_type=\"raven-divider.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t<div class=\"raven-widget-wrapper\">\r\n\t\t\t<div class=\"raven-divider\">\r\n\t\t\t\t<span class=\"raven-divider-line raven-divider-solid\"><\/span>\r\n\t\t\t<\/div>\r\n\t\t<\/div>\r\n\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-50a7f3e elementor-position-left elementor-view-default elementor-mobile-position-top elementor-vertical-align-top elementor-widget elementor-widget-icon-box\" data-id=\"50a7f3e\" data-element_type=\"widget\" data-widget_type=\"icon-box.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t<div class=\"elementor-icon-box-wrapper\">\n\n\t\t\t\t\t\t<div class=\"elementor-icon-box-icon\">\n\t\t\t\t<span  class=\"elementor-icon\">\n\t\t\t\t<i aria-hidden=\"true\" class=\"far fa-thumbs-up\"><\/i>\t\t\t\t<\/span>\n\t\t\t<\/div>\n\t\t\t\n\t\t\t\t\t\t<div class=\"elementor-icon-box-content\">\n\n\t\t\t\t\t\t\t\t\t<h4 class=\"elementor-icon-box-title\">\n\t\t\t\t\t\t<span  >\n\t\t\t\t\t\t\tSkill Level\t\t\t\t\t\t<\/span>\n\t\t\t\t\t<\/h4>\n\t\t\t\t\n\t\t\t\t\t\t\t\t\t<p class=\"elementor-icon-box-description\">\n\t\t\t\t\t\tUpper-Intermediate\t\t\t\t\t<\/p>\n\t\t\t\t\n\t\t\t<\/div>\n\t\t\t\n\t\t<\/div>\n\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-e74a040 elementor-widget elementor-widget-raven-divider\" data-id=\"e74a040\" data-element_type=\"widget\" data-widget_type=\"raven-divider.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t<div class=\"raven-widget-wrapper\">\r\n\t\t\t<div class=\"raven-divider\">\r\n\t\t\t\t<span class=\"raven-divider-line raven-divider-solid\"><\/span>\r\n\t\t\t<\/div>\r\n\t\t<\/div>\r\n\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-2ad1413 elementor-position-left elementor-view-default elementor-mobile-position-top elementor-vertical-align-top elementor-widget elementor-widget-icon-box\" data-id=\"2ad1413\" data-element_type=\"widget\" data-widget_type=\"icon-box.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t<div class=\"elementor-icon-box-wrapper\">\n\n\t\t\t\t\t\t<div class=\"elementor-icon-box-icon\">\n\t\t\t\t<span  class=\"elementor-icon\">\n\t\t\t\t<i aria-hidden=\"true\" class=\"far fa-bookmark\"><\/i>\t\t\t\t<\/span>\n\t\t\t<\/div>\n\t\t\t\n\t\t\t\t\t\t<div class=\"elementor-icon-box-content\">\n\n\t\t\t\t\t\t\t\t\t<h4 class=\"elementor-icon-box-title\">\n\t\t\t\t\t\t<span  >\n\t\t\t\t\t\t\tExercises\t\t\t\t\t\t<\/span>\n\t\t\t\t\t<\/h4>\n\t\t\t\t\n\t\t\t\t\t\t\t\t\t<p class=\"elementor-icon-box-description\">\n\t\t\t\t\t\tna\t\t\t\t\t<\/p>\n\t\t\t\t\n\t\t\t<\/div>\n\t\t\t\n\t\t<\/div>\n\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-5c7de32 elementor-widget elementor-widget-raven-divider\" data-id=\"5c7de32\" data-element_type=\"widget\" data-widget_type=\"raven-divider.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t<div class=\"raven-widget-wrapper\">\r\n\t\t\t<div class=\"raven-divider\">\r\n\t\t\t\t<span class=\"raven-divider-line raven-divider-solid\"><\/span>\r\n\t\t\t<\/div>\r\n\t\t<\/div>\r\n\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-108adec elementor-position-left elementor-vertical-align-middle elementor-view-default elementor-mobile-position-top elementor-widget elementor-widget-icon-box\" data-id=\"108adec\" data-element_type=\"widget\" data-widget_type=\"icon-box.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t<div class=\"elementor-icon-box-wrapper\">\n\n\t\t\t\t\t\t<div class=\"elementor-icon-box-icon\">\n\t\t\t\t<span  class=\"elementor-icon\">\n\t\t\t\t<i aria-hidden=\"true\" class=\"fas fa-book\"><\/i>\t\t\t\t<\/span>\n\t\t\t<\/div>\n\t\t\t\n\t\t\t\t\t\t<div class=\"elementor-icon-box-content\">\n\n\t\t\t\t\t\t\t\t\t<h4 class=\"elementor-icon-box-title\">\n\t\t\t\t\t\t<span  >\n\t\t\t\t\t\t\tPosts from the Series\t\t\t\t\t\t<\/span>\n\t\t\t\t\t<\/h4>\n\t\t\t\t\n\t\t\t\t\n\t\t\t<\/div>\n\t\t\t\n\t\t<\/div>\n\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-cea4630 elementor-vertical-align-middle elementor-widget elementor-widget-icon-box\" data-id=\"cea4630\" data-element_type=\"widget\" data-widget_type=\"icon-box.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t<div class=\"elementor-icon-box-wrapper\">\n\n\t\t\t\n\t\t\t\t\t\t<div class=\"elementor-icon-box-content\">\n\n\t\t\t\t\t\t\t\t\t<h4 class=\"elementor-icon-box-title\">\n\t\t\t\t\t\t<a href=\"https:\/\/holypython.com\/python-packaging-quick-tutorial-checklist\/\" target=\"_blank\" >\n\t\t\t\t\t\t\t1- Introduction\t\t\t\t\t\t<\/a>\n\t\t\t\t\t<\/h4>\n\t\t\t\t\n\t\t\t\t\n\t\t\t<\/div>\n\t\t\t\n\t\t<\/div>\n\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-9d225a8 elementor-vertical-align-middle elementor-widget elementor-widget-icon-box\" data-id=\"9d225a8\" data-element_type=\"widget\" data-widget_type=\"icon-box.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t<div class=\"elementor-icon-box-wrapper\">\n\n\t\t\t\n\t\t\t\t\t\t<div class=\"elementor-icon-box-content\">\n\n\t\t\t\t\t\t\t\t\t<h4 class=\"elementor-icon-box-title\">\n\t\t\t\t\t\t<a href=\"https:\/\/holypython.com\/python-packaging-getting-ready\/\" target=\"_blank\" >\n\t\t\t\t\t\t\t2- Getting Ready\t\t\t\t\t\t<\/a>\n\t\t\t\t\t<\/h4>\n\t\t\t\t\n\t\t\t\t\n\t\t\t<\/div>\n\t\t\t\n\t\t<\/div>\n\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-682d727 elementor-vertical-align-middle elementor-widget elementor-widget-icon-box\" data-id=\"682d727\" data-element_type=\"widget\" data-widget_type=\"icon-box.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t<div class=\"elementor-icon-box-wrapper\">\n\n\t\t\t\n\t\t\t\t\t\t<div class=\"elementor-icon-box-content\">\n\n\t\t\t\t\t\t\t\t\t<h4 class=\"elementor-icon-box-title\">\n\t\t\t\t\t\t<a href=\"https:\/\/holypython.com\/python-packaging-software-licenses-open-source-licensing-and-more\/\" target=\"_blank\" >\n\t\t\t\t\t\t\t3- Licensing\t\t\t\t\t\t<\/a>\n\t\t\t\t\t<\/h4>\n\t\t\t\t\n\t\t\t\t\n\t\t\t<\/div>\n\t\t\t\n\t\t<\/div>\n\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-44764d6 elementor-vertical-align-middle elementor-widget elementor-widget-icon-box\" data-id=\"44764d6\" data-element_type=\"widget\" data-widget_type=\"icon-box.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t<div class=\"elementor-icon-box-wrapper\">\n\n\t\t\t\n\t\t\t\t\t\t<div class=\"elementor-icon-box-content\">\n\n\t\t\t\t\t\t\t\t\t<h4 class=\"elementor-icon-box-title\">\n\t\t\t\t\t\t<a href=\"https:\/\/holypython.com\/python-packaging-hosting-code-at-github\/\" >\n\t\t\t\t\t\t\t4-Github\t\t\t\t\t\t<\/a>\n\t\t\t\t\t<\/h4>\n\t\t\t\t\n\t\t\t\t\n\t\t\t<\/div>\n\t\t\t\n\t\t<\/div>\n\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-c48657d elementor-widget elementor-widget-raven-divider\" data-id=\"c48657d\" data-element_type=\"widget\" data-widget_type=\"raven-divider.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t<div class=\"raven-widget-wrapper\">\r\n\t\t\t<div class=\"raven-divider\">\r\n\t\t\t\t<span class=\"raven-divider-line raven-divider-solid\"><\/span>\r\n\t\t\t<\/div>\r\n\t\t<\/div>\r\n\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-3308cf6 elementor-vertical-align-middle elementor-widget elementor-widget-icon-box\" data-id=\"3308cf6\" data-element_type=\"widget\" data-widget_type=\"icon-box.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t<div class=\"elementor-icon-box-wrapper\">\n\n\t\t\t\n\t\t\t\t\t\t<div class=\"elementor-icon-box-content\">\n\n\t\t\t\t\t\t\t\t\t<h4 class=\"elementor-icon-box-title\">\n\t\t\t\t\t\t<a href=\"https:\/\/holypython.com\/python-packaging-necessary-files-setup-py-requirements-txt-readme-md-__init__-py\/\" >\n\t\t\t\t\t\t\t5- Necessary Files\t\t\t\t\t\t<\/a>\n\t\t\t\t\t<\/h4>\n\t\t\t\t\n\t\t\t\t\n\t\t\t<\/div>\n\t\t\t\n\t\t<\/div>\n\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-b2978e8 elementor-vertical-align-middle elementor-widget elementor-widget-icon-box\" data-id=\"b2978e8\" data-element_type=\"widget\" data-widget_type=\"icon-box.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t<div class=\"elementor-icon-box-wrapper\">\n\n\t\t\t\n\t\t\t\t\t\t<div class=\"elementor-icon-box-content\">\n\n\t\t\t\t\t\t\t\t\t<h4 class=\"elementor-icon-box-title\">\n\t\t\t\t\t\t<a href=\"https:\/\/holypython.com\/python-packaging-local-installation-tests-before-uploading\/\" target=\"_blank\" >\n\t\t\t\t\t\t\t6- Local Tests\t\t\t\t\t\t<\/a>\n\t\t\t\t\t<\/h4>\n\t\t\t\t\n\t\t\t\t\n\t\t\t<\/div>\n\t\t\t\n\t\t<\/div>\n\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-07a20b0 elementor-vertical-align-middle elementor-widget elementor-widget-icon-box\" data-id=\"07a20b0\" data-element_type=\"widget\" data-widget_type=\"icon-box.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t<div class=\"elementor-icon-box-wrapper\">\n\n\t\t\t\n\t\t\t\t\t\t<div class=\"elementor-icon-box-content\">\n\n\t\t\t\t\t\t\t\t\t<h4 class=\"elementor-icon-box-title\">\n\t\t\t\t\t\t<a href=\"https:\/\/holypython.com\/python-packaging-uploading-a-python-library-to-pypi\/\" target=\"_blank\" >\n\t\t\t\t\t\t\t7- Upload to PyPI\t\t\t\t\t\t<\/a>\n\t\t\t\t\t<\/h4>\n\t\t\t\t\n\t\t\t\t\n\t\t\t<\/div>\n\t\t\t\n\t\t<\/div>\n\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-d806fed elementor-widget elementor-widget-raven-divider\" data-id=\"d806fed\" data-element_type=\"widget\" data-widget_type=\"raven-divider.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t<div class=\"raven-widget-wrapper\">\r\n\t\t\t<div class=\"raven-divider\">\r\n\t\t\t\t<span class=\"raven-divider-line raven-divider-solid\"><\/span>\r\n\t\t\t<\/div>\r\n\t\t<\/div>\r\n\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-83ee22b elementor-widget elementor-widget-heading\" data-id=\"83ee22b\" data-element_type=\"widget\" data-widget_type=\"heading.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t<h4 class=\"elementor-heading-title elementor-size-default\">Course Provider<\/h4>\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-c3a3813 elementor-widget elementor-widget-text-editor\" data-id=\"c3a3813\" data-element_type=\"widget\" data-widget_type=\"text-editor.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t\t\t<p>Provided by HolyPython.com<\/p>\t\t\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-5f17dc3 elementor-widget elementor-widget-image\" data-id=\"5f17dc3\" data-element_type=\"widget\" data-widget_type=\"image.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t<img decoding=\"async\" width=\"398\" height=\"344\" src=\"https:\/\/holypython.com\/wp-content\/uploads\/2020\/10\/holypython_side_logo_img.jpg\" class=\"attachment-full size-full wp-image-15177\" alt=\"\" srcset=\"https:\/\/holypython.com\/wp-content\/uploads\/2020\/10\/holypython_side_logo_img.jpg 398w, https:\/\/holypython.com\/wp-content\/uploads\/2020\/10\/holypython_side_logo_img-300x259.jpg 300w\" sizes=\"(max-width: 398px) 100vw, 398px\" \/>\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/section>\n\t\t\t\t\t<\/div>\n\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/section>\n\t\t\t\t<section class=\"elementor-section elementor-top-section elementor-element elementor-element-f302186 elementor-section-boxed elementor-section-height-default elementor-section-height-default\" data-id=\"f302186\" data-element_type=\"section\">\n\t\t\t\t\t\t<div class=\"elementor-container elementor-column-gap-default\">\n\t\t\t\t\t<div class=\"elementor-column elementor-col-100 elementor-top-column elementor-element elementor-element-461d7c3\" data-id=\"461d7c3\" data-element_type=\"column\">\n\t\t\t<div class=\"elementor-widget-wrap elementor-element-populated\">\n\t\t\t\t\t\t<div class=\"elementor-element elementor-element-20c770e elementor-widget elementor-widget-text-editor\" data-id=\"20c770e\" data-element_type=\"widget\" data-widget_type=\"text-editor.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t\t\t<p>This page is a practical summary version of all the steps involved in Python library packaging. You can also find links for longer versions of each step with more detailed explanations, comments and remedies for potential pitfalls at the bottom of this page along with a Python packaging checklist.<\/p><p><span style=\"color: var( --e-global-color-text ); font-family: var( --e-global-typography-text-font-family );\">If you&#8217;re reading this tutorial you might already have a cool invention or an improved version of some other program. In that case congratulations! You&#8217;re one step closer to creating wealth for yourself and also for the world.<\/span><\/p><p>If you don&#8217;t have something tangible yet don&#8217;t worry, it&#8217;s something that comes with sustained practice. I don&#8217;t mean to be corny but, just continue coding and exploring and if you stay at it it&#8217;s almost guaranteed to happen. When the inspiration is there though, it&#8217;s advised not to sleep on it, so when the moment comes, don&#8217;t put it off, don&#8217;t delay, act and realize!<\/p><p>So, here is a summary of the major Python packaging cornerstones:<\/p><ol style=\"font-family: Merriweather, sans-serif;\"><li>Getting the Code Ready for Packaging<\/li><li>Hosting at Github<\/li><li>Open Source Software Licenses<\/li><li>Necessary Files (setup.py, readme.md, license, __init__.py, requirements.txt, setup.cfg)<\/li><li>Local Installation, tests and __init__.py File<\/li><li>Uploading to PyPI with Twine<\/li><\/ol><div><span style=\"font-family: Merriweather, sans-serif;\">Long version links at the bottom.<\/span><\/div>\t\t\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-0d70e47 elementor-widget elementor-widget-image\" data-id=\"0d70e47\" data-element_type=\"widget\" data-widget_type=\"image.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t\t\t\t\t\t<figure class=\"wp-caption\">\n\t\t\t\t\t\t\t\t\t\t<img decoding=\"async\" width=\"640\" height=\"427\" src=\"https:\/\/holypython.com\/wp-content\/uploads\/2020\/09\/sGwoXcxKbcE-.jpg\" class=\"attachment-full size-full wp-image-15260\" alt=\"\" srcset=\"https:\/\/holypython.com\/wp-content\/uploads\/2020\/09\/sGwoXcxKbcE-.jpg 640w, https:\/\/holypython.com\/wp-content\/uploads\/2020\/09\/sGwoXcxKbcE--300x200.jpg 300w\" sizes=\"(max-width: 640px) 100vw, 640px\" \/>\t\t\t\t\t\t\t\t\t\t\t<figcaption class=\"widget-image-caption wp-caption-text\">A routine startup portrait, members discussing in front of computers<\/figcaption>\n\t\t\t\t\t\t\t\t\t\t<\/figure>\n\t\t\t\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-4ae60be elementor-widget elementor-widget-text-editor\" data-id=\"4ae60be\" data-element_type=\"widget\" data-widget_type=\"text-editor.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t\t\t<p>At some point in your coding journey, eventually you realize the power of publishing. Open source is really cool and it enables sharing technical knowledge and intellectual products at an unprecedented level. But only when you experience first hand:<\/p><ul><li>An open source program development on Github<\/li><li>Publishing your program on a library like Pypi. Maybe at different stages like:<ul><li>Pre-alpha,<\/li><li>Alpha,<\/li><li>Beta,<\/li><li>Release Candidate,<\/li><li>Stable Release)<\/li><\/ul><\/li><\/ul><p>you really start to feel the incredible power of open source synergies.<\/p><p>It is recommended to every programmer, yet, the knowledge gap seems to prevent many people from getting to that stage.<\/p><p>It&#8217;s not that difficult, but there is an open source terminology involved which can be confusing for a lot of people.<\/p><p>This is a huge value loss for everyone, for the programmer, for his environment, eventually for the whole world. Because you never know how far that programmer is going to be able to go if those gaps are bridged and dots are connected.<\/p><p>So, hopefully this Python tutorial empowers coders at the beginning stages of their journey and helps them understand how to package Python code, how to create a library, how to create a module. You might not necessarily be a beginner programmer, but you might not have discovered these topics yet or had the opportunity or occasion for it.<\/p><p>Nevertheless, understanding library structures and entering open source world really expands a coders horizons and we recommend stepping into this knowledge space as soon as possible since the benefits are so high.<\/p><p>You might have just learned how to print &#8220;Hello World&#8221; or you might actually be producing advanced level programs already and just not have stumbled upon this knowledge yet. In the end, it&#8217;s all good. Everyone&#8217;s journey is unique and it&#8217;s important to embrace and strive to progressively move forward.<\/p><p>\u00a0<\/p><p>Let&#8217;s check out the general frame of the packaging process and if you&#8217;d like to go deeper in any of the steps we have links for that too.<\/p>\t\t\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/section>\n\t\t\t\t<section class=\"elementor-section elementor-top-section elementor-element elementor-element-5b539c2 elementor-section-boxed elementor-section-height-default elementor-section-height-default\" data-id=\"5b539c2\" data-element_type=\"section\">\n\t\t\t\t\t\t<div class=\"elementor-container elementor-column-gap-default\">\n\t\t\t\t\t<div class=\"elementor-column elementor-col-100 elementor-top-column elementor-element elementor-element-15b6b4f\" data-id=\"15b6b4f\" data-element_type=\"column\">\n\t\t\t<div class=\"elementor-widget-wrap elementor-element-populated\">\n\t\t\t\t\t\t<div class=\"elementor-element elementor-element-700d5ec elementor-widget__width-auto elementor-widget elementor-widget-heading\" data-id=\"700d5ec\" data-element_type=\"widget\" data-widget_type=\"heading.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t<h2 class=\"elementor-heading-title elementor-size-default\">Python Packaging Preparation<\/h2>\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-f5e910f elementor-widget elementor-widget-text-editor\" data-id=\"f5e910f\" data-element_type=\"widget\" data-widget_type=\"text-editor.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t\t\t<p>After you have a functioning code you will want to do a certain type of cleaning up on it because, code in a library is slightly different than the code in a local .py file that&#8217;s used for personal tasks and development. Here are some common practices:<\/p><ul><li>Clean up the unnecessary comments<\/li><li>Clean up the part or all of print functions not to cloud user&#8217;s terminal too much<\/li><li>If something can be expressed as a user-defined function, then consider building some functions.<\/li><li>Tidy up via Python classes. Try to place everything inside a class or multiple classes. User-defined functions can be run from inside the class when needed. For example:<ul><li>class A:<ul><li>def alpha():<\/li><\/ul><\/li><\/ul><\/li><li>A.alpha()<\/li><\/ul><p>Before we advance, and after certain improvements on your code you also need a few tools for packaging so you might want to get them ready. These are:<\/p><ol><li>A Github account<\/li><li>A PyPI account<\/li><li>Command Prompt that works with Python (or PowerShell), we suggest Anaconda Command Prompt as a practical and complete solution.<\/li><li><b>twine<\/b> library installed in Python for uploading to PyPI<\/li><\/ol>\t\t\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/section>\n\t\t\t\t<section class=\"elementor-section elementor-top-section elementor-element elementor-element-4ad40cf elementor-section-boxed elementor-section-height-default elementor-section-height-default\" data-id=\"4ad40cf\" data-element_type=\"section\">\n\t\t\t\t\t\t<div class=\"elementor-container elementor-column-gap-default\">\n\t\t\t\t\t<div class=\"elementor-column elementor-col-100 elementor-top-column elementor-element elementor-element-1f02641\" data-id=\"1f02641\" data-element_type=\"column\">\n\t\t\t<div class=\"elementor-widget-wrap elementor-element-populated\">\n\t\t\t\t\t\t<div class=\"elementor-element elementor-element-2f19210 elementor-widget__width-auto elementor-widget elementor-widget-heading\" data-id=\"2f19210\" data-element_type=\"widget\" data-widget_type=\"heading.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t<h2 class=\"elementor-heading-title elementor-size-default\">Creating a Github Repository<\/h2>\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-c5beba2 elementor-widget elementor-widget-text-editor\" data-id=\"c5beba2\" data-element_type=\"widget\" data-widget_type=\"text-editor.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t\t\t<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Ut elit tellus, luctus nec ullamcorper mattis, pulvinar dapibus leo.<\/p>\t\t\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-ec17793 elementor-widget elementor-widget-html\" data-id=\"ec17793\" data-element_type=\"widget\" data-widget_type=\"html.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t<pre rel=\"Python\"><code>python setup.py sdist\r\n<\/code><\/pre>\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/section>\n\t\t\t\t<section class=\"elementor-section elementor-top-section elementor-element elementor-element-88d6cd7 elementor-section-boxed elementor-section-height-default elementor-section-height-default\" data-id=\"88d6cd7\" data-element_type=\"section\">\n\t\t\t\t\t\t<div class=\"elementor-container elementor-column-gap-default\">\n\t\t\t\t\t<div class=\"elementor-column elementor-col-100 elementor-top-column elementor-element elementor-element-a72199f\" data-id=\"a72199f\" data-element_type=\"column\">\n\t\t\t<div class=\"elementor-widget-wrap elementor-element-populated\">\n\t\t\t\t\t\t<div class=\"elementor-element elementor-element-596efce elementor-widget__width-auto elementor-widget elementor-widget-heading\" data-id=\"596efce\" data-element_type=\"widget\" data-widget_type=\"heading.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t<h2 class=\"elementor-heading-title elementor-size-default\">Choosing a license<\/h2>\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-215a67b elementor-widget elementor-widget-text-editor\" data-id=\"215a67b\" data-element_type=\"widget\" data-widget_type=\"text-editor.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t\t\t<p>If you&#8217;re sharing your code you need a license so that important aspects of usage, development, price, modification, reselling, responsibility, sublicensing etc. are more clear.<\/p><p>Most common open source licenses are:<\/p><p><span style=\"color: var( --e-global-color-text ); font-family: var( --e-global-typography-text-font-family );\">Apache-2.0<\/span><\/p><p>GNU GPL<\/p><p>GNU LGPL<\/p><p>MIT License<\/p><p>BSD Licenses<\/p><p>More on open source licenses <a href=\"https:\/\/holypython.com\/python-packaging-software-licenses-open-source-licensing-and-more\/\" target=\"_blank\" rel=\"noopener\">here<\/a>.<\/p>\t\t\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/section>\n\t\t\t\t<section class=\"elementor-section elementor-top-section elementor-element elementor-element-a861af0 elementor-section-boxed elementor-section-height-default elementor-section-height-default\" data-id=\"a861af0\" data-element_type=\"section\">\n\t\t\t\t\t\t<div class=\"elementor-container elementor-column-gap-default\">\n\t\t\t\t\t<div class=\"elementor-column elementor-col-100 elementor-top-column elementor-element elementor-element-1d70353\" data-id=\"1d70353\" data-element_type=\"column\">\n\t\t\t<div class=\"elementor-widget-wrap elementor-element-populated\">\n\t\t\t\t\t\t<div class=\"elementor-element elementor-element-2c75433 elementor-widget__width-auto elementor-widget elementor-widget-heading\" data-id=\"2c75433\" data-element_type=\"widget\" data-widget_type=\"heading.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t<h2 class=\"elementor-heading-title elementor-size-default\">Necessary Files<\/h2>\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-0364f26 elementor-widget elementor-widget-text-editor\" data-id=\"0364f26\" data-element_type=\"widget\" data-widget_type=\"text-editor.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t\t\t<p>You need a couple of files that you might not be familiar with in order to package your Python library and turn it into an installable repository. These files are:<\/p>\n<p>setup.py<\/p>\n<p>requirements.txt (optional)<\/p>\n<p>readme.md&nbsp;<span style=\"color: var( --e-global-color-text ); font-family: var( --e-global-typography-text-font-family );\">(optional)<\/span><\/p>\n<p>setup.cfg&nbsp;<span style=\"color: var( --e-global-color-text ); font-family: var( --e-global-typography-text-font-family );\">(optional)<\/span><\/p><p><span style=\"color: var( --e-global-color-text ); font-family: var( --e-global-typography-text-font-family );\">__init__.py (optional)<\/span><\/p><p><span style=\"color: var( --e-global-color-text ); font-family: var( --e-global-typography-text-font-family );\">So, before being misleading, although it seems only setup.py is obligatory for Python installation and this is technically true, all of the files above are pretty obligatory in practical sense. You don&#8217;t really want to miss any of them.<\/span><\/p>\t\t\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-1063d07 elementor-widget elementor-widget-html\" data-id=\"1063d07\" data-element_type=\"widget\" data-widget_type=\"html.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t<pre rel=\"Python\"><code>python setup.py sdist\r\n<\/code><\/pre>\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/section>\n\t\t\t\t<section class=\"elementor-section elementor-top-section elementor-element elementor-element-a1836f3 elementor-section-boxed elementor-section-height-default elementor-section-height-default\" data-id=\"a1836f3\" data-element_type=\"section\">\n\t\t\t\t\t\t<div class=\"elementor-container elementor-column-gap-default\">\n\t\t\t\t\t<div class=\"elementor-column elementor-col-100 elementor-top-column elementor-element elementor-element-69c39b8\" data-id=\"69c39b8\" data-element_type=\"column\">\n\t\t\t<div class=\"elementor-widget-wrap elementor-element-populated\">\n\t\t\t\t\t\t<div class=\"elementor-element elementor-element-eefbce4 elementor-widget__width-auto elementor-widget elementor-widget-heading\" data-id=\"eefbce4\" data-element_type=\"widget\" data-widget_type=\"heading.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t<h2 class=\"elementor-heading-title elementor-size-default\">Creating a Release on Github<\/h2>\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-1ef1cf3 elementor-widget elementor-widget-text-editor\" data-id=\"1ef1cf3\" data-element_type=\"widget\" data-widget_type=\"text-editor.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t\t\t<p>Github is a great platform for coding collaboration, version management and open source sharing. It&#8217;s free and you simply sign up and create a new repository.<\/p><p>You might want to skip the license selection for your project at the very beginning if you&#8217;re not informed on the topic yet.<\/p>\t\t\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/section>\n\t\t\t\t<section class=\"elementor-section elementor-top-section elementor-element elementor-element-5814d0a elementor-section-boxed elementor-section-height-default elementor-section-height-default\" data-id=\"5814d0a\" data-element_type=\"section\">\n\t\t\t\t\t\t<div class=\"elementor-container elementor-column-gap-default\">\n\t\t\t\t\t<div class=\"elementor-column elementor-col-100 elementor-top-column elementor-element elementor-element-3a0a62e\" data-id=\"3a0a62e\" data-element_type=\"column\">\n\t\t\t<div class=\"elementor-widget-wrap elementor-element-populated\">\n\t\t\t\t\t\t<div class=\"elementor-element elementor-element-1f6cb4f elementor-widget__width-auto elementor-widget elementor-widget-heading\" data-id=\"1f6cb4f\" data-element_type=\"widget\" data-widget_type=\"heading.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t<h2 class=\"elementor-heading-title elementor-size-default\">Local Installation &amp; Testing<\/h2>\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-71c95aa elementor-widget elementor-widget-text-editor\" data-id=\"71c95aa\" data-element_type=\"widget\" data-widget_type=\"text-editor.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t\t\t<p>First off, you can just navigate to the root folder which hosts your package and import the package after launching Python there. This is as simple as navigating with <b>cd<\/b> command and then launching Python and trying to import the library as intended.<\/p><p>Eventually though you will want to make a real installation to see if everything is going through smoohtly.\u00a0<\/p><p>You can use the code below for a local installation, first create a source distribution, it will create a Python egg and source distribution in the folder where your package exists.<\/p>\t\t\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-c18c942 elementor-widget elementor-widget-text-editor\" data-id=\"c18c942\" data-element_type=\"widget\" data-widget_type=\"text-editor.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t\t\t<p>Installing a library locally is very simple and straightforward. Just navigate to the package&#8217;s root folder where setup.py can be found and execute the command below:<\/p>\t\t\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-ed4546a elementor-widget elementor-widget-html\" data-id=\"ed4546a\" data-element_type=\"widget\" data-widget_type=\"html.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t<pre rel=\"Python\"><code>pip install .\r\n<\/code><\/pre>\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-6ca6266 elementor-widget elementor-widget-text-editor\" data-id=\"6ca6266\" data-element_type=\"widget\" data-widget_type=\"text-editor.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t\t\t<p>This one will properly install the package inside the site-packages folder under your Python installation folder.<\/p><p><b>It can be more convenient if you don&#8217;t want to have to navigate to the specific directory to import your library and it&#8217;s still a local installation and has nothing to do with uploading.<\/b><\/p><p>After installation is successful, you can just import your library like any other library:<\/p>\t\t\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-45baa64 elementor-widget elementor-widget-html\" data-id=\"45baa64\" data-element_type=\"widget\" data-widget_type=\"html.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t<pre rel=\"Python\"><code>import [library_I_developed]\r\n<\/code><\/pre>\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-018cc32 elementor-widget elementor-widget-text-editor\" data-id=\"018cc32\" data-element_type=\"widget\" data-widget_type=\"text-editor.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t\t\t<p>At this point, you can make the final checks, see if library is installing and functioning as it&#8217;s supposed to, you can also check if <b>__init__.py<\/b> files are functioning properly and creating the correct importing structure you intend for your users.<\/p>\t\t\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/section>\n\t\t\t\t<section class=\"elementor-section elementor-top-section elementor-element elementor-element-9e5c950 elementor-section-boxed elementor-section-height-default elementor-section-height-default\" data-id=\"9e5c950\" data-element_type=\"section\">\n\t\t\t\t\t\t<div class=\"elementor-container elementor-column-gap-default\">\n\t\t\t\t\t<div class=\"elementor-column elementor-col-100 elementor-top-column elementor-element elementor-element-4b55fab\" data-id=\"4b55fab\" data-element_type=\"column\">\n\t\t\t<div class=\"elementor-widget-wrap elementor-element-populated\">\n\t\t\t\t\t\t<div class=\"elementor-element elementor-element-d26af60 elementor-widget__width-auto elementor-widget elementor-widget-heading\" data-id=\"d26af60\" data-element_type=\"widget\" data-widget_type=\"heading.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t<h2 class=\"elementor-heading-title elementor-size-default\">Uploading to PyPI<\/h2>\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-50bfe9a elementor-widget elementor-widget-text-editor\" data-id=\"50bfe9a\" data-element_type=\"widget\" data-widget_type=\"text-editor.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t\t\t<p><b>If everything is looking absolutely fine it&#8217;s time to step into the wild. Wild in this case is Python Package Index or PyPI.<\/b><\/p><p>Egg and source distribution terminology can be confusing. Source distribution is just your library packaged in a <b>.zip<\/b> or <b>.tar.gz<\/b> compressed archive formats. Installation occurs through these source distributions.<\/p><p>Egg is pretty much the same thing and it&#8217;s a zip file, it&#8217;s just a bit specialized and distinct so it&#8217;s extension is .egg instead of .zip. You can still open it as a zip file and check out the content if you&#8217;re curious.<\/p><p>So, let&#8217;s create the source distribution:<\/p>\t\t\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-1ceba86 elementor-widget elementor-widget-html\" data-id=\"1ceba86\" data-element_type=\"widget\" data-widget_type=\"html.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t<pre rel=\"Python\"><code>python setup.py sdist\r\n<\/code><\/pre>\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-839a10d elementor-widget elementor-widget-text-editor\" data-id=\"839a10d\" data-element_type=\"widget\" data-widget_type=\"text-editor.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t\t\t<p>This will create a source distribution which is basically a tar.gz or zip file as mentioned above.<\/p><p>Now you have a source distribution ready to be shipped to PyPI however, it&#8217;s beneficial to add one more step. It takes a couple of seconds but it can save you lots of headache.<\/p><p>Using twine check all the distributions inside the package. If there is an error with the setup.py file or readme.md file or any of the other ones, it will tell you what the error is so you can fix it and ship again.<\/p>\t\t\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-b8a0aad elementor-widget elementor-widget-html\" data-id=\"b8a0aad\" data-element_type=\"widget\" data-widget_type=\"html.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t<pre rel=\"Python\"><code>import twine\r\n\r\ntwine check dist\/*\r\n<\/code><\/pre>\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-e8cca38 elementor-widget elementor-widget-text-editor\" data-id=\"e8cca38\" data-element_type=\"widget\" data-widget_type=\"text-editor.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t\t\t<p>Once everything clears 100%, it&#8217;s time to upload. Just execute the command below:<br \/><i>Don&#8217;t forget to import twine if you haven&#8217;t before.<\/i><\/p>\t\t\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-0ccf0d1 elementor-widget elementor-widget-html\" data-id=\"0ccf0d1\" data-element_type=\"widget\" data-widget_type=\"html.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t<pre rel=\"Python\"><code>twine upload dist\/*\r\n<\/code><\/pre>\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-9589251 elementor-widget elementor-widget-text-editor\" data-id=\"9589251\" data-element_type=\"widget\" data-widget_type=\"text-editor.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t\t\t<p>You&#8217;ll be asked your PyPI username and then password, just type those in order and press enter and your package will be uploaded.<\/p>\t\t\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-54fcfbd elementor-widget elementor-widget-text-editor\" data-id=\"54fcfbd\" data-element_type=\"widget\" data-widget_type=\"text-editor.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t\t\t<p>If update to PyPI is successful, that means that now your library can be installed on any computer with Python and internet connection all around the world. All that&#8217;s needed is the execution of this simple pip command:<\/p>\t\t\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-e81efaf elementor-widget elementor-widget-html\" data-id=\"e81efaf\" data-element_type=\"widget\" data-widget_type=\"html.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t<pre rel=\"Python\"><code>pip install [Library_Name]\r\n<\/code><\/pre>\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-c792cbf elementor-widget elementor-widget-text-editor\" data-id=\"c792cbf\" data-element_type=\"widget\" data-widget_type=\"text-editor.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t\t\t<p>Just get rid of the brackets around your library name when you&#8217;re actually installing it.<\/p>\t\t\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/section>\n\t\t\t\t<section class=\"elementor-section elementor-top-section elementor-element elementor-element-ccaff17 elementor-section-boxed elementor-section-height-default elementor-section-height-default\" data-id=\"ccaff17\" data-element_type=\"section\">\n\t\t\t\t\t\t<div class=\"elementor-container elementor-column-gap-default\">\n\t\t\t\t\t<div class=\"elementor-column elementor-col-100 elementor-top-column elementor-element elementor-element-ef79018\" data-id=\"ef79018\" data-element_type=\"column\">\n\t\t\t<div class=\"elementor-widget-wrap elementor-element-populated\">\n\t\t\t\t\t\t<div class=\"elementor-element elementor-element-0721804 elementor-widget__width-auto elementor-widget elementor-widget-heading\" data-id=\"0721804\" data-element_type=\"widget\" data-widget_type=\"heading.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t<h2 class=\"elementor-heading-title elementor-size-default\">Updating the package in PyPI<\/h2>\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-186873e elementor-widget elementor-widget-text-editor\" data-id=\"186873e\" data-element_type=\"widget\" data-widget_type=\"text-editor.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t\t\t<p><b>You will likely have new versions every now and then just create a new source distribution and repeat the check and upload steps and your package will be updated automatically.<\/b><\/p>\t\t\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-fe9297c elementor-widget elementor-widget-html\" data-id=\"fe9297c\" data-element_type=\"widget\" data-widget_type=\"html.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t<pre rel=\"Python\"><code>python setup.py sdist\r\n<\/code><\/pre>\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-3258d04 elementor-widget elementor-widget-html\" data-id=\"3258d04\" data-element_type=\"widget\" data-widget_type=\"html.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t<pre rel=\"Python\"><code>import twine\r\n\r\ntwine check dist\/*\r\n<\/code><\/pre>\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-099dff1 elementor-widget elementor-widget-html\" data-id=\"099dff1\" data-element_type=\"widget\" data-widget_type=\"html.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t<pre rel=\"Python\"><code>twine upload dist\/*\r\n<\/code><\/pre>\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-4056cf1 elementor-widget elementor-widget-text-editor\" data-id=\"4056cf1\" data-element_type=\"widget\" data-widget_type=\"text-editor.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t\t\t<p>After that you might want to update your library in your computer from PyPI. Just run this code for that:<\/p>\t\t\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-31eea96 elementor-widget elementor-widget-html\" data-id=\"31eea96\" data-element_type=\"widget\" data-widget_type=\"html.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t<pre rel=\"Python\"><code>pip install [Library_Name] --upgrade \r\n<\/code><\/pre>\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-1e03b34 elementor-widget elementor-widget-text-editor\" data-id=\"1e03b34\" data-element_type=\"widget\" data-widget_type=\"text-editor.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t\t\t<p>If you still have question, each step included here has its own long version below and maybe the answers you&#8217;re looking for are there. It can still be a good idea to check them out even if you don&#8217;t have any questions since there are some cool knowledge included regarding each step of Python packaging.<\/p>\t\t\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/section>\n\t\t\t\t<section class=\"elementor-section elementor-top-section elementor-element elementor-element-a8e4083 elementor-section-boxed elementor-section-height-default elementor-section-height-default\" data-id=\"a8e4083\" data-element_type=\"section\">\n\t\t\t\t\t\t<div class=\"elementor-container elementor-column-gap-default\">\n\t\t\t\t\t<div class=\"elementor-column elementor-col-100 elementor-top-column elementor-element elementor-element-24cca33\" data-id=\"24cca33\" data-element_type=\"column\">\n\t\t\t<div class=\"elementor-widget-wrap elementor-element-populated\">\n\t\t\t\t\t\t<div class=\"elementor-element elementor-element-71e97bf elementor-widget__width-auto elementor-widget elementor-widget-heading\" data-id=\"71e97bf\" data-element_type=\"widget\" data-widget_type=\"heading.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t<h2 class=\"elementor-heading-title elementor-size-default\">Python Packaging Tutorials (Long Versions):<\/h2>\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-a77201e elementor-widget elementor-widget-text-editor\" data-id=\"a77201e\" data-element_type=\"widget\" data-widget_type=\"text-editor.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t\t\t<ol>\n<li><a href=\"https:\/\/holypython.com\/python-packaging-quick-tutorial-checklist\/\">Python Packaging Quick Version (this tutorial)<\/a><\/li>\n<li><a href=\"https:\/\/holypython.com\/python-packaging-getting-ready\/\" target=\"_blank\" rel=\"noopener\">Getting the Code Ready for Packaging<\/a><\/li>\n<li><a href=\"https:\/\/holypython.com\/python-packaging-hosting-code-at-github\/\">Hosting at Github<\/a><\/li>\n<li><a href=\"https:\/\/holypython.com\/python-packaging-software-licenses-open-source-licensing-and-more\/\" target=\"_blank\" rel=\"noopener\">Open Source Software Licenses<\/a><\/li>\n<li><a href=\"https:\/\/holypython.com\/python-packaging-necessary-files-setup-py-requirements-txt-readme-md-__init__-py\/\" target=\"_blank\" rel=\"noopener\">Necessary Files<\/a><\/li>\n<li><a href=\"https:\/\/holypython.com\/python-packaging-local-installation-tests-before-uploading\/\" target=\"_blank\" rel=\"noopener\">Local Installation, Tests and __init__.py File<\/a><\/li>\n<li><a href=\"https:\/\/holypython.com\/python-packaging-uploading-a-python-library-to-pypi\/\" target=\"_blank\" rel=\"noopener\">Uploading to PyPI with Twine<\/a><\/li>\n<\/ol>\t\t\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/section>\n\t\t\t\t<\/div>\n\t\t","protected":false},"excerpt":{"rendered":"<p>Packaging is a very exciting process for the coder. Packaging allows you to share your work with the world and step into a structured, real developer position rather than dealing with bits and pieces of code here and there. And I don&#8217;t mean position in a corporate sense here, after all you know your position [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":15262,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[67,52],"tags":[],"class_list":["post-14832","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-packaging","category-tutorials"],"acf":[],"_links":{"self":[{"href":"https:\/\/holypython.com\/wp-json\/wp\/v2\/posts\/14832","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/holypython.com\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/holypython.com\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/holypython.com\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/holypython.com\/wp-json\/wp\/v2\/comments?post=14832"}],"version-history":[{"count":0,"href":"https:\/\/holypython.com\/wp-json\/wp\/v2\/posts\/14832\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/holypython.com\/wp-json\/wp\/v2\/media\/15262"}],"wp:attachment":[{"href":"https:\/\/holypython.com\/wp-json\/wp\/v2\/media?parent=14832"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/holypython.com\/wp-json\/wp\/v2\/categories?post=14832"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/holypython.com\/wp-json\/wp\/v2\/tags?post=14832"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}