Skip to content

Commit d61bf7d

Browse files
Add Contributing Guide & Code of Conduct (#734)
* change dev guid to contributing guide, add coc & issue templates * Update CODE_OF_CONDUCT.md * add CLA paragraphs to contributing guide Co-authored-by: Tom Herold <[email protected]>
1 parent 880b4f2 commit d61bf7d

File tree

8 files changed

+203
-14
lines changed

8 files changed

+203
-14
lines changed
Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
---
2+
name: Bug report
3+
about: Create a report to help us improve
4+
title: ''
5+
labels: bug
6+
assignees: ''
7+
8+
---
9+
10+
## Context
11+
- Affected library: e.g. webknossos or wkcuber
12+
<!--- In what context did your bug occur? -->
13+
<!--- Providing context helps us come up with a solution that is most useful. -->
14+
15+
## Expected Behavior
16+
<!--- What should should happen instead of the bug / error message. -->
17+
18+
## Current Behavior
19+
<!--- What happens instead of the expected behavior? -->
20+
21+
## Steps to Reproduce the bug
22+
<!-- If the bug is hard to reproduce check the following: -->
23+
- [ ] Cannot reproduce the bug anymore / needs deeper investigation.
24+
<!--- If you can reproduce the bug, provide a list of actions to reproduce the bug. -->
25+
26+
1.
27+
2.
28+
3.
29+
4.
30+
31+
## Your Environment for bug
32+
<!--- In what environment did the bug occur? -->
33+
- Operating System and version: e.g. Windows 10
34+
- Version of webKnossos-libs (Release or Commit):
35+
(can be found e.g. with `pip show webknossos` or `wkcuber --version`)
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
---
2+
name: Feature suggestion
3+
about: Suggest an idea for this project
4+
title: ''
5+
labels: enhancement
6+
assignees: ''
7+
8+
---
9+
10+
## Detailed Description
11+
- Affected library: e.g. webknossos or wkcuber
12+
<!--- Provide a detailed description of the change or new feature you would like to have. -->
13+
14+
## Use Cases & Context
15+
<!--- Describe use cases where this feature is missing. -->
16+
<!--- Why is this change / new feature important ? -->

.github/PULL_REQUEST_TEMPLATE.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,3 +7,6 @@
77
### Todos:
88
Make sure to delete unnecessary points or to check all before merging:
99
- [ ] Updated Changelog
10+
- [ ] Updated Documentation
11+
- [ ] Added / Updated Tests
12+
- [ ] Considered adding this to the Examples

CODE_OF_CONDUCT.md

Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
# Code of Conduct
2+
3+
## Our Pledge
4+
5+
In the interest of fostering an open and welcoming environment, we as contributors and maintainers pledge to making participation in our project and our community a harassment-free experience for everyone, regardless of age, body size, disability, ethnicity, gender identity and expression, level of experience, nationality, personal appearance, race, religion, or sexual identity and orientation.
6+
7+
8+
## Our Standards
9+
10+
Examples of behavior that contributes to creating a positive environment include:
11+
12+
* Using welcoming and inclusive language
13+
* Being respectful of differing viewpoints and experiences
14+
* Gracefully accepting constructive criticism
15+
* Focusing on what is best for the community
16+
* Showing empathy towards other community members
17+
18+
Examples of unacceptable behavior by participants include:
19+
20+
* The use of sexualized language or imagery and unwelcome sexual attention or advances
21+
* Trolling, insulting/derogatory comments, and personal or political attacks
22+
* Public or private harassment
23+
* Publishing others' private information, such as a physical or electronic address, without explicit permission
24+
* Other conduct which could reasonably be considered inappropriate in a professional setting
25+
26+
27+
## Our Responsibilities
28+
29+
Project maintainers are responsible for clarifying the standards of acceptable behavior and are expected to take appropriate and fair corrective action in response to any instances of unacceptable behavior.
30+
31+
Project maintainers have the right and responsibility to remove, edit, or reject comments, commits, code, wiki edits, issues, and other contributions that are not aligned to this Code of Conduct, or to ban temporarily or permanently any contributor for other behaviors that they deem inappropriate, threatening, offensive, or harmful.
32+
33+
34+
## Scope
35+
36+
This Code of Conduct applies both within project spaces and in public spaces when an individual is representing the project or its community. Examples of representing a project or community include using an official project e-mail address, posting via an official social media account, or acting as an appointed representative at an online or offline event. Representation of a project may be further defined and clarified by project maintainers.
37+
38+
39+
## Enforcement
40+
41+
Instances of abusive, harassing, or otherwise unacceptable behavior may be reported by contacting the project team at [[email protected]](mailto:[email protected]). The project team will review and investigate all complaints, and will respond in a way that it deems appropriate to the circumstances. The project team is obligated to maintain confidentiality with regard to the reporter of an incident. Further details of specific enforcement policies may be posted separately.
42+
43+
Project maintainers who do not follow or enforce the Code of Conduct in good faith may face temporary or permanent repercussions as determined by other members of the project's leadership.
44+
45+
46+
## Attribution
47+
48+
This Code of Conduct is adapted from the [Contributor Covenant](http://contributor-covenant.org), version 1.4, available at [http://contributor-covenant.org/version/1/4](http://contributor-covenant.org/version/1/4/)

docs/src/webknossos-py/development.md renamed to CONTRIBUTING.md

Lines changed: 94 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,98 @@
1-
# Contributions & Development
1+
# Contributing Guide
22

3-
## How to contribute
3+
**Welcome to the webKnossos-libs contributing guide :sparkles: **
4+
5+
Thank you for taking the time to contribute to this project! The following is a set of guidelines for contributing to the different webKnossos related Python libraries, which are part of the [webKnossos-libs repository on GitHub](https://github.com/scalableminds/webknossos-libs). These are mostly guidelines, not rules. Use your best judgment, and feel free to propose changes to this document in a pull request.
6+
7+
## Code of Conduct
8+
9+
webKnossos-libs and everyone contributing and collaborating on this project is expected to follow the [webKnossos-libs Code of Conduct](CODE_OF_CONDUCT.md). Please report unacceptable behavior to [[email protected]](mailto:[email protected]).
10+
11+
12+
## How can I help?
413

514
We welcome community feedback and contributions! We are happy to have
615

7-
* general feedback and questions on the [image.sc forum](https://forum.image.sc/tag/webknossos),
8-
* feature requests and bug reports as [issues on GitHub](https://github.com/scalableminds/webknossos-libs/issues/new),
9-
* documentation, examples and code contributions as [pull requests on GitHub](https://github.com/scalableminds/webknossos-libs/compare).
16+
* [general feedback, observations and questions](#feedback-observations-and-questions) on the [image.sc forum](https://forum.image.sc/tag/webknossos),
17+
* [feature suggestions and bug reports](#issues-feature-suggestions-and-bug-reports) as [issues on GitHub](https://github.com/scalableminds/webknossos-libs/issues/new),
18+
* [documentation, examples and code contributions](#pull-requests-docs-and-code-contributions) as [pull requests on GitHub](https://github.com/scalableminds/webknossos-libs/compare).
19+
20+
21+
## Feedback, Observations and Questions
22+
23+
We'd love to hear your feedback on the webKnossos Python libraries!
24+
We're also interested in hearing if these tools don't work for your usecase,
25+
or if you have questions regarding their usage.
26+
27+
Please leave a message on the [image.sc forum](https://forum.image.sc/tag/webknossos)
28+
using the `webknossos` tag to enable public communication on those topics.
29+
If you prefer to share information only with the webKnossos team, please write an email
30+
to [[email protected]](mailto:[email protected]). For commercial support please
31+
reach out to [scalable minds](https://scalableminds.com).
32+
33+
34+
## Issues: Feature Suggestions and Bug Reports
35+
36+
We track feature requests and bug reports in the [webKnossos-libs repository issues](https://github.com/scalableminds/webknossos-libs/issues).
37+
Before opening a new issue, please do a quick search of existing issues to make sure your suggestion hasn’t already been added.
38+
If your issue doesn’t already exist, and you’re ready to create a new one, make sure to state what you would like to implement, improve or bugfix.
39+
Please use one of the provided templates to make this process easier for you.
40+
41+
You can submit an issue [here](https://github.com/scalableminds/webknossos-libs/issues/new)
42+
(read more about [issues here](https://docs.github.com/en/issues)).
43+
44+
45+
### Report a Bug :lady_beetle:
46+
47+
When you find a bug, please double-check if an issue for the same bug exists already.
48+
If that's not the case, please verify in the [documentation](https://docs.webknossos.org/api/webknossos.html)
49+
that you use the API as intended. If that's the case, please
50+
[add an issue using the bug report template](https://github.com/scalableminds/webknossos/issues/new?template=bug_report.md).
51+
52+
53+
### Suggest a New Feature
54+
55+
If you are missing a feature to support your use-case, please consider the following points:
56+
57+
1. Please verify if this feature is directly related to webKnossos.
58+
Does it belong into the webKnossos Python libraries?
59+
2. Double-check if an issue for this feature exists already. If there is one with a very similar scope,
60+
please considering commenting there.
61+
3. If possible, consider how the implementation might look like (e.g. how would the public API change),
62+
as well as how this could be tested and presented in the examples.
63+
64+
Then, please [add an issue using the feature suggestion template](https://github.com/scalableminds/webknossos/issues/new?template=feature_suggestion.md).
65+
66+
67+
## Pull Requests: Docs and Code Contributions
68+
69+
This project welcomes contributions and suggestions. Most contributions require you to
70+
agree to a Contributor License Agreement (CLA) declaring that you have the right to,
71+
and actually do, grant us the rights to use your contribution. For details, visit
72+
https://cla-assistant.io/scalableminds/webknossos-libs.
73+
74+
When you submit a pull request, a CLA-bot will automatically determine whether you need
75+
to provide a CLA and decorate the PR appropriately (e.g., label, comment). Simply follow the
76+
instructions provided by the bot. You will only need to do this once using our CLA.
77+
78+
If you want to fix a minor problem in the documentation, examples or other code, feel free to
79+
[open a pull requests for it on GitHub](https://github.com/scalableminds/webknossos-libs/compare)
80+
(read more about [pull requests here](https://docs.github.com/en/pull-requests).
81+
82+
For larger features and changes, we prefer that you open a new issue before creating a pull request.
83+
Please include the following in your pull request:
84+
85+
* The pull request description should explain what you've done.
86+
* Add tests for the new features.
87+
* Comply with the coding styles.
88+
* Adapt or add the documentation.
89+
* Consider enhancing the examples.
90+
91+
The specific coding styles, test frameworks and documentation setup of webKnossos-libs are described
92+
in the following sections:
1093

1194

12-
## Development
95+
### Development
1396

1497
The [webknossos-libs repository](https://github.com/scalableminds/webknossos-libs) is structured as a mono-repo, containing multiple packages:
1598

@@ -30,7 +113,7 @@ See below for specifics of the different packages. Let's have a look at the comm
30113
[`pip install -f requirements.txt`](https://github.com/scalableminds/webknossos-libs/blob/master/requirements.txt)
31114

32115
To install the dependencies for all sub-projects, run `make install`.
33-
* **Tooling** we use across the sub-projects:
116+
* **Tooling** we use across the sub-projects to enforce coding styles and tests:
34117
* `format.sh`: black and isort
35118
* `lint.sh`: pylint
36119
* `typecheck.sh`: mypy
@@ -49,7 +132,7 @@ Internal workflows for scalable minds:
49132
This updates the changelog and pushes a new tag, which triggers another CI run building and publishing the package.
50133

51134

52-
### `webknossos` package
135+
#### `webknossos` package
53136

54137
The `webknossos` folder contains examples, which are not part of the package, but are tested via `tests/test_examples.py` and added to the documentation (see `docs/src/webknossos-py/examples`).
55138

@@ -69,7 +152,7 @@ To re-generate the code, run
69152
```
70153

71154

72-
### `wkcuber` package
155+
#### `wkcuber` package
73156

74157
Currently the test setup consists of different scripts as well as pytest tests. The following commands are run in CI:
75158
```bash
@@ -81,14 +164,14 @@ poetry run tests/scripts/all_tests.sh
81164
There is also a `test.sh` which is currently outdated, see [issue #580](https://github.com/scalableminds/webknossos-libs/issues/580).
82165

83166

84-
### `cluster_tools` package
167+
#### `cluster_tools` package
85168

86169
For testing the `slurm` setup a docker-compose setup is available. Please see the [respective Readme](https://github.com/scalableminds/webknossos-libs/blob/master/cluster_tools/README.md) for details.
87170

88171
For testing the `kubernetes` setup, we recommend a [Kubernetes-in-Docker setup](https://kind.sigs.k8s.io/).
89172

90173

91-
## Documentation
174+
### Documentation
92175

93176
We render a common documentation for webKnossos itself and webknossos-libs from this repository using [mkdocs](https://www.mkdocs.org/). Source-files for the documentation are stored at `docs/src`:
94177

docs/mkdocs.yml

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -105,11 +105,13 @@ nav:
105105
- User: api/webknossos/administration/user.md
106106
- Project: api/webknossos/administration/project.md
107107
- Task: api/webknossos/administration/task.md
108-
- Other:
109-
- webknossos-py/changelog.md
108+
- Version Changelog:
110109
- webknossos-py/stability_policy.md
110+
- webknossos-py/changelog.md
111+
- Community:
112+
- webknossos-py/CONTRIBUTING.md
113+
- webknossos-py/CODE_OF_CONDUCT.md
111114
- Getting Help:
112-
- webknossos-py/development.md
113115
- Community Support: https://forum.image.sc/tag/webknossos" target="_blank
114116
- Email Support: mailto:[email protected]
115117
- Commercial Support: https://scalableminds.com" target="_blank
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
../../../CODE_OF_CONDUCT.md
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
../../../CONTRIBUTING.md

0 commit comments

Comments
 (0)