# Buggy code
def convert_datetime_to_string(field, registry=None):
    return DateTime(description=field.help_text, required=not field.null)


# Traceback (TypeError)
Traceback (most recent call last):
File "./manage.py", line 21, in <module>
main()
File "./manage.py", line 17, in main
execute_from_command_line(sys.argv)
File "/home/username/.virtualenvs/project/lib/python3.8/site-packages/django/core/management/__init__.py", line 401, in execute_from_command_line
utility.execute()
File "/home/username/.virtualenvs/project/lib/python3.8/site-packages/django/core/management/__init__.py", line 395, in execute
self.fetch_command(subcommand).run_from_argv(self.argv)
File "/home/username/.virtualenvs/project/lib/python3.8/site-packages/django/core/management/base.py", line 328, in run_from_argv
self.execute(*args, **cmd_options)
File "/home/username/.virtualenvs/project/lib/python3.8/site-packages/django/core/management/base.py", line 369, in execute
output = self.handle(*args, **options)
File "/home/username/.virtualenvs/project/lib/python3.8/site-packages/graphene_django/management/commands/graphql_schema.py", line 113, in handle
self.get_schema(schema, out, indent)
File "/home/username/.virtualenvs/project/lib/python3.8/site-packages/graphene_django/management/commands/graphql_schema.py", line 70, in get_schema
self.save_graphql_file(out, schema)
File "/home/username/.virtualenvs/project/lib/python3.8/site-packages/graphene_django/management/commands/graphql_schema.py", line 59, in save_graphql_file
outfile.write(print_schema(schema.graphql_schema))
File "/home/username/.virtualenvs/project/lib/python3.8/site-packages/graphql/utilities/print_schema.py", line 39, in print_schema
return print_filtered_schema(
File "/home/username/.virtualenvs/project/lib/python3.8/site-packages/graphql/utilities/print_schema.py", line 61, in print_filtered_schema
"\n\n".join(
File "/home/username/.virtualenvs/project/lib/python3.8/site-packages/graphql/utilities/print_schema.py", line 65, in <genexpr>
(print_type(type_) for type_ in types),
File "/home/username/.virtualenvs/project/lib/python3.8/site-packages/graphql/utilities/print_schema.py", line 128, in print_type
return print_object(type_)
File "/home/username/.virtualenvs/project/lib/python3.8/site-packages/graphql/utilities/print_schema.py", line 162, in print_object
+ print_fields(type_)
File "/home/username/.virtualenvs/project/lib/python3.8/site-packages/graphql/utilities/print_schema.py", line 198, in print_fields
fields = [
File "/home/username/.virtualenvs/project/lib/python3.8/site-packages/graphql/utilities/print_schema.py", line 199, in <listcomp>
print_description(field, "  ", not i)
File "/home/username/.virtualenvs/project/lib/python3.8/site-packages/graphql/utilities/print_schema.py", line 282, in print_description
block_string = print_block_string(description, "", prefer_multiple_lines)
File "/home/username/.virtualenvs/project/lib/python3.8/site-packages/graphql/language/block_string.py", line 91, in print_block_string
result += value.replace("\n", "\n" + indentation) if indentation else value
TypeError: can only concatenate str (not "__proxy__") to str

# Fixed code
def convert_datetime_to_string(field, registry=None):
    return DateTime(
        description=get_django_field_description(field), required=not field.null
    )