Skip to content

Fix IDE static analysis diagnostics and type checking errors #22

@DevAbdullah90

Description

@DevAbdullah90

Description

Currently, there are several Pyright/Pyrefly static analysis errors and diagnostics across the Google Antigravity Python SDK workspace. This issue tracks the fixes for these problems.

We have fixed these errors on the fork branch fix-ide-type-diagnostics. Since direct pull requests to this repository are restricted to collaborators only, we would appreciate it if you could review the changes or invite us as a collaborator to submit a Pull Request.

Proposed Changes

The changes include:

  1. Core SDK Types (google/antigravity/types.py):
    • Imported cast and casted return values and validation error dictionaries to prevent invariant list type errors.
    • Handled IsADirectoryError check in file reading.
  2. Local Connection (google/antigravity/connections/local/local_connection.py):
    • Removed redundant class-level target attribute to resolve conflicts with parent class fields.
    • Defined _TARGET_MAP to resolve type lookups, and properly typed local connection strategy variables.
    • Updated connection send method signature with **kwargs to match parent interface.
  3. Local Connection Tests (google/antigravity/connections/local/local_connection_test.py):
    • Added explicit metadata imports and assertions to guarantee non-null thread and configuration variables.
  4. Workspace Configurations:
    • Added pyrightconfig.json and pytest configurations (conftest.py) to manage local test run contexts cleanly.

Link to fork branch with full implementation: https://github.com/DevAbdullah90/antigravity-sdk-python/tree/fix-ide-type-diagnostics

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions