Add combined wipe tool for DC3D + TemporaryGraphicsHandlerService#3482
Conversation
There was a problem hiding this comment.
PR Summary:
- Adds a new "Wipe External Services" pushbutton under
Wipe.pulldownthat lets users combine and clear orphanedDirectContext3DServiceandTemporaryGraphicsHandlerServiceregistrations in one selectable list. - Gracefully degrades when a service (e.g.
TemporaryGraphicsHandlerService, Revit 2022+) is unavailable on older hosts. - Adds
bundle.yamlwith title/tooltip translations for 8 locales, consistent with sibling Wipe tools.
Review Summary:
The implementation correctly follows the existing pyrevit/revit/dc3dserver.py pattern for resolving/removing ExternalService servers (GetActiveServerIds, IsRegisteredServerId, RemoveServer), and error handling/fallback for unavailable services on older Revit versions is solid. Naming conventions (PEP8), blank-line spacing, and localization format all match repo conventions. One style issue was found: a couple of lines exceed Black's 88-character line length (manual +-based string concatenation), which conflicts with the PR's own checklist claiming Black formatting was applied. No functional/logic bugs were found.
Suggestions
There was a problem hiding this comment.
Pull request overview
This PR adds a new pyRevitTools pushbutton under Project → Wipe that lets users remove problematic external service servers from both DirectContext3D and TemporaryGraphicsHandlerService via a single combined picker, helping with crash/instability triage when third-party add-ins leave bad registrations behind.
Changes:
- Added a new “Wipe External Services” pushbutton script that enumerates active servers across two external service types and removes user-selected servers.
- Added localized button title + a detailed multi-language tooltip describing the tool and its use.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
| extensions/pyRevitTools.extension/pyRevit.tab/Project.panel/Wipe.pulldown/Wipe External Services.pushbutton/script.py | New combined selection/removal workflow for DirectContext3D + TemporaryGraphicsHandlerService external servers. |
| extensions/pyRevitTools.extension/pyRevit.tab/Project.panel/Wipe.pulldown/Wipe External Services.pushbutton/bundle.yaml | New localized UI metadata (title/tooltip) for the added pushbutton. |
|
📦 New work-in-progress (wip) builds are available for 6.5.4 |
|
📦 New work-in-progress (wip) builds are available for 6.5.4 |
|
📦 New work-in-progress (wip) builds are available for 6.5.4 |
|
📦 New work-in-progress (wip) builds are available for 6.5.4 |
|
📦 New work-in-progress (wip) builds are available for 6.5.4 |
Description
What
New pushbutton: Wipe External Services. Extends the existing DC3D
purge script to also cover TemporaryGraphicsHandlerService, with both
service types merged into one selectable list instead of separate
tools.
Why
Third-party plugins can leave orphaned/crashing registrations on
either service. One combined tool avoids having to hunt for two
different buttons when triaging a crash.
Checklist
Before submitting your pull request, ensure the following requirements are met:
pipenv run black {source_file_or_directory}