#NEWLINE# def write( self , data , dst , label = None , mode = 'wb' ) : #NEWLINE# #INDENT# 'Write data to ``chroot/dst`` with optional label.\n\n    Has similar exceptional cases as ``Chroot.copy``\n    ' #NEWLINE# dst = self . _normalize ( dst ) #NEWLINE# self . _tag ( dst , label ) #NEWLINE# self . _ensure_parent ( dst ) #NEWLINE# with open ( os . path . join ( self . chroot , dst ) , mode ) as wp : #NEWLINE# #INDENT# wp . write ( data )