jitsu import fails with StateChanged on local environment

Bug #1064767 reported by Sidnei da Silva
10
This bug affects 2 people
Affects Status Importance Assigned to Milestone
juju-jitsu
New
Undecided
Unassigned

Bug Description

sidnei@sidnei-laptop:~/src/ubuntuone/infra/puppet$ jitsu import --environment=local ~/src/canonical-marshal/precise/u1-updown/lcy02.json --repository=/home/sidnei/src/canonical-marshal
2012-10-09 20:53:43,879 juju.common:DEBUG Environment is initialized.
2012-10-09 20:53:44,029 jitsu.import:INFO Publishing charm local:precise/haproxy-23
2012-10-09 20:53:44,033 jitsu.import:INFO Publishing charm local:precise/apache2-31
2012-10-09 20:53:44,034 jitsu.import:INFO Publishing charm local:precise/haproxy-23
2012-10-09 20:53:44,036 jitsu.import:INFO Publishing charm local:precise/haproxy-23
2012-10-09 20:53:44,037 jitsu.import:INFO Publishing charm local:precise/u1-updown-190
2012-10-09 20:53:44,038 jitsu.import:INFO Publishing charm local:precise/squid-reverseproxy-0
2012-10-09 20:53:44,039 jitsu.import:INFO Publishing charm local:precise/memcached-27
Unhandled error in Deferred:
Unhandled Error
Traceback (most recent call last):
  File "/usr/lib/python2.7/dist-packages/twisted/internet/defer.py", line 397, in errback
    self._startRunCallbacks(fail)
  File "/usr/lib/python2.7/dist-packages/twisted/internet/defer.py", line 464, in _startRunCallbacks
    self._runCallbacks()
  File "/usr/lib/python2.7/dist-packages/twisted/internet/defer.py", line 551, in _runCallbacks
    current.result = callback(current.result, *args, **kw)
  File "/usr/lib/python2.7/dist-packages/twisted/internet/defer.py", line 1101, in gotResult
    _inlineCallbacks(r, g, deferred)
--- <exception caught here> ---
  File "/usr/lib/python2.7/dist-packages/twisted/internet/defer.py", line 1043, in _inlineCallbacks
    result = result.throwExceptionIntoGenerator(g)
  File "/usr/lib/python2.7/dist-packages/twisted/python/failure.py", line 382, in throwExceptionIntoGenerator
    return g.throw(self.type, self.value, self.tb)
  File "/usr/share/juju-jitsu/sub-commands/import", line 163, in run_one
    yield func(*args, **kw)
  File "/usr/lib/python2.7/dist-packages/twisted/internet/defer.py", line 1043, in _inlineCallbacks
    result = result.throwExceptionIntoGenerator(g)
  File "/usr/lib/python2.7/dist-packages/twisted/python/failure.py", line 382, in throwExceptionIntoGenerator
    return g.throw(self.type, self.value, self.tb)
  File "/usr/share/juju-jitsu/sub-commands/import", line 102, in load
    charm_states = yield publisher.publish()
  File "/usr/lib/python2.7/dist-packages/twisted/internet/defer.py", line 1045, in _inlineCallbacks
    result = g.send(result)
  File "/usr/lib/python2.7/dist-packages/juju/charm/publisher.py", line 123, in _eb_verify_duplicate
    raise StateChanged(msg)
juju.state.errors.StateChanged: State changed while operation was in progress

Revision history for this message
Sidnei da Silva (sidnei) wrote :

Subsequent import after the exception does not cause a new exception, however all machines are stuck in pending state.

Revision history for this message
Khris Richardson (khris-richardson) wrote :

I have reproduced this issue multiple times, and in each instance the JSON being imported by jitsu includes multiple services with the same charm, as is the case with this bug report...

2012-10-09 20:53:44,034 jitsu.import:INFO Publishing charm local:precise/haproxy-23
2012-10-09 20:53:44,036 jitsu.import:INFO Publishing charm local:precise/haproxy-23

Revision history for this message
Khris Richardson (khris-richardson) wrote :

Duplicate reduction of the charms being publishing seems to resolve this issue.

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.