Open kvdmolen opened 9 years ago
I had this set up per the instructions but there was a small bug preventing it from executing properly.
It appears to be working now, but will have to be manually restarted if the server is rebooted.
On Thu, Apr 9, 2015 at 2:38 AM, Klaas van der Molen < notifications@github.com> wrote:
This Issue should have moved to the next phase: http://178.62.254.91/lf/issue/show/2.html
I don't know how that should work, but I can imagine it's some sort of server-side cronjob..?
— Reply to this email directly or view it on GitHub https://github.com/Socioneers/LiquidVoting/issues/21.
No problem. Small manual after server-reboot could then be useful at some point :)
Still seems to hang (only for the last voting-phase it seems, perhaps different job, since it should close the issue and calculate winners and so):
Now it seems to be running again.. perhaps it takes some time.. please double-check, this is pretty important..
Now new issues are directly set to "discussion" phase, skipping admission.
Also please check again the 00 days 00:00:00 which is a little weird as the issue should then be closed
Yes there is a test-case: if you look at this issue http://178.62.254.91/lf/issue/show/20.html it is actually "finished" status disapproved. Also the button "vote now" is gone.
Unlike here http://178.62.254.91/lf/issue/show/18.html where the button is still there (and the last phase is still highlighted).
Clicking the "vote now" button in above page will generate an error, perhaps that is related? Otherwise I'd have no clue either.. can you send the location of the cron-job file?
/opt/LiquidVoting/frontend/model/issue.lua:134: member_id mandatory for member_info
Stack trace follows:
[C]: in function 'assert'
/opt/LiquidVoting/frontend/model/issue.lua:134: in function 'selector_generator'
../lib/mondelefant.lua:1250: in function <../lib/mondelefant.lua:1243>
(...tail calls...)
../lib/mondelefant.lua:1334: in function <../lib/mondelefant.lua:1333>
[C]: in function '__index'
/opt/LiquidVoting/frontend/app/main/issue/_head.lua:36: in function 'content'
../env/ui/tag.lua:38: in function 'tag'
/opt/LiquidVoting/frontend/env/ui/title.lua:23: in function 'content'
../env/ui/tag.lua:38: in function 'tag'
...
/opt/LiquidVoting/frontend/app/main/_filter/20_session.lua:26: in function 'func'
../env/execute/file_path.lua:24: in function 'file_path'
../env/execute/_add_filters_by_path.lua:17: in function 'wrapper_func'
../env/execute/wrapped.lua:21: in function <../env/execute/wrapped.lua:11>
(...tail calls...)
../env/execute/filtered_view.lua:28: in function 'filtered_view'
webmcp.lua:382: in function <webmcp.lua:257>
[C]: in function 'xpcall'
webmcp.lua:256: in main chunk
[C]: in function 'pcall'
/opt/webmcp/cgi-bin/webmcp-wrapper.lua:7: in main chunk
[C]: in ?
The cron script is /opt/LiquidVoting/lf_updated.sh
. You will see that I have commented out logging to syslog.
I am running in tmux (terminal multiplexer) so it will persist when I logout.
I don't think the "vote now" error above was related to this.
As far as why the phases are not updating, my understanding is that it's the linked c code that does this. I have set it up according to the documentation and it appears to run with no errors:
/home/admin/src/LiquidVoting/core
% ./lf_update dbname=liquid_feedback_01 && ./lf_update_issue_order dbname=liquid_feedback_01 && ./lf_update_suggestion_order dbname=liquid_feedback_01 && echo ok
ok
Beyond that the only want to figure out why it does not work is to go line by line in the C files, which is a big job. In my opinion it's overkill in a really amazing way that these updates were done in C.
A further complexity -- the C files themselves are referring to several non-trivial stored procedures. Debugging this will take some time, and in my opinion it might be easier to just throw out this mess and write something simple in, let's say python, that is the equivalent of:
while true
if (...)
advance_phase
Ok, thanks for the investigation. Rewrite in Python will definitely be the better option.
But, if it works, it works, and indeed now i think that the "voting phase" issue is like this:
Is it still in the voting phase if the "Half frozen at 2015-04-22 17:53:08" date is in the past?
Ok, please put this on hold, we'll figure out this thing.
I assume indeed the cron-script is simply working as expected.
This Issue should have moved to the next phase: http://178.62.254.91/lf/issue/show/2.html
I don't know how that should work, but I can imagine it's some sort of server-side cronjob..?