Matrix no longer works w/ bundles from the store #36

Closed
petevg opened this Issue Dec 6, 2016 · 1 comment

Comments

Projects
None yet
2 participants
Collaborator

petevg commented Dec 6, 2016

The following invocation of matrix no longer works:

matrix tests/test_2.matrix

It fails with the following error:

Task(command='matrix.tasks.deploy', args={'version': 'current', 'entity': 'cs:bundle/wiki-simple'})
Traceback (most recent call last):
  File "/home/petevg/Code/matrix/matrix/model.py", line 163, in execute
    result = await self.execute_plugin(context, cmd, rule)
  File "/home/petevg/Code/matrix/matrix/model.py", line 180, in execute_plugin
    result = await cmd(context, rule, self, event)
  File "/home/petevg/Code/matrix/matrix/tasks/deploy.py", line 6, in deploy
    new_apps = await context.juju_model.deploy(str(context.config.path))
  File "/home/petevg/Code/matrix/.tox/py35/lib/python3.5/site-packages/juju/model.py", line 897, in deploy
    await client_facade.AddCharm(channel, entity_id)
  File "/home/petevg/Code/matrix/.tox/py35/lib/python3.5/site-packages/juju/client/facade.py", line 317, in wrapper
    reply = await f(*args, **kwargs)
  File "/home/petevg/Code/matrix/.tox/py35/lib/python3.5/site-packages/juju/client/_client.py", line 9371, in AddCharm
    reply = await self.rpc(msg)
  File "/home/petevg/Code/matrix/.tox/py35/lib/python3.5/site-packages/juju/client/facade.py", line 436, in rpc
    result = await self.connection.rpc(msg, encoder=TypeEncoder)
  File "/home/petevg/Code/matrix/.tox/py35/lib/python3.5/site-packages/juju/client/connection.py", line 93, in rpc
    raise JujuAPIError(result)
juju.errors.JujuAPIError: charm or bundle URL has invalid form: "/home/petevg/Code/matrix"

This is related to the refactor that allows us to skip specifying a bundle in a .matrix test. If intentional, this is fine, but we need to revise that test, and possibly allow a user to pass in a bundle name from the store as an arg (close if I'm just missing the arg).

Owner

johnsca commented Dec 6, 2016

The entity param to the deploy command has been dropped entirely, as Matrix now only ever deploys local bundles. In this case, it's defaulting to the current directory, which is not a bundle. So, a different path should be passed in via the --path (-p) arg, or matrix be run from a different directory.

johnsca added a commit that referenced this issue Dec 6, 2016

Improve error handling when run against invalid bundle
Also removes the `entity` param from missed test files.

Fixes #36

@petevg petevg closed this in #37 Dec 6, 2016

petevg added a commit that referenced this issue Dec 6, 2016

Improve error handling when run against invalid bundle (#37)
Also removes the `entity` param from missed test files.

Fixes #36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment