1
  7   ˆl–Ðz¾”*i?u8 p"¸ ©‹Fÿ‘äÇò 8à
ëO‰¶@ ÿ?Âƒh¹ÁÀ¿      1
  X   ˆl–ßi~”Ši?u@†à_¸ ©‹Fÿ“þ\qå›�p/H� -7³WüÿÃ{‹„„-i[D<†ªoZƒ›Ù«Ä692_‹I|¥Žƒî4ÃVŸÄÃ ´    ‹      }TKo›@>Ã¯˜HQXdÇJÎ)‘ª6úPÓ[É˜véî’Ørüß3ìƒGÒö`Œæù}ßÌµ
AiYf:º	3Á•†�E!±H5ÞI)$$ ñO[JdQê=—Ø¹¢ø&k±m+\à¾R+ŠNÕ�gÀÂ Ô(ÓM…ó0¨Ó¦AI/Ç0¨KÖJ‰<;Pø’ç%/õ�œ�Ò¢ùÆ}[-[ƒ½OaÉ-P¶DÝJŸá»u©�1‰JTO8' ¿0Ó>4(s`úÐ ÈÁ€³$�(oy¦KÁ£ØDz'Å³©ø“‚Mw}±	>JåeØv´ƒàºgŒ}mëÊE©îÓ—\c�’�hÆðòÚÉ@<†‹‹‰ó6�ëø?ØÖwû†hâVëQÞjZÀ!%´ä$\“em¤êjíÛ®Ös(„&ËùqTåDeØùÑÉ6vÄë�·]Ò½­4Íçáñ¦7šÍPoŒf´™ªßŠ‡ûC½ÕÂ»™)_!E«f�Ä0�<­ž¥Kÿ,8¾õÚ=(yñI´¼Ãuå=–„^ò-î­½‡Æqß…²~kÌPnnñº‚V‚Q:aª=3b²èl–�§ïúŽaX÷È0›T¦½¯ºØM�àùî@lŽIzKŸvìÊçÚMß-�Õ¢B^è�¹�!>°·ÄºÕ›~˜M‹-AR�f0Ê3ÇÈìrôAaÐ÷^Ê)r/s_’a2�–ßÈm[…5šY§Ïi9Œcñ”V-ºæÊƒ™Âcj?	ÌU˜Û!ÅCÊÑå¥3�&K¼³Tg;°zL„é<:Ùj;º‰Ò¶ÌßEu“jZµ›Æýèi¯~÷ˆ­õd4Îi˜9,sô÷a|ód˜Í_p¸�ñ6zš‰éo7Yó;Q
õzù§=4h       ˆÀ¿Å523_‘I|¥‰ÓMdœv ©ƒ†ü+=ÅÄ     ‹      Õ•QoÚ0Çßû)<?ì.	lhÔñÔ‘JC£€(Ó4M{0¶!V;r”}ú9$¨l­“:‰½ä.Éßw÷sœ;ò*™æ_§·èãün„¦Ÿ?Œ†„[ _:€džÔ/ºí ¸c„SçŠ>Àv»mo;mcW0ŸAêò¬¥³Š»¶pÓ+R=£Wˆ¤’	oqÊe’µ��È,˜µ+•�~Ý®!7ŠË²ò�Ì!—¹±»Æt{ ��ðb�°j#måw€3žJudŸšddaÄ®ª!ü'ù|Ø=[ìÓV®¥Ä¥hÃ2µÒ1v¦À”¨|…JËcŠ]Â"cú¡½RKŒXæbüm8˜|÷:piµš†R+—1~?ˆÇ×“8ÁtÌrŸ��ÖÜyÍ¦#V:”¡–JŠ³âûZ|¯~œ˜ÔšD–ÜªÂ)£Ÿ¤à�Q¹ÉÊ‚yÖ7ž µÇªZ"þ´Œÿ²Ó›Ùíxžgõ–ˆ*ÄSu/ñõ0�2+µC‰²’;¯mðê\¯õ¢,®·¨)ÞªUê0E¨…N*ÿ‚xi2!í1ó9ZUÚÀÜ8ÇuþVXDo[aØŠ}E—CÂç„ïPØë½K"ˆÑÿJÐ9t.æ­õƒ6[}ŒàËI„µÜøÓÚ¾€eŸÎ<³ÁAÓú	ì�zØý†õÐO    5   	ˆl–Ðz¾”*i?u8 p ¸”Å£�þB g]’>ðùÈƒh¹ÇÆÅ      	Normal
  5   ˆl–Ðz¾”*i?u8 p"¸TÅ£�þB g]iá¿#R—ùÉƒh¹ÈÇÆ      Normal
  5   ˆl–Ðz¾”*i?u8 p\ªbÑ¿�þB g]d`rG%óÊƒh¹ÉÈÇ      Normal
      ˆÆ‘äÇò 8à
ëOŠ0þÊƒh¹ÉÈÇ      1
     ˆÀ�þB g]’>ðùÊƒh¹ÉÈÇ      Normal
  5   ˆl–Ðz¾”*i?u8 p"¸TÅ£�þB g]iæÝ‚{ùËƒh¹ÊÉÈ      DMA32
  L   ˆl–Ðz¾”*i?u8 q \êbÑ¿�þB g\‘ÇÈÑoùÌƒh¹Ëa–Ðz¾”*i?u8 p"¸ÈTÅ£Ê      Normal
  A   ˆl–Ü4ý( ©”u( 	•íÀà™S�ÿ�þC#Ž,Ü¢#á�a	HçÎƒu±9Í_ŠI|¥�+Wé3ž¯ÀÌ f    # Copyright (C) 2007-2011 Canonical Ltd
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA

"""Directory lookup that uses Launchpad."""

from urllib.parse import urlsplit

from ... import (
    debug,
    errors,
    trace,
    transport,
    )
from ...urlutils import InvalidURL
from ...i18n import gettext

from .uris import (
    DEFAULT_INSTANCE,
    LAUNCHPAD_DOMAINS,
    LPNET_SERVICE_ROOT,
    )
from .account import get_lp_login


# As breezy.transport.remote may not be loaded yet, make sure bzr+ssh
# is counted as a netloc protocol.
transport.register_urlparse_netloc_protocol('bzr+ssh')
transport.register_urlparse_netloc_protocol('lp')
transport.register_urlparse_netloc_protocol('lp+bzr')


def _requires_launchpad_login(scheme, netloc, path, query,
                              fragment):
    """Does the URL require a Launchpad login in order to be reached?

    The URL is specified by its parsed components, as returned from
    urlsplit.
    """
    return (scheme in ('bzr+ssh', 'sftp')
            and (netloc.endswith('launchpad.net') or
                 netloc.endswith('launchpad.test')))


def _expand_user(path, url, lp_login):
    if path.startswith('~/'):
        if lp_login is None:
            raise InvalidURL(path=url,
                             extra='Cannot resolve "~" to your username.'
                             ' See "bzr help launchpad-login"')
 