Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 21 additions & 0 deletions .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
## Description
Please include a summary of the change and which issue is fixed. Please also include relevant motivation and context.

## Type of change
- [ ] Bug fix (non-breaking change which fixes an issue)
- [ ] New feature (non-breaking change which adds functionality)
- [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected)
- [ ] Documentation update
- [ ] Performance optimization
Comment on lines +1 to +9
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

medium

This PR template is a great addition! To make it even more useful, I suggest a couple of enhancements:

  1. Explicit Issue Linking: Adding a Closes # (issue) line makes it very clear which issue is being addressed and allows GitHub to automatically close it upon merging.
  2. More Change Types: Including Refactoring and Chore provides more accurate options for categorizing PRs that don't add features or fix bugs, which is common in project maintenance.

These changes will help improve PR clarity and project management.

Suggested change
## Description
Please include a summary of the change and which issue is fixed. Please also include relevant motivation and context.
## Type of change
- [ ] Bug fix (non-breaking change which fixes an issue)
- [ ] New feature (non-breaking change which adds functionality)
- [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected)
- [ ] Documentation update
- [ ] Performance optimization
## Description
Please include a summary of the change and which issue is fixed. Please also include relevant motivation and context.
Closes # (issue)
## Type of change
- [ ] Bug fix (non-breaking change which fixes an issue)
- [ ] New feature (non-breaking change which adds functionality)
- [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected)
- [ ] Documentation update
- [ ] Performance optimization
- [ ] Refactoring (code structure changes with no new features)
- [ ] Chore (build process, tooling, or dependency updates)


## How Has This Been Tested?
Please describe the tests that you ran to verify your changes.

## Checklist:
- [ ] My code follows the style guidelines of this project
- [ ] I have performed a self-review of my own code
- [ ] I have commented my code, particularly in hard-to-understand areas
- [ ] I have made corresponding changes to the documentation
- [ ] My changes generate no new warnings
- [ ] I have added tests that prove my fix is effective or that my feature works
- [ ] New and existing unit tests pass locally with my changes
31 changes: 31 additions & 0 deletions .github/workflows/documentation.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
name: Documentation and Quality Checks

on:
push:
branches: ["main"]
pull_request:
branches: ["main"]

jobs:
link-checker:
name: Link Checker
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Link Checker
uses: lycheeverse/lychee-action@v2
with:
args: --exclude-mail --verbose --no-progress './**/*.md'
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

todo-scanner:
name: TODO/FIXME Scanner
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Scan for TODO/FIXME
run: |
echo "Scanning for TODO and FIXME comments in the codebase..."
# Exclude common meta-directories and the .github folder to avoid matching this workflow file
grep -rnEi "TODO|FIXME" . --exclude-dir={node_modules,.git,.next,.agent,.jules,.github} || echo "No TODO/FIXME comments found."
Comment on lines +28 to +31
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟠 Major

Don’t mask real grep errors as “no TODO/FIXME found.”

grep ... || echo ... treats both “no matches” and real execution errors the same. This can hide scanner failures.

Proposed fix
-          grep -rnEi "TODO|FIXME" . --exclude-dir={node_modules,.git,.next,.agent,.jules,.github} || echo "No TODO/FIXME comments found."
+          if grep -rnEi "\b(TODO|FIXME)\b" . --exclude-dir={node_modules,.git,.next,.agent,.jules,.github}; then
+            echo "TODO/FIXME comments found."
+          else
+            status=$?
+            if [ "$status" -eq 1 ]; then
+              echo "No TODO/FIXME comments found."
+            else
+              echo "grep failed with exit code $status"
+              exit "$status"
+            fi
+          fi
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In @.github/workflows/documentation.yml around lines 28 - 31, The current grep
pipeline ("grep -rnEi \"TODO|FIXME\" . --exclude-dir={...} || echo \"No
TODO/FIXME comments found.\"") masks real grep errors by treating exit code 1
(no matches) and >=2 (errors) the same; change it to run the grep command,
capture its exit code, and branch: if exit code is 0 let the matches print, if 1
print "No TODO/FIXME comments found.", and if >=2 write an error to stderr and
exit with that code. Reference the existing grep invocation string and the
fallback echo to locate where to implement this exit-code-aware logic.

7 changes: 7 additions & 0 deletions .lycheereignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# Exclude LinkedIn because it often returns 999 or 403 in CI
https://www.linkedin.com/.*
# Exclude Twitter/X
https://twitter.com/.*
https://x.com/.*
# Exclude local development URLs
http://localhost:.*
Comment on lines +2 to +7
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

medium

The regex patterns for ignoring URLs can be made more robust. The current patterns are quite specific and might miss variations of the URLs.

For example, https://www.linkedin.com/.* won't match http://linkedin.com/ or https://linkedin.com/. By using https? and (www\.)?, we can cover more cases (HTTP/HTTPS, with or without www.) and make the ignore list more effective.

https?://(www\.)?linkedin\.com/.*
# Exclude Twitter/X
https?://(www\.)?twitter\.com/.*
https?://(www\.)?x\.com/.*
# Exclude local development URLs
http://localhost:.*

Comment on lines +1 to +7
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟠 Major

🧩 Analysis chain

🌐 Web query:

For lycheeverse/lychee-action v2, what ignore filename is auto-detected by default: .lycheeignoreor.lycheereignore?

💡 Result:

.lycheeignore

Citations:


Rename .lycheereignore to .lycheeignore.

The file is named .lycheereignore, but lychee-action auto-detects .lycheeignore. The ignore patterns won't be applied in CI until the filename is corrected.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In @.lycheereignore around lines 1 - 7, The ignore file is misnamed
`.lycheereignore` so lychee-action won't pick up the patterns; rename the file
to `.lycheeignore` and ensure the same contents (LinkedIn, Twitter/X, localhost
patterns) are preserved so lychee-action can auto-detect and apply these ignore
rules.