I am wondering if there is any way / python code to force QGIS 3.12 to reload the data source of mesh layer and its assigned datasets?
Mesh layer is a .xmdf file that's similar to .2dm with assigned datasets.
My layer:
from qgis.core import QgsProject
layer = QgsProject.instance().mapLayersByName('urib_v61-T_F100_P')[0]
I tried:
layer.dataProvider().forceReload()
AttributeError: 'QgsMeshDataProvider' object has no attribute 'forceReload'
layer.dataProvider().Reload()
AttributeError: 'QgsMeshDataProvider' object has no attribute 'Reload'
This seems to just force redraw of layer in Map Canvas:
layer.setAutoRefreshInterval(360000)
layer.triggerRepaint()
This works for raster layers but doesn't seem to refresh assigned datasets:
layer.dataProvider().reloadData()