Skip to content

Latest commit

 

History

History
68 lines (54 loc) · 2.53 KB

CONTRIBUTING.rst

File metadata and controls

68 lines (54 loc) · 2.53 KB

Contributor's guide

Coding style

  • Follow PEP 8. flake8 would help.
  • Order imports by lexicographical order.
  • Prefer relative imports.
  • All functions, classes, methods, attributes, and modules should have the docstring.
  • Functions and methods should contain :param:, :type: (:return:, :rtype if it returns something), (:raise: if it may raise an error) in their docstring.

Tests

  • All code patches should contain one or more unit tests or regression tests.
  • All code patches have to successfully run tests on every Python version we aim to support. tox would help.
  • All commits will be tested by GitHub Actions (Linux and Windows).

Maintainer's guide

Releasing

Here's a brief check list for releasing a new version:

  • Double check if the version is correctly bumped. You can bump the version by changing __version__ in sass.py file. Note that it might be already bumped by other maintainers, so check what's the latest release version from PyPI.
  • The changelog has to be complete, and frozen. "To be released" sentence has to be replaced by the actual release date.
  • If the code freeze for the release is done (including version bump), tag the commit using git tag command. The tag name has to simply be the version name e.g. 1.2.3. Of course, the tag also has to be pushed to the upstream repository.
  • Make a source distribution and upload it to PyPI (python3 setup.py sdist upload). If it's successful the new version must appear on PyPI.
  • GitHub Actions automatically makes binary wheels for Windows, but each CI build takes a while. These wheels are not automatically uploaded, you can retreive them from the build's artifacts.
  • Run ./bin/build-manylinux-wheels to build linux wheels and upload them to PyPI (takes ~5 minutes).
  • The docs website also has to be updated. It's currently a static website deployed on GitHub Pages. Use python setup.py upload_doc command. Although it seems possible to be automated using Github Actions.
  • Manually create a release through https://github.com/sass/libsass-python/releases/

Ping Hong Minhee (hongminhee@member.fsf.org, @dahlia on GitHub) if you need any help!