-
Notifications
You must be signed in to change notification settings - Fork 34
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
CodeGate doesn't distinguish Python built-in modules and external packages #518
Comments
@ptelang retest |
This issue is fixed in the latest version by this PR. |
Currently, Codegate cannot identify libraries like hashlib which were external earlier but are now built into python. We can address this issue when the projects functionality is implemented. Codegate can then read the dependency files (e.g. requirements.tx, pyproject.toml, etc.) to detect cases like hashlib and prevent the false positive. |
@ptelang this is fixed now? |
Describe the issue
CodeGate isn't aware of the built-in Python modules, and may treat imports of these as references to external packages.
The specific case I've encountered is
hashlib
- at one time it was an external package and so exists in PyPI and thus also in our data set, but the external package was archived and moved to built-in ages ago. When CodeGate encountersimport hashlib
in code, it finds the archived package in the vector DB, and reports it as archived/deprecated.Insight report - https://www.insight.stacklok.com/report/pypi/hashlib
PyPI entry - https://pypi.org/project/hashlib/20081119/
CodeGate behavior:
Steps to Reproduce
Reference the app.py file from the codegate-demonstration repo using Copilot or Continue chat.
Operating System
MacOS (Arm)
IDE and Version
VS Code 1.96.2
Extension and Version
Any
Provider
GitHub Copilot
Model
Any
Logs
Additional Context
No response
The text was updated successfully, but these errors were encountered: