FlaskBB
A lightweight forum software in Flask
Member
Joined:
Posts: 11

I am using pythonanywhere and since they don't have redis I am trying to configure flaskbb without it. when I try and start celery I get this message.

Cannot connect to amqp://guest:**@127.0.0.1:5672//: [Errno 111] Connection refused.
Trying again in 16.00 seconds...

I don't know what to do next!
CELERY_BROKER_URL ="" in my config file

Member
Joined:
Posts: 11

Presuming I need celery in order to send emails?

Administrator
avatar
Joined:
Posts: 139

Did you set REDIS_ENABLED to False? What did you exactly do that this error happens? Did you try to start celery? Or did you just try to start flaskbb?


Cheers! 🍻

Member
Joined:
Posts: 11

Yes I set REDIS_ENABLED = False

I ran
flaskbb --config /home/<username>/flaskbb/flaskbb.cfg celery worker

to start celery. Flaskbb is already running. It is live and functions as normal except on the maintenance page it warns that celery is not running. It looks like it is trying to use Redis despite the config?

Administrator
avatar
Joined:
Posts: 139

Oh ok. In that case, just ignore the warning. Could you try if sending mails is still possible? If not, could you open a new issue on github? :)


Cheers! 🍻

Member
Joined:
Posts: 5

I would like to know what is Celery used for? I am running FlaskBB without it and my activation e-mails are being sent, but when I open the link, it says the token is invalid.

Administrator
avatar
Joined:
Posts: 139

podlomar wrote:

I would like to know what is Celery used for? I am running FlaskBB without it and my activation e-mails are being sent, but when I open the link, it says the token is invalid.

Celery is used for sending non blocking emails. Could you try if this is happening when you have celery running?


Cheers! 🍻

Member
Joined:
Posts: 5

Ok, now I have redis + celery running. I run celery with the command

flask --config None celery worker -E

I have installed the forum from scratch. I have standard postfix service running. The activation e-mail from the first registered user arrived, though the activation link did not work (Server error: invalid token). After that activation e-mails stopped arriving at all. Maybe it is because I am using the same e-mail for testing. So I always register a user, if the e-mail does not come in 15 minutes or so, I delete the user and create a new one with the same e-mail. Nevertheless, the first e-mail to the adress arrived ok, but as I said, the link did not work.

Member
Joined:
Posts: 5

Well ok, the undelivered e-mails may have been some bug in my postfix conf, but the activation still gives me an error of invalid activation token

Administrator
avatar
Joined:
Posts: 139

podlomar wrote:

Ok, now I have redis + celery running. I run celery with the command

flask --config None celery worker -E

I have installed the forum from scratch. I have standard postfix service running. The activation e-mail from the first registered user arrived, though the activation link did not work (Server error: invalid token). After that activation e-mails stopped arriving at all. Maybe it is because I am using the same e-mail for testing. So I always register a user, if the e-mail does not come in 15 minutes or so, I delete the user and create a new one with the same e-mail. Nevertheless, the first e-mail to the adress arrived ok, but as I said, the link did not work.

what does the token look like? btw, you have to run celery with the same config as you run flaskbb so setting --config None isn't a good idea probably.


Cheers! 🍻