[Bug] restart -g -d runs in the foreground
Maintainers usually reply within 1 day
Nobody has claimed this yet.
Assessment
- Difficulty
- 4/5
- Estimated time
- 1-2 days
- Newbie friendliness
- 65/100
Research direction
Start by reading src/ServerManager.php lines 156–166 and Workerman’s argument handling at vendor/workerman/workerman/src/Worker.php lines 1095–1103; then check the relevant test setup and docs/commands.md. Verify with a real run that both option orders start as a daemon, add a test for the behavior, and update the docs so they no longer advise avoiding the options together.
Written by the indexing model from the issue text.
Description
Problem
If you use both -g and -d in one command, the order of the two options decides the result.
bin/console workerman:server restart -g -d can start the server in the foreground, not as a daemon.
How to see it
src/ServerManager.php:156-166buildsWorker::$commandfrom-dand-gand gives it to Workerman.vendor/workerman/workerman/src/Worker.php:1095-1103reads the real$argvfirst and thenWorker::$command. It keeps only the first mode it finds (-dor-g).- So with
-g -din the shell, only-gis used and the daemon mode is lost. - This was found by reading the code. It was not tried with a real server yet.
Fix idea
- Set
Worker::$daemonizedirectly, or - pass only one mode string to Workerman and keep
-dand-gapart.
Done when
- The behaviour is checked with a real run.
-
restart -g -dandrestart -d -gboth run as a daemon. - A test covers it.
-
docs/commands.mdno longer says to avoid the two options together.
- Dominant language
- PHP
- Stars
- 2
- Forks
- 3
- Avg merge
- 39m
- Merged PRs (30d)
- 105
Getting set up
- Ships a Dockerfile or Docker Compose file
- Has a pull request template
- Read the contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from crazy-goat/workerman-bundle
-
[Tests] Strengthen '0'/'-5' warmup-timeout rejection assertions to include got suffixPossibly taken @rootsiemen claimed this 1 day ago. Opengood first issue priority:low type:refactor
Difficulty 1/5 1-3 hours Newbie friendliness 90/100
crazy-goat/workerman-bundle#1065 ·
Maintainers usually reply within 1 day
-
[Code Quality] CacheWarmupTimeoutConfig throws bare InvalidArgumentException instead of typed InvalidCacheWarmupTimeoutExceptionPossibly taken @rootsiemen claimed this 1 day ago. Openpriority:low type:refactor
Difficulty 2/5 1-3 hours Newbie friendliness 80/100
crazy-goat/workerman-bundle#1063 · 1 comment ·
Maintainers usually reply within 1 day
-
[Tests] Matrix sed rewrite class [a-z-]+ excludes digits — future symfony/foo2bar silently skippedOpenpriority:low type:refactor
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
crazy-goat/workerman-bundle#1060 ·
Maintainers usually reply within 1 day
-
[Code Quality] Test helper captureFingerprintForPid() duplicates MasterFingerprint UID readPossibly taken @rootsiemen claimed this 2 days ago. Opengood first issue priority:low type:refactor
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
crazy-goat/workerman-bundle#1057 ·
Maintainers usually reply within 1 day
-
[Code Quality] SfxDownloader extract path has no destination-writability pre-check for cached zipsOpenpriority:low type:refactor
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
crazy-goat/workerman-bundle#1052 ·
Maintainers usually reply within 1 day
All issues in crazy-goat/workerman-bundle
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
codeigniter4/CodeIgniter4#10616 ·
Maintainers usually reply within 1 day
-
bug code quality
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
SemanticMediaWiki/SemanticMediaWiki#7149 ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 65/100
google/site-kit-wp#13825 ·
Maintainers usually reply within 3 days
-
Made by AI module: MCP type: bug
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
Maintainers usually reply within 1 day