This lesson is still being designed and assembled (Pre-Alpha version)

Packaging

When you are programming, usually you are solving a problem - the programming is simply a means to an end. If that’s the case, then packaging is a means to a means to an end. This often makes packaging the last thing you think about, but it’s actually one of the most important parts of any work, as it’s what makes code obtainable and reusable!

Packaging is absolutely critical as soon as you:

Unfortunately, packing has a lot of historical cruft, bad practices that have easy solutions today but are still propagated. This material tries to correct that by showing you a clean, modern way to write and work with Python packages.

Prerequisites

  • Basic Python
  • Light familiarity with pytest may be helpful

Schedule

Setup Download files required for the lesson
00:00 1. Environments and task runners How do you install and manage packages?
How can you ensure others run the same code you do?
00:20 2. Python to package How do we take code in a Jupyter Notebook or Python script and turn that into a package?
What are the minimum elements required for a Python package?
How do you set up tests?
00:45 3. Other files that belong with your package What other files are important parts of your software package?
What software license should you use for your project?
01:05 4. Metadata What metadata is important to add to your package?
How to I add common functionality, like executable scripts?
01:25 5. Versioning Key question (FIXME)
01:25 6. Documentation Key question (FIXME)
01:25 7. CI with GitHub Actions How do you ensure code keeps passing
01:45 8. Publishing package and citation How do I publish a package?
How do I make my work citable?
02:25 Finish

The actual schedule may vary slightly depending on the topics and exercises chosen by the instructor.