fengsp / django-grpc-framework

gRPC for Django.
https://djangogrpcframework.readthedocs.io/
Apache License 2.0
390 stars 52 forks source link

django-grpc-framework doesn't work with Django 4.1.1 #42

Open francot opened 2 years ago

francot commented 2 years ago

Following quick start tutorial: https://djangogrpcframework.readthedocs.io/en/latest/quickstart.html with Django 4.1.1

command python manage.py grpcrunserver --dev

return error:

Traceback (most recent call last):
  File "manage.py", line 22, in <module>
    main()
  File "manage.py", line 18, in main
    execute_from_command_line(sys.argv)
  File "/home/franco/.virtualenvs/proto/lib/python3.8/site-packages/django/core/management/__init__.py", line 446, in execute_from_command_line
    utility.execute()
  File "/home/franco/.virtualenvs/proto/lib/python3.8/site-packages/django/core/management/__init__.py", line 440, in execute
    self.fetch_command(subcommand).run_from_argv(self.argv)
  File "/home/franco/.virtualenvs/proto/lib/python3.8/site-packages/django/core/management/__init__.py", line 279, in fetch_command
    klass = load_command_class(app_name, subcommand)
  File "/home/franco/.virtualenvs/proto/lib/python3.8/site-packages/django/core/management/__init__.py", line 49, in load_command_class
    return module.Command()
  File "/home/franco/.virtualenvs/proto/lib/python3.8/site-packages/django/core/management/base.py", line 274, in __init__
    raise TypeError("requires_system_checks must be a list or tuple.")
TypeError: requires_system_checks must be a list or tuple.
legau commented 2 years ago

This lib is not maintained anymore, I suggest you take a look at https://github.com/socotecio/django-socio-grpc which was originally based on this library. It does support Django 4.1.

dashdanw commented 2 years ago

@legau what would it take to boot this back up?

fan9704 commented 1 year ago

I also have this problem

vermastuti commented 1 year ago

I also got this same error

fan9704 commented 1 year ago

Or try my project i upgrade it to Django 4 https://github.com/fan9704/NeoRPCSeach

but I,m it can work correctly(long time ago)

mertwec commented 1 year ago

for fix this problem, need change one string in file of [django-grpc-framework]: in file: "path_to_venv/lib/python3.10/site-packages/django_grpc_framework/management/commands/grpcrunserver.py" replace 20 string from 'requires_system_checks = False' to 'requires_system_checks = []'