- 04 Jul, 2013 7 commits
-
-
Fabien Potencier authored
-
Fabien Potencier authored
* 1.0: bumped version to 1.0.2-DEV prepared the 1.0.1 release updated CHANGELOG for 1.0 added a unit test for previous merge (refs #706) Fixed typo in the ServiceProviderInterface interface PHPDoc block. Add note on how to handle fatal errors, as per mailing list Alter app references in middleware doc Make DoctrineServiceProvider db connection lazy Workaround for OptionsResolver validating options add '_route' key to RedirectableUrlMatcher::redirect reflect change: Modularity chapter renamed to Organizing Controllers (#570) Add target branch notes Fixed namespace path Conflicts: doc/changelog.rst src/Silex/Application.php tests/Silex/Tests/Provider/ValidatorServiceProviderTest.php
-
Fabien Potencier authored
-
Fabien Potencier authored
-
Fabien Potencier authored
-
Fabien Potencier authored
-
Fabien Potencier authored
-
- 03 Jul, 2013 12 commits
-
-
Fabien Potencier authored
This PR was merged into the master branch. Discussion ---------- Introduced new symfony Debug component for error_handler cookbook Just fix the error_handler cookbook now use the Symfony Debug Component. Commits ------- 145b48a0 Introduced new symfony Debug component for error_handler cookbook
-
Fabien Potencier authored
-
Fabien Potencier authored
This PR was merged into the 1.0 branch. Discussion ---------- add '_route' key to RedirectableUrlMatcher::redirect When there is a logger, the Symfony\Compoment\HttpKernel\EventListener\RouterListener::onKernelRequest method expects the '_route' key to exist in order to log the matched route and issues a PHP Notice <?php date_default_timezone_set('America/Los_Angeles'); require_once __DIR__ . '/../vendor/autoload.php'; Symfony\Component\HttpKernel\Debug\ErrorHandler::register(); $app = new Silex\Application(); $app['debug'] = true; $app['monolog.logfile'] = 'C:/TEMP/log.log'; $app->register(new \Silex\Provider\MonologServiceProvider()); $app->get('/a/', function() { return 'done'; }); $app->run(); *[url]/a* issues the notice before redirecting to */a/* Commits ------- 3d1a868c add '_route' key to RedirectableUrlMatcher::redirect
-
Fabien Potencier authored
This PR was squashed before being merged into the master branch (closes #710). Discussion ---------- Added swiftmailers second argument for the send function within the SwiftmailerTrait Commits ------- 78115b47 Added swiftmailers second argument for the send function within the SwiftmailerTrait
-
NLZ13 authored
-
Barney Hanlon authored
Updated require-dev to have phpunit at a safe enough version, and updated the documentation to reflect the change. (closes #727)
-
Fabien Potencier authored
This PR was squashed before being merged into the master branch (closes #713). Discussion ---------- Added instructions for installing dev testing package As per [discussion about this requirement](https://groups.google.com/d/topic/silex-php/FfgPucE2Bu4/discussion). Commits ------- 862cf398 Added instructions for installing dev testing package
-
Tobias Sjösten authored
-
Fabien Potencier authored
This PR was squashed before being merged into the master branch (closes #741). Discussion ---------- Change the ControllerResolver type hint to Psr\\Log\\LoggerInterface This allows it to work with any logger, in particular, it un-breaks the case where the monolog bridge is not installed. See also 817240e4. This should resolve #740. Commits ------- b85d610d Change the ControllerResolver type hint to Psr\Log\LoggerInterface
-
Igor Wiedler authored
-
Fabien Potencier authored
This PR was merged into the 1.0 branch. Discussion ---------- Add note on how to handle fatal errors I'm not so happy with this solution from a usability perspective, but I don't want to have global error handlers in silex itself. An option we could consider is making symfony's ErrorHandler fall back to an internal ``ExceptionHandler`` for fatal errors. But obviously that is not very elegant either. Ideas welcome. Commits ------- 7a222ce5 Add note on how to handle fatal errors, as per mailing list
-
Fabien Potencier authored
This PR was merged into the master branch. Discussion ---------- Override the logger service by default Fixes #731 Been sat on this for a while, not been able to think of anything else that needs doing for it. Commits ------- 817240e4 Override the logger service by default
-
- 02 Jul, 2013 1 commit
-
-
Dave Marshall authored
-
- 30 Jun, 2013 1 commit
-
-
Fabien Potencier authored
This PR was merged into the 1.0 branch. Discussion ---------- Fixed typo in the ServiceProviderInterface interface PHPDoc block. Commits ------- 8bf3f788 Fixed typo in the ServiceProviderInterface interface PHPDoc block.
-
- 29 Jun, 2013 1 commit
-
-
Hugo Hamon authored
-
- 24 Jun, 2013 1 commit
-
-
Igor Wiedler authored
-
- 19 Jun, 2013 2 commits
-
-
Fabien Potencier authored
This PR was submitted for the master branch but it was merged into the 1.0 branch instead (closes #725). Discussion ---------- Alter app references in middleware doc I use ControllerProvider's and functions for my controllers, and I rely on the ````Application```` and ````Request```` being injected via the parameters of each function. Today I happened to need to build some middleware, but found that ````public function before(Application $app)```` resulted in a fatal as the middleware does not use type hinting to set parameters like controllers do. On digging a bit deeper I found in ````Silex\EventListener\MiddlewareListener.php::onKernelRequest```` the following line: ```` $ret = call_user_func($callback, $request, $this->app); ```` This injects application as the second parameter. I'm really happy that it does do this, but the parameter order seems a little strange to me. It's a bit at odds with the rest of the documentation on controllers - the general method prototype is ````method(Application $app, Request $request)````. Given this, I would have expected the app to come first in the parameter list. The same applies to the after callback, except it has ````Response```` between ````Request```` and ````Application````. The global middleware defined in ````Application```` do not inject the app in any of the callbacks, confusing the matter further. My pattern doesn't actually require this, but some people's might. Is there a reason this hasn't been done? It would be very simple to add, given the three methods are inside the ````Application```` class itself. The ideal fix to this would be that the middleware use type hinting to apply the parameters, but this is complicated by the callbacks occurring in two classes, neither of which are local to the existing type hinting code. At the very least I think this functionality should be documented, so this is what I have provided in the PR. Commits ------- ddc9b92 Alter app references in middleware doc
-
Tom Adam authored
-
- 06 Jun, 2013 4 commits
-
-
Fabien Potencier authored
This PR was squashed before being merged into the 1.0 branch (closes #722). Discussion ---------- Make DoctrineServiceProvider db connection lazy Specifically, do not create all connections early, only create them as needed. Commits ------- 9cf31e47 Make DoctrineServiceProvider db connection lazy
-
Igor Wiedler authored
-
Fabien Potencier authored
This PR was squashed before being merged into the 1.0 branch (closes #723). Discussion ---------- Workaround for OptionsResolver validating options Couldn't think of anyway to determine which version of the form component was being used, so went with the the suck it and see. Commits ------- 60338ac9 Workaround for OptionsResolver validating options
-
Dave Marshall authored
-
- 04 Jun, 2013 1 commit
-
-
Jérôme Macias authored
-
- 25 May, 2013 4 commits
-
-
Fabien Potencier authored
-
Fabien Potencier authored
This PR was submitted for the 1.0 branch but it was merged into the master branch instead (closes #705). Discussion ---------- Make dispatcher lazy, do not trigger its creation on middleware definition The dispatcher has quite a few dependencies due to all of the subscribers that are added to it. One of these is the logger, several other services are affected as well though. The listener shortcut methods like on(), before(), after(), error() all force creation of the dispatcher and thus all of its dependencies. This makes it impossible to have lazy configuration of those services. The specific issue that triggered this was lazy configuration of the logger, which simply does not work once you have before() or after(). By using extend(), all of those shortcut calls can delay the creation of the dispatcher and thus solve the issue. It will add a slight overhead, but it should be relatively small, since the results of creating a service are memoized through share(). Commits ------- efa0383 Add changelog entry for lazy dispatcher proxies 59b56b0 Make dispatcher lazy, do not trigger its creation on middleware definition
-
Igor Wiedler authored
-
Igor Wiedler authored
The dispatcher has quite a few dependencies due to all of the subscribers that are added to it. One of these is the logger, several other services are affected as well though. The listener shortcut methods like on(), before(), after(), error() all force creation of the dispatcher and thus all of its dependencies. This makes it impossible to have lazy configuration of those services. The specific issue that triggered this was lazy configuration of the logger, which simply does not work once you have before() or after(). By using extend(), all of those shortcut calls can delay the creation of the dispatcher and thus solve the issue. It will add a slight overhead, but it should be relatively small, since the results of creating a service are memoized through share().
-
- 16 May, 2013 1 commit
-
-
luisgonzalez authored
When there is a logger, the Symfony\Compoment\HttpKernel\EventListener\RouterListener class expects the '_route' key to exist in order to log the matched route and issues a PHP Notice
-
- 08 May, 2013 2 commits
-
-
Fabien Potencier authored
This PR was submitted for the master branch but it was merged into the 1.0 branch instead (closes #700). Discussion ---------- reflect change: Modularity chapter renamed to Organizing Controllers (#570) Commits ------- d051da3 reflect change: Modularity chapter renamed to Organizing Controllers (#570)
-
silverskater authored
-
- 07 May, 2013 2 commits
-
-
Fabien Potencier authored
This PR was squashed before being merged into the 1.0 branch (closes #699). Discussion ---------- Add target branch notes Consolidate the information recently added to the wiki, once merged, we could edit the wiki page to point towards the docs. Commits ------- b99a10e5 Add target branch notes
-
Dave Marshall authored
-
- 04 May, 2013 1 commit
-
-
Fabien Potencier authored
This PR was merged into the master branch. Discussion ---------- [1.1] Drop support for symfony/* <2.3 I've left the ranges in, because it's likely that we will extend them in the future. Commits ------- 54be4f51 [1.1] Remove symfony <2.3 hacks 2b45f600 [1.1] Add minimum-stability of dev 8f8ba416 [1.1] Update all symfony version references in the docs to 2.3 7a14b209 [1.1] Update symfony versions in fat composer.json e9478ddd Drop support for symfony/* <2.3
-