annotate .travis.yml @ 5373:faf3f01ef446

Run into a roadblock with trying to install python 3 compatible xapian. Leaving my attempt in as commented out code for next person to attempt. Reinstaled the code that works with python 2 environment so CI can be used for testing python 2 at least.
author John Rouillard <rouilj@ieee.org>
date Fri, 20 Jul 2018 21:16:49 -0400
parents 5e5f1dfb1596
children 1ad46057ae4a
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
5003
a9e0ef739241 Add .travis.yml
John Kristensen <john@jerrykan.com>
parents:
diff changeset
1 language: python
a9e0ef739241 Add .travis.yml
John Kristensen <john@jerrykan.com>
parents:
diff changeset
2 python:
a9e0ef739241 Add .travis.yml
John Kristensen <john@jerrykan.com>
parents:
diff changeset
3 - 2.7
5368
904d7cd19d67 Set up travis to run python 3.4 across code as well. Do not fail the
John Rouillard <rouilj@ieee.org>
parents: 5259
diff changeset
4 - 3.4
904d7cd19d67 Set up travis to run python 3.4 across code as well. Do not fail the
John Rouillard <rouilj@ieee.org>
parents: 5259
diff changeset
5
904d7cd19d67 Set up travis to run python 3.4 across code as well. Do not fail the
John Rouillard <rouilj@ieee.org>
parents: 5259
diff changeset
6 matrix:
904d7cd19d67 Set up travis to run python 3.4 across code as well. Do not fail the
John Rouillard <rouilj@ieee.org>
parents: 5259
diff changeset
7 allow_failures:
904d7cd19d67 Set up travis to run python 3.4 across code as well. Do not fail the
John Rouillard <rouilj@ieee.org>
parents: 5259
diff changeset
8 - python: 3.4
5003
a9e0ef739241 Add .travis.yml
John Kristensen <john@jerrykan.com>
parents:
diff changeset
9
a9e0ef739241 Add .travis.yml
John Kristensen <john@jerrykan.com>
parents:
diff changeset
10 sudo: false
a9e0ef739241 Add .travis.yml
John Kristensen <john@jerrykan.com>
parents:
diff changeset
11
a9e0ef739241 Add .travis.yml
John Kristensen <john@jerrykan.com>
parents:
diff changeset
12 addons:
a9e0ef739241 Add .travis.yml
John Kristensen <john@jerrykan.com>
parents:
diff changeset
13 apt:
a9e0ef739241 Add .travis.yml
John Kristensen <john@jerrykan.com>
parents:
diff changeset
14 packages:
5373
faf3f01ef446 Run into a roadblock with trying to install python 3 compatible
John Rouillard <rouilj@ieee.org>
parents: 5372
diff changeset
15 # required for install of xapian-bindings-1.2.16
faf3f01ef446 Run into a roadblock with trying to install python 3 compatible
John Rouillard <rouilj@ieee.org>
parents: 5372
diff changeset
16 - libxapian-dev
faf3f01ef446 Run into a roadblock with trying to install python 3 compatible
John Rouillard <rouilj@ieee.org>
parents: 5372
diff changeset
17 # required for install of 1.3.7 version of xapian
5372
5e5f1dfb1596 Add python-sphinx. Looks like it's needed to build:
John Rouillard <rouilj@ieee.org>
parents: 5371
diff changeset
18 - python-sphinx
5003
a9e0ef739241 Add .travis.yml
John Kristensen <john@jerrykan.com>
parents:
diff changeset
19 # Required to install pyme
a9e0ef739241 Add .travis.yml
John Kristensen <john@jerrykan.com>
parents:
diff changeset
20 - libgpgme11-dev
a9e0ef739241 Add .travis.yml
John Kristensen <john@jerrykan.com>
parents:
diff changeset
21 - swig
a9e0ef739241 Add .travis.yml
John Kristensen <john@jerrykan.com>
parents:
diff changeset
22
a9e0ef739241 Add .travis.yml
John Kristensen <john@jerrykan.com>
parents:
diff changeset
23 before_install:
a9e0ef739241 Add .travis.yml
John Kristensen <john@jerrykan.com>
parents:
diff changeset
24 - cd /tmp
5373
faf3f01ef446 Run into a roadblock with trying to install python 3 compatible
John Rouillard <rouilj@ieee.org>
parents: 5372
diff changeset
25 # commented out section of xapian installing core and bindings.
5370
90836bd3b1c0 Try to install xapian-core from source. Deb package on ubuntu trusty
John Rouillard <rouilj@ieee.org>
parents: 5369
diff changeset
26 # install core 1.3.7 as version in trusty deb is 1.2. need 1.3 for python 3.
5373
faf3f01ef446 Run into a roadblock with trying to install python 3 compatible
John Rouillard <rouilj@ieee.org>
parents: 5372
diff changeset
27 #- curl -s -O https://oligarchy.co.uk/xapian/1.3.7/xapian-core-1.3.7.tar.xz
faf3f01ef446 Run into a roadblock with trying to install python 3 compatible
John Rouillard <rouilj@ieee.org>
parents: 5372
diff changeset
28 #- tar -Jxvf xapian-core-1.3.7.tar.xz
faf3f01ef446 Run into a roadblock with trying to install python 3 compatible
John Rouillard <rouilj@ieee.org>
parents: 5372
diff changeset
29 #- cd xapian-core-1.3.7/
faf3f01ef446 Run into a roadblock with trying to install python 3 compatible
John Rouillard <rouilj@ieee.org>
parents: 5372
diff changeset
30 #- ./configure && make && sudo make install
faf3f01ef446 Run into a roadblock with trying to install python 3 compatible
John Rouillard <rouilj@ieee.org>
parents: 5372
diff changeset
31 #- cd /tmp
faf3f01ef446 Run into a roadblock with trying to install python 3 compatible
John Rouillard <rouilj@ieee.org>
parents: 5372
diff changeset
32 #- curl -s -O https://oligarchy.co.uk/xapian/1.3.7/xapian-bindings-1.3.7.tar.xz
faf3f01ef446 Run into a roadblock with trying to install python 3 compatible
John Rouillard <rouilj@ieee.org>
parents: 5372
diff changeset
33 #- tar -Jxvf xapian-bindings-1.3.7.tar.xz
faf3f01ef446 Run into a roadblock with trying to install python 3 compatible
John Rouillard <rouilj@ieee.org>
parents: 5372
diff changeset
34 #- cd xapian-bindings-1.3.7/
faf3f01ef446 Run into a roadblock with trying to install python 3 compatible
John Rouillard <rouilj@ieee.org>
parents: 5372
diff changeset
35 #- ./configure --prefix=$VIRTUAL_ENV --with-python && make && make install
faf3f01ef446 Run into a roadblock with trying to install python 3 compatible
John Rouillard <rouilj@ieee.org>
parents: 5372
diff changeset
36 # the above fails on python 2.7 with:
faf3f01ef446 Run into a roadblock with trying to install python 3 compatible
John Rouillard <rouilj@ieee.org>
parents: 5372
diff changeset
37 # ImportError: libxapian-1.3.so.8: cannot open shared object file:
faf3f01ef446 Run into a roadblock with trying to install python 3 compatible
John Rouillard <rouilj@ieee.org>
parents: 5372
diff changeset
38 # No such file or directory
faf3f01ef446 Run into a roadblock with trying to install python 3 compatible
John Rouillard <rouilj@ieee.org>
parents: 5372
diff changeset
39 # That library is installed by xapian-core-1.3.7 above. My guess
faf3f01ef446 Run into a roadblock with trying to install python 3 compatible
John Rouillard <rouilj@ieee.org>
parents: 5372
diff changeset
40 # is that the virtualenv is created by travis software before
faf3f01ef446 Run into a roadblock with trying to install python 3 compatible
John Rouillard <rouilj@ieee.org>
parents: 5372
diff changeset
41 # before_install is called and xapian-core is installed.
faf3f01ef446 Run into a roadblock with trying to install python 3 compatible
John Rouillard <rouilj@ieee.org>
parents: 5372
diff changeset
42 # So libxapian is not present in the virtualenv python install.
faf3f01ef446 Run into a roadblock with trying to install python 3 compatible
John Rouillard <rouilj@ieee.org>
parents: 5372
diff changeset
43 # See https://travis-ci.org/roundup-tracker/roundup/builds/406481321
faf3f01ef446 Run into a roadblock with trying to install python 3 compatible
John Rouillard <rouilj@ieee.org>
parents: 5372
diff changeset
44 # Install 1.2.16 xapian-bindings compatible with xapian-dev in ubuntu trusty
faf3f01ef446 Run into a roadblock with trying to install python 3 compatible
John Rouillard <rouilj@ieee.org>
parents: 5372
diff changeset
45 - curl -s -O https://oligarchy.co.uk/xapian/1.2.16/xapian-bindings-1.2.16.tar.xz
faf3f01ef446 Run into a roadblock with trying to install python 3 compatible
John Rouillard <rouilj@ieee.org>
parents: 5372
diff changeset
46 - tar -Jxvf xapian-bindings-1.2.16.tar.xz
faf3f01ef446 Run into a roadblock with trying to install python 3 compatible
John Rouillard <rouilj@ieee.org>
parents: 5372
diff changeset
47 - cd xapian-bindings-1.2.16/
5003
a9e0ef739241 Add .travis.yml
John Kristensen <john@jerrykan.com>
parents:
diff changeset
48 - ./configure --prefix=$VIRTUAL_ENV --with-python && make && make install
a9e0ef739241 Add .travis.yml
John Kristensen <john@jerrykan.com>
parents:
diff changeset
49
a9e0ef739241 Add .travis.yml
John Kristensen <john@jerrykan.com>
parents:
diff changeset
50 # change back to the checked out repository directory
a9e0ef739241 Add .travis.yml
John Kristensen <john@jerrykan.com>
parents:
diff changeset
51 - cd $TRAVIS_BUILD_DIR
a9e0ef739241 Add .travis.yml
John Kristensen <john@jerrykan.com>
parents:
diff changeset
52
a9e0ef739241 Add .travis.yml
John Kristensen <john@jerrykan.com>
parents:
diff changeset
53 install:
5099
a7cf77108e97 issue2550636 instal whosh as part of travis ci to try to get indexer testing working
John Rouillard <rouilj@ieee.org>
parents: 5060
diff changeset
54 - pip install MySQL-python psycopg2 pytz pyme whoosh
5060
de420f34d696 Add codecov support to TravisCI
John Kristensen <john@jerrykan.com>
parents: 5059
diff changeset
55 - pip install pytest-cov codecov
5003
a9e0ef739241 Add .travis.yml
John Kristensen <john@jerrykan.com>
parents:
diff changeset
56
a9e0ef739241 Add .travis.yml
John Kristensen <john@jerrykan.com>
parents:
diff changeset
57 before_script:
a9e0ef739241 Add .travis.yml
John Kristensen <john@jerrykan.com>
parents:
diff changeset
58 # set up mysql database
a9e0ef739241 Add .travis.yml
John Kristensen <john@jerrykan.com>
parents:
diff changeset
59 - mysql -u root -e 'GRANT ALL ON rounduptest.* TO rounduptest@localhost IDENTIFIED BY "rounduptest";'
a9e0ef739241 Add .travis.yml
John Kristensen <john@jerrykan.com>
parents:
diff changeset
60
a9e0ef739241 Add .travis.yml
John Kristensen <john@jerrykan.com>
parents:
diff changeset
61 # set up postgresql database
a9e0ef739241 Add .travis.yml
John Kristensen <john@jerrykan.com>
parents:
diff changeset
62 - psql -c "CREATE ROLE rounduptest WITH CREATEDB LOGIN PASSWORD 'rounduptest';" -U postgres
a9e0ef739241 Add .travis.yml
John Kristensen <john@jerrykan.com>
parents:
diff changeset
63
a9e0ef739241 Add .travis.yml
John Kristensen <john@jerrykan.com>
parents:
diff changeset
64 # HACK: workaround mysql bug: http://bugs.mysql.com/bug.php?id=74901
a9e0ef739241 Add .travis.yml
John Kristensen <john@jerrykan.com>
parents:
diff changeset
65 # needed for test_mysql.mysqlDBTest.testFilteringSpecialChars
a9e0ef739241 Add .travis.yml
John Kristensen <john@jerrykan.com>
parents:
diff changeset
66 - sed -i 's/CREATE DATABASE \%s/CREATE DATABASE \%s COLLATE utf8_general_ci/' roundup/backends/back_mysql.py
a9e0ef739241 Add .travis.yml
John Kristensen <john@jerrykan.com>
parents:
diff changeset
67
a9e0ef739241 Add .travis.yml
John Kristensen <john@jerrykan.com>
parents:
diff changeset
68 script:
5060
de420f34d696 Add codecov support to TravisCI
John Kristensen <john@jerrykan.com>
parents: 5059
diff changeset
69 - py.test -v test/ --cov=roundup
de420f34d696 Add codecov support to TravisCI
John Kristensen <john@jerrykan.com>
parents: 5059
diff changeset
70
de420f34d696 Add codecov support to TravisCI
John Kristensen <john@jerrykan.com>
parents: 5059
diff changeset
71 after_success:
de420f34d696 Add codecov support to TravisCI
John Kristensen <john@jerrykan.com>
parents: 5059
diff changeset
72 - codecov

Roundup Issue Tracker: http://roundup-tracker.org/