python-discord/sir-lancebot

Fix Gitpod support

hedyhli opened this issue · 1 comments

Description

We require Python 3.11.* now, Gitpod config should be updated to have pyenv install the correct version.

Steps to Reproduce

Expected Behaviour

Successful initialization

Actual Behaviour

Incompatible version error

Known Impacted Platforms

n/a

Possible Solutions

Update .gitpod.yml to use the correct version during setup.

diff --git a/.gitpod.yml b/.gitpod.yml
index a10e6e26..cc63d02a 100644
--- a/.gitpod.yml
+++ b/.gitpod.yml
@@ -1,5 +1,5 @@
 tasks:
   - name: "Python Environment"
-    before: "pyenv install 3.9.6 && pyenv global 3.9.6"
+    before: "pyenv install 3.11 && pyenv global 3.11"
     init: "pip install poetry && export PIP_USER=false"
     command: "poetry install && poetry run pre-commit install"

And while we're at it we should fix #916 at the same time.

diff --git a/.gitpod.yml b/.gitpod.yml
index a10e6e26..d80a8c2e 100644
--- a/.gitpod.yml
+++ b/.gitpod.yml
@@ -1,5 +1,5 @@
 tasks:
   - name: "Python Environment"
-    before: "pyenv install 3.9.6 && pyenv global 3.9.6"
-    init: "pip install poetry && export PIP_USER=false"
-    command: "poetry install && poetry run pre-commit install"
+    before: "pyenv install 3.11 && pyenv global 3.11"
+    init: "pip install poetry"
+    command: "export PIP_USER=false && poetry install && poetry run pre-commit install"

Additional Details

Unless this was discussed elsewhere, I believe that our gitpod support should be kept up-to-date, because it lowers the barrier to contributing to sir-lancebot tremendously. I personally benefitted from it as well; it makes the process as simple as simply clicking a link and waiting for the setup to finish.

Would you like to implement a fix?

Note: For high-priority or critical bugs, fixes may be implemented by staff.

Yes I can implement the fix, it's very trivial.

Sounds good.