sympy-bot icon indicating copy to clipboard operation
sympy-bot copied to clipboard

Heroku ending free tier

Open asmeurer opened this issue 1 year ago • 9 comments

Heroku is ending their free tier, starting November 28, 2022. https://blog.heroku.com/next-chapter

Once this happens the bot will stop working, unless we switch to a paid plan. We can request open source credits from them. I am emailing them to make the request.

If they don't give us credits, we should consider moving the bot activities to GitHub actions. This will be easier to maintain, but the downside is that actions run much slower than the bot.

asmeurer avatar Aug 25 '22 18:08 asmeurer

There are also Heroku alternatives https://twitter.com/jacobian/status/1562833339345936385. It might be just as much work to move to them as to GitHub Actions, though, so if we are going to move, IMO we should just move to GitHub Actions for the increased maintainability. TBH I would have just used GitHub Actions for this if it had existed when I started, even though I've been pretty happy with the speed and overall reliability of Heroku.

asmeurer avatar Aug 25 '22 18:08 asmeurer

Heroku has graciously granted us credits through January with their open source credits program, but they have told me that the program will not be extended further than that, so we need to either come up with an alternative or pay for Heroku credits (the credits they have granted us are $7/mo. so I expect it may cost roughly that much).

CC @certik @oscarbenjamin

asmeurer avatar Dec 01 '22 05:12 asmeurer

I switched over to render.com. It still has a free tier. Maybe that is an option?

moorepants avatar Dec 01 '22 10:12 moorepants

I think $7/month is fine to pay if needed.

certik avatar Dec 01 '22 13:12 certik

Looks like render does have a free tier https://render.com/docs/free. Here is their Heroku migration guide https://render.com/docs/migrate-from-heroku.

asmeurer avatar Dec 01 '22 20:12 asmeurer

Trying render at #102, but currently it isn't working.

I'm also trying replit, which has a Heroku import (https://replit.com/@asmeurer/sympy-bot). I set up the secrets and the webhook for replit, but it isn't working. I get the error

Traceback (most recent call last):
  File "/home/runner/sympy-bot/venv/lib/python3.8/site-packages/aiohttp/web_protocol.py", line 433, in _handle_request
    resp = await request_handler(request)
  File "/home/runner/sympy-bot/venv/lib/python3.8/site-packages/aiohttp/web_app.py", line 504, in _handle
    resp = await handler(request)
  File "/home/runner/sympy-bot/sympy_bot/webapp.py", line 33, in main_post
    event = sansio.Event.from_http(request.headers, body, secret=secret)
  File "/home/runner/sympy-bot/venv/lib/python3.8/site-packages/gidgethub/sansio.py", line 131, in from_http
    raise ValidationFailure("secret not provided")
gidgethub.ValidationFailure: secret not provided

asmeurer avatar Dec 09 '22 00:12 asmeurer

OK, I got replit to work (it wasn't obvious from the interface, but you have to manually restart it when you add an environment variable). So the bot should be live again for now. Replit is pretty clunky in my experience with it so far, but we'll see.

asmeurer avatar Dec 09 '22 00:12 asmeurer

Just opened a PR (https://github.com/sympy/sympy/pull/24361) and the bot didn't show up until I fiddled with it. So that's not a good sign for replit.

Meanwhile, Heroku support isn't being particularly helpful (they're just telling me to do the things I've already tried doing).

asmeurer avatar Dec 10 '22 01:12 asmeurer

Got Heroku running again. I have disabled the replit webhook, but it can be reenabled to make it work again (you may also have to go to https://replit.com/@sympy/sympy-bot and manually start it, which probably only I have access to do right now). Replit kept turning off and doesn't seem to consistently wake itself up when it receives a webhook, so I'm not a fan of it.

I never figured out the problem with the render deploy #102.

asmeurer avatar Dec 15 '22 22:12 asmeurer