There are many ways to contribute to Autoscoper, with varying levels of effort. Do try to look through the documentation first if something is unclear, and let us know how we can do better.
- Ask a question on the Autoscoper forum
- Use Autoscoper issues to submit a feature request or bug, or add to the discussion on an existing issue
- Submit a Pull Request to improve Autoscoper or its documentation
We encourage a range of Pull Requests, from patches that include passing tests and documentation, all the way down to half-baked ideas that launch discussions.
If you are new to Autoscoper development and you don't have push access to the Autoscoper repository, here are the steps:
- Fork and clone the repository.
- Create a branch.
- Push the branch to your GitHub fork.
- Create a Pull Request.
This corresponds to the Fork & Pull Model
described in the GitHub collaborative development
documentation.
When submitting a PR, the developers following the project will be notified. That
said, to engage specific developers, you can add Cc: @<username>
comment to notify
them of your awesome contributions.
Based on the comments posted by the reviewers, you may have to revisit your patches.
We encourage all developers to:
-
add or update tests.
-
consider potential backward compatibility breakage and discuss these on the Autoscoper forum.
Write your commit messages using the standard prefixes for Autoscoper commit messages:
BUG:
Fix for runtime crash or incorrect resultCOMP:
Compiler error or warning fixDOC:
Documentation changeENH:
New functionalityPERF:
Performance improvementSTYLE:
No logic impact (indentation, comments)WIP:
Work In Progress not ready for merge
The body of the message should clearly describe the motivation of the commit (what, why, and how). In order to ease the task of reviewing commits, the message body should follow the following guidelines:
- Leave a blank line between the subject and the body.
This helps
git log
andgit rebase
work nicely, and allows to smooth generation of release notes. - Try to keep the subject line below 72 characters, ideally 50.
- Capitalize the subject line.
- Do not end the subject line with a period.
- Use the imperative mood in the subject line (e.g.
BUG: Fix spacing not being considered.
). - Wrap the body at 80 characters.
- Use semantic line feeds to separate different ideas, which improves the readability.
- Be concise, but honor the change: if significant alternative solutions were available, explain why they were discarded.
- If the commit refers to a topic discussed on the Autoscoper forum, or fixes a regression test, provide the link. If it fixes a compiler error, provide a minimal verbatim message of the compiler error. If the commit closes an issue, use the GitHub issue closing keywords.
Keep in mind that the significant time is invested in reviewing commits and pull requests, so following these guidelines will greatly help the people doing reviews.
These guidelines are largely inspired by Chris Beam's How to Write a Commit Message post.
Examples:
- Bad:
BUG: Check pointer validity before dereferencing
-> implementation detail, self-explanatory (by looking at the code) - Good:
BUG: Fix crash in Module X when clicking Apply button
- Bad:
ENH: More work in CameraViewWidget
-> more work is too vague, CameraViewWidget is too low level - Good:
ENH: Add float image outputs in module X
- Bad:
COMP: Typo in cmake variable
-> implementation detail, self-explanatory - Good:
COMP: Fix compilation error with Numpy on Visual Studio
Getting your contributions integrated is relatively straightforward, here is the checklist:
-
All tests pass
-
Consensus is reached. This usually means that at least two reviewers approved the changes (or added a
LGTM
comment) and at least one business day passed without anyone objecting.LGTM
is an acronym for Looks Good to Me. -
To accommodate developers explicitly asking for more time to test the proposed changes, integration time can be delayed by few more days.
-
If you do NOT have push access, a Autoscoper core developer will integrate your PR. If you would like to speed up the integration, do not hesitate to send a note on the Autoscoper forum.
-
Given the topic of interest, initiate discussion on the Autoscoper forum.
-
Identify a small circle of community members that are interested to study the topic in more depth.
-
Take the discussion off the general list, work on the analysis of options and alternatives, summarize findings on the wiki or similar.
-
Announce on the Autoscoper forum the in-depth discussion of the topic for the Autoscoper bi-weekly meeting, encourage anyone that is interested in weighing in on the topic to join the discussion. If there is someone who is interested to participate in the discussion, but cannot join the meeting due to conflict, they should notify the leaders of the given project and identify the time suitable for everyone.
-
Hopefully, reach consensus at the hangout and proceed with the agreed plan.
The initial version of these guidelines is adapted from 3D Slicer guidelines