From e607f96d270d88dee24ec03271b4bdd367b30c97 Mon Sep 17 00:00:00 2001 From: Gregor Zeitlinger Date: Tue, 24 Jun 2025 13:40:55 +0200 Subject: [PATCH 1/5] exclude https://central.sonatype.com/service/rest/repository/browse/maven-snapshots/io/opentelemetry/ - which is not available right now --- .github/workflows/reusable-markdown-link-check.yml | 7 ------- .gitignore | 1 + lychee.toml | 14 ++++++++++++++ 3 files changed, 15 insertions(+), 7 deletions(-) create mode 100644 lychee.toml diff --git a/.github/workflows/reusable-markdown-link-check.yml b/.github/workflows/reusable-markdown-link-check.yml index 23c28caed2bc..680c7d0ab981 100644 --- a/.github/workflows/reusable-markdown-link-check.yml +++ b/.github/workflows/reusable-markdown-link-check.yml @@ -14,14 +14,7 @@ jobs: - uses: lycheeverse/lychee-action@82202e5e9c2f4ef1a55a3d02563e1cb6041e5332 # v2.4.1 with: - # excluding links to pull requests and issues is done for performance - # stackexchange link fails with 403 when accessed by lychee args: > --include-fragments - --exclude "^https://github.com/open-telemetry/opentelemetry-java-instrumentation/(issues|pull)/\\d+$" - --exclude "^http://code.google.com/p/concurrentlinkedhashmap$" - --exclude "^https://softwareengineering.stackexchange.com/questions/29727" - --max-retries 6 - --max-concurrency 4 --github-token ${{ github.token }} . diff --git a/.gitignore b/.gitignore index 42e4e27f7515..308ea9e1651f 100644 --- a/.gitignore +++ b/.gitignore @@ -58,6 +58,7 @@ hs_err_pid* replay_pid* .attach_pid* .telemetry* +.lycheecache !java-agent/benchmark/releases/*.jar diff --git a/lychee.toml b/lychee.toml new file mode 100644 index 000000000000..e094e334d6f8 --- /dev/null +++ b/lychee.toml @@ -0,0 +1,14 @@ +max_retries = 6 +max-concurrency = 4 +cache = true + +# excluding links to pull requests and issues is done for performance +# stackexchange link fails with 403 when accessed by lychee +exclude = [ + '^https://github.com/open-telemetry/opentelemetry-java-instrumentation/(issues|pull)/\\d+$', + '^http://code.google.com/p/concurrentlinkedhashmap$', + '^https://softwareengineering.stackexchange.com/questions/29727', + '^https://central.sonatype.com/service/rest/repository/browse/maven-snapshots/io/opentelemetry/$', +] + + From 5cae04f0ea72120b115b7687ec9d0d8611474daa Mon Sep 17 00:00:00 2001 From: Gregor Zeitlinger Date: Tue, 24 Jun 2025 14:01:28 +0200 Subject: [PATCH 2/5] fix lychee --- .github/workflows/reusable-markdown-link-check.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/reusable-markdown-link-check.yml b/.github/workflows/reusable-markdown-link-check.yml index 680c7d0ab981..8f3a0c338305 100644 --- a/.github/workflows/reusable-markdown-link-check.yml +++ b/.github/workflows/reusable-markdown-link-check.yml @@ -15,6 +15,7 @@ jobs: - uses: lycheeverse/lychee-action@82202e5e9c2f4ef1a55a3d02563e1cb6041e5332 # v2.4.1 with: args: > + --config lychee.toml --include-fragments --github-token ${{ github.token }} . From f16820d2f91fd3176aebf1f20637ca8c4ebedb6c Mon Sep 17 00:00:00 2001 From: Gregor Zeitlinger Date: Tue, 24 Jun 2025 14:27:48 +0200 Subject: [PATCH 3/5] fix lychee --- .../workflows/reusable-markdown-link-check.yml | 3 +-- lychee.toml | 15 +++++++++++++-- 2 files changed, 14 insertions(+), 4 deletions(-) diff --git a/.github/workflows/reusable-markdown-link-check.yml b/.github/workflows/reusable-markdown-link-check.yml index 8f3a0c338305..7c2f372df4e8 100644 --- a/.github/workflows/reusable-markdown-link-check.yml +++ b/.github/workflows/reusable-markdown-link-check.yml @@ -15,7 +15,6 @@ jobs: - uses: lycheeverse/lychee-action@82202e5e9c2f4ef1a55a3d02563e1cb6041e5332 # v2.4.1 with: args: > - --config lychee.toml - --include-fragments + --config ./lychee.toml --github-token ${{ github.token }} . diff --git a/lychee.toml b/lychee.toml index e094e334d6f8..02104b506262 100644 --- a/lychee.toml +++ b/lychee.toml @@ -1,14 +1,25 @@ max_retries = 6 max-concurrency = 4 cache = true +no_progress = true + +# Stealth +user_agent = "Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:128.0) Gecko/20100101 Firefox/128.0" + +# Check links inside `` and `
` blocks and Markdown code blocks
+include_verbatim = true
+
+# Check fragments in links
+include_fragments = true
 
 # excluding links to pull requests and issues is done for performance
 # stackexchange link fails with 403 when accessed by lychee
 exclude = [
-  '^https://github.com/open-telemetry/opentelemetry-java-instrumentation/(issues|pull)/\\d+$',
+  '^https://github.com/open-telemetry/opentelemetry-java-instrumentation/(issues|pull)/\d+$',
   '^http://code.google.com/p/concurrentlinkedhashmap$',
-  '^https://softwareengineering.stackexchange.com/questions/29727',
+  '^https://softwareengineering.stackexchange.com/questions/29727.*',
   '^https://central.sonatype.com/service/rest/repository/browse/maven-snapshots/io/opentelemetry/$',
+  '^http://localhost:4318/.*',
 ]
 
 

From 449899d7366ac03896af7428cc200d367566592b Mon Sep 17 00:00:00 2001
From: Gregor Zeitlinger 
Date: Tue, 24 Jun 2025 14:30:04 +0200
Subject: [PATCH 4/5] fix lychee

---
 lychee.toml | 1 +
 1 file changed, 1 insertion(+)

diff --git a/lychee.toml b/lychee.toml
index 02104b506262..d3653bffdd05 100644
--- a/lychee.toml
+++ b/lychee.toml
@@ -19,6 +19,7 @@ exclude = [
   '^http://code.google.com/p/concurrentlinkedhashmap$',
   '^https://softwareengineering.stackexchange.com/questions/29727.*',
   '^https://central.sonatype.com/service/rest/repository/browse/maven-snapshots/io/opentelemetry/$',
+  '^file:///home/runner/work/opentelemetry-java-instrumentation/opentelemetry-java-instrumentation/instrumentation/gwt-2.0/javaagent/src/testapp/webapp/greeting/greeting.nocache.js$',
   '^http://localhost:4318/.*',
 ]
 

From 3dab72a0f4493a9fa1c467da98b35c6788f12e86 Mon Sep 17 00:00:00 2001
From: Gregor Zeitlinger 
Date: Tue, 24 Jun 2025 17:03:20 +0200
Subject: [PATCH 5/5] Apply suggestions from code review

Co-authored-by: Trask Stalnaker 
---
 lychee.toml | 9 +--------
 1 file changed, 1 insertion(+), 8 deletions(-)

diff --git a/lychee.toml b/lychee.toml
index d3653bffdd05..698a061990de 100644
--- a/lychee.toml
+++ b/lychee.toml
@@ -1,14 +1,9 @@
 max_retries = 6
-max-concurrency = 4
-cache = true
-no_progress = true
+max_concurrency = 4
 
 # Stealth
 user_agent = "Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:128.0) Gecko/20100101 Firefox/128.0"
 
-# Check links inside `` and `
` blocks and Markdown code blocks
-include_verbatim = true
-
 # Check fragments in links
 include_fragments = true
 
@@ -19,8 +14,6 @@ exclude = [
   '^http://code.google.com/p/concurrentlinkedhashmap$',
   '^https://softwareengineering.stackexchange.com/questions/29727.*',
   '^https://central.sonatype.com/service/rest/repository/browse/maven-snapshots/io/opentelemetry/$',
-  '^file:///home/runner/work/opentelemetry-java-instrumentation/opentelemetry-java-instrumentation/instrumentation/gwt-2.0/javaagent/src/testapp/webapp/greeting/greeting.nocache.js$',
-  '^http://localhost:4318/.*',
 ]