Skip to content

Commit ec86843

Browse files
Make pipeline more verbose (#1037)
* Verbose pipeline * More warnings, warnings as errors * fixed some warnings * Update .github/workflows/coverage.yml Co-authored-by: DominikKamp <130753997+DominikKamp@users.noreply.github.com> --------- Co-authored-by: DominikKamp <130753997+DominikKamp@users.noreply.github.com>
1 parent a22bd67 commit ec86843

File tree

6 files changed

+6
-18
lines changed

6 files changed

+6
-18
lines changed

.github/workflows/coverage.yml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -40,8 +40,9 @@ jobs:
4040
4141
- name: Install PySCIPOpt
4242
run: |
43-
export CFLAGS="-O0 -ggdb" # disable compiler optimizations for faster builds
44-
python -m pip install .
43+
export CFLAGS="-O0 -ggdb -Wall -Wextra -Werror" # Debug mode. More warnings. Warnings as errors.
44+
python -m pip install . -v 2>&1 | tee build.log
45+
grep -i "warning" build.log || true
4546
4647
- name: Run pyscipopt tests
4748
run: |

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
- Generalized getLhs() and getRhs() to additionally support any linear type constraint
1515
### Fixed
1616
- Raised an error when an expression is used when a variable is required
17+
- Fixed some compile warnings
1718
### Changed
1819
- MatrixExpr.sum() now supports axis arguments and can return either a scalar or MatrixExpr depending on the result dimensions
1920
### Removed

src/pyscipopt/event.pxi

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ cdef class Eventhdlr:
3939

4040

4141
# local helper functions for the interface
42-
cdef Eventhdlr getPyEventhdlr(SCIP_EVENTHDLR* eventhdlr) noexcept with gil:
42+
cdef Eventhdlr getPyEventhdlr(SCIP_EVENTHDLR* eventhdlr):
4343
cdef SCIP_EVENTHDLRDATA* eventhdlrdata
4444
eventhdlrdata = SCIPeventhdlrGetData(eventhdlr)
4545
return <Eventhdlr>eventhdlrdata

src/pyscipopt/expr.pxi

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -358,7 +358,7 @@ cdef class ExprCons:
358358
def __repr__(self):
359359
return 'ExprCons(%s, %s, %s)' % (self.expr, self._lhs, self._rhs)
360360

361-
def __nonzero__(self):
361+
def __bool__(self):
362362
'''Make sure that equality of expressions is not asserted with =='''
363363

364364
msg = """Can't evaluate constraints as booleans.

src/pyscipopt/scip.pxd

Lines changed: 0 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -408,12 +408,6 @@ cdef extern from "scip/scip.h":
408408
ctypedef struct SCIP_PROPDATA:
409409
pass
410410

411-
ctypedef struct SCIP_PROPTIMING:
412-
pass
413-
414-
ctypedef struct SCIP_PRESOLTIMING:
415-
pass
416-
417411
ctypedef struct SCIP_PRESOL:
418412
pass
419413

@@ -456,9 +450,6 @@ cdef extern from "scip/scip.h":
456450
ctypedef struct SCIP_PRESOL:
457451
pass
458452

459-
ctypedef struct SCIP_HEURTIMING:
460-
pass
461-
462453
ctypedef struct SCIP_SEPA:
463454
pass
464455

@@ -510,9 +501,6 @@ cdef extern from "scip/scip.h":
510501
ctypedef struct BMS_BLKMEM:
511502
pass
512503

513-
ctypedef struct SCIP_EXPR:
514-
pass
515-
516504
ctypedef struct SCIP_EXPRHDLR:
517505
pass
518506

@@ -708,7 +696,6 @@ cdef extern from "scip/scip.h":
708696
SCIP_Real SCIPgetLocalTransEstimate(SCIP* scip)
709697

710698
# Solve Methods
711-
SCIP_RETCODE SCIPsolve(SCIP* scip)
712699
SCIP_RETCODE SCIPsolve(SCIP* scip) noexcept nogil
713700
SCIP_RETCODE SCIPsolveConcurrent(SCIP* scip)
714701
SCIP_RETCODE SCIPfreeTransform(SCIP* scip)

src/pyscipopt/scip.pxi

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7974,7 +7974,6 @@ cdef class Model:
79747974
79757975
"""
79767976
raise Warning("model.getDualMultiplier(cons) is deprecated: please use model.getDualsolLinear(cons)")
7977-
return self.getDualsolLinear(cons)
79787977

79797978
def getDualfarkasLinear(self, Constraint cons):
79807979
"""

0 commit comments

Comments
 (0)