Starting with Python in OH3

Hi all,
I’ve created a complete new OH3 envrionment and configured all things and items of my smart home. I really like the new UI and want to start developing my rules.
I need to learn python because of other reasons. So I thought to go with python to develop my new rules in openhab. I’ve installed the addon and did a hello world example to test the log output. Everything works so far.
But what next? I found the tutorials of rlkoshak to translate the rules from JSR223 to Python, but this was OH2.5. I think there’s a better way to setup python rules now?
Do you know any examples or tutorials so far? I just want to have a starting point: how to set a trigger, how to get the status of an item.

Try this Installation — openHAB Helper Libraries documentation

Have you tried that in OH3? I understand that these don’t work without a current PR linked in various places in the forum…

No, it should be pretty much the same. Though you have the choice to create rules in .py files like was done in those tutorials or in the UI in which case you would not use the @rule and @when annotations. In the UI, the rule is created through the UI as are the triggers so all you need to define is the code that runs.

Correct, they depend on the Helper Libraries as written. Though there is a PR to update them to work in OH 3 that can be downloaded from github.

No, it works. Read a little bit more in the forum. There are small changes like joda time vs. Java time. Apart of it it works. Installation method is diffrerent but you looked for starting information. It contains basic infirmation rule templates etc.
Just answering your first question, yes I had tried OH3 several times sinces last August. Now I have been using OH3 R1 since it is published and all my phyton rules are working. I’m not that s…pid sorry.

Well - I clicked the link in your original post

and recognised it as the one for installing on OH2. So care to share what the correct link is that we should all be reading if it’s not the one that you originally offered for help?

You asked for examples and tutorials how to use Python for Openhab. For installation I suggested to use forum. Use this one: Jython helper libraries for OH3 and previous one for 2.5.

For openHAB 3, as per the OP and title.

Starting with Python in OH3

You suggested instructions for OH2.5.

Which is the link I replied to your first post with!

So it looks like

doesn’t apply to me.

Glad we got there in the end!