Error of Item file after updating to oh 2.1

After updating to openhab 2.1 I get the following error in karaf:

20:54:47.678 [WARN ] [el.core.internal.ModelRepositoryImpl] - Configuration model 'additional.items' has errors, therefore ignoring it: [95,53]: no viable alternative at input '%'
[95,57]: mismatched input ']' expecting RULE_ID
[95,64]: mismatched input '>' expecting RULE_ID
[96,61]: no viable alternative at input '%'
[96,65]: mismatched input ']' expecting RULE_ID
[96,72]: mismatched input '>' expecting RULE_ID
[97,65]: no viable alternative at input '%'
[97,69]: mismatched input ']' expecting RULE_ID
[97,76]: mismatched input '>' expecting RULE_ID
[98,65]: no viable alternative at input '%'
[98,69]: mismatched input ']' expecting RULE_ID
[98,76]: mismatched input '>' expecting RULE_ID

Can somebody explain me what the error means?

Thank you!

The new version shows where in the file it detects syntax errors. The first one is in line 95, column 53.

1 Like

Thank you! but can you tell me what is wrong with this block:

//Sonos 
Number SonosKuecheFavorit "Sonos Kueche Favoriten" [%.0f] <list>
Number SonosWohnzimmerFavorit "Sonos Wohnzimmer Favoriten" [%.0f] <list>
Number SonosSchlafzimmerFavorit "Sonos Schlafzimmer Favoriten" [%.0f] <list>
Number SonosKinderzimmerFavorit "Sonos Kinderzimmer Favoriten" [%.0f] <list>

I don’t understand the error. If I commented the lines out. The file is loaded without errors.

Those lines look like they are from a sitemap and not from an items file.
A number for Favorites? I’d expect strings.

Why? These are the items for a selection menus called “Favorit”. Since today I had no problems with these items and the rule and sitemap with this items had no problems and function was given with no errors.

Ok. I guess you are running into the same problem that have. Changing from 2.0 to 2.1 raiss a lot of errors in files previously used without problem.
Presently I’m clueless as well.

Should be, according to the docs:

Number SonosKuecheFavorit "Sonos Kueche Favoriten [%.0f]" <list> 
Number SonosWohnzimmerFavorit "Sonos Wohnzimmer Favoriten [%.0f]" <list> 
Number SonosSchlafzimmerFavorit "Sonos Schlafzimmer Favoriten [%.0f]" <list> 
Number SonosKinderzimmerFavorit "Sonos Kinderzimmer Favoriten [%.0f]" <list>  

I get no errors after changing your version the the above.

Thank you! That was the reason! Every time these small things:-)

2 Likes