Skip to content

Commit a9c5e47

Browse files
committed
FIX(site): pick +1 linkcode failure errmsg
1 parent 5ff565e commit a9c5e47

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

docs/source/conf.py

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -170,10 +170,12 @@ def linkcode_resolve(domain, info):
170170
return uri
171171
except TypeError as ex:
172172
# don't clutter logs, these are mostly non functions.
173-
assert "module, class, method, function," in str(ex), ex
173+
assert "module, class, method, function," in str(ex), (ex, item_name)
174174
except OSError as ex:
175-
# don't clutter logs, these are mostly non functions.
176-
assert "could not find class definition" in str(ex), ex
175+
# don't clutter logs, these are mostly non functions or `__new__` specials.
176+
assert "could not find class definition" in str(
177+
ex
178+
) or "could not get source code" in str(ex), (ex, item_name)
177179
except Exception as ex:
178180
log.warning(
179181
"Ignoring error on while searching lineno of '%s': %s(%s)",

0 commit comments

Comments
 (0)