Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

QGIS: data tables don't appear #291

Closed
visr opened this issue Jun 8, 2023 · 2 comments · Fixed by #328
Closed

QGIS: data tables don't appear #291

visr opened this issue Jun 8, 2023 · 2 comments · Fixed by #328
Labels
QGIS Ribasim QGIS plugin

Comments

@visr
Copy link
Member

visr commented Jun 8, 2023

When loading one of the example models, it only loads the Edge and Node layers for me. The data tables that are in the GeoPackage don't show up like they did before. If I click on one of the data tables in the Nodes tab of the Ribasim widget, an empty data table appears. That is expected if the table doesn't exist, but this also happens for tables that do exist, like "Pump / static" in the basic model.

image

This is using QGIS 3.30.3 and current main branch.

@visr visr added QGIS Ribasim QGIS plugin bug labels Jun 8, 2023
@github-project-automation github-project-automation bot moved this to To do in Ribasim Jun 8, 2023
@SouthEndMusic
Copy link
Collaborator

Is this the issue discussed in #288?

@visr
Copy link
Member Author

visr commented Jun 9, 2023

No, it's another issue I found while looking into that one.

@visr visr closed this as completed in #328 Jun 16, 2023
visr added a commit that referenced this issue Jun 16, 2023
Fixes #291

The QGIS plugin uses this metadata table to get the table names. Since
switching from GDAL to SQLite for writing data tables, the data tables
were not registered in gpkg_contents anymore. The GeoPackage
[spec](http://www.geopackage.org/spec131/#attributes) says this needs to
be done, but GDAL itself is more lenient, still showing the data tables
without registering them.

So now the gpkg_contents of basic.gpkg looks like this:

<img width="734" alt="image"
src="https://github.com/Deltares/Ribasim/assets/4471859/0e8bf370-4cad-4c0a-844e-3a3cb6b15ef4">

Fixes #288 

Meant to create a separate PR for this, but
bd4aae4 fixes two more issues. One is
that clicking save before stopping editing did not trigger the old
`afterCommitChanges`, using `editingStopped` works in both cases. The
other is that the new column edge_type is now also filled in
automatically with "flow". There is #301 for control in QGIS. To fix
that this function also needs to be updated.
@github-project-automation github-project-automation bot moved this from To do to ✅ Done in Ribasim Jun 16, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
QGIS Ribasim QGIS plugin
Projects
Archived in project
Development

Successfully merging a pull request may close this issue.

2 participants