2014-07-12 13:36:11 -03:00
|
|
|
language: cpp
|
2016-04-14 20:28:04 -03:00
|
|
|
sudo: false
|
2015-11-24 18:25:53 -04:00
|
|
|
|
2019-04-01 09:33:11 -03:00
|
|
|
dist: xenial
|
2015-11-24 18:25:53 -04:00
|
|
|
addons:
|
2016-04-14 12:53:52 -03:00
|
|
|
apt:
|
|
|
|
sources:
|
|
|
|
- ubuntu-toolchain-r-test
|
2019-04-01 09:33:11 -03:00
|
|
|
- sourceline: 'deb http://apt.llvm.org/xenial/ llvm-toolchain-xenial-7 main'
|
2018-09-19 13:01:28 -03:00
|
|
|
key_url: 'https://apt.llvm.org/llvm-snapshot.gpg.key'
|
2016-04-14 12:53:52 -03:00
|
|
|
packages:
|
|
|
|
- build-essential
|
|
|
|
- gawk
|
|
|
|
- genromfs
|
|
|
|
- libc6-i386
|
2016-10-16 06:30:59 -03:00
|
|
|
- libxml2-dev
|
|
|
|
- libxslt1-dev
|
2016-04-14 12:53:52 -03:00
|
|
|
- python-pip
|
|
|
|
- python-dev
|
|
|
|
- zlib1g-dev
|
2019-06-13 22:37:17 -03:00
|
|
|
- gdb
|
2019-04-01 09:33:11 -03:00
|
|
|
- cmake
|
|
|
|
- cmake-data
|
2018-09-19 13:01:28 -03:00
|
|
|
- clang-7
|
|
|
|
- llvm-7
|
2014-07-12 13:36:11 -03:00
|
|
|
|
2016-04-14 22:03:18 -03:00
|
|
|
cache:
|
2018-08-29 20:15:09 -03:00
|
|
|
ccache: false
|
2016-04-14 22:03:18 -03:00
|
|
|
directories:
|
|
|
|
- $HOME/opt
|
|
|
|
|
2014-07-12 13:36:11 -03:00
|
|
|
before_install:
|
2019-09-04 07:09:52 -03:00
|
|
|
- echo 0 | sudo dd of=/proc/sys/kernel/yama/ptrace_scope
|
2016-04-14 23:48:57 -03:00
|
|
|
- Tools/scripts/configure-ci.sh
|
2016-05-17 11:41:52 -03:00
|
|
|
- if [ "$TRAVIS_EVENT_TYPE" = "cron" ]; then export CI_CRON_JOB=1 ; fi
|
2015-11-24 22:26:41 -04:00
|
|
|
|
2015-11-24 18:25:53 -04:00
|
|
|
script:
|
2016-01-18 12:15:02 -04:00
|
|
|
- Tools/scripts/build_ci.sh
|
2014-12-31 18:43:16 -04:00
|
|
|
|
|
|
|
notifications:
|
|
|
|
webhooks:
|
|
|
|
urls:
|
|
|
|
- https://webhooks.gitter.im/e/e5e0b55e353e53945b4b
|
|
|
|
on_success: change # options: [always|never|change] default: always
|
|
|
|
on_failure: always # options: [always|never|change] default: always
|
|
|
|
on_start: false # default: false
|
2015-06-02 17:44:17 -03:00
|
|
|
|
2016-05-17 02:31:04 -03:00
|
|
|
compiler:
|
|
|
|
- gcc
|
|
|
|
|
2015-06-02 17:44:17 -03:00
|
|
|
env:
|
|
|
|
global:
|
2015-06-11 19:56:15 -03:00
|
|
|
# The next declaration is the encrypted COVERITY_SCAN_TOKEN, created
|
|
|
|
# via the "travis encrypt" command using the project repo's public key
|
|
|
|
- secure: "FjIwqZQV2FhNPWYITX5LZXTE38yYqBaQdbm3QmbEg/30wnPTm1ZOLIU7o/aSvX615ImR8kHoryvFPDQDWc6wWfqTEs3Ytq2kIvcIJS2Y5l/0PFfpWJoH5gRd6hDThnoi+1oVMLvj1+bhn4yFlCCQ2vT/jxoGfiQqqgvHtv4fLzI="
|
2019-02-28 06:52:17 -04:00
|
|
|
- AUTOTEST_UPLOAD=true # Upload logs of failed tests to ArduPilot server; requires authentication
|
2016-03-08 21:03:29 -04:00
|
|
|
|
|
|
|
matrix:
|
2016-05-17 02:31:04 -03:00
|
|
|
fast_finish: true
|
2016-03-08 21:03:29 -04:00
|
|
|
include:
|
2018-08-29 22:02:55 -03:00
|
|
|
- if: type != cron
|
|
|
|
compiler: "gcc"
|
2019-07-31 22:25:43 -03:00
|
|
|
env: CI_BUILD_TARGET="revo-bootloader periph-build CubeOrange-bootloader iofirmware stm32f7 stm32h7 fmuv2-plane"
|
2018-08-29 20:15:09 -03:00
|
|
|
- if: type != cron
|
|
|
|
compiler: "gcc"
|
2018-01-22 20:40:41 -04:00
|
|
|
env: CI_BUILD_TARGET="sitltest-copter"
|
2018-08-29 20:15:09 -03:00
|
|
|
- if: type != cron
|
|
|
|
compiler: "gcc"
|
2018-09-19 13:01:28 -03:00
|
|
|
env: CI_BUILD_TARGET="sitltest-quadplane sitltest-plane"
|
|
|
|
- if: type != cron
|
2019-03-26 14:15:22 -03:00
|
|
|
compiler: "clang-7"
|
2019-09-17 18:09:33 -03:00
|
|
|
env: CI_BUILD_TARGET="sitltest-rover sitltest-sub sitltest-balancebot"
|
2019-09-23 23:58:12 -03:00
|
|
|
- if: type != cron
|
|
|
|
compiler: "gcc"
|
|
|
|
env: CI_BUILD_TARGET="unit-tests"
|
2019-04-15 22:24:50 -03:00
|
|
|
- if: type != cron
|
|
|
|
compiler: "clang-7"
|
2020-03-03 04:20:56 -04:00
|
|
|
env: CI_BUILD_TARGET="sitl"
|
CI: Run flake8 on Python 3.7
Yet another attempt at #7131 because without automated test, these _undefined names_ keep creeping back into the codebase: #9225, #9226, #9229, #9788, #10038, and a new one below...
[flake8](http://flake8.pycqa.org) testing of https://github.com/ArduPilot/ardupilot on Python 3.7.1
$ __flake8 . --count --select=E901,E999,F821,F822,F823 --show-source --statistics__
```
./Tools/autotest/sim_vehicle.py:396:39: F821 undefined name 'autotest'
swarminit_filepath = os.path.join(autotest, "swarminit.txt")
^
1 F821 undefined name 'autotest'
```
__E901,E999,F821,F822,F823__ are the "_showstopper_" [flake8](http://flake8.pycqa.org) issues that can halt the runtime with a SyntaxError, NameError, etc. Most other flake8 issues are merely "style violations" -- useful for readability but they do not effect runtime safety.
* F821: undefined name `name`
* F822: undefined name `name` in `__all__`
* F823: local variable name referenced before assignment
* E901: SyntaxError or IndentationError
* E999: SyntaxError -- failed to compile a file into an Abstract Syntax Tree
2019-01-18 06:46:11 -04:00
|
|
|
- language: python
|
|
|
|
python: 3.7
|
|
|
|
addons: # speedup: This test does not need addons
|
|
|
|
compiler:
|
|
|
|
dist: xenial # required for Python >= 3.7 (travis-ci/travis-ci#9069)
|
|
|
|
before_install: pip install flake8
|
|
|
|
script:
|
2019-07-31 23:32:20 -03:00
|
|
|
- EXCLUDE=./.*,./modules/gtest,./modules/ChibiOS/test,./modules/uavcan/libuavcan,./modules/libcanard
|
CI: Run flake8 on Python 3.7
Yet another attempt at #7131 because without automated test, these _undefined names_ keep creeping back into the codebase: #9225, #9226, #9229, #9788, #10038, and a new one below...
[flake8](http://flake8.pycqa.org) testing of https://github.com/ArduPilot/ardupilot on Python 3.7.1
$ __flake8 . --count --select=E901,E999,F821,F822,F823 --show-source --statistics__
```
./Tools/autotest/sim_vehicle.py:396:39: F821 undefined name 'autotest'
swarminit_filepath = os.path.join(autotest, "swarminit.txt")
^
1 F821 undefined name 'autotest'
```
__E901,E999,F821,F822,F823__ are the "_showstopper_" [flake8](http://flake8.pycqa.org) issues that can halt the runtime with a SyntaxError, NameError, etc. Most other flake8 issues are merely "style violations" -- useful for readability but they do not effect runtime safety.
* F821: undefined name `name`
* F822: undefined name `name` in `__all__`
* F823: local variable name referenced before assignment
* E901: SyntaxError or IndentationError
* E999: SyntaxError -- failed to compile a file into an Abstract Syntax Tree
2019-01-18 06:46:11 -04:00
|
|
|
- flake8 . --count --exclude=$EXCLUDE --select=E901,E999,F821,F822,F823 --show-source --statistics
|