Skip to content

Commit f2b92d8

Browse files
committed
Add backtrace to debug
1 parent d71bc54 commit f2b92d8

File tree

3 files changed

+10
-1
lines changed

3 files changed

+10
-1
lines changed

.travis.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,11 +12,12 @@ python:
1212
install:
1313
- sudo apt-get update -qq
1414
- sudo apt-get install -qq swig python-dev libxml2-dev libxmlsec1-dev
15+
- sudo apt-get install gdb
1516
- 'travis_retry pip install .'
1617
- 'travis_retry pip install -e ".[test]"'
1718

1819
script:
19-
- 'coverage run --source=src/onelogin/saml2 --rcfile=tests/coverage.rc setup.py test'
20+
- './seg_wrapper.sh coverage run --source=src/onelogin/saml2 --rcfile=tests/coverage.rc setup.py test'
2021
- 'coverage report -m --rcfile=tests/coverage.rc'
2122
# - 'pylint src/onelogin/saml2 --rcfile=tests/pylint.rc'
2223
- 'pep8 tests/src/OneLogin/saml2_tests/*.py demo-flask/*.py demo-django/*.py src/onelogin/saml2/*.py --config=tests/pep8.rc'

backtrace

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
backtrace
2+
quit

seg_wrapper.sh

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
#!/bin/bash
2+
ulimit -c unlimited
3+
"$@"
4+
if [[ $? -eq 139 ]]; then
5+
gdb -q $1 core -x ./backtrace
6+
fi

0 commit comments

Comments
 (0)