Skip to content

[HttpKernel] deprecate global dir to load resources from #33258

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

Merged
merged 1 commit into from
Aug 21, 2019

Conversation

Tobion
Copy link
Contributor

@Tobion Tobion commented Aug 20, 2019

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

Replaces #31958

Here two example deprecations by adding files in the deprecated locations:

Overwriting the resource "@AcmeBundle/Resources/config/routing.yaml" with "/vagrant/src/Resources/AcmeBundle/config/routing.yaml" is deprecated since Symfony 4.4 and will be removed in 5.0.
Loading the file "foobar.yaml" from the global resource directory "/vagrant/src" is deprecated since Symfony 4.4 and will be removed in 5.0.

@@ -80,23 +80,14 @@ public function getBundle($name);
* where BundleName is the name of the bundle
* and the remaining part is the relative path in the bundle.
*
* If $dir is passed, and the first segment of the path is "Resources",
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This description and the code is not compatible with #32845
But since we don't need these arguments anymore, it doesn't matter now.

@Tobion Tobion force-pushed the deprecate-global-resource-dir branch from 7d210c7 to db46679 Compare August 20, 2019 15:53
@Tobion
Copy link
Contributor Author

Tobion commented Aug 20, 2019

I need to take a look at the functional test setup which fail

@Tobion Tobion force-pushed the deprecate-global-resource-dir branch from db46679 to 4e615d5 Compare August 20, 2019 22:52
@Tobion Tobion force-pushed the deprecate-global-resource-dir branch from 4e615d5 to aa82566 Compare August 20, 2019 22:57
@Tobion
Copy link
Contributor Author

Tobion commented Aug 20, 2019

Tests are passing.

@nicolas-grekas nicolas-grekas added this to the next milestone Aug 21, 2019
@nicolas-grekas
Copy link
Member

Thank you @Tobion.

nicolas-grekas added a commit that referenced this pull request Aug 21, 2019
…om (Tobion)

This PR was merged into the 4.4 branch.

Discussion
----------

[HttpKernel] deprecate global dir to load resources from

| Q             | A
| ------------- | ---
| Branch?       | 4.4
| Bug fix?      | no
| New feature?  | no <!-- please update src/**/CHANGELOG.md files -->
| BC breaks?    | no     <!-- see https://symfony.com/bc -->
| Deprecations? | yes <!-- please update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass?   | yes    <!-- please add some, will be required by reviewers -->
| Fixed tickets | #31915   <!-- #-prefixed issue number(s), if any -->
| License       | MIT
| Doc PR        |

Replaces #31958

Here two example deprecations by adding files in the deprecated locations:
```
Overwriting the resource "@AcmeBundle/Resources/config/routing.yaml" with "/vagrant/src/Resources/AcmeBundle/config/routing.yaml" is deprecated since Symfony 4.4 and will be removed in 5.0.
Loading the file "foobar.yaml" from the global resource directory "/vagrant/src" is deprecated since Symfony 4.4 and will be removed in 5.0.
```

Commits
-------

aa82566 [HttpKernel] deprecate global dir to load resources from
@nicolas-grekas nicolas-grekas merged commit aa82566 into symfony:4.4 Aug 21, 2019
@Tobion Tobion deleted the deprecate-global-resource-dir branch August 21, 2019 15:10
@nicolas-grekas nicolas-grekas modified the milestones: next, 4.4 Oct 27, 2019
This was referenced Nov 12, 2019
$paths[] = $this->path;
}

if (4 !== \func_num_args() || func_get_arg(3)) {
Copy link
Contributor

@maxhelias maxhelias Nov 19, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This condition is weird no ? Because if we pass $triggerDeprecation on false, it still executed or I miss something ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants