Title: ubuntu-latest uses wrong JDK version · Issue #997 · actions/setup-java · GitHub
Open Graph Title: ubuntu-latest uses wrong JDK version · Issue #997 · actions/setup-java
X Title: ubuntu-latest uses wrong JDK version · Issue #997 · actions/setup-java
Description: Description: When [25] is selected, [17] is used. This issue seems to be specific to steps that use the sudo command. Logs: https://github.com/qzind/tray/actions/runs/23968390243/job/69912859804 Task version: v5 Platform: Ubuntu macOS Wi...
Open Graph Description: Description: When [25] is selected, [17] is used. This issue seems to be specific to steps that use the sudo command. Logs: https://github.com/qzind/tray/actions/runs/23968390243/job/69912859804 Ta...
X Description: Description: When [25] is selected, [17] is used. This issue seems to be specific to steps that use the sudo command. Logs: https://github.com/qzind/tray/actions/runs/23968390243/job/69912859804 Ta...
Opengraph URL: https://github.com/actions/setup-java/issues/997
X: @github
Domain: redirect.github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"ubuntu-latest uses wrong JDK version","articleBody":"**Description:**\nWhen [25] is selected, [17] is used. \n\nThis issue seems to be specific to steps that use the `sudo` command.\n\nLogs:\nhttps://github.com/qzind/tray/actions/runs/23968390243/job/69912859804\n\n**Task version:**\nv5\n\n**Platform:**\n- [x] Ubuntu\n- [ ] macOS\n- [ ] Windows\n\n**Runner type:**\n- [x] Hosted\n- [ ] Self-hosted\n\n**Repro steps:** \nhttps://github.com/qzind/tray/blob/669af6f31f3b6417c32299ea70376afe414825a1/.github/workflows/build.yaml\n\n**Expected behavior:**\nJava 25 is used\n\n**Actual behavior:**\nJava 17 is used","author":{"url":"https://github.com/tresf","@type":"Person","name":"tresf"},"datePublished":"2026-04-04T01:45:25.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":14},"url":"https://github.com/997/setup-java/issues/997"}
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:7ee770b6-35f6-fcd7-d317-fed7b1446ff1 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | D462:21FC3B:B595B8:F5EF1A:6A4C53E8 |
| html-safe-nonce | 0315b6f50521f988aef15741ec4b9c8f1aaef337ffba0e810baeb5571931888a |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJENDYyOjIxRkMzQjpCNTk1Qjg6RjVFRjFBOjZBNEM1M0U4IiwidmlzaXRvcl9pZCI6Ijc5NjgxNTg4MTQwNjU5Mzk0MzIiLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ== |
| visitor-hmac | 32ecbd8bb594b67242b35af035fc334fa59411e8b0789b2aa35ec7198080b2fa |
| hovercard-subject-tag | issue:4202926745 |
| github-keyboard-shortcuts | repository,issues,actions,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/actions/setup-java/997/issue_layout |
| twitter:image | https://opengraph.githubassets.com/63ad5b00a5e66e2ee6d6d8c81007aa4da158a921ea0bde26ebf0e0d188f5cdaf/actions/setup-java/issues/997 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/63ad5b00a5e66e2ee6d6d8c81007aa4da158a921ea0bde26ebf0e0d188f5cdaf/actions/setup-java/issues/997 |
| og:image:alt | Description: When [25] is selected, [17] is used. This issue seems to be specific to steps that use the sudo command. Logs: https://github.com/qzind/tray/actions/runs/23968390243/job/69912859804 Ta... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | tresf |
| hostname | github.com |
| expected-hostname | github.com |
| None | 3d11bb817438277de2a940854450e83a7d32b6aeb5014e9e6b00a6423900251c |
| turbo-cache-control | no-preview |
| go-import | github.com/actions/setup-java git https://github.com/actions/setup-java.git |
| octolytics-dimension-user_id | 44036562 |
| octolytics-dimension-user_login | actions |
| octolytics-dimension-repository_id | 196057608 |
| octolytics-dimension-repository_nwo | actions/setup-java |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 196057608 |
| octolytics-dimension-repository_network_root_nwo | actions/setup-java |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 14099438da5379150f15a2892474c7c7e6c0e55e |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width