diff --git a/.github/workflows/ci-test.yml b/.github/workflows/ci-test.yml index 8028aca76..ddce82a7f 100644 --- a/.github/workflows/ci-test.yml +++ b/.github/workflows/ci-test.yml @@ -33,8 +33,8 @@ jobs: name: CI build test # run the finalizer for coveralls even if one or more - # matrix runs fail. - # continue-on-error: true + # experimental matrix runs fail. + # continue-on-error: ${{ matrix.experimental }} #runs-on: ubuntu-latest # use below if running on multiple OS's. @@ -185,7 +185,7 @@ jobs: # Change distutils.sysconfig... to just sysconfig and SO # to EXT_SUFFIX to get valid value. if [[ $PYTHON_VERSION == "3."* ]]; then sed -i -e '/PYTHON3_SO=/s/distutils\.//g' -e '/PYTHON3_SO=/s/"SO"/"EXT_SUFFIX"/g' configure; ./configure --prefix=$VIRTUAL_ENV --with-python3 --disable-documentation; fi - case "$PYTHON_VERSION" in nightly) echo skipping xapian build;; *) make && sudo make install; esac + case "$PYTHON_VERSION" in nightly|3.12*) echo skipping xapian build;; *) make && sudo make install; esac - name: Install pytest and other packages needed for running tests run: pip install flake8 mock pytest pytest-cov requests diff --git a/.travis.yml b/.travis.yml index 3a51866cd..5729849ab 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,6 +1,8 @@ # check syntax using: # https://config.travis-ci.com/explore +# have commit skip build by adding '[skip travis]' to commit message. + os: linux language: python diff --git a/doc/mysql.txt b/doc/mysql.txt index 985ea7b1e..c0ce01312 100644 --- a/doc/mysql.txt +++ b/doc/mysql.txt @@ -70,6 +70,9 @@ this: The MySQL database should not contain any tables. Tests will not drop the database with existing data. +Note that ``rounduptest`` is a well known account. You should delete +it and the ``rounduptest`` database and create a new user/database for +production use. Showing MySQL who's boss ======================== diff --git a/doc/postgresql.txt b/doc/postgresql.txt index 3ad38c5d4..365104159 100644 --- a/doc/postgresql.txt +++ b/doc/postgresql.txt @@ -27,7 +27,6 @@ suggest that you install into a python virtual environment. .. _PostgreSQL: https://www.postgresql.org/ - Running the PostgreSQL unit tests ================================= @@ -36,7 +35,23 @@ the postgresql database on the local machine and create and drop databases. See the config values in 'test/db_test_base.py' about which database connection, name and user will be used. +At this time the following command will setup the user:: + + sudo -u postgres psql -c "CREATE ROLE rounduptest WITH CREATEDB LOGIN PASSWORD 'rounduptest';" -U postgres + +Note ``rounduptest`` is a well known account, so you should +remove/disable the account after testing and set up a suitable +production account. You need to remove any database owned by +``rounduptest`` first. So something like this should work:: + + + sudo -u postgres psql -c "DROP DATABASE rounduptest;" -U postgres + sudo -u postgres psql -c "DROP ROLE rounduptest;" -U postgres +If the ``rounduptest`` database is left in a broken state +(e.g. because of a crash during testing) dropping the database and +restarting the tests should fix it. + Credit ====== diff --git a/scripts/Docker/Dockerfile b/scripts/Docker/Dockerfile index 653434ef9..e8ec1f3bb 100644 --- a/scripts/Docker/Dockerfile +++ b/scripts/Docker/Dockerfile @@ -24,7 +24,7 @@ ARG source=local ARG pythonversion=3.11 #FROM python:3-alpine -FROM python@sha256:caafba876f841774905f73df0fcaf7fe3f55aaf9cb48a9e369a41077f860d4a7 as build +FROM python@sha256:3a619e3c96fd4c5fc5e1998fd4dcb1f1403eb90c4c6409c70d7e80b9468df7df as build # Inherit global values https://github.com/moby/moby/issues/37345 ARG appdir @@ -133,7 +133,7 @@ RUN if [ -n "$pip_mod" ]; then pip install --no-cache-dir ${pip_mod}; fi # build a new smaller docker image for execution. Build image above # is 1G in size. # FROM python:3-alpine -FROM python@sha256:caafba876f841774905f73df0fcaf7fe3f55aaf9cb48a9e369a41077f860d4a7 +FROM python@sha256:3a619e3c96fd4c5fc5e1998fd4dcb1f1403eb90c4c6409c70d7e80b9468df7df # import from global ARG appdir