Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,7 @@ Codecov-cli supports user input. These inputs, along with their descriptions and
| `create-report-results` | Used for local upload. It tells codecov that you finished local uploading and want it to calculate the results for you to get them locally.
| `get-report-results` | Used for local upload. It asks codecov to provide you the report results you calculated with the previous command.
| `pr-base-picking` | Tells codecov that you want to explicitly define a base for your PR
| `upload-process` | A wrapper for 3 commands. Create-commit, create-report and do-upload. You can use this command to upload to codecov instead of using the previosly mentioned commands.
| `upload-process` | A wrapper for 3 commands. Create-commit, create-report and do-upload. You can use this command to upload to codecov instead of using the previously mentioned commands.
| `send-notifications` | A command that tells Codecov that you finished uploading and you want to be sent notifications. To disable automatically sent notifications please consider adding manual_trigger to your codecov.yml, so it will look like codecov: notify: manual_trigger: true.
>**Note**: Every command has its own different options that will be mentioned later in this doc. Codecov will try to load these options from your CI environment variables, if not, it will try to load them from git, if not found, you may need to add them manually.

Expand Down
2 changes: 1 addition & 1 deletion codecov_cli/commands/labelanalysis.py
Original file line number Diff line number Diff line change
Expand Up @@ -259,7 +259,7 @@ def _parse_runner_params(runner_params: List[str]) -> Dict[str, str]:
# a good reason for the param to include '=' in the value.
if param.count("=") == 0:
logger.warning(
f"Runner param {param} is not well formated. Setting value to None. Use '--runner-param key=value' to set value"
f"Runner param {param} is not well formatted. Setting value to None. Use '--runner-param key=value' to set value"
)
final_params[param] = None
else:
Expand Down
2 changes: 1 addition & 1 deletion codecov_cli/plugins/pycoverage.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ def project_root(self) -> typing.Optional[pathlib.Path]:
def report_type(self) -> str:
"""
Report type to generate.
Overrided if include_contexts == True
Overridden if include_contexts == True
report_type: str [values xml|json; default xml]
"""
return self.get("report_type", "xml")
Expand Down
2 changes: 1 addition & 1 deletion codecov_cli/runners/pytest_standard_runner.py
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ def _possibly_warn_bad_config(self, config_params: dict):
provided_config_params = config_params.keys()
for provided_param in provided_config_params:
if provided_param not in available_config_params:
logger.warning(f"Config parameter '{provided_param}' is unknonw.")
logger.warning(f"Config parameter '{provided_param}' is unknown.")

def parse_captured_output_error(self, exp: CalledProcessError) -> str:
result = ""
Expand Down
2 changes: 1 addition & 1 deletion codecov_cli/services/report/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,7 @@ def send_reports_result_get_request(
state = response_content.get("state").lower()
if state == "error":
logger.error(
"An error occured while processing the report. Please try again later.",
"An error occurred while processing the report. Please try again later.",
extra=dict(
extra_log_attributes=dict(
response_status_code=response_obj.status_code,
Expand Down
2 changes: 1 addition & 1 deletion codecov_cli/services/staticanalysis/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ async def run_analysis_entrypoint(
files = list(ff.find_files(folder, pattern, folders_to_exclude))
processing_results = await process_files(files, numberprocesses, config)
# Let users know if there were processing errors
# This is here and not in the funcition so we can add an option to ignore those (possibly)
# This is here and not in the function so we can add an option to ignore those (possibly)
# Also makes the function easier to test
processing_errors = processing_results["processing_errors"]
log_processing_errors(processing_errors)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ def visit(self, node: Node):
self.visit(c)

def _is_function_docstring(self, node: Node):
"""Skips docstrings for funtions, such as this one.
"""Skips docstrings for functions, such as this one.
Pytest doesn't include them in the report, so I don't think we should either,
at least for now.
"""
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ license = {file = "LICENSE"}
name = "codecov-cli"
readme = "README.md"
requires-python = ">= 3.9"
version = "10.3.0"
version = "10.4.0"

[project.scripts]
codecov = "codecov_cli.main:run"
Expand Down
2 changes: 1 addition & 1 deletion tests/helpers/test_folder_searcher.py
Original file line number Diff line number Diff line change
Expand Up @@ -256,7 +256,7 @@ def test_search_directories(tmp_path):
filename_include_regex = globs_to_regex(["*.app"])
filepaths = [
"banana.app/path/of/directory.txt",
"path/to/apple.app/path/of/directorys",
"path/to/apple.app/path/of/directories",
"path/to/banana.app/folder/test.txt",
"apple.py",
"banana.py",
Expand Down
20 changes: 10 additions & 10 deletions tests/runners/test_pytest_standard_runner.py
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ def test_warning_bad_config(self, mock_warning):
runner = PytestStandardRunner(params)
# Adding invalid config options emits a warning
mock_warning.assert_called_with(
"Config parameter 'some_missing_option' is unknonw."
"Config parameter 'some_missing_option' is unknown."
)
# Warnings don't change the config
assert runner.params == {**params, "some_missing_option": "option"}
Expand Down Expand Up @@ -91,7 +91,7 @@ def side_effect(command, *args, **kwargs):
cmd=command,
returncode=2,
output=b"Process running up to here...",
stderr=b"Some error occured",
stderr=b"Some error occurred",
)

mock_subprocess.run.side_effect = side_effect
Expand All @@ -100,7 +100,7 @@ def side_effect(command, *args, **kwargs):
_ = self.runner._execute_pytest(["--option", "--ignore=batata"])
assert (
str(exp.value)
== "Pytest exited with non-zero code 2.\nThis is likely not a problem with label-analysis. Check pytest's output and options.\nPYTEST OUTPUT:\nProcess running up to here...\nSome error occured"
== "Pytest exited with non-zero code 2.\nThis is likely not a problem with label-analysis. Check pytest's output and options.\nPYTEST OUTPUT:\nProcess running up to here...\nSome error occurred"
)

@patch("codecov_cli.runners.pytest_standard_runner.subprocess")
Expand All @@ -112,7 +112,7 @@ def side_effect(command, *args, **kwargs):
raise CalledProcessError(
cmd=command,
returncode=2,
stderr=b"Some error occured",
stderr=b"Some error occurred",
)

mock_subprocess.run.side_effect = side_effect
Expand All @@ -134,26 +134,26 @@ def side_effect(command, *args, **kwargs):
cmd=["python", "-m", "pytest", "missing_label"],
returncode=2,
output=b"Process running up to here...",
stderr=b"Some error occured",
stderr=b"Some error occurred",
),
"\nProcess running up to here...\nSome error occured",
"\nProcess running up to here...\nSome error occurred",
),
(
CalledProcessError(
cmd=["python", "-m", "pytest", "missing_label"],
returncode=2,
output="Process running up to here...",
stderr="Some error occured",
stderr="Some error occurred",
),
"\nProcess running up to here...\nSome error occured",
"\nProcess running up to here...\nSome error occurred",
),
(
CalledProcessError(
cmd=["python", "-m", "pytest", "missing_label"],
returncode=2,
stderr=b"Some error occured",
stderr=b"Some error occurred",
),
"\nSome error occured",
"\nSome error occurred",
),
],
)
Expand Down
2 changes: 1 addition & 1 deletion tests/services/report/test_report_results.py
Original file line number Diff line number Diff line change
Expand Up @@ -215,7 +215,7 @@ def test_get_report_results_200_error(mocker, capsys):
mocked_response.assert_called_once()
assert (
"error",
'An error occured while processing the report. Please try again later. --- {"response_status_code": 200, "state": "error", "result": {}}',
'An error occurred while processing the report. Please try again later. --- {"response_status_code": 200, "state": "error", "result": {}}',
) in output


Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -286,7 +286,7 @@ async def test_send_single_upload_put_fail_exception(self, mocker):

async def side_effect(presigned_put, data):
if presigned_put == "http://storage-url-003":
raise httpx.HTTPError("Some error occured in the request")
raise httpx.HTTPError("Some error occurred in the request")

mock_client.put.side_effect = side_effect

Expand Down