mcpyproject / McPy

A open source Minecraft server written 100% in Python
GNU Affero General Public License v3.0
84 stars 15 forks source link

Remove startup.py in favor of simpler dependencies.py #53

Closed hydrostaticcog closed 3 years ago

hydrostaticcog commented 3 years ago

This PR aims to remove startup.py and replace it with dependencies.py.

Dependencies.py only does the following things:

Me and Bennyturtle are both trying to resolve the issue of startup.py, so see his PR when he is done with his portion

**NOTE: Some of dependencies.py was copied from startup.py (basically what it needs to do, or just some ways to do it)***

0ddlyoko commented 3 years ago

Isn't it better to use a "requirements.txt" file as described here: https://pip.pypa.io/en/latest/user_guide/#requirements-files Instead of adding 5+ lines per dependencies ?

hydrostaticcog commented 3 years ago

Yes, and I have fixed that with the most recent commit. Thanks for reminding me!

hydrostaticcog commented 3 years ago

I had to include additional code to figure out what OS McPy is running on becuase of compatibility with Debian/Ubuntu. They both disable to ensurepip module, thus I had to use the apt command to install pip.

hydrostaticcog commented 3 years ago

We mainly need to test this on Debian-based distros, since one of the problems was Debian's disabling of the ensurepip module. I can confirm that this works as intended on Windows 10 and Ubuntu 20.04 (WSL). I think that it would work on Debian, but I have not tested it.

Geolykt commented 3 years ago

I think we might also need to test it on macos, just to be one the sure side

hydrostaticcog commented 3 years ago

I'll need to wipe the dust off my macOS system.

hydrostaticcog commented 3 years ago

The dependencies.py works as intended on macOS 10.14.6 (dependencies were not previously installed) however, there is still the issue of #52 which prevents the server from starting.

hydrostaticcog commented 3 years ago

It appears I can't comprehend how to squash commits.

Geolykt commented 3 years ago

Isn't really important, we can squash then when merging

hydrostaticcog commented 3 years ago

Ok

Geolykt commented 3 years ago

This should be merged sometime soon for the sake of allowing further development within the parts the PR changed

hydrostaticcog commented 3 years ago

I'm ready for merge, so merge when ready!