Pass 3 of 3 · Deep dive of PHAROSPass 1 · OverviewPass 2 · How it works
Code Observatory / function
path_role
codeintel.retrieval.path_role
PINNED SOURCE Source and edges from the index at this commit. An execution appears only where one was recorded.
PHAROS at 975a38dMIT license
Around this symbol
Search all symbolsLoading
| Symbol | File | Resolved by |
|---|---|---|
| is_test_path | retrieval.py | same file |
| search | retrieval.py | same file |
| Symbol | File | Resolved by |
|---|---|---|
| _candidates | describe.py | through an import |
| _finalize | retrieval.py | same file |
| Symbol | File | Resolved by |
|---|---|---|
| retrieval | retrieval.py | same file |
codeintel.retrieval.path_rolebackend/app/codeintel/retrieval.py, lines 149–157Open source
def path_role(path: str) -> str: """``test``, ``docs``, ``example`` or ``source``.""" if is_test_path(path): return "test" if _DOCS_PATH_RE.search(path or ""): return "docs" if _EXAMPLE_PATH_RE.search(path or ""): return "example" return "source"What the index recorded
- Signature
def path_role(path: str) -> str:- File
backend/app/codeintel/retrieval.py- Lines
- 149–157
- Parser
- python-ast
- Git blob
884729a39ae0b3d340ad83f75946677dcddf3791- Call sites
- 2 named, 2 resolved, 0 left unlinked
- Outside this subset
- 10 more edges reach code outside the graph shown here
