File size: 2,389 Bytes
065fee7
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
Contributing Code
-----------------
A good pull request:

-  Is clear.
-  Works across all supported versions of Python.
-  Follows the existing style of the code base (see Codestyle section).
-  Has comments included as needed.

-  A test case that demonstrates the previous flaw that now passes with
   the included patch, or demonstrates the newly added feature.
-  If it adds/changes a public API, it must also include documentation
   for those changes.
-  Must be appropriately licensed (Apache 2.0).

Reporting An Issue/Feature
--------------------------
First, check to see if there's an existing
`issue <https://github.com/boto/botocore/issues>`__/`pull requests <https://github.com/boto/botocore/pulls>`__ for the bug/feature.

If there isn't an existing issue there, please file an issue *first*. The
ideal report includes:

-  A description of the problem/suggestion.
-  How to recreate the bug.
-  If relevant, including the versions of your:

   -  Python interpreter
   -  s3transfer
   -  Optionally of the other dependencies involved (e.g. Botocore)

-  If possible, create a pull request with a (failing) test case
   demonstrating what's wrong. This makes the process for fixing bugs
   quicker & gets issues resolved sooner.

Codestyle
---------
This project uses flake8 to enforce codstyle requirements. We've codified this
process using a tool called `pre-commit <https://pre-commit.com/>`__. pre-commit
allows us to specify a config file with all tools required for code linting,
and surfaces either a git commit hook, or single command, for enforcing these.

To validate your PR prior to publishing, you can use the following
`installation guide <https://pre-commit.com/#install>`__ to setup pre-commit.

If you don't want to use the git commit hook, you can run the below command
to automatically perform the codestyle validation:

.. code-block:: bash

    $ pre-commit run

This will automatically perform simple updates (such as white space clean up)
and provide a list of any failing flake8 checks. After these are addressed,
you can commit the changes prior to publishing the PR.
These checks are also included in our CI setup under the "Lint" workflow which will provide output on Github for anything missed locally.

See the `flake8` section of the
`setup.cfg <https://github.com/boto/s3transfer/blob/develop/setup.cfg>`__ for the
currently enforced rules.