Skip to content

chore(auto-nav-sidebar): Improve missing page error readability#2880

Merged
SoonIter merged 1 commit intomainfrom
copilot/fix-missing-custom-page
Dec 15, 2025
Merged

chore(auto-nav-sidebar): Improve missing page error readability#2880
SoonIter merged 1 commit intomainfrom
copilot/fix-missing-custom-page

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented Dec 12, 2025

Summary

Colorized the missing custom page error message in auto-nav sidebar resolution to clearly highlight the absent file path and the _meta.json source, improving readability of the CLI output.

Related Issue

Checklist

  • Tests updated (or not required).
  • Documentation updated (or not required).
Original prompt

Error: The file "/Users/bytedance/Documents/codes/rspress/website/docs/en/guide/basic/custom-page" does not exist, please check it in "/Users/bytedance/Documents/codes/rspress/website/docs/en/guide/basic/_meta.json".


💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.

@netlify
Copy link
Copy Markdown

netlify bot commented Dec 12, 2025

Deploy Preview for rspress-v2 ready!

Name Link
🔨 Latest commit 2fe0b4f
🔍 Latest deploy log https://app.netlify.com/projects/rspress-v2/deploys/693fa9552d78450008c75726
😎 Deploy Preview https://deploy-preview-2880--rspress-v2.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

@CLAassistant
Copy link
Copy Markdown

CLAassistant commented Dec 12, 2025

CLA assistant check
All committers have signed the CLA.

@SoonIter
Copy link
Copy Markdown
Member

@copilot Error: The file "/Users/bytedance/Documents/codes/rspress/website/docs/en/guide/basic/custom-page" does not exist, please check it in "/Users/bytedance/Documents/codes/rspress/website/docs/en/guide/basic/_meta.json".

这个错误信息不是很好读懂,试着优化,可增加颜色显示

Copy link
Copy Markdown
Contributor Author

Copilot AI commented Dec 12, 2025

@copilot Error: The file "/Users/bytedance/Documents/codes/rspress/website/docs/en/guide/basic/custom-page" does not exist, please check it in "/Users/bytedance/Documents/codes/rspress/website/docs/en...

Updated the error to include colored highlights for the missing file and its meta source. Commit 6bba8d2. Screenshot:

Copilot AI changed the title [WIP] Fix missing custom page file in documentation [WIP] Improve missing custom page error readability Dec 12, 2025
@SoonIter SoonIter marked this pull request as ready for review December 12, 2025 13:05
Copilot AI review requested due to automatic review settings December 12, 2025 13:05
@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Dec 12, 2025

Rsdoctor Bundle Diff Analysis

📁 web

Path: website/doc_build/web/rsdoctor-data.json

📌 Baseline Commit: f4c42dbbfd | PR: #2893

Metric Current Baseline Change
📊 Total Size 14.6 MB 14.6 MB 0 B (0.0%)
📄 JavaScript 14.0 MB 14.0 MB 0 B (0.0%)
🎨 CSS 113.7 KB 113.7 KB 0 B (0.0%)
🌐 HTML 0 B 0 B N/A
📁 Other Assets 480.4 KB 480.4 KB 0 B (0.0%)

📦 Download Diff Report: web Bundle Diff

Generated by Rsdoctor GitHub Action

@SoonIter SoonIter changed the title [WIP] Improve missing custom page error readability chore(auto-nav-sidebar): Improve missing page error readability Dec 12, 2025
@SoonIter SoonIter force-pushed the copilot/fix-missing-custom-page branch from 6bba8d2 to 864584c Compare December 12, 2025 13:06
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR enhances the error message readability when a custom page file is missing during auto-nav sidebar resolution by adding colorized output to the CLI. The error message now highlights the missing file path in yellow, prefixes it with a red "Missing page file:" label, and shows the source _meta.json file in cyan.

Key Changes

  • Added picocolors import for terminal color formatting
  • Extracted metaFilePath variable to avoid duplication
  • Reformatted the error message with color-coded components for better visual clarity

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Timeless0911
Timeless0911 previously approved these changes Dec 15, 2025
@SoonIter SoonIter force-pushed the copilot/fix-missing-custom-page branch from 6a017ec to 2fe0b4f Compare December 15, 2025 06:23
@SoonIter SoonIter enabled auto-merge (squash) December 15, 2025 07:22
@SoonIter SoonIter merged commit 6b80077 into main Dec 15, 2025
9 checks passed
@SoonIter SoonIter deleted the copilot/fix-missing-custom-page branch December 15, 2025 07:24
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.

5 participants