Version 3.3.8

Released: January 17, 2020

Changes

Converter

A new was added to the CONVERTER_GRAPHICS_BACKEND_ARGUMENTS setting to allow passing a maximum image pixel count to Pillow. The entry is called 'pillow_maximum_image_pixels' and defaults to 89478485. This entry is used to increase the threshold upon which Pillow with trigger the Decompression bomb protection. (https://pillow.readthedocs.io/en/5.1.x/releasenotes/5.0.0.html#decompression-bombs-now-raise-exceptions)

Dependencies

The OS detection for the paths of pdfinfo, pdftoppm, libreoffice, exiftool and tesseract was improved to work on MacOs.

Documentation

The direct deployment documentation was updated to advise users installing in a custom directory to verify the automatically generated supervisor configuration file.

A note was added to the LDAP section of the FAQ to assist users with potential local environment issues.

The sample docker-compose.yml file and documentation were updated to ensure RabbitMQ messages are persistent.

The File Storage section of the documentation was improved.

The documentation update script was updated to delete published documentation files before uploading new content. Old documentation links will not work anymore. For a more complete explanation check forum post: https://forum.mayan-edms.com/viewtopic.php?t=1605

File metadata

Fixed typos in the file metadata property label.

Improved the way the file metadata property path was read. Accessing the file metadata value from a template will no longer error out when passed an invalid path to the driver as reference.

Metadata

Fixed the metadata app view permissions layout. The metadata add, edit, and remove permissions are now required for both the document and the the metadata type in order to add, edit or remove a metadata from a document. The HTML and API were updated, as well as the document metadata widget to only show metadata types for which the document metadata view permission was been granted.

The redirects after the document metadata add, edit, and remove actions were fixed too.

Permissions

The permissions are now initialized on every start or installation instead of them being initialized on demand. This fixes the situation where not all permissions would show up as available in the role permission assignment view.

Signatures

Document detached signing was fixed as is operating as expected again.

Sources

A repeated raise statement was removed that was causing HTML markup to show up on the upload error display widget.

Tags

The Tags apps API required permissions was fixed. The required permissions of the API match those of the view and comply with MERC 0006. (https://docs.mayan-edms.com/mercs/0006-lower-information-disclose.html)

Templating

The model property choice field of the template widget is now never required, regardless of the required setting of the template field. This fixes the web link creation form.

Removals

  • None

Upgrading process

  1. Stop supervisord:

    sudo systemctl stop supervisor
    

Upgrading from Mayan EDMS 3.2.x

  1. Update the Redis configuration:

    Configure Redis to discard data when it runs out of memory, not save its database, and only keep 2 database:

    echo "maxmemory-policy allkeys-lru" | sudo tee -a /etc/redis/redis.conf
    echo "save \"\"" | sudo tee -a /etc/redis/redis.conf
    echo "databases 2" | sudo tee -a /etc/redis/redis.conf
    sudo systemctl restart redis
    
  2. Install the Python 3 development OS package:

    sudo apt-get install python3-dev
    
  3. Update the virtualenv to use Python 3:

    sudo -u mayan virtualenv --clear /opt/mayan-edms -p /usr/bin/python3
    
  4. Create a home directory for the Mayan EDMS system user:

    mkdir /home/mayan
    
  5. Grant ownership to the Mayan EDMS system user:

    chown mayan:mayan /home/mayan
    
  6. Reinstall the Python client for PostgreSQL and Redis:

    sudo -u mayan /opt/mayan-edms/bin/pip install --no-use-pep517 psycopg2==2.8.3 redis==3.3.11
    

    Note

    Platforms with the ARM CPU might also need additional requirements:

    sudo -u mayan /opt/mayan-edms/bin/pip install --no-use-pep517 psutil==5.6.2
    
  7. Reinstall the Python client for RabbitMQ if you are using RabbitMQ as a broker:

    sudo -u mayan /opt/mayan-edms/bin/pip install --no-use-pep517 amqp==2.5.2
    

Upgrade steps from any previous version of Mayan EDMS

  1. Remove deprecated requirements:

    sudo -u mayan curl https://gitlab.com/mayan-edms/mayan-edms/raw/master/removals.txt -o /tmp/removals.txt \
    && sudo -u mayan /opt/mayan-edms/bin/pip uninstall -y -r /tmp/removals.txt
    
  2. Update the Mayan EDMS Python package:

    sudo -u mayan /opt/mayan-edms/bin/pip install mayan-edms==3.3.8
    

    the requirements will also be updated automatically.

  3. Make a backup of your supervisord file:

    sudo cp /etc/supervisor/conf.d/mayan.conf /etc/supervisor/conf.d/mayan.conf.bck
    
  4. Update the supervisord configuration file. Replace the environment variables values show here with your respective settings. This step will refresh the supervisord configuration file with the new queues and the latest recommended layout:

    sudo -u mayan MAYAN_DATABASE_ENGINE=django.db.backends.postgresql MAYAN_DATABASE_NAME=mayan \
    MAYAN_DATABASE_PASSWORD=mayanuserpass MAYAN_DATABASE_USER=mayan \
    MAYAN_DATABASE_HOST=127.0.0.1 MAYAN_MEDIA_ROOT=/opt/mayan-edms/media \
    /opt/mayan-edms/bin/mayan-edms.py platformtemplate supervisord | sudo sh -c "cat > /etc/supervisor/conf.d/mayan.conf"
    

    or:

    sudo -u mayan MAYAN_DATABASES=\"{'default':{'ENGINE':'django.db.backends.postgresql','NAME':'mayan','PASSWORD':'mayanuserpass','USER':'mayan','HOST':'127.0.0.1'}}\" \
    MAYAN_MEDIA_ROOT=/opt/mayan-edms/media \
    /opt/mayan-edms/bin/mayan-edms.py platformtemplate supervisord | sudo sh -c "cat > /etc/supervisor/conf.d/mayan.conf"
    
  5. Edit the supervisord configuration file and update any setting specific to your installation:

    sudo vi /etc/supervisor/conf.d/mayan.conf
    
  6. Migrate existing database schema with:

    sudo -u mayan MAYAN_DATABASE_ENGINE=django.db.backends.postgresql MAYAN_DATABASE_NAME=mayan \
    MAYAN_DATABASE_PASSWORD=mayanuserpass MAYAN_DATABASE_USER=mayan \
    MAYAN_DATABASE_HOST=127.0.0.1 MAYAN_MEDIA_ROOT=/opt/mayan-edms/media \
    /opt/mayan-edms/bin/mayan-edms.py performupgrade
    

    or:

     sudo -u mayan MAYAN_DATABASES="{'default':{'ENGINE':'django.db.backends.postgresql','NAME':'mayan','PASSWORD':'mayanuserpass','USER':'mayan','HOST':'127.0.0.1'}}" \
     MAYAN_MEDIA_ROOT=/opt/mayan-edms/media \
    /opt/mayan-edms/bin/mayan-edms.py performupgrade
    
  7. Add new static media:

    sudo -u mayan MAYAN_MEDIA_ROOT=/opt/mayan-edms/media \
    /opt/mayan-edms/bin/mayan-edms.py preparestatic --noinput
    
  8. Start supervisord:

    sudo systemctl start supervisor
    

The upgrade procedure is now complete.

Backward incompatible changes

  • None

Bugs fixed or issues closed