From b402e89b35323b6d3076636bc2e263bae6729a9c Mon Sep 17 00:00:00 2001 From: DSungatulin Date: Tue, 13 Feb 2024 11:32:23 +0600 Subject: [PATCH] edit workflows --- .github/workflows/pyci.yml | 2 +- gendiff/formatters/stylish.py | 6 +++--- setup.cfg | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/.github/workflows/pyci.yml b/.github/workflows/pyci.yml index 121a3d5..3a5d7c4 100644 --- a/.github/workflows/pyci.yml +++ b/.github/workflows/pyci.yml @@ -10,7 +10,7 @@ jobs: strategy: matrix: # we want to test our package on several versions of Python - python-version: [3.11, 3.12] + python-version: [3.10, 3.11, 3.12] steps: - uses: actions/checkout@v4 - name: Set up Python ${{ matrix.python-version }} diff --git a/gendiff/formatters/stylish.py b/gendiff/formatters/stylish.py index 33aade2..fec6b43 100644 --- a/gendiff/formatters/stylish.py +++ b/gendiff/formatters/stylish.py @@ -13,12 +13,12 @@ def walk(dict_, output, depth, indent): beginning = f'{(INDENT_CHAR * INDENT_NUMBER) * depth + key}: ' if isinstance(value, dict): output.append( - beginning + walk(value, [], depth + 1, indent + (INDENT_CHAR * INDENT_NUMBER)) # noqa: E501 + beginning + walk(value, [], depth + 1, indent + (INDENT_CHAR * INDENT_NUMBER)) ) else: output.append(beginning + get_data_format(value)) return ( - '{\n' + '\n'.join(output) + f'\n{indent + (INDENT_CHAR*INDENT_NUMBER)[0:-LEFTWARD_SHIFT]}' + '}' # noqa: E501 + '{\n' + '\n'.join(output) + f'\n{indent + (INDENT_CHAR*INDENT_NUMBER)[0:-LEFTWARD_SHIFT]}' + '}' ) if isinstance(value, dict): @@ -54,7 +54,7 @@ def walk(diff, output, depth): if nested: output.append(indent + special_char + key + ': {') walk(nested, output, depth + 1) - output.append(indent + (INDENT_CHAR * INDENT_NUMBER)[0:-LEFTWARD_SHIFT] + '}') # noqa: E501 + output.append(indent + (INDENT_CHAR * INDENT_NUMBER)[0:-LEFTWARD_SHIFT] + '}') else: action = entry['action'] old_value = entry['old value'] diff --git a/setup.cfg b/setup.cfg index 29d0216..bb0a839 100644 --- a/setup.cfg +++ b/setup.cfg @@ -10,7 +10,7 @@ exclude = .git,__pycache__,.venv,dist,build ignore = # line break occurred before a binary operator - W503 + W503, E501 per-file-ignores = # init modules can contain the local imports, logic, unused imports