juju / amulet

Testing harness and tools for Juju Charms
Other
17 stars 33 forks source link

Error loading metadata.yaml with non-ascii chars #130

Open tvansteenburgh opened 8 years ago

tvansteenburgh commented 8 years ago

From a test run of lp:~jose/charms/trusty/pubphoto/trunk

DEBUG:runner:call ['/tmp/bundletester-KdHqrm/pubphoto/tests/10-deploy'] (cwd: /tmp/bundletester-KdHqrm/pubphoto)
DEBUG:runner:/usr/lib/python3/dist-packages/path.py:1719: DeprecationWarning: path is deprecated. Use Path instead.
DEBUG:runner:  warnings.warn(msg, DeprecationWarning)
DEBUG:runner:E
DEBUG:runner:======================================================================
DEBUG:runner:ERROR: setUpClass (__main__.TestDeployment)
DEBUG:runner:----------------------------------------------------------------------
DEBUG:runner:Traceback (most recent call last):
DEBUG:runner:  File "/tmp/bundletester-KdHqrm/pubphoto/tests/10-deploy", line 13, in setUpClass
DEBUG:runner:    cls.deployment.add('pubphoto')
DEBUG:runner:  File "/usr/lib/python3/dist-packages/amulet/deployer.py", line 184, in add
DEBUG:runner:    service_name, charm, branch=branch, series=series or self.series)
DEBUG:runner:  File "/usr/lib/python3/dist-packages/amulet/charm.py", line 57, in fetch
DEBUG:runner:    series=series)
DEBUG:runner:  File "/usr/lib/python3/dist-packages/amulet/charm.py", line 40, in get_charm
DEBUG:runner:    return LocalCharm(charm_path, series)
DEBUG:runner:  File "/usr/lib/python3/dist-packages/amulet/charm.py", line 83, in __init__
DEBUG:runner:    self._raw = self._load(os.path.join(path, 'metadata.yaml'))
DEBUG:runner:  File "/usr/lib/python3/dist-packages/amulet/charm.py", line 110, in _load
DEBUG:runner:    data = yaml.safe_load(f.read())
DEBUG:runner:  File "/usr/lib/python3.4/encodings/ascii.py", line 26, in decode
DEBUG:runner:    return codecs.ascii_decode(input, self.errors)[0]
DEBUG:runner:UnicodeDecodeError: 'ascii' codec can't decode byte 0xc3 in position 83: ordinal not in range(128)
DEBUG:runner:
DEBUG:runner:----------------------------------------------------------------------
DEBUG:runner:Ran 0 tests in 0.204s
DEBUG:runner:
DEBUG:runner:FAILED (errors=1)
DEBUG:runner:Exit Code: 1
DEBUG:bundletester.utils:Updating JUJU_ENV: "charm-testing-aws" -> ""
DEBUG:bundletester.fetchers:bzr revision-info: 1 jose@ubuntu.com-20160425170434-2f3bc23vit8wqtik
marcoceppi commented 8 years ago

I don't think Juju will be able to deploy this either though, have we tried?

tvansteenburgh commented 8 years ago

@marcoceppi Yep, just deployed it (juju2).

marcoceppi commented 8 years ago

It must only be the name field