Skip to content

GitLab

  • Projects
  • Groups
  • Snippets
  • Help
    • Loading...
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
silkaj
silkaj
  • Project overview
    • Project overview
    • Details
    • Activity
    • Releases
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 162
    • Issues 162
    • List
    • Boards
    • Labels
    • Service Desk
    • Milestones
  • Merge Requests 3
    • Merge Requests 3
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Packages & Registries
    • Packages & Registries
    • Package Registry
    • Container Registry
  • Analytics
    • Analytics
    • CI/CD
    • Repository
    • Value Stream
  • Snippets
    • Snippets
  • Members
    • Members
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • clients
  • python
  • silkajsilkaj
  • Issues
  • #182

Closed
Open
Created Jan 26, 2019 by Moul@moulOwner5 of 7 tasks completed5/7 tasks

Migrate from Pipenv/setup.{py,cfg} to Poetry/pyproject.toml

Problems with Pipenv and setup.{py,cfg}

  • Pipenv dependency update is updating all packages. There is an option to update just one, but last time I tried it it was broken.
  • When updating a dependency, two files needs to me changed: one for the dev env Pipenv.{lock} and the other for the PyPi distribution setup.{py,cfg}. In other words, there is no central file to handle dependencies.
  • Dependencies update is very CPU consuming

Advantages of Poetry and pyproject.toml

  • Poetry can update one dependency at the time.
  • Poetry uses a central file for the dev env and the PyPi distribution.
  • Poetry can build and publish to PyPi out of the box. wheel and twine are hidden under the hood. Nice for CI/CD and new contributors.
  • Poetry installs dev dependencies by defaults
  • pyproject.toml is the standard file format defined by the Python project.
  • Easier installation of DuniterPy as a local dependency

Poetry

  • https://github.com/python-poetry/poetry
  • https://python-poetry.org/
  • Conference explaining different dependencies manager and Python env (dev env)

Plan

  • Add documentation for Poetry installation and usage, update README.md link
  • Add pyproject.toml and poetry.lock files
  • Get rid of Pipenv doc, update README.md link
  • Get rid of Pipenv{.lock} and setup.py files
  • Update release.sh
  • Update documentations: release, tests

Black, Python 3.5 support

  • Black dependency needs Python 3.6 as a minimal version for the development environment. We want to keep Python 3.5 support. We want Black not to be pre-install Black in Poetry for now. It’s a pain in the ass, as a Black should be installed separately.

The classifiers are updated (erased) by python dependency. Try to upload to PyPi test and install it in Python 3.5 environment. Not possible to install it Silkaj without Python 3.5 support on a Python 3.5 installation.

  • Solution: the black line is commented, and can be uncommented to install black on Python version ≥ 3.6 environement.
  • Open ticket to add Black as a dependency when dropping Python 3.5.

Other

  • #217 (closed): Migration to setup.cfg
  • Dependency manager discussion for DuniterPy
Edited Jun 14, 2020 by Moul
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information
Assignee
Assign to
0.8.0
Milestone
0.8.0 (Past due)
Assign milestone
Time tracking
None
Due date
None