8000 [FrameworkBundle] remove esi/ssi renderers if inactive by dmaicher · Pull Request #25489 · symfony/symfony · GitHub
[go: up one dir, main page]

Skip to content

[FrameworkBundle] remove esi/ssi renderers if inactive #25489

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
Dec 14, 2017

Conversation

dmaicher
Copy link
Contributor
Q A
Branch? 2.7
Bug fix? yes
New feature? no
BC breaks? no
Deprecations? no
Tests pass? yes
Fixed tickets #25246
License MIT
Doc PR -

As found out within #25246 the esi/ssi fragment renderer services were registered for < 3.4 even when the framework config for it was disabled.

On 3.4+ this has been fixed already and the service definitions are removed.

With this fix the usual exception message appears when framework.esi or framework.ssi are disabled and using render_esi(...) or render_ssi(...):

An exception has been thrown during the rendering of a template ("The "esi" renderer does not exist.").

Note: Some people may see this exception when updating to this patch but this just means they are using esi/ssi without enabling it.

@fabpot
Copy link
Member
fabpot commented Dec 14, 2017

Thank you @dmaicher.

@fabpot fabpot merged commit e1c3652 into symfony:2.7 Dec 14, 2017
fabpot added a commit that referenced this pull request Dec 14, 2017
…aicher)

This PR was merged into the 2.7 branch.

Discussion
----------

[FrameworkBundle] remove esi/ssi renderers if inactive

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

As found out within #25246 the esi/ssi fragment renderer services were registered for < 3.4 even when the framework config for it was disabled.

On 3.4+ this has been fixed already and the service definitions are removed.

With this fix the usual exception message appears when `framework.esi` or `framework.ssi` are disabled and using `render_esi(...)` or `render_ssi(...)`:

```
An exception has been thrown during the rendering of a template ("The "esi" renderer does not exist.").
```

**Note: Some people may see this exception when updating to this patch but this just means they are using esi/ssi without enabling it.**

Commits
-------

e1c3652 [FrameworkBundle] remove esi/ssi renderers if inactive
@dmaicher dmaicher deleted the fix-25246 branch December 14, 2017 19:56
This was referenced Dec 15, 2017
nicolas-grekas added a commit that referenced this pull request Dec 15, 2017
This PR was merged into the 3.4 branch.

Discussion
----------

[FrameworkBundle] fix merge of 3.3 into 3.4

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

In 3.4+ there were tests for disabled esi/ssi already so now they have been duplicated by merging #25489 up from 2.7

This just cleans up the duplication.

Commits
-------

76e16ff [FrameworkBundle] fix merge of 3.3 into 3.4
This was referenced Jan 5, 2018
@trsteel88
Copy link
Contributor

Having an issue with a bundle template that uses render_esi(). It used to just automatically fallback to a normal render() in that instance.

Now it fails unless esi is enabled in config.yml. However, I don't want esi enabled for this specific project.

Is there a way around this?

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.

4 participants
0