Xqt added a comment.

  The context is wrong. There is not reassignment of the iterable because a 
property is used. Indeed there is a reassignment of a variable path but this is 
a wanted behavior:
  
    path = Path(folder_path)
    if not is_zipfile(path):
        for path in path.parents:  # find a new path to proceed later
            if is_zipfile(path):
                break
        else:
            raise NotADirectoryError('20', 'Not a directory', folder_path)
    
    zip_file = ZipFile(path)

TASK DETAIL
  https://phabricator.wikimedia.org/T304279

EMAIL PREFERENCES
  https://phabricator.wikimedia.org/settings/panel/emailpreferences/

To: Xqt
Cc: Xqt, Aklapper, pywikibot-bugs-list, JJMC89, Fernandobacasegua34, 786, 
Suran38, Biggs657, Lalamarie69, Jyoo1011, JohnsonLee01, Juan90264, SHEKH, 
Dijkstra, Alter-paule, Beast1978, Un1tY, Khutuck, Zkhalido, Hook696, Kent7301, 
joker88john, Viztor, CucyNoiD, Wenyi, Gaboe420, Giuliamocci, Cpaulf30, Af420, 
Bsandipan, Tbscho, MayS, Lewizho99, Mdupont, Maathavan, Dvorapa, Altostratus, 
Neuronton, Avicennasis, mys_721tx, jayvdb, Masti, Alchimista
_______________________________________________
pywikibot-bugs mailing list -- [email protected]
To unsubscribe send an email to [email protected]

Reply via email to