File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 2020 # Skip "venv" and other similarly named directories
2121 if path .name .startswith ("venv" ) or path .name .startswith (".venv" ) or path .name .startswith ("." ) or "site-packages" in path .parts :
2222 continue
23+
2324 # Skip and print "cause"
2425 cause = None
26+ # Skip if read issue
2527 try :
2628 txt = path .read_text ()
2729 except UnicodeDecodeError :
3436 if not line or line .startswith ("#" ):
3537 continue
3638 if not line .startswith (('"' , "'" )):
37- print ()
3839 cause = f"Warning: Skipping (due to missing docstring) { path .relative_to (root )} "
3940 break
41+ # namespace packages not unsupported.
42+ # Fix? https://github.com/mkdocstrings/mkdocstrings/discussions/563
43+ if path .name != "__init__.py" :
44+ parent_has_init = (path .parent / "__init__.py" ).exists ()
45+ if not parent_has_init :
46+ cause = f"Warning: Skipping namespace package file: { path .relative_to (root )} "
4047 if cause :
48+ print (cause )
4149 continue
4250
4351 parts = tuple (path .relative_to (src ).with_suffix ("" ).parts )
You can’t perform that action at this time.
0 commit comments