Bug 149284 - LO Base freeze when using a form with macro to enter MySQL data
Summary: LO Base freeze when using a form with macro to enter MySQL data
Status: UNCONFIRMED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: LibreOffice (show other bugs)
Version:
(earliest affected)
7.6.4.1 release
Hardware: x86-64 (AMD64) Linux (All)
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: Database-Connectivity
  Show dependency treegraph
 
Reported: 2022-05-25 12:26 UTC by J-Paul
Modified: 2023-12-30 03:13 UTC (History)
2 users (show)

See Also:
Crash report or crash signature:


Attachments
Table MySQL (2.23 MB, text/plain)
2022-05-25 12:45 UTC, J-Paul
Details
LO Base to test (1.57 MB, application/vnd.oasis.opendocument.database)
2022-05-25 12:46 UTC, J-Paul
Details

Note You need to log in before you can comment on or make changes to this bug.
Description J-Paul 2022-05-25 12:26:03 UTC
Description:
I use LO 7.3.3 (on Ubuntu 22.04) as frontend of a MySQL database (8.0). I use the direct connection.
I use a form to enter records in 1 table : ID with auto-increment, a date and 2 Integer fields (corresponding to keys of other tables). The table has more than 40 000 records.
To test, if I use this form without any macro (I enter manually the date and the integer fields), no problem.
If I add any macro : after choosing a data in a listbox, copy the ID in an integer field, the form will freeze after 2 or 3 records and I must force to quit.
I have run LO with the terminal. When it freeze I get :
(soffice:14749): Gdk-WARNING **: 12:28:25.650: Tried to unmap the parent of a popup
This problem doesn't happen when I use a JDBC connection but it's slow


Steps to Reproduce:
1.Have a LO Base directly connected to a MySQL database
2.Have a form with macro which display or write something
3.Record the record

Actual Results:
LO freeze or crashes suddenly 

Expected Results:
it works smoothly !


Reproducible: Always


User Profile Reset: No



Additional Info:
I add the same problem with LO 6.3 in a virtual machine
Comment 1 J-Paul 2022-05-25 12:45:55 UTC
Created attachment 180368 [details]
Table MySQL
Comment 2 J-Paul 2022-05-25 12:46:57 UTC
Created attachment 180369 [details]
LO Base to test
Comment 3 Alex Thurgood 2022-06-10 07:26:55 UTC
@J-Paul : could you try and reproduce this behaviour with a more simplified embedded HSQLDB example and corresponding form (preferably with a reduced data set)?

I downloaded your SQL dump and tried to import the data into a test database, but then I ended up having to edit a number of form controls as the queries which are used to populate them are highly dependent on the db name you have used, and I still couldn't get the form to work properly even without macros, so I gave up.
Comment 4 J-Paul 2022-06-10 12:55:19 UTC
Sorry ! Of course, it's quite impossible to use it without the real MySQL database because the form and queries need some other configuration tables (I can provide them).

I could do what you ask for but if I change the database type, the problem is over !
I mean : now, I have switched to a MySQL JDBC connection and I have no more this problem. So this issue seems to depend of the direct connection to MySQL.

On the french OpenOffice/LibreOffice Forum, several people say they have no problem with a direct connection OpenOffice-MySQL.
So, this issue seems to be specific to LO. Would it be better with MariaDB (other people say the connector has been developed for MariaDB) ?
Comment 5 QA Administrators 2022-06-11 03:30:14 UTC Comment hidden (obsolete)
Comment 6 Alex Thurgood 2023-06-22 17:43:44 UTC
@J-Paul: if you're using a distrib-provided version of LO, you might be able to install the corresponding debug packet, and then run LO in a lldb debugger or gdb session until it crashes to get a full backtrace with symbols, and then paste the output to a text file which you could attach to this bug report.
Comment 7 Adam664 2023-06-26 15:50:45 UTC
Could not reproduce using 

Version: 7.5.3.2 (X86_64)
Build ID: 50(Build:2)
CPU threads: 1; OS: Linux 6.3; UI render: default; VCL: gtk3
Locale: en-US (en_US.UTF-8); UI: en-US
Calc: threaded

and

Version: 7.7.0.0.alpha0+ (X86_64) / LibreOffice Community
Build ID: 5a2c6f4df7149f8c1f543f120fe19bd66abfc189
CPU threads: 1; OS: Linux 6.3; UI render: default; VCL: gtk3
Locale: en-US (en_US.UTF-8); UI: en-US
Calc: threaded

Was not able to use @J-Paul 's database as it was too complicated to set up. Used a simple one table MySQL database, directly connected, with a simple 3 field form and a simple macro that filled out one of the fields.

@J-Paul can you try and reproduce with a simple database? Setting to NEEDINFO.
Comment 8 QA Administrators 2023-12-24 03:12:39 UTC Comment hidden (obsolete)
Comment 9 J-Paul 2023-12-28 18:19:37 UTC
Hello,
I understand very well your request but I can't reach it !
I mean : the "How to debug" webpage of the wiki is too much technical for me : I don't understand how to use the commands and what are the consequences of what is required.
So it is not usable for me. I'm sorry.
Comment 10 Alex Thurgood 2023-12-28 22:18:10 UTC
@J-Paul : the error message points to a gdk issue, and my own searching with the error message leads to a suggestion that the problem of freezing is linked to the use of Wayland as the desktop UI default provided by Ubuntu.

I have encountered many such UI freezes with Wayland unfortunately, not just with LibreOffice, some requiring force kill of the application. 

One way to test this is to start an Xorg session instead of Wayland when you open a desktop session from the user login screen. If the problem still persists in LibreOffice when using a Xorg session, then the problem is 'likely with the Gnome core snap package used by Ubuntu. In any of these eventualities, the problem would not lie with LibreOffice, this would therefore not be our bug.
Comment 11 J-Paul 2023-12-29 13:21:30 UTC
Hello,
That was easy ! But it is not the good answer… I try to use this LO Base file in a Wayland and then in a Xorg session : same issue ! The app freezes or close suddenly ! I have only to make a search in a table to get the freeze.
I have looked in the system log and the Journal : I have not seen anything.
Comment 12 QA Administrators 2023-12-30 03:13:48 UTC Comment hidden (obsolete)