Bug 1980052 - udunits2 default path to unit database is not where it is installed
Summary: udunits2 default path to unit database is not where it is installed
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: udunits2
Version: 34
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Tom "spot" Callaway
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2021-07-07 16:54 UTC by Gary Granger
Modified: 2021-07-17 01:38 UTC (History)
2 users (show)

Fixed In Version: udunits2-2.2.28-3.fc34
Doc Type: ---
Doc Text:
Clone Of:
Environment:
Last Closed: 2021-07-17 01:38:55 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description Gary Granger 2021-07-07 16:54:32 UTC
Description of problem:

The udunits2 program fails to run with this error message:
udunits2: Couldn't initialize unit-system from database "/share/udunits/udunits2.xml": No such file or directory

The udunits2 package installs this file here:
/usr/share/udunits/udunits2.xml

Version-Release number of selected component (if applicable):
udunits2-2.2.28-2.fc34.x86_64

How reproducible:
Always happens if using the default, built-in path.

Steps to Reproduce:
1. Run 'udunits2' program to see the error message.

Actual results:

Expected results:
It is possible to override the unit-system path with the environment variable, and then the program prompts for units to convert:

# rpm -q udunits2
udunits2-2.2.28-2.fc34.x86_64
# export UDUNITS2_XML_PATH=/usr/share/udunits/udunits2.xml
# udunits2
You have: degC
You want: degF
    1 degC = 33.8 degF
    x/degF = 1.8*(x/degC) + 32

Additional info:
I assume the problem is in the default compiled into the library, because I discovered this problem when some other code failed to initialize the udunits2 library.

Comment 1 Fedora Update System 2021-07-08 15:04:11 UTC
FEDORA-2021-6ff07f7601 has been submitted as an update to Fedora 34. https://bodhi.fedoraproject.org/updates/FEDORA-2021-6ff07f7601

Comment 2 Fedora Update System 2021-07-09 01:52:49 UTC
FEDORA-2021-6ff07f7601 has been pushed to the Fedora 34 testing repository.
Soon you'll be able to install the update with the following command:
`sudo dnf upgrade --enablerepo=updates-testing --advisory=FEDORA-2021-6ff07f7601`
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2021-6ff07f7601

See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.

Comment 3 Gary Granger 2021-07-09 14:41:34 UTC
Works for me, thanks!

Comment 4 Fedora Update System 2021-07-17 01:38:55 UTC
FEDORA-2021-6ff07f7601 has been pushed to the Fedora 34 stable repository.
If problem still persists, please make note of it in this bug report.


Note You need to log in before you can comment on or make changes to this bug.