Pip install custom libraries in Server Code

Would it be possible to pip install custom libraries from the Server Code, similar to using Google Colab?

For example, on Colab, I can do this by running:

!pip install git+https://github.com/user/repo.git

I’m currently using Colab + Anvil’s Uplink to do this but it would be nice if it’s possible to run everything on Anvil.

This might not be necessary. If you’re on a paid plan, Anvil has a lot of server-side packages pre-installed for you: List of Packages.