Open
Description
The scip-python index
command is fatally crashing on our python repository.
Minimal Error Repro
ParamSpec
is available in the standard typing
module post 3.10
from typing import ParamSpec
from collections.abc import Callable
P = ParamSpec("P")
def decorator(func: Callable[P, None]) -> Callable[P, None]:
pass
class BaseFactory:
@classmethod
@decorator
def create(cls, *args, **kwargs):
return super().create(*args, **kwargs)
class ChildFactory(BaseFactory):
@classmethod
def create(cls, *args, **kwargs):
return super().create(*args, **kwargs)
Command:
npx @sourcegraph/scip-python index --cwd ${pathToIndexRoot} --output ${scipFile}
Environment:
Python 3.10.17
Actual error:
Experienced Fatal Error While Indexing:\nPlease create an issue at github.com/sourcegraph/scip-python: {\n currentFilepath: '/Users/kevinxu/Documents/work/detail/packages/codetools/src/test_data/sample_python_repo/factories/deployment.py',\n error: TypeError: Cannot read properties of undefined (reading 'node')\n at L.getFunctionRelationships (/Users/kevinxu/Documents/work/detail/node_modules/.pnpm/@sourcegraph+scip-python@0.6.0_@types+node@22.13.4_typescript@5.7.3/node_modules/@sourcegraph/scip-python/dist/scip-python.js:1:83363)\n at L.visitFunction (/Users/kevinxu/Documents/work/detail/node_modules/.pnpm/@sourcegraph+scip-python@0.6.0_@types+node@22.13.4_typescript@5.7.3/
Thought
- Do we need to re-sync the typeshed-fallback stubs (they haven't been updated in 2 years)?