def iso_path_slugify(path, path_table, is_dir=False, strict=True):
<EOL>parent, base = split(path)<EOL>slug_parent = path_table[parent]<EOL>if is_dir:<EOL><INDENT>slug_base = iso_name_slugify(base)[:<NUM_LIT:8>]<EOL><DEDENT>else:<EOL><INDENT>name, ext = base.rsplit('<STR_LIT:.>', <NUM_LIT:1>) if '<STR_LIT:.>' in base else (base, '<STR_LIT>')<EOL>slug_base = '<STR_LIT:.>'.join([iso_name_slugify(name)[:<NUM_LIT:8>], ext])<EOL><DEDENT>if strict:<EOL><INDENT>slug_base = slug_base.upper()<EOL><DEDENT>slugs = set(path_table.values())<EOL>path_table[path] = slug = join(slug_parent, slug_base)<EOL>while slug in slugs:<EOL><INDENT>slug_base = iso_name_increment(slug_base, is_dir)<EOL>path_table[path] = slug = join(slug_parent, slug_base)<EOL><DEDENT>return slug<EOL>
Slugify a path, maintaining a map with the previously slugified paths.

    The path table is used to prevent slugified names from collisioning,
    using the `iso_name_increment` function to deduplicate slugs.

    Example:
        >>> path_table = {'/': '/'}
        >>> iso_path_slugify('/ébc.txt', path_table)
        '/_BC.TXT'
        >>> iso_path_slugify('/àbc.txt', path_table)
        '/_BC2.TXT'