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

Ensure more specialised exceptions are raised in PyQGIS #55576

Merged
merged 1 commit into from
Dec 12, 2023

Conversation

nyalldawson
Copy link
Collaborator

instead of the generic QgsException one
Refs warning in #55481 (comment)

/tmp/work/geography/qgis/work/qgis-3.28.13/build/python/core/build/_core/sip_corepart0.cpp:38168: warning: exception of type 'QgsProviderConnectionException' will be caught
38168 |             catch (QgsProviderConnectionException &sipExceptionRef)
      |
/tmp/work/geography/qgis/work/qgis-3.28.13/build/python/core/build/_core/sip_corepart0.cpp:38158: warning:    by earlier handler for 'QgsException'
38158 |             catch (QgsException &sipExceptionRef)

instead of the generic QgsException one
Refs warning in qgis#55481 (comment)

```
/tmp/work/geography/qgis/work/qgis-3.28.13/build/python/core/build/_core/sip_corepart0.cpp:38168: warning: exception of type 'QgsProviderConnectionException' will be caught
38168 |             catch (QgsProviderConnectionException &sipExceptionRef)
      |
/tmp/work/geography/qgis/work/qgis-3.28.13/build/python/core/build/_core/sip_corepart0.cpp:38158: warning:    by earlier handler for 'QgsException'
38158 |             catch (QgsException &sipExceptionRef)
```
Copy link

🪟 Windows builds ready!

Windows builds of this PR are available for testing here. Debug symbols for this build are available here.

(Built from commit 51d7e9f)

@troopa81 troopa81 merged commit 5171e05 into qgis:master Dec 12, 2023
@qgis-bot
Copy link
Collaborator

The backport to release-3_28 failed:

The process '/usr/bin/git' failed with exit code 1
stderr
error: could not apply 51d7e9ff1a1... Ensure more specialised exceptions are raised in PyQGIS
hint: After resolving the conflicts, mark them with
hint: "git add/rm <pathspec>", then run
hint: "git cherry-pick --continue".
hint: You can instead skip this commit with "git cherry-pick --skip".
hint: To abort and get back to the state before "git cherry-pick",
hint: run "git cherry-pick --abort".

stdout
Auto-merging python/core/qgsexception.sip
CONFLICT (content): Merge conflict in python/core/qgsexception.sip

To backport manually, run these commands in your terminal:

# Fetch latest updates from GitHub
git fetch
# Create a new working tree
git worktree add .worktrees/backport-release-3_28 release-3_28
# Navigate to the new working tree
cd .worktrees/backport-release-3_28
# Create a new branch
git switch --create backport-55576-to-release-3_28
# Cherry-pick the merged commit of this pull request and resolve the conflicts
git cherry-pick 51d7e9ff1a1de84a4e6f6e9584c559338eb0dbfa
# Push it to GitHub
git push --set-upstream origin backport-55576-to-release-3_28
# Go back to the original working tree
cd ../..
# Delete the working tree
git worktree remove .worktrees/backport-release-3_28

Then, create a pull request where the base branch is release-3_28 and the compare/head branch is backport-55576-to-release-3_28.

@qgis-bot qgis-bot added the failed backport The automated backport attempt failed, needs a manual backport label Dec 12, 2023
@nyalldawson nyalldawson deleted the exceptions branch January 8, 2024 02:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
failed backport The automated backport attempt failed, needs a manual backport
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants