Page 41 of 48

Re: Dashticz - Module - Garbage collector

Posted: Thursday 14 January 2021 12:58
by JuanUil
Hi,
Getting further and further with this wonderful dashboard.
today tried to implement trash.
When implemented this in config.js
Spoiler: show
//Blocks
var blocks = {} //only once

// --------------------------------------------------------------------------------------------
// Garbage Collector
// --------------------------------------------------------------------------------------------

config['garbage_company'] = 'blink';
config['garbage_zipcode'] = '5721GW';
config['garbage_street'] = 'Kerkstraat';
config['garbage_housenumber'] = '74';
config['garbage_maxitems'] = '4';
config['garbage_width'] = '5';
config['garbage_use_names'] = true;
config['garbage_use_colors'] = true;

config['garbage'] = {
gft: {kliko: 'green', code: '#375b23', name: 'GFT'},
pmd: {kliko: 'orange', code: '#db5518', name: 'PMD'},
rest: {kliko: 'brown', code: '#7c3607', name: 'Restafval'},
papier: {kliko: 'blue', code: '#153477', name: 'Papier'},
};
I get an error "error getting garbagedata undefined"

Looking in the console I see that there is a 0 before the HTTPS://

Image

How can I change this or remove this 0?

Re: Dashticz - Module - Garbage collector

Posted: Thursday 14 January 2021 13:27
by Lokonli
I guess you redefined the CORS proxy in CONFIG.js.

You can remove that setting from CONFIG.js: just use default.

If your PHP setup is working it will use the internal CORS proxy. It not, a public CORS proxy will be used.

Re: Dashticz - Module - Garbage collector

Posted: Thursday 14 January 2021 14:14
by JuanUil
Thnx again for the help!!
Working now!!

Re: Dashticz - Module - Garbage collector

Posted: Friday 22 January 2021 9:45
by wbouwens
I have also the garbage collector. since one week the collector show no data found. i have an ical agenda with my trash data.

Re: Dashticz - Module - Garbage collector

Posted: Friday 22 January 2021 12:02
by Lokonli
If you share the link to the ical agenda I'll check.

In the mean time, can you post the following info:
* Dashticz version
* master or beta branch?
* PHP version
* OS and hardware of the system you run the Dashticz browser.

In Chrome, open DevTools (F12), refresh Dashticz:
* What are the user message on the console tab?
* Which errors are reported on the error tab?
* On the network tab search for the network request to your calendar. You can do this by filtering on garbage or ical in the network tab.
* What is the request response?

Re: Dashticz - Module - Garbage collector

Posted: Thursday 28 January 2021 16:44
by Rtificial
Just checking, my garbage block was working fine, I am using the Belgia recycleapp provider, and since some time today, I get no more data (the block say 'Laden...').
When checking the console, this is the output I get:

Code: Select all

<br />
<b>Warning</b>:  Undefined property: stdClass::$accessToken in <b>C:\xampp2\htdocs\vendor\dashticz\garbage\index.php</b> on line <b>303</b><br />
<br />
<b>Warning</b>:  Undefined property: stdClass::$items in <b>C:\xampp2\htdocs\vendor\dashticz\garbage\index.php</b> on line <b>321</b><br />
<br />
<b>Warning</b>:  Trying to access array offset on value of type null in <b>C:\xampp2\htdocs\vendor\dashticz\garbage\index.php</b> on line <b>321</b><br />
<br />
<b>Warning</b>:  Attempt to read property "id" on null in <b>C:\xampp2\htdocs\vendor\dashticz\garbage\index.php</b> on line <b>321</b><br />
<br />
<b>Warning</b>:  Undefined property: stdClass::$items in <b>C:\xampp2\htdocs\vendor\dashticz\garbage\index.php</b> on line <b>343</b><br />
<br />
<b>Warning</b>:  Trying to access array offset on value of type null in <b>C:\xampp2\htdocs\vendor\dashticz\garbage\index.php</b> on line <b>343</b><br />
<br />
<b>Warning</b>:  Attempt to read property "id" on null in <b>C:\xampp2\htdocs\vendor\dashticz\garbage\index.php</b> on line <b>343</b><br />
<br />
<b>Warning</b>:  Undefined property: stdClass::$items in <b>C:\xampp2\htdocs\vendor\dashticz\garbage\index.php</b> on line <b>369</b><br />
<br />
<b>Warning</b>:  foreach() argument must be of type array|object, null given in <b>C:\xampp2\htdocs\vendor\dashticz\garbage\index.php</b> on line <b>369</b><br />
Anyone else experiencing the same?

When I try to debug manually, using:

Code: Select all

 
 curl -H "x-consumer: recycleapp.be" -H "x-secret: Qp4KmgmK2We1ydc9Hxso5D6K0frz3a9raj2tqLjWN5n53TnEijmmYz78pKlcma54sjKLKogt6f9WdnNUci6Gbujnz6b34hNbYo4DzyYRZL5yzdJyagFHS15PSi2kPUc4v2yMck81yFKhlk2aWCTe93" "https://recycleapp.be/api/app/v1/access-token" > accesstoken.json
 
it seems I am not getting a key:

Code: Select all

{"host":"http://api-http:8080","identifier":"25d0abc2-4dd7-40c2-ab27-8be5b515fd71","timestamp":"2021-01-28T15:42:14.945Z","status":401,"name":"Unauthorized","message":"Missing authorization"}

Re: Dashticz - Module - Garbage collector

Posted: Thursday 28 January 2021 17:36
by geertvercamer
yes, I just noticed something similar. I get 'Geen gegevens gevonden'

Re: Dashticz - Module - Garbage collector

Posted: Saturday 30 January 2021 23:47
by Gianni
recycleapp has changed the street names

Now it's get the name fron the id of https://data.vlaanderen.be/

https://data.vlaanderen.be/doc/straatnaam/xxxxxx in my case

https://recycleapp.be/api/app/v1/collec ... 3&size=100

Re: Dashticz - Module - Garbage collector

Posted: Monday 01 February 2021 12:06
by jvdz
They have moved away from a fixed secret, which is now defined inside /static/js/main.0b66adb4.chunk.js.
I assume the name of that file can also change so retrieve that from the home page in my implementation.
Hope that helps.

Jos

Re: Dashticz - Module - Garbage collector

Posted: Monday 01 February 2021 13:32
by Lokonli
jvdz wrote: Monday 01 February 2021 12:06 They have moved away from a fixed secret, which is now defined inside /static/js/main.0b66adb4.chunk.js.
I assume the name of that file can also change so retrieve that from the home page in my implementation.
Hope that helps.

Jos
Thanks, Jos. I'll try to implement the same.

Re: Dashticz - Module - Garbage collector

Posted: Sunday 07 February 2021 18:02
by Renber
hello, to date I see that recyleapp is not yet repaired. For information, there is a change of key as said above. The new key x-secret is: 8a9pIQlfYpgmJZD15KdK70MCTR2xyD0EAvOmi9HCBfiBUY4n34ytxQmqo3AP2OET6tssYy6R4Be6N2M2GtiX3AcbiNxR8G7pOalN45dXPZ4emKE2c1nimx9B1YFciutJwFZHYHI2Qpzo0E0GCDHkg5

vendor/dashticz/garbage/index.php

Re: Dashticz - Module - Garbage collector

Posted: Monday 08 February 2021 8:35
by Lokonli
recycleapp has been fixed in latest beta.

Re: Dashticz - Module - Garbage collector

Posted: Monday 08 February 2021 9:50
by Rtificial
So I did a quick test, just replaced the garbage index.php, and reconfigured again for recycleapp, though this still has the same problem for me.

As for iCal in the garbage collector, this doesn't seem to work with recurring events in the calendar, is that a known issue?
I had all my garbage collections as recurrings, and those worked only the first time. For tomorrow, I did not see any. Now I created a single even for tomorrow, and it shows up in the block.

Re: Dashticz - Module - Garbage collector

Posted: Monday 08 February 2021 10:11
by Lokonli
Rtificial wrote: Monday 08 February 2021 9:50 So I did a quick test, just replaced the garbage index.php, and reconfigured again for recycleapp, though this still has the same problem for me.

As for iCal in the garbage collector, this doesn't seem to work with recurring events in the calendar, is that a known issue?
I had all my garbage collections as recurrings, and those worked only the first time. For tomorrow, I did not see any. Now I created a single even for tomorrow, and it shows up in the block.
Did you download the beta version of index.php?

What is the PHP version as reported by Dashticz? (upper right settings icon, then Info tab)

What is the result of the recycleapp network request? You can find it in the network tab of DevTools (after pressing F12, and refresh Dashticz).
The network request should look like: (you can filter on recycleapp)

Code: Select all

http://dashticz-ip:port/vendor/dashticz/garbage/index.php?service=recycleapp&street=...&sub=...&zipcode=...&nr=..&t=
Can you post the output of that request? (you can open it in a browser)

Re: Dashticz - Module - Garbage collector

Posted: Monday 08 February 2021 11:25
by Rtificial
I indeed downloaded the beta version.
PHP is reported as 8.0.1

http://192.168.178.65:888/vendor/dashti ... &nr=190&t=

The response is :
<br />
<b>Warning</b>: Undefined property: stdClass::$accessToken in <b>C:\xampp2\htdocs\vendor\dashticz\garbage\index.php</b> on line <b>303</b><br />
<br />
<b>Warning</b>: Undefined property: stdClass::$items in <b>C:\xampp2\htdocs\vendor\dashticz\garbage\index.php</b> on line <b>321</b><br />
<br />
<b>Warning</b>: Trying to access array offset on value of type null in <b>C:\xampp2\htdocs\vendor\dashticz\garbage\index.php</b> on line <b>321</b><br />
<br />
<b>Warning</b>: Attempt to read property "id" on null in <b>C:\xampp2\htdocs\vendor\dashticz\garbage\index.php</b> on line <b>321</b><br />
<br />
<b>Warning</b>: Undefined property: stdClass::$items in <b>C:\xampp2\htdocs\vendor\dashticz\garbage\index.php</b> on line <b>343</b><br />
<br />
<b>Warning</b>: Trying to access array offset on value of type null in <b>C:\xampp2\htdocs\vendor\dashticz\garbage\index.php</b> on line <b>343</b><br />
<br />
<b>Warning</b>: Attempt to read property "id" on null in <b>C:\xampp2\htdocs\vendor\dashticz\garbage\index.php</b> on line <b>343</b><br />
<br />
<b>Warning</b>: Undefined property: stdClass::$items in <b>C:\xampp2\htdocs\vendor\dashticz\garbage\index.php</b> on line <b>369</b><br />
<br />
<b>Warning</b>: foreach() argument must be of type array|object, null given in <b>C:\xampp2\htdocs\vendor\dashticz\garbage\index.php</b> on line <b>369</b><br />
[]

Re: Dashticz - Module - Garbage collector

Posted: Monday 08 February 2021 11:53
by Lokonli
Rtificial wrote: Monday 08 February 2021 11:25 I indeed downloaded the beta version.
PHP is reported as 8.0.1

http://192.168.178.65:888/vendor/dashti ... &nr=190&t=

The response is :
<br />
<b>Warning</b>: Undefined property: stdClass::$accessToken in <b>C:\xampp2\htdocs\vendor\dashticz\garbage\index.php</b> on line <b>303</b><br />
<br />
<b>Warning</b>: Undefined property: stdClass::$items in <b>C:\xampp2\htdocs\vendor\dashticz\garbage\index.php</b> on line <b>321</b><br />
<br />
<b>Warning</b>: Trying to access array offset on value of type null in <b>C:\xampp2\htdocs\vendor\dashticz\garbage\index.php</b> on line <b>321</b><br />
<br />
<b>Warning</b>: Attempt to read property "id" on null in <b>C:\xampp2\htdocs\vendor\dashticz\garbage\index.php</b> on line <b>321</b><br />
<br />
<b>Warning</b>: Undefined property: stdClass::$items in <b>C:\xampp2\htdocs\vendor\dashticz\garbage\index.php</b> on line <b>343</b><br />
<br />
<b>Warning</b>: Trying to access array offset on value of type null in <b>C:\xampp2\htdocs\vendor\dashticz\garbage\index.php</b> on line <b>343</b><br />
<br />
<b>Warning</b>: Attempt to read property "id" on null in <b>C:\xampp2\htdocs\vendor\dashticz\garbage\index.php</b> on line <b>343</b><br />
<br />
<b>Warning</b>: Undefined property: stdClass::$items in <b>C:\xampp2\htdocs\vendor\dashticz\garbage\index.php</b> on line <b>369</b><br />
<br />
<b>Warning</b>: foreach() argument must be of type array|object, null given in <b>C:\xampp2\htdocs\vendor\dashticz\garbage\index.php</b> on line <b>369</b><br />
[]
An error on line 303 on $accessToken means you are using the master version ...
Please fix this first.

After that I've to check compatibility with PHP8.

Re: Dashticz - Module - Garbage collector

Posted: Monday 08 February 2021 12:04
by Rtificial
My bad :-( It's working fine now, just a bit slow in loading :-)

Re: Dashticz - Module - Garbage collector

Posted: Monday 08 February 2021 18:48
by Renber
Works perfectly thanks for the update :)

Re: Dashticz - Module - Garbage collector

Posted: Wednesday 10 February 2021 9:37
by RuudP1987
I added the calendar for Avalex, but it keeps saying loading.. Did I miss something?

Code: Select all

//afvalophaalkalender
blocks['mygarbage'] = {
    company: 'avalex',
    zipcode: '2622 km',
    street: 'straat van malakka',
    housenumber: xx,
    maxitems: 6,
    width: 12
}

Re: Dashticz - Module - Garbage collector

Posted: Wednesday 10 February 2021 15:47
by HansieNL
Did you try the zipcode without a space?