René's URL Explorer Experiment


Title: Command line: argfile paths with spaces, a thread pool never shut down, a --dry-run error naming a missing flag · Issue #40 · openjavaformat/open-java-format · GitHub

Open Graph Title: Command line: argfile paths with spaces, a thread pool never shut down, a --dry-run error naming a missing flag · Issue #40 · openjavaformat/open-java-format

X Title: Command line: argfile paths with spaces, a thread pool never shut down, a --dry-run error naming a missing flag · Issue #40 · openjavaformat/open-java-format

Description: What Three small command-line problems, each also open in google-java-format: Paths with spaces in an argfile: google/google-java-format#421. CommandLineOptionsParser splits an @argfile at every whitespace character and knows no quotes, ...

Open Graph Description: What Three small command-line problems, each also open in google-java-format: Paths with spaces in an argfile: google/google-java-format#421. CommandLineOptionsParser splits an @argfile at every wh...

X Description: What Three small command-line problems, each also open in google-java-format: Paths with spaces in an argfile: google/google-java-format#421. CommandLineOptionsParser splits an @argfile at every wh...

Opengraph URL: https://github.com/openjavaformat/open-java-format/issues/40

X: @github

direct link

Domain: github.com


Hey, it has json ld scripts:
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Command line: argfile paths with spaces, a thread pool never shut down, a --dry-run error naming a missing flag","articleBody":"### What\n\nThree small command-line problems, each also open in google-java-format:\n\n1. **Paths with spaces in an argfile**: [google/google-java-format#421](https://github.com/google/google-java-format/issues/421). `CommandLineOptionsParser` splits an `@argfile` at every whitespace character and knows no quotes, so the line `\"/tmp/dir with space/A.java\"` becomes three arguments. Each one is reported as \"Skipping non-Java file\", and the run exits 0 having formatted nothing. An argfile that names itself ends in a `StackOverflowError`.\n2. **A thread pool that is never shut down**: [google/google-java-format#384](https://github.com/google/google-java-format/issues/384). `Main.formatFiles` creates a fixed thread pool on every call and never shuts it down. The command line does not notice, because the process exits, but a tool that calls `Main` in-process keeps up to `MAX_THREADS` idle threads per call.\n3. **`--dry-run` with `--replace`**: [google/google-java-format#1094](https://github.com/google/google-java-format/issues/1094). The error says \"cannot use --dry-run and --in-place at the same time\", but there is no `--in-place`; the flag is `-i`, `-r` or `--replace`.\n\n### Fix\n\n1. Port [google/google-java-format#931](https://github.com/google/google-java-format/pull/931) by Karlheinz Friedberger (open): a single- or double-quoted string in an argfile is one argument, and an argfile that includes itself is reported as an error.\n2. Close the pool when `formatFiles` returns. On Java 21 `ExecutorService` is `AutoCloseable` and `close()` waits for the submitted tasks, so a try-with-resources is enough.\n3. Port [google/google-java-format#1451](https://github.com/google/google-java-format/pull/1451) by rootkiller6788 (open): the message names `--replace`.\n\n### Done when\n\n- `CommandLineOptionsParserTest` reads a quoted path with spaces from an argfile as one path, and a self-including argfile fails with a clear message;\n- a `MainTest` shows that no pool thread is left once `format` returns;\n- `CommandLineFlagsTest` expects `--replace` for both `--replace --dry-run` and `-i -n`;\n- the ported commits keep their upstream authors.\n","author":{"url":"https://github.com/abashev","@type":"Person","name":"abashev"},"datePublished":"2026-09-23T07:15:33Z","url":"https://github.com/openjavaformat/open-java-format/issues/40"}

react-profiling0
react-import-mapreact,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322
route-pattern/_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format)
route-controllervoltron_issues_fragments
route-actionissue_layout
fetch-noncev2:063dcac7-8420-75cf-e3a6-ba77276a08fb
current-catalog-service-hash81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114
request-idA174:9AE98:E18FC:12C6CF:6AFBAEE1
html-safe-nonce57796a86f014e7384bfd753d17e057e95040d875579b1c84ca4d2dae373f7bae
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJBMTc0OjlBRTk4OkUxOEZDOjEyQzZDRjo2QUZCQUVFMSIsInZpc2l0b3JfaWQiOiI3NTExMzk0OTY5MjAyNzAwMDAxIiwicmVnaW9uX2VkZ2UiOiJpYWQiLCJyZWdpb25fcmVuZGVyIjoiaWFkIn0=
visitor-hmacf41dd357f0d08017f116c3acf63483689826f81f1a684d1619bf78165c2f335e
hovercard-subject-tagissue:5550086789
github-keyboard-shortcutsrepository,issues,copilot
google-site-verificationApib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I
octolytics-urlhttps://collector.github.com/github/collect
analytics-location///voltron/issues_fragments/issue_layout
fb:app_id1401488693436528
apple-itunes-appapp-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/openjavaformat/open-java-format/40/issue_layout
twitter:imagehttps://opengraph.githubassets.com/9c6b006a49e62429ed5e051d793132889d08e3f8aec17e85163640f6be88d7b4/openjavaformat/open-java-format/issues/40
twitter:cardsummary_large_image
og:imagehttps://opengraph.githubassets.com/9c6b006a49e62429ed5e051d793132889d08e3f8aec17e85163640f6be88d7b4/openjavaformat/open-java-format/issues/40
og:image:altWhat Three small command-line problems, each also open in google-java-format: Paths with spaces in an argfile: google/google-java-format#421. CommandLineOptionsParser splits an @argfile at every wh...
og:image:width1200
og:image:height600
og:site_nameGitHub
og:typeobject
og:author:usernameabashev
hostnamegithub.com
expected-hostnamegithub.com
Nonee25fbd830d3e6ad0e8935c105cf4fdc70c593dffcd27bb45b790ae4fece5ea55
turbo-cache-controlno-preview
go-importgithub.com/openjavaformat/open-java-format git https://github.com/openjavaformat/open-java-format.git
octolytics-dimension-user_id325177626
octolytics-dimension-user_loginopenjavaformat
octolytics-dimension-repository_id1288055459
octolytics-dimension-repository_nwoopenjavaformat/open-java-format
octolytics-dimension-repository_publictrue
octolytics-dimension-repository_is_forktrue
octolytics-dimension-repository_parent_id214273098
octolytics-dimension-repository_parent_nwopalantir/palantir-java-format
octolytics-dimension-repository_network_root_id214273098
octolytics-dimension-repository_network_root_nwopalantir/palantir-java-format
turbo-body-classeslogged-out env-production page-responsive
disable-turbofalse
browser-stats-urlhttps://api.github.com/_private/browser/stats
browser-errors-urlhttps://api.github.com/_private/browser/errors
release08c8f17f9d27054a108b8b6254e405de0151f660
ui-targetfull
theme-color#1e2327
color-schemelight dark
react-app-nameissues

Links:

Skip to contenthttps://github.com/openjavaformat/open-java-format/issues/40#start-of-content
https://github.com/
Sign inhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fopenjavaformat%2Fopen-java-format%2Fissues%2F40
GitHubRepository hosting, code review, and collaborationhttps://github.com/platform
CopilotAI coding agent for tasks, projects, and automated workhttps://github.com/features/copilot
ActionsCI/CD and automationhttps://github.com/features/actions
Code QualityQuality analysis, fixes, and enforcementhttps://github.com/features/code-quality
CodespacesCloud development environmentshttps://github.com/features/codespaces
Code SecurityVulnerability detection and remediationhttps://github.com/security/advanced-security/code-security
Secret ProtectionSecret scanning and leak preventionhttps://github.com/security/advanced-security/secret-protection
All Featureshttps://github.com/features
Documentationhttps://docs.github.com/en
Traininghttps://learn.github.com/skills
Certificationshttps://learn.github.com/credentials
Build with Copilothttps://github.com/features/ai
Customize Copilothttps://docs.github.com/en/copilot/how-tos/copilot-on-github/customize-copilot/customize-copilot-overview
Integrationshttps://github.com/marketplace
Trending reposhttps://github.com/trending
GitHub Sponsorshttps://github.com/open-source/sponsors
Developer articleshttps://github.com/resources/articles
ChangelogYour source for the latest features, improvements, and fixes across GitHub products, all in one place.https://github.blog/changelog/
Enterpriseshttps://github.com/enterprise
Teamhttps://github.com/team
Startupshttps://github.com/enterprise/startups
Nonprofitshttps://github.com/solutions/industry/nonprofits
Healthcarehttps://github.com/solutions/industry/healthcare
Financial serviceshttps://github.com/solutions/industry/financial-services
Manufacturinghttps://github.com/solutions/industry/manufacturing
Governmenthttps://github.com/solutions/industry/government
See all industrieshttps://github.com/solutions/industry
Why GitHubhttps://github.com/why-github
Customer Storieshttps://github.com/customer-stories
Business insightshttps://github.com/solutions/executive-insights
Trust Centerhttps://github.com/trust-center
GitHub Advanced SecurityEnterprise-grade code securityhttps://github.com/security/advanced-security
Copilot for businessEnterprise-grade AI featureshttps://github.com/features/copilot/copilot-business
Premium SupportEnterprise-grade 24/7 supporthttps://github.com/enterprise/premium-support
Documentationhttps://docs.github.com/en
Resource centerhttps://github.com/resources
Bloghttps://github.blog/
Events & webinarshttps://github.com/resources/events
Community Forumhttps://github.com/orgs/community/discussions
Customer Storieshttps://github.com/customer-stories
Integrationshttps://github.com/marketplace
Customer supporthttps://help.github.com/
Traininghttps://learn.github.com/skills
GitHub Statushttps://www.githubstatus.com/
Abouthttps://github.com/about
Partnershttps://github.com/partners
Changeloghttps://github.blog/changelog/
GitHub UniverseThe event for developers, by developers — talks, workshops, and what’s next for GitHub.https://githubuniverse.com/
Pricinghttps://github.com/pricing
Sign inhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fopenjavaformat%2Fopen-java-format%2Fissues%2F40
Sign uphttps://github.com/signup?ref_cta=Sign+up&ref_loc=header+logged+out&ref_page=%2F%3Cuser-name%3E%2F%3Crepo-name%3E%2Fvoltron%2Fissues_fragments%2Fissue_layout&source=header-repo&source_repo=openjavaformat%2Fopen-java-format
Reloadhttps://github.com/openjavaformat/open-java-format/issues/40
Reloadhttps://github.com/openjavaformat/open-java-format/issues/40
Reloadhttps://github.com/openjavaformat/open-java-format/issues/40
openjavaformathttps://github.com/openjavaformat
open-java-formathttps://github.com/openjavaformat/open-java-format
Codehttps://github.com/openjavaformat/open-java-format
Issues30 (30)https://github.com/openjavaformat/open-java-format/issues
Pull requests5 (5)https://github.com/openjavaformat/open-java-format/pulls
Discussionshttps://github.com/openjavaformat/open-java-format/discussions
Actionshttps://github.com/openjavaformat/open-java-format/actions
Security and qualityhttps://github.com/openjavaformat/open-java-format/security
Insightshttps://github.com/openjavaformat/open-java-format/pulse
https://github.com/openjavaformat/open-java-format
New issuehttps://github.com/login?return_to=https://github.com/openjavaformat/open-java-format/issues/40
New issuehttps://github.com/login?return_to=https://github.com/openjavaformat/open-java-format/issues/40
Command line: argfile paths with spaces, a thread pool never shut down, a --dry-run error naming a missing flaghttps://github.com/openjavaformat/open-java-format/issues/40#top
bugSomething isn't workinghttps://github.com/openjavaformat/open-java-format/issues?q=state%3Aopen%20label%3A%22bug%22
https://github.com/abashev
abashevhttps://github.com/abashev
on Sep 23, 2026https://github.com/openjavaformat/open-java-format/issues/40#issue-5550086789
google/google-java-format#421https://github.com/google/google-java-format/issues/421
google/google-java-format#384https://github.com/google/google-java-format/issues/384
google/google-java-format#1094https://github.com/google/google-java-format/issues/1094
google/google-java-format#931https://github.com/google/google-java-format/pull/931
google/google-java-format#1451https://github.com/google/google-java-format/pull/1451
abashevhttps://github.com/abashev
bugSomething isn't workinghttps://github.com/openjavaformat/open-java-format/issues?q=state%3Aopen%20label%3A%22bug%22
on Sep 23, 2026https://github.com/openjavaformat/open-java-format/issues/40#event-31657291726
abashevhttps://github.com/abashev
on Sep 23, 2026https://github.com/openjavaformat/open-java-format/issues/40#event-31662008951
Read quoted arguments from parameter files, and refuse a file that in…https://github.com/openjavaformat/open-java-format/commit/f5e6b12d7be9e72e654258d64d89ddf40e12fa15
f5e6b12https://github.com/openjavaformat/open-java-format/commit/f5e6b12d7be9e72e654258d64d89ddf40e12fa15
Shut down the command line's thread pool when formatting is donehttps://github.com/openjavaformat/open-java-format/commit/c10548dd8f4830e75bf44a000defa577a006734c
c10548dhttps://github.com/openjavaformat/open-java-format/commit/c10548dd8f4830e75bf44a000defa577a006734c
Name --replace in the error for --dry-run with in-place formattinghttps://github.com/openjavaformat/open-java-format/commit/c73a0830bae8a7144ae03c0e9c26a9ea58c9a326
c73a083https://github.com/openjavaformat/open-java-format/commit/c73a0830bae8a7144ae03c0e9c26a9ea58c9a326
abashevhttps://github.com/abashev
completedhttps://github.com/openjavaformat/open-java-format/issues?q=is%3Aissue%20state%3Aclosed%20archived%3Afalse%20reason%3Acompleted
on Sep 23, 2026https://github.com/openjavaformat/open-java-format/issues/40#event-31685972731
Sign up for freehttps://github.com/signup?return_to=https://github.com/openjavaformat/open-java-format/issues/40
Sign in to commenthttps://github.com/login?return_to=https://github.com/openjavaformat/open-java-format/issues/40
bugSomething isn't workinghttps://github.com/openjavaformat/open-java-format/issues?q=state%3Aopen%20label%3A%22bug%22
https://github.com
Termshttps://docs.github.com/site-policy/github-terms/github-terms-of-service
Privacyhttps://docs.github.com/site-policy/privacy-policies/github-privacy-statement
Securityhttps://github.com/security
Statushttps://www.githubstatus.com/
Communityhttps://github.community/
Docshttps://docs.github.com/
Contacthttps://support.github.com?tags=dotcom-footer

Viewport: width=device-width


URLs of crawlers that visited me.