-
Notifications
You must be signed in to change notification settings - Fork 786
"Configuration model x.rules is either empty or cannot be parsed correctly" error #4161
Comments
Could you post a log file with exceptions here? |
Sure - do you mean just: 2017-08-30 14:04:43.325 [INFO ] [el.core.internal.ModelRepositoryImpl] - Refreshing model 'sonos.rules' or something else? Dan |
That is a well known issue when using Samba shares - there simply is a moment in which the file is empty and thus cannot be parsed. So the warning is technically correct. |
The oddity is that this isn't a Samba share - I'm locally editing files on a local drive, and those files aren't shared over the network. As this is a live system I stopped using Visual Studio when I saw the error - but I'll play with it a little and let you know if I see any real problems. |
On second thoughts, get a series of errors when I edit an items file: 2017-08-30 14:58:22.347 [INFO ] [el.core.internal.ModelRepositoryImpl] - Refreshing model 'sensors.items' then: 2017-08-30 14:58:22.571 [INFO ] [el.core.internal.ModelRepositoryImpl] - Refreshing model 'sensors.items' Is this another warning I can happily ignore? |
This is weird and I haven't seen this with any other editors - maybe worth to report at https://github.com/openhab/openhab-vscode/issues and have @kubawolanin comment on it.
I am afraid not - this is something that should be looked into. |
thanks |
Update on the weirdness: looking again at the logs, it doesn't just give the "failed to add a second" error for the items in that items file; it gives it for every item across all items files. So am I right to think this is definitely an openhab and not a VisualStudio problem? |
Further update: I just got exactly the same items error when editing with Sublime Text. So not a Visual Studio problem for sure. |
Thanks! Versions are 0.9.0.201708151402 org.eclipse.smarthome.model.thing Dan |
From a timing perspective, both PRs should be included in your version. Therefore this needs to be looked into more closely. Just to be sure we don't miss any clues: Are there any other errors/exceptions in your logs? Maybe the one from #4162? |
No, no other errors other than those above (with the warning repeated for every single item). Dan |
@SJKA Probably not related, and I feel we are going away from the original issue filed, but it might give a clue. I noticed the same error on all of my items (both defined in .items files and through PaperUI) when starting or restarting openHAB. I have exactly the same version of ESH running as @Dan1001. It is not consistent though. I tried restarting about 10 times. 7 out of 10, I get the "Failed to add a second with the same UID!" errors. In the other cases, I don't. Everything seems to work though. Also maybe important, I do have a restore on startup strategy for all items from mapDB. |
I too have everything restoring on startup from mapDB, but the error occurs well after a restart. I can't find a pattern to when it happens - no more than once every editing session, I would say. |
- fixes eclipse-archived#4162 - also fixes duplicate added events for items see eclipse-archived#4161 (comment) and closes eclipse-archived#617 - minor cosmetics Signed-off-by: Henning Treu <henning.treu@telekom.de>
The PR #4163 should fix the duplicate items bug. Still open here: |
Cool - do you know when it will go into the snapshot so I can test? |
- fixes #4162 - also fixes duplicate added events for items see #4161 (comment) and closes #617 - minor cosmetics Signed-off-by: Henning Treu <henning.treu@telekom.de>
the fix got accepted and merged. the next ESH stable build is planed in the next 12h I guess and the next openHAB snapshot afterwards will be your choice :-) |
That is awesome - thank you. Out of interest, how come so few people have come across the problem? In other words: why am I special? |
The problem originates in a non-deterministic start order of OSGi services. It could happen that the item model was parsed bevor the GenericItemProvider was available. But this does not happen on every startup. And the probability may also depend on your system settings and installed bundles. |
I've been experiencing it on a system that's been running for hours/days - is it possible I have a different problem? I guess we'll find out when I install the snapshot... |
Even though everything technically works, these log messages are "error messages on firth sight" and a lot of users are probably irritated by them. In my opinion they should be dealt with for the sake of UX. |
@ThomDietrich My comment is pretty old and has been already proven incorrect in the discussion here. The issue is hence still open and we need to find out what the actual root cause of it is. Ignoring it without knowing why they happen is imho not an option. |
I actually got that, thanks for the clarification. |
Hi,
I'm running OH2.2 snapshot on Ubuntu 14.04. I usually use SublimeText as an editor, editing locally. When I use Visual Studio and the OH extension (also locally) I get the above error when editing rules.
I appreciate a number of people have experienced similar issues with a variety of editors when editing across a Samba networked drive, but a local problem seems unusual, and it was suggested I raise as an issue (see here).
thanks!
Dan
The text was updated successfully, but these errors were encountered: