Bug 157051 - Complaint about a missing template from the previous version's installation folder location
Summary: Complaint about a missing template from the previous version's installation f...
Status: UNCONFIRMED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
Version:
(earliest affected)
7.6.0.3 release
Hardware: All All
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: Templates Updates
  Show dependency treegraph
 
Reported: 2023-09-01 10:56 UTC by Eyal Rozenberg
Modified: 2024-02-09 09:28 UTC (History)
4 users (show)

See Also:
Crash report or crash signature:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Eyal Rozenberg 2023-09-01 10:56:43 UTC
I've recently upgraded LO 7.5 to 7.6 . Now, when I open Writer, I get the error message:

/opt/libreoffice7.5/share/template/common/styles/Default.ott does not exist

now, I do remember making kind of edit or another to the default template a few months ago. But - even if I did, this should certainly not happen: Either the edited template should be at a path within the user's home directory; or it should be at a path that's relative to the installation folder; or there should be some other handling of template paths which are invalidated by an update to a new version.
Comment 1 Stéphane Guillou (stragu) 2023-09-15 13:44:06 UTC
How did you edit the template in the first place?
I assume you uninstalled 7.5?
Does the message pop up in a dialog or in the console?
Please more information so we can try to reproduce.
Please also see bug 78707.
Comment 2 Eyal Rozenberg 2023-09-15 15:51:03 UTC
(In reply to Stéphane Guillou (stragu) from comment #1)
> How did you edit the template in the first place?

I don't remember... I'm sorry. It might have been related to trying to reproduce some other bug, where you need to have edited the default template. I'm not sure, sorry.

> I assume you uninstalled 7.5?

Yes, I have, and I was still getting this message.

> Does the message pop up in a dialog or in the console?

A dialog.


I'm sorry I don't have more information. But - this should be enough to have developers check the location of the default template, for the case of it somehow pointing to a previous installation's folder. Or some other appropriate heuristic.
Comment 3 QA Administrators 2023-09-16 03:22:12 UTC Comment hidden (obsolete)
Comment 4 Buovjaga 2023-10-02 07:14:41 UTC
Grepping through my user profile, I see .config/libreoffice/4/user/registrymodifications.xcu has paths like

$(brandbaseurl)/share/template/common/styles/Default.ott

So I guess in your case $(brandbaseurl) is still pointing to /opt/libreoffice7.5
Comment 5 Eyal Rozenberg 2024-02-07 23:04:47 UTC
This is happening again, after my upgrade from 7.6 to 24.2:

/opt/libreoffice/share/template/common/style/Default.ott does not exist

this has got to annoy a lot of upgrading users!

And getting two of these prompts on startup.

Version: 24.2.0.2 (X86_64) / LibreOffice Community
Build ID: b1fd3a6f0759c6f806568e15c957f97194bbec8f
CPU threads: 4; OS: Linux 6.6; UI render: default; VCL: gtk3
Locale: en-IL (en_IL); UI: en-US
Comment 6 Heiko Tietze 2024-02-08 08:33:58 UTC
(In reply to Eyal Rozenberg from comment #5)
> this has got to annoy a lot of upgrading users!
Doubt this.

>ls /usr/lib/libreoffice/share/template/common/styles/
Default.ott  Modern.ott  Simple.ott
(Arch Linux)

What goes into a release is decided by the package manager. It depends on your OS/DE how things work, if you don't update via direct download from TDF site.

I see no benefit in /opt nor using the version number in the directory.

Ultimately no UX topic, and likely NOB.
Comment 7 Eyal Rozenberg 2024-02-08 08:48:47 UTC
(In reply to Heiko Tietze from comment #6)
> > this has got to annoy a lot of upgrading users!
> Doubt this.
> ...
> What goes into a release is decided by the package manager.
>
> your OS/DE how things work, if you don't update via direct download from TDF
> site.

I actually do use the DEBs from the LibreOffice website, not my distribution's package (which is older); and I have not altered the template locations relative to those.

> >ls /usr/lib/libreoffice/share/template/common/styles/
> Default.ott  Modern.ott  Simple.ott
> (Arch Linux)

That's not what the DEBs we bundle do. They put templates in a directory whose name is LO-version-specific.

So... that's on us.

> I see no benefit in /opt nor using the version number in the directory.

If we do that, we must arrange it so that a new version notices this fact, and switches to a directory with a new name (at worst - with a prompt if it can't decide what to do).
Comment 8 Heiko Tietze 2024-02-08 09:30:49 UTC
[09:55] <htietze> cloph_away: This one is for you: tdf#157051
[10:01] <cloph_away> htietze: not really, that's more a fringe usecase where the user hardcoded those and then didn't reset the default template. If you were to set a default template for new documents, it is not from the installation directory, but from your own documents, and when you change your mind and want to have the default back, you'd use reset to default instead of manually picking the file from the installation folder. 
[10:03] <cloph_away> So if you think it is a LO problem, then one that isn't with the installers, but with the select-default-template functionality - if picking the builtin one it should not add it explicitly but should act as "reset to default" - whether that is worth doing for a niche problem: hard to tell..
[10:04] <cloph_away> (value in config should be <value>$(brandbaseurl)/share/template/common/styles/Default.ott</value> and not the explicit /opt/libreoffice7.5/.... path - so that path would "adjust" to whatever new version is installed)
[10:05] <cloph_away> and this is the case here.

=> NAB
Comment 9 Eyal Rozenberg 2024-02-08 19:44:42 UTC
(In reply to Heiko Tietze from comment #8)
> [10:01] <cloph_away> htietze: not really, that's more a fringe usecase where
> the user hardcoded those 

Nope, the developers or release masters hard-coded those. I never hard-coded anything in my LO profile.

> and then didn't reset the default template.

> If you
> were to set a default template for new documents, it is not from the
> installation directory, but from your own documents, and when you change
> your mind and want to have the default back, you'd use reset to default
> instead of manually picking the file from the installation folder. 

But I don't want to set a default template from my own documents.

> [10:03] <cloph_away> So if you think it is a LO problem, then one that isn't
> with the installers, but with the select-default-template functionality - if
> picking the builtin one it should not add it explicitly but should act as
> "reset to default" - whether that is worth doing for a niche problem: hard
> to tell..

If I have taken no niche action, this is not a niche problem.

> <value>$(brandbaseurl)/share/template/common/styles/Default.ott</value> and
> not the explicit /opt/libreoffice7.5/.... path - so that path would "adjust"
> to whatever new version is installed)

Which file is that supposed to be in?