I've done a little bit of research, but I cannot seem to find a way to handle if two users have sent data in, but the Python script can only handle one.
This is typically how the script works:
1) User Enters Data '123'
2) Python listener executes on Data
|
| Sends requests to server and retrieves data (typically ~1 min)
| Script writes to HTML files
|
3) Finishes writing to files, waits for more User input
Now the problem is that if another user enters data during that step 2 - 3 stage, the script is no longer listening, and will not do anything with this data.
Is there anyway that I can have it always listen for a change, and once it does, pass it onto a class or another entity of itself so it can continue to listen for another asynchronous change?
EDIT:
- The User enters the Data on a website, which is consequently written to a text file.
- The Python script currently checks the last modified line in this file to see if it differs from the previous check. If this check results in true, then execute the class with the modified line