Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Converters cannot convert datetime.timedelta to float. #348

Open
@dionyself

Description

hello devs.
During a conversation about an issue of graphql-core @jkimbo found a possible error

@convert_django_field.register(models.DurationField)
def convert_field_to_float(field, registry=None):
return Float(description=field.help_text, required=not field.null)

raising something like { "message": "float() argument must be a string or a number, not 'datetime.timedelta'" }

you can check graphql-python/graphql-core#150 for more info.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions

        AltStyle によって変換されたページ (->オリジナル) /