00000003
     ˆÃÂÉ525ÁÇÆ     ‹      Õ•ßoÓ0Çß÷W?ðÖ^Òý(tŽÑh*Q­k«®!„�»�µÄ®l·¥üõ8MJË´Â Æ“Ï—¯ïîsI|äY<êNß�{èÍôf€Æo_ú]„ ïN» ñ4®œ5ƒ 7ÄgÎ-: ëõº¹>mj3‡é2Wäg`�‘©krÇ1=!¥�ž ’	ÆýŠˆ“.´¯¸øŒô�^:+¹ðç6¸XÉTØÒv¢€BÚlê¥}JsÔÛm°Ë¤¨¢ú<P'"‰æ›2øÇsù�[–lS–¦¡ÄehÅr9Wvz�)‘ÅY“Fdª•…$gê®9—3ŒXî"ü¡ß}ô:pYyš†2#f~Õ�†—£(ÆtÈ
A€=¬¹ñš+LÌ:Th.gRð£âÛJ|+¿WšXØÔÈ…“Zí¥àQS�Ûó¬çž 3‡ªJÂÖ–~×ŒñÕ¤7œÆýIÕ^†ØW÷;oÓ13B9K#Rç�5V•ã¹Jìâr·EuÑFÎ3‡)Bô òHg:çÂ²£Üqaº³+½WZ+h]4Â°¾Da»\ ô4Œ\	³e¨­§Â°TwJ¯Õ!„ÿ ñ‰-}(£ñ�fïzV+DÁE§Åòêõ?Àº‡ô¿â,ÅÊÿÖ˜Vëßxäõõ` °AªøŒÌ[8e       ˆÃÂÉ523ÁÇÆ     ‹      Õ•QoÚ0Çßû)<?ì.¡S©ã©#HC£€(Õ4MÓäÄ†XMld(ûôsH´*[§mZ÷äóåï»û]y�ºÓ�ãz7½ ñÍÛA¿‹pàÃi žÆÕƒ³fô†áÌ¹E`½^7×§Mmæ0�@æŠü¬32uMî8¦'¤ôÑD2Á¸_qÒå‚öwHÏè¥³’nc�‹•L…-m'
(D¡Í¦^ÎCPš‹ Þ`—I¥#Põi ÎCÍ7eúðO§ò·,Ùf,MC‰ËÐŠår®"ìôS"‹9²&�0ÈT+IÎÔms.g±ÜEøS¿;úìuà²ò4%eFÌ"ü¦/FQŒé�‚ {\så5—˜˜u¨Ð\Î¤àGÅ×•øZ~=0®4±°©‘'µÚKÁ#¢¦:·æY_y‚Ìª*	ÿY7Xz¯ãËIo8�û“ª%¼±¯î7^¦cf„r(–F¤Îûjª*ÅK•ØÅÅn‹êš�œgS„èQå/€ÎtÎ…9D=¹ÃÂtgVú ´VÐj7Â°ž£ðu'h#ô<Œ\	³e¨­çÂ°T·J¯Õ!„ÿžñ…-}(£ñ�fïzV+DA»Ó
ŽbùÛôý?Àz€ô¿â,ÅÊÿÖ˜Vëßxâíõ\ °@ªù÷T¼Â&b       ˆÃÂÉ524ÁÇÆ     ‹      Õ•QoÚ0Çßû)<?ì.¡”jÔñÔ¤¡Q@”iš¦irbC¬&6²Œ}ú9$V•­Ó6­{òùò÷Ýý.‰�<‹Ç½ÙûI½žÝÑäí«á ‡pàÝy žÅÕƒv3ú#ŒpæÜ²°Ùlš›ó¦6˜M!sEÞëŒL]“;Žé)}ô‘L0îWDœt¹ ÅÅg¤çôÊYÉ…?·µÀÅZ¦Â–¶¢Ðf[/�KPš‹ Þ¶/À®’JH Šêó@�ˆ$šoËüáÏåCî@X²KYš†—¡5ËåBEØé%¦DdMa�©V’œ©»æBÎ1b¹‹ð‡AoüÑëÀeåiJÊŒ˜Gøe/]�£Ó+ö°æÆk®12ëP¡¹œKÁOŠo+ñ­ür:`\ibaS#—Nju�‚G<FMun—Ì³^x‚Ì«*	ÿY7Xú]3&×Óþh¦UKxâPÝï¼9L'ÌåP,�H�wÖXUŽç*±Ë«ýÕE¹È¦5ÐƒÊ_ �ëœsÌzŠrÏ…éÞ:®ô^i­ Õi„a#|�ÂËnÐAèi0¹fÇP[O…a¥î”Þ¨cÿAÿâ[ùPF'âÍÁõ¬Vˆ‚N·œÄòê›€uéÅY‰µÿ­1­Ö¿ðÈëêÁ@`7‚T#ð+Fû;ûe    $   ˆÃÂÉ524Áa–Ü4ý( ©¤ýÔâ�fã/ÜmÕ1hßÇ     ‹      Õ•QoÚ0Çßû)<?ì.�Ò©ÔñÔ¤¡Q@”iš¦irbC¬&6²Œ}ú9$V•­Ó6­{òùò÷Ýý.‰�<‹Ç½ÙûI½žÝÑäí«á ‡pà]»ÏâêÁy3ú#ŒpæÜ²°Ùlš›vS›Ì¦�¹"?ëŒL]“;Žé)}ô‘L0îWDœt¹ ÅÅg¤çôÊYÉ…?·µÀÅZ¦Â–¶¢Ðf[/í(ÍEPo/;`WI%$PEõy NDÍ·eþð�çò!w ,Ù¥,MC‰ËÐšår¡"ìôS"‹²&�0ÈT+IÎÔ]s!ç±ÜEøÃ 7þèuà²ò4%eFÌ#ü²�®ÆQŒéˆ‚ {Xsã5×˜™u¨Ð\Î¥à'Å·•øV~90®4±°©‘K'µ:HÁ#£¦:·KæY;ž 3ÇªJÂÖ–~×ŒÉõ´?šÅƒiÕ^†8T÷;oÓ	3B9K#Rç�5V•ã¹Jìòj¿EuÑF.2‡)Bô òHç:çÂ³ž¢Üsaº·Ž+½WZ+h]4Â°^¢ðE7¸@èi0¹fÇP[O…a¥î”Þ¨cÿAÿâ[ùPF'âÍÁõ¬Vˆ‚‹n+8‰å/Ô7ÿ ëÒÿŠ³kÿ[cZ­à‘×Ôƒ�Àn¨FàWï&Še    !   ˆÌ�þ^”/,Ü¡p¬ˆ$‘¦�üÿË„eÇÊÉ¾Ç ?÷     # obsutil.py - utility functions for obsolescence
#
# Copyright 2017 Boris Feld <boris.feld@octobus.net>
#
# This software may be used and distributed according to the terms of the
# GNU General Public License version 2 or any later version.


import re

from .i18n import _
from .node import (
    hex,
    short,
)
from . import (
    diffutil,
    encoding,
    error,
    phases,
    util,
)
from .utils import dateutil

### obsolescence marker flag

## bumpedfix flag
#
# When a changeset A' succeed to a changeset A which became public, we call A'
# "bumped" because it's a successors of a public changesets
#
# o    A' (bumped)
# |`:
# | o  A
# |/
# o    Z
#
# The way to solve this situation is to create a new changeset Ad as children
# of A. This changeset have the same content than A'. So the diff from A to A'
# is the same than the diff from A to Ad. Ad is marked as a successors of A'
#
# o   Ad
# |`:
# | x A'
# |'|
# o | A
# |/
# o Z
#
# But by transitivity Ad is also a successors of A. To avoid having Ad marked
# as bumped too, we add the `bumpedfix` flag to the marker. <A', (Ad,)>.
# This flag mean that the successors express the changes between the public and
# bumped version and fix the situation, breaking the transitivity of
# "bumped" here.
bumpedfix = 1
usingsha256 = 2


class marker:
    """Wrap obsolete marker raw data"""

    def __init__(self, repo, data):
        # the repo argument will be used to create changectx in later version
        self._repo = repo
        self._data = data
        self._decodedmeta = None

    def __hash__(self):
        return hash(self._data)

    def __eq__(self, other):
        if type(other) != type(self):
            return False
        return self._data == other._data

    def prednode(self):
        """Predecesso