[2.0 beta 2] NameError: name 'LargeFile' is not defined

Bug #1570626 reported by Andres Rodriguez
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
MAAS
Fix Released
Critical
Gavin Panella

Bug Description

<root@maasx>:/var/log/apt# apt dist-upgrade
Reading package lists... Done
Building dependency tree
Reading state information... Done
Calculating upgrade... Done
The following packages were automatically installed and are no longer required:
  iproute libecap2v5 libllvm3.6v5 python3-characteristic python3-dns
Use 'apt autoremove' to remove them.
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
2 not fully installed or removed.
After this operation, 0 B of additional disk space will be used.
Do you want to continue? [Y/n]
Setting up maas-region-controller (2.0.0~beta2+bzr4920-0ubuntu1) ...
Operations to perform:
  Synchronize unmigrated apps: messages, staticfiles
  Apply all migrations: maasserver, piston3, contenttypes, sessions, metadataserver, auth, sites
Synchronizing apps without migrations:
  Creating tables...
    Running deferred SQL...
  Installing custom SQL...
Running migrations:
  Rendering model states... DONE
  Applying maasserver.0044_remove_di_bootresourcefiles...Traceback (most recent call last):
  File "/usr/lib/python3/dist-packages/django/db/models/fields/related.py", line 600, in __get__
    rel_obj = getattr(instance, self.cache_name)
AttributeError: 'BootResourceFile' object has no attribute '_largefile_cache'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/lib/python3/dist-packages/maasserver/migrations/builtin/maasserver/0044_remove_di_bootresourcefiles.py", line 24, in remove_di_bootresourcefiles
    largefile = resource_file.largefile
  File "/usr/lib/python3/dist-packages/django/db/models/fields/related.py", line 617, in __get__
    rel_obj = qs.get()
  File "/usr/lib/python3/dist-packages/django/db/models/query.py", line 334, in get
    self.model._meta.object_name
__fake__.DoesNotExist: LargeFile matching query does not exist.

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/sbin/maas-region", line 67, in <module>
    main()
  File "/usr/sbin/maas-region", line 63, in main
    run()
  File "/usr/sbin/maas-region", line 51, in run
    management.execute_from_command_line()
  File "/usr/lib/python3/dist-packages/django/core/management/__init__.py", line 354, in execute_from_command_line
    utility.execute()
  File "/usr/lib/python3/dist-packages/django/core/management/__init__.py", line 346, in execute
    self.fetch_command(subcommand).run_from_argv(self.argv)
  File "/usr/lib/python3/dist-packages/django/core/management/base.py", line 394, in run_from_argv
    self.execute(*args, **cmd_options)
  File "/usr/lib/python3/dist-packages/django/core/management/base.py", line 445, in execute
    output = self.handle(*args, **options)
  File "/usr/lib/python3/dist-packages/maasserver/management/commands/dbupgrade.py", line 320, in handle
    fake_initial=self._south_was_performed(database))
  File "/usr/lib/python3/dist-packages/django/core/management/__init__.py", line 120, in call_command
    return command.execute(*args, **defaults)
  File "/usr/lib/python3/dist-packages/django/core/management/base.py", line 445, in execute
    output = self.handle(*args, **options)
  File "/usr/lib/python3/dist-packages/django/core/management/commands/migrate.py", line 222, in handle
    executor.migrate(targets, plan, fake=fake, fake_initial=fake_initial)
  File "/usr/lib/python3/dist-packages/django/db/migrations/executor.py", line 110, in migrate
    self.apply_migration(states[migration], migration, fake=fake, fake_initial=fake_initial)
  File "/usr/lib/python3/dist-packages/django/db/migrations/executor.py", line 148, in apply_migration
    state = migration.apply(state, schema_editor)
  File "/usr/lib/python3/dist-packages/django/db/migrations/migration.py", line 115, in apply
    operation.database_forwards(self.app_label, schema_editor, old_state, project_state)
  File "/usr/lib/python3/dist-packages/django/db/migrations/operations/special.py", line 183, in database_forwards
    self.code(from_state.apps, schema_editor)
  File "/usr/lib/python3/dist-packages/maasserver/migrations/builtin/maasserver/0044_remove_di_bootresourcefiles.py", line 25, in remove_di_bootresourcefiles
    except LargeFile.DoesNotExist:
NameError: name 'LargeFile' is not defined
dpkg: error processing package maas-region-controller (--configure):
 subprocess installed post-installation script returned error exit status 1
dpkg: dependency problems prevent configuration of maas:
 maas depends on maas-region-controller (= 2.0.0~beta2+bzr4920-0ubuntu1); however:
  Package maas-region-controller is not configured yet.

dpkg: error processing package maas (--configure):
 dependency problems - leaving unconfigured
No apport report written because the error message indicates its a followup error from a previous failure.
                                                                                                          Errors were encountered while processing:
 maas-region-controller
 maas
E: Sub-process /usr/bin/dpkg returned an error code (1)

Related branches

Changed in maas:
milestone: none → 2.0.0
importance: Undecided → Critical
Gavin Panella (allenap)
Changed in maas:
status: New → In Progress
assignee: nobody → Gavin Panella (allenap)
Changed in maas:
status: In Progress → Fix Committed
Changed in maas:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.