[IMPORTANT] Python workflow update#1537
Conversation
|
@alexunderch properly moving to pyproject.toml is a big change that I don't have proper time to investigate fully at the moment (so likely want to delay until after OpenSpiel 2.0 is released). But I agree: that list is too large. It should only contain the dependencies listed in In the short-term (separately, in a different PR), can we just reduce that list to just those packages in |
|
@lanctot technically, we already did this: I will fix some bugs. Maybe we can get optional deps + basic pre-commit (just linter + pyink) to the 2.0 release? I think, then, I will take my time to cook it properly. |
|
Okay, the tests pass, but the setup takes significantly longer than before. I'll do some housekeeping. |
|
@lanctot, overall the new system works and it's a little bit faster and easier than just using I still think to get rid of the python extra deps script with the env variables, because it won't really work on Windows, I reckon. Instead, I may create several Second of all, wdyt about introducing And lastly, can you comment someting on what's the linter approach on doc-strings should be? Overall, the goal of the PR is to introduce (I don't really do much more than moving couple of lines of code around) a correct installing system that should allow to build the library from source on MacOS, Linux, and Windows, outline the issues for the latter. Moreover, for Linux and MacOS, we'll make some nice adjustments to lint and format the code automatically to lessen the burden of reviewing process. I believe that it would be a nice addtion to the 2.0 release. Didn't want to leave the gap with the weird |
|
@lanctot, technically the most of PR is done, at least is what could be covered by tests:
There is still a part with a linter. Because I turned on doc-string support of the publicy avaliable linter and there are so many warnings caused by the legacy code base, so I'wll repeatedly ask you to give it a look. As soon as you're ready, I can add a workflow that formats the code and runs the linter on the commited changes 😄 . This would be the final thing that this harmless PR introduces. Have a nice day |
|
Let's say, this PR is review-ready |
To whom it may concern:
While testing windows build, I've found out that there is now
pyproject.tomlwith some interesting set of "full" dependecies:open_spiel/pyproject.toml
Line 45 in 3af8893
It's not very useful as the main installation is done through
setup.py. To combat the issue, I decided to basically "fork" #1071 because the author is busy or what. Therefore, I moved the building process topyproject, whensetup.pyis just responsible for theCMakepluginOverall this PR introduces:
python_extra_deps.shand will have all deps directly installable, likepip install open-spiel[pytorch, jax]@lanctot, can you please, check out what what linter do you have because Google's basic linter raises a ton of docstring warnings/convention errors.