Improve UX for model relinking: add context menu actions (Show Info, Open on CivitAI, Open containing folder), sanitize CivitAI descriptions, persist info dialog size, and adjust CSS spacing and visibility.
Extract local, HuggingFace, CivitAI and lora-manager searches into functions returning (results, found); build search_tasks and run them concurrently with asyncio.to_thread + asyncio.gather; consolidate result merging. Improves concurrency and clarity.
Improve text on buttons, info-panel rows, settings tooltips, and menu
labels to more accurately describe what each element does rather than
stating the obvious. No functional changes.
Adds a new include_brackets parameter to ColoredFormatter that controls
whether square brackets wrap timestamps, root labels, and log level names
in formatted log output. When True, brackets are applied; when False
(the default for AzLogsLogger), brackets are omitted for cleaner output.
This allows callers like AzLogsLogger to opt-in to bracket formatting
independently via the constructor.
- Update version field in config.js, log_funcs.js, and logger.js from 1.5.1 to 1.5.3
- Rename LoggerUtils to lowercase_kebab-case log_funcs in log_funcs.js description
- Simplify Logger description to lowercase logger in logger.js
- Remove 'Colorful logs in the console' detail from logger.js description
Capture and display the file path, line, and column where each log
call originated. Uses a lightweight stack-trace parser (Error().stack)
that skips internal log_system frames, preferring the first external
caller.
Changes:
- getCallsite(), parseStackLine(), formatCallsite(), formatSuffix() added
- log() and logModule() include callsite in logData and display it as
a parenthetical suffix on both console and exported output
- serializeLogEntry/logToStorage/logToInspector preserve callsite through
serialization round-trips
- exportLogs text output uses formatSuffix for consistent display
Console output (ColoredFormatter):
- Level name is now wrapped in [LEVEL] and left-padded via _format_level.
- Timestamp and root-label segments are individually bracket-wrapped, keeping
plain-output layout consistent with coloured output.
- Separator between fields is colourised (colour code derived from level theme)
so the table structure remains readable.
- New include_milliseconds init flag controls whether a fractional-second suffix
is appended to the timestamp; _format_time respects it.
- _display_logger_name unchanged; _split_logger_name still decomposes dotted names
into root / detail parts.
File logging (AzLogsLogger):
- file_handlers dict introduced to cache one RotatingFileHandler per top-level
root module, preventing duplicate handlers when multiple sub-modules log to
the same file (_get_file_handler / _get_log_file / _root_module_name).
- File handler formatter upgraded from a bare logging.Formatter to ColoredFormatter
(colours off, milliseconds on, datefmt hard-coded to
'%Y-%m-%d %H:%M:%S') so file output carries the same column structure as
the console formatter.
- reset_loggers method properly removes and closes all handlers (StreamHandler
and RotatingFileHandler) from every configured logger before clearing
self.loggers and self.file_handlers, allowing _get_logger to be called again
with fresh settings.
- set_file_logging now delegates to reset_loggers instead of simply clearing
the loggers dict.
- Bump web/log_system version from 1.5.0 to 1.5.1 to match core/
- Fix console inspector format: add space before suffix %c and trailing empty
color intent so suffix text is not merged with the preceding styled message
- Add edge case guard in splitModuleName for single-part module strings that
differ from LOGGER_NAME, restoring previous behavior of returning the
logger name as root and the full value as detail
- Increment log_system version from 1.5.0 to 1.5.1 in all module docstrings
- Add # ruff: noqa: T201 to log_funcs.py and logger.py to suppress
ruff T201 (favored print() usage) warning in logging utility modules
- Rename web/utils/{css-loader→css_loader,ErrorHandler→error_handler,IconUtils→icon_utils,ResourceManager→resource_manager} and web/log_system/{LoggerUtils→log_funcs} to lowercase_kebab-case naming convention
- Update all cross-import paths in the recreated utils and linker.js accordingly
- Add removeResolvedFromPopup / markEntryAsResolved to visually mark resolved entries in the ComfyUI Missing Models popup
- Add updateNodesDirectly to update graph node widgets in-place without triggering a full workflow reload
- Add checkAndOpenForMissingModels with isAutoOpenEnabled/setAutoOpenEnabled to auto-open the linker dialog when a workflow with missing models is loaded
- Add helper methods getMissingSearchKey, getSearchState, mergeSearchResults for per-entry search state caching and merging
- Bump package version from 1.4.1 to 1.5.0 across LoggerUtils.js, config.js, and logger.js
- Move changelog-style feature notes inline under the author/version JSDoc header
in LoggerUtils.js, replacing the trailing block comment with a structured list
- Rename LOG_MODULE_NAME from 'model-linker' to 'MLinker' for shorter prefixes
- Add USE_COLORS config option to control styled console output
- Refine log level color palette: purple/debug, green/info, amber/warn, red/error
- Update timestamp format to HH:mm:ss.SSS for millisecond precision
- Refactor console log rendering to a color-coded table layout with background
highlights on timestamps and logger name columns
- Add splitModuleName helper to separate root module from dotted sub-namespace
- Add stringifyArgs helper for safe serialization of non-string log arguments
(strings, errors, objects via JSON.stringify, fallback to String)
- Update serializeLogEntry and console output to use the new leveled layout
(levelName padded to fixed width)
- Bump version to 1.5.0 in config.py, log_funcs.py, and logger.py
- Add USE_COLORS = True to core/log_system/config.py
- Import USE_COLORS in log_funcs.py and pass it to the logger context as
use_colors, honouring AZLOGS_USE_COLORS env var when set
- Introduce LEVEL_THEME mapping per-level RGB colors for DEBUG/INFO/WARN/ERROR
- Add TIME_BG background color for timestamp blocks
- Refactor _color_level into _color_level_badge: bold + background color badge
- Add _color_timestamp, _color_root_label, _color_separator, _color_message helpers
- Format output as: <level-badge> <timestamp> <root-label> <message> <source>
- Split logger name into root/detail via _split_logger_name; show only detail in source field
- Non-colored fallback path uses same structured layout without ANSI codes
- Change logging stacklevel from 3 to 4 in all log helper functions
(create_module_logger, log_debug, log_info, log_warn, log_error) to
correctly attribute the caller location in stack output.
- Reduce level_field_width from 9 to 5 (e.g. ERROR→5 chars) and set
source_field_width to 0 so source column auto-sizes to its content.
- Add MESSAGE color (cyan) for log message highlighting in colored output.
- Extract four helper methods from ColoredFormatter.format:
_display_logger_name — strips the 'azlogs.' namespace prefix
_display_level_name — normalises WARNING → WARN for compact display
_format_time — builds HH:MM:SS.mmm timestamps
_color_level — applies bold+color to the level token
- Simplify format() to assemble [HH:MM:SS.mmm] LVL (logger:line): message
with the new helpers applied inline.
Move the inline search-control HTML block into a dedicated renderSearchControls()
method on LinkerManagerDialog so the search bar can be reused from multiple code paths.
Previously, the search controls were only rendered when no download source was known.
Now they are also shown when a download URL exists, giving users the ability to run a
search alongside the resolved download source.
Also normalises line endings on one affected line.
Update the HuggingFace Token tooltip to provide precise guidance on
creating a fine-grained token with only Read access to public gated
repos, explicitly noting that Write, Inference, Webhooks, Billing,
Jobs, and org permissions are not needed.
- Set default level/source field widths to 0 (no extra spacing) in DEFAULT_CONFIG
- Add level_field_width and source_field_width parameters to ColoredFormatter
- Pad/center level tag and ljust source tag ([name:lineno]) consistently
- Add _field_width() helper to safely convert config values to non-negative ints
- Pass config widths through to ColoredFormatter in AzLogsLogger setup
- Set LOG_MODULE_NAME to 'MLinker' in config.py
- Switch __init__.py to use create_module_logger(); remove inline logging.getLogger calls
- Rewrite log_funcs.py: introduce module-name normalization (_normalize_module_name/_normalize_module_path/_resolve_module_name), ModuleLogger class, and global log-level switching (set_global_level replaces per-module set_module_level)
- Enhance logger.py: show [name:lineno] in console prefix, sanitize log file names for safe filesystem paths, wrap RotatingFileHandler setup with OSError handling to fall back to console-only logging, pass stacklevel through log() and propagate kwargs to exception()
- Update web/log_system/logger.js: dispatch to level-specific console methods (debug/info/warn/error) via CONSOLE_METHODS map; replace truncated t/m/l/a localStorage schema with serializeLogEntry/deserializeLogEntry (backward-compatible with short keys); load saved logs on construction via loadLogs()
Remove ~8000 lines of inline JavaScript styles from linker.js and organize
them into two focused stylesheets:
- linker-shell.css: modal shell, backdrop, window controls, layout structure
- linker-main.css: main content area (cards, buttons, forms, dialogs, tabs)
Simplify and clean up css-variables.css variable definitions.
Update css-loader.js to load both new stylesheet files.
Significantly improves code maintainability and separation of concerns.
Remove individual CSS component file references and streamline css-loader
to only load css-variables.css. The web/css directory now contains the
consolidated stylesheet, reducing complexity and improving maintainability.
Enhance logging system with configurable module names and dynamic
localStorage keys to avoid conflicts between multiple plugin instances.
- Add LOG_MODULE_NAME and DEFAULT_LOGGER_NAME to web/log_system/config.js
- Update logger.js to use dynamic storage keys based on module name
- Change window property from ResolutionMasterLogger to dynamic key
- Add PyDoc metadata to core/log_system/config.py
- Add JSDoc metadata blocks to all web log_system files
Reorganize web utilities:
- Move css-loader.js from web/ to web/utils/
- Add ErrorHandler.js for centralized error handling
- Add ResourceManager.js for stylesheet and template loading
rename: web/css-loader.js => web/utils/css-loader.js
- Add 'node_title' field to model info dictionaries in get_node_model_info
- Display custom node titles in missing models dialog when available
- Show 'NodeLabel #id · CustomTitle' format for better model identification
- Split scale into startScale and targetScale for clarity
- Introduce padding constants (140px horizontal, 96px vertical)
- Calculate fitScale based on viewport and node dimensions with padding
- Constrain target scale between 0.15 and 1 minimum/max bounds
- Extract getCenteredOffset helper for offset calculations
- Simplify animation interpolation using consistent offset objects
Replace instant canvas jumps with smooth animated transitions using
ease-in-out-cubic easing. The animateCanvasToNode method calculates the
target offset based on node position and canvas dimensions, then smoothly
interpolates the canvas offset over 380ms. Includes proper cleanup of
pending animation frames and fallback handling for older ComfyUI versions.
- Remove backdrop click event listener that closed the dialog
- Change backdrop background from rgba(0,0,0,0.5) to transparent
- Hide backdrop entirely in show() method (display: none)
- Replace text-based locate icon (⌖) with SVG icon via getLocateIconHtml()
- Add CSS styling for .ml-node-chip-icon and its SVG element
- Replace blue accent color (rgba(78,161,255)) with green (rgba(114,211,138))
- Update select/input backgrounds to use CSS variables (--ml-border, --ml-panel-bg-strong)
- Add gradient backgrounds and border-radius improvements to dropdown lists
- Increase option padding and add smooth transitions
- Fix select option styling to respect theme variables
- Add enableWheelScrollChaining() to prevent scroll propagation in dropdowns
- Apply wheel scroll chaining to download target and combo autocomplete lists
- Add min-width: 0 to flex/grid containers to prevent overflow
- Remove bottom padding from options wrapper
- Reduce label widths from 220px to 150px for tighter layout
- Add input min-width: 0 and set input column to minmax(0, 380px)
- Align toggle control to right edge using margin-left: auto
- Adjust number row grid-template-columns to minmax(72px, 118px)
- Introduce responsive breakpoints at 900px and 760px
- Optimize small-screen layouts with reduced gaps and single-column stacking
- Persist active tab selection across dialog sessions via localStorage
- Replace CSS pseudo-element tooltips with centralized global tooltip element
- Add showTooltip/hideTooltip/bindTooltips methods with smart positioning
- Tooltip adapts to viewport edges with max-width constrained to available space
- Cleanup tooltip on dialog close to prevent memory leaks
Add align-content: start and align-items: start CSS properties to
.options-content, .options-header, .options-section, .options-stack,
.options-panel, and .options-body to ensure all child elements are
top-aligned instead of being centered or stretched by default grid
layout behavior.
- Move save button and status to fixed bottom actions section in sidebar
- Enable independent scrolling for main content area with custom scrollbar styling
- Implement section visibility toggling (is-hidden) instead of scroll-based navigation
- Restructure grid layout to use flexbox in sidebar for better control
- Add proper height constraints (100%, min-height: 0) to enable scrolling within flex/grid children
- Update mobile breakpoint to adjust sidebar height and border styling
Replace single-column card layout with two-pane shell (sidebar + main) for
better visual separation between provider sections. Introduce tabbed navigation
between CivitAI and HuggingFace settings.
Replace checkbox rows with modern toggle switches for all boolean search-method
options. Each toggle includes an inline tooltip for immediate context.
Add unsaved-changes status indicator (dirty/saved states) to improve UX.
Remove the separate 'How to get CivitAI session token' expandable help panel;
tooltip now contains concise instructions inline.
Update form layout to use grid-based input rows with consistent spacing and
improved mobile responsiveness via media queries. Adjust colors, borders,
and spacing throughout for a cleaner, more compact appearance.
- Add civitai_use_trpc_search and civitai_use_html_fallback config options
- Update search_civitai_for_file to conditionally use tRPC and HTML methods
- Include method flags in cache key to respect search method preferences
- Add checkboxes in options UI to control each CivitAI search method
- Add tooltip badges to all API key labels explaining their purpose
- Persist new settings to localStorage and pass through search pipeline
- Add grid-based layout for download target folder and type selectors
- Apply responsive design with media query for screens ≤720px
- Align labels consistently using flexbox for better visual alignment