Permalink
Commits on Feb 17, 2017
  1. bug #21639 [DI] Set getter edges as lazy (nicolas-grekas)

    This PR was merged into the 3.3-dev branch.
    
    Discussion
    ----------
    
    [DI] Set getter edges as lazy
    
    | Q             | A
    | ------------- | ---
    | Branch?       | master
    | Bug fix?      | yes
    | New feature?  | no
    | BC breaks?    | no
    | Deprecations? | no
    | Tests pass?   | yes
    | Fixed tickets | -
    | License       | MIT
    | Doc PR        | -
    
    Fixes tests
    
    Commits
    -------
    
    279f6a2 [DI] Set getter edges as lazy
    nicolas-grekas committed Feb 17, 2017
Commits on Feb 16, 2017
Commits on Feb 14, 2017
  1. Merge branch '3.2'

    * 3.2: (27 commits)
      Improve tracking of environment variables in the case of private services
      [DI] Align AutowirePass with 2.8
      property constraints can be added in child classes
      added test for staticClassLoader in LazyLoadingMetadatafactory
      fixed PHPUnit setUp and tearDown method visibility
      spelling fixes
      Readd Symfony version status in the toolbar
      [Security] LdapUserProvider should not throw an exception if the UID key does not exist in an LDAP entry
      make sure that null can be the invalid value
      [VarDumper] Improve dump of AMQP* Object
      Fix annotations cache folder path
      [FrameworkBundle] Wire ArrayCache for annotation reader at bootstrap
      Ignore missing 'debug.file_link_formatter' service in Debug bundle
      [VarDumper] Fixed dumping of terminated generator
      bumped Symfony version to 3.2.4
      updated VERSION for 3.2.3
      updated CHANGELOG for 3.2.3
      bumped Symfony version to 2.8.18
      updated VERSION for 2.8.17
      updated CHANGELOG for 2.8.17
      ...
    nicolas-grekas committed Feb 14, 2017
  2. Merge branch '2.8' into 3.2

    * 2.8:
      property constraints can be added in child classes
      added test for staticClassLoader in LazyLoadingMetadatafactory
      spelling fixes
      Readd Symfony version status in the toolbar
      make sure that null can be the invalid value
      [VarDumper] Improve dump of AMQP* Object
      [VarDumper] Fixed dumping of terminated generator
      bumped Symfony version to 2.8.18
      updated VERSION for 2.8.17
      updated CHANGELOG for 2.8.17
      bumped Symfony version to 2.7.25
      updated VERSION for 2.7.24
      update CONTRIBUTORS for 2.7.24
      updated CHANGELOG for 2.7.24
      [FrameworkBundle] Simplify createPackageDefinition
      fix directory resource considers same timestamp not fresh
      return false early from directory resource
    nicolas-grekas committed Feb 14, 2017
  3. Merge branch '2.7' into 2.8

    * 2.7:
      property constraints can be added in child classes
      added test for staticClassLoader in LazyLoadingMetadatafactory
      spelling fixes
      make sure that null can be the invalid value
      bumped Symfony version to 2.7.25
      updated VERSION for 2.7.24
      update CONTRIBUTORS for 2.7.24
      updated CHANGELOG for 2.7.24
      [FrameworkBundle] Simplify createPackageDefinition
      fix directory resource considers same timestamp not fresh
      return false early from directory resource
    nicolas-grekas committed Feb 14, 2017
  4. minor #21605 [DI] Align AutowirePass with 2.8 (nicolas-grekas)

    This PR was merged into the 3.2 branch.
    
    Discussion
    ----------
    
    [DI] Align AutowirePass with 2.8
    
    | Q             | A
    | ------------- | ---
    | Branch?       | 3.2
    | Bug fix?      | no
    | New feature?  | yes
    | BC breaks?    | no
    | Deprecations? | no
    | Tests pass?   | yes
    | Fixed tickets | -
    | License       | MIT
    | Doc PR        | -
    
    Follow up a less than ideal [merge conflict resolution](symfony/symfony#18691 (comment)), found while reviewing AutowirePass in 2.8 and 3.2 and wondering about the delta. Should reduce future merge conflicts and help history tracking.
    
    Commits
    -------
    
    dd5236a [DI] Align AutowirePass with 2.8
    nicolas-grekas committed Feb 14, 2017
Commits on Feb 13, 2017
Commits on Feb 12, 2017
Commits on Feb 10, 2017
  1. feature #21194 [Yaml] Add tags support (GuilhemN)

    This PR was squashed before being merged into the 3.3-dev branch (closes #21194).
    
    Discussion
    ----------
    
    [Yaml] Add tags support
    
    | Q             | A
    | ------------- | ---
    | Branch?       | master
    | Bug fix?      | no
    | New feature?  | yes
    | BC breaks?    | no
    | Deprecations? | yes
    | Tests pass?   | yes
    | Fixed tickets | symfony/symfony#21185
    | License       | MIT
    | Doc PR        |
    
    This PR adds custom tags support to the Yaml component.
    Symfony tags (`!!binary`, `!str`, etc.) are still managed in the parser to have a lighter diff but we'll be able to convert them later if we want to.
    
    The primary addition of this PR is the `TagInterface`:
    ```php
    interface TagInterface
    {
        public function construct(mixed $value): mixed;
    }
    ```
    
    It can be used to register custom tags. An example that could be used to convert [the syntax `=iterator`](symfony/symfony#20907 (comment)) to a tag:
    ```php
    final class IteratorTag implements TagInterface
    {
        public function construct(mixed $value): mixed
        {
            return new IteratorArgument($value);
        }
    }
    
    $parser = new Parser(['iterator' => new IteratorTag()]);
    ```
    
    If you think this is too complex, @nicolas-grekas [proposed an alternative](symfony/symfony#21185 (comment)) to my proposal externalizing this support by introducing a new class `TaggedValue`.
    
    Commits
    -------
    
    4744107 [Yaml] Add tags support
    nicolas-grekas committed Feb 10, 2017
Commits on Feb 9, 2017
Commits on Feb 8, 2017
Commits on Feb 7, 2017
Commits on Feb 2, 2017
  1. feature #21455 [DI] Allow to count on lazy collection arguments (ogiz…

    …anagi)
    
    This PR was merged into the 3.3-dev branch.
    
    Discussion
    ----------
    
    [DI] Allow to count on lazy collection arguments
    
    | Q             | A
    | ------------- | ---
    | Branch?       | master
    | Bug fix?      | no
    | New feature?  | yes
    | BC breaks?    | no
    | Deprecations? | no
    | Tests pass?   | yes
    | Fixed tickets | symfony/symfony#21450 (comment)
    | License       | MIT
    | Doc PR        | todo (with symfony/symfony-docs#7336)
    
    When using the new iterator feature of the DI component to lazy load collection, we always know the number of arguments in the collection (only the invalidBehavior set to `IGNORE_ON_INVALID_REFERENCE` may change this number). So we are able to generate and use a `RewindableGenerator` implementing `\Countable` by computing this value ahead.
    
    So, in a service accepting `array|iterable`, like in the `GuardAuthenticationListener` (see #21450):
    
    ```php
    class GuardAuthenticationListener implements ListenerInterface
    {
        private $guardAuthenticators;
    
        /**
           * @param iterable|GuardAuthenticatorInterface[]  $guardAuthenticators   The authenticators, with keys that match what's passed to GuardAuthenticationProvider
           * @param LoggerInterface                         $logger                A LoggerInterface instance
        */
        public function __construct($guardAuthenticators, LoggerInterface $logger = null)
        {
              // ...
        }
    
        public function handle(GetResponseEvent $event)
        {
            if (null !== $this->logger) {
                $context = array()
                if (is_array($this->guardAuthenticators) || $this->guardAuthenticators instanceof \Countable) {
                    $context['authenticators'] = count($this->guardAuthenticators);
                }
                $this->logger->debug('Checking for guard authentication credentials.', $context);
            }
            // ...
        }
    }
    ```
    
    we still keep the ability to call count without loosing the lazy load benefits.
    
    Commits
    -------
    
    f23e460 [DI] Allow to count on lazy collection arguments
    nicolas-grekas committed Feb 2, 2017
  2. bug #21508 [DI] : Fix bad generation of proxy class when use override…

    …n getter on class with constructor (jean-pasqualini)
    
    This PR was merged into the 3.3-dev branch.
    
    Discussion
    ----------
    
    [DI] : Fix bad generation of proxy class when use overriden getter on class with constructor
    
    [DI] : Fix bad generation of proxy class when use overriden getter on class with constructor
    
    | Q             | A
    | ------------- | ---
    | Branch?       | master
    | Bug fix?      | yes
    | New feature?  | no
    | BC breaks?    | no
    | Deprecations? | no
    | Tests pass?   | yes
    | Fixed tickets | #21507
    | License       | MIT
    
    - [X] Add test fail
    - [X] Fix bug
    - [X] Run test pass
    
    Commits
    -------
    
    2440b0f [DI] : Fix bad generation of proxy class when use overriden getter on class with constructor
    nicolas-grekas committed Feb 2, 2017
Commits on Feb 1, 2017