Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Django 1.11 support on python 3 #56

Open
AgDude opened this issue Jul 3, 2020 · 2 comments
Open

Django 1.11 support on python 3 #56

AgDude opened this issue Jul 3, 2020 · 2 comments

Comments

@AgDude
Copy link

AgDude commented Jul 3, 2020

The way that django-eventstream requires channels in setup.py prevents dependency resolution for django 1.11 on python 3. I am upgrading a project which uses pip-tools for dependency management and get the following output:

There are incompatible versions in the resolved dependencies:
  Django<2 (from -r requirements/requirements.in (line 33))
  Django>=2.2 (from channels==2.4.0->django-eventstream==3.1.0->-r requirements/requirements.in (line 34))

pip-tools does not currently have an option to override that. jazzband/pip-tools#561

The way this is defined effectively makes django-eventstream only compatible with django>=2.2 on python 3. Since pip doesn't have strict dependency resolution this probably goes unnoticed in most cases.

I would be happy to offer a PR, but I don't see a good solution without forcing users to explicitly install channels, which would likely break things for many users. It seems like this might be addressed with extra_requires but I am not seeing how to make it dependent on the django version.

@jkarneges
Copy link
Member

It looks like extra_requires could be used to specify channels as an optional dependency, that would only be installed if the user asks for it (for example by specifying a dependency to django-eventstream[channels]). This would be a breaking change though, and ideally the option would be inverted (channels enabled by default).

How about copying the django-eventstream module into your source tree, so you can control the dependencies and not attempt to install channels?

@jkarneges
Copy link
Member

I've decided to simply require installing channels manually, to make it easier for users to select between older Django versions and the latest Channels versions. The major version of django-eventstream has been bumped to avoid surprises. Hopefully this fixes your issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants