FS#56213 - [mysql-workbench] Preferences can't be saved

Attached to Project: Community Packages
Opened by Laurent HOAREAU (laurent_waro) - Friday, 03 November 2017, 02:19 GMT
Last edited by Christian Hesse (eworm) - Friday, 10 November 2017, 07:46 GMT
Task Type Bug Report
Category Packages
Status Closed
Assigned To Christian Hesse (eworm)
Architecture x86_64
Severity Medium
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 1
Private No

Details

Description:
Preferences can't by saved and return to default at the next start of workbench.
It seems that the file (wb_options.xml) in which workbench stores its preferences doesn't exist anymore. (this file should be in ~username/.mysql/workbench/ as reported here : https://dev.mysql.com/doc/workbench/en/wb-configuring-files.html

Additional info:
* package version(s)
version 6.3.9-6



Steps to reproduce:
Go to Workbench preferences : menu "Edit" -- "Preferences..."
Change something in "Fonts" for example.
The changes won't by saved and return to defaults at the next start of workbench
This task depends upon

Closed by  Christian Hesse (eworm)
Friday, 10 November 2017, 07:46 GMT
Reason for closing:  Not a bug
Additional comments about closing:  issue with system locale
Comment by Doug Newgard (Scimmia) - Saturday, 04 November 2017, 15:28 GMT
What does `ls -la ~/.mysql/` give you?
Comment by Laurent HOAREAU (laurent_waro) - Monday, 06 November 2017, 02:41 GMT
Hi Doug,
the command gives me :
drwx------ 3 - - 4096 28 sept. 06:31 .
drwxr-x---+ 40 - - 4096 6 nov. 05:48 ..
drwx------ 10 - - 4096 3 nov. 05:53 workbench

And in the directory 'workbench', this command gives me :
drwx------ 10 - - 4096 3 nov. 05:53 .
drwx------ 3 - - 4096 28 sept. 06:31 ..
drwx------ 2 - - 4096 3 nov. 06:40 cache
-rw-r--r-- 1 - - 3240 3 nov. 05:53 connections.xml
drwx------ 2 - - 4096 28 sept. 06:31 libraries
drwx------ 2 - - 4096 3 nov. 05:53 log
drwx------ 2 - - 4096 28 sept. 06:31 modules
drwx------ 2 - - 4096 28 sept. 06:31 scripts
-rw-r--r-- 1 - - 2933 3 nov. 05:53 server_instances.xml
drwx------ 2 - - 4096 28 sept. 06:31 snippets
drwx------ 2 - - 4096 3 nov. 05:53 sql_history
drwx------ 8 - - 4096 3 nov. 07:06 sql_workspaces

Thanks.
Comment by Doug Newgard (Scimmia) - Monday, 06 November 2017, 02:57 GMT
What kind of ownership is that?!? That's likely your problem.
Comment by Laurent HOAREAU (laurent_waro) - Monday, 06 November 2017, 13:00 GMT
Sorry, i replaced my username and the group by "- -" in the result of the ls command when I did the reply of your message.
So the problem comes for somewhere else...
Comment by Doug Newgard (Scimmia) - Monday, 06 November 2017, 13:34 GMT
So you thought it was a good idea to intentionally change/leave out critical info while debugging. Yeah, good luck.
Comment by Eli Schwartz (eschwartz) - Monday, 06 November 2017, 14:39 GMT
Yeah, that is needlessly confusing considering that your username is unlikely to be confidential information...
Comment by Laurent HOAREAU (laurent_waro) - Tuesday, 07 November 2017, 02:16 GMT
Hi Doug and Eli.
Sorry again for my stupid reflex. That's was not my intention. I didn't think about the consequences.
I deleted the workbench directory in .mysql/ and restart workbench but it doesn't change anything.
I tried to give access with read and write at all the workbench directory (with recursive) .mysql/ but I doesn't change anything too.

I can't remember when the problem occured for the first time. I uses workbench since 5 years under Archlinux. I began with the AUR version and pass to the 'stable' branch when the AUR version was stop.
The problem is on the two computers I used, and I use gnome 3.
At this point, I don't know where investigate...

Thanks of your help again.
Comment by Christian Hesse (eworm) - Tuesday, 07 November 2017, 06:46 GMT
What does it print when started from a terminal?
Any useful information in ~/.mysql/workbench/log/wb.log?
Comment by Laurent HOAREAU (laurent_waro) - Tuesday, 07 November 2017, 07:52 GMT
From the terminal :
Workbench can't find libproj.so, some options may be unavailable.
Ready.
Gtk-Message: GtkDialog mapped without a transient parent. This is discouraged.
terminate called after throwing an instance of 'std::runtime_error'
what(): locale::facet::_S_create_c_locale name not valid

And in the log, in the file attached

I tried to fix some preferences but nothing in the terminal and nothing in the log relative to changes in preferences
   wb.log (1.2 KiB)
Comment by Laurent HOAREAU (laurent_waro) - Tuesday, 07 November 2017, 07:58 GMT
For libproj.so, the package is already install (proj-4.9.3-1) and the libraries are present in the /usr/lib directory
Comment by Christian Hesse (eworm) - Tuesday, 07 November 2017, 08:13 GMT
Possibly an issue with your locale generation and/or settings?
Comment by Laurent HOAREAU (laurent_waro) - Wednesday, 08 November 2017, 02:37 GMT
Hum, what do you mean about "an issue with your locale generation and/or settings"?
Do you still talking about the file wb_options.xml or the locale of the system?

Where can I find a wb_options.xml? or do you think its necessary to try to install workbench by compilation?
Comment by Christian Hesse (eworm) - Wednesday, 08 November 2017, 21:02 GMT
I speak about the system locales:
https://wiki.archlinux.org/index.php/Locale

You terminal output shows some suspicious messages about the locale. Not sure if this can cause the issues you see, but let's try to fix that first.
Comment by Laurent HOAREAU (laurent_waro) - Friday, 10 November 2017, 03:05 GMT
Hi Christian,
for the locale, if I do a "locale" command in a terminal, I've got that :
LANG=fr_FR.UTF-8
LC_CTYPE="fr_FR.UTF-8"
LC_NUMERIC=fr_FR.UTF-8
LC_TIME=fr_FR.UTF-8
LC_COLLATE=fr_FR.UTF-8
LC_MONETARY=fr_FR.UTF-8
LC_MESSAGES="fr_FR.UTF-8"
LC_PAPER=fr_FR.UTF-8
LC_NAME="fr_FR.UTF-8"
LC_ADDRESS="fr_FR.UTF-8"
LC_TELEPHONE="fr_FR.UTF-8"
LC_MEASUREMENT=fr_FR.UTF-8
LC_IDENTIFICATION="fr_FR.UTF-8"
LC_ALL=

I think that my locale is ok. I use Gnome, but if it's true that it doesn't use the same settings for locale as a terminal environnement, actually, my gnome's locale is the same as my terminal environnement. To verify that, a command line "gsettings get org.gnome.system.locale region" returned me 'fr_FR.UTF-8'.

I noticed that when I closed workbench, I've got this message "locale::facet::_S_create_c_locale name not valid" in terminal.
Problems with this message were reported here, and locales are involved : https://bugs.mysql.com/bug.php?id=84908
I fixed my locale.conf by adding "en_US.UTF-8 UTF-8" and re-generating locales. In fact, there was only one locale in my locale.gen (it was fr_FR.UTF-8).

Now, Workbench can save settings in preferences and now the files and some new others are now present in the directory '~/.mysql/workbench`'.
Some problems I faced like some reported at https://bugs.mysql.com/bug.php?id=84908 don't appear anymore too!

So I think that my problem is solved! Thanks for driving me to a solution!

Still staying the problem with libproj.so that workbench doesn't find whereas it is already installed... Perhaps have you got any idea about that?

Thanks again!
Comment by Christian Hesse (eworm) - Friday, 10 November 2017, 07:45 GMT
The issue with libproj.so is unrelated, I do see it here as well.

Loading...