File tree Expand file tree Collapse file tree 1 file changed +15
-4
lines changed
Expand file tree Collapse file tree 1 file changed +15
-4
lines changed Original file line number Diff line number Diff line change 22import collections
33import concurrent .futures
44from datetime import timedelta
5+ from glob import glob
56import json
67import os
78from packaging import version
@@ -440,12 +441,22 @@ def find_inos():
440441 if args .sketches :
441442 arg_sketch_pattern = re .compile (args .sketches , re .IGNORECASE )
442443 for spath in search_path_list :
443- for spath_object in spath .glob ("**/*.[ip][nd][oe]" ):
444+ # Due to issue with Path.glob() which does not follow symlink
445+ # use glob.glob
446+ # See: https://bugs.python.org/issue33428
447+ # for spath_object in spath.glob("**/*.[ip][nd][oe]"):
448+ # if args.sketches:
449+ # if arg_sketch_pattern.search(str(spath_object)) is None:
450+ # continue
451+ # if spath_object.is_file():
452+ # sketch_list.append(spath_object.parent)
453+ for sk_ino in glob (str (spath / "**" / "*.[ip][nd][oe]" ), recursive = True ):
444454 if args .sketches :
445- if arg_sketch_pattern .search (str ( spath_object ) ) is None :
455+ if arg_sketch_pattern .search (sk_ino ) is None :
446456 continue
447- if spath_object .is_file ():
448- sketch_list .append (spath_object .parent )
457+ p_ino = Path (sk_ino )
458+ if p_ino .is_file ():
459+ sketch_list .append (p_ino .parent )
449460 sketch_list = sorted (set (sketch_list ))
450461
451462
You can’t perform that action at this time.
0 commit comments