symforce.test_util.stubs_util module

class FixMissingImports[source]

Bases: FixMissingImports

parse_annotation_str(annotation_str)[source]
Parameters:

annotation_str (str) –

Return type:

ResolvedType | InvalidExpression | Value

patch_lcmtype_imports()[source]
Return type:

None

patch_current_module_prefix()[source]

Fix use of the current module in nested types

Could upstream

Return type:

None

patch_handle_docstring()[source]

Patch BaseParser.handle_docstring to always strip empty lines from the start or end of docstrings

Return type:

None

patch_fix_missing_none_hash_field_annotation()[source]

See https://github.com/sizmailov/pybind11-stubgen/pull/236

Return type:

None

patch_numpy_annotations()[source]
Return type:

None

class FixNumpyArrayRemoveParameters[source]

Bases: IParser

handle_class(path, class_)[source]
Parameters:
  • path (QualifiedName) –

  • class_ (type) –

Return type:

Class | None

parse_annotation_str(annotation_str)[source]
Parameters:

annotation_str (str) –

Return type:

ResolvedType | InvalidExpression | Value

patch_remove_parameters()[source]

Fix NumpyArrayRemoveParameters to work with pybind 3.x and deduplicate overloads

Return type:

None