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

Correctly specify dependency on typing_extensions #107

Merged
merged 2 commits into from
Nov 21, 2024

Conversation

AustinT
Copy link
Collaborator

@AustinT AustinT commented Nov 17, 2024

Syntheseus previously depended on typing_extensions without specifying this in the pyproject.toml file, causing a fresh install to fail the tests. This PR fixes this by:

  1. Wrapping the second import of typing_extensions in an if/else block to only run if python < 3.8 is used (otherwise an import from typing can be used directly). This was already present in the first import of typing_extensions.
  2. Modify pyproject.toml to specify that typing_extensions is required, but only if python < 3.8.

@AustinT
Copy link
Collaborator Author

AustinT commented Nov 17, 2024

(I noticed this issue when investigating #106 )

@AustinT
Copy link
Collaborator Author

AustinT commented Nov 18, 2024

@kmaziarz the tests are failing in this PR due to a segmentation fault, but this doesn't seem very related to the PR? I've tried re-running 3 times now but it still won't pass. Not sure what's going on here...

@kmaziarz
Copy link
Contributor

Modify pyproject.toml to specify that typing_extensions is required, but only if python < 3.8

My thinking was that we should drop support for Python 3.7 soon anyway; we only maintained it due to being required by GLN, but as of #103 this is no longer the case.

Perhaps we should release 0.5.0 to have a final numbered version that still supports Python 3.7, and then bump the version requirement after that?

Tests are failing in this PR due to a segmentation fault, but this doesn't seem very related to the PR

Yeah, doesn't seem related to the PR. It also happens from main, and seems to also be caused by torch-scatter... 😆 I'll need to take a closer look at what's going on

@kmaziarz
Copy link
Contributor

Update: I don't think the environment issues are really caused by torch_scatter, and rather by the fact that installing syntheseus[all] now reinstalls the torch despite it already being present in the env. This is due to another package updating upstream. I'll send a fix soon although we may want to set things up a bit more robustly in the long term...

@AustinT
Copy link
Collaborator Author

AustinT commented Nov 21, 2024

Great Kris, thanks for looking into this! I agree about not supporting python 3.7 anymore- that makes our lives a lot easier. Releasing a final python 3.7 version and then dropping support sounds good.

@kmaziarz
Copy link
Contributor

The issue should be fixed as of #108. I think this is not everything, as I also get problems with building torch-scatter as reported in the other issue. I'll look into that too, but I think that's separate, and doesn't seem to happen in CI. At the very least #108 should unblock your PR, which I imagine we still may want to merge in order to get a fully working 0.5.0 version (before we drop support for Python 3.7 and strip out some of the changes from your PR)?

@AustinT
Copy link
Collaborator Author

AustinT commented Nov 21, 2024

Sounds good, once #108 is merged lets re-run CI, merge this if there are no issues, make a new release, then drop python 3.7 support!

@kmaziarz
Copy link
Contributor

Sounds good, once #108 is merged lets re-run CI, merge this if there are no issues, make a new release, then drop python 3.7 support!

I've rebased the PR onto main now; lets see if the CI passes this time around.

@AustinT
Copy link
Collaborator Author

AustinT commented Nov 21, 2024

Looks like it passes @kmaziarz. Should I merge?

@kmaziarz
Copy link
Contributor

Seems good to merge, maybe just add a CHANGELOG entry.

@AustinT AustinT merged commit 713ab41 into microsoft:main Nov 21, 2024
5 checks passed
@AustinT AustinT deleted the no-typing-extensions branch November 21, 2024 16:56
AustinT added a commit that referenced this pull request Nov 21, 2024
@AustinT
Copy link
Collaborator Author

AustinT commented Nov 21, 2024

Sorry, didn't see your comment re CHANGELOG

@AustinT AustinT restored the no-typing-extensions branch November 21, 2024 16:58
@AustinT
Copy link
Collaborator Author

AustinT commented Nov 21, 2024

@kmaziarz what's the easiest way to just add the CHANGELOG entry? I made an update on my fork's CHANGELOG here but it wasn't reflected in this PR anymore.

@AustinT
Copy link
Collaborator Author

AustinT commented Nov 21, 2024

@kmaziarz fixed CHANGELOG in #109

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

Successfully merging this pull request may close these issues.

2 participants