Skip to content
This repository was archived by the owner on Jun 24, 2026. It is now read-only.

Show black diff on travis builds#1565

Merged
reaperhulk merged 1 commit into
masterfrom
travis-diff-black
Nov 24, 2019
Merged

Show black diff on travis builds#1565
reaperhulk merged 1 commit into
masterfrom
travis-diff-black

Conversation

@disconnect3d

Copy link
Copy Markdown
Member

TLDR: This is not helpful when looking at lint build output:

$ black --check manticore/core/smtlib/solver.py
would reformat manticore/core/smtlib/solver.py
Oh no! 💥 💔 💥
1 file would be reformatted.

And this is more helpful:

$ black --diff --check manticore/core/smtlib/solver.py
--- manticore/core/smtlib/solver.py	2019-11-24 11:14:37.431508 +0000
+++ manticore/core/smtlib/solver.py	2019-11-24 12:09:00.461367 +0000
@@ -149,13 +149,11 @@
         self._proc: Popen = None

         # z3 parameters can be listed via `z3 -p` and set on the CLI
         parameters = "parallel.enable=true"

-        self._command = (
-            f"{consts.z3_bin} -t:{consts.timeout*1000} -memory:{consts.memory} -smt2 {parameters} -in"
-        )
+        self._command = f"{consts.z3_bin} -t:{consts.timeout*1000} -memory:{consts.memory} -smt2 {parameters} -in"

         # Commands used to initialize z3
         self._init = [
             # http://smtlib.cs.uiowa.edu/logics-all.shtml#QF_AUFBV
             # Closed quantifier-free formulas over the theory of bitvectors and bitvector arrays extended with
would reformat manticore/core/smtlib/solver.py
Oh no! 💥 💔 💥
1 file would be reformatted.

TLDR: This is not helpful when looking at `lint` build output:
```
$ black --check manticore/core/smtlib/solver.py
would reformat manticore/core/smtlib/solver.py
Oh no! 💥 💔 💥
1 file would be reformatted.
```

And this is more helpful:
```
$ black --diff --check manticore/core/smtlib/solver.py
--- manticore/core/smtlib/solver.py	2019-11-24 11:14:37.431508 +0000
+++ manticore/core/smtlib/solver.py	2019-11-24 12:09:00.461367 +0000
@@ -149,13 +149,11 @@
         self._proc: Popen = None

         # z3 parameters can be listed via `z3 -p` and set on the CLI
         parameters = "parallel.enable=true"

-        self._command = (
-            f"{consts.z3_bin} -t:{consts.timeout*1000} -memory:{consts.memory} -smt2 {parameters} -in"
-        )
+        self._command = f"{consts.z3_bin} -t:{consts.timeout*1000} -memory:{consts.memory} -smt2 {parameters} -in"

         # Commands used to initialize z3
         self._init = [
             # http://smtlib.cs.uiowa.edu/logics-all.shtml#QF_AUFBV
             # Closed quantifier-free formulas over the theory of bitvectors and bitvector arrays extended with
would reformat manticore/core/smtlib/solver.py
Oh no! 💥 💔 💥
1 file would be reformatted.
```
@reaperhulk
reaperhulk merged commit 33779ca into master Nov 24, 2019
@reaperhulk
reaperhulk deleted the travis-diff-black branch November 24, 2019 12:40
ekilmer added a commit that referenced this pull request Dec 17, 2019
* master: (33 commits)
  removes travis entirely (#1572)
  Run mypy on manticore directory by default (#1573)
  Fix deprecation warnings related to setting verbosity (#1574)
  Bump version to fix pip install on Python 3.6 (#1571)
  Direct CI badge directly to CI action (#1570)
  switch to github actions (take two) (#1568)
  Add --quick-mode to configure Manticore for fast exploration (#1555)
  pytest-xdist prevents disturbing stdout, revert to travis_wait (#1566)
  Show black diff on travis builds (#1565)
  various changes to resolve test timeout/invalid dep issues (#1563)
  try pytest xdist (#1561)
  switch to pytest (#1560)
  Fixes different problems found by lgtm (#1558)
  reorg some deps a bit, usee env markers for dataclasses (#1559)
  fix some deprecation warnings (#1556)
  Add flag to only generate alive states when finalizing Manticore (#1554)
  Arrayvarname (#1552)
  Fix Z3 version parsing (#1551)
  Update README.md (#1553)
  Manticore 0.3.2 (#1547)
  ...
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants