Skip to content

Dumper: expose lazy object - skip virtual properties - #619

Open
Daaarkling wants to merge 21 commits into
nette:masterfrom
slevomat:fix-expose-virtual
Open

Daaarkling wants to merge 21 commits into
nette:masterfrom
slevomat:fix-expose-virtual

Conversation

@Daaarkling

Copy link
Copy Markdown
  • bug fix / new feature? bug fix
  • BC break? no
  • doc PR: nette/docs#??? no

For uninitialized lazy ghost proxies, skips virtual properties (property hooks) because their getters can trigger proxy initialization and cause for example Doctrine identity map collisions during error logging.

@dg
dg force-pushed the master branch 2 times, most recently from 1731e8d to efbf873 Compare July 18, 2026 02:16
dg added 20 commits August 18, 2026 13:15
Single helper replacing e.target everywhere; with shadow DOM coming,
composedPath()[0] is the element the event actually originated from.
Infrastructure for distributing styles as constructed stylesheets;
nothing consumes it yet.
CSS is no longer injected into the host page's document.head. Styles are
distributed as constructed stylesheets (adoptedStyleSheets) built from
the Tracy.css registry, so host-page styling cannot be affected by Tracy
and vice versa. This also makes Tracy styles work under CSP without
'unsafe-inline' style-src.

- Bar: <tracy-bar> shadow host, panels live inside a <tracy-div id=tracy-debug>
  wrapper kept for backward compatibility of third-party panel CSS; the
  panel popup window adopts the stylesheets explicitly in toWindow()
- BlueScreen: <tracy-bs> shadow host; the standalone error page keeps a
  document-level <style> so it renders without JavaScript
- standalone dumps: <tracy-dump> custom element with shadow root; upgrade is
  deferred while the parser is still constructing children
The shadow boundary now provides the isolation, so the #tracy-debug and
#tracy-bs selector prefixes and most of reset.css are no longer needed.
Layers are named tracy-base and tracy-components so they cannot collide
with the host page's own cascade layers (e.g. Tailwind).
setPointerCapture() replaces the document-level mousemove/mouseup +
touchmove/touchend pairs, works for touch input (which passive touchmove
listeners could not preventDefault), guarantees drag end delivery when
the pointer leaves the window, and removes the module-global dragging
flag. options.start is no longer invoked twice per drag.
…ssets

renderTemplate() no longer reads and minifies CSS/JS assets for templates
that do not embed them (agent markdown, AJAX content) and the expensive
object-graph traversal in findGeneratorsAndFibers() is computed once per
exception and reused by all render targets. The agent console block is no
longer emitted into .html files written by renderToFile().
…ustom properties

Adds 'auto' theme support driven by prefers-color-scheme. The .tracy-light
and .tracy-dark classes emitted by the Renderer keep working.
- BlueScreen panel callbacks may return a 'text' key with a markdown
  section included in renderAgent() output and .md log files
- new AgentPanel interface formalizes getAgentInfo() for Bar panels,
  method_exists() discovery still works
- Bar::renderAgent() isolates a throwing panel instead of aborting
- info panel provides a System Info section for agents
- redirect queue entries are logged to console in chronological order
…ception reports

- every logged exception appends a JSON Lines record (time, level, hash,
  message, report filename, source) usable by log aggregators and AI agents
- Logger::$retention ('30 days') deletes old .html/.md exception reports,
  checked opportunistically at most once a day
The header offers a button that copies the complete markdown report
(same content renderAgent() produces) to the clipboard - ready to paste
into an issue tracker or an AI assistant. The payload is embedded as an
inert JSON script inside the shadow root; the button appears only when
the Clipboard API is available.
Re-stamps request time and output-buffer level, clears timers, barDump
data, the live dump snapshot and per-request strategy state, and flushes
FileSession so deferred content of the previous request is persisted.
Intended for FrankenPHP worker mode, RoadRunner and Swoole.
- Bar lives in the top layer via the Popover API, no more z-index battles
  with host-page overlays and modal dialogs (with graceful fallback)
- toggles are keyboard-accessible (tabindex + Enter/Space activation)
- collapsed content uses hidden='until-found' so browser find-in-page
  reaches it and auto-expands the match
- Logger::$notifiers[] hooks for one-line Slack/Sentry/webhook integrations
- mailers receive the exception report filename as a third argument

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants