RapidPro 6.2.4 cant run "pip install -r pip-freeze.txt" error

281 views
Skip to first unread message

Clerio Alfredo Faife

unread,
Aug 4, 2021, 9:50:25 AM8/4/21
to rapidpro-dev
Hi team,

I'm  struggling to  have  rapidpro installed  on  my local machine  using version 6.2.4.  The error occurs when I run  the command  "pip install -r pip-freeze.txt" as per  the instruction on site https://rapidpro.github.io/rapidpro/docs/development/.

The errors are on steps:  
--   Building wheel for pycrypto (setup.py) ... error
--   Building wheel for rcssmin (setup.py) ... error
--   Building wheel for rjsmin (setup.py) ... error

I  have been trying this and  other  approaches  such  as Docker and  different versions  for weeks  and with no  success.

Can you please advice  on  how to  proceed

Thanks     in   advance
Clerio Faife

Rowan Seymour

unread,
Aug 5, 2021, 10:18:32 AM8/5/21
to Clerio Alfredo Faife, rapidpro-dev
It's a little hard to know what's going on without seeing the actual errors, but I'd suggest trying to install the latest 6.4.x release of RapidPro instead which uses poetry for dependencies.

-Rowan

--
You received this message because you are subscribed to the Google Groups "rapidpro-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to rapidpro-dev...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/rapidpro-dev/bb68be2d-5a35-42a4-8add-97b04a09f8f9n%40googlegroups.com.


--
Rowan Seymour | +593 979099233 | @rowanseymour

Rowan Seymour

unread,
Aug 5, 2021, 11:25:53 AM8/5/21
to Clerio Alfredo Faife, rapidpro-dev
It looks like your system doesn't have Python dev libraries installed 

-Rowan

On Thu, 5 Aug 2021 at 10:23, Clerio Alfredo Faife <clerio...@gmail.com> wrote:
Hi Rowan,

Thanks for your response, I  have tried version  6.4.8  with poetry as well,  and it does not work.
Find the  errors here: https://pastebin.com/GYnctfvY

The issue is in  Installing rcssmin (1.0.6): Failed

Regards
Clerio Alfredo Faife

Clerio Alfredo Faife

unread,
Aug 5, 2021, 11:28:54 AM8/5/21
to Rowan Seymour, rapidpro-dev
What should I do? how can   I get them installed?

Regards
Clerio Alfredo Faife

Clerio Alfredo Faife

unread,
Aug 5, 2021, 11:28:57 AM8/5/21
to Rowan Seymour, rapidpro-dev
Hi Rowan,

Thanks for your response, I  have tried version  6.4.8  with poetry as well,  and it does not work.
Find the  errors here: https://pastebin.com/GYnctfvY

The issue is in  Installing rcssmin (1.0.6): Failed

Regards
Clerio Alfredo Faife

On Thu, 5 Aug 2021 at 16:18, Rowan Seymour <rowans...@gmail.com> wrote:

Clerio Alfredo Faife

unread,
Aug 9, 2021, 11:34:04 AM8/9/21
to rapidpro-dev
Hi all, 

Im still stuck,  and    i'm  tacking  weeks  with no success,  can    someone  please help me

Regards
Clero Faife

Clerio Alfredo Faife

unread,
Aug 9, 2021, 11:50:00 AM8/9/21
to rapidpro-dev
I also  tried this docker compose  file my self,   but  it looks like the mailroom cant aceess db

attached the docker-compose .yaml   file:
docker-compose.yml

Clerio Alfredo Faife

unread,
Aug 9, 2021, 12:14:52 PM8/9/21
to rapidpro-dev
At least with docker i can have it  running  on my local machine,  the problem  comes when I try  to create  flows........

Here is the error when  I try to create  flow    running rapidpro  with docker  compose:



flow-error.png

but mailroom is running,  below mailroom logs:

mailroom-log.png

I would  to go with this approach  (container) as Im close to get it done, 

I would be glad if someone help me to sort it out.

Regards
Clerio Faife 

Allan Stockman rugano

unread,
Aug 9, 2021, 3:24:01 PM8/9/21
to rapidpro-dev
You need some of the libraries installed. Are you installing that on Debian based Linux distro? just install these libraries mentioned here https://stackoverflow.com/a/58415632/2219080 and especially the python3-dev (depending of the version of python you are using. For example I have installed it on python3.7 so I need to install apt-get install python3.7-dev. 

Clerio Alfredo Faife

unread,
Aug 10, 2021, 4:09:43 AM8/10/21
to rapidpro-dev

Thanks Allan for your feedback.

As per you suggested, I ran  apt-get install python3.7-dev  and now I am able to run   pip install -r pip-freeze.txt   on version  6.2.4(not the stable one). I finally succeeded installing the rapidpro version  6.2.4 on my local machine. Thank you so much.
 
As the documentation   says at https://rapidpro.github.io/rapidpro/docs/development/, if I intend to  deal with flows,  i can  download  the latest mailroom version from the Mailroom releases, and I did it, and it is also running,  The  thing is,  i cant configure  my android channel as I only can access  rapidpro via localhost/127.0.0.1 and not through my private  network IP address. 

Is there any additional  configuration  needed to access  local instance of rapidpro  via private network IP address?

Regards

Clerio Alfredo Faife

unread,
Aug 10, 2021, 11:50:22 AM8/10/21
to rapidpro-dev
Changed the setting.py.dev file at line   78 to  INTERNAL_IPS = ("127.0.0.1","192.168.100.2",)  where 192.168.100.2 is my valid local ip address.
But I still cant access through the local ip,  is  something  else missing???????????????

Allan Stockman rugano

unread,
Aug 10, 2021, 3:16:40 PM8/10/21
to rapidpro-dev
For the Android Channel, I think you will need a public IP to replace the one in the app. Your local one is not reachable over the internet. 

Clerio Alfredo Faife

unread,
Aug 10, 2021, 3:27:25 PM8/10/21
to Allan Stockman rugano, rapidpro-dev
Yes I do understand  that, for now I just want test on my local network. I need to reach the instance in the browser  through  my local IP address instead of 127.0.0.1

Clerio Alfredo Faife

unread,
Aug 10, 2021, 4:33:01 PM8/10/21
to rapidpro-dev
I just  ran  $ python manage.py runserver 0.0.0.0:8000 and it is working, i  can now sync rapidpro with my mobile device.... this is awesome :).

But I still can not create flows,  but i  have  mailroom running on  the same machine, when  I go to the  browser at http://localhost:8090/ I get this result:
{
      component: "mailroom",
      url: "/",
      version: "6.4.3"
}

Below mailroom logs:

ERRO[0000] fcm not configured, no syncing of android channels 
ERRO[0001] error while running cron                      cron=fire_schedules error="error while getting unfired schedules: error selecting unfired schedules: pq: relation \"triggers_trigger_exclude_groups\" does not exist" lock=lgTeMaPEZQ lockName=fire_schedules_lock



Rowan Seymour

unread,
Aug 10, 2021, 4:44:37 PM8/10/21
to Clerio Alfredo Faife, rapidpro-dev
You're trying to run incompatible versions of RapidPro and Mailroom - if you really need to run RapidPro 6.2.x then you need to run it with Mailroom 6.2.x as well

-Rowan

Clerio Alfredo Faife

unread,
Aug 10, 2021, 5:16:17 PM8/10/21
to rapidpro-dev
Thanks Rowan, 

I downgraded the    mailroom version to 6.2.2, I now I can create  flows. But the thing is this as described in the  print-screen below:

Screenshot from 2021-08-10 23-12-02.png

After create the flow,  the  next page never stops loading.

Rudi Giesler

unread,
Aug 11, 2021, 4:56:38 AM8/11/21
to Clerio Alfredo Faife, rapidpro-dev
Hi

The frontend is hardcoded to look at `/mr/` for mailroom, so what you need is a load balancer (like nginx), in front of all the components, and then you need to access rapidpro through the loadbalancer, so that `/` goes to django, and `/mr/` goes to mailroom.

See https://rapidpro.github.io/rapidpro/docs/mailroom/ for some example nginx configs.

Regards,
Rudi.

Clerio Alfredo Faife

unread,
Aug 11, 2021, 10:57:06 AM8/11/21
to rapidpro-dev
Thanks Rudi,

Now it works as expected,  I added NGINX as reverse proxy as  per you suggested and now it work like charm.

I will be putting my configs of nginx here,  might be useful for someone else:

   upstream mailroom_server {
      server 127.0.0.1:8090 fail_timeout=60;
   }

   upstream rapidpro {
      server 127.0.0.1:8000;
   }


   server {
      listen 80; 

      location / {
          proxy_pass http://rapidpro;
      }
      # all Mailroom URLs go to Mailroom
      location  /mr {
          proxy_set_header Host $http_host;
          proxy_pass http://mailroom_server;
          break;
      }
   }
Once again thanks  everyone. 
     

Reply all
Reply to author
Forward
0 new messages