[hotfix] [docs] Fix broken flink-training links in hands-on section#27746
Open
kylerballiet wants to merge 1 commit intoapache:masterfrom
Open
[hotfix] [docs] Fix broken flink-training links in hands-on section#27746kylerballiet wants to merge 1 commit intoapache:masterfrom
kylerballiet wants to merge 1 commit intoapache:masterfrom
Conversation
Collaborator
featzhang
reviewed
Mar 7, 2026
Member
featzhang
left a comment
There was a problem hiding this comment.
Thanks for fixing the broken links 👍
Since the original implementation used .Site.Params.Branch, it might be better to keep the parameterization instead of hardcoding master.
For example:
{{ .Site.Params.TrainingBranch | default "master" }}
This would allow the training repository branch to be configurable in the future.
| - name: The rendered link name (required) | ||
| */}} | ||
| <a href="{{ .Site.Params.TrainingExercises }}/tree/{{ .Site.Params.Branch }}/"> | ||
| <a href="{{ .Site.Params.TrainingExercises }}/tree/master/"> |
Member
There was a problem hiding this comment.
{{ .Site.Params.TrainingBranch | default "master" }}
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What is the purpose of the change
Fix broken flink-training links in the Learn Flink docs. Several pages have a "Hands-on" section that use the
training_repoandtraining_linkshortcodes (e.g. Intro to the DataStream API, Data Pipelines & ETL, Streaming Analytics, Event-driven Applications). Two issues affected all of these: (1) the repo link pointed to a branch (e.g. release-2.2) that does not exist in apache/flink-training; (2) the exercise links usedblobfor paths that are directories in the repo, so the URLs were wrong. Both shortcodes now use themasterbranch, and the exercise shortcode usestreeinstead ofblob, so the links work on every page that uses them.Brief change log
training_repo.html: usemasterbranch for the repo URL instead of.Site.Params.Branchtraining_link.html: usetreeinstead ofblobfor exercise paths, and usemasterbranchVerifying this change
This change is a trivial rework / code cleanup without any test coverage.
I built the docs locally using the project's pinned Hugo version (0.124.1 via
setup_hugo.shandbuild_docs.sh) and verified the flink-training and exercise links on all affected Learn Flink pages (DataStream API, Data Pipelines & ETL, Streaming Analytics, Event-driven Applications); the links resolve correctly on each page. Note: building with a newer Hugo (e.g. 0.157 from Homebrew) produced several unrelated template errors, so I used the pinned version for verification.Does this pull request potentially affect one of the following parts:
Documentation