# Installing janus on Google Colab

**URL:** <https://swi-prolog.discourse.group/t/installing-janus-on-google-colab/7443>\
**Category:** Installing\
**Tags:** janus\
**Created:** [May 12, 2024, 12:36pm UTC](https://swi-prolog.discourse.group/t/installing-janus-on-google-colab/7443 "2024-05-12T12:36:32Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Nema](https://avatars.discourse-cdn.com/v4/letter/n/97f17d/32.png) [@Nema](https://swi-prolog.discourse.group/u/Nema)\
**Post date:** [May 12, 2024, 12:36pm UTC](https://swi-prolog.discourse.group/t/installing-janus-on-google-colab/7443/1 "2024-05-12T12:36:32Z")

</div>

Hi everyone,  
I’m trying to install janus\_swi in Google Colab throught

!pip install janus\_swi

but I get the error:

error: subprocess-exited-with-error

× Getting requirements to build wheel did not run successfully.  
│ exit code: 1

Does anyone know how to fix it?

---

<div class="post-metadata">

**Author:** ![jan](https://yyz2.discourse-cdn.com/free1/user_avatar/swi-prolog.discourse.group/jan/32/4_2.png) [@jan](https://swi-prolog.discourse.group/u/jan)\
**Post date:** [May 12, 2024, 3:08pm UTC](https://swi-prolog.discourse.group/t/installing-janus-on-google-colab/7443/2 "2024-05-12T15:08:48Z")

</div>

Can you get some more details? A possible cause is that this pip package does not install SWI-Prolog itself. That must be installed and `swipl` must be in `PATH`. The pip installer uses that to figure out the SWI-Prolog location and components. You also need a C compiler installed.

If anyone knows how to improve on this, please share.

---

<div class="post-metadata">

**Author:** ![Nema](https://avatars.discourse-cdn.com/v4/letter/n/97f17d/32.png) [@Nema](https://swi-prolog.discourse.group/u/Nema)\
**Post date:** [May 12, 2024, 3:22pm UTC](https://swi-prolog.discourse.group/t/installing-janus-on-google-colab/7443/3 "2024-05-12T15:22:34Z")

</div>

Thank you very much,  
yes, that was the problem!  
I now write all the code required if anyone will have the same issue:

# install swi-prolog

!apt-add-repository --yes ppa:swi-prolog/stable

!apt-get update

!apt-get install swi-prolog

# then install and import janus

!pip install janus\_swi

import janus\_swi as janus
