Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Process] Unable to use Process on Windows 2003 in Symfony 2.3.12 #10681

Closed
macintoshplus opened this issue Apr 10, 2014 · 5 comments

Comments

Projects
None yet
4 participants
@macintoshplus
Copy link

commented Apr 10, 2014

After updating Symfony 2.3.11 to 2.3.12 , no more process using the Process component object Symfony works!

an error code 1 is always returned !

It works if I comment line 238 of src/Symfony/Component/Process/process.php file.

Command executed from the command line :
php app/console assetic:dump --env=prod

result:

Dumping all prod assets.
Debug mode is off.

10:29:18 [file+] D:/wwwroot/project/app/../web/bundles/project/min/g
lobal.css

  [Assetic\Exception\FilterException]
  An error occurred while running:
  "C:\Program Files\Java\jre7\bin\java.exe" "-jar" "D:/wwwroot/project/app/Re
  sources/java/yuicompressor-2.4.7.jar" "--charset" "UTF-8" "-o" "C:\Document
  s and Settings\adm\Local Settings\Temp\1\YUI36F.tmp" "--type" "css" "C:
  \Documents and Settings\adm\Local Settings\Temp\1\YUI36E.tmp"

  Input:
 [...]

assetic:dump [--watch] [--force] [--period="..."] [write_to]
@romainneutron

This comment has been minimized.

Copy link
Member

commented Apr 10, 2014

Hello, thanks for the report, can you add a var_dump($commandline) at line 245 so that I could see what is actually passed to proc_open ?

@macintoshplus

This comment has been minimized.

Copy link
Author

commented Apr 10, 2014

The result :

"cmd /V:ON /E:ON /C "("C:\Program Files\Java\jre7\bin\java.exe" "-ja
r" "D:/wwwroot_ieo/project/app/Resources/java/yuicompressor-2.4.7.jar" "--charset" "
UTF-8" "-o" "C:\Documents and Settings\adm\Local Settings\Temp\1\YUI377.tmp"
 "--type" "css" "C:\Documents and Settings\adm\Local Settings\Temp\1\YUI376.
tmp")" 1>C:\Documents and Settings\adm\Local Settings\Temp\1\sf_378.tmp 2>C:
\Documents and Settings\adm\Local Settings\Temp\1\sf_379.tmp"

There is no problem on Windows 7 or Windows 2008 R2.

@romainneutron

This comment has been minimized.

Copy link
Member

commented Apr 10, 2014

well, thanks for this detailed report

@romainneutron

This comment has been minimized.

Copy link
Member

commented Apr 17, 2014

@macintoshplus Could you try the patch I provided in #10728 and confirm it fixes your issue?

@macintoshplus

This comment has been minimized.

Copy link
Author

commented Apr 17, 2014

Hi,

Your patch works great!

Remains to be seen arriving in the next version of Symfony 2.3.

Thank you for your help.

fabpot added a commit that referenced this issue Apr 18, 2014

bug #10728 [2.3][Process] Fix #10681, process are failing on Windows …
…Server 2003 (romainneutron)

This PR was merged into the 2.3 branch.

Discussion
----------

[2.3][Process] Fix #10681, process are failing on Windows Server 2003

| Q             | A
| ------------- | ---
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #10681
| License       | MIT

Commits
-------

46fdfbb [Process] Fix #10681, process are failing on Windows Server 2003

@fabpot fabpot closed this Apr 18, 2014

fabpot added a commit that referenced this issue Apr 18, 2014

Merge branch '2.3' into 2.4
* 2.3:
  Textarea value should default to empty string instead of null.
  Fix doc blocks
  [Process] Fix #10681, process are failing on Windows Server 2003
  [Security] fix DBAL connection typehint
  [HttpFoundation] status 201 is allowed to have a body
  unified return null usages

Conflicts:
	src/Symfony/Component/Console/Helper/DescriptorHelper.php
	src/Symfony/Component/DependencyInjection/ContainerBuilder.php
	src/Symfony/Component/Finder/Tests/Iterator/RecursiveDirectoryIteratorTest.php
	src/Symfony/Component/Form/Extension/Core/DataTransformer/IntegerToLocalizedStringTransformer.php
	src/Symfony/Component/HttpKernel/Fragment/InlineFragmentRenderer.php

fabpot added a commit that referenced this issue Apr 18, 2014

Merge branch '2.4'
* 2.4:
  unified return null usages
  [Validator] added Japanese translation
  Textarea value should default to empty string instead of null.
  Fix doc blocks
  [Process] Fix #10681, process are failing on Windows Server 2003
  updated doc
  [Security] fix DBAL connection typehint
  [HttpFoundation] status 201 is allowed to have a body
  unified return null usages

Conflicts:
	src/Symfony/Component/DependencyInjection/ContainerBuilder.php
	src/Symfony/Component/DomCrawler/Crawler.php
	src/Symfony/Component/Security/Core/Authentication/Provider/PreAuthenticatedAuthenticationProvider.php

sandergo90 pushed a commit to sandergo90/symfony that referenced this issue Jul 4, 2019

Merge branch '2.3' into 2.4
* 2.3:
  Textarea value should default to empty string instead of null.
  Fix doc blocks
  [Process] Fix symfony#10681, process are failing on Windows Server 2003
  [Security] fix DBAL connection typehint
  [HttpFoundation] status 201 is allowed to have a body
  unified return null usages

Conflicts:
	src/Symfony/Component/Console/Helper/DescriptorHelper.php
	src/Symfony/Component/DependencyInjection/ContainerBuilder.php
	src/Symfony/Component/Finder/Tests/Iterator/RecursiveDirectoryIteratorTest.php
	src/Symfony/Component/Form/Extension/Core/DataTransformer/IntegerToLocalizedStringTransformer.php
	src/Symfony/Component/HttpKernel/Fragment/InlineFragmentRenderer.php

sandergo90 pushed a commit to sandergo90/symfony that referenced this issue Jul 4, 2019

Merge branch '2.4'
* 2.4:
  unified return null usages
  [Validator] added Japanese translation
  Textarea value should default to empty string instead of null.
  Fix doc blocks
  [Process] Fix symfony#10681, process are failing on Windows Server 2003
  updated doc
  [Security] fix DBAL connection typehint
  [HttpFoundation] status 201 is allowed to have a body
  unified return null usages

Conflicts:
	src/Symfony/Component/DependencyInjection/ContainerBuilder.php
	src/Symfony/Component/DomCrawler/Crawler.php
	src/Symfony/Component/Security/Core/Authentication/Provider/PreAuthenticatedAuthenticationProvider.php
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.