mirror of
https://github.com/graphql-python/graphene.git
synced 2024-11-27 03:53:56 +03:00
Removed slots
This commit is contained in:
parent
ff7bf20f6d
commit
2b676743ae
|
@ -10,7 +10,6 @@ from ..utils.orderedtype import OrderedType
|
|||
|
||||
|
||||
class Argument(GraphQLArgument, OrderedType):
|
||||
__slots__ = ('name', 'type', 'default_value', 'description', 'creation_counter')
|
||||
|
||||
def __init__(self, type, default_value=None, description=None, name=None, _creation_counter=None):
|
||||
self.name = name
|
||||
|
@ -43,7 +42,7 @@ class Argument(GraphQLArgument, OrderedType):
|
|||
|
||||
def to_arguments(*args, **extra):
|
||||
from .proxy import TypeProxy
|
||||
args = list(filter(None, args))+[extra]
|
||||
args = list(filter(None, args)) + [extra]
|
||||
arguments = []
|
||||
iter_arguments = chain(*[arg.items() for arg in args])
|
||||
arguments_names = set()
|
||||
|
|
|
@ -11,7 +11,6 @@ from .proxy import TypeProxy
|
|||
|
||||
|
||||
class GrapheneEnumType(GrapheneType, GraphQLEnumType):
|
||||
__slots__ = ('graphene_type', '_name', '_description', '_values', '_value_lookup', '_name_lookup')
|
||||
|
||||
def __init__(self, *args, **kwargs):
|
||||
graphene_type = kwargs.pop('graphene_type')
|
||||
|
|
|
@ -38,7 +38,6 @@ class AbstractField(object):
|
|||
|
||||
|
||||
class Field(AbstractField, GraphQLField, OrderedType):
|
||||
__slots__ = ('_name', '_type', '_args', '_resolver', 'deprecation_reason', 'description', 'source', 'attname', 'parent', 'creation_counter', 'required')
|
||||
|
||||
def __init__(self, type, args=None, resolver=None, source=None, deprecation_reason=None, name=None, description=None, required=False, _creation_counter=None, **extra_args):
|
||||
self.name = name
|
||||
|
@ -114,7 +113,6 @@ class Field(AbstractField, GraphQLField, OrderedType):
|
|||
|
||||
|
||||
class InputField(AbstractField, GraphQLInputObjectField, OrderedType):
|
||||
__slots__ = ('_name', '_type', 'default_value', 'description', 'required')
|
||||
|
||||
def __init__(self, type, default_value=None, description=None, name=None, required=False, _creation_counter=None):
|
||||
self.name = name
|
||||
|
|
|
@ -7,7 +7,7 @@ from .proxy import TypeProxy
|
|||
|
||||
|
||||
class GrapheneInputObjectType(GrapheneFieldsType, GraphQLInputObjectType):
|
||||
__slots__ = ('graphene_type', '_name', '_description', '_fields', '_field_map')
|
||||
pass
|
||||
|
||||
|
||||
class InputObjectTypeMeta(ClassTypeMeta):
|
||||
|
|
|
@ -5,7 +5,7 @@ from .definitions import ClassTypeMeta, GrapheneFieldsType, FieldMap
|
|||
|
||||
|
||||
class GrapheneInterfaceType(GrapheneFieldsType, GraphQLInterfaceType):
|
||||
__slots__ = ('graphene_type', '_name', '_description', '_fields', '_field_map', 'resolve_type')
|
||||
pass
|
||||
|
||||
|
||||
class InterfaceTypeMeta(ClassTypeMeta):
|
||||
|
|
|
@ -7,7 +7,6 @@ from .interface import GrapheneInterfaceType
|
|||
|
||||
|
||||
class GrapheneObjectType(GrapheneFieldsType, GraphQLObjectType):
|
||||
__slots__ = ('graphene_type', '_name', '_description', '_fields', '_field_map', '_is_type_of', '_provided_interfaces', '_interfaces')
|
||||
|
||||
@property
|
||||
def is_type_of(self):
|
||||
|
|
|
@ -6,7 +6,6 @@ from .proxy import TypeProxy
|
|||
|
||||
|
||||
class GrapheneScalarType(GrapheneType, GraphQLScalarType):
|
||||
__slots__ = ('graphene_type', '_name', '_description', '_serialize', '_parse_value', '_parse_literal')
|
||||
|
||||
def __init__(self, *args, **kwargs):
|
||||
GrapheneType.__init__(self, *args, **kwargs)
|
||||
|
|
|
@ -8,7 +8,6 @@ from ..utils.get_graphql_type import get_graphql_type
|
|||
|
||||
|
||||
class Schema(GraphQLSchema):
|
||||
__slots__ = '_query', '_mutation', '_subscription', '_type_map', '_directives', '_implementations', '_possible_type_map', '_types', '_executor'
|
||||
|
||||
def __init__(self, query=None, mutation=None, subscription=None, directives=None, types=None, executor=None):
|
||||
if query:
|
||||
|
|
Loading…
Reference in New Issue
Block a user