Opened 5 days ago

Closed 5 days ago

Last modified 5 days ago

#70307 closed defect (duplicate)

qgis3: NetCDF files not recognized in current QGIS port that includes GDAL

Reported by: jeeq1997 Owned by: Veence (Vincent)
Priority: Normal Milestone:
Component: ports Version: 2.9.3
Keywords: sonoma Cc: nilason (Nicklas Larsson), stromnov (Andrey Stromnov), mascguy (Christopher Nielsen)
Port: qgis3 gdal py311-opencv4

Description

GDAL v3.9.0 installed with this version of QGIS Macports which seems to not include support for NetCDF files. It seems the version of GDAL that is currently installed with the QGIS port does not recognize the NetCDF file format because it might not be included in this GDAL build.

When trying to update the GDAL library port, I get the below error message, so perhaps there is also issues with Python and this version of QGIS port? Maybe there are two instances of Python installed, one in MacPort QGIS and another outside which maybe the conflict, Not sure. I know this is a ticket for GDAL specifically, but noting that trying to update the GDAL port had the below errors.

Thank you.

The following ports will be rebuilt:
 py311-opencv4 @4.8.0
 py311-fiona @1.9.6
 py311-gdal @3.8.4
 py311-rasterio @1.3.9
 py311-rsgislib @5.1.1
Continue? [Y/n]: Y
--->  Computing dependencies for py311-opencv4
Error: Can't install py311-opencv4 because conflicting ports are active: py311-opencv4
Error: rev-upgrade failed: Error rebuilding py311-opencv4

Change History (5)

comment:1 Changed 5 days ago by ryandesign (Ryan Carsten Schmidt)

Cc: nilason stromnov mascguy added
Keywords: sonoma added; Sonoma removed
Owner: set to Veence
Port: qgis3 gdal py311-opencv4 added; QGIS GDAL removed
Status: newassigned
Summary: NetCDF files not recognized in current QGIS port that includes GDALqgis3: NetCDF files not recognized in current QGIS port that includes GDAL

The gdal port has many variants (optional features). Consult the output of port variants gdal to learn what they are. One of them is called "netcdf" so I suspect you will want to enable that variant to get gdal to have support for netcdf. sudo port install gdal +netcdf

The message "Can't install py311-opencv4 because conflicting ports are active: py311-opencv4" occurs because the py311-opencv4 port declares that it conflicts with itself; this is clearly nonsense and needs to be corrected.

comment:2 Changed 5 days ago by ryandesign (Ryan Carsten Schmidt)

Priority: HighNormal

The message "The following ports will be rebuilt:" comes from the rev-upgrade part of MacPorts which runs after any port upgrade or installation to see if anything is broken. The fact that it found py311-opencv4 and others were broken and needed to be rebuilt does not necessarily have any relation to the fact that it was the gdal port you were upgrading.

comment:3 Changed 5 days ago by ryandesign (Ryan Carsten Schmidt)

Resolution: duplicate
Status: assignedclosed

So, the first problem should be solved by enabling gdal's +netcdf variant, and the second problem is already tracked in #69987.

comment:4 Changed 5 days ago by jeeq1997

sudo port install gdal +netcdf

Did indeed appear to fix the issue. THANK YOU so much for the quick replay and useful solution. Terminal also asked to rebuild various ports and then the py311-opencv4 error shows up if you try to rebuild, but this did not seem to affect the ability to import NetCDF files. Thank you for tracking this other issue.

comment:5 Changed 5 days ago by Christopher Nielsen <mascguy@…>

In 961e4409aa51872e64d443297dd90f790db20044/macports-ports (master):

opencv4: fix self conflict for python subports

Fixes: #69987
See: #70307

Note: See TracTickets for help on using tickets.