[Sugar-devel] [PATCH sugar] Construct the published name based on the public key OLPC #10737
Sascha Silbe
sascha-ml-reply-to-2011-2 at silbe.org
Tue Mar 29 14:02:56 EDT 2011
Excerpts from Simon Schampijer's message of Tue Mar 29 18:37:19 +0200 2011:
Acked-by: Sascha Silbe <silbe at activitycentral.com>
If you care enough, some minor corrections would be:
> Limit the name to be only 8 characters maximum. The avahi
> service name has a 64 character limit. It consists of
> the room name the published-name and the host name.
^ add comma ^ s/-/ /
> + def _get_published_name(self):
> + """ Construct the published name based on the public key
^ Remove space
> + Limit the name to be only 8 characters maximum. The avahi
> + service name has a 64 character limit. It consists of
> + the room name the published-name and the host name.
See above.
> +
> + """
> + public_key_hash = sha1(get_profile().pubkey).hexdigest()
> + return public_key_hash[:8]
We should probably add a pubkey_hash property to sugar.profile.Profile.
But not this time. :)
Thanks for the patch!
Sascha
--
http://sascha.silbe.org/
http://www.infra-silbe.de/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 500 bytes
Desc: not available
URL: <http://lists.sugarlabs.org/archive/sugar-devel/attachments/20110329/8da7bb9b/attachment.pgp>
More information about the Sugar-devel
mailing list