Skip to content
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

Uncaught TypeError: deleteInstanceNotInUse() #20

Closed
Brovning opened this issue Feb 26, 2022 · 1 comment
Closed

Uncaught TypeError: deleteInstanceNotInUse() #20

Brovning opened this issue Feb 26, 2022 · 1 comment
Assignees
Labels
bug Something isn't working

Comments

@Brovning
Copy link
Owner

Brovning commented Feb 26, 2022

Describe the bug

Fatal error: Uncaught TypeError: Return value of Fronius::deleteInstanceNotInUse() must be of the type bool, int returned in C:\ProgramData\Symcon\modules\fronius\libs\myFunctions.php:179
Stack trace:
#0 C:\ProgramData\Symcon\modules\fronius\libs\myFunctions.php(337): Fronius->deleteInstanceNotInUse(22370, '{3CFF0FD9-E306-...')
https://github.com/Brovning/fronius/issues/1 C:\ProgramData\Symcon\modules\fronius\fronius\module.php(563): Fronius->checkModbusGateway('192.168.1.112', 502, 2, 0)
https://github.com/Brovning/fronius/issues/2 C:\Windows\System32-(3): Fronius->ApplyChanges()
#3 {main}
thrown in C:\ProgramData\Symcon\modules\fronius\libs\myFunctions.php on line 179
Abort Processing during Fatal-Error: Uncaught TypeError: Return value of Fronius::deleteInstanceNotInUse() must be of the type bool, int returned in C:\ProgramData\Symcon\modules\fronius\libs\myFunctions.php:179
Stack trace:
#0 C:\ProgramData\Symcon\modules\fronius\libs\myFunctions.php(337): Fronius->deleteInstanceNotInUse(22370, '{3CFF0FD9-E306-...')
https://github.com/Brovning/fronius/issues/1 C:\ProgramData\Symcon\modules\fronius\fronius\module.php(563): Fronius->checkModbusGateway('192.168.1.112', 502, 2, 0)
https://github.com/Brovning/fronius/issues/2 C:\Windows\System32-(3): Fronius->ApplyChanges()
#3 {main}
thrown
Error in Script C:\ProgramData\Symcon\modules\fronius\libs\myFunctions.php on Line 179 (Code: -32603)

Und es werden massig neue Modbus Gateways angelegt.
Alle Instanzen und Gateways bereits gelöscht…

source: https://community.symcon.de/t/modul-fronius-wechselrichter/51132/181?u=brovning

@Brovning Brovning added the bug Something isn't working label Feb 26, 2022
@Brovning Brovning self-assigned this Feb 26, 2022
@Brovning
Copy link
Owner Author

Der Fehler war das "&=". Hierbei handelt es sich um einen Bitweisen Operator, welcher einen Integer zurückliefert!
$foo = true;
$foo &= false; // int(0)
$foo = (bool)$foo; // bool(false)

Richtig:
$foo = true;
$foo = $foo && false; // bool(false)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant