§
    cÌc§B  ã                   óº  — d Z ddlZddlmZmZ ddlmZmZmZm	Z	  G d„ dej
        ¦  «        Z G d„ d	ej
        ¦  «        Z G d
„ dej
        ¦  «        Z G d„ dej
        ¦  «        Z G d„ dej
        ¦  «        Z G d„ dej
        ¦  «        Z G d„ dej        ¦  «        Z G d„ dej
        ¦  «        Z G d„ dej
        ¦  «        Z G d„ dej
        ¦  «        Z G d„ dej
        ¦  «        Z G d„ d¦  «        Z G d„ d¦  «        Z G d „ d!¦  «        Zd"„ Zd,d#„Zd$efd%„Zd,d&eee                  fd'„Zd(„ Zd)ed*dfd+„Z  ej!        eee         f         ¦   «         Z"dS )-z&Helper functions for proposing merges.é    N)ÚOptionalÚTypeé   )ÚerrorsÚhooksÚregistryÚurlutilsc                   ó   — e Zd ZdZd„ ZdS )ÚNoSuchProjectz$Project does not exist: %(project)s.c                 óR   — t           j                             | ¦  «         || _        d S ©N)r   ÚBzrErrorÚ__init__Úproject)Úselfr   s     ú./usr/lib/python3/dist-packages/breezy/forge.pyr   zNoSuchProject.__init__"   s#   € ÝŒ× Ò  Ñ&Ô&Ð&ØˆŒˆˆó    N©Ú__name__Ú
__module__Ú__qualname__Ú_fmtr   © r   r   r   r      s(   € € € € € à1€Dðð ð ð ð r   r   c                   ó   — e Zd ZdZdd„ZdS )ÚMergeProposalExistsz)A merge proposal already exists: %(url)s.Nc                 ó`   — t           j                             | ¦  «         || _        || _        d S r   )r   r   r   ÚurlÚexisting_proposal)r   r   r   s      r   r   zMergeProposalExists.__init__+   s-   € ÝŒ× Ò  Ñ&Ô&Ð&ØˆŒØ!2ˆÔÐÐr   r   r   r   r   r   r   r   '   s-   € € € € € à6€Dð3ð 3ð 3ð 3ð 3ð 3r   r   c                   ó   — e Zd ZdZd„ ZdS )ÚUnsupportedForgez"No supported forge for %(branch)s.c                 óR   — t           j                             | ¦  «         || _        d S r   )r   r   r   Úbranch©r   r"   s     r   r   zUnsupportedForge.__init__5   s#   € ÝŒ× Ò  Ñ&Ô&Ð&ØˆŒˆˆr   Nr   r   r   r   r    r    1   s(   € € € € € à/€Dðð ð ð ð r   r    c                   ó   — e Zd ZdZdS )ÚReopenFailedz/Reopening the merge proposal failed: %(error)s.N©r   r   r   r   r   r   r   r%   r%   :   s   € € € € € à<€D€D€Dr   r%   c                   ó   — e Zd ZdZdS )ÚTitleUnsupportedz3The merge proposal %(mp)s does not support a title.Nr&   r   r   r   r(   r(   ?   s   € € € € € à@€D€D€Dr   r(   c                   ó   — e Zd ZdZdS )ÚAutoMergeUnsupportedz5The merge proposal %(mp)s does not support automerge.Nr&   r   r   r   r*   r*   D   s   € € € € € àB€D€D€Dr   r*   c                   ó   — e Zd ZdZd„ ZdS )ÚProposeMergeHooksz)Hooks for proposing a merge on Launchpad.c                 ó®   — t           j                             | t          d¦  «         |                      ddd¦  «         |                      ddd¦  «         d S )NzProposer.hooksÚget_prerequisitez6Return the prerequisite branch for proposing as merge.)é   r   Úmerge_proposal_bodyz6Return an initial body for the merge proposal message.)r   ÚHooksr   r   Úadd_hook©r   s    r   r   zProposeMergeHooks.__init__L   sm   € ÝŒ×Ò˜T¥8Ð-=Ñ>Ô>Ð>Ø�ŠØØDÀfñ	Nô 	Nð 	Nð 	�ŠØ!ØDÀfñ	Nô 	Nð 	Nð 	Nð 	Nr   N©r   r   r   Ú__doc__r   r   r   r   r,   r,   I   s.   € € € € € Ø3Ð3ðNð Nð Nð Nð Nr   r,   c                   ó   — e Zd ZdZdZd„ ZdS )ÚLabelsUnsupportedz#Labels not supported by this forge.z&Labels are not supported by %(forge)r.c                 óR   — t           j                             | ¦  «         || _        d S r   ©r   r   r   Úforge©r   r:   s     r   r   zLabelsUnsupported.__init__[   ó#   € ÝŒ× Ò  Ñ&Ô&Ð&ØˆŒ
ˆ
ˆ
r   N©r   r   r   r5   r   r   r   r   r   r7   r7   V   s.   € € € € € Ø-Ð-à3€Dðð ð ð ð r   r7   c                   ó   — e Zd ZdZd„ ZdS )ÚPrerequisiteBranchUnsupportedz0Prerequisite branch not supported by this forge.c                 óR   — t           j                             | ¦  «         || _        d S r   r9   r;   s     r   r   z&PrerequisiteBranchUnsupported.__init__c   r<   r   Nr4   r   r   r   r?   r?   `   s)   € € € € € Ø:Ð:ðð ð ð ð r   r?   c                   ó   — e Zd ZdZdZd„ ZdS )ÚForgeLoginRequiredz(Action requires forge login credentials.z7Action requires credentials for hosting site %(forge)r.c                 óR   — t           j                             | ¦  «         || _        d S r   r9   r;   s     r   r   zForgeLoginRequired.__init__m   r<   r   Nr=   r   r   r   rB   rB   h   s.   € € € € € Ø2Ð2àF€Dðð ð ð ð r   rB   c                   ó   — e Zd ZdZdZd„ ZdS )ÚSourceNotDerivedFromTargetz0Source branch is not derived from target branch.zCSource %(source_branch)r not derived from target %(target_branch)r.c                 óJ   — t           j                             | ||¬¦  «         d S )N©Úsource_branchÚtarget_branch)r   r   r   ©r   rH   rI   s      r   r   z#SourceNotDerivedFromTarget.__init__x   s3   € ÝŒ× Ò Ø Ø'ð 	!ñ 	)ô 	)ð 	)ð 	)ð 	)r   Nr=   r   r   r   rE   rE   r   s0   € € € € € Ø:Ð:ð(€Dð)ð )ð )ð )ð )r   rE   c                   ó¸   — e Zd ZU dZeed<   dd„Zd„ Zd„ Zd„ Z	d„ Z
d	„ Zd
„ Zd„ Zddœd„Zd„ Zddœd„Zd„ Zd„ Zd„ Zd„ Zd„ Zd„ Zdd„Zd„ Zd„ Zd„ Zd„ Zd„ ZdS )ÚMergeProposalzAA merge proposal.

    :ivar url: URL for the merge proposal
    Úsupports_auto_mergeNc                 ó   — || _         d S r   )r   ©r   r   s     r   r   zMergeProposal.__init__†   s   € ØˆŒˆˆr   c                 ó*   — t          | j        ¦  «        ‚r   ©ÚNotImplementedErrorÚget_web_urlr3   s    r   rS   zMergeProposal.get_web_url‰   s   € Ý! $Ô"2Ñ3Ô3Ð3r   c                 ó*   — t          | j        ¦  «        ‚)z*Get the description of the merge proposal.)rR   Úget_descriptionr3   s    r   rU   zMergeProposal.get_descriptionŒ   ó   € å! $Ô"6Ñ7Ô7Ð7r   c                 ó*   — t          | j        ¦  «        ‚)z*Set the description of the merge proposal.)rR   Úset_description)r   Údescriptions     r   rX   zMergeProposal.set_description�   rV   r   c                 ó*   — t          | j        ¦  «        ‚©zGet the title.)rR   Ú	get_titler3   s    r   r\   zMergeProposal.get_title”   ó   € å! $¤.Ñ1Ô1Ð1r   c                 ó*   — t          | j        ¦  «        ‚r[   )rR   Ú	set_title)r   Útitles     r   r_   zMergeProposal.set_title˜   r]   r   c                 ó*   — t          | j        ¦  «        ‚)z Get the proposed commit message.)rR   Úget_commit_messager3   s    r   rb   z MergeProposal.get_commit_messageœ   ó   € å! $Ô"9Ñ:Ô:Ð:r   c                 ó*   — t          | j        ¦  «        ‚)zSet the propose commit message.)rR   Úset_commit_message)r   Úcommit_messages     r   re   z MergeProposal.set_commit_message    rc   r   )Úpreferred_schemesc                ó*   — t          | j        ¦  «        ‚)zReturn the source branch.)rR   Úget_source_branch_url©r   rg   s     r   ri   z#MergeProposal.get_source_branch_url¤   ó   € å! $Ô"<Ñ=Ô=Ð=r   c                 ó*   — t          | j        ¦  «        ‚)z1Return the latest revision for the source branch.)rR   Úget_source_revisionr3   s    r   rm   z!MergeProposal.get_source_revision¨   s   € å! $Ô":Ñ;Ô;Ð;r   c                ó*   — t          | j        ¦  «        ‚)zReturn the target branch.)rR   Úget_target_branch_urlrj   s     r   ro   z#MergeProposal.get_target_branch_url¬   rk   r   c                 ó*   — t          | j        ¦  «        ‚)zSet the target branch name.)rR   Úset_target_branch_namer3   s    r   rq   z$MergeProposal.set_target_branch_name°   s   € å! $Ô"=Ñ>Ô>Ð>r   c                 ó*   — t          | j        ¦  «        ‚r   )rR   Úget_source_projectr3   s    r   rs   z MergeProposal.get_source_project´   ó   € Ý! $Ô"9Ñ:Ô:Ð:r   c                 ó*   — t          | j        ¦  «        ‚r   )rR   Úget_target_projectr3   s    r   rv   z MergeProposal.get_target_project·   rt   r   c                 ó*   — t          | j        ¦  «        ‚)z.Close the merge proposal (without merging it).)rR   Úcloser3   s    r   rx   zMergeProposal.closeº   ó   € å! $¤*Ñ-Ô-Ð-r   c                 ó*   — t          | j        ¦  «        ‚)z2Check whether this merge proposal has been merged.)rR   Ú	is_mergedr3   s    r   r{   zMergeProposal.is_merged¾   r]   r   c                 ó*   — t          | j        ¦  «        ‚)zqCheck whether this merge proposal is closed

        This can either mean that it is merged or rejected.
        )rR   Ú	is_closedr3   s    r   r}   zMergeProposal.is_closedÂ   s   € õ
 " $¤.Ñ1Ô1Ð1r   Fc                 ó*   — t          | j        ¦  «        ‚)zMerge this merge proposal.)rR   Úmerge)r   rf   Úautos      r   r   zMergeProposal.mergeÉ   ry   r   c                 ó*   — t          | j        ¦  «        ‚)zjCan this merge proposal be merged?

        The answer to this can be no if e.g. it has conflics.
        )rR   Úcan_be_mergedr3   s    r   r‚   zMergeProposal.can_be_mergedÍ   s   € õ
 " $Ô"4Ñ5Ô5Ð5r   c                 ó*   — t          | j        ¦  «        ‚)z4If this proposal was merged, who merged it.
        )rR   Úget_merged_byr3   s    r   r„   zMergeProposal.get_merged_byÔ   ó   € õ " $Ô"4Ñ5Ô5Ð5r   c                 ó*   — t          | j        ¦  «        ‚)z9If this proposal was merged, when it was merged.
        )rR   Úget_merged_atr3   s    r   r‡   zMergeProposal.get_merged_atÙ   r…   r   c                 ó*   — t          | j        ¦  «        ‚)zaPost a comment on the merge proposal.

        Args:
          body: Body of the comment
        )rR   Úpost_comment)r   Úbodys     r   r‰   zMergeProposal.post_commentÞ   s   € õ " $Ô"3Ñ4Ô4Ð4r   c                 ó*   — t          | j        ¦  «        ‚)zReopen this merge proposal.)rR   Úreopenr3   s    r   rŒ   zMergeProposal.reopenæ   s   € å! $¤+Ñ.Ô.Ð.r   r   )NF)r   r   r   r5   ÚboolÚ__annotations__r   rS   rU   rX   r\   r_   rb   re   ri   rm   ro   rq   rs   rv   rx   r{   r}   r   r‚   r„   r‡   r‰   rŒ   r   r   r   rL   rL   ~   s¯  € € € € € € ðð ð
 ÐÐÑðð ð ð ð4ð 4ð 4ð8ð 8ð 8ð8ð 8ð 8ð2ð 2ð 2ð2ð 2ð 2ð;ð ;ð ;ð;ð ;ð ;ð :>ð >ð >ð >ð >ð >ð<ð <ð <ð :>ð >ð >ð >ð >ð >ð?ð ?ð ?ð;ð ;ð ;ð;ð ;ð ;ð.ð .ð .ð2ð 2ð 2ð2ð 2ð 2ð.ð .ð .ð .ð6ð 6ð 6ð6ð 6ð 6ð
6ð 6ð 6ð
5ð 5ð 5ð/ð /ð /ð /ð /r   rL   c                   ó\   — e Zd ZdZ e¦   «         Zd„ Zd„ Zd„ Z	 	 	 	 	 d	de	e
         fd„ZdS )
ÚMergeProposalBuilderz}Merge proposal creator.

    :param source_branch: Branch to propose for merging
    :param target_branch: Target branch
    c                 ó"   — || _         || _        d S r   rG   rJ   s      r   r   zMergeProposalBuilder.__init__ô   s   € Ø*ˆÔØ*ˆÔÐÐr   c                 ó*   — t          | j        ¦  «        ‚)z]Get a body for the proposal for the user to modify.

        :return: a str or None.
        )rR   Úget_initial_bodyr3   s    r   r“   z%MergeProposalBuilder.get_initial_bodyø   ó   € õ
 " $Ô"7Ñ8Ô8Ð8r   c                 ó*   — t          | j        ¦  «        ‚)z>Determine the initial comment for the merge proposal.
        )rR   Úget_infotextr3   s    r   r–   z!MergeProposalBuilder.get_infotextÿ   s   € õ " $Ô"3Ñ4Ô4Ð4r   NFÚdelete_source_after_mergec
                 ó*   — t          | j        ¦  «        ‚)aØ  Create a proposal to merge a branch for merging.

        Args:
          description: Description for the merge proposal
          reviewers: Optional list of people to ask reviews from
          labels: Labels to attach to the proposal
          prerequisite_branch: Optional prerequisite branch
          commit_message: Optional commit message
          work_in_progress:
            Whether this merge proposal is still a work-in-progress
          allow_collaboration:
            Whether to allow changes to the branch from the target branch
            maintainer(s)
          delete_after_merge: Whether to delete the source branch after it
            has been merged
        Returns: A `MergeProposal` object
        )rR   Úcreate_proposal)
r   rY   r`   Ú	reviewersÚlabelsÚprerequisite_branchrf   Úwork_in_progressÚallow_collaborationr—   s
             r   r™   z$MergeProposalBuilder.create_proposal  s   € õ, " $Ô"6Ñ7Ô7Ð7r   )NNNNNFFN)r   r   r   r5   r,   r   r   r“   r–   r   r�   r™   r   r   r   r�   r�   ë   s•   € € € € € ðð ð ÐÑÔ€Eð+ð +ð +ð9ð 9ð 9ð5ð 5ð 5ð
 BFØ9=Ø'+ØDIØDHð	8ð 8ð 4<¸D´>ð	8ð 8ð 8ð 8ð 8ð 8r   r�   c                   ó*  — e Zd ZU dZeed<   eed<   ed„ ¦   «         Zeed<   eed<   eed<   dZ	eed	<   	 	 	 dd„Z
d d„Zd„ Zd„ Zd„ Zd!d„Zd„ Zd„ Zed"d„¦   «         Zed„ ¦   «         Zed"d„¦   «         Zd#d„Zd"d„Zd„ Zd„ Zed„ ¦   «         Zd„ Zd„ Zd
S )$ÚForgezA hosting site manager.
    Úsupports_merge_proposal_labelsÚsupports_merge_proposal_titlec                 ó\   — d                      t          | ¦  «        j        | j        ¦  «        S )zName of this instance.z{} at {})ÚformatÚtyper   Úbase_urlr3   s    r   Únamez
Forge.name'  s%   € ð × Ò ¥ d¡¤Ô!4°d´mÑDÔDÐDr   Ú&supports_merge_proposal_commit_messager¦   Ú!merge_proposal_description_formatFÚsupports_allow_collaborationNTc
                 ó*   — t          | j        ¦  «        ‚)a>  Publish a branch to the site, derived from base_branch.

        :param base_branch: branch to derive the new branch from
        :param new_branch: branch to publish
        :return: resulting branch, public URL
        :raise ForgeLoginRequired: Action requires a forge login, but none is
            known.
        )rR   Úpublish_derived)
r   Ú
new_branchÚbase_branchr§   r   ÚownerÚrevision_idÚ	overwriteÚallow_lossyÚtag_selectors
             r   r¬   zForge.publish_derived;  s   € õ " $Ô"6Ñ7Ô7Ð7r   c                 ó*   — t          | j        ¦  «        ‚)z)Get a derived branch ('a fork').
        )rR   Úget_derived_branch)r   r®   r§   r   r¯   rg   s         r   rµ   zForge.get_derived_branchH  s   € õ " $Ô"9Ñ:Ô:Ð:r   c                 ó*   — t          | j        ¦  «        ‚)zGet the push URL for a branch.)rR   Úget_push_urlr#   s     r   r·   zForge.get_push_urlM  ó   € å! $Ô"3Ñ4Ô4Ð4r   c                 ó*   — t          | j        ¦  «        ‚)z%Get the web viewing URL for a branch.rQ   r#   s     r   rS   zForge.get_web_urlQ  s   € å! $Ô"2Ñ3Ô3Ð3r   c                 ó*   — t          | j        ¦  «        ‚)zõGet a merge proposal creator.

        :note: source_branch does not have to be hosted by the forge.

        :param source_branch: Source branch
        :param target_branch: Target branch
        :return: A MergeProposalBuilder object
        )rR   Úget_proposerrJ   s      r   r»   zForge.get_proposerU  s   € õ " $Ô"3Ñ4Ô4Ð4r   Úopenc                 ó*   — t          | j        ¦  «        ‚)a  Get the merge proposals for a specified branch tuple.

        :param source_branch: Source branch
        :param target_branch: Target branch
        :param status: Status of proposals to iterate over
        :return: Iterate over MergeProposal object
        )rR   Úiter_proposals)r   rH   rI   Ústatuss       r   r¾   zForge.iter_proposals`  s   € õ " $Ô"5Ñ6Ô6Ð6r   c                 ó*   — t          | j        ¦  «        ‚)z»Retrieve a branch proposal by URL.

        :param url: Merge proposal URL.
        :return: MergeProposal object
        :raise UnsupportedForge: Forge does not support this URL
        )rR   Úget_proposal_by_urlrO   s     r   rÁ   zForge.get_proposal_by_urlj  s   € õ " $Ô":Ñ;Ô;Ð;r   c                 ó*   — t          | j        ¦  «        ‚)z-Return true if this forge hosts given branch.)rR   Úhostsr#   s     r   rÃ   zForge.hostss  ry   r   c                 ó*   — t          | j        ¦  «        ‚)zDCreate a Forge object if this forge knows about a hostname.
        )rR   Úprobe_from_hostname)ÚclsÚhostnameÚpossible_transportss      r   rÅ   zForge.probe_from_hostnamew  s   € õ " #Ô"9Ñ:Ô:Ð:r   c                 ón   — t          j        |j        ¦  «        }|                      ||j        g¬¦  «        S )z9Create a Forge object if this forge knows about a branch.©rÈ   )r	   Ústrip_segment_parametersÚuser_urlÚprobe_from_urlÚcontrol_transport)rÆ   r"   r   s      r   Úprobe_from_branchzForge.probe_from_branch}  sA   € õ Ô/°´Ñ@Ô@ˆØ×!Ò!Ø fÔ&>Ð%?ð "ñ Aô Að 	Ar   c                 óx   — t           j                             |¦  «        j        }|                      ||¬¦  «        S )z6Create a Forge object if this forge knows about a URL.rÊ   )r	   ÚURLÚfrom_stringÚhostrÅ   )rÆ   r   rÈ   rÇ   s       r   rÍ   zForge.probe_from_url„  s6   € õ ”<×+Ò+¨CÑ0Ô0Ô5ˆØ×&Ò& xÐEXÐ&ÑYÔYÐYr   c                 ó*   — t          | j        ¦  «        ‚)a¢  Iterate over the proposals created by the currently logged in user.

        :param status: Only yield proposals with this status
            (one of: 'open', 'closed', 'merged', 'all')
        :param author: Name of author to query (defaults to current user)
        :return: Iterator over MergeProposal objects
        :raise ForgeLoginRequired: Action requires a forge login, but none is
            known.
        )rR   Úiter_my_proposals)r   r¿   Úauthors      r   rÕ   zForge.iter_my_proposalsŠ  s   € õ " $Ô"8Ñ9Ô9Ð9r   c                 ó*   — t          | j        ¦  «        ‚)z°Iterate over the currently logged in users' forks.

        :param owner: Name of owner to query (defaults to current user)
        :return: Iterator over project_name
        )rR   Úiter_my_forks)r   r¯   s     r   rØ   zForge.iter_my_forks–  s   € õ " $Ô"4Ñ5Ô5Ð5r   c                 ó*   — t          | j        ¦  «        ‚)zDelete a project.
        )rR   Údelete_project©r   r§   s     r   rÚ   zForge.delete_projectž  ó   € õ " $Ô"5Ñ6Ô6Ð6r   c                 ó*   — t          | j        ¦  «        ‚)zCreate a project.
        )rR   Úcreate_projectrÛ   s     r   rÞ   zForge.create_project£  rÜ   r   c                 ó*   — t          | j        ¦  «        ‚)z=Iterate instances.

        :return: Forge instances
        )rR   Úiter_instances)rÆ   s    r   rà   zForge.iter_instances¨  s   € õ " #Ô"4Ñ5Ô5Ð5r   c                 ó*   — t          | j        ¦  «        ‚)zoRetrieve the name of the currently logged in user.

        :return: Username or None if not logged in
        )rR   Úget_current_userr3   s    r   râ   zForge.get_current_user°  r”   r   c                 ó*   — t          | j        ¦  «        ‚)zRerieve the web URL for a user.)rR   Úget_user_url)r   Úusers     r   rä   zForge.get_user_url·  r¸   r   )NNNFTN)NNN)r¼   r   )r¼   N)r   r   r   r5   r�   rŽ   Úpropertyr§   Ústrrª   r¬   rµ   r·   rS   r»   r¾   rÁ   rÃ   ÚclassmethodrÅ   rÏ   rÍ   rÕ   rØ   rÚ   rÞ   rà   râ   rä   r   r   r   r    r      s  € € € € € € ðð ð
 %)Ð(Ð(Ñ(à#'Ð'Ð'Ñ'àðEð Eñ „XðEð -1Ð0Ð0Ñ0ð €M€M�Mð (+Ð*Ð*Ñ*ð */Ð  $Ð.Ð.Ñ.àEIØ@EØ7;ð8ð 8ð 8ð 8ð;ð ;ð ;ð ;ð
5ð 5ð 5ð4ð 4ð 4ð	5ð 	5ð 	5ð7ð 7ð 7ð 7ð<ð <ð <ð.ð .ð .ð ð;ð ;ð ;ñ „[ð;ð
 ðAð Añ „[ðAð ðZð Zð Zñ „[ðZð

:ð 
:ð 
:ð 
:ð6ð 6ð 6ð 6ð7ð 7ð 7ð
7ð 7ð 7ð
 ð6ð 6ñ „[ð6ð9ð 9ð 9ð5ð 5ð 5ð 5ð 5r   r    c                 óô   — |                       ¦   «         D ]}|                     ¦   «         r nŒt          ‚	 |                     d¦  «        }|d|…         S # t          $ r |                     d¦  «        cY S w xY w)zCDetermine the title for a merge proposal based on full description.z. Nú.)Ú
splitlinesÚstripÚ
ValueErrorÚindexÚrstrip)rY   Ú	firstlineÚis      r   Údetermine_titlerò   ¼  sž   € à ×+Ò+Ñ-Ô-ð ð ˆ	Ø�?Š?ÑÔð 	ØˆEð	õ ÐðØ�OŠO˜DÑ!Ô!ˆð ˜˜!˜Œ}Ðøõ ð %ð %ð %Ø×Ò Ñ$Ô$Ð$Ð$Ð$ð%øøøs   ¶A ÁA7Á6A7c                 ó  — |r|D ]}|                      | ¦  «        r|c S Œt                               ¦   «         D ]E\  }}	 |                     | ¦  «        }|�|                     |¦  «         |c S # t
          $ r Y ŒBw xY wt          | ¦  «        ‚)zòFind the forge for a branch.

    :param branch: Branch to find forge for
    :param possible_forges: Optional list of forges to reuse
    :raise UnsupportedForge: if there is no forge that supports `branch`
    :return: A `Forge` object
    )rÃ   ÚforgesÚitemsrÏ   Úappendr    )r"   Úpossible_forgesr:   r§   Ú	forge_clss        r   Ú	get_forgerù   Ë  sÇ   € ð ð Ø$ð 	ð 	ˆEØ�{Š{˜6Ñ"Ô"ð Ø���ðå!Ÿ<š<™>œ>ð ð ‰ˆˆið	Ø×/Ò/°Ñ7Ô7ˆEð Ð*Ø×&Ò& uÑ-Ô-Ð-ØˆLˆLˆLøõ  ð 	ð 	ð 	ØˆDð	øøøõ ˜6Ñ
"Ô
"Ð"s   Á A0Á0
A=Á<A=rÇ   c                 ó�   — t          ¦   «         D ])}	 |                     | ¦  «        c S # t          $ r Y Œ&w xY wt          | ¦  «        ‚)z!Get a forge from a hostname.
    )Úiter_forge_instancesrÅ   r    )rÇ   Úinstances     r   Úget_forge_by_hostnamerý   ã  sf   € õ )Ñ*Ô*ð ð ˆð	Ø×/Ò/°Ñ9Ô9Ð9Ð9Ð9øÝð 	ð 	ð 	ØˆDð	øøøå
˜8Ñ
$Ô
$Ð$ó   ’)©
6µ6r:   c              #   óš   K  — | €$d„ t                                ¦   «         D ¦   «         }n| g}|D ]}|                     ¦   «         E d{V —† ŒdS )zXIterate over all known forge instances.

    :return: Iterator over Forge instances
    Nc                 ó   — g | ]\  }}|‘ŒS r   r   )Ú.0r§   rø   s      r   ú
<listcomp>z(iter_forge_instances.<locals>.<listcomp>ô  s   € ÐGÐGÐG¡_ T¨9�yÐGÐGÐGr   )rô   rõ   rà   )r:   Úforge_clsesrø   s      r   rû   rû   î  sq   è è € ð
 €}ØGÐG½¿º¹¼ÐGÑGÔGˆˆà�gˆØ ð .ð .ˆ	Ø×+Ò+Ñ-Ô-Ð-Ð-Ð-Ð-Ð-Ð-Ð-Ð-ð.ð .r   c                 ó�   — t          ¦   «         D ])}	 |                     | ¦  «        c S # t          $ r Y Œ&w xY wt          | ¦  «        ‚)zÆGet the proposal object associated with a URL.

    :param url: URL of the proposal
    :raise UnsupportedForge: if there is no forge that supports the URL
    :return: A `MergeProposal` object
    )rû   rÁ   r    )r   rü   s     r   rÁ   rÁ   û  sf   € õ )Ñ*Ô*ð ð ˆð	Ø×/Ò/°Ñ4Ô4Ð4Ð4Ð4øÝð 	ð 	ð 	ØˆDð	øøøå
˜3Ñ
Ô
Ðrþ   r   Úreturnc                 ó.  — t           j                             | ¦  «        }|j        }t                               ¦   «         D ]G\  }}	 |                     | ¦  «        }|                     |j        ¦  «          dS # t          $ r Y ŒDw xY wt          | ¦  «        ‚)zECreate a project.

    Args:
      url: URL of project to create
    N)
r	   rÑ   rÒ   rÓ   rô   rõ   rÍ   rÞ   Úpathr    )r   Ú
parsed_urlrÇ   r§   rø   Úhosters         r   rÞ   rÞ   
  s¤   € õ ”×)Ò)¨#Ñ.Ô.€JØŒ€HÝ!Ÿ<š<™>œ>ð 	$ð 	$‰ˆˆið	Ø×-Ò-¨cÑ2Ô2ˆFð ×!Ò! *¤/Ñ2Ô2Ð2ØˆEˆEøõ	  ð 	ð 	ð 	ØˆDð	øøøõ ˜sÑ#Ô#Ð#s   ÁA8Á8
BÂBr   )#r5   ÚreÚtypingr   r   Ú r   r   r   r	   r   r   r   r    r%   r(   r*   r1   r,   r7   r?   rB   rE   rL   r�   r    rò   rù   rç   rý   rû   rÁ   rÞ   ÚRegistryrô   r   r   r   ú<module>r     s­  ðð" -Ð ,à 	€	€	€	Ø !Ð !Ð !Ð !Ð !Ð !Ð !Ð !ðð ð ð ð ð ð ð ð ð ð ð ðð ð ð ð �F”Oñ ô ð ð3ð 3ð 3ð 3ð 3˜&œ/ñ 3ô 3ð 3ðð ð ð ð �v”ñ ô ð ð=ð =ð =ð =ð =�6”?ñ =ô =ð =ð
Að Að Að Að A�v”ñ Aô Að Að
Cð Cð Cð Cð C˜6œ?ñ Cô Cð Cð

Nð 
Nð 
Nð 
Nð 
N˜œñ 
Nô 
Nð 
Nðð ð ð ð ˜œñ ô ð ðð ð ð ð  F¤Oñ ô ð ðð ð ð ð ˜œñ ô ð ð	)ð 	)ð 	)ð 	)ð 	) ¤ñ 	)ô 	)ð 	)ðj/ð j/ð j/ð j/ð j/ñ j/ô j/ð j/ðZ/8ð /8ð /8ð /8ð /8ñ /8ô /8ð /8ðd\5ð \5ð \5ð \5ð \5ñ \5ô \5ð \5ð~ð ð ð#ð #ð #ð #ð0% Cð %ð %ð %ð %ð
.ð 
. ¨¨e¬Ô 5ð 
.ð 
.ð 
.ð 
.ð ð  ð  ð$˜ð $ ð $ð $ð $ð $ð( 
-ˆÔ	˜3  U¤Ð+Ô	,Ñ	.Ô	.€€€r   