Python Forum
Web App That Request Data from Another Web Site every 12-hours
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Web App That Request Data from Another Web Site every 12-hours
#4
(Sep-21-2018, 07:58 PM)nilamo Wrote: I vote against time.sleep for 12(!!) hours. For one thing, if you logout or the machine restarts, then your script never runs again. I would set it up as two completely independent things. There's a web app, that takes some data and displays it. Then there's a second script that updates that data. The web app doesn't need to care about how often the data is updated, it just pushes it to the browser. And the second script also shouldn't care about how often it should run, it should just fetch the page, and update the data, every time it's run. And then run the update script once every 12 hours using cron. https://en.wikipedia.org/wiki/Cron
Thank you for your answer. So, if I deploy my web app, the server will run my main app script right? And if I want to send a request to another web site and monitor it through my app, does the server able to execute the other independent script which uses cron?
Reply


Messages In This Thread
RE: Web App That Request Data from Another Web Site every 12-hours - by jomonetta - Sep-22-2018, 12:31 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  How to scraping data from dinamic site sergio21124444 2 780 Nov-08-2023, 12:43 PM
Last Post: sergio21124444
  POST request with form data issue web scraping hoff1022 1 2,742 Aug-14-2020, 10:25 AM
Last Post: kashcode
  Scraping a dynamic data-table in python through AJAX request filozofo 1 3,936 Aug-14-2020, 10:13 AM
Last Post: kashcode
  How to retrieve data from site ROHK 2 2,491 Mar-01-2019, 12:26 PM
Last Post: ROHK
  Mechanize and BeautifulSoup read not correct hours vaeVictis 5 4,520 Jan-15-2019, 01:27 PM
Last Post: metulburr

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020