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

Cleanup OBE references to gdal_remote and "Online" QgsLayerType #728

Merged
merged 11 commits into from
Aug 17, 2023

Conversation

trey-stafford
Copy link
Contributor

@trey-stafford trey-stafford commented Aug 15, 2023

Description

Title. Related to #655.

The handling of the term "online" is a bit messy. For example, we have a function called vector_or_raster that is typed to return one of "Raster", "Vector", or "Online", but our mapping from provider -> layer type doesn't include "Online", so vector_or_raster will only return what its function name indicates - "Vector" or "Raster".

The only place we appear to use the "Online" QgsLayerType is in the export code that produces the layer csv. This puts "Online" in the "Vector or Raster" column for online layers! That seems confusing. Maybe a separate field for "On disk" that is true/false would be a better indicator. Online assets are still either vectors or rasters!

This PR takes one step in the right direction by cleaning up OBE references to gdal_remote layers and removes "Online" from the list of QgsLayerTypes. Instead, add in the unique "Online" behavior where it's used - in the export code!

Checklist

If an item on this list is done or not needed, check it with [x] or click the
checkbox.

  • The PR description links to issues that it resolves with closes #{issue_number}
  • Config lockfile updated (inv config.export > qgreenland/config/cfg-lock.json)
  • Environment lockfile updated if needed (conda-lock)
  • Version bumped if needed (bumpversion (major|minor|patch|prerelease|build))
  • CHANGELOG.md updated
  • Documentation updated if needed
  • New unit tests if needed

@trey-stafford trey-stafford marked this pull request as ready for review August 15, 2023 22:40
@MattF-NSIDC
Copy link
Member

I don't think I'll get to this til tomorrow!

CHANGELOG.md Outdated Show resolved Hide resolved
@MattF-NSIDC
Copy link
Member

This puts "Online" in the "Vector or Raster" column for online layers! That seems confusing. Maybe a separate field for "On disk" that is true/false would be a better indicator. Online assets are still either vectors or rasters!

💯 let's decouple these concepts.

@trey-stafford trey-stafford merged commit 69769b6 into main Aug 17, 2023
3 checks passed
@trey-stafford trey-stafford deleted the obe-gdal-remote branch August 17, 2023 18:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants