Merge lp://staging/~facundo/ubuntuone-client/lr-dont-delete-partial-nopartialfile into lp://staging/ubuntuone-client

Proposed by Facundo Batista
Status: Merged
Approved by: dobey
Approved revision: 736
Merged at revision: 738
Proposed branch: lp://staging/~facundo/ubuntuone-client/lr-dont-delete-partial-nopartialfile
Merge into: lp://staging/ubuntuone-client
Diff against target: 216 lines (+151/-6)
2 files modified
tests/syncdaemon/test_fsm.py (+125/-2)
ubuntuone/syncdaemon/filesystem_manager.py (+26/-4)
To merge this branch: bzr merge lp://staging/~facundo/ubuntuone-client/lr-dont-delete-partial-nopartialfile
Reviewer Review Type Date Requested Status
Lucio Torre (community) Approve
Guillermo Gonzalez Approve
Review via email: mp+38834@code.staging.launchpad.net

Commit message

Handle better errors on partial creation. (LP: #657195, LP: #662660)

Description of the change

Handle better errors on partial creation.

This has two sides:

- Leave the node in a better state if *any* error happens when touching disk: in this case, I moved the MD handling before the filesystem handling. So, from now, if something bad happens when creating the partial in the disk, the node will still be in SERVER state, and LR will re-download it.

- Support too long filenames: for this, specific code were added to the filename handling when the file is created: we trim the filename until the filesystem stops giving that error to us.

As the filename may be trimmed according to filesystem errors, it's not fully predictable any more. So, when that happens, it's stored in the metadata object.

Tests included for everything.

To post a comment you must log in.
Revision history for this message
Guillermo Gonzalez (verterok) wrote :

looks good, tests pass.

review: Approve
736. By Facundo Batista

Make the filename length platform agnostic in the test

Revision history for this message
Lucio Torre (lucio.torre) :
review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
The diff is not available at this time. You can reload the page or download it.

Subscribers

People subscribed via source and target branches