Skip to content

Commit

Permalink
Do not add docks if self.iface is not defined when using qgis_process (
Browse files Browse the repository at this point in the history
  • Loading branch information
Gustry committed Feb 21, 2024
1 parent 2c9a215 commit 7ab2553
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# Changelog

## Unreleased

- Fix loading of the plugin when used with `qgis_process`, contribution from @Gustry

## 4.1.0 - 2023-11-15

- Fix loading of the plugin when the Pandas library is not found, contribution from @Gustry
Expand Down
2 changes: 1 addition & 1 deletion DataPlotly/gui/dock.py
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@ def addDocksFromProject(self, document: QDomDocument):
# FIXME : trigger the plot creation (not working)
# main_panel = self.getDock(tag_name).main_panel
# main_panel.create_plot()
if self.read_from_project(document):
if self.iface and self.read_from_project(document):
self.iface.mainWindow().restoreGeometry(self.geometry)
self.iface.mainWindow().restoreState(self.state, version=999)
return True
Expand Down

0 comments on commit 7ab2553

Please sign in to comment.