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

Function isPythonModuleLevelDef

src/resolution/import-resolver.ts:679–681  ·  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

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

Callers 1

getFileExportIndexFunction · 0.85

Calls 1

hasMethod · 0.80

Tested by

no test coverage detected