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

[FrameworkBundle] Workaround php -S ignoring auto_prepend_file #14272

Merged
merged 1 commit into from Apr 18, 2015

Conversation

@nicolas-grekas
Copy link
Member

commented Apr 8, 2015

Q A
Bug fix? yes
New feature? no
BC breaks? no
Deprecations? no
Tests pass? yes
Fixed tickets -
License MIT
Doc PR -

php -S front_controller.php (thus php app/console server:run) ignores auto_prepend_file for no reason.

@nicolas-grekas nicolas-grekas force-pushed the nicolas-grekas:fwk-fix23 branch from 865eb2a to 45c48bd Apr 8, 2015
@nicolas-grekas

This comment has been minimized.

Copy link
Member Author

commented Apr 8, 2015

@nicolas-grekas nicolas-grekas force-pushed the nicolas-grekas:fwk-fix23 branch from 45c48bd to dcde445 Apr 9, 2015
@jakzal

This comment has been minimized.

Copy link
Member

commented Apr 9, 2015

What about auto_append_file?

@nicolas-grekas

This comment has been minimized.

Copy link
Member Author

commented Apr 10, 2015

auto_append_file is bugged also, but we can't do anything about it, there is no sane way to detect that the filewill not be included.

@fabpot

This comment has been minimized.

Copy link
Member

commented Apr 10, 2015

Do we really need to support it here? Would it be better to just wait for the PHP bug fix? I mean, how many Symfony users are using this "weird" PHP feature anyway?

@nicolas-grekas

This comment has been minimized.

Copy link
Member Author

commented Apr 10, 2015

I rely on this to have a consistent debugging env (think dump()) all the time.

@nicolas-grekas

This comment has been minimized.

Copy link
Member Author

commented Apr 18, 2015

ping @symfony/deciders @symfony/mergers

@fabpot

This comment has been minimized.

Copy link
Member

commented Apr 18, 2015

👍

@nicolas-grekas nicolas-grekas merged commit dcde445 into symfony:2.3 Apr 18, 2015
1 of 2 checks passed
1 of 2 checks passed
fabbot.io Doing some proofreading and checking your coding style.
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details
nicolas-grekas added a commit that referenced this pull request Apr 18, 2015
…file (nicolas-grekas)

This PR was merged into the 2.3 branch.

Discussion
----------

[FrameworkBundle] Workaround php -S ignoring auto_prepend_file

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

`php -S front_controller.php` (thus `php app/console server:run`) ignores auto_prepend_file for no reason.

Commits
-------

dcde445 [FrameworkBundle] Workaround php -S ignoring auto_prepend_file
@nicolas-grekas nicolas-grekas deleted the nicolas-grekas:fwk-fix23 branch Apr 18, 2015
// Workaround https://bugs.php.net/64566
if (ini_get('auto_prepend_file') && !in_array(realpath(ini_get('auto_prepend_file')), get_included_files(), true)) {
require ini_get('auto_prepend_file');
}

This comment has been minimized.

Copy link
@stof

stof Apr 18, 2015

Member

this should be done only after the check for asset files IMO

This comment has been minimized.

Copy link
@nicolas-grekas

nicolas-grekas Apr 18, 2015

Author Member

To be a real and exact workaround, we must replicate the behavior of the native feature, thus doing this first

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
4 participants
You can’t perform that action at this time.