moving files while they are encoding breaks encoding #2442

Closed
opened 2014-07-29 15:13:21 +00:00 by j · 2 comments
Owner

moving a file to a new item while its encoding the encoding will fail.

  File "/srv/pandora/pandora/archive/tasks.py", line 133, in extract_stream
    stream.encode()
  File "/srv/pandora/pandora/archive/models.py", line 694, in encode
    self.save()
  File "/srv/pandora/pandora/archive/models.py", line 721, in save
    self.file.save()
  File "/srv/pandora/pandora/archive/models.py", line 235, in save
    self.path = self.normalize_path()
  File "/srv/pandora/pandora/archive/models.py", line 178, in normalize_path
    return self.normalize_item_path()
  File "/srv/pandora/pandora/archive/models.py", line 187, in normalize_item_path
    return ox.movie.format_path(self.get_path_info())
  File "/srv/pandora/pandora/archive/models.py", line 148, in get_path_info
    if self.item:
  File "/srv/pandora/src/django/django/db/models/fields/related.py", line 350, in __get__
    rel_obj = qs.get(**params)

moving a file to a new item while its encoding the encoding will fail. ``` File "/srv/pandora/pandora/archive/tasks.py", line 133, in extract_stream stream.encode() File "/srv/pandora/pandora/archive/models.py", line 694, in encode self.save() File "/srv/pandora/pandora/archive/models.py", line 721, in save self.file.save() File "/srv/pandora/pandora/archive/models.py", line 235, in save self.path = self.normalize_path() File "/srv/pandora/pandora/archive/models.py", line 178, in normalize_path return self.normalize_item_path() File "/srv/pandora/pandora/archive/models.py", line 187, in normalize_item_path return ox.movie.format_path(self.get_path_info()) File "/srv/pandora/pandora/archive/models.py", line 148, in get_path_info if self.item: File "/srv/pandora/src/django/django/db/models/fields/related.py", line 350, in __get__ rel_obj = qs.get(**params) ```
j added the
backend
label 2014-07-29 15:13:21 +00:00
j added this to the 14.03 milestone 2014-07-29 15:13:21 +00:00
j self-assigned this 2014-07-29 15:13:21 +00:00
j added the
normal
defect
labels 2014-07-29 15:13:21 +00:00
Author
Owner

In []changeset:pandora,4265:

#!CommitTicketReference repository="" revision="pandora,4265"
reload stream from db before updating after encode, fixes #2442
In []changeset:pandora,4265: ``` #!CommitTicketReference repository="" revision="pandora,4265" reload stream from db before updating after encode, fixes #2442 ```
j added the
fixed
label 2014-07-29 15:43:41 +00:00
j closed this issue 2014-07-29 15:43:41 +00:00
Author
Owner

In []changeset:pandora,4267:

#!CommitTicketReference repository="" revision="pandora,4267"
really fix #2442
In []changeset:pandora,4267: ``` #!CommitTicketReference repository="" revision="pandora,4267" really fix #2442 ```
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: 0x2620/pandora#2442
No description provided.