planetlabs / qgis-planet-plugin

Browse, filter, preview and download Planet Inc imagery in QGIS.
https://developers.planet.com/docs/integrations/qgis/
GNU General Public License v2.0
45 stars 12 forks source link

Run tests only on major releases #112

Closed john-dupuy closed 1 year ago

john-dupuy commented 1 year ago

There's a bug that's impacting the plugin install test:

FAIL: Plugin install, load, unload, and uninstall failed with the following:
Traceback (most recent call last):
  File "<string>", line 73, in <module>
  File "/usr/share/qgis/python/pyplugin_installer/installer.py", line 581, in installFromZipFile
    QgsSettings.createPluginTreeNode("_plugin_manager").childSetting("last-zip-directory").setValue(QFileInfo(filePath).absoluteDir().absolutePath())
AttributeError: 'NoneType' object has no attribute 'setValue'

I believe it may have come from https://github.com/qgis/QGIS/pull/51614? Regardless, we should only run tests and install against the stable releases.

john-dupuy commented 1 year ago

@Samweli I see you just did a release of the plugin - please update the changelog in planet_explorer/metadata.txt whenever you do a release.

It will resolve this test failure:

    def test_changelog_up_to_date(request):
        """
        Verifies:
            - PLQGIS-TC19
        """
        root_dir = request.config.rootdir
        if root_dir.basename == "tests":
            root_dir = root_dir / ".." / ".."
        most_recent_release_on_github = requests.get(
            urljoin(REPO_URL, "releases?per_page=1")
        ).json()[0]["name"]
        most_recent_release_in_changelog = get_recent_release_from_changelog(root_dir)
>       assert (
            most_recent_release_in_changelog == most_recent_release_on_github
        ), "Release on Github does not match the most recent changelog entry!"
E       AssertionError: Release on Github does not match the most recent changelog entry!
E       assert 'v2.2.0' == 'v2.3.0'
E         - v2.3.0
E         ?    ^
E         + v2.2.0
Samweli commented 1 year ago

@Samweli I see you just did a release of the plugin - please update the changelog in planet_explorer/metadata.txt whenever you do a release.

It will resolve this test failure:

@john-dupuy thanks,It is not an official release I was testing to see if the new custom plugin repository changes are in effect.

john-dupuy commented 1 year ago

@Samweli I see you just did a release of the plugin - please update the changelog in planet_explorer/metadata.txt whenever you do a release. It will resolve this test failure:

@john-dupuy thanks,It is not an official release I was testing to see if the new custom plugin repository changes are in effect.

Thanks @Samweli, not a huge issue. I suggest setting future non-official releases to a pre-release (non-production ready).

Samweli commented 1 year ago

Thanks @Samweli, not a huge issue. I suggest setting future non-official releases to a pre-release (non-production ready).

Sure, thanks. I have removed the release and the related tag, will update them after I have made changes in the metadata file.