Skip to content

media-library : optimizations#250

Draft
kmurugulla wants to merge 13 commits intomainfrom
media-bulk-status
Draft

media-library : optimizations#250
kmurugulla wants to merge 13 commits intomainfrom
media-bulk-status

Conversation

@kmurugulla
Copy link
Copy Markdown
Collaborator

Please always provide the GitHub issue(s) your PR is for, as well as test URLs where your change can be observed (before and after):

Fix #

Test URLs:

@aem-code-sync
Copy link
Copy Markdown

aem-code-sync bot commented Mar 13, 2026

Hello, I'm the AEM Code Sync Bot and I will run some actions to deploy your branch and validate page speed.
In case there are problems, just click a checkbox below to rerun the respective action.

  • Re-run PSI checks
  • Re-sync branch
Commits

@aem-code-sync
Copy link
Copy Markdown

aem-code-sync bot commented Mar 13, 2026

Page Scores Audits Google
📱 /tools/media-library/index.html PERFORMANCE A11Y SEO BEST PRACTICES SI FCP LCP TBT CLS PSI
🖥️ /tools/media-library/index.html PERFORMANCE A11Y SEO BEST PRACTICES SI FCP LCP TBT CLS PSI

@aem-code-sync aem-code-sync bot temporarily deployed to media-bulk-status March 13, 2026 15:07 Inactive
@aem-code-sync aem-code-sync bot temporarily deployed to media-bulk-status March 13, 2026 18:43 Inactive
Comment thread tools/media-library/indexing/bulk-status.js
@aem-code-sync aem-code-sync bot temporarily deployed to media-bulk-status March 13, 2026 19:15 Inactive
Comment thread tools/media-library/indexing/reconcile.js
Comment thread tools/media-library/indexing/reconcile.js
Comment thread tools/media-library/indexing/parse.js Outdated
@claude
Copy link
Copy Markdown
Contributor

claude bot commented Mar 13, 2026

Code review comment posted

@kmurugulla kmurugulla requested a review from amol-anand March 13, 2026 20:58
@aem-code-sync aem-code-sync bot temporarily deployed to media-bulk-status March 14, 2026 00:20 Inactive
Copy link
Copy Markdown
Contributor

@claude claude bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

placeholder

Comment thread tools/media-library/media-library.js Outdated
Comment thread tools/media-library/media-library.js Outdated
@kmurugulla kmurugulla marked this pull request as draft March 14, 2026 02:03
@aem-code-sync aem-code-sync bot temporarily deployed to media-bulk-status March 15, 2026 03:23 Inactive
@kmurugulla kmurugulla marked this pull request as ready for review March 15, 2026 03:23
@aem-code-sync aem-code-sync bot temporarily deployed to media-bulk-status March 15, 2026 03:31 Inactive
Comment thread tools/media-library/indexing/build.js
Comment thread tools/media-library/indexing/parse.js
Comment thread tools/media-library/media-library.js
Comment thread tools/media-library/media-library.js
@claude
Copy link
Copy Markdown
Contributor

claude bot commented Mar 15, 2026

Code Review

Issues Found

BLOCKING:

  • build.jsperf.medialog.* accessed unconditionally when perf defaults to null, causing a TypeError crash on incremental builds (inline suggestion posted)
  • parse.js — Retry callback omits isSuccess from return value; success/fail counters and recovered set are always wrong after retries (inline suggestion posted)

SHOULD FIX:

  • media-library.js — Two console.log statements fire unconditionally on every index run (not gated by isPerfEnabled()), violating the "no debug console.log" rule (inline suggestions posted)

One-Click Fixes

I have added GitHub Suggestions for all fixable issues. Go to Files changed and click Commit suggestion to apply each fix.

Verdict

REQUEST CHANGES

Copy link
Copy Markdown
Contributor

@claude claude bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Superseded by detailed review below - please ignore this entry.

Comment thread tools/media-library/indexing/build.js
Comment thread tools/media-library/indexing/parse.js
Comment thread tools/media-library/media-library.js
Comment thread tools/media-library/media-library.js
@claude
Copy link
Copy Markdown
Contributor

claude bot commented Mar 15, 2026

Code Review Summary. BLOCKING: (1) indexing/build.js ~line 103 -- Null dereference: perf.medialog.* accessed without null guard; perf defaults to null. Inconsistent with the if(perf and parseStats) guard used earlier in same function. (2) indexing/parse.js retry block -- isSuccess is never returned by the retry processConcurrently callback, making counter adjustments and recovery tracking completely dead code. Retried-but-successful pages permanently counted as failures in stats. SHOULD FIX: (1) media-library.js -- Two unconditional console.log calls (index start + end) fire for ALL users on every index. All other console.log in this PR are correctly gated behind isPerfEnabled(). Violates CLAUDE.md no-debug-console.log rule. (2) PR description -- After preview URL uses .aem.live (production) instead of .aem.page (feature branch preview). Correct URL: https://media-bulk-status--helix-tools-website--adobe.aem.page/tools/media-library/index.html. One-Click Fixes: A GitHub Suggestion has been added for the parse.js bug. Go to Files changed and click Commit suggestion to apply. Verdict: REQUEST CHANGES

@aem-code-sync aem-code-sync bot temporarily deployed to media-bulk-status March 16, 2026 13:19 Inactive
@kmurugulla kmurugulla changed the title Media bulk status media-library : optimizations Mar 17, 2026
@aem-code-sync aem-code-sync bot temporarily deployed to media-bulk-status March 17, 2026 20:34 Inactive
@aem-code-sync aem-code-sync bot temporarily deployed to media-bulk-status March 19, 2026 16:23 Inactive
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