Error performing 3.4.0 database upgrade

When things don't work as they should.
Post Reply
mheiland
Posts: 7
Joined: Sat Sep 14, 2019 11:22 am

Error performing 3.4.0 database upgrade

Post by mheiland »

Hi,

thanks for releasing Mayan 3.4.0 and the continued effort into this great project!

While upgrading from 3.3.16, running Debian Buster, Python 3.7 and PostgreSQL, i ran into the following DB migration issue:

Code: Select all

root@docs:~# sudo -u mayan MAYAN_DATABASE_ENGINE=django.db.backends.postgresql MAYAN_DATABASE_NAME=mayan MAYAN_DATABASE_PASSWORD=* MAYAN_DATABASE_USER=mayan MAYAN_DATABASE_HOST=db.domain.tld MAYAN_MEDIA_ROOT=/opt/mayan-edms/media /opt/mayan-edms/bin/mayan-edms.py performupgrade

Code: Select all

Operations to perform:
  Apply all migrations: acls, actstream, admin, auth, authtoken, autoadmin, cabinets, checkouts, common, contenttypes, converter, django_celery_beat, django_gpg, document_comments, document_indexing, document_parsing, document_signatures, document_states, documents, dynamic_search, events, file_caching, file_metadata, linking, lock_manager, mailer, mayan_statistics, metadata, motd, ocr, permissions, quotas, sessions, sites, sources, tags, user_management, web_links
Running migrations:
  Applying admin.0003_logentry_add_action_flag_choices... OK
  Applying auth.0009_alter_user_last_name_max_length... OK
  Applying auth.0010_alter_group_name_max_length... OK
  Applying auth.0011_update_proxy_permissions... OK
  Applying cabinets.0003_auto_20200330_0851... OK
  Applying document_indexing.0017_auto_20200330_0851... OK
  Applying document_states.0019_workflowtransition_condition... OK
  Applying document_states.0020_auto_20200311_1714... OK
  Applying documents.0054_trasheddocument... OK
  Applying file_caching.0004_auto_20200309_0922... OK
  CommandError: Error during pre_upgrade signal: 'DefinedStorage' object has no attribute 'delete', <class 'AttributeError'>
  Applying file_caching.0005_auto_20200322_0607...
root@docs:~#
User avatar
rosarior
Developer
Developer
Posts: 546
Joined: Tue Aug 21, 2018 3:28 am
Location: Puerto Rico
Contact:

Re: Error performing 3.4.0 database upgrade

Post by rosarior »

Thanks for the report. We are taking a look to try to replicate this and issue a fix asap.
sal-e
Posts: 6
Joined: Mon Feb 10, 2020 8:18 am

Re: Error performing 3.4.0 database upgrade

Post by sal-e »

Hi,

I got hit by the same problem. I'm using Simple Docker installation https://docs.mayan-edms.com/chapters/do ... er-install.

Any help appreciated.

Thank you.
User avatar
rosarior
Developer
Developer
Posts: 546
Joined: Tue Aug 21, 2018 3:28 am
Location: Puerto Rico
Contact:

Re: Error performing 3.4.0 database upgrade

Post by rosarior »

We were able to replicate the issue and fix the code of the migration.

A new release has been submitted and once the pipeline finishes (https://gitlab.com/mayan-edms/mayan-edm ... /131716205) (about 1 hour) the new version 3.4.1 will be available to use.

Thank you for the report.
mheiland
Posts: 7
Joined: Sat Sep 14, 2019 11:22 am

Re: Error performing 3.4.0 database upgrade

Post by mheiland »

Thats quick, awesome!

Code: Select all

Running migrations:
  Applying file_caching.0005_auto_20200322_0607... OK
  Applying file_caching.0006_auto_20200322_0626... OK
  Applying quotas.0001_initial... OK
Fix confirmed.
User avatar
rosarior
Developer
Developer
Posts: 546
Joined: Tue Aug 21, 2018 3:28 am
Location: Puerto Rico
Contact:

Re: Error performing 3.4.0 database upgrade

Post by rosarior »

Thank for posting the confirmation!
sal-e
Posts: 6
Joined: Mon Feb 10, 2020 8:18 am

Re: Error performing 3.4.0 database upgrade

Post by sal-e »

I can confirm that new (3.4.1) docker image works as expected.
User avatar
rosarior
Developer
Developer
Posts: 546
Joined: Tue Aug 21, 2018 3:28 am
Location: Puerto Rico
Contact:

Re: Error performing 3.4.0 database upgrade

Post by rosarior »

Awesome, thanks for the feedback!
Post Reply