New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Implement a LastLogAcitivity check #99
Conversation
f3f9121
to
3e509b9
Compare
Codecov Report
@@ Coverage Diff @@
## master #99 +/- ##
==========================================
+ Coverage 97.31% 97.34% +0.03%
==========================================
Files 11 11
Lines 1153 1205 +52
Branches 128 137 +9
==========================================
+ Hits 1122 1173 +51
- Misses 21 22 +1
Partials 10 10
Continue to review full report at Codecov.
|
3e509b9
to
b76de5a
Compare
b76de5a
to
1ca2d53
Compare
@niram8 would you mind giving this check a try? This should solve your log file problem without a shell script. |
1ca2d53
to
fe46e3f
Compare
I would be happy to test. I do not know how to do it. How can I update my current autosuspend installation to test the new feature? And how should the autosuspend config file look like? |
Parses a log file and uses that first timestamp found when iterating the file starting from the last line. Will fix #98
fe46e3f
to
c34602b
Compare
You need to install autosuspend from the development source to test this. Ideally, you deinstall the existing package before testing (you should back up your existing config file before doing that). I have updated the from-source installation instructions in the manual to make the installation of the update version more easy for you: https://autosuspend.readthedocs.io/en/latest/installation.html#manual-installation. Use |
I got the following error while I tried to install the brannch feature/98-last-log-time-check:
There is already a file "pip" in directory "/opt/autosuspend/bin/" but no directory "pip" The process is difficult for me as a non-linux user |
You have to execute the two lines in the instruction in two separate invocations, not a single one. |
Still errors. Here the output:
A lot of things happen if I use "master" instead of "eature/98‐last‐log‐time‐check" |
That is very strange. I just copy and pasted your git URL and it doesn't work. When I build the URL on my own it works. Looks like there is some invisible control character inside. Please try this one: git+https://github.com/languitar/autosuspend.git@feature/98-last-log-time-check#egg=autosuspend[all] |
Still error:
|
That was only the URL, not the whole command to execute. python3 -m venv /opt/autosuspend
/opt/autosuspend/bin/pip install git+https://github.com/languitar/autosuspend.git@feature/98-last-log-time-check#egg=autosuspend[all] That's what you need to execute. |
Run through. But a lot of error messages in the output , see attached file (hope it works how I attached the file) |
Ah, you are missing the python development headers. That prevents a native dependency from compiling. Do the following to install them: apt-get install python3-dev build-essential Maybe that's enough to make things work. |
Apparently not so eay. See attached file. |
You didn't complete the package installation but cancelled it. |
Sorry I forgot the -y parameter (apt-get install python3-dev build-essential) Otherwise it does not work on my system (forwhatever reason) |
At least yet another missing package for enabling compilation:
Maybe afterwards it gets further. |
Still error. |
I suspect you need to install |
Which package should I install? I looked on the web but cannot identify it. Maybe you could give me the complete apt-get install command. |
? |
This gives the error: Unable to locate package dbus-1-dev |
I am not sure on what Linux distribution you are running. Maybe the package is called |
My linux distribution is: turnkey-nextcloud-16.0-buster-amd64 But I think I give it up. I cannot manage the manual install I further installed: Still errors (see attached file) |
That's normal. You do not have the development headers for some packages which need to be installed before the autosuspend installation can succeed. The pattern is always the same. In case something is missing the appropriate -dev package needs to be installed. Your suspicion with |
I'll just merge this for now. In my test cases this works. If something doesn't work as expected once this is released, please open an new issue. |
🎉 This PR is included in version 3.1.0 🎉 The release is available on GitHub release Your semantic-release bot 📦🚀 |
Parses a log file and uses that first timestamp found when iterating the
file starting from the last line.
Will fix #98