resuming is broken in sstream-mirror

Bug #1237658 reported by Scott Moser
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
simplestreams
Fix Released
Medium
Unassigned
simplestreams (Ubuntu)
Fix Released
Medium
Unassigned

Bug Description

$ rm -Rf out.d/ ;
$ sstream-mirror --max=1 http://maas.ubuntu.com/images/ephemeral/releases/streams/v1/index.json out.d/
wait 10 seconds
hit Ctrl-C
...
  File "/usr/lib/python2.7/dist-packages/simplestreams/objectstores/__init__.py", line 113, in insert
    wfp.write(buf)
KeyboardInterrupt

Try it again
$ sstream-mirror --max=1 http://maas.ubuntu.com/images/ephemeral/releases/streams/v1/index.json out.d/
Traceback (most recent call last):
  File "/usr/bin/sstream-mirror", line 93, in <module>
    main()
  File "/usr/bin/sstream-mirror", line 89, in main
    tmirror.sync(smirror, initial_path)
  File "/usr/lib/python2.7/dist-packages/simplestreams/mirrors/__init__.py", line 85, in sync
    return self.sync_index(reader, path, data, content)
  File "/usr/lib/python2.7/dist-packages/simplestreams/mirrors/__init__.py", line 228, in sync_index
    self.sync(reader, path=epath)
  File "/usr/lib/python2.7/dist-packages/simplestreams/mirrors/__init__.py", line 83, in sync
    return self.sync_products(reader, path, data, content)
  File "/usr/lib/python2.7/dist-packages/simplestreams/mirrors/__init__.py", line 302, in sync_products
    self.insert_item(item, src, target, pgree, ipath_cs)
  File "/usr/lib/python2.7/dist-packages/simplestreams/mirrors/__init__.py", line 386, in insert_item
    size=data.get('size'))
  File "/usr/lib/python2.7/dist-packages/simplestreams/objectstores/__init__.py", line 104, in insert
    reader.set_start_pos(os.path.getsize(partfile))
  File "/usr/lib/python2.7/dist-packages/simplestreams/contentsource.py", line 149, in set_start_pos
    raise Exception("can't set start pos after open()")
Exception: can't set start pos after open()

ProblemType: Bug
DistroRelease: Ubuntu 13.10
Package: simplestreams 0.1.0~bzr313-0ubuntu1
ProcVersionSignature: User Name 3.11.0-12.18-generic 3.11.3
Uname: Linux 3.11.0-12-generic x86_64
ApportVersion: 2.12.5-0ubuntu1
Architecture: amd64
Date: Wed Oct 9 20:37:38 2013
Ec2AMI: ami-000005a3
Ec2AMIManifest: FIXME
Ec2AvailabilityZone: nova
Ec2InstanceType: m1.large
Ec2Kernel: aki-0000022a
Ec2Ramdisk: ari-0000022a
MarkForUpload: True
PackageArchitecture: all
ProcEnviron:
 TERM=screen
 PATH=(custom, no user)
 XDG_RUNTIME_DIR=<set>
 LANG=en_US.UTF-8
 SHELL=/bin/bash
SourcePackage: simplestreams
UpgradeStatus: No upgrade log present (probably fresh install)

Revision history for this message
Scott Moser (smoser) wrote :
Revision history for this message
Scott Moser (smoser) wrote :

fixed in 315.

Changed in simplestreams (Ubuntu):
status: New → Fix Committed
importance: Undecided → Medium
Changed in simplestreams:
status: New → Fix Committed
importance: Undecided → Medium
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package simplestreams - 0.1.0~bzr315-0ubuntu1

---------------
simplestreams (0.1.0~bzr315-0ubuntu1) saucy; urgency=low

  * New upstream snapshot.
    * fix interpreter written on sstream-sync, sstream-query and
      sstream-mirror. It should be python3, not python2.7. (LP: #1237637)
    * simplestreams/mirrors/__init__.py: fix bug causing resumed downloads
      to stack trace (LP: #1237658)
 -- Scott Moser <email address hidden> Wed, 09 Oct 2013 17:30:23 -0400

Changed in simplestreams (Ubuntu):
status: Fix Committed → Fix Released
Scott Moser (smoser)
description: updated
description: updated
Revision history for this message
Scott Moser (smoser) wrote : Fixed in simplestreams version 0.1.0.

This bug is believed to be fixed in simplestreams in version 0.1.0. If this is still a problem for you, please make a comment and set the state back to New

Thank you.

Changed in simplestreams:
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.