# This task is used when there is an error in the CI that can't be
# replicated locally.
steps:
- task: UsePythonVersion@0
  inputs:
    versionSpec: '$(python.version)'

- template: jdk.yml
  parameters:
    version: '$(jdk.version)'

- script: |
    sudo apt install gdb
    pip install ./
  displayName: 'Build module'

- script: python -c "import jpype"
  displayName: 'Check module'

- script: |
    python setup.py test_java
    pip install -r test-requirements.txt
    pip install numpy jedi
    gdb -ex 'handle SIGSEGV nostop noprint pass' -ex "run -m pytest -v test/jpypetest/test_jstring.py --checkjni"  -ex "bt" -ex "quit" python
  displayName: 'Debug module'

