Skip to content

Latest commit

 

History

History
28 lines (19 loc) · 1.35 KB

CONTRIBUTING.md

File metadata and controls

28 lines (19 loc) · 1.35 KB

Contributing to PyangBind

Contributions to PyangBind are very welcome, either directly via pull requests, or as feature suggestions or bug reports.

Code Style

To avoid unnecessary discussions about coding style we are currently enforcing it with black. Before pushing code:

  • make sure you are running the correct version of black as per requirements.DEVELOPER.txt.
  • reformat your code with black passing the option --line-length 119.

Testing

  • New code should be covered by tests, and run under both Python 2 and 3.
  • To ease the testing of generated bindings, there is the tests.base.PyangBindTestCase class which you may subclass in order to automate the process. A simple example of its usage can be seen in tests/strings/run.py.
  • Tests can be run via the tox command, or python3 -m pytest -q tests.

Other Issues

  • If you have an issue with generated code/odd errors during build -- please do just e-mail this over or open an issue. If you can't share the YANG itself, then anonymised YANG is very welcome.
  • If you'd like to discuss the best design for a feature, or don't get how a feature fits in, please open an issue, send an e-mail, or join us in the #pyangbind channel on the NetworkToCode Slack.

And most of all, thanks for contributions :-)