Code

Opened 8 years ago

Closed 8 years ago

#887 closed defect (fixed)

save manipulator throws UnboundLocalError when saving new files

Reported by: mcroydon Owned by: jacob
Component: Metasystem Version:
Severity: normal Keywords:
Cc: Triage Stage: Unreviewed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: UI/UX:

Description

When saving new files, line 1636 of /home/code/django/core/meta/__init__.py sometimes throws the following error:
UnboundLocalError: local variable 'old_rel_obj' referenced before assignment

This can be fixed by assinging old_rel_obj to None in all cases (see patch).

Attachments (1)

django.core.meta.init.diff (762 bytes) - added by mcroydon 8 years ago.
Move old_rel_object outside the if clause so it exists to be checked in all cases.

Download all attachments as: .zip

Change History (2)

Changed 8 years ago by mcroydon

Move old_rel_object outside the if clause so it exists to be checked in all cases.

comment:1 Changed 8 years ago by adrian

  • Resolution set to fixed
  • Status changed from new to closed

Fixed in [1434].

Add Comment

Modify Ticket

Change Properties
<Author field>
Action
as closed
as The resolution will be set. Next status will be 'closed'
The resolution will be deleted. Next status will be 'new'
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.