[Bug]: User defined Java expression - fields insertion on selected text
Apache Hop version?
2.13
Java version?
17.0.2
Operating system
Linux
What happened?
- Have a relatively long expression in the Java expression field, such as:
"This is a relatively long string " + [replace_me] + " and it could really be even longer" - Modify the expression: select the text
[replace_me], and then double click on a field on the left panel to insert it in place
It happens sometimes that the field is not correctly inserted, specifically if you select the text to replace with:
- mouse press before
[ - mouse drag
- mouse release after
]
In this case, the field name will overwrite the expression starting from the last character.
This operation cannot be undone with CTRL + Z or similar (you can only cancel all modifications)
Issue Priority
Priority: 2
Issue Component
Component: Hop Gui
I was unable to reproduce it under Windows and Hop 2.14
record_2025-05-26_16-22-39.zip
I attach a screen grab of what can happen, even with Hop 2.14 😅 (using Ubuntu 24.04 on a Windows VirtualBox, no particular graphics options enabled). In this case, I meant to replace the "1" with a field, but the "1" is not removed and the field overwrites a trailing space