Commit 0f3ecb7e authored by Łukasz Langa's avatar Łukasz Langa
Browse files

18.4a4 hotfix: don't populate the cache on --check

Fixes #175
parent 25abcea6
Loading
Loading
Loading
Loading
+5 −0
Changes for README.md: 5 added lines, 0 removed lines.
Original line number Diff line number Diff line
@@ -522,6 +522,11 @@ More details can be found in [CONTRIBUTING](CONTRIBUTING.md).

## Change Log

### 18.4a4

* don't populate the cache on `--check` (#175)


### 18.4a3

* added a "cache"; files already reformatted that haven't changed on disk
+3 −3
Changes for black.py: 3 added lines, 3 removed lines.
Original line number Diff line number Diff line
@@ -43,7 +43,7 @@
from blib2to3.pgen2 import driver, token
from blib2to3.pgen2.parse import ParseError

__version__ = "18.4a3"
__version__ = "18.4a4"
DEFAULT_LINE_LENGTH = 88

# types
@@ -245,7 +245,7 @@ def reformat_one(
                )
            ):
                changed = Changed.YES
            if write_back != WriteBack.DIFF and changed is not Changed.NO:
            if write_back == WriteBack.YES and changed is not Changed.NO:
                write_cache(cache, [src], line_length)
        report.done(src, changed)
    except Exception as exc:
@@ -312,7 +312,7 @@ async def schedule_formatting(

    if cancelled:
        await asyncio.gather(*cancelled, loop=loop, return_exceptions=True)
    if write_back != WriteBack.DIFF and formatted:
    if write_back == WriteBack.YES and formatted:
        write_cache(cache, formatted, line_length)