Skip to content
Permalink
Branch: master
Commits on Mar 22, 2019
  1. feature #30448 [Finder] Ignore paths from .gitignore #26714 (amaabdou)

    fabpot committed Mar 22, 2019
    This PR was squashed before being merged into the 4.3-dev branch (closes #30448).
    
    Discussion
    ----------
    
     [Finder] Ignore paths from .gitignore #26714
    
    | Q             | A
    | ------------- | ---
    | Branch?       | master for features
    | Bug fix?      | no
    | New feature?  | yes
    | BC breaks?    | no
    | Deprecations? | no
    | Tests pass?   | yes
    | Fixed tickets | #26714
    | License       | MIT
    | Doc PR        | symfony/symfony-docs#... <!-- required for new features -->
    
    <!--
    Write a short README entry for your feature/bugfix here (replace this comment block.)
    This will help people understand your PR and can be used as a start of the Doc PR.
    Additionally:
     - Bug fixes must be submitted against the lowest branch where they apply
       (lowest branches are regularly merged to upper ones so they get the fixes too).
     - Features and deprecations must be submitted against the master branch.
    -->
    Implementation of feature request #26714
    
    Finder::ignoreVCS() is great at ignoring file patterns for the files created by popular VCS systems.
    
    However, it would be great to be able to instruct Finder to actually exclude the paths excluded by .gitignore.
    
    So if we have .gitignore:
    
    vendor/
    cache/
    
    Finder::create()
    	->files()
        ->ignoreVCS(true) // <--- Ignores `.git`
    	->ignoreVCSIgnored(true); // <--- Ignores vendor/ and cache/
    
    Commits
    -------
    
    9491393  [Finder] Ignore paths from .gitignore #26714
  2. [Finder] Ignore paths from .gitignore #26714

    amaabdou authored and fabpot committed Mar 5, 2019
  3. fixed CS

    fabpot committed Mar 22, 2019
Commits on Mar 21, 2019
  1. feature #30625 [HttpKernel] add RealHttpKernel: handle requests with …

    fabpot committed Mar 21, 2019
    …HttpClientInterface (fabpot)
    
    This PR was merged into the 4.3-dev branch.
    
    Discussion
    ----------
    
    [HttpKernel] add RealHttpKernel: handle requests with HttpClientInterface
    
    | Q             | A
    | ------------- | ---
    | Branch?       | master
    | Bug fix?      | no
    | New feature?  | yes
    | BC breaks?    | no
    | Deprecations? | no
    | Tests pass?   | yes
    | Fixed tickets | -
    | License       | MIT
    | Doc PR        | -
    
    This commit is directly extracted from #30602 by @fabpot
    
    Commits
    -------
    
    b579b02 [HttpKernel] add RealHttpKernel: handle requests with HttpClientInterface
  2. minor #30626 [HttpClient] improve MockResponse (nicolas-grekas)

    nicolas-grekas committed Mar 21, 2019
    This PR was merged into the 4.3-dev branch.
    
    Discussion
    ----------
    
    [HttpClient] improve MockResponse
    
    | Q             | A
    | ------------- | ---
    | Branch?       | master
    | Bug fix?      | no
    | New feature?  | no
    | BC breaks?    | no
    | Deprecations? | no
    | Tests pass?   | yes
    | Fixed tickets | -
    | License       | MIT
    | Doc PR        | -
    
    While working with `MockHttpClient`, we figured out these would be useful:
     - `MockResponse::getRequestOptions()` to get the options that were used when doing the request
    - relax the format of the `raw_headers` info and allow it to be defined as name=>value(s) pairs.
    
    Commits
    -------
    
    26f6e28 [HttpClient] improve MockResponse
  3. [HttpClient] improve MockResponse

    nicolas-grekas committed Mar 21, 2019
  4. [HttpKernel] add RealHttpKernel: handle requests with HttpClientInter…

    fabpot authored and nicolas-grekas committed Jan 30, 2019
    …face
Commits on Mar 20, 2019
  1. fixed encoder in Mime

    fabpot committed Mar 20, 2019
  2. feature #30508 [Routing] Exposed "utf8" option, defaults "locale" and…

    fabpot committed Mar 20, 2019
    … "format" in configuration (Jules Pietri)
    
    This PR was merged into the 4.3-dev branch.
    
    Discussion
    ----------
    
    [Routing] Exposed "utf8" option, defaults "locale" and "format" in configuration
    
    | Q             | A
    | ------------- | ---
    | Branch?       | master
    | Bug fix?      | no
    | New feature?  | yes
    | BC breaks?    | no
    | Deprecations? | no
    | Tests pass?   | yes
    | Fixed tickets | ~
    | License       | MIT
    | Doc PR        | symfony/symfony-docs#11126
    
    A sibling to #30501, everything is in the title :).
    
    Commits
    -------
    
    2911490 [Routing] Exposed "utf8" option, defaults "locale" and "format" in configuration
  3. [Routing] Exposed "utf8" option, defaults "locale" and "format" in co…

    Jules Pietri authored and HeahDude committed Mar 10, 2019
    …nfiguration
  4. feature #28920 [EventDispatcher] swap arguments of dispatch() to allo…

    fabpot committed Mar 20, 2019
    …w registering events by FQCN (nicolas-grekas)
    
    This PR was merged into the 4.3-dev branch.
    
    Discussion
    ----------
    
    [EventDispatcher] swap arguments of dispatch() to allow registering events by FQCN
    
    | Q             | A
    | ------------- | ---
    | Branch?       | master
    | Bug fix?      | no
    | New feature?  | yes
    | BC breaks?    | no
    | Deprecations? | yes
    | Tests pass?   | yes
    | Fixed tickets | -
    | License       | MIT
    | Doc PR        | -
    
    PR green and ready. From UPGRADE files:
    
     EventDispatcher
    ---------------
    
     * The signature of the `EventDispatcherInterface::dispatch()` method should be updated to `dispatch($event, string $eventName = null)`, not doing so is deprecated
    
    HttpKernel
    ----------
    
     * Renamed `FilterControllerArgumentsEvent` to `ControllerArgumentsEvent`
     * Renamed `FilterControllerEvent` to `ControllerEvent`
     * Renamed `FilterResponseEvent` to `ResponseEvent`
     * Renamed `GetResponseEvent` to `RequestEvent`
     * Renamed `GetResponseForControllerResultEvent` to `ViewEvent`
     * Renamed `GetResponseForExceptionEvent` to `ExceptionEvent`
     * Renamed `PostResponseEvent` to `TerminateEvent`
    
    Security
    ---------
    
     * The `ListenerInterface` is deprecated, turn your listeners into callables instead.
     * The `Firewall::handleRequest()` method is deprecated, use `Firewall::callListeners()` instead.
    
    Commits
    -------
    
    75369da [EventDispatcher] swap arguments of dispatch() to allow registering events by FQCN
  5. feature #30605 [Cache] added DSN support for rediss in AbstractAdapte…

    fabpot committed Mar 20, 2019
    …r and RedisTrait (alex-vasilchenko-md)
    
    This PR was squashed before being merged into the 4.3-dev branch (closes #30605).
    
    Discussion
    ----------
    
    [Cache] added DSN support for rediss in AbstractAdapter and RedisTrait
    
    | Q             | A
    | ------------- | ---
    | Branch?       | master
    | Bug fix?      | no
    | New feature?  | yes
    | BC breaks?    | no
    | Deprecations? | no
    | Tests pass?   | yes
    | Fixed tickets | #30573
    | License       | MIT
    
    A fix for this issue: #30573
    Support for "rediss:" in DSN added.
    
    Commits
    -------
    
    7e2852d [Cache] added DSN support for rediss in AbstractAdapter and RedisTrait
  6. minor #30611 throw TypeErrors to prepare for type hints in 5.0 (xabbuh)

    fabpot committed Mar 20, 2019
    This PR was merged into the 4.3-dev branch.
    
    Discussion
    ----------
    
    throw TypeErrors to prepare for type hints in 5.0
    
    | Q             | A
    | ------------- | ---
    | Branch?       | master
    | Bug fix?      | no
    | New feature?  | no
    | BC breaks?    | no
    | Deprecations? | no
    | Tests pass?   | yes
    | Fixed tickets |
    | License       | MIT
    | Doc PR        |
    
    Commits
    -------
    
    10afb99 throw TypeErrors to prepare for type hints in 5.0
  7. bug #30612 [FrameworkBundle] fix max host connections option for XML …

    fabpot committed Mar 20, 2019
    …configs (xabbuh)
    
    This PR was merged into the 4.3-dev branch.
    
    Discussion
    ----------
    
    [FrameworkBundle] fix max host connections option for XML configs
    
    | Q             | A
    | ------------- | ---
    | Branch?       | master
    | Bug fix?      | yes
    | New feature?  | no
    | BC breaks?    | no
    | Deprecations? | no
    | Tests pass?   | yes
    | Fixed tickets |
    | License       | MIT
    | Doc PR        |
    
    Commits
    -------
    
    3378f5e fix max host connections option for XML configs
Commits on Mar 19, 2019
  1. fix max host connections option for XML configs

    xabbuh committed Mar 19, 2019
  2. throw TypeErrors to prepare for type hints in 5.0

    xabbuh committed Mar 19, 2019
  3. feature #30604 [HttpClient] add MockHttpClient (nicolas-grekas)

    fabpot committed Mar 19, 2019
    This PR was merged into the 4.3-dev branch.
    
    Discussion
    ----------
    
    [HttpClient] add MockHttpClient
    
    | Q             | A
    | ------------- | ---
    | Branch?       | master
    | Bug fix?      | no
    | New feature?  | yes
    | BC breaks?    | no
    | Deprecations? | no
    | Tests pass?   | yes
    | Fixed tickets | -
    | License       | MIT
    | Doc PR        | -
    
    This PR introduces `MockHttpClient` and `MockResponse`, to be used for testing classes that need an HTTP client without making actual HTTP requests.
    
    `MockHttpClient` is configured via its constructor: you provide it either with an iterable or a callable, and these will be used to provide responses as the consumer requests them.
    
    Example:
    ```php
    $responses = [
        new MockResponse($body1, $info1),
        new MockResponse($body2, $info2),
    ];
    
    $client = new MockHttpClient($responses);
    $response1 = $client->request(...); // created from $responses[0]
    $response2 = $client->request(...); // created from $responses[1]
    ```
    
    Or alternatively:
    ```php
    $callback = function ($method, $url, $options) {
        return new MockResponse(...);
    };
    
    $client = new MockHttpClient($callback);
    $response = $client->request(...); // calls $callback internal
    ```
    
    The responses provided to the client don't have to be instances of `MockResponse` - any `ResponseInterface` works (e.g. `$this->getMockBuilder(ResponseInterface::class)->getMock()`).
    
    Using `MockResponse` allows simulating chunked responses and timeouts:
    ```php
    $body = function () {
        yield 'hello';
        yield ''; // the empty string is turned into a timeout so that they are easy to test
        yield 'world';
    };
    $mockResponse = new Mockresponse($body);
    ```
    
    Last but not least, the implementation simulates the full lifecycle of a properly behaving `HttpClientInterface` contracts implementation: error handling, progress function, etc. This is "proved" by `MockHttpClientTest`, who implements and passes the reference test suite in `HttpClientTestCase`.
    
    Commits
    -------
    
    8fd7584 [HttpClient] add MockHttpClient
  4. [HttpClient] add MockHttpClient

    nicolas-grekas committed Mar 19, 2019
  5. feature #21035 [FrameworkBundle] Deprecate the Templating component i…

    fabpot committed Mar 19, 2019
    …ntegration (dunglas, fabpot)
    
    This PR was merged into the 4.3-dev branch.
    
    Discussion
    ----------
    
    [FrameworkBundle] Deprecate the Templating component integration
    
    | 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
    
    This PR deprecates the Templating component integration in FrameworkBundle. Only a few people use it because almost everybody use Twig or the serializer to output data. Removing this component will facilitate the maintenance.
    
    Commits
    -------
    
    7169f4d [Templating] added more deprecation
    224c891 [FrameworkBundle] Deprecate the Templating component integration
  6. [Templating] added more deprecation

    fabpot committed Mar 19, 2019
  7. minor #30608 [TwigBundle] Simplify code (fabpot)

    fabpot committed Mar 19, 2019
    This PR was merged into the 4.3-dev branch.
    
    Discussion
    ----------
    
    [TwigBundle] Simplify code
    
    | Q             | A
    | ------------- | ---
    | Branch?       | master
    | Bug fix?      | no
    | New feature?  | no <!-- don't forget to update src/**/CHANGELOG.md files -->
    | BC breaks?    | no     <!-- see https://symfony.com/bc -->
    | Deprecations? | no <!-- don't forget to update UPGRADE-*.md and src/**/CHANGELOG.md files -->
    | Tests pass?   | yes    <!-- please add some, will be required by reviewers -->
    | Fixed tickets | n/a
    | License       | MIT
    | Doc PR        | n/a
    
    <!--
    Write a short README entry for your feature/bugfix here (replace this comment block.)
    This will help people understand your PR and can be used as a start of the Doc PR.
    Additionally:
     - Bug fixes must be submitted against the lowest branch where they apply
       (lowest branches are regularly merged to upper ones so they get the fixes too).
     - Features and deprecations must be submitted against the master branch.
    -->
    
    Commits
    -------
    
    4d6967e [TwigBundle] simplified code
  8. [TwigBundle] simplified code

    fabpot committed Mar 19, 2019
  9. feature #30567 [HttpClient] exceptions carry response (antonch1989)

    fabpot committed Mar 19, 2019
    This PR was squashed before being merged into the 4.3-dev branch (closes #30567).
    
    Discussion
    ----------
    
    [HttpClient] exceptions carry response
    
    | Q             | A
    | ------------- | ---
    | Branch?       | master
    | Bug fix?      | no
    | New feature?  | yes
    | BC breaks?    | no     <!-- see https://symfony.com/bc -->
    | Deprecations? | no
    | Tests pass?   | yes    <!-- please add some, will be required by reviewers -->
    | Fixed tickets | #30502
    | License       | MIT
    | Doc PR        |
    
    Commits
    -------
    
    103448c [HttpClient] exceptions carry response
  10. [HttpClient] exceptions carry response

    antonch1989 authored and fabpot committed Mar 14, 2019
  11. feature #28849 [Messenger] Support for handling messages after curren…

    sroze committed Mar 19, 2019
    …t bus is finished (Nyholm)
    
    This PR was merged into the 4.3-dev branch.
    
    Discussion
    ----------
    
    [Messenger] Support for handling messages after current bus is finished
    
    | Q             | A
    | ------------- | ---
    | Branch?       | master
    | Bug fix?      | no
    | New feature?  | yes
    | BC breaks?    | no
    | Deprecations? | no
    | Tests pass?   | yes
    | Fixed tickets |
    | License       | MIT
    | Doc PR        | symfony/symfony-docs#10015
    
    This is a replacement for #27844. We achieve the same goals without introducing the new concept of "recorder".
    
    ```php
    class CreateUserHandler
    {
        private $em;
        private $eventBus;
    
        public function __construct(MessageBus $eventBus, EntityManagerInterface $em)
        {
            $this->eventBus = $eventBus;
            $this->em = $em;
        }
    
        public function __invoke(CreateUser $command)
        {
            $user = new User($command->getUuid(), $command->getName(), $command->getEmail());
            $this->em->persist($user);
    
            $message = new UserCreatedEvent($command->getUuid();
            $this->eventBus->dispatch((new Envelope($message))->with(new DispatchAfterCurrentBus()));
        }
    }
    ```
    
    Note that this `DispatchAfterCurrentBusMiddleware` is added automatically as the first middleware.
    
    2019-03-13: I updated the PR description.
    
    Commits
    -------
    
    903355f Support for handling messages after current bus is finished
  12. fixed CHANGELOG

    fabpot committed Mar 19, 2019
  13. feature #29538 [Workflow] Add colors to workflow dumps (alexislefebvre)

    fabpot committed Mar 19, 2019
    This PR was squashed before being merged into the 4.3-dev branch (closes #29538).
    
    Discussion
    ----------
    
    [Workflow] Add colors to workflow dumps
    
    Fixes #28874
    
    | Q             | A
    | ------------- | ---
    | Branch?       | master
    | Bug fix?      | no
    | New feature?  | yes
    | BC breaks?    | no
    | Deprecations? | no
    | Tests pass?   | yes
    | Fixed tickets | #28874, replaces #28933
    | License       | MIT
    | Doc PR        | TODO, requires symfony/symfony-docs#9476
    
    Fetch data with the `MetadataStore` from #26092 in order to add colors to the dumps.
    
    Example of configuration:
    
    ```yaml
                transitions:
                    submit:
                        from: start
                        to: travis
                        metadata:
                            title: transition submit title
                            dump_style:
                                label: 'My custom label'
                                arrow_color: '#0088FF'
                                label_color: 'Red'
    ```
    
    This code was developed as a bundle, examples can be found on its repository: https://github.com/alexislefebvre/SymfonyWorkflowStyleBundle
    
    Commits
    -------
    
    60ad109 [Workflow] Add colors to workflow dumps
  14. [Workflow] Add colors to workflow dumps

    alexislefebvre authored and fabpot committed Dec 9, 2018
  15. Support for handling messages after current bus is finished

    Nyholm and ogizanagi committed Oct 13, 2018
    Co-authored-by: Maxime Steinhausser <ogizanagi@users.noreply.github.com>
Commits on Mar 18, 2019
  1. bug #30594 [HttpClient] changes minimal php version to use curl push …

    nicolas-grekas committed Mar 18, 2019
    …function (XuruDragon)
    
    This PR was merged into the 4.3-dev branch.
    
    Discussion
    ----------
    
    [HttpClient] changes minimal php version to use curl push function
    
    | 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       |
    
    Adding some changes to CurlHttpClient to avoid potential bugs in php < 7.2.17 or php < 7.3.4.
    For more information check these bugs :
    - https://bugs.php.net/bug.php?id=77747
    - https://bugs.php.net/bug.php?id=77535
    
    Resolve by the following commit by Nikic :
    - php/php-src@97f9fd6
    
    Commits
    -------
    
    01a663a [HttpClient] changes minimal php version to use curl push function
  2. feature #28975 [DI] Add an url EnvProcessor (jderusse)

    nicolas-grekas committed Mar 18, 2019
    This PR was merged into the 4.3-dev branch.
    
    Discussion
    ----------
    
    [DI] Add an url EnvProcessor
    
    | Q             | A
    | ------------- | ---
    | Branch?       | master
    | Bug fix?      | no
    | New feature?  | yes
    | BC breaks?    | no
    | Deprecations? | no
    | Tests pass?   | yes
    | Fixed tickets | -
    | License       | MIT
    | Doc PR        | symfony/symfony-docs#11128
    
    This PR add a new env processor `url` to convert an URL (or DSN) into an array.
    
    The main goal is to simplify the project configuration and reduce the number of env variable when working with bundle which are not able to deal with DSN
    (pick some random project in symfony/recipes-contrib: https://github.com/symfony/recipes-contrib/blob/master/facile-it/mongodb-bundle/0.6/manifest.json or https://github.com/symfony/recipes-contrib/blob/master/wouterj/eloquent-bundle/1.0/manifest.json)
    
    ```yaml
    # before
    MONGODB_HOST=localhost
    MONGODB_PORT=27017
    MONGODB_USER=
    MONGODB_PASSWORD=
    MONGODB_DB=symfony
    
    mongo_db_bundle:
        data_collection: '%kernel.debug%'
        clients:
            default:
                hosts:
                - { host: '%env(MONGODB_HOST)%', port: '%env(int:MONGODB_PORT)%' }
                username: '%env(MONGODB_USER)%'
                password: '%env(MONGODB_PASSWORD)%'
                connectTimeoutMS: 3000
        connections:
            default:
                database_name: '%env(MONGODB_DB)%'
    
    # after
    MONGODB_DSN=mongodb://localhost:27017/symfony
    
    mongo_db_bundle:
        data_collection: '%kernel.debug%'
        clients:
            default:
                hosts:
                - { host: '%env(key:host:url:MONGODB_DSN)%', port: '%env(key:port:url:MONGODB_DSN)%' }
                username: '%env(key:user:url:MONGODB_DSN)%'
                password: '%env(key:pass:url:MONGODB_DSN)%'
                connectTimeoutMS: 3000
        connections:
            default:
                database_name: '%env(key:path:url:MONGODB_DSN)%'
    ```
    
    Added also a `query_string` processor to parse query string
    
    ```
    DATABASE_DSN=mysql://localhost/db?charset=utf8
    
    foo:
      bar:
        charset: '%env(key:charset:query_string🔑query:url:DATABASE_DSN)%'
    ```
    
    Commits
    -------
    
    f253c9b Add an url EnvProcessor
Commits on Mar 17, 2019
  1. Add an url EnvProcessor

    jderusse committed Oct 25, 2018
Older
You can’t perform that action at this time.