Commit Graph

30321 Commits

Author SHA1 Message Date
Nicolas Grekas
9b7df39865 [DI] Add and wire ServiceSubscriberInterface 2017-03-22 20:26:09 +01:00
Fabien Potencier
fa36ce8858 minor #22067 [Yaml] ParseException: pcre.backtrack_limit reached (nicolas-grekas)
This PR was merged into the 3.3-dev branch.

Discussion
----------

[Yaml] ParseException: pcre.backtrack_limit reached

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

while merging 3.2 into master, I noticed that `testCanParseVeryLongValue` is triggering this error on master, due to this regexp that we added for handling yaml tags. This regexp needs to be fixed so that we can merge the test case.

ping @GuilhemN

Commits
-------

f0256f1aa5 [Yaml] Fix pcre.backtrack_limit reached
2017-03-22 12:08:11 -07:00
Fabien Potencier
065bf489fa feature #22011 [FrameworkBundle][Serializer] Add option to register a circular_reference_handler (lyrixx)
This PR was merged into the 3.3-dev branch.

Discussion
----------

[FrameworkBundle][Serializer] Add option to register a circular_reference_handler

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

---

Right now, it's quite hard (especially for new comers) to register a CircularReferenceHandler:

![screenshot1](https://cloud.githubusercontent.com/assets/408368/23959193/ce19bcec-09a4-11e7-82c7-80abd7b7f602.png)

---

This PR introduce an option to wire a service to the internal Object Normalizer.

Commits
-------

0a638f5352 [FrameworkBundle][Serializer] Add option to register a "circular_reference_handler"
2017-03-22 12:06:37 -07:00
Fabien Potencier
ad95227f73 bug #21208 [Validator] Add object handling of invalid constraints in Composite (SenseException)
This PR was submitted for the master branch but it was merged into the 2.7 branch instead (closes #21208).

Discussion
----------

[Validator] Add object handling of invalid constraints in Composite

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

This PR fixes a minor bug described in #21206. The constraint `Symfony\Component\Validator\Constraints\Composite` doesn't check in it's exception handling if the wrongly created instance of a nested constraint is an object, which is the expected type for a constraint.

Commits
-------

4bd2c22871 [Validator] Add object handling of invalid constraints in Composite
2017-03-22 12:05:14 -07:00
Claudio Zizza
4bd2c22871 [Validator] Add object handling of invalid constraints in Composite 2017-03-22 12:05:13 -07:00
Fabien Potencier
7b6006488e feature #19673 [DI] Deprecate Container::isFrozen and introduce isCompiled (ro0NL)
This PR was merged into the 3.3-dev branch.

Discussion
----------

[DI] Deprecate Container::isFrozen and introduce isCompiled

| Q | A |
| --- | --- |
| Branch? | "master" |
| Bug fix? | no |
| New feature? | yes |
| BC breaks? | no |
| Deprecations? | yes |
| Tests pass? | yes |
| Fixed tickets | comma-separated list of tickets fixed by the PR, if any |
| License | MIT |
| Doc PR | reference to the documentation PR, if any |

This deprecates the concept of freezing a container, implied by `Container::isFrozen`. However, freezing happens due compilation (`Container::compile`). So having just `isCompiled` instead seems more intuitive, and plays along well with `ContainerBuilder`.

Before/After;
- `Container::isFrozen`
  - Checks if the parameter bag is frozen, but is deprecated in 3.2
  - In 4.0 this methods does not exists and can be replaced with `getParameterBag() instanceof FrozenParameterBag` _or_ `isCompiled()`. Depending on what you want (to clarify; the behavior is different when passing a frozen bag to the constructor)
- `Container::isCompiled`
  - Truly checks if `compile()` has ran, and is a new feature
- `ContainerBuilder::merge` etc.
  - Now uses `isCompiled` instead of `isFrozen`, ie. we allow for it till compilation regarding the state of the paramater bag

Commits
-------

6abd312800 [DI] Deprecate Container::isFrozen and introduce isCompiled
2017-03-22 12:01:37 -07:00
Roland Franssen
6abd312800 [DI] Deprecate Container::isFrozen and introduce isCompiled 2017-03-22 19:49:34 +01:00
Fabien Potencier
c97407ee17 feature #19954 [Console] Exclude empty namespaces in text descriptor (ro0NL)
This PR was merged into the 3.3-dev branch.

Discussion
----------

[Console] Exclude empty namespaces in text descriptor

| Q | A |
| --- | --- |
| Branch? | "master" |
| Bug fix? | yes |
| New feature? | no |
| BC breaks? | no |
| Deprecations? | no |
| Tests pass? | yes |
| Fixed tickets | comma-separated list of tickets fixed by the PR, if any |
| License | MIT |
| Doc PR | reference to the documentation PR, if any |

Before:

```
$ bin/console

 doctrine
  doctrine:mapping:convert                [orm:convert:mapping] Convert mapping information between supported formats.
 orm <----
 router
  router:match                            Helps debug routes by simulating a path info match

$ bin/console list orm

  [Symfony\Component\Debug\Exception\ContextErrorException]
  Warning: max(): Array must contain at least one element

$ bin/console list generate

Available commands for the "generate" namespace:
  generate:bundle      Generates a bundle
  generate:command     Generates a console command
  generate:controller  Generates a controller
```

After:

```
$ bin/console

 doctrine
  doctrine:mapping:convert                [orm:convert:mapping] Convert mapping information between supported formats.
 router
  router:match                            Helps debug routes by simulating a path info match

$ bin/console list orm

Available commands for the "orm" namespace:
  orm:convert:mapping  Convert mapping information between supported formats.

$ bin/console list generate

Available commands for the "generate" namespace:
  generate:bundle             Generates a bundle
  generate:command            Generates a console command
  generate:controller         Generates a controller
  generate:doctrine:crud      Generates a CRUD based on a Doctrine entity
  generate:doctrine:entities  Generates entity classes and method stubs from your mapping information
  generate:doctrine:entity    Generates a new Doctrine entity inside a bundle
  generate:doctrine:form      Generates a form type class based on a Doctrine entity
```

Overrules #19776 but also includes other fixes related to aliases that popped up when writing tests 👍

Commits
-------

d5a7608036 [Console] Exclude empty namespaces in text descriptor
2017-03-22 11:48:53 -07:00
Fabien Potencier
858af7158f feature #21093 [Lock] Create a lock component (jderusse)
This PR was squashed before being merged into the 3.3-dev branch (closes #21093).

Discussion
----------

[Lock] Create a lock component

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | they will
| Fixed tickets | #20382
| License       | MIT
| Doc PR        | symfony/symfony-docs#7364

This PR aim to add a new component Lock going further than the FileSystem\LockHandler by allowing remote backend (like Redis, memcache, etc)
Inspired by

## Usage

The simplest way to use lock is to inject an instance of a Lock in your service
```php
class MyService
{
    private $lock;

    public function __construct(LockInterface $lock)
    {
        $this->lock = $lock;
    }

    public function run()
    {
        $this->lock->acquire(true);

        // If I'm here, no exception had been raised. Lock is acquired
        try {
            // do my job
        } finally {
            $this->lock->release();
        }
    }
}
```
Configured with something like
```yaml
services:
    app.my_service:
        class: AppBundle\MyService
        arguments:
            - app.lock.my_service
    app.lock.my_service:
        class: Symfony\Component\Lock\Lock
        factory: ['@locker', createLock]
        arguments: ['my_service']
```

If you need to lock serveral resource on runtime, wou'll nneed to inject the LockFactory.
```php
class MyService
{
    private $lockFactory;

    public function __construct(LockFactoryInterface $lockFactory)
    {
        $this->lockFactory = $lockFactory;
    }

    public function run()
    {
        foreach ($this->items as $item) {
            $lock = $this->lockFactory->createLock((string) $item);

            try {
                $lock->acquire();
            } catch (LockConflictedException $e) {
                continue;
            }

            // When I'm here, no exception had been, raised. Lock is acquired
            try {
                // do my job
            } finally {
                $lock->release();
            }
        }
    }
}
```
Configured with something like
```yaml
services:
    app.my_service:
        class: AppBundle\MyService
        arguments:
            - '@locker'
```

This component allow you to refresh an expirable lock.
This is usefull, if you run a long operation split in several small parts.
If you lock with a ttl for the overall operatoin time and your process crash, the lock will block everybody for the defined TTL.
But thank to the refresh method, you're able to lock for a small TTL, and refresh it between each parts.
```php
class MyService
{
    private $lock;

    public function __construct(LockInterface $lock)
    {
        $this->lock = $lock;
    }

    public function run()
    {
        $this->lock->acquire(true);

        try {
            do {
                $finished = $this->performLongTask();

                // Increase the expire date by 300 more seconds
                $this->lock->refresh();
            } while (!$finished)
            // do my job
        } finally {
            $this->lock->release();
        }
    }
}
```

## Naming anc implementation choise

```
$lock->acquire()
vs
$lock->lock()
```

Choose to use acquire, because this component is full of `lock` Symfony\Component\Lock\Lock::Lock` raised a E_TOO_MANY_LOCK in my head.

```
$lock->acquire(false);
$lock->acquire(true);
vs
$lock->aquire()
$lock->waitAndAquire()
```

Not a big fan of flag feature and 2. But I choose to use the blocking flag to offer a simple (and common usecase) implementation

```
$lock = $factory->createLock($key);
$lock->acquire();
vs
$lock->aquire($key)
```

I choose to a the pool of locks implementation. It allow the user to create 2 instances and use cross lock even in the same process.

```
interface LockInterface
final class Lock implements LockInterface
vs
final class Lock
```

I choose to use a Interface even if there is only one implementaiton to offer an extension point here

# TODO

## In this PR
* [x] tests
* [x] add logs
* [x] offer several redis connectors
* [x] try other store implementation to validate the architecture/interface

## In other PR
* documentation
* add configuration in framework bundle
* add stop watch in the debug bar
* improve the combined store (takes the drift into account and elapsed time between each store)
* implement other stores (memcache, ...)
* use this component in session manipulation (fixes #4976)

Commits
-------

018e0fc330 [Lock] Create a lock component
2017-03-22 11:45:21 -07:00
Jérémy Derussé
018e0fc330 [Lock] Create a lock component 2017-03-22 11:45:19 -07:00
Roland Franssen
d5a7608036 [Console] Exclude empty namespaces in text descriptor 2017-03-22 19:41:00 +01:00
Fabien Potencier
6327b4161d feature #21007 [WebProfilerBundle] Improve AJAX toolbar panel (ro0NL)
This PR was squashed before being merged into the 3.3-dev branch (closes #21007).

Discussion
----------

[WebProfilerBundle] Improve AJAX toolbar panel

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #... <!-- #-prefixed issue number(s), if any -->
| License       | MIT
| Doc PR        | symfony/symfony-docs#... <!--highly recommended for new features-->

Before

![image](https://cloud.githubusercontent.com/assets/1047696/21394974/072b3570-c79b-11e6-8104-23e9be365b0b.png)

![image](https://cloud.githubusercontent.com/assets/1047696/21383263/1dc484fc-c765-11e6-84e8-7133d67da324.png)

After

![image](https://cloud.githubusercontent.com/assets/1047696/21394997/1a508cb8-c79b-11e6-87de-962ac41c9022.png)

![image](https://cloud.githubusercontent.com/assets/1047696/21383308/53b4f196-c765-11e6-8993-2645f342c7e9.png)

Commits
-------

afbcaa7a32 [WebProfilerBundle] Improve AJAX toolbar panel
2017-03-22 11:29:13 -07:00
Roland Franssen
afbcaa7a32 [WebProfilerBundle] Improve AJAX toolbar panel 2017-03-22 11:28:54 -07:00
Fabien Potencier
d378947321 feature #20642 [FrameworkBundle] Add project directory default for installing assets (Noah Heck)
This PR was merged into the 3.3-dev branch.

Discussion
----------

[FrameworkBundle] Add project directory default for installing assets

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

This allows the `assets:install` console command to have a fallback default of the project root directory.

Current behavior is to install assets only in the `target` of the current working directory.

Commits
-------

7a11f3ecf3 [FrameworkBundle] Add project directory default for installing assets
2017-03-22 11:06:20 -07:00
Fabien Potencier
1cb9afde12 feature #20365 [TwigBridge] Handle form label attributes like others (ro0NL)
This PR was squashed before being merged into the 3.3-dev branch (closes #20365).

Discussion
----------

[TwigBridge] Handle form label attributes like others

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

The HTML for rendering attributes is duplicated in multiple blocks, making it error prone/hard to maintain.

Next, the label attributes followed a different approach. Imo. all should follow the same base rendering, showing the above is actually an issue.

Commits
-------

e317e0aeab [TwigBridge] Handle form label attributes like others
2017-03-22 10:41:18 -07:00
Roland Franssen
e317e0aeab [TwigBridge] Handle form label attributes like others 2017-03-22 10:41:14 -07:00
Fabien Potencier
a4a41662a6 feature #22010 [FrameworkBundle][Translator] Make the Translator works with any PSR-11 container (chalasr)
This PR was merged into the 3.3-dev branch.

Discussion
----------

[FrameworkBundle][Translator] Make the Translator works with any PSR-11 container

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

Uses a service-locator for collected translation loaders and replace the single call of `getParameter()` by an optional constructor argument.

Commits
-------

85177a649e [FrameworkBundle] Make Translator works with any PSR-11 container
2017-03-22 09:31:28 -07:00
Robin Chalas
85177a649e [FrameworkBundle] Make Translator works with any PSR-11 container 2017-03-22 16:47:35 +01:00
Fabien Potencier
7c308be5de bug #22070 [PhpUnitBridge] add errors as late as possible (xabbuh)
This PR was merged into the 3.3-dev branch.

Discussion
----------

[PhpUnitBridge] add errors as late as possible

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

PHPUnit may change the test's state after the listener's startTest()
method has been executed thus leading to broken test result output.

Commits
-------

167742e521 add errors as late as possible
2017-03-22 08:44:06 -07:00
Robin Chalas
5446903296 [FrameworkBundle] Allow configuring serializer mapping paths 2017-03-22 16:36:42 +01:00
Fabien Potencier
4149eab349 minor #22108 [Console] Fix ConsoleLoggerTest (chalasr)
This PR was merged into the 3.3-dev branch.

Discussion
----------

[Console] Fix ConsoleLoggerTest

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

Should make appveyor green again.

Commits
-------

de6799cb17 Fix ConsoleLoggerTest
2017-03-22 07:07:28 -07:00
Fabien Potencier
8aefa27ef8 minor #22104 [WebProfilerBundle] Remove uneeded directive in the form collector (romain-pierre)
This PR was submitted for the master branch but it was merged into the 2.8 branch instead (closes #22104).

Discussion
----------

[WebProfilerBundle] Remove uneeded directive in the form collector

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

Hi, as discussed with @javiereguiluz in #22102, it's better to completely remove this directive to avoid side effects on different Symfony versions. I can see an icon offset on 3.3. This directive was not "present" for so many time.. so...

Commits
-------

40a67c9e60 [WebProfilerBundle] Remove uneeded directive in the form collector styles
2017-03-22 07:05:53 -07:00
Romain
40a67c9e60 [WebProfilerBundle] Remove uneeded directive in the form collector styles 2017-03-22 07:05:52 -07:00
Robin Chalas
de6799cb17 Fix ConsoleLoggerTest 2017-03-22 13:19:17 +01:00
Christian Flothmann
daac6c2449 minor #22105 [Yaml] Fix error handling on ini file parsing (chalasr)
This PR was merged into the 3.3-dev branch.

Discussion
----------

[Yaml] Fix error handling on ini file parsing

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

Should make travis green again on master.
/cc @xabbuh

Commits
-------

71cec82 [Yaml] Fix error handling in parser
2017-03-22 12:03:03 +01:00
Robin Chalas
71cec8203f [Yaml] Fix error handling in parser 2017-03-22 11:47:48 +01:00
Nicolas Grekas
f0256f1aa5 [Yaml] Fix pcre.backtrack_limit reached 2017-03-22 09:30:29 +01:00
Fabien Potencier
3495b35e4f feature #21038 [FrameworkBundle] deprecated cache:clear with warmup (fabpot)
This PR was merged into the 3.3-dev branch.

Discussion
----------

[FrameworkBundle] deprecated cache:clear with warmup

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

The warmup part of `cache:clear` does not work well, and does not deliver the guarantee that the generated cache is exactly the same as the one that would have been generated via `cache:warmup`.

As one of the goal of Symfony 4 is to be able to generate all the cache for read-only filsystem, I propose to deprecate the warmup part of `cache:clear` in 3.3 to be able to remove it completely in 4.0. In 4.0, the `--no-warmup` option would be a noop (and can then be removed in 5.0).

Commits
-------

7ed3237645 [FrameworkBundle] deprecated cache:clear with warmup
2017-03-21 17:01:46 -07:00
Fabien Potencier
7d76227e06 removed usage of $that 2017-03-21 15:48:52 -07:00
Fabien Potencier
664740698e Merge branch '2.8' into 3.2
* 2.8:
  HttpCache: New test for revalidating responses with an expired TTL
  [Serializer] [XML] Ignore Process Instruction
2017-03-21 15:47:50 -07:00
Fabien Potencier
3b1143c47c Merge branch '2.7' into 2.8
* 2.7:
  HttpCache: New test for revalidating responses with an expired TTL
  [Serializer] [XML] Ignore Process Instruction
2017-03-21 15:47:17 -07:00
Fabien Potencier
f9b64a206b minor #22099 HttpCache: New test for revalidating responses with an expired TTL (mpdude)
This PR was squashed before being merged into the 2.7 branch (closes #22099).

Discussion
----------

HttpCache: New test for revalidating responses with an expired TTL

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

See #22035, in particular [this and the following comments](https://github.com/symfony/symfony/pull/22035#issuecomment-287572234).

Commits
-------

067ab52ba0 HttpCache: New test for revalidating responses with an expired TTL
2017-03-21 15:46:55 -07:00
Matthias Pigulla
067ab52ba0 HttpCache: New test for revalidating responses with an expired TTL 2017-03-21 15:46:50 -07:00
Fabien Potencier
bca4778ef1 bug #22044 [Serializer] [XML] Ignore Process Instruction (jordscream)
This PR was merged into the 2.7 branch.

Discussion
----------

[Serializer] [XML] Ignore Process Instruction

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

This Pull request ignores Process instruction data in XML for decoding the data.

Commits
-------

0c741f5704 [Serializer] [XML] Ignore Process Instruction
2017-03-21 15:20:34 -07:00
Fabien Potencier
7ed3237645 [FrameworkBundle] deprecated cache:clear with warmup 2017-03-21 15:16:20 -07:00
Jordan Samouh
0c741f5704 [Serializer] [XML] Ignore Process Instruction 2017-03-21 23:11:30 +01:00
Fabien Potencier
7f7b897ee2 feature #22098 [*Bundle] Add autowiring aliases for common services (nicolas-grekas)
This PR was merged into the 3.3-dev branch.

Discussion
----------

[*Bundle] Add autowiring aliases for common services

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

As spotted while working on #22060, we're missing many aliases to prevent any autowiring ambiguities.
I also removed the "Symfony\Component\EventDispatcher\EventDispatcher" and "Symfony\Component\DependencyInjection\Container" aliases: we'd better encourage using the corresponding interfaces instead.
On ControllerTrait, we need to type hint against SessionInterface, because otherwise, when session support is disabled, autowiring still auto-registers an "autowired.Session" service, which defeats the purpose of being able to enable/disable it.

Commits
-------

08c2ee32f1 [*Bundle] Add autowiring aliases for common services
2017-03-21 14:56:35 -07:00
Fabien Potencier
b0482963f1 Merge branch '3.2'
* 3.2:
  Fixes a typo in the form collector styles
  [WebProfilerBundle] Fix content-security-policy compatibility
  [WebProfilerBundle] Drop dead code
  [HttpKernel] Fixed bug with purging of HTTPS URLs
  fix some risky tests
  [DI] [YamlFileLoader] change error message of a non existing file
  [WebProfilerBundle] Handle Content-Security-Policy-Report-Only header correctly
  [Security] Added option to return true in the method isRememberMeRequested
2017-03-21 14:44:47 -07:00
Fabien Potencier
8cd835e658 Merge branch '2.8' into 3.2
* 2.8:
  Fixes a typo in the form collector styles
  [HttpKernel] Fixed bug with purging of HTTPS URLs
  fix some risky tests
  [DI] [YamlFileLoader] change error message of a non existing file
  [Security] Added option to return true in the method isRememberMeRequested
2017-03-21 14:44:32 -07:00
Fabien Potencier
295a8e0a82 Merge branch '2.7' into 2.8
* 2.7:
  [HttpKernel] Fixed bug with purging of HTTPS URLs
  fix some risky tests
  [DI] [YamlFileLoader] change error message of a non existing file
  [Security] Added option to return true in the method isRememberMeRequested
2017-03-21 14:39:01 -07:00
Fabien Potencier
65260bc346 minor #22066 fix some risky tests (xabbuh)
This PR was merged into the 2.7 branch.

Discussion
----------

fix some risky tests

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

PHPUnit 6 marks tests as risky when they have no assertions (and are not marked as skipped or incomplete). This PR will update our test suite accordingly.

Component that still need to be covered:

- [ ] Config
- [ ] Form
- [ ] HttpFoundation
- [ ] Security
- [ ] Workflow

Commits
-------

abf1787dcc fix some risky tests
2017-03-21 14:36:30 -07:00
Nicolas Grekas
08c2ee32f1 [*Bundle] Add autowiring aliases for common services 2017-03-21 22:34:27 +01:00
Fabien Potencier
4c0006a1dd feature #22095 [DI] Add logging and better failure recovery to AutowirePass (nicolas-grekas)
This PR was merged into the 3.3-dev branch.

Discussion
----------

[DI] Add logging and better failure recovery to AutowirePass

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

So useful to understand what autowiring is doing.

Commits
-------

3e297ba3e4 [DI] Add logging and better failure recovery to AutowirePass
2017-03-21 14:28:17 -07:00
Romain Pierre
b3f341fd90 Fixes a typo in the form collector styles 2017-03-21 14:21:32 -07:00
Fabien Potencier
819de0aa9b minor #22102 Fixes a typo in the form collector styles (romain-pierre)
This PR was merged into the 3.3-dev branch.

Discussion
----------

Fixes a typo in the form collector styles

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

Ping @javiereguiluz

Commits
-------

6e13a58e16 Fixes a typo in the form collector styles
2017-03-21 14:20:49 -07:00
Romain Pierre
6e13a58e16 Fixes a typo in the form collector styles 2017-03-21 22:03:13 +01:00
Nicolas Grekas
3e297ba3e4 [DI] Add logging and better failure recovery to AutowirePass 2017-03-21 19:30:57 +01:00
Fabien Potencier
a96a99723a feature #21889 Deprecate the special SYMFONY__ environment variables (javiereguiluz)
This PR was squashed before being merged into the 3.3-dev branch (closes #21889).

Discussion
----------

Deprecate the special SYMFONY__ environment variables

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

Commits
-------

e3362e854c Deprecate the special SYMFONY__ environment variables
2017-03-21 08:27:08 -07:00
Javier Eguiluz
e3362e854c Deprecate the special SYMFONY__ environment variables 2017-03-21 08:27:06 -07:00
Fabien Potencier
7f89ad41d7 minor #22094 [FrameworkBundle] Document removal of server:* commands (chalasr)
This PR was merged into the 3.3-dev branch.

Discussion
----------

[FrameworkBundle] Document removal of server:* commands

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #21373
| License       | MIT
| Doc PR        | n/a

To ease upgrading.

We could also add something like that in the framework application:
```php
public function findNamespace($namespace)
{
    try {
        return parent::findNamespace($namespace);
    } catch (CommandNotFoundException $e) {
        if ('server' === $namespace) {
            throw new CommandNotFoundException('The "server:start", "server:stop", "server:status" and "server:run" commands have been moved...');
        }
    }
}
```
But AFAIK we never did so in the past, tell me if we should.

Commits
-------

c99641a540 Document removal of server:* commands from the framework
2017-03-21 07:59:18 -07:00