openHAB 3.0 Milestone 3 discussion

I noticed that it takes some time to stop. But I didn’t explicitely check for it. Will have a closer look next time.

Curiosity happened so I timed it…

$ time sudo systemctl stop openhab

real    2m0.700s
user    0m0.006s
sys     0m0.002s

Is anyone else noticing serious delays between things happening and the bus updating? By the order of minutes? I have a Neeo remote and there is a solid few minutes (5 or more) between button click and it showing up on the event bus. M2 did not have this issue. I’ve also noticed that if I update the state of an item in the cli that it is taking minutes before it is hitting the bus.

EDIT: More info - As per top, my java process is permanently above 100%. Not sure why it’s sitting so high.

EDIT2: I backed out to M2 but left addons at M3 and the system is substantially more stable now. Not sure what changed from M2 to M3, but something is definitely broke. I’ve opened a bug as https://github.com/openhab/openhab-core/issues/1852

did expire make it into this one?

Yes you add it to item as metadata

1 Like

The time thingy has changed

The next-gen rule engine (NGRE) of openHAB 2.5 has now become the official rule engine within openHAB. Good news is that your rule DSL files are not impacted by this change and should run smoothly on it. The only change you’ll have to look our for in your rules is the fact that rules now use Java Time API instead of Jodatime, so some expressions need to be slightly adapted.

From

Try

now.getHour()

2 Likes

just played around a bit with the model and want to mass edit the model. I didn’t find the “Code”-functionality as it is with things. or “Select” as it is with items. Is it something, that’s being worked on to ensure consistent user experience! :wink:

One thing to understand about the model is it’s all just Items. Locations (always) and Equipment (mostly) are just regular old Groups with a semantic tag. Points are just regular old Items with semantic tags and a group membership to place them in a location and as part of an equipment. Knowing how it works will help you understand why you won’t see a code view of the model. It’s not built using one definition that could be shown as a single YAML. The closest you could come is showing a YAML with all you semantically tagged Items listed.

Given this, depending on the operation you want to perform, the bulk actions will take place on the appropriate Item’s page. For example, to move a bunch of equipment from one room to another, go to the Group Item for the room, and bulk select the Items to add as members. Then do the same to remove them.

I suspect over time there will be improvements to the model UI but any improvements are going to be quite complex to achieve I think so we need to be patient on that front.

2 Likes

2.5x this is also there, I hoped it would not be in version 3. But still, these warnings are present. It irritates. I read all the topics on the forum that mention this warning, I did not find a single explanation of why this is needed. Once there was a mention - do not pay attention, but I would not want the incomprehensible, not used by me features were automatically enabled, plus everything, issued warnings. Is there a way to disable this?

5 posts were split to a new topic: OH2 rule failing in OH3

Hi, I’m facing error

2020-11-28 10:00:01.666 [ERROR] [internal.handler.ScriptActionHandler] - Script execution of rule with UID 'tmp_LivingDining-9' failed: An error occurred during the script execution: Could not invoke method: java.util.List.size() on instance: [Ljava.lang.String;@9e18950 in tmp_LivingDining

in the following rule (it was ok in 2.5.10)

rule "Descodificar estados da lareira"
when
	Item GF_LivingDining_Stove_Out changed
then
	var lines = GF_LivingDining_Stove_Out.state.toString.split('\n')
	if (lines.size('\n') > 6) {
		val estado_lar = lines.get(4).split('=').get(1)
		GF_LivingDining_Stove_Stat.postUpdate(estado_lar)
		var temp_amb = Double::parseDouble(lines.get(7).split('=').get(1))
		GF_LivingDining_Stove_Temperature.postUpdate(temp_amb)
	}

	// caso a lareira tenha sido ligada/desligada fora do OpenHAB vamos actualizar o estado
	if (GF_LivingDining_Stove_Stat.state == "0" && GF_LivingDining_Stove.state == ON){
		// a lareira foi desligada
		GF_LivingDining_Stove.sendCommand(OFF)
	} else if (GF_LivingDining_Stove_Stat.state == "7" && GF_LivingDining_Stove.state == OFF){
		// a lareira foi ligada
		GF_LivingDining_Stove.sendCommand(ON)
	}
end

GF_LivingDining_Stove_Out is updated with a script (Exec add-on) and contains:

error_MODO_on_off=0
on_off=0
modo_operacion=1
modo_func=1
estado=0
consigna_potencia=5
consigna_temperatura=23.0
temperatura=19.7
temperatura_ext=---.-
0

I need to parse contents of lines 5 & 8 and assign their value to some items.

Are you sure this worked? lines.size(’\n’) is kind of nonsense. lines is an array created by splitting the string on ‘\n’. That split removed all the ‘\n’ as a result. So even if this worked the call to size would always return 0 because there are no more \n.

But the perform goes even deeper because there is no size method that takes a String on Lists. So remove the argument to size and it should be ok.

1 Like

As I played around a bit on my test-installation I already built my whole model for my smarthome… But as I messed around, I also did some major misconfiguration, I wanted to solve. I figured, if I could get my model as “code”, I could easily remove those and insert them in my “staging”-environment before I’m ready to switch fully to OH3 (at least for my main installation, I have to have an OH2 around for some legacy 1.x bindings I use).

Yes

I’m afraid it produces the same error. Will try Regex instead.

Edit: if (lines.size('\n') > 6) should be if (lines.length > 6)

Hi,

had some issues updating to milestone 3 (from m2) - so i basically did a fresh install. One problem - all my zwave nodes won’t initialize (no xml file created). Do you know if there is anything (a flag, file) to delete or how to reinforce the initalization? All nodes are found when adding them (node 4, node 5…) but no update (manufacturerer etc.) takes place. Only one xml file for the controller exists.

Regards,
Herbert

Edit - [SOLVED] No access to USB zwave stick was the solution, don’t know why it was necessary this time…

People please stay on topic and do not post all of your personal issues with M3 into this thread but open new ones.

That being said, @Z0l you (like me) might suffer from this still open issue:

EDIT: @kai could you add a “OH3 migration” category to “Setup, Installation and Use” please ?

4 Likes

Hi,

great job, m3 comes with some very powerfull features, especially the developer sidebar.

I have some thoughts, which can make the user experience greater:

  • I love the Event-Monitor, perhaps it is possible to add also a Log-Monitor?
  • Things, Rules, Scripts and Schedules have an alphabet picker. I have over 500 items, so an alphabet picker for items would help a lot
  • Changing the sort order of the items (by Text, by Name) would be great
  • The code view for Rules, Pages and Things is a great feature for guys who loved the configuration files in OH2. It combines the power of fast editing and accessability by the web ui. It would be great, if there could be a code view for items to.
  • The code view will be much more powerfull, if one could switch from the collection overview (of rules / things / maybe items) to code view with all the elements of the collection in it (to have the possibility of search & replace in all rules, for example).
  • A feature for adding Rules from Textual Definition like the one for items would be helpfull

Greetings
Guido

It would be cool, if one could really import the text files for items and rules into the UI config.
At the moment, they show up but are not fully editable.

Mhhhhh, is there anybody using the developer sidebar on the iPad?

Hello,

I don’t know if this is the right place.
Started to learn the new version 3 before migrating from 2.5.

The design looks good and happy for the most part so part.

I think only that there is a missed opportunity on two things.

  1. The web access is still without SSL support. This would have been nice (maybe with Let’s Encrypt integration?)
  2. Yes, we have secured the configuration with and admin accoutn, but for viewing it’s still open.
    Would be nice to extend the security to put everything behind a login.

I hope these options will be considerd and added at a later time.
Keep up the good work!

Regards,
Edwin