@@ -3,7 +3,9 @@ We want to make contributing to this project as easy and transparent as
...
@@ -3,7 +3,9 @@ We want to make contributing to this project as easy and transparent as
possible.
possible.
## Our Development Process
## Our Development Process
Minor changes and improvements will be released on an ongoing basis. Larger changes (e.g., changesets implementing a new paper) will be released on a more periodic basis.
Minor changes and improvements will be released on an ongoing basis. Larger
changes (e.g., changesets implementing a new paper) will be released on a
more periodic basis.
## Pull Requests
## Pull Requests
We actively welcome your pull requests.
We actively welcome your pull requests.
...
@@ -29,19 +31,61 @@ Facebook has a [bounty program](https://www.facebook.com/whitehat/) for the safe
...
@@ -29,19 +31,61 @@ Facebook has a [bounty program](https://www.facebook.com/whitehat/) for the safe
disclosure of security bugs. In those cases, please go through the process
disclosure of security bugs. In those cases, please go through the process
outlined on that page and do not file a public issue.
outlined on that page and do not file a public issue.
* In your editor, install the [editorconfig](https://editorconfig.org/) extension which should ensure that you are following the same standards as us.
* In your editor, install the [editorconfig](https://editorconfig.org/) extension
which should ensure that you are following the same standards as us.
* Ideally, run black and isort before opening up your PR.
* Ideally, run black and isort before opening up your PR.
```
```
black ./(mmf|tests|tools)/**/*.py
black .
isort -rc (mmf|tests|tools)
isort
flake8
```
```
* Read the [editorconfig](.editorconfig) file to understand the exact coding style preferences.
* Read the [editorconfig](.editorconfig) file to understand the exact coding style preferences.
## Testing
### Static analysis
```
mypy .
```
### Unit tests
```
pytest
```
### CircleCI status
From your PR page, you can expand on the CircleCI results. For GPU test, you should see
what CI has run, like:
```
...
----- generated xml file: /home/circleci/fairscale/test-results/junit.xml ------
================== 217 passed, 2 xfailed in 218.74s (0:03:38) ==================
CircleCI received exit code 0
```
The number of passed and failed should give you an idea on whether your local
test was the same or not.
## Commit Guidelines
## Commit Guidelines
We follow the same guidelines as AngularJS. Each commit message consists of a **header**, a **body** and a **footer**. The header has a special format that includes a **type**, and a **subject**:
We follow the same guidelines as AngularJS. Each commit message consists of a **header**,
a **body** and a **footer**. The header has a special format that includes a **type**,