Conditions | 4 |
Total Lines | 32 |
Lines | 0 |
Ratio | 0 % |
Tests | 4 |
CRAP Score | 4 |
Changes | 3 | ||
Bugs | 0 | Features | 0 |
1 | 3 | ||
9 | 3 | def stage(draft): |
|
10 | 3 | repository, bumpversion_part, release_type, proposed_version = status() |
|
11 | |||
12 | if not repository.changes_since_last_version: |
||
13 | 3 | error("There aren't any changes to release!") |
|
14 | return |
||
15 | 3 | ||
16 | info('Staging [{}] release for version {}'.format( |
||
17 | release_type, |
||
18 | proposed_version |
||
19 | )) |
||
20 | |||
21 | bumpversion_arguments = ( |
||
22 | BumpVersion.DRAFT_OPTIONS if draft |
||
23 | else BumpVersion.STAGE_OPTIONS |
||
24 | ) |
||
25 | bumpversion_arguments += [bumpversion_part] |
||
26 | |||
27 | info('Running: bumpversion {}'.format( |
||
28 | ' '.join(bumpversion_arguments) |
||
29 | )) |
||
30 | |||
31 | try: |
||
32 | bumpversion.main(bumpversion_arguments) |
||
33 | except bumpversion.WorkingDirectoryIsDirtyException as err: |
||
34 | error(err) |
||
35 | raise |
||
36 | staged_files = [ |
||
37 | |||
38 | ] |
||
39 | staged_release = None |
||
40 | return staged_release |
||
41 |
This can be caused by one of the following:
1. Missing Dependencies
This error could indicate a configuration issue of Pylint. Make sure that your libraries are available by adding the necessary commands.
2. Missing __init__.py files
This error could also result from missing
__init__.py
files in your module folders. Make sure that you place one file in each sub-folder.