Coder Social home page Coder Social logo

Comments (10)

xlanor avatar xlanor commented on June 11, 2024

Are you opening a file and not closing it properly anywhere?

from sneakpeek.

fterh avatar fterh commented on June 11, 2024

Nope. I suspect it ran out of memory or something, because this's happened before, and it's always after a few days.

@yleong suggested running it as a system service I think, so this might be low priority if we're able to rewrite how the program is run.

from sneakpeek.

xlanor avatar xlanor commented on June 11, 2024

If you are planning to do a refactor, I strongly suggest that the files be regrouped, minimally, into an src/ drive and tests/ drive respectively for source code and test files.

from sneakpeek.

yleong avatar yleong commented on June 11, 2024

The Reddit API was returning a HTTP response status of 503 Service Unavailable when praw is trying to call response = self._authenticator._post(url, **data) to get new submissions.
The relevant line is prawcore.exceptions.ResponseException: received 503 HTTP response. (source here) The rest of it looks to be this exception being thrown up the stack until it hits some sort of stdin handler.
I think we can catch this response here and retry the request after waiting for a bit, since 503 sometimes indicates an overloaded server. This can be done in addition to running it under pm2 or systemd to ensure higher uptime.

Regarding the code refactor, I am not familiar with Python project structure, but what @xlanor suggested makes sense.

from sneakpeek.

yleong avatar yleong commented on June 11, 2024

Are there more crash logs available?

from sneakpeek.

fterh avatar fterh commented on June 11, 2024

Yup!

nohup.txt

from sneakpeek.

yleong avatar yleong commented on June 11, 2024

Ricemedia handler also threw exception. I have opened #19 to track that separately.

from sneakpeek.

fterh avatar fterh commented on June 11, 2024

@yleong I checked the PRs and I saw you merged one which fixes this. Can I close this issue and prepare to create a new release?

from sneakpeek.

yleong avatar yleong commented on June 11, 2024

Sure. If the program still crashes maybe we can reopen.

from sneakpeek.

fterh avatar fterh commented on June 11, 2024

Okay, closing this for now. @yleong @xlanor I'm pushing v0.5.0-beta into production, I've run manual tests and it looks good.

from sneakpeek.

Related Issues (17)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.