style: fix linting issues in get_ident_filename_matches

This commit is contained in:
Paul Gauthier (aider) 2024-11-26 06:26:26 -08:00
parent 62b02d4370
commit 266093189d

View file

@ -582,15 +582,11 @@ class Coder:
def get_ident_filename_matches(self, idents):
all_fnames = defaultdict(set)
existing_basenames = {
Path(fname).name.lower()
for fname in self.get_inchat_relative_files()
+ [self.get_rel_fname(f) for f in self.abs_read_only_fnames]
}
for fname in self.get_all_relative_files():
base = Path(fname).with_suffix("").name.lower()
# Only skip if we already have a file with this name AND the base name matches the identifier
# Only skip if we already have a file with this name AND
# the base name matches the identifier
if len(base) >= 5:
all_fnames[base].add(fname)