summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
...
| * | | application: Make 'parse_configuration_and_cli' parameter requiredEric N. Vander Weele2019-11-031-2/+2
| | | | | | | | | | | | | | | | | | | | The remaining CLI arguments is now always provided as an argument this method.
* | | | Merge branch 'application-parse-prelim-opts' into 'master'Anthony Sottile2019-11-034-22/+11
|\ \ \ \ | | | | | | | | | | | | | | | | | | | | application: Rename prelim parsing method to 'parse_preliminary_options' See merge request pycqa/flake8!374
| * | | | application: Rename prelim parsing method to 'parse_preliminary_options'Eric N. Vander Weele2019-11-034-22/+11
| |/ / / | | | | | | | | | | | | | | | | | | | | Positional arguments are not used nor parsed for pre-configuration loading. Thus, renaming the method and updating the docstrings appropriately.
* | | | Merge branch 'application-make-config' into 'master'Anthony Sottile2019-11-031-8/+8
|\ \ \ \ | |/ / / |/| | | | | | | | | | | application: Simplify creation of configuration file finder See merge request pycqa/flake8!373
| * | | application: Simplify creation of configuration file finderEric N. Vander Weele2019-11-031-8/+8
|/ / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This commit simplifies and updates the method for handling the creation of the configuration file finder. The main takeaways are: - Renaming the parameter (i.e., `extra_config_files`) to be a noun to better describe the input versus what the option name was called. - Refreshed the docstring to align with changes from previous commits and this one. - Remove the check to see if it a configuration file finder was already created. This is not necessary as each entire run of a `flake8` calls this method once. When the programmatic API is provided, configuration would be provided 'in-code' and not rely upon external files/resources. - Use directly the program name from the `Application`, itself since this is the authoritative source for defining it.
* | | Merge branch 'black-19.10b0-reformat' into 'master'Anthony Sottile2019-11-021-3/+4
|\ \ \ | | | | | | | | | | | | | | | | Reformat with black >= 19.10b0 See merge request pycqa/flake8!372
| * | | Reformat with black >= 19.10b0Eric N. Vander Weele2019-11-011-3/+4
|/ / / | | | | | | | | | | | | This resets the `black` formatting baseline so it doesn't get picked up in future commits.
* | | Merge branch 'separate-prelim-options' into 'master'Anthony Sottile2019-10-317-81/+118
|\ \ \ | | | | | | | | | | | | | | | | Separate pre-configuration CLI parsing See merge request pycqa/flake8!364
| * | | application: Forward remaining unknown arguments to final CLI parsingEric N. Vander Weele2019-10-252-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Now that `parse_preliminary_options_and_args()` ignores unknown options and arguments, forward the remaining unknown arguments to the main CLI and configuration method to be consumed. This prevents re-parsing the entire `argv` list again by forwarding the remaining arguments left to be consumed.
| * | | application: Ensure `--version` is unknown during preliminary parsingEric N. Vander Weele2019-10-252-17/+3
| | | | | | | | | | | | | | | | | | | | Now that the preliminary parser is being used, we can remove needing to prune out `--version` and copying the original `argv` list.
| * | | application: Ensure `-h/--help` is unknown during preliminary parsingEric N. Vander Weele2019-10-252-8/+14
| | | | | | | | | | | | | | | | | | | | Now that the preliminary parser is being used, we can remove needing to prune out `-h` and `--help` from the copied `args` list.
| * | | application: Keep unknown options in the unknown argument listEric N. Vander Weele2019-10-252-7/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Positional arguments aren't necessary for determining where to load configuration anymore and is safe to keep both options and arguments to be forwarded for later parsing after configuration is loaded.
| * | | application: Change to `argparse.ArgumentParser` for preliminary parsingEric N. Vander Weele2019-10-252-3/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Now that preliminary options are registered with the preliminary parser on the `Application`, leverage that for parsing known options. This important change removes the `Application.option_manager` from being responsible for pre-configuration parsing and the workarounds needed in the `Application.parse_preliminary_options_and_args()` to account for the fact that `Application.option_manager` was aware of *all* options, not just the options necessary for pre-configuration loading. A following commit will address removing these workarounds.
| * | | application: Register preliminary options on a separate argument parserEric N. Vander Weele2019-10-253-10/+20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We introduce a new `ArgumentParser` for registering the preliminary options to be inherited by the `Application.option_manager`. The next step will be to use the `Application.prelim_arg_parser` for parsing and handling preliminary options and arguments. Note that we prevent the preliminary parser from handling `-h/--help` and defer to that to the primary parser.
| * | | optmanager: Inherit options from parent argument parsersEric N. Vander Weele2019-10-252-3/+30
| | | | | | | | | | | | | | | | | | | | | | | | Allow for including options from parent `argparse.ArgumentParser` objects in preparation of splitting out the handling of preliminary options from the `OptionManager`.
| * | | options: Split-out registration of preliminary optionsEric N. Vander Weele2019-10-253-44/+56
| | | | | | | | | | | | | | | | | | | | This is in preparation for having separate `ArgumentParser`s for preliminary and the remaining options.
* | | | Merge branch '3.7-maintenance' into 'master'Anthony Sottile2019-10-283-1/+25
|\ \ \ \ | | | | | | | | | | | | | | | | | | | | Merge 3.7.9 tag and release notes See merge request pycqa/flake8!369
| * | | | Release 3.7.93.7.93.7-maintenanceAnthony Sottile2019-10-283-1/+25
| | | | |
| * | | | Merge branch 'backport_pr_340' into '3.7-maintenance'Anthony Sottile2019-10-281-11/+10
| |\ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | [3.7] Fix travis-ci See merge request pycqa/flake8!368
| | * | | | Fix travis-ciAnthony Sottile2019-10-281-11/+10
| | | | | |
| * | | | | Merge branch 'backport_pr_366' into '3.7-maintenance'Anthony Sottile2019-10-284-45/+15
| |\ \ \ \ \ | | |/ / / / | |/| | | | | | | | | | | | | | | | [3.7] Only use multiprocessing when the method is fork See merge request pycqa/flake8!367
| | * | | | Only use multiprocessing when the method is forkAnthony Sottile2019-10-284-45/+15
| |/ / / / | | | | | | | | | | | | | | | | | | | | In python3.8 on macos and in all versions on windows the multiprocessing method is `spawn` which does not preserve class state.
* | | | | Merge branch 'specific_noqa_pycodestyle' into 'master'Anthony Sottile2019-10-282-5/+15
|\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Do not pass `noqa` to plugins, have flake8 decide whether to report Closes #552 See merge request pycqa/flake8!331
| * | | | | Do not pass `noqa` to plugins, have flake8 decide whether to reportAnthony Sottile2019-08-292-5/+15
| | | | | |
* | | | | | Merge branch 'only_fork' into 'master'Anthony Sottile2019-10-284-45/+15
|\ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Only use multiprocessing when the method is fork Closes #587 See merge request pycqa/flake8!366
| * | | | | | Only use multiprocessing when the method is forkAnthony Sottile2019-10-284-45/+15
|/ / / / / / | | | | | | | | | | | | | | | | | | | | | | | | In python3.8 on macos and in all versions on windows the multiprocessing method is `spawn` which does not preserve class state.
* | | | | | Merge branch 'flake8-bugbear' into 'master'Anthony Sottile2019-10-253-3/+7
|\ \ \ \ \ \ | |_|_|/ / / |/| | | | | | | | | | | | | | | | | linters: Add flake8-bugbear for finding bugs and design problems See merge request pycqa/flake8!365
| * | | | | linters: Add flake8-bugbear for finding bugs and design problemsEric N. Vander Weele2019-10-253-3/+7
|/ / / / / | | | | | | | | | | | | | | | | | | | | Also, make appropriate changes to satisfy issues flagged by `flake8-bugbear`.
* | | | | Merge branch 'config-search-relative-to-cwd' into 'master'Anthony Sottile2019-10-238-66/+37
|\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | Simplify configuration file search to be relative to cwd See merge request pycqa/flake8!363
| * | | | | application: Remove forwarding unused preliminary argumentsEric N. Vander Weele2019-10-133-7/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The `ConfigFileFinder` doesn't utilize the preliminary arguments (i.e., the file names) anymore for computing the starting path for the configuration file search.
| * | | | | tests: Verify `ConfigFileFinder` behavior based on `getcwd()`Eric N. Vander Weele2019-10-131-41/+18
| | | | | | | | | | | | | | | | | | | | | | | | Update the tests now that `ConfigFileFinder` searches relative to the current working directory.
| * | | | | config: Remove `args` parameter from `ConfigFileFinder.__init__`Eric N. Vander Weele2019-10-136-17/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Now that `args` parameters is not being used, it is safe to remove from the constructor signature. Further work is required to evaluate and clean-up tearing out the threading-through of `args` from various callers and tests.
| * | | | | config: Search for configuration relative to current working directoryEric N. Vander Weele2019-10-131-3/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is the initial incision to only search for configuration relative to the current working directory where `flake8` is invoked. This brings configuration file detection closer to other CLI-like programs.
* | | | | | Merge branch 'black-format' into 'master'Anthony Sottile2019-10-131-3/+1
|\ \ \ \ \ \ | |/ / / / / | | | | | | | | | | | | | | | | | | Reformat files via `black` See merge request pycqa/flake8!362
| * | | | | Reformat files via `black`Eric N. Vander Weele2019-10-131-3/+1
|/ / / / / | | | | | | | | | | | | | | | This was missed in bb12b83.
* | | | | Merge branch 'remove-output-file-config' into 'master'Anthony Sottile2019-10-131-1/+0
|\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | options: Remove parsing `--output-file` from the configuration file See merge request pycqa/flake8!361
| * | | | | options: Remove parsing `--output-file` from the configuration fileEric N. Vander Weele2019-10-121-1/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The `--output-file` option is used when parsing and handling preliminary options for logging. It is also used to set `BaseFormatter.filename`. Towards ensuring that the option is respected consistently for both logging and formatting plugins, only observe the value from the CLI.
* | | | | | Merge branch 'remove-verbose-config' into 'master'Anthony Sottile2019-10-134-18/+1
|\ \ \ \ \ \ | |/ / / / / |/| | | | | | | | | | | | | | | | | options: Remove parsing `--verbose` from the configuration file See merge request pycqa/flake8!360
| * | | | | options: Remove parsing `--verbose` from the configuration fileEric N. Vander Weele2019-10-124-18/+1
|/ / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The `--verbose` option is only used by `flake8`, itself,` when parsing and handling preliminary options. After parsing and merging options from the configuration file, there is no other behavioral impact to the core of `flake8`. In other words, setting `verbose = ...` in a configuration file doesn't change the logging verbosity. While the `FileProcessor` does expose a `verbose` attribute, obtained from the parsed options, the verbosity of the core of `flake8` should be consistent with how a plugin may respond to the attribute's value.
* | | | | Merge branch 'remove-application-prelim-option-state' into 'master'Anthony Sottile2019-10-014-41/+59
|\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | Remove application prelimary option state See merge request pycqa/flake8!358
| * | | | | application: Remove preliminary argument parsing stateEric N. Vander Weele2019-10-013-17/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The preliminary options and arguments returned from `.parse_preliminary_options_and_args()` are now all threaded through to the appropriate methods during initialization.
| * | | | | application: Pass prelim opts to `.find_plugins()`Eric N. Vander Weele2019-10-013-8/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The configuration file and boolean to ignore configuration files can be threaded through now that `.parse_preliminary_options_and_args()` returns options and arguments.
| * | | | | application: Pass prelim opts and args to `.make_config_finder()`Eric N. Vander Weele2019-10-013-9/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Now that `.parse_preliminary_options_and_args()` returns options and arguments, the boolean for appending configuration and the arguments can be threaded through to the creation of the `ConfigFileFinder`.
| * | | | | application: Pass returned prelim options to `.configure_logging()`Eric N. Vander Weele2019-10-013-8/+17
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The verbosity and output file options can be obtained from options returned by `.parse_preliminary_options_and_args()`, instead of state from the `Application` object.
| * | | | | application: Return namespace and args from preliminary arg parsingEric N. Vander Weele2019-10-012-4/+13
|/ / / / / | | | | | | | | | | | | | | | | | | | | | | | | | This is the initial step towards removing state from the `Application` object during argument parsing and handling. The goal is to remove `Application.prelim_opts` and `Application.prelim_args`.
* | | | | Merge branch 'remove_E101_indent_char_resetting' into 'master'Ian Stapleton Cordasco2019-09-254-28/+20
|\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | Don't reset indent_char when we encounter E101 See merge request pycqa/flake8!357
| * | | | | Don't reset indent_char when we encounter E101Anthony Sottile2019-09-244-28/+20
|/ / / / /
* | | | | Merge branch 'whitespace_fixers' into 'master'Anthony Sottile2019-09-084-3/+7
|\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | Add whitespace fixers See merge request pycqa/flake8!355
| * | | | | Add whitespace fixersAnthony Sottile2019-09-074-3/+7
|/ / / / /
* | | | | Merge branch 'type_more' into 'master'Anthony Sottile2019-09-084-46/+83
|\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | Add more type annotations See merge request pycqa/flake8!353