MCPcopy Create free account
hub / github.com/colbymchenry/codegraph / isPythonModuleLevelDef

Function isPythonModuleLevelDef

src/resolution/import-resolver.ts:677–679  ·  view source on GitHub ↗

A def at module level — what `from mod import name` can bind.

(n: Node)

Source from the content-addressed store, hash-verified

675
676/** A def at module level — what `from mod import name` can bind. */
677function isPythonModuleLevelDef(n: Node): boolean {
678 return PYTHON_MODULE_LEVEL_KINDS.has(n.kind) && !n.qualifiedName.includes('::');
679}
680
681function parentDir(dir: string): string {
682 const slash = dir.lastIndexOf('/');

Callers 1

getFileExportIndexFunction · 0.85

Calls 1

hasMethod · 0.80

Tested by

no test coverage detected