Conversation
Fix ImportConfig defaults (CI)
cjshrader
left a comment
There was a problem hiding this comment.
Thank you so much for your work here, this is a good start and will be a cool feature.
Beyond the comments I've left, can you also make sure you've run prek and resolved any issues it might report?
https://github.com/d4lfteam/d4lf/blob/main/README.md#formatting--linting
|
|
||
| Output format is a JSON list with a single entry, so it can be consumed by tools that expect a list. | ||
| """ | ||
| out_dir = IniConfigLoader().user_dir / "paragon" |
There was a problem hiding this comment.
We can discuss more in discord because I'm open to discussion, but right now I'm not entirely sold on having a separate file for paragon points. Why can't we just have it be part of the imported yaml profile? And then the active one is decided a lot like profiles, we have a property that they set for which profile should be used for paragon? But let's discuss.
There was a problem hiding this comment.
whats your name at discord ? :)
There was a problem hiding this comment.
Are you not Stillwater? No way two people were independently working on this exact same feature?
There was a problem hiding this comment.
DONE-I agree with the concern about a separate Paragon points file.
I updated the implementation so the imported Paragon payload is embedded directly into the generated/updated YAML profile under a top-level Paragon key.
The overlay still keeps the build/profile switcher, because users can have multiple D4LF profiles “active” and need a quick way to choose which Paragon payload is currently displayed. To avoid requiring manual config edits, I also persist the last selected profile/build so the overlay can reopen in the same state.
src/paragon_overlay.py
Outdated
| @@ -0,0 +1,639 @@ | |||
| # Integrated into D4LF as src.paragon_overlay | |||
There was a problem hiding this comment.
This code is very inconsistent with our existing code base. There is a lot here that I have no idea what it's doing or if it's needed. We're able to draw on the screen just fine in other code without 100 lines of constants, and it makes it difficult to evaluate what this code does. In vision_mode_with_highlighting and vision_mode_fast we use tkinter for drawing, can we not use tkinter here? And note we have things like Cam and ResManager to help us manage resolution changes, I think you'll be setting yourself up for errors if you're not using those.
There was a problem hiding this comment.
I’ll aim to: (1) replace the Win32 overlay with a tkinter canvas overlay, (2) route all coordinate/scaling through Cam/ResManager, and (3) remove the large constants/proc boilerplate. If you’d like, I can do this as a separate PR to keep review scope small.
There was a problem hiding this comment.
I think this PR is fine, all the changes will be to this code anyway which is new code
There was a problem hiding this comment.
DONE -I refactored the new paragon_overlay to match the existing codebase style: the Win32/ctypes layered overlay and constant boilerplate are removed and replaced with a tkinter Canvas overlay (similar to the vision modes). Window sizing is now driven via Cam.window_roi where available and ResManager().resolution for resolution/scaling, avoiding custom DPI/screen calculations. Also ran prek to ensure ruff passes.
Ran prek locally (uv run prek run -a) and pushed the resulting formatting/lint fixes. CI should now be clean.
src/scripts/handler.py
Outdated
| from src.utils.process_handler import kill_thread, safe_exit | ||
| from src.utils.window import screenshot | ||
|
|
||
| if sys.platform == "win32": |
There was a problem hiding this comment.
We can assume we're running on Windows
There was a problem hiding this comment.
DONE — removed the sys.platform == "win32" guard and treated Windows as the default runtime
src/paragon_overlay.py
Outdated
| @@ -0,0 +1,639 @@ | |||
| # Integrated into D4LF as src.paragon_overlay | |||
There was a problem hiding this comment.
I think this PR is fine, all the changes will be to this code anyway which is new code
README.md
Outdated
|
|
||
| Each window gives further instructions on how to use it and what kind of input it expects. | ||
|
|
||
| - Paragon overlay does not appear / does nothing |
There was a problem hiding this comment.
This was fine in common issues, just below the GUI closing with no error
There was a problem hiding this comment.
Done — moved the overlay troubleshooting item back under Common issues, directly below “GUI closes with no error”.
I updated the overlay to load Paragon data from the current profiles/*.yaml format (top-level Paragon written by paragon_export.py), while keeping legacy .json support for older exports. Also updated the default source directory and README references from ~/.d4lf/paragon/*.json to ~/.d4lf/profiles/*.yaml to match the new workflow
Update importer checkbox label and description Align README wording with new Paragon workflow
Release notes — Paragon Import/Export + Integrated Paragon Overlay
This patch adds full Paragon JSON export to D4LF’s build importers and integrates a Paragon overlay directly into D4LF (no separate overlay executable needed). It also improves naming consistency across sources and restores live file logging.
What’s new
Paragon Import / Export (to overlay-compatible JSON)
Export boards with rotation (0/90/180/270), glyph slug (if present), and a 21×21 node map (441 nodes) per board.
Export location defaults to ~/.d4lf/paragon (or your configured user dir).
Integrated Paragon overlay
Overlay module is now shipped inside D4LF and can be launched as a dedicated mode of the same app.
Multi-JSON folder loading
Overlay can load a single JSON file or a folder containing multiple *.json builds, with a build selector.
Configurable global hotkey toggle
New hotkey setting to start/stop the overlay (default F10).
CLI support
d4lf.exe --paragon-overlay ""
Importer improvements
Mobalytics: exports stable, “friendly slug” names.
Maxroll: exports friendly slugs instead of internal IDs and fixes missing helper references that could crash export.
D4Builds: fixes Paragon navigation logic and improves board naming; adds class-prefixed slugs for consistency.
Fixes
Live logfile writing restored
Fixes a regression where D4LF stopped updating live logs under d4lf/logs by preserving the file handler during GUI initialization.
Overlay reliability
Startup stability improvements and easier diagnostics via overlay-side logging.
Adds a practical recovery for “off-screen” overlay placement (delete d4_overlay_config.json next to d4lf.exe to reset).
New / used configuration keys
advanced_options.toggle_paragon_overlay (default: F10)
advanced_options.paragon_overlay_source_dir (set via the “Paragon Folder” button; defaults to ~/.d4lf/paragon)
Notes / limitations
Overlays typically won’t render over exclusive fullscreen; use borderless windowed in Diablo IV.
Website DOM changes can break scrapers (importers may need selector updates over time).