
    Fwgi                     J    d Z ddlmZ ddlmZ  G d dej
                        Zy)zm
Fixer for os.getcwd() -> os.getcwdu().
Also warns about "from os import getcwd", suggesting the above form.
    )
fixer_base)Namec                       e Zd ZdZd Zy)	FixGetcwdz
              power< 'os' trailer< dot='.' name='getcwd' > any* >
              |
              import_from< 'from' 'os' 'import' bad='getcwd' >
              c                     d|v r,|d   }|j                  t        d|j                               y d|v r| j                  |d       y t	        d      )Nnamegetcwdu)prefixbadz#import os, use os.getcwd() instead.z,For some reason, the pattern matcher failed.)replacer   r
   cannot_convert
ValueError)selfnoderesultsr   s       U/var/www/horilla/myenv/lib/python3.12/site-packages/libpasteurize/fixes/fix_getcwd.py	transformzFixGetcwd.transform   sS    g7#DLLj=>w&LMLMM    N)__name__
__module____qualname__PATTERNr    r   r   r   r   	   s    G	Nr   r   N)__doc__lib2to3r   lib2to3.fixer_utilr   BaseFixr   r   r   r   <module>r      s&   
  #N
"" Nr   