Development: Indexed Inputs

ok that seems to have worked

although i’m a little confused as to what happened as there are no duplicated inputs from inbetween switching branches and running the populateindexes api.

Great! If you try changing the name for a particular input now it should continue to update that input as before, demonstrating that csv data is allocated based on indexes rather than the names.

You can then try posting a json value e.g node=10&data=voltage:24000 and that will update based on names rather than indexes.

Scrap that!

Although the inputs got indexed and initially it looked like it was updating it stopped updating

when i checked emonhub i was getting a 401 error from the server so I switched back to master branch and the backlog was uploaded and now updating again

However when i switched back to indexedinputs again to confirm, it seems to be working fine again.

looking in the emonhub logs I have thousands of these returned in place of “ok” for the time it was not updating a few minutes after populating the indexes.

<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/test/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/test/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />

This is nuts!

In the time it’s taken me to write that post it has stopped again, despite me checking it was working ok on both branches,

Same fault in emonhub, I will post a log in a moment, I just need to remove some details.

ok, forget the 401, I had an old emoncms interfacer still trying to post to an account i deleted recently. The errors that relate to this are the “Missing argument 5” and “Cannot modify header information”

2018-09-21 16:56:28,208 DEBUG 1950182 NEW FRAME : 1537545388.2 OK 10 222 92 143 0 51 0 2 0 245 5 (-60)
2018-09-21 16:56:28,215 DEBUG 1950182 Timestamp : 1537545388.2
2018-09-21 16:56:28,218 DEBUG 1950182      Node : 10
2018-09-21 16:56:28,220 DEBUG 1950182    Values : [23774, 143, 51, 2, 1525]
2018-09-21 16:56:28,223 DEBUG 1950182      RSSI : -60
2018-09-21 16:56:28,290 INFO emonCMS-TEST2 sending: https://TEST2.myserver.co.uk/input/bulk.json?apikey=E-M-O-N-C-M-S-A-P-I-K-E-Y&data=[[1537544812.01,25,195,0,607,26,1,0,-59],[1537544813.23,10,23714,-83,310,77,1537,-60],[1537544814.43,30,3,399632704,-69],[1537544818.26,10,23678,-73,302,50,1537,-61],[1537544819.27,30,3,399637704,-72],[1537544823.38,10,23659,-65,296,46,1537,-56],[1537544824.4,30,3,399642704,-68],[1537544828.17,10,23665,-78,289,24,1537,-61],[1537544833.35,10,23649,-100,285,2,1537,-61],[1537544834.36,30,3,399652704,-71],[1537544838.33,10,23651,-91,279,3,1537,-61],[1537544839.54,30,3,399657704,-72],[1537544843.27,10,23625,-88,273,2,1537,-60],[1537544844.32,30,3,399662704,-79],[1537544848.31,10,23639,-79,266,2,1537,-60],[1537544849.33,30,3,399667704,-67],[1537544853.32,10,23660,-68,258,3,1537,-54],[1537544854.35,30,3,399672704,-73],[1537544858.36,10,23663,-68,257,3,1537,-61],[1537544862.12,19,207,0,581,28,-38],[1537544863.41,10,23649,-64,250,2,1537,-63],[1537544864.52,30,3,399682704,-73],[1537544868.32,10,23661,-53,244,3,1537,-61],[1537544869.09,26,201,0,556,18,1,0,-36],[1537544869.38,30,3,399687704,-70],[1537544870.42,25,195,0,607,26,1,0,-59],[1537544873.28,10,23653,-55,239,2,1537,-62],[1537544874.36,30,3,399692704,-73],[1537544878.29,10,23639,-46,235,3,1531,-60],[1537544879.3,30,3,399697704,-70],[1537544884.35,30,3,399702704,-69],[1537544888.34,10,23675,-34,225,2,1537,-60],[1537544893.21,10,23668,-27,218,2,1537,-61],[1537544894.3,30,3,399712704,-76],[1537544898.26,10,23671,-21,211,3,1531,-60],[1537544899.52,30,3,399717704,-72],[1537544903.28,10,23666,-16,206,3,1537,-61],[1537544904.33,30,3,399722704,-75],[1537544908.19,10,23679,-9,199,3,1531,-60],[1537544909.5,30,3,399727704,-71],[1537544913.33,10,23689,-9,198,3,1531,-56],[1537544914.38,30,3,399732704,-73],[1537544918.17,10,23689,-1,190,2,1537,-60],[1537544921.01,19,207,0,581,28,-38],[1537544923.28,10,23686,2,187,3,1537,-61],[1537544924.34,30,3,399742704,-68],[1537544928.19,10,23679,7,184,2,1531,-60],[1537544929.25,25,195,0,606,27,1,0,-60],[1537544929.59,30,3,399747704,-73],[1537544929.85,26,201,0,556,18,1,0,-36],[1537544933.29,10,23667,11,178,2,1537,-62],[1537544934.37,30,3,399752704,-72],[1537544938.14,10,23664,16,173,2,1537,-60],[1537544939.25,30,3,399757704,-74],[1537544943.24,10,23661,24,167,3,1531,-69],[1537544944.27,30,3,399762704,-74],[1537544948.25,10,23654,24,166,3,1531,-60],[1537544953.18,10,23684,31,160,2,1531,-60],[1537544954.3,30,3,399772704,-67],[1537544958.35,10,23675,37,156,3,1531,-60],[1537544959.33,30,3,399777704,-70],[1537544963.35,10,23666,41,151,2,1531,-61],[1537544964.43,30,3,399782704,-74],[1537544968.19,10,23668,51,147,3,1531,-60],[1537544969.45,30,3,399787704,-73],[1537544974.41,30,3,399792704,-73],[1537544978.2,10,23671,59,138,2,1537,-61],[1537544980.31,19,207,0,581,28,-39],[1537544983.16,10,23680,64,134,2,1537,-62],[1537544984.47,30,3,399802704,-67],[1537544987.99,25,195,0,607,26,1,0,-59],[1537544988.29,10,23676,70,128,3,1531,-61],[1537544989.37,30,3,399807704,-68],[1537544989.9,26,201,0,556,18,1,0,-37],[1537544993.23,10,23676,71,124,3,1537,-62],[1537544994.28,30,3,399812704,-70],[1537544998.3,10,23687,75,120,2,1531,-61],[1537544999.34,30,3,399817704,-69],[1537545003.32,10,23706,84,116,3,1531,-61],[1537545004.44,30,3,399822704,-69],[1537545008.39,10,23706,88,109,2,1531,-60],[1537545013.18,10,23707,96,106,2,1537,-60],[1537545014.41,30,3,399832704,-67],[1537545018.13,10,23719,94,101,2,1531,-60],[1537545019.4,30,3,399837704,-70],[1537545023.17,10,23739,98,99,2,1537,-60],[1537545024.26,30,3,399842704,-68],[1537545028.18,10,23722,104,95,2,1531,-61],[1537545029.43,30,3,399847704,-66],[1537545033.17,10,23713,104,91,2,1531,-54],[1537545034.48,30,3,399852704,-73],[1537545038.24,10,23725,112,88,2,1531,-61],[1537545039.28,19,207,0,581,28,-39],[1537545043.28,10,23727,110,87,2,1531,-64],[1537545044.33,30,3,399862704,-67],[1537545046.58,25,195,0,606,27,1,0,-60],[1537545048.29,10,23727,112,86,2,1531,-61],[1537545049.34,30,3,399867704,-65],[1537545050.17,26,201,0,556,18,1,0,-36],[1537545053.15,10,23733,119,81,2,1531,-62]]&sentat=1537545388
2018-09-21 16:56:28,329 DEBUG 1950182 Append to 'emonCMS-LIVE' buffer => time: 1537545388.2, data: [10, 23774, 143, 51, 2, 1525, -60], ref: 1950182
2018-09-21 16:56:28,570 WARNING emonCMS-TEST2 send failure: wanted 'ok' but got '<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Missing argument 5 for InputMethods::process_node(), called in /var/www/TEST2/emoncms/Modules/input/input_methods.php on line 269 and defined in <b>/var/www/TEST2/emoncms/Modules/input/input_methods.php</b> on line <b>281</b><br />
<br />
<b>Warning</b>:  Cannot modify header information - headers already sent by (output started at /var/www/TEST2/emoncms/Modules/input/input_methods.php:281) in <b>/var/www/TEST2/emoncms/index.php</b> on line <b>246</b><br />
ok'
2018-09-21 16:56:28,592 DEBUG 1950182 Append to 'emonCMS-TEST2' buffer => time: 1537545388.2, data: [10, 23774, 143, 51, 2, 1525, -60], ref: 1950182

… and it still hasn’t started updating again since the last branch switch

Switched to master and it’s updating again, it’s backfilling the buffered data, but when it is up to date I will switch branches and time how long it lasts

Switched to indexedinputs branch at 17:25

at 17:29 it’s still ok, but I am tailing the emonhub log and those errors are being returned all the time, even when the inputs page is being updated ok.

[EDIT]

17:31 it has stopped again

[EDIT2]

It reached 7mins (last updated) then when down to 4mins, back up to 7mins down to 5mins and back up again.

When i switch to master the update comes down and remains under 10s.

I’ll keep an eye on it but I’m pretty sure there is no network delays etc, I’m pretty sure the indexedinputs branch is (randomly?) updating or rejecting data without apparent rhyme or reason. I’ve checked the emonhub.logs since going back on master and there are no errors or unsuccessful posts at all.

[EDIT3] Still going strong at 17:54 and the logs are clear of errors

[EDIT4] still good at 21:25, no errors and under 10s since last updated, it’s definitely an indexedinputs branch issue.

Aha, testing with input/post rather than input/bulk led me to missing the error. I’ve uploaded a fix now.

Great, have you pushed those changes up to github? I can’t see any new changes.

Oops tried uploading from the wrong place, here it is fix missing names parameter · emoncms/emoncms@f46db21 · GitHub

1 Like

Unfortunately that’s not fixed it. Is there anything else i should have done other than pull in the changes?

The 1 previous error in emonhub.log has now morphed into these 2

<b>Notice</b>:  Undefined index: index in <b>/var/www/TEST2/emoncms/Modules/input/input_model.php</b> on line <b>214</b><br />
<br />
<b>Notice</b>:  Undefined index: index in <b>/var/www/TEST2/emoncms/Modules/input/input_model.php</b> on line <b>215</b><br />
<br />

Some more info.

This setting in settings.php is playing a part in this too

    // Show all fatal PHP errors
    $display_errors = true;

Originally this was set to the default “true” (the wrong default IMO given the number of user using emonhub) and errors were being returned with the “ok” so the response doesn’t === “ok” (it ends in “ok”) so emonhub keeps resending the same data.

Do you have this setting “true” or “false” ?

With it set to true and I use the following bulk api request in a browser I get multiple errors as shown below.

https://myserver.co.uk/input/bulk.json?apikey=abc123&data=[[1537626752.5,10,23912,620,537,40,1431,-58],[1537626757.32,10,23933,691,540,4,1431,-59]]&sentat=1537626758
<br />
<b>Notice</b>:  Undefined index: index in <b>/var/www/TEST2/emoncms/Modules/input/input_model.php</b> on line <b>214</b><br />
<br />
<b>Notice</b>:  Undefined index: index in <b>/var/www/TEST2/emoncms/Modules/input/input_model.php</b> on line <b>215</b><br />
<br />
<b>Notice</b>:  Undefined index: index in <b>/var/www/TEST2/emoncms/Modules/input/input_model.php</b> on line <b>214</b><br />
<br />
<b>Notice</b>:  Undefined index: index in <b>/var/www/TEST2/emoncms/Modules/input/input_model.php</b> on line <b>215</b><br />
<br />
<b>Notice</b>:  Undefined index: index in <b>/var/www/TEST2/emoncms/Modules/input/input_model.php</b> on line <b>214</b><br />
<br />
<b>Notice</b>:  Undefined index: index in <b>/var/www/TEST2/emoncms/Modules/input/input_model.php</b> on line <b>215</b><br />
<br />
<b>Notice</b>:  Undefined index: index in <b>/var/www/TEST2/emoncms/Modules/input/input_model.php</b> on line <b>214</b><br />
<br />
<b>Notice</b>:  Undefined index: index in <b>/var/www/TEST2/emoncms/Modules/input/input_model.php</b> on line <b>215</b><br />
<br />
<b>Notice</b>:  Undefined index: index in <b>/var/www/TEST2/emoncms/Modules/input/input_model.php</b> on line <b>214</b><br />
<br />
<b>Notice</b>:  Undefined index: index in <b>/var/www/TEST2/emoncms/Modules/input/input_model.php</b> on line <b>215</b><br />
<br />
<b>Notice</b>:  Undefined index: index in <b>/var/www/TEST2/emoncms/Modules/input/input_model.php</b> on line <b>214</b><br />
<br />
<b>Notice</b>:  Undefined index: index in <b>/var/www/TEST2/emoncms/Modules/input/input_model.php</b> on line <b>215</b><br />
<br />
<b>Notice</b>:  Undefined index: index in <b>/var/www/TEST2/emoncms/Modules/input/input_model.php</b> on line <b>214</b><br />
<br />
<b>Notice</b>:  Undefined index: index in <b>/var/www/TEST2/emoncms/Modules/input/input_model.php</b> on line <b>215</b><br />
<br />
<b>Notice</b>:  Undefined index: index in <b>/var/www/TEST2/emoncms/Modules/input/input_model.php</b> on line <b>214</b><br />
<br />
<b>Notice</b>:  Undefined index: index in <b>/var/www/TEST2/emoncms/Modules/input/input_model.php</b> on line <b>215</b><br />
ok

when I set it to false I just get “ok” with no grumbles.

By setting this to “false” emonhub no longer gets the errors from emoncms and it seems to be running just fine, except every now and again I notice the “updated” time is ~120s so it is still hiccuping somewhere and the errors reported are not fixed, they are just not reported.

This also begs the question what is a “fatal PHP error” as these error don’t seem to be fatal, however reporting the errors makes them fatal if running emonhub. This has been discussed before so I don’t expect any change, but anyone running emonhub or any system that relies on a response === “ok” must change that setting to “false”. (This being a test setup I run it as close to stock as possible, my live servers are “false”)

That said, there is still an issue in indexedinputs to be resolved that might have been missed if that setting had been set to true, so I’m going to switch back to “true” on this test server.

[edit] This also makes me question what drives the “Updated” field on the inputs page, assuming emoncms WAS processing the data and just grumbling about it in the response, causing emonhub to repost the same data again and again, why does the input page show it’s not updating when it is ?

[EDIT2]
Yup, the inputs page is sporadically lying to us as well!

Here’s a screenshot of a realtime visualisation at 1min resolution of the voltage feed, you can see from the timeline and my desktop clock, that is bang up to date whilst the input page says 158s since “Updated”.

[EDIT3]

But eventually it stops

Notice the error dialog box on the realtime graph,

Uncaught TypeError: Cannot read property ‘0’ of undefined

[EDIT4]

Changing the resolution on the realtime graph to one hour shows that it stopped updating at 16:23 or 16:24 around 4 or 5 minutes after the input page suggested the updates stopped.

The missing index error would happen if the redis cache of the inputs did not include the index. Calling

http://localhost/emoncms/input/populateindexes.json 

should reload the redis cache to include the index and hopefully sort that error, although I imagine you have already ran this so Im not sure why the inputs did note have the index present…

I have

$display_errors = true;

Your test bulk api call works fine for me.

Is there any chance that you have phpmqtt_input running in the background, or somehow two emoncms instances running on the same database? causing these intermittency issues?

There is no mqtt installed at all on this server

This emoncms instance is on the same host as one of my live instances, they do not share a database table, obviously they both use the same mysql server (different users) and redis too (different prefixes though). They are on separate ip’s, domain names and virtual hosts, they don’t even share ssl cert and the feed data is on different drives, So they are pretty well isolated.

It isn’t really that intermittent, with $display_errors = true on master branch it’s perfectly ok, with $display_errors = false on indexedinputs branch it is pretty solid too, I had noticed some occasional 100 ~120 s Updated times but not recently, so I could put that down to dodgy wifi or something, I certainly cannot reproduce it this afternoon. And with $display_errors = true on indexedinputs branch it is permanently returning errors to every request, but emoncms seems to soldier on for a while but eventually it always fails, it has now come to light that the input page “Updated” times show an issue before the processing actually stops and produces no feed data, it’s as if it’s getting clogged up, perhaps it’s linked to the size of the payloads emonhub is dropping on it since they will progressively get bigger as the errors prevent emonhub from deleting the previously sent data. Or is emoncms buffering something and eventually tripping up, maybe in stages?

It’s certainly not intermittent in the fact it will fail, it’s just the time and behavior prior to failing is currently less predictable.

Ok good to hear, does running

http://localhost/emoncms/input/populateindexes.json 

get rid of the index missing error?

Yes, apparent so!

But I have definitely run that previously and aside from switch branches I have not rebooted, flushed redis or made any changes to the mysql tables so i have no idea why that needs running again.

Having said that, I think I should wait half an hour or so to be sure it doesn’y eventually fail, but the fact there are no errors coming back in the response from emoncms in the emonhub.logs looks very promising as i was getting those errors permanently, even in the initial minutes before it eventually failed.

[edit] is there a reason the populateindexes cannot go inline with the input processing? I’m not keen on a separate script even if it was a successful single shot thing. This will trip up users updating without knowing about this in advance.

I was just looking through the indexinputs PR/diff and noticed the word “index” is always wrapped in backticks in mysql statements as it is a mysql reserved word. Knowing that, would it not be better to avoid using that word and use “idx” or “input_index” or something similar instead? It’s easy to change now (before wide adoption), but down the road, less so, and it may prove problematic, even if edits are made to the code and the backticks forgotten etc. It just seems an unnecessary risk/evil when any word could be used.

Could the handling of this be different for mysql and mariadb or different version numbers or OS’s?

It’s a longshot I know, but I’m running dry on idea’s.

Something else that’s been on my mind that relates to the fact I had to rerun the populateindedex api call is that late last night I ran the db update again as I’m switching branches and testing multiple things here so db update and clearing browser cache are happening very frequently, and on this occasion it told me there was an update to the user table “index” field, I clicked it and got a green “ok” banner.

I know without any shadow of a doubt I have updated the db several times since running the populateindexes api the second time, and many more times since i did it the first time. So I have to wonder why that change is either not sticking indefinitely or at least being perceived as such by the check db code.

Initially I wanted to avoid adding a checking overhead, but I think it should be possible, and likely needed for its adoption.

Yes we could use a different name at this point, might go for your short hand idx.

I will modify to try both of these.

Ok, auto index population, change of index name to indx and phpmqtt_input support are now implemented:

Change of index name to indx:

Autopopulation of index:

phpmqtt_input support:

1 Like