Skip to content

Conversation

@matejchalk
Copy link
Collaborator

The @nx/eslint:workspace-rule generator uses __filename as meta.docs.url by default. This causes a validation error for the plugin config's audit.docsUrl, as a file path doesn't pass our z.string().url() validation.

To reduce friction for users, the validation has been tweaked to tolerate invalid URLs. A warning is logged, and the invalid URL is removed from the metadata to prevent broken links.

Implemented using Zod's .catch() method.

@matejchalk matejchalk marked this pull request as ready for review February 19, 2025 13:54
@github-actions
Copy link
Contributor

Code PushUp

🤨 Code PushUp report has both improvements and regressions – compared target commit 6816c00 with source commit 29a1bc6.

🕵️ See full comparison in Code PushUp portal 🔍

🏷️ Categories

🏷️ Category ⭐ Previous score ⭐ Current score 🔄 Score change
Performance 🟡 53 🔴 46 ↓ −6.3
Code coverage 🟢 91 🟢 91 ↑ +0.1
Security 🟡 75 🟡 75
Updates 🟡 77 🟡 77
Accessibility 🟢 92 🟢 92
Best Practices 🟢 100 🟢 100
SEO 🟡 61 🟡 61
Bug prevention 🟢 100 🟢 100
Code style 🟢 100 🟢 100
Documentation 🔴 23 🔴 23
👍 1 group improved, 👎 1 group regressed, 👍 2 audits improved, 👎 5 audits regressed, 10 audits changed without impacting score

🗃️ Groups

🔌 Plugin 🗃️ Group ⭐ Previous score ⭐ Current score 🔄 Score change
Lighthouse Performance 🟡 53 🔴 46 ↓ −6.3
Code coverage Code coverage metrics 🟢 91 🟢 91 ↑ +0.1

16 other groups are unchanged.

🛡️ Audits

🔌 Plugin 🛡️ Audit 📏 Previous value 📏 Current value 🔄 Value change
Lighthouse Speed Index 🟨 5.1 s 🟥 6.7 s ↑ +31.8 %
Lighthouse First Contentful Paint 🟨 2.8 s 🟥 3.2 s ↑ +14.5 %
Lighthouse Largest Contentful Paint 🟨 3.7 s 🟨 3.9 s ↑ +4.8 %
Lighthouse Total Blocking Time 🟥 2,640 ms 🟥 6,980 ms ↑ +164.6 %
Lighthouse Time to Interactive 🟥 13.1 s 🟥 14.8 s ↑ +12.7 %
Code coverage Branch coverage 🟨 85.9 % 🟨 86 % ↑ +0.1 %
Code coverage Line coverage 🟨 89.8 % 🟨 89.8 % ↑ +0.1 %
Lighthouse Minimizes main-thread work 🟥 12.2 s 🟥 19.3 s ↑ +58.6 %
Lighthouse Avoids enormous network payloads 🟩 Total size was 1,821 KiB 🟩 Total size was 1,825 KiB ↑ +0.2 %
Lighthouse JavaScript execution time 🟥 6.3 s 🟥 8.6 s ↑ +37.9 %
Lighthouse Metrics 🟩 100% 🟩 100% ↑ +12.7 %
Lighthouse Max Potential First Input Delay 🟥 1,670 ms 🟥 2,800 ms ↑ +67.5 %
Lighthouse Eliminate render-blocking resources 🟥 Potential savings of 860 ms 🟥 Potential savings of 440 ms ↓ −48.4 %
Lighthouse Initial server response time was short 🟩 Root document took 460 ms 🟩 Root document took 550 ms ↑ +19.3 %
Lighthouse Network Round Trip Times 🟩 20 ms 🟩 110 ms ↑ +367.9 %
Lighthouse Server Backend Latencies 🟩 150 ms 🟩 210 ms ↑ +37 %
Lighthouse Uses efficient cache policy on static assets 🟨 27 resources found 🟨 27 resources found ↓ −0.1 %

579 other audits are unchanged.

@matejchalk matejchalk merged commit a54295c into main Feb 19, 2025
17 checks passed
@matejchalk matejchalk deleted the tolerate-invalid-docs-url branch February 19, 2025 15:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants