Repository navigation
fix(results): restore nested if blocks in trace panel template - #58
Merged
Merged
Conversation
Co-authored-by: sentry[bot] <39604003+sentry[bot]@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes a
TemplateSyntaxError: Invalid block tag on line 256: 'endif'that broke scenario result views (e.g./runs/{run_id}/results/{result_id}/).Root Cause
In commit
163f058, refactoring the target-trace section into a<details>element merged the outer{% if rep.trace %}and inner{% if rep.trace.spans %}checks into a single{% if rep.trace and rep.trace.spans %}. However, the inner block's{% else %}and{% endif %}were left in place alongside the outer{% endif %}and an extra closing</div>, leaving line 256's{% endif %}without a matching opening tag and causing Django's template compiler to fail immediately.Changes
{% if rep.trace %}around the<details>wrapper and an inner{% if rep.trace.spans %}inside<div class="mt-3">.{% else %}branch so the "target exported no spans" message can render as intended.</div>and extra{% endif %}.Fixes SIMPLEAUDITSTUDIO-2Q
@sentry <feedback>: Autofix iterates on these changes@sentry stop iterating: Autofix stops iterating on this run