<div dir="ltr">For what it's worth, I've already unpromulgated the <a href="http://shelr.tv">shelr.tv</a> charm and re-promulgated the new shelrtv charm in order to rectify this error. This might explain why the store is no longer returning anything for cs:precise/<a href="http://shelr.tv">shelr.tv</a></div>
<div class="gmail_extra"><br><br><div class="gmail_quote">On Tue, Mar 26, 2013 at 11:47 AM, Abel Deuring <span dir="ltr"><<a href="mailto:abel.deuring@canonical.com" target="_blank">abel.deuring@canonical.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="im">On <a href="tel:26.03.2013%2015" value="+12603201315">26.03.2013 15</a>:41, Gustavo Niemeyer wrote:<br>

> On Tue, Mar 26, 2013 at 11:35 AM, Abel Deuring<br>
> <<a href="mailto:abel.deuring@canonical.com">abel.deuring@canonical.com</a>> wrote:<br>
>> well, we retrieve the data about charms from Launchpad. My question was<br>
>> simply: Is it worth to change charmworld so that it can properly deal<br>
>> with the name <a href="http://shelr.tv" target="_blank">shelr.tv</a>, or should the name be fixed because it might<br>
>> also be unusable in juju-core?<br>
><br>
> That's exactly the point I'm trying to make: everything that is not in<br>
> the charm store is not usable. It should filter based on whether the<br>
> charm exists or not, rather than whether it can import it from<br>
> Launchpad directly.<br>
<br>
</div>Divergence betwen LP and the charm store might be an issue (though<br>
charmworld checks the main store too), but that's not my main point,<br>
neither is importing from LP an issue with <a href="http://shelr.tv" target="_blank">shelr.tv</a>. The problem we have<br>
with this charm is that we use MongoDB records like {'_id':<br>
'cs:<long-path>/<a href="http://shelr.tv" target="_blank">shelr.tv</a>', ...}<br>
<br>
i.e., the charm name is used in the ID. But dots should not be used in<br>
MongoDB keys because queries like collection.find({'a.b': 'c'}) search<br>
for records like {'a': {'b': 'c'}}. And more recent versions of pymongo<br>
raise an error when you try to insert or update a record with a dot in a<br>
key.<br>
<div class="im"><br>
><br>
> There's an existing API in the charm store that gives you [1] precise<br>
> information about what exists, including the actual digest that was<br>
> imported.<br>
<br>
</div>ok, one step forward:<br>
<br>
<a href="https://store.juju.ubuntu.com/charm-info?charms=cs:precise/shelrtv&stats=0" target="_blank">https://store.juju.ubuntu.com/charm-info?charms=cs:precise/shelrtv&stats=0</a><br>
<br>
returns some reasonable data (and a related charm is indeed available), but<br>
<br>
<a href="https://store.juju.ubuntu.com/charm-info?charms=cs:precise/shelr.tv&stats=0" target="_blank">https://store.juju.ubuntu.com/charm-info?charms=cs:precise/shelr.tv&stats=0</a><br>
<br>
returns an error:<br>
<br>
{"cs:precise/<a href="http://shelr.tv" target="_blank">shelr.tv</a>":{"revision":0,"errors":["charm URL has invalid<br>
charm name: \"cs:precise/<a href="http://shelr.tv" target="_blank">shelr.tv</a>\""]}}<br>
<br>
So we have a possible name inconsistency between LP and the charm<br>
store... Can we assume that dots (and perhaps other other symbols) are<br>
simply removed when an LP product name is mapped to a charm name? (A<br>
quick "grep -r shelrtv" in a local copy of<br>
lp:~charmers/charms/precise/<a href="http://shelr.tv/trunk" target="_blank">shelr.tv/trunk</a> returned no results.)<br>
<span class="HOEnZb"><font color="#888888"><br>
Abel<br>
</font></span><div class="HOEnZb"><div class="h5"><br>
--<br>
Juju mailing list<br>
<a href="mailto:Juju@lists.ubuntu.com">Juju@lists.ubuntu.com</a><br>
Modify settings or unsubscribe at: <a href="https://lists.ubuntu.com/mailman/listinfo/juju" target="_blank">https://lists.ubuntu.com/mailman/listinfo/juju</a><br>
</div></div></blockquote></div><br></div>