Skip to content

Commit

Permalink
Clean up errors and remove unused ignores] [batch:18/554] [shard:3/N]
Browse files Browse the repository at this point in the history
Reviewed By: connernilsen

Differential Revision: D64651745

fbshipit-source-id: a554a1d01ba05ff3639fb205ed7a417aa99aac0c
  • Loading branch information
generatedunixname89002005287564 authored and facebook-github-bot committed Oct 21, 2024
1 parent a276b8d commit 09dc442
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 9 deletions.
5 changes: 0 additions & 5 deletions thrift/lib/py3/test/auto_migrate/metadata.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@

import unittest

# pyre-fixme[21]: Could not find module `testing.metadata`.
import testing.metadata
from apache.thrift.metadata.types import ThriftPrimitiveType
from testing.clients import TestingService, TestingServiceChild
Expand All @@ -29,7 +28,6 @@

class MetadataTests(unittest.TestCase):
def test_metadata_enums(self) -> None:
# pyre-fixme[16]: Module `testing` has no attribute `metadata`.
meta = gen_metadata(testing.metadata)
enumName = "testing.Perm"
self.assertIsNotNone(meta)
Expand All @@ -44,7 +42,6 @@ def test_metadata_enums(self) -> None:
self.assertEqual(permEnum, gen_metadata(Perm(1)))

def test_metadata_structs(self) -> None:
# pyre-fixme[16]: Module `testing` has no attribute `metadata`.
meta = gen_metadata(testing.metadata)
structName = "testing.hard"
self.assertIsNotNone(meta)
Expand Down Expand Up @@ -136,7 +133,6 @@ def test_metadata_struct_recursive(self) -> None:
self.assertEqual(other_integers.is_union, integers.is_union)

def test_metadata_exceptions(self) -> None:
# pyre-fixme[16]: Module `testing` has no attribute `metadata`.
meta = gen_metadata(testing.metadata)
errorName = "testing.HardError"
self.assertIsNotNone(meta)
Expand All @@ -159,7 +155,6 @@ def test_metadata_exceptions(self) -> None:
self.assertEqual(field.type.value, ThriftPrimitiveType.THRIFT_I32_TYPE)

def test_metadata_services(self) -> None:
# pyre-fixme[16]: Module `testing` has no attribute `metadata`.
meta = gen_metadata(testing.metadata)
serviceName = "testing.TestingService"
self.assertIsNotNone(meta)
Expand Down
4 changes: 0 additions & 4 deletions thrift/lib/python/any/any_registry.py
Original file line number Diff line number Diff line change
Expand Up @@ -365,10 +365,6 @@ def _load_struct(self, any_obj: Any) -> StructOrUnionOrException:

def _load_primitive(self, any_obj: Any) -> PrimitiveType:
return deserialize_primitive(
# pyre-fixme[6]: For 1st argument expected `Type[Variable[TPrimitive
# (bound to Union[Enum, IOBuf, bool, bytes, float, int, str])]]` but got
# `Type[Union[Enum, GeneratedError, IOBuf, StructOrUnion, bool, bytes,
# float, int, str]]`.
self._type_name_to_serializable_type(any_obj.type.name),
any_obj.data,
protocol=_standard_protocol_to_serializer_protocol(
Expand Down

0 comments on commit 09dc442

Please sign in to comment.