-
-
Notifications
You must be signed in to change notification settings - Fork 3.6k
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
[linky] Yet another website underlaying API modification #17538
base: main
Are you sure you want to change the base?
Conversation
Signed-off-by: Gaël L'hopital <gael@lhopital.org>
This gives a first answer to the initial connection issue but I must investigate a bit, data may have changed leading to UNDEF items. |
Signed-off-by: Gaël L'hopital <gael@lhopital.org>
Signed-off-by: Gaël L'hopital <gael@lhopital.org>
I will test this evening and finish the review. |
...nhab.binding.linky/src/main/java/org/openhab/binding/linky/internal/LinkyHandlerFactory.java
Show resolved
Hide resolved
...rg.openhab.binding.linky/src/main/java/org/openhab/binding/linky/internal/dto/PrmDetail.java
Show resolved
Hide resolved
...rg.openhab.binding.linky/src/main/java/org/openhab/binding/linky/internal/dto/PrmDetail.java
Outdated
Show resolved
Hide resolved
...hab.binding.linky/src/main/java/org/openhab/binding/linky/internal/handler/LinkyHandler.java
Show resolved
Hide resolved
@clinique : is your upgrade of jsoup really necessary ? I can't start the binding with your new version. If I update my bundle with command bundle:update:
If I uninstall the bundle and then put the jar file in folder addons:
|
Please upgrade jsoup in a separate PR. I am now trying to remove jsoup upgrade to be able to test the fix! |
This will also facilitate backport to branch 4.2.x. |
...hab.binding.linky/src/main/java/org/openhab/binding/linky/internal/handler/LinkyHandler.java
Outdated
Show resolved
Hide resolved
If I remove jsoup upgrade, I am able to use the binding again and it is alive (ONLINE) again, bravo. |
When I switch my dev environment to linky I always have a hard time (mvn clean install, update project, clean project...) resolving dependencies (especially jsoup). I had a look at what was used by other binding and saw 1.14.3, 1.15.3 and 1.15.4. On maven rep I saw that 1.14.3 had 3 security issues. Reason why I made this move but I can revert to 1.14.3 |
Signed-off-by: Gaël L'hopital <gael@lhopital.org>
Signed-off-by: Gaël L'hopital <gael@lhopital.org>
Signed-off-by: Gaël L'hopital <gael@lhopital.org>
Changing this dependency seems to prevent the update of the binding in an existing OH setup. |
I just installed the very last version and the internal server error is back ! Let's wait the retries during the day, it occurs that the service is not available before the end of the morning. I will see with the retry ar 11 am. Edit: Still in error at 11 am. |
int idxLast = days.periodes.get(days.periodes.size() - 1).dateDebut.get(weekFields.dayOfWeek()) == 7 ? 2 | ||
: 1; | ||
Aggregate weeks = values.aggregats.weeks; | ||
if (weeks.datas.size() > idxLast) { | ||
updateKwhChannel(LAST_WEEK, weeks.datas.get(idxLast)); | ||
} | ||
if (weeks.datas.size() > (idxLast + 1)) { | ||
updateKwhChannel(THIS_WEEK, weeks.datas.get(idxLast + 1)); | ||
} else { | ||
updateKwhChannel(THIS_WEEK, 0.0); | ||
} | ||
setCurrentAndPrevious(values.aggregats.weeks, THIS_WEEK, LAST_WEEK); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would like to be sure that the proper week values are delivered every day of the week. I previously implemented it to have a proper 0 value each Monday as current week value and not the value from last week.
So before merging, I will check if the week values are correct Saturday (today), Sunday, Monday and Tuesday.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No problem, I'm not in a hurry.
I'll make a separate PR then. This will reduce a bit the number of bindings being on 1.14.x (we are far behind main branch of jsoup 1.18.1) and there are known vulnerabilities up to 1.15.2 |
Still not working for me at Midday.. Can you try on your side ? |
...penhab.binding.linky/src/main/java/org/openhab/binding/linky/internal/api/EnedisHttpApi.java
Show resolved
Hide resolved
Tested on my side, the same today. Weird thing is the same query in the browser works without issue. |
Now it works... |
Signed-off-by: Gaël L'hopital <gael@lhopital.org>
Signed-off-by: Gaël L'hopital <gael@lhopital.org>
Still KO for me. |
<properties> | ||
<bnd.importpackage>javax.annotation.meta;resolution:=optional</bnd.importpackage> | ||
</properties> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why did you add that? What's the purpose?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's the way I found to solve the dependency resolution issue I faced.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It was building fine without that.
Signed-off-by: Gaël L'hopital <gael@lhopital.org>
Still KO today. |
You may try to tace it in debug mode to understand where it's blocked. |
Here are my logs:
|
Checking the request done by the website, I agree that it is the same (except the parameter dateDebut). |
I tried with this code but same result, internal server error:
Same without the Host header and same without user agent. |
Resolves #17513