Commits
-------
b6bf018 tweaked error handling for the forward compatibility
dd606b5 added note about the purpose of this class
c1426ba added locale handling forward compatibility
10eed30 added MessageDataCollector forward compatibility
Discussion
----------
Forward compat
Bug fix: no
Feature addition: yes
Backwards compatibility break: no
Symfony2 tests pass: yes
Fixes the following tickets: #2522
Commits
-------
78e9b2f [Form] Fixed textarea_widget (W3C standards)
Discussion
----------
[Form] Fixed textarea_widget (W3C standards)
Textarea widget included the "pattern" attribute but is not valid by W3C standards.
(See PR 2666 - New PR because rebase inside the 2.0 branch)
---------------------------------------------------------------------------
by fabpot at 2011/11/18 09:01:41 -0800
@hlecorche: Thanks for your work on this issue. Can you update the unit tests to be sure that this case is covered? If you're not comfortable with this, just tell me and I will do it myself
---------------------------------------------------------------------------
by hlecorche at 2011/11/19 02:51:06 -0800
@fabpot: I did'nt commited because I am not sure. I changed the "tests/Symfony/Tests/Component/Form/AbstractLayoutTest.php" file :
public function testTextarea()
{
$form = $this->factory->createNamed('textarea', 'na&me', 'foo&bar', array(
'property_path' => 'name',
'pattern' => 'foo',
));
$this->assertWidgetMatchesXpath($form->createView(), array(),
'/textarea
[@name="na&me"]
[not(@pattern)]
[.="foo&bar"]
'
);
}
Is it correct?
Commits
-------
36cebf0 Fix infinite loop on circullar reference in form factory
Discussion
----------
[BugFix][Form]Throw exception on form name circulal ref
Bug fix: yes
Feature addition: no
Backwards compatibility break: no
Symfony2 tests pass: yes
Closes: #2673
When FormType method `getName()` returns the same value as `getParent()` we're asking about trouble, and land into infinite loop.
Commits
-------
57e1aeb Fixed undefined index notice in readProperty() method (PropertyPath)
Discussion
----------
Fixed undefined index notice in readProperty() method (PropertyPath)
Hi,
For some reasons, I get `notice` errors on `readProperty()` with Propel:
Notice: Undefined index: 0 in /Users/william/projects/Propel/testProjects/symfony2/vendor/symfony/src/Symfony/Component/Form/Util/PropertyPath.php line 284
The `PropelObjectCollection` implements `ArrayAccess`, the `readProperty()` method does not check if the given `index` exists so the `notice` error is thrown. I suppose to check whether the index exists or not has to be added.
Regards,
William
---------------------------------------------------------------------------
by fabpot at 2011/09/27 23:42:07 -0700
The patch is probably not what we want to do. First, I suppose that you are not creating the propertyPath by hand. If that is the case, we need to understand why the property path does not exist. Then, even if we might want to check the existence of the index, if it does not exist, we should probably throw an exception instead of just ignoring the problem.
---------------------------------------------------------------------------
by willdurand at 2011/09/28 01:14:49 -0700
My bad. This is a Propel bug due to `ArrayObject`. It throws a notice error if the index is not found in `offsetGet()` which is wrong according to the `ArrayAccess` interface. If the index is not found, we have to return `null`.
@fabpot Are you agree with that (for the `null` value) ?
---------------------------------------------------------------------------
by fabpot at 2011/09/28 01:17:09 -0700
My point is that it should never happen under normal circumstances.
---------------------------------------------------------------------------
by willdurand at 2011/09/28 01:23:55 -0700
@fabpot Not sure to get it.
The fact is that it tries to get the value (`getValue()`) of a fresh object, just added to the `collection` when I'm submitting a form with a `CollectionType` and a new entry in it.
I mean it tries to get this new object (not yet persisted, not yet in the collection) in the collection (`getValue()` -> `readProperty()`) which implements `ArrayAccess` but this object cannot be in the collection at this time.
Am I wrong ?
And, without this notice error thrown by Propel, I probably never opened this issue...
---------------------------------------------------------------------------
by willdurand at 2011/09/29 06:40:34 -0700
@fabpot: you can try this example: http://www.propelorm.org/cookbook/symfony2/mastering-symfony2-forms-with-propel.html#manytomany_relations in order to make your own tests. Will it be enough?
As I said, it throws a weird notice for the reasons above.
---------------------------------------------------------------------------
by jaugustin at 2011/10/04 12:58:10 -0700
any news on this ?
@fabpot did you have time to look at the test case ?
---------------------------------------------------------------------------
by cedriclombardot at 2011/11/09 14:29:42 -0800
@fabpot: can we have news about this ?
Commits
-------
79ae3fc [Form] fixed radio and checkbox when data is not bool
Discussion
----------
[Form] fixed checkbox view
The checkbox view was being built based on app data, not client data. This fixes it.
Bug fix: yes
Feature addition: no
Backwards compatibility break: no
Symfony2 tests pass: yes
Fixes the following tickets: -
Todo: -
---------------------------------------------------------------------------
by fabpot at 2011/11/16 13:31:09 -0800
`RadioType` suffers from the same problem, no?
---------------------------------------------------------------------------
by kriswallsmith at 2011/11/16 13:32:50 -0800
Yeah, I'll fix that too.
---------------------------------------------------------------------------
by kriswallsmith at 2011/11/16 13:43:29 -0800
Updated to include `RadioType`.
Commits
-------
86a8b9f Allow vendors checkout transport method to be overridden manually.
Discussion
----------
Allow vendors checkout transport method to be overridden manually.
In one particular environment I cannot checkout using vendors.php using the default http:// transport methods, but only git://
This patch gives complete freedom to override the default.
Side note: http:// as a transport method at github is deprecated as all http:// urls redirect to https://
My motivation for this patch is to allow continuous integration (previous phing patch closed which included this required change) since multiple regular checkouts to github via http protocol get blocked more but git based protocol transport don't. Without this, vendors.php may not always work and it's required to get the dependencies in order to be able to run the unit tests.
---------------------------------------------------------------------------
by stealth35 at 2011/11/15 06:14:32 -0800
If `http` is deprecated why you put this in default ?
---------------------------------------------------------------------------
by drak at 2011/11/15 06:26:17 -0800
Since the current list of checkouts is using `http`, I just left it. I try to keep topic branches laser focused so it's clear what the change was about. If you would like, I can change it because it actually makes sense. By the way, I double checked with `curl -I http://github.com/symfony/symfony.git` and the only response is a redirect to `https`.
---------------------------------------------------------------------------
by drak at 2011/11/15 18:40:16 -0800
Reopening on `master`.
---------------------------------------------------------------------------
by drak at 2011/11/15 21:32:09 -0800
Ok I've rebased this branch and force updated the branch so it's against 2.0 and has the changes discussed.
Commits
-------
4fbcc20 UPDATE.md: trivial markdown syntax fix
Discussion
----------
UPDATE.md: trivial markdown syntax fix
Sorry if this is so trivial it's annoying. I just fix 'em as I find 'em, and I keep commits small.
Commits
-------
8399574 Fixes a small php doc issue of Symfony\Component\Console\Command\Command::setDefinition()
Discussion
----------
Fixes a small php doc issue of Symfony\Component\Console\Command\Command::setDefinition()
Have setDefinition() accept InputDefinition instead of Definition.
Commits
-------
58c2276 Skipped tests when PDO is not available
Discussion
----------
Skipped tests when PDO is not available
Some tests are failing with an exception when PDO SQLite is not available. This skips them instead.
Commits
-------
f83ef1e [DoctrineBundle] Fix tests - incorrect class names (copy paste error most probably)
Discussion
----------
[DoctrineBundle] Fix tests - incorrect class names
Bug fix: yes
Feature addition: no
Backwards compatibility break: no
Symfony2 tests pass: yes
Fixes the following tickets: -
Some classes are incorrectly named resulting in failed tests for DoctrineBundle, looks like a copy paste error.
Commits
-------
470f872 [FrameworkBundle] fixed formatting of farsi translation file
Discussion
----------
[FrameworkBundle] fixed formatting of farsi translation file
It now matches the other languages translation files.
Commits
-------
67d91f0 fixed typo in exception message
Discussion
----------
Fixed typo in exception message
Fixed a small typo in the exception message which was added in d67fbe9e
Commits
-------
24dcd0f [DoctrineBundle] added missing default parameters, needed to setup and use DBAL without ORM
Discussion
----------
[DoctrineBundle] added missing default parameters for DBAL
Without this change, user can't use DBAL without ORM. When user configures only DBAL - he'll get:
[Symfony\Component\DependencyInjection\Exception\ParameterNotFoundException]
The service "doctrine" has a dependency on a non-existent parameter "doctrine.entity_managers".
Commits
-------
4858fbe [TwigBundle] Fix trace to not show 'in at line' when file/line are empty.
Discussion
----------
[TwigBundle] Fix trace to not show 'in at line' when file/line are empty.
Occasionally I saw call stacks where file/line are empty in the raw exception object, but the trace.html.twig file was still showing 'in at line' with empty values. I believe this fixes that.
Bug fix: yes
Feature addition: no
Backwards compatibility break: no
Symfony2 tests pass: yes
Fixes the following tickets: -
---------------------------------------------------------------------------
by fabpot at 2011/11/09 22:49:35 -0800
The current code looks correct to me. Can you try with the latest version of Twig to be sure that you don't have this issue because of a bug in Twig that has been fixed since then?
---------------------------------------------------------------------------
by dpb587 at 2011/11/10 07:20:34 -0800
Thanks for the feedback. Should I change my patch to check that both are defined and non-empty, such as `trace.file is defined and trace.file and trace.line is defined and trace.line`?
I think the issue is that I'm seeing the file and line keys are defined but empty. I created another branch with a pseudo-test case that shows a little more information. Using symfony-standard with symfony in deps as follows and symfony/twig removed from deps.lock.
[symfony]
git=git://github.com/dpb587/symfony.git
version=origin/patch-trace-debug
Then running the following:
phpunit -c app/ vendor/symfony/tests/Symfony/Tests/Bundle/TwigBundle/Controller/ExceptionController.php
The test (is backwards) and passes, dumping the following (this call happens right after a call_user_func):
Array
(
[namespace] => Symfony\Bundle\FrameworkBundle\EventListener
[short_class] => RouterListener
[class] => Symfony\Bundle\FrameworkBundle\EventListener\RouterListener
[type] => ->
[function] => onKernelRequest
[file] =>
[line] =>
[args] => Array
(
[0] => Array
(
[0] => object
[1] => Symfony\Component\HttpKernel\Event\GetResponseEvent
)
)
)
I saw the same results with two php versions:
PHP 5.3.3-7+squeeze3 with Suhosin-Patch (cli) (built: Jun 28 2011 08:24:40)
Copyright (c) 1997-2009 The PHP Group
Zend Engine v2.3.0, Copyright (c) 1998-2010 Zend Technologies
with Xdebug v2.1.1, Copyright (c) 2002-2011, by Derick Rethans
with Suhosin v0.9.32.1, Copyright (c) 2007-2010, by SektionEins GmbH
PHP 5.3.8 (cli) (built: Nov 4 2011 05:43:22)
Copyright (c) 1997-2011 The PHP Group
Zend Engine v2.3.0, Copyright (c) 1998-2011 Zend Technologies
with the ionCube PHP Loader v4.0.10, Copyright (c) 2002-2011, by ionCube Ltd., and
with Zend Guard Loader v3.3, Copyright (c) 1998-2010, by Zend Technologies
Sorry if I'm simply missing something or doing something silly.
---------------------------------------------------------------------------
by fabpot at 2011/11/11 13:12:21 -0800
`trace.file is defined and trace.file and trace.line is defined and trace.line` looks good to me.