[DCOM-152] [GH-234] Criteria filtering doesn't work with DateTime instance Created: 17/Dec/12 Updated: 30/Apr/13 |
|
| Status: | Awaiting Feedback |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Benjamin Eberlei |
| Resolution: | Unresolved | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of ludekstepan: Url: https://github.com/doctrine/common/pull/234 Message: Filtering associations doesn't work with DateTime instance as a comparison value because filtering uses === operator. It works with SQL backed filtering, but not on PHP collection level. ```php |
[DCOM-9] Annotation mapper tries to parse PHPDocblock annotations Created: 16/Jun/10 Updated: 16/Jun/10 Resolved: 16/Jun/10 |
|
| Status: | Closed |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | 2.0.0-BETA2 |
| Fix Version/s: | 2.0.0-BETA3 |
| Type: | Bug | Priority: | Blocker |
| Reporter: | Antoine Hedgecock | Assignee: | Roman S. Borschel |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Environment: |
OS: Ubuntu, PHP version: 5.3.2 |
||
| Description |
|
In the upgrade from DC2 beta1 to beta2 the annonation mapper now starts to try and parse a some of the PHPDocblock annotations such as @package @subpackage but also the email adress in @author Example of docblock /** * @author Antoine Hedgecock <antoine@pmg.se> * @version 1.0.0 */ /** * @package Models * @subpackage Default * * @Entity(repositoryClass="Default_Model_Mapper_Category") * @Table(name="categories") * @InheritanceType("SINGLE_TABLE") * @DiscriminatorColumn(name="type", type="smallint") * @DiscriminatorMap({ * "0" = "Project_Model_Category" * }) */ will cause it to try and load
note pmg because its in the email of the author annotation |
| Comments |
| Comment by Roman S. Borschel [ 16/Jun/10 ] |
|
Please try with the latest version of Doctrine Common http://github.com/doctrine/common See also |
| Comment by Antoine Hedgecock [ 16/Jun/10 ] |
|
After comparing the source code version i found the following changes that could cause the issue Line 249 in Beta2 $this->lexer->lookahead != null && ! $this->lexer->isNextToken(Lexer::T_OPEN_PARENTHESIS) && ! ClassLoader::classExists($name) |
| Comment by Roman S. Borschel [ 16/Jun/10 ] |
|
Fixed in the beta3 release that is already out now. |
[DCOM-30] Documentation Bug regarding setAnnotationNamespaceAlias Created: 12/Nov/10 Updated: 15/Feb/11 Resolved: 15/Feb/11 |
|
| Status: | Closed |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Timo A. Hummel | Assignee: | Guilherme Blanco |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
In the documentation on http://www.doctrine-project.org/projects/common/2.0/docs/reference/annotations/en#setup-and-configuration:namespace-aliases I'm given the following example: $reader->setAnnotationNamespaceAlias('MyCompany\Annotations', 'my');
However, this only works here if I do it that way: $reader->setAnnotationNamespaceAlias('MyCompany\Annotations\\', 'my');
If the latter one is correct, it should be documented as such. |
| Comments |
| Comment by Guilherme Blanco [ 15/Feb/11 ] |
|
Already fixed in documentation. |
[DCOM-48] Autoloading with a namespace is very restricted Created: 08/Apr/11 Updated: 17/Jul/11 Resolved: 17/Jul/11 |
|
| Status: | Closed |
| Project: | Doctrine Common |
| Component/s: | Class Loading |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Improvement | Priority: | Major |
| Reporter: | Matthieu Napoli | Assignee: | Benjamin Eberlei |
| Resolution: | Invalid | Votes: | 0 |
| Labels: | None | ||
| Description |
|
Sorry for the vague title of the issue, but here is the problem: $classLoader = new ClassLoader('Tests', '/basePath/tests'); If I want to autoload \Tests\Class1, it will look for /basePath/tests/Tests/Class1.php. I would like it to load: /basePath/tests/Class1.php. i.e., the namespace registered is removed from the path. Do you see what I mean ? Zend Framework autoloader allow this behavior, I am surprised the Doctrine autoloader doesn't allow that. Thanks |
| Comments |
| Comment by Matthieu Napoli [ 29/Apr/11 ] |
|
Hi, any news on this ? I'd like to know if this is going to be corrected some day, or if I should not wait for it and find another solution ? Thank you |
| Comment by Guilherme Blanco [ 17/Jul/11 ] |
|
Hi, Zend Framework (v1) does not follow PSR-0 (http://groups.google.com/group/php-standards/web/psr-0-final-proposal) so it does whatever it wants. Let me explain what is the deal: Every single project, no matter what it is, can be contained in a package (aka. namespace in PHP). This means that: library - Controller.php - Controller/ - Action.php Is plain wrong. Why? Because it's part of a project (Your app (Application), Zend, Doctrine, Symfony, etc). Cheers, |
| Comment by Benjamin Eberlei [ 17/Jul/11 ] |
|
You can use any autoloader you want for your own classes, the Doctrine one is just focused on namespaces becuse Doctrine only uses namespaces. |
[DCOM-36] Declare annotation namespaces in the class' doc comment Created: 10/Feb/11 Updated: 15/Feb/11 Resolved: 15/Feb/11 |
|
| Status: | Closed |
| Project: | Doctrine Common |
| Component/s: | Annotations |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Improvement | Priority: | Major |
| Reporter: | Kris Wallsmith | Assignee: | Guilherme Blanco |
| Resolution: | Can't Fix | Votes: | 0 |
| Labels: | None | ||
| Description |
|
I would like to declare my default annotation namespace and namespace aliases in my class' doc comment. This will ensure my class can be understood by the annotation reader regardless of its configuration. An example of how I would use this: |
| Comments |
| Comment by Jonathan H. Wage [ 11/Feb/11 ] |
|
I don't think implementing this is possible in any easy way. |
| Comment by Guilherme Blanco [ 15/Feb/11 ] |
|
This cannot be done without adding a lot of WTF factor to Doctrine codebase. For individual docblocks there's a simple way, but it is impossible to make they interchange definitions (like declare namespace on class docblock and take advantage of it on method docblock). Marking it as can't fix, since our structure cannot support it without a complete rewrite (which would collide with our current interests). |
[DCOM-35] Change AnnotationReader cache salt Created: 01/Feb/11 Updated: 15/Feb/11 Resolved: 15/Feb/11 |
|
| Status: | Closed |
| Project: | Doctrine Common |
| Component/s: | Annotations |
| Affects Version/s: | 2.0.1 |
| Fix Version/s: | 2.0.2 |
| Type: | Bug | Priority: | Major |
| Reporter: | Guilherme Blanco | Assignee: | Guilherme Blanco |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
Our current AnnotationReader::$_CACHE_SALT conflicts with Symfony2 Console. The solution is to change the CACHE_SALT from: private static $CACHE_SALT = '@<Annot>'; To: private static $CACHE_SALT = '@[Annot]'; |
| Comments |
| Comment by Guilherme Blanco [ 15/Feb/11 ] |
|
Fixed |
[DCOM-34] calling setAutoloadAnnotationClasses on doctrine annotations reader causes fatal error Created: 08/Jan/11 Updated: 15/Feb/11 Resolved: 15/Feb/11 |
|
| Status: | Closed |
| Project: | Doctrine Common |
| Component/s: | Annotations |
| Affects Version/s: | 2.0.0 |
| Fix Version/s: | 2.0.2 |
| Type: | Bug | Priority: | Major |
| Reporter: | Hash Panak | Assignee: | Benjamin Eberlei |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Environment: |
Snow leopard, intel |
||
| Description |
|
When I try to set setAutoloadAnnotationClasses(true) gives me a fatal error, call to undefined method PHP Fatal error: Call to undefined method Doctrine\Common\Annotations\AnnotationReader::setAutoloadAnnotationClasses() |
| Comments |
| Comment by Guilherme Blanco [ 15/Feb/11 ] |
|
The correct method name is: setAutoloadAnnotations We need to fix the documentation of Common package. |
| Comment by Guilherme Blanco [ 15/Feb/11 ] |
|
Fixed |
[DCOM-72] Change CommonException to interface and use it everywhere! Created: 22/Oct/11 Updated: 21/Feb/13 Resolved: 21/Feb/13 |
|
| Status: | Closed |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | 2.3 |
| Type: | Improvement | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Benjamin Eberlei |
| Resolution: | Duplicate | Votes: | 0 |
| Labels: | None | ||
| Comments |
| Comment by Benjamin Eberlei [ 22/Oct/11 ] |
|
This is also necessary for everything else that accepts a class name, we should compile a list of the most important methods. |
| Comment by Marco Pivetta [ 21/Feb/13 ] |
|
See DCOM-80 |
[DCOM-133] [GH-212] Issue/gh #135 Created: 09/Nov/12 Updated: 09/Nov/12 Resolved: 09/Nov/12 |
|
| Status: | Closed |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Marco Pivetta |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of Ocramius: Url: https://github.com/doctrine/common/pull/212 Message: Fixes #135 |
| Comments |
| Comment by Benjamin Eberlei [ 09/Nov/12 ] |
|
A related Github Pull-Request [GH-212] was closed |
[DCOM-132] [GH-211] Cache interface fix Created: 01/Nov/12 Updated: 14/Jan/13 Resolved: 14/Jan/13 |
|
| Status: | Closed |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Benjamin Eberlei |
| Resolution: | Invalid | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of szicsu: Url: https://github.com/doctrine/common/pull/211 Message: The CacheProvider contained more public methods, |
| Comments |
| Comment by Benjamin Eberlei [ 09/Nov/12 ] |
|
A related Github Pull-Request [GH-211] was closed |
[DCOM-124] [GH-203] Added deleteByPregix, deleteBySuffix, deleteByRegex in CacheProvider Created: 16/Oct/12 Updated: 14/Jan/13 Resolved: 14/Jan/13 |
|
| Status: | Closed |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Benjamin Eberlei |
| Resolution: | Won't Fix | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of masarliev: Url: https://github.com/doctrine/common/pull/203 Message: I found that this feature is missing. |
[DCOM-120] [GH-197] Avoid a critical error when parsed class is not found Created: 03/Oct/12 Updated: 08/Oct/12 Resolved: 08/Oct/12 |
|
| Status: | Closed |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Benjamin Eberlei |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of alphalemon: Url: https://github.com/doctrine/common/pull/197 Message: Found a bug that returns a critical error when parsed class is not found. The new test explains exactly the situation found. This issue was found running this test suite: https://github.com/alphalemon/AlphaLemonCmsBundle, running the following test; phpunit Tests/Functional/Controller/SecuryControllerTest.php |
| Comments |
| Comment by Benjamin Eberlei [ 07/Oct/12 ] |
|
A related Github Pull-Request [GH-197] was closed |
[DCOM-119] [GH-196] Make getNamespacedId protected instead of private Created: 02/Oct/12 Updated: 14/Jan/13 Resolved: 14/Jan/13 |
|
| Status: | Closed |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Benjamin Eberlei |
| Resolution: | Invalid | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of jnonon: Url: https://github.com/doctrine/common/pull/196 Message: We want to extend the cache class provider MemcacheCache.php in order to set a custom namespace. However, because getNamespacedId is a private method, basically a complete rewrite and code duplication of the class is needed. --JN |
| Comments |
| Comment by Benjamin Eberlei [ 02/Oct/12 ] |
|
A related Github Pull-Request [GH-196] was closed |
[DCOM-117] [GH-194] If that $element exists give it back Created: 28/Sep/12 Updated: 14/Jan/13 Resolved: 14/Jan/13 |
|
| Status: | Closed |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Benjamin Eberlei |
| Resolution: | Invalid | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of seltzlab: Url: https://github.com/doctrine/common/pull/194 Message: I think it would very useful to get back the element that matched |
| Comments |
| Comment by Benjamin Eberlei [ 01/Oct/12 ] |
|
A related Github Pull-Request [GH-194] was closed |
[DCOM-114] [GH-190] Test new3 Created: 24/Sep/12 Updated: 14/Jan/13 Resolved: 14/Jan/13 |
|
| Status: | Closed |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Benjamin Eberlei |
| Resolution: | Invalid | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of beberlei: Url: https://github.com/doctrine/common/pull/190 Message: something master test? |
| Comments |
| Comment by Benjamin Eberlei [ 24/Sep/12 ] |
|
A related Github Pull-Request [GH-190] was closed |
| Comment by Benjamin Eberlei [ 24/Sep/12 ] |
|
A related Github Pull-Request [GH-190] was reopened |
| Comment by Benjamin Eberlei [ 24/Sep/12 ] |
|
A related Github Pull-Request [GH-190] was closed |
| Comment by Benjamin Eberlei [ 24/Sep/12 ] |
|
A related Github Pull-Request [GH-190] was reopened |
| Comment by Benjamin Eberlei [ 24/Sep/12 ] |
|
A related Github Pull-Request [GH-190] was closed |
| Comment by Benjamin Eberlei [ 24/Sep/12 ] |
|
A related Github Pull-Request [GH-190] was reopened |
| Comment by Benjamin Eberlei [ 24/Sep/12 ] |
|
A related Github Pull-Request [GH-190] was closed |
| Comment by Marco Pivetta [ 14/Jan/13 ] |
|
Was a test for the GH bot |
[DCOM-111] [GH-187] Test new3 Created: 24/Sep/12 Updated: 14/Jan/13 Resolved: 14/Jan/13 |
|
| Status: | Closed |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Benjamin Eberlei |
| Resolution: | Invalid | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of beberlei: Url: https://github.com/doctrine/common/pull/187 Message: test 3 |
| Comments |
| Comment by Benjamin Eberlei [ 24/Sep/12 ] |
|
A related Github Pull-Request [GH-187] was closed |
| Comment by Benjamin Eberlei [ 24/Sep/12 ] |
|
A related Github Pull-Request [GH-187] was reopened |
| Comment by Benjamin Eberlei [ 24/Sep/12 ] |
|
A related Github Pull-Request [GH-187] was closed |
| Comment by Marco Pivetta [ 14/Jan/13 ] |
|
Was a test for the GH bot |
[DCOM-109] [GH-185] Test new Created: 24/Sep/12 Updated: 14/Jan/13 Resolved: 14/Jan/13 |
|
| Status: | Closed |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Benjamin Eberlei |
| Resolution: | Invalid | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of beberlei: Url: https://github.com/doctrine/common/pull/185 Message: test |
| Comments |
| Comment by Benjamin Eberlei [ 24/Sep/12 ] |
|
A related Github Pull-Request [GH-185] was closed |
| Comment by Marco Pivetta [ 14/Jan/13 ] |
|
Was a test for the GH bot |
[DCOM-112] [GH-188] Test new3 Created: 24/Sep/12 Updated: 14/Jan/13 Resolved: 14/Jan/13 |
|
| Status: | Closed |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Benjamin Eberlei |
| Resolution: | Invalid | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of beberlei: Url: https://github.com/doctrine/common/pull/188 Message: trying against 2.3 |
| Comments |
| Comment by Benjamin Eberlei [ 24/Sep/12 ] |
|
A related Github Pull-Request [GH-188] was closed |
| Comment by Benjamin Eberlei [ 24/Sep/12 ] |
|
A related Github Pull-Request [GH-188] was reopened |
| Comment by Benjamin Eberlei [ 24/Sep/12 ] |
|
A related Github Pull-Request [GH-188] was closed |
| Comment by Benjamin Eberlei [ 24/Sep/12 ] |
|
A related Github Pull-Request [GH-188] was reopened |
| Comment by Benjamin Eberlei [ 24/Sep/12 ] |
|
A related Github Pull-Request [GH-188] was closed |
| Comment by Marco Pivetta [ 14/Jan/13 ] |
|
Was a test for the GH bot |
[DCOM-110] [GH-186] Test new2 Created: 24/Sep/12 Updated: 14/Jan/13 Resolved: 14/Jan/13 |
|
| Status: | Closed |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Benjamin Eberlei |
| Resolution: | Invalid | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of beberlei: Url: https://github.com/doctrine/common/pull/186 Message: new pull test |
| Comments |
| Comment by Benjamin Eberlei [ 24/Sep/12 ] |
|
A related Github Pull-Request [GH-186] was closed |
| Comment by Marco Pivetta [ 14/Jan/13 ] |
|
Was a test for the GH bot |
[DCOM-113] [GH-189] Test new3 Created: 24/Sep/12 Updated: 14/Jan/13 Resolved: 14/Jan/13 |
|
| Status: | Closed |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Benjamin Eberlei |
| Resolution: | Invalid | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of beberlei: Url: https://github.com/doctrine/common/pull/189 Message: last test i hope |
| Comments |
| Comment by Benjamin Eberlei [ 24/Sep/12 ] |
|
A related Github Pull-Request [GH-189] was closed |
| Comment by Marco Pivetta [ 14/Jan/13 ] |
|
Was a test for the GH bot |
[DCOM-107] [GH-183] Fix bug in classExists when using multiple autoloaders (i.e. ZF2) Created: 17/Sep/12 Updated: 14/Jan/13 Resolved: 14/Jan/13 |
|
| Status: | Closed |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Marco Pivetta |
| Resolution: | Duplicate | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of bramstroker: Url: https://github.com/doctrine/common/pull/183 Message: The autoloading routine in the classExists method makes the assumption the autoload method always returns a value (i.e. no void) when the autoloading of a class is succesfull. When you have multiple autoloaders registered to the spl stack this can lead to problems. In my case I'm using ZF2 ClassmapAutoloader and StandardAutoloader as fallback. The classmapAutoloader returns nothing so the autoload method in the StandardAutoloader is called as well, because the for loop is continued. This results in a second include, and a fatal error "Cannot redeclare class" is triggered. |
| Comments |
| Comment by Benjamin Eberlei [ 17/Sep/12 ] |
|
A related Github Pull-Request [GH-183] was closed |
| Comment by Marco Pivetta [ 14/Jan/13 ] |
|
Handled in |
[DCOM-108] [GH-184] Fix bug in classExists when using multiple autoloaders (i.e. ZF2) Created: 17/Sep/12 Updated: 14/Jan/13 Resolved: 14/Jan/13 |
|
| Status: | Closed |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Marco Pivetta |
| Resolution: | Duplicate | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of bramstroker: Url: https://github.com/doctrine/common/pull/184 Message: The autoloading routine in the classExists method makes the assumption the autoload method always returns a value (i.e. no void) when the autoloading of a class is succesfull. When you have multiple autoloaders registered to the spl stack this can lead to problems. In my case I'm using ZF2 ClassmapAutoloader and StandardAutoloader as fallback. The classmapAutoloader returns nothing so the autoload method in the StandardAutoloader is called as well, because the for loop is continued. This results in a second include, and a fatal error "Cannot redeclare class" is triggered. |
| Comments |
| Comment by Benjamin Eberlei [ 17/Sep/12 ] |
|
A related Github Pull-Request [GH-184] was closed |
| Comment by Benjamin Eberlei [ 18/Sep/12 ] |
|
A related Github Pull-Request [GH-184] was reopened |
| Comment by Marco Pivetta [ 14/Jan/13 ] |
|
Handled in |
[DCOM-105] Common base exception class Created: 27/Aug/12 Updated: 21/Feb/13 Resolved: 21/Feb/13 |
|
| Status: | Closed |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Improvement | Priority: | Major |
| Reporter: | Till | Assignee: | Marco Pivetta |
| Resolution: | Duplicate | Votes: | 0 |
| Labels: | None | ||
| Description |
|
Per our discussion on IRC/Twitter. It would be nice if all exceptions thrown had a common base, so something like this is possible to catch all exceptions from Doctrine: try { // some code here } catch (\Doctrine\Common\BaseException $e) { // something in Doctrine threw an exception, handle it here } (The name is just an example.) For reference: |
| Comments |
| Comment by Christophe Coevoet [ 27/Aug/12 ] |
|
Instead of a base class (which forbids extending the SPL exception), I would go the same way than Symfony2 and ZF: using an interface. |
| Comment by Till [ 27/Aug/12 ] |
|
That's basically what the PEAR2 RFC is doing. |
| Comment by Marco Pivetta [ 21/Feb/13 ] |
|
Duplicate of DCOM-80 |
[DCOM-97] phpParser.php and 'use' keyword in anonymous functions Created: 13/Feb/12 Updated: 30/Mar/12 Resolved: 30/Mar/12 |
|
| Status: | Closed |
| Project: | Doctrine Common |
| Component/s: | Annotations |
| Affects Version/s: | 2.1.4 |
| Fix Version/s: | 2.2 |
| Type: | Bug | Priority: | Major |
| Reporter: | Thomas Lecarpentier | Assignee: | Benjamin Eberlei |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Environment: |
php 5.3, Symfony2, linux |
||
| Description |
|
When i use the keyword 'use' in anonymous function (like describe in page http://php.net/manual/en/functions.anonymous.php) Exemple : /**
... The phpParser generate error [ErrorException] It try to parse 'use ($year, $month, $day)' as Class |
| Comments |
| Comment by Fabio B. Silva [ 25/Mar/12 ] |
|
I think this is fixed on the php parser rewrite. (2.2) |
| Comment by Fabio B. Silva [ 25/Mar/12 ] |
|
Coverage added : https://github.com/doctrine/common/commit/7ec510dbb2279f76a00ecf3f911298879c6ba1a1 I think this could be closed.. |
| Comment by Fabio B. Silva [ 30/Mar/12 ] |
|
Fixed on php parser rewrite. (2.2) |
[DCOM-86] k-fish Created: 09/Dec/11 Updated: 30/Dec/11 Resolved: 30/Dec/11 |
|
| Status: | Closed |
| Project: | Doctrine Common |
| Component/s: | Annotations |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Improvement | Priority: | Major |
| Reporter: | Karsten Dambekalns | Assignee: | Fabio B. Silva |
| Resolution: | Won't Fix | Votes: | 0 |
| Labels: | None | ||
| Description |
|
When parsing a class the DocParser uses class_exists() to check for annotation classes (this triggers autoloading) - only afterwards the annotation is ignored if it should be ignored. At least for simple unqualified names the check against the ignored annotations could be done earlier. This already goes a long way: ----- DocParser.php, at about line 555 ----- $alias = (false === $pos = strpos($name, ' ----- DocParser.php, at about line 555 ----- |
| Comments |
| Comment by Fabio B. Silva [ 30/Dec/11 ] |
|
Other explanations : https://github.com/doctrine/common/pull/90#issuecomment-3313175 |
[DCOM-99] Variable Support in DQL Created: 25/Apr/12 Updated: 14/Jan/13 Resolved: 14/Jan/13 |
|
| Status: | Closed |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | New Feature | Priority: | Major |
| Reporter: | Masoud Mazarei | Assignee: | Marco Pivetta |
| Resolution: | Invalid | Votes: | 0 |
| Labels: | None | ||
| Description |
|
sometimes in complex queries need to use variable, |
| Comments |
| Comment by Marco Pivetta [ 07/Jun/12 ] |
|
Could you please provide more information to this? Otherwise, this issue is quite invalid... |
[DCOM-174] [GH-255] Hotfix/dcom 173 tests Created: 18/Feb/13 Updated: 19/Feb/13 Resolved: 18/Feb/13 |
|
| Status: | Closed |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Marco Pivetta |
| Resolution: | Duplicate | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of Ocramius: Url: https://github.com/doctrine/common/pull/255 Message: This PR introduces tests to avoid epic fails such as #254 and #253 |
| Comments |
| Comment by Marco Pivetta [ 18/Feb/13 ] |
|
Handled in |
| Comment by Benjamin Eberlei [ 19/Feb/13 ] |
|
A related Github Pull-Request [GH-255] was closed |
[DCOM-156] [GH-238] fix to solve fatal error: apc_exist() does not exist Created: 04/Jan/13 Updated: 10/Jan/13 Resolved: 10/Jan/13 |
|
| Status: | Closed |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Benjamin Eberlei |
| Resolution: | Won't Fix | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of uran1980: Url: https://github.com/doctrine/common/pull/238 Message: Hi, folks. I'm running *Zend Server CE 5.6.0 5.6.0 SP4* with *PHP Version 5.3.14* and APC builtin: Now when I run in my project based on Symfony 2.1.6 comand:  *Possible solution are in my pull request.* As I descovered I am not alone with this problem: http://stackoverflow.com/questions/9125904/apc-exist-does-not-exist(http://stackoverflow.com/questions/9125904/apc-exist-does-not-exist) |
| Comments |
| Comment by Benjamin Eberlei [ 10/Jan/13 ] |
|
A related Github Pull-Request [GH-238] was closed |
| Comment by Marco Pivetta [ 10/Jan/13 ] |
|
This issue affects older versions of APC. If a fix is needed, a legacy APC cache class shall be implemented. |
[DCOM-150] [GH-232] [DocParser] Don't check class exists if annotation name is ignored Created: 10/Dec/12 Updated: 14/Jan/13 Resolved: 14/Jan/13 |
|
| Status: | Closed |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Benjamin Eberlei |
| Resolution: | Duplicate | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of Stroitel: Url: https://github.com/doctrine/common/pull/232 Message: DocParser checks for the exist of all the annotation names even if they are ignored. Maybe this is feature , but i don't sure. |
| Comments |
| Comment by Benjamin Eberlei [ 10/Dec/12 ] |
|
A related Github Pull-Request [GH-232] was closed |
| Comment by Marco Pivetta [ 14/Jan/13 ] |
|
Superseded by DCOM-151 |
[DCOM-137] [GH-218] hotfix cache Created: 16/Nov/12 Updated: 14/Jan/13 Resolved: 14/Jan/13 |
|
| Status: | Closed |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Benjamin Eberlei |
| Resolution: | Duplicate | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of jakoch: Url: https://github.com/doctrine/common/pull/218 Message: a) replaced silence operator by is_file() check. |
| Comments |
| Comment by Benjamin Eberlei [ 16/Nov/12 ] |
|
A related Github Pull-Request [GH-218] was closed |
| Comment by Marco Pivetta [ 14/Jan/13 ] |
[DCOM-139] [GH-220] replaced silence operator by is_file() check Created: 16/Nov/12 Updated: 21/Feb/13 Resolved: 21/Feb/13 |
|
| Status: | Closed |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Benjamin Eberlei |
| Resolution: | Invalid | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of jakoch: Url: https://github.com/doctrine/common/pull/220 Message: |
[DCOM-135] [GH-214] [WIP] [Cache] Move cache ID namespacing to CacheNamespace class Created: 12/Nov/12 Updated: 21/Feb/13 Resolved: 21/Feb/13 |
|
| Status: | Closed |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Benjamin Eberlei |
| Resolution: | Incomplete | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of CHH: Url: https://github.com/doctrine/common/pull/214 Message: |
[DCOM-134] [GH-213] Added sort option for array collection Created: 11/Nov/12 Updated: 14/Jan/13 Resolved: 14/Jan/13 |
|
| Status: | Closed |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Benjamin Eberlei |
| Resolution: | Won't Fix | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of andrewtarry: Url: https://github.com/doctrine/common/pull/213 Message: I have added a sorter class and sortBy method for the ArrayCollection class. It gives the option to reorder the ArrayCollection after someone has gotten it from the database, e.g. from a relationship. It takes an array of method names to sort by in order to priority and it takes an optional boolean to set the order to ascending. Here is an example: `$arraycollection->sortBy(array('getName()', 'getAddress()'));` It will recursively loop the collection change the order. Each time it will look to see if the previous matching option is the same as for the previous element and then store those elements in list to be reordered. Once it has looped all the elements it will reorder the elements it has matched and if there is another option to reorder by it will loop only the elements it matched last time so it is not looping the whole array each time. |
| Comments |
| Comment by Marco Pivetta [ 14/Jan/13 ] |
|
Can't change because of BC, and the performance impact is too high |
[DCOM-4] Cannot use namespace separator and namespace alias at the same time for annotations Created: 09/May/10 Updated: 24/May/10 Resolved: 24/May/10 |
|
| Status: | Closed |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | 2.0.0-BETA2 |
| Type: | Improvement | Priority: | Major |
| Reporter: | Tim Nagel | Assignee: | Roman S. Borschel |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
In the function Annotation() in \Doctrine\Common\Annotations\Parser.php (~line 225) There is a check for how many $nameParts there are, and the doctrine code will only append the namespace aliases if there are no namespace separators. There is also an argument against modification since the user of the code could just define more namespace aliases, but I feel that it should be able to cope with a namespace alias and a namespace separator at the same time. |
| Comments |
| Comment by Benjamin Eberlei [ 09/May/10 ] |
|
From our discussion on IRC, the problems here are:
|
| Comment by Tim Nagel [ 24/May/10 ] |
|
Proposed solution to the namespace separators: http://github.com/merk/common/commit/b31166c6a85235e03935a4b41f5a54aa478f6c6b I am unsure about throwing exception messages or doing anything too fancy in this area since there will be instances where other annotations are used for other purposes (phpdoc, etc) where you only want to ignore them. |
[DCOM-2] Annotation and autoloading Created: 20/Apr/10 Updated: 14/Jun/10 Resolved: 14/Jun/10 |
|
| Status: | Closed |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | 2.0.0-BETA3 |
| Type: | Improvement | Priority: | Major |
| Reporter: | Kirill chEbba Chebunin | Assignee: | Roman S. Borschel |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
The problem is that we need to load all annnotation classes before we read annotations from the target class. The reason of this, is a fix of bug #77 Solutions: May be there are some another, better solutions. |
| Comments |
| Comment by Roman S. Borschel [ 22/Apr/10 ] |
|
The class_exists check can maybe be removed altogether since is_subclass_of is no longer used. |
| Comment by Tim Nagel [ 24/May/10 ] |
|
Would removing the second parameter to class_exists solve the problem sufficiently? I would thing you would have to leave the class_exists check in, otherwise it will try to parse annotations that do not resolve to class names? |
| Comment by Tim Nagel [ 27/May/10 ] |
|
Changed: http://github.com/merk/common/commit/152fdecf11b7999262df0410b5584951de5191b3 |
| Comment by Roman S. Borschel [ 27/May/10 ] |
|
The fundamental problem with class_exists($blub) (which is the same as class_exists($blub, true) is that it basically requires a class loader / autoloader that fails silently when a class file does not exist, which means it must use costly file_exists checks before loading any class. The Doctrine\Common\ClassLoader does (on purpose) not check for file existance. If the class loader is responsible for a particular class and it is requested to load it, failing to do so is (and should be) a fatal error. We consider the fact that two responsibilities are mixed here, a) (auto)loading a class file and b) checking for the existance of a class (file), to be a design flaw in class_exists / autoloading. It means that you are required to check for file existance in a class loader and fail silently if the file does not exist which is completely unnecessary in 99% of the cases. Compare how many times class_exists(..., true) is usually used in a single request and how many classes, in total, are usually loaded per request. So just for the case that some code might use an occasional class_exists(..., true) check you have to check each single file for existance before loading it (and you must fail silently, it might be a class_exists check!). Even more, in a case where you really only want to check for class (file) existance, but you dont actually want to load it, you can't! class_exists(..., true) when the class file exists results in loading the class file, even if its completely unnecessary. We are planning to come up with a better approach that separates the 2 concerns. This is related to |
| Comment by Roman S. Borschel [ 27/May/10 ] |
|
The recommended approach for annotations by the way, (recommended by me), is to load them manually via a require call. The ORM does exactly this. If you rely on class_exists(..., true) and silently failing autoloaders, this becomes costly considering how often class_exists would be invoked while parsing annotations. |
[DCOM-22] Cache should support an array of options. Created: 19/Aug/10 Updated: 30/Aug/10 Resolved: 30/Aug/10 |
|
| Status: | Closed |
| Project: | Doctrine Common |
| Component/s: | Caching |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Improvement | Priority: | Major |
| Reporter: | Guilherme Blanco | Assignee: | Guilherme Blanco |
| Resolution: | Won't Fix | Votes: | 0 |
| Labels: | None | ||
| Description |
|
Currently the overall code to instantiate Cache drivers cannot be generic. The first one is simply a no argument instantiation. The second, even after isntantiation, it still requires you to call a method (->setMemcache) in order to work. Please consider these sample codes: A suggested approach could be a CacheManager as a fatory. Anyway, this should be fixed VERY soon. |
| Comments |
| Comment by Roman S. Borschel [ 21/Aug/10 ] |
|
After our discussion yesterday, can we close this? |
| Comment by Guilherme Blanco [ 30/Aug/10 ] |
|
As discussed, we won't fix this. |
[DCOM-16] Doctrine\Cache\Cache\AbstractCache::deleteByPrefix() vs. cache namespace Created: 05/Aug/10 Updated: 31/Aug/10 Resolved: 31/Aug/10 |
|
| Status: | Closed |
| Project: | Doctrine Common |
| Component/s: | Caching |
| Affects Version/s: | 2.0.0-BETA2, 2.0.0-BETA3, 2.0.0-BETA4 |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | xlite | Assignee: | Roman S. Borschel |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Environment: |
PHP 5.3.0 + memcache + xdebug; FreeBSD 6.4-RELEASE-p |
||
| Description |
|
The methods deleteByPrefix() / deleteByRegExp() / deleteBySuffix() are based on the method getIds(), which returns unique identifiers with an added namespace in the front. That is why to be able to delete cells using these three methods, you have to know the namespace. $cacheDriver->setNamespace('ns'); In this example the cell will not be deleted. |
| Comments |
| Comment by Guilherme Blanco [ 31/Aug/10 ] |
|
In commit: http://github.com/doctrine/common/commit/a2238b871c13cf0e195fa18f0b8744e38baabf48 Thanks for reporting that! |
[DCOM-14] Exclude @throws annotation from parsing. Created: 21/Jul/10 Updated: 31/Aug/10 Resolved: 31/Aug/10 |
|
| Status: | Closed |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Jan Obrátil | Assignee: | Roman S. Borschel |
| Resolution: | Cannot Reproduce | Votes: | 0 |
| Labels: | None | ||
| Environment: |
Ubuntu Linux 10.04 LTS Server, standard lamp instalation from repositories |
||
| Description |
|
CLI doctrine tool fails when parsing entity sources (for example: doctrine orm:validate-schema) by following error: This error appears when @HasLifecycleCallbacks annotation is added into entity. The solution is adding "@throws" annotation into strippedTags into Doctrine/Common/Annotations/Parser.php |
| Comments |
| Comment by Roman S. Borschel [ 26/Aug/10 ] |
|
Can you confirm that this is still a problem with the latest code? |
| Comment by Jan Obrátil [ 27/Aug/10 ] |
|
I'm using the latest Doctrine2 available thru pear: Installed packages, channel pear.doctrine-project.org: I still have to alter Parser.php |
| Comment by Guilherme Blanco [ 31/Aug/10 ] |
|
This ticket is invalid. I added coverage to it on commit: http://github.com/doctrine/common/commit/7e7a06e9878a1a41a72a062fa18d71d6c64a600a Seems you have a @throws definition that is connected to the returned class, and this is then considered an annotation. |
[DCOM-10] The annotation parser isn't EBNF compliant Created: 04/Jul/10 Updated: 16/Feb/11 Resolved: 16/Feb/11 |
|
| Status: | Closed |
| Project: | Doctrine Common |
| Component/s: | Annotations |
| Affects Version/s: | 2.0.0-BETA4 |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Bernhard Schussek | Assignee: | Guilherme Blanco |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Environment: |
PHP 5.3.2, Linux Ubuntu 10.04 |
||
| Description |
|
The EBNF allows passing multiple comma-separated annotations to an annotation: Annotation ::= "@" AnnotationName ["(" [Values] ")"] Values ::= Array | Value {"," Value}* Value ::= PlainValue | FieldAssignment PlainValue ::= integer | string | float | boolean | Array | Annotation Therefore the following should be possible. /** @Name(@Foo, @Bar) */ This results in an error though. IMO, /** @Name(@Foo, @Bar) */ should be equivalent to /** @Name({@Foo, @Bar}) */
just like /** @Name(foo = "foo", bar = "bar") */ is equivalent to /** @Name({foo = "foo", bar = "bar"}) */
|
| Comments |
| Comment by Bernhard Schussek [ 04/Jul/10 ] |
|
Fixed in http://github.com/bschussek/doctrine-common/tree/DCOM-10 |
| Comment by Bernhard Schussek [ 04/Jul/10 ] |
|
As I've just noticed, the statement that /** @Name(foo = "foo", bar = "bar") */ equals /** @Name({foo = "foo", bar = "bar"}) */
is wrong. The first does field assignments, the second stores the array in the "value" field. Nevertheless, either Doctrine's implementation (as per my commit) or the EBNF have to be updated. |
| Comment by Guilherme Blanco [ 15/Feb/11 ] |
|
Your branch added another vulnerability, so I cannot merge. The problem appears when you do this: @Name(@Foo, {bar="bar"})
What would you expect on this situation? I'd imagine this: array(
0 => object<Foo>,
1 => array(
'bar' => 'bar'
)
)
But with your patch, the actual result is: array(
0 => object<Foo>,
'bar' => 'bar'
)
There's a way to fix it by changing how FieldAssignment returns. Instead of returning an array, it should return return an stdClass. I'll assign this issue to me, so I can work on it to be EBNF compatible. Too bad it took so many time for us to look at it. =( |
| Comment by Bernhard Schussek [ 16/Feb/11 ] |
|
Yes, I'd expect the first result. Thanks for looking into this, I completely forgot about this issue. |
| Comment by Guilherme Blanco [ 16/Feb/11 ] |
|
This issue was fixed in: https://github.com/doctrine/common/commit/4210fbd8b261c000c793461c4f815b4d43bcc362 Thanks a lot for the bug report. |
[DCOM-8] Annotation Parser tries to Load Classes that don't exist Created: 14/Jun/10 Updated: 14/Jun/10 Resolved: 14/Jun/10 |
|
| Status: | Closed |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | 2.0.0-BETA2 |
| Fix Version/s: | 2.0.0-BETA3 |
| Type: | Bug | Priority: | Major |
| Reporter: | Marc Neuhaus | Assignee: | Roman S. Borschel |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Attachments: |
|
| Description |
|
If i add the Annotation Tag @ignore to my model the Parser tries to load the Mapping class for that property. Since this class doesn't exist it fails with a fatal error. I attached the stripped down Entity with the @ignore annotation, the Error Text and a Possible Solution Greetings Marc |
| Comments |
| Comment by Roman S. Borschel [ 14/Jun/10 ] |
|
Fixed in http://github.com/doctrine/common/commit/f34d581f646b3d9b5f06c6c081ac3e568d8496ff |
[DCOM-176] [GH-256] Refactored AnnotationDriver to handle only required classes Created: 01/Mar/13 Updated: 01/Mar/13 Resolved: 01/Mar/13 |
|
| Status: | Closed |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Marco Pivetta |
| Resolution: | Invalid | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of mattcockayne: Url: https://github.com/doctrine/common/pull/256 Message: Whilst debugging an issue I was having I found that the AnnotationDriver uses get_declared_classes() and iterates over the result to identify classes that should be handled. This seems like a ridiculous overhead especially as it then instantiated a ReflectionClass for each declared class. As an example my current project was iterating over 522 items when it needed to only handle 6. I've kept the alterations to a minimum but it now takes a snapshot of the declared classes before and after the require for the files and then uses array_diff to get only the classes we are targeting. |
| Comments |
| Comment by Marco Pivetta [ 01/Mar/13 ] |
|
Patch breaks logic when files where already included |
| Comment by Benjamin Eberlei [ 01/Mar/13 ] |
|
A related Github Pull-Request [GH-256] was closed |
[DCOM-177] [GH-257] Add an prefix to ApcCache Created: 03/Mar/13 Updated: 03/Mar/13 Resolved: 03/Mar/13 |
|
| Status: | Closed |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Marco Pivetta |
| Resolution: | Invalid | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of NoUseFreak: Url: https://github.com/doctrine/common/pull/257 Message: In shared hosting I ran into cache-collision. This gives users the option to avoid this problem. |
| Comments |
| Comment by Benjamin Eberlei [ 03/Mar/13 ] |
|
A related Github Pull-Request [GH-257] was closed |
[DCOM-178] [GH-258] Add an prefix to ApcCache Created: 03/Mar/13 Updated: 03/Mar/13 Resolved: 03/Mar/13 |
|
| Status: | Closed |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Marco Pivetta |
| Resolution: | Invalid | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of NoUseFreak: Url: https://github.com/doctrine/common/pull/258 Message: In shared hosting I ran into cache-collision. This gives users the option to avoid this problem. |
| Comments |
| Comment by Benjamin Eberlei [ 03/Mar/13 ] |
|
A related Github Pull-Request [GH-258] was closed |
[DCOM-196] [GH-278] [DCOM-194] Fixed proxying magic getter with reference Created: 06/Jun/13 Updated: 10/Jun/13 Resolved: 10/Jun/13 |
|
| Status: | Closed |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Doctrine Bot | Assignee: | Marco Pivetta |
| Resolution: | Duplicate | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of Majkl578: Url: https://github.com/doctrine/common/pull/278 Message: This is a proposal for a fix for |
| Comments |
| Comment by Doctrine Bot [ 10/Jun/13 ] |
|
A related Github Pull-Request [GH-278] was closed: |
| Comment by Marco Pivetta [ 10/Jun/13 ] |
|
Duplicate of |
[DCOM-198] [GH-281] DCOM-194 Created: 10/Jun/13 Updated: 10/Jun/13 Resolved: 10/Jun/13 |
|
| Status: | Closed |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Doctrine Bot | Assignee: | Marco Pivetta |
| Resolution: | Duplicate | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of Ocramius: Url: https://github.com/doctrine/common/pull/281 Message: Cleaned up version of #278 |
| Comments |
| Comment by Marco Pivetta [ 10/Jun/13 ] |
|
Duplicate of |
| Comment by Doctrine Bot [ 10/Jun/13 ] |
|
A related Github Pull-Request [GH-281] was closed: |
[DCOM-24] Documentation about Default Namespace has error. Created: 25/Sep/10 Updated: 15/Feb/11 Resolved: 15/Feb/11 |
|
| Status: | Closed |
| Project: | Doctrine Common |
| Component/s: | Annotations |
| Affects Version/s: | 2.0.0-RC1 |
| Fix Version/s: | None |
| Type: | Task | Priority: | Minor |
| Reporter: | Margus Sipria | Assignee: | Guilherme Blanco |
| Resolution: | Invalid | Votes: | 0 |
| Labels: | None | ||
| Description |
|
$reader->setDefaultAnnotationNamespace('Doctrine\Common\Annotations'); I used above code to test annotations without namespaces just to find out that there there is missing \ (or 2 if you count escaping) at the end of that string. This works: $reader->setDefaultAnnotationNamespace('Doctrine\\Common\\Annotations reference guide where I found error is here: http://www.doctrine-project.org/projects/common/2.0/docs/reference/annotations/en#setup-and-configuration:default-namespace |
| Comments |
| Comment by Guilherme Blanco [ 15/Feb/11 ] |
|
Already fixed on documentation. |
[DCOM-7] Slight Refactor of ClassLoader Created: 06/May/10 Updated: 13/Jun/10 Resolved: 13/Jun/10 |
|
| Status: | Closed |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | 2.0.0-BETA2 |
| Type: | Improvement | Priority: | Minor |
| Reporter: | Michael Ridgway | Assignee: | Roman S. Borschel |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Attachments: |
|
| Description |
|
This is a rather trivial issue: I'd like to add a function to the Common\ClassLoader called getClassPath($className) or something named similarly so that we are able to find where an autoloader will look for the specified class. The autoloader doesn't check for file existence normally (as it shouldn't) but there are cases where the developer does need to make sure that the file exists before a class is attempted to be loaded. I've attached a patch for the changes that I'm proposing. |
| Comments |
| Comment by Roman S. Borschel [ 06/May/10 ] |
|
We have another idea for these issues (basically for the issue of using class_exists(..., true) and your new method may even complement this nicely. I will let you know what I mean here soon. |
| Comment by Roman S. Borschel [ 13/Jun/10 ] |
|
There is now ClassLoader#classExists as well as ClassLoader#getClassLoader available. |
[DCOM-42] Sort in ArrayCollection Created: 22/Mar/11 Updated: 17/Jul/11 Resolved: 17/Jul/11 |
|
| Status: | Closed |
| Project: | Doctrine Common |
| Component/s: | Collections |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Improvement | Priority: | Trivial |
| Reporter: | Thomas Lundquist | Assignee: | Benjamin Eberlei |
| Resolution: | Won't Fix | Votes: | 0 |
| Labels: | None | ||
| Description |
|
Needed a sort function in ArrayCollection, made it. Simple but works for me at least. Pull request: https://github.com/doctrine/common/pull/12 |
| Comments |
| Comment by Guilherme Blanco [ 17/Jul/11 ] |
|
As per github comment. |
[DCOM-61] Class annotation is not setting annotation properties Created: 18/Aug/11 Updated: 25/Aug/11 Resolved: 25/Aug/11 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | Annotations |
| Affects Version/s: | 2.1 |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Blocker |
| Reporter: | James Reed | Assignee: | Benjamin Eberlei |
| Resolution: | Invalid | Votes: | 0 |
| Labels: | None | ||
| Environment: |
Windows 7 64-bit, PHP v5.3.1 |
||
| Description |
|
My annotations were working fine with v2.0.5. Once I upgraded to v2.1 they stopped working. Using this condensed code based on the v2.1 documentation on Annotations (http://www.doctrine-project.org/docs/common/2.1/en/reference/annotations.html): require 'c:/dev/library/doctrine-orm/Doctrine/Common/ClassLoader.php'; $classLoader = new \Doctrine\Common\ClassLoader('Doctrine', 'c:/dev/library/doctrine-orm'); $classLoader->register(); $classLoader = new \Doctrine\Common\ClassLoader('Symfony', 'c:/dev/library/doctrine-orm/Doctrine'); $classLoader->register(); $reader = new \Doctrine\Common\Annotations\AnnotationReader(); $reader->setIgnoreNotImportedAnnotations(true); $reader->setEnableParsePhpImports(false); $className = 'User'; $reflectionClass = new \ReflectionClass($className); $classAnnotations = $reader->getClassAnnotations($reflectionClass); echo "Class Annotations - $className:\n"; print_r($classAnnotations); /** * @Annotation */ class Foo { public $bar; } /** * @Foo(bar="foo") */ class User { } The result is: Class Annotations - User: Array ( [0] => Foo Object ( [bar] => ) ) Why is bar empty? If I remove the @Foo annotation from the docblock for the User class, then the result is an empty array. So it's clearly detecting the annotation, it's just not setting the annotation property. |
| Comments |
| Comment by James Reed [ 25/Aug/11 ] |
|
This is blocking me from upgrading to v2.1 |
| Comment by James Reed [ 25/Aug/11 ] |
|
Got the same result with v2.0.6. Must be something I'm missing here. |
[DCOM-84] Improve Proxy Naming Created: 01/Dec/11 Updated: 13/Dec/11 Resolved: 12/Dec/11 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | 2.2 |
| Type: | Improvement | Priority: | Blocker |
| Reporter: | Johannes Schmitt | Assignee: | Benjamin Eberlei |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
see https://gist.github.com/b493493ecdb22c21590e |
| Comments |
| Comment by Benjamin Eberlei [ 12/Dec/11 ] |
|
Implemented in https://github.com/doctrine/common/pull/83 |
| Comment by Benjamin Eberlei [ 13/Dec/11 ] |
|
This issue is referenced in Github Pull-Request GH-83 |
[DCOM-173] Add test assets and tests for proxy generators Created: 18/Feb/13 Updated: 21/Feb/13 Due: 18/Feb/13 Resolved: 21/Feb/13 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | 2.4 |
| Fix Version/s: | 2.4 |
| Type: | Bug | Priority: | Blocker |
| Reporter: | Marco Pivetta | Assignee: | Marco Pivetta |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
Need to add tests assets to check __isset __get __set, etc. Currently only code generation for proxies inheriting __sleep is tested. |
| Comments |
| Comment by Marco Pivetta [ 18/Feb/13 ] |
| Comment by Marco Pivetta [ 21/Feb/13 ] |
|
Merged |
[DCOM-27] Method Next from ArrayCollection needs to return something! Created: 11/Oct/10 Updated: 31/Oct/10 Resolved: 31/Oct/10 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | Collections |
| Affects Version/s: | 2.0.0-RC1 |
| Fix Version/s: | 2.0.0-RC2 |
| Type: | Bug | Priority: | Critical |
| Reporter: | Henrique Girardi dos Santos | Assignee: | Benjamin Eberlei |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
I think this method needs to return something... /**
doctrine-common/lib/Doctrine/Common/Collections/ArrayCollection.php |
| Comments |
| Comment by Benjamin Eberlei [ 31/Oct/10 ] |
|
resolved |
[DCOM-25] method setAutoloadAnnotationClasses-fails Created: 25/Sep/10 Updated: 31/Oct/10 Resolved: 31/Oct/10 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | Annotations |
| Affects Version/s: | 2.0.0-RC1 |
| Fix Version/s: | 2.0.0-RC2 |
| Type: | Bug | Priority: | Critical |
| Reporter: | Margus Sipria | Assignee: | Benjamin Eberlei |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
$reader = new Doctrine\Common\Annotations\AnnotationReader(); above code is trying use default parser's setAutoloadAnnotationClasses-method, which isn't found, instead parser has setAutoloadAnnotations. |
| Comments |
| Comment by Benjamin Eberlei [ 31/Oct/10 ] |
|
fixed. |
[DCOM-69] [APC Cache] doFlush does not clear user cache Created: 27/Sep/11 Updated: 03/Oct/11 Resolved: 03/Oct/11 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | Caching |
| Affects Version/s: | 2.2 |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Critical |
| Reporter: | Jérôme Forêt | Assignee: | Guilherme Blanco |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
lib\Doctrine\Common\Cache\ApcCache.php The function "doFlush" only clears opcode cache. To correct it, one solution should be : protected function doFlush() { $res = false; $bool1 = apc_clear_cache(); $bool2 = apc_clear_cache('user'); if ($bool1 && $bool2) { $res = true; } return $res; } |
| Comments |
| Comment by Guilherme Blanco [ 03/Oct/11 ] |
|
Fixed in https://github.com/doctrine/common/commit/d6e4c8b22af9800db4fd9d679ce98538da028168 |
[DCOM-194] Creating Proxy class failure for own __get method Created: 22/May/13 Updated: 10/Jun/13 Resolved: 10/Jun/13 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | 2.4 |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Critical |
| Reporter: | Jan Pecek | Assignee: | Marco Pivetta |
| Resolution: | Fixed | Votes: | 1 |
| Labels: | proxy | ||
| Environment: |
using Nette framework ( http://nette.org ), PHP 5.4 |
||
| Description |
|
Nette framework (http://nette.org) has got own Nette\Object as a base of other objects. It also rewrite the default __get method in PHP object but it uses definition with pointer:
public function &__get($name)
Doctrine Common creates Proxy classes with __get method too but not with reference. It causes an error using strict warning:
Declaration of Proxy\__CG__\MyEntityObject::__get() should be compatible with & Nette\Object::__get($name)
The problem is in ProxyGenerator. Locally I've patched it in my Doctrine repository clone but don't know how to resolve it globally. |
| Comments |
| Comment by Marco Pivetta [ 22/May/13 ] |
|
https://github.com/doctrine/common/blob/2.4.0-RC2/lib/Doctrine/Common/Proxy/ProxyGenerator.php#L386-L403 could be patched to verify if the method is byref/byval. |
| Comment by Christophe Coevoet [ 03/Jun/13 ] |
|
This should probably be checked for all proxied methods, not only for magic ones |
| Comment by Marco Pivetta [ 03/Jun/13 ] |
|
Christophe Coevoet I think I already check proxied methods, but didn't apply that logic for magic methods. edit: indeed, there's a test for that: https://github.com/doctrine/common/blob/2.4.0-RC3/tests/Doctrine/Tests/Common/Proxy/LazyLoadableObject.php#L101-L106 |
| Comment by Michael Moravec [ 06/Jun/13 ] |
|
Hello, I've patched ProxyGenerator::generateMagicGet method to support reference, see Github PR #278. |
| Comment by Jan Pecek [ 06/Jun/13 ] |
|
Michael Moravec: Yes, this is ok. Now, proxy classes are generated well. |
| Comment by Marco Pivetta [ 10/Jun/13 ] |
|
Cleaned and re-submitted at https://github.com/doctrine/common/pull/281 Please review and then I'll merge. |
| Comment by Marco Pivetta [ 10/Jun/13 ] |
|
Merged at https://github.com/doctrine/common/commit/d658ec7a03f6475eff0dd1eb940bdedd862e4b96 |
[DCOM-31] setAutoloadAnnotationClasses() within AnnotationReader fails Created: 12/Nov/10 Updated: 15/Nov/10 Resolved: 15/Nov/10 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | 2.0.0-RC2 |
| Type: | Bug | Priority: | Major |
| Reporter: | Timo A. Hummel | Assignee: | Benjamin Eberlei |
| Resolution: | Duplicate | Votes: | 0 |
| Labels: | None | ||
| Description |
|
When calling setAutoloadAnnotationClasses() from within AnnotationReader, it fails because setAutoloadAnnotationClasses() is not implemented in Doctrine\Common\Annotations\Parser. This should be fixed, or at least a FeatureNotImplementedException or such. |
| Comments |
| Comment by Benjamin Eberlei [ 15/Nov/10 ] |
|
Duplicate of |
[DCOM-57] Doctrine\Common\Cache\AbstractCache::deleteAll() does not take the namespace into account Created: 14/Jul/11 Updated: 08/Sep/11 Resolved: 27/Aug/11 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | Caching |
| Affects Version/s: | 2.1 |
| Fix Version/s: | 2.1.2 |
| Type: | Bug | Priority: | Major |
| Reporter: | Eric Durand-Tremblay | Assignee: | Guilherme Blanco |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Environment: |
Memcached |
||
| Description |
|
The deleteAll() function delete all keys with no respect of the namespace. Using orm:clear-cache:metadata with memcache result in the deletion of all memcache keys. (including keys unrelated to the orm) |
| Comments |
| Comment by Eric Durand-Tremblay [ 14/Jul/11 ] |
|
See pull request : https://github.com/doctrine/common/pull/46 I think the best way to fix this problem is to check for the namespace in the getIds() function. Unfortunately, that would break the interface of AbstractCache Split the function in getIds() and abstract _getIds(). Do the namespace check in getIds() I can do pull request on github if necessary. NOTE |
| Comment by Guilherme Blanco [ 27/Aug/11 ] |
|
Fixed in master since this commit: https://github.com/doctrine/common/commit/486169851ea87b3e14ed45d5bfd7d07b1d41af65 |
| Comment by Benjamin Eberlei [ 08/Sep/11 ] |
|
Merged into 2.1.x for next release |
[DCOM-56] Remote autoloading from annotations completly, replacing it with its own loading mechanism Created: 01/Jul/11 Updated: 02/Jul/11 Resolved: 02/Jul/11 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | Annotations |
| Affects Version/s: | 2.1 |
| Fix Version/s: | 2.1 |
| Type: | Improvement | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Benjamin Eberlei |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This is a mail from me to the symfony-dev mailing-list: I am sorry it is very late to bring this up again, but given the nasty problems I faced today with the way annotationreader works with autoload = true I have to share them (and blow of some steam). While i guess its to late to change this again before 2.0, we might still have to discuss to go away from autoload = true for 2.1. Now for the reasons: AnnotationReader with autoload = true (which Symfony2 uses) will not only require a silent autoloader, it requires ALL autoloaders used to be silent. While this is the case for the Symfony Universal loader its not the case for the Doctrine one, and not for many others - and its not even a PSR-0 requirement. For a simple reason: Supporting silent failure means using file_exists, means a file stat, which means apc.stat = 0 is useless. While I don't care so much about it in Doctrine context, because the AnnotationReader default is NOT to autoload annotations this will cause problems for Symfony: Not every library in any Symfony2 app will be included through a silent autoloader. That means given the context users might run into problems using annotations that they have absolutely no way of fixing. And since the AnnotationReader does not know this upfront, potential failures become very real issue. Example: I use SecurityExtraBundle and happen to have my SuperDuperLibrary XYZ. That library was developed by my company and contains tons of important business logic but unfortunately uses a non-silent autoloader (for whatever reasons). However i use Symfony to secure access to it by generating secure proxies. Now what happens if an annotation reader runs over that library? Because the current namespace is always considered, for every @var _NAMESPACE." All this trouble we are getting into with autoloading annotations is just because we wanted to validate that the annotations used actually exist. But since we changed to a use/import approach rather then re-using namespaces we don't even have the clashing problem anymore that got us into the trouble with class_exists before. The autoloading however also got us and users into other problems: 1. We have to maintain a rather large map of "blacklisted" annotations that never throw failure exceptions because they are actually used as doc documentations. As with blacklists this is never a complete list. While I do think it would have been nice to offer validation for annotation this is a task that should be put on IDEs and developers, since it turns out that its not possible flawlessly within the library itself. The AnnotationReader should always use class_exists($name, false). Docblocks are still comments and the code shouldn't fail because classes are not available that are not even relevant in the context of the current AnnotationReader. Each part of the code that uses an AnnotationReader should require_once the annotations that it can potentially need upfront. That even works for Validation as you can grab the tags from the DIC. That way we have a single mode of operation for the AnnotationReader and not two different ones that are 180 degrees different. OF course one could argue ALWAYS to use class_exists($name, true) instead, but i hope my mail showed why this is not a good idea. If for some reason we do want autoloading for annotations then it should be a mechanism different from the PHP one, because they are both not compatible. The reader could have hooks for autoloading and validation mechanisms. Nothing we want to add for Doctrine Common 2.1, but something we could easily play around with for Common 3. Next a mail with implementation details: I propose to change the following on AnnotationReader: 1. Add a method to register annotation classes: This way for symfony only the UniversalClassLoader data has to be used |
| Comments |
| Comment by Benjamin Eberlei [ 02/Jul/11 ] |
|
Implemented |
[DCOM-55] Ugly problems with default import __NAMESPACE__ when it contains non-annotation classes that are docblock props Created: 29/Jun/11 Updated: 29/Jun/11 Resolved: 29/Jun/11 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | 2.1 |
| Fix Version/s: | 2.1 |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Benjamin Eberlei |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
Say you have a class "Entity". Then /** @Entity */ on a class in the same namespace will try to instantiate Entity. We should avoid this by testing if Entity is a subclass of \Doctrine\Common\Annotations\Annotation |
| Comments |
| Comment by Benjamin Eberlei [ 29/Jun/11 ] |
|
Actually this problem is more problematic, we have to enforce extending \Doctrine\Common\Annotations\Annotation for ALL annotations. |
| Comment by Benjamin Eberlei [ 29/Jun/11 ] |
|
Fixed. |
[DCOM-54] ClassLoader protected properties Created: 14/Jun/11 Updated: 17/Jul/11 Resolved: 17/Jul/11 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | Class Loading |
| Affects Version/s: | None |
| Fix Version/s: | 2.1.1 |
| Type: | Improvement | Priority: | Major |
| Reporter: | Jon Johnson | Assignee: | Benjamin Eberlei |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Environment: |
na |
||
| Description |
|
It would be great if the members of ClassLoader($fileExtension, $namespace, $includePath, $namespaceSeparator) where protected instead of private. In order to work around |
| Comments |
| Comment by Guilherme Blanco [ 17/Jul/11 ] |
|
Fixed in https://github.com/doctrine/common/commit/c614a20e02cb8fd5531bce1adcb34a1210f79ac6 |
[DCOM-53] PhpParser doesn't ignore commented keywords Created: 24/May/11 Updated: 04/Sep/11 Resolved: 04/Sep/11 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Michel D'HOOGE | Assignee: | Benjamin Eberlei |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Environment: |
PhpParser class provided with Symfony2 BETA 2 |
||
| Description |
|
The PhpParser makes a too optimistic assumption about code convention... If you have the word 'class' or 'interface' in the comment before the class definition, preg_match_all finds wrong slice of code and PHP complains with a Warning about "Unterminated comment". This occurs only once after the cache is cleared. |
| Comments |
| Comment by Fabio B. Silva [ 03/Sep/11 ] |
|
Hello all After rewriting the php parser does not happen. : https://github.com/doctrine/common/commit/d274bd7fe9e8f5657c670ed8a22a31024544eeeb I think that can be closed Thanks |
| Comment by Michel D'HOOGE [ 04/Sep/11 ] |
|
Unfortunately, I can't remember when the problem disappeared but it is no longer here for sure. |
[DCOM-51] Support parsing of single quotes Created: 03/May/11 Updated: 05/May/11 Resolved: 05/May/11 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | Annotations |
| Affects Version/s: | 2.0.2 |
| Fix Version/s: | 2.1 |
| Type: | New Feature | Priority: | Major |
| Reporter: | Jordi Boggiano | Assignee: | Guilherme Blanco |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
It'd be great to support single quotes, this limitation doesn't make sense from a user point of view and in php context single quotes are so commonly used that it's easy to slip and then get some funny Exception message out of it. |
| Comments |
| Comment by Jordi Boggiano [ 03/May/11 ] |
|
Patch against master is at https://github.com/doctrine/common/pull/17 |
| Comment by Guilherme Blanco [ 05/May/11 ] |
|
Merged the pull request. Thanks! |
[DCOM-50] Unable to use '@' in combination with a number (example: email@3domain.tld) in comment block Created: 28/Apr/11 Updated: 13/May/11 Resolved: 13/May/11 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | Annotations |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Florian Preusner | Assignee: | Guilherme Blanco |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
My tld contains a number at the beginning (8points.de). Exception: I think this is a bug?! |
| Comments |
| Comment by Guilherme Blanco [ 13/May/11 ] |
|
Fixed on master. https://github.com/doctrine/common/commit/42029e6327f6ffc00a268cb61892b8ecbba49278 |
[DCOM-47] When using different class loaders Created: 07/Apr/11 Updated: 27/Dec/11 Resolved: 14/Sep/11 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | Class Loading |
| Affects Version/s: | 2.1 |
| Fix Version/s: | 2.1.2 |
| Type: | Bug | Priority: | Major |
| Reporter: | Gediminas Morkevicius | Assignee: | Guilherme Blanco |
| Resolution: | Cannot Reproduce | Votes: | 0 |
| Labels: | None | ||
| Environment: |
all |
||
| Description |
|
ClassLoader::classExists($class); will fail if different class loader is used which does not return any boolean value. This includes Symfony2 UniversalClassLoader I have never used this function before because native PHP method class_exits($class, true) first will try to autoload. But if the class does not exist |
| Comments |
| Comment by Christophe Coevoet [ 07/Apr/11 ] |
|
This is known and documented in the code: https://github.com/doctrine/common/blob/master/lib/Doctrine/Common/Annotations/Parser.php#L110 |
| Comment by Guilherme Blanco [ 14/Sep/11 ] |
|
Since Annotations package changed a lot since the bug was opened and today, I'm closing the ticket as "Cannot reproduce". Please reopen it if the issue is still valid with a testcase. Cheers, |
| Comment by Benjamin Eberlei [ 27/Dec/11 ] |
|
This issue is referenced in Github Pull-Request GH-88 |
| Comment by Jan Dolecek [ 27/Dec/11 ] |
|
Still a problem! Especially since this is used by ORM (https://github.com/doctrine/doctrine2/commit/3aea203b9ca77df65f55f036080a9af653194cbf) Class loader doesn't have to return bool (and usually DOES NOT), so even though it has loaded the class, classExists will return false. Please pull this https://github.com/doctrine/common/pull/88 |
| Comment by Benjamin Eberlei [ 27/Dec/11 ] |
|
Related Pull Request was closed: https://github.com/doctrine/common/pull/88 |
[DCOM-45] Allow different namespaces for the same alias Created: 07/Apr/11 Updated: 26/Apr/11 Resolved: 26/Apr/11 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | Annotations |
| Affects Version/s: | 2.1 |
| Fix Version/s: | 2.1 |
| Type: | Improvement | Priority: | Major |
| Reporter: | Johannes Schmitt | Assignee: | Benjamin Eberlei |
| Resolution: | Won't Fix | Votes: | 0 |
| Labels: | None | ||
| Description |
|
Right now, it is only possible to register one namespace per annotation alias. This might lead to problems since we now throw exceptions if an annotation is not found in that namespace (https://github.com/doctrine/common/commit/8967f476ddcdb7b9017a8be7f774979ca4c72247). This improvement would be a necessary first step in order to overcome the problem we talked about on IRC (FrameworkExtra/SecurityExtra both using the "extra" alias). |
| Comments |
| Comment by Johannes Schmitt [ 26/Apr/11 ] |
|
I'll close this as there is a better solution now. |
[DCOM-46] Make annotation index configurable Created: 07/Apr/11 Updated: 13/May/11 Resolved: 13/May/11 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | Annotations |
| Affects Version/s: | 2.1 |
| Fix Version/s: | 2.1 |
| Type: | Improvement | Priority: | Major |
| Reporter: | Johannes Schmitt | Assignee: | Guilherme Blanco |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
So, this is another improvement that I'd like to make. Right now all annotations are indexed by their name which has the limitation that on the top level annotations with the same name are only gathered once. /**
* @param mixed $a
* @param mixed $a
* @param mixed $a
*/
function ($a, $b, $c) { }
In the above case the annotation parser would only pick up one "param" annotation. My guess is that this was done for fast lookups, but I think we need to make this configurable (I know you hate this word /**
* @params({@param, @param, @param})
*/
function($a, $b, $c) {}
This only requires two lines to be changed/made conditional, see p.s. If you want me to provide a patch for this, just tell me. |
| Comments |
| Comment by Guilherme Blanco [ 13/May/11 ] |
|
Implemented on master. https://github.com/doctrine/common/commit/59910f53fad7ce08a1ec840d9874a74cefcf32b8 |
[DCOM-44] Throw exception if known namespaced annotation is not found Created: 05/Apr/11 Updated: 06/Apr/11 Resolved: 05/Apr/11 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | 2.1 |
| Type: | Improvement | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Benjamin Eberlei |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
If we know that an annotation is namespaced and that the namespace exists we should throw an exception if the annotation specified does not exist, currently its just skipped which can be very nasty to debug. |
| Comments |
| Comment by Benjamin Eberlei [ 05/Apr/11 ] |
|
Implemented |
| Comment by Gediminas Morkevicius [ 06/Apr/11 ] |
|
For example my extensions are using same alias[vendor name] for all annotations. In this case each extension can be used independetly from others. And after this "fix" it couples all extensions and forces to autoload all annotations because in other case it will simply throw a fatal error, since class_exists now uses require without even checking if file exists. |
| Comment by Benjamin Eberlei [ 06/Apr/11 ] |
|
This change should not fatal through class_exists(). I dont change the autoloading behavior at all, i just throw an exception if the class was not found and annotation is namesapced Johannes complained about this for the same reason (reusing vendor prefixes). I find this quite annoying, because i constantly misstype annotations and get no error messages at all, the number of bug reports in this regard is also quite high. We have to find a solution for this |
[DCOM-32] Memcache cache relies on deprecated functions Created: 21/Dec/10 Updated: 28/Mar/12 Resolved: 27/Aug/11 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | Caching |
| Affects Version/s: | 2.0.0-RC2 |
| Fix Version/s: | 2.2 |
| Type: | Bug | Priority: | Major |
| Reporter: | Sebastian Hoitz | Assignee: | Guilherme Blanco |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
The method getIds() in MemcacheCache relies on the old "cachedump" stat type. But as you can read here: http://de2.php.net/manual/en/memcache.getextendedstats.php this has been removed due to security reasons. |
| Comments |
| Comment by Sebastian Hoitz [ 21/Dec/10 ] |
|
Adding this to memcached before getting the extended stats cachedump fixed this issue for me: if(!is_int($slabId)) { continue; } |
| Comment by Guilherme Blanco [ 15/Feb/11 ] |
|
This issue doesn't seen to be valid anymore based on commit of @hobodave on Jan 29th. Please reopen if it is still valid. I could not reproduce. |
| Comment by Guilherme Blanco [ 18/Apr/11 ] |
|
Memcache daemon 1.4.5 do not provide cachedump and triggers a couple of issues all around. We need to think on a workaround since current state of Doctrine 2 is unusable with recent memcache. |
| Comment by Denis [ 07/May/11 ] |
|
There additionally seems to be a hard-coded limit to the size of the dump: http://lists.danga.com/pipermail/memcached/2007-April/003906.html |
| Comment by Guilherme Blanco [ 27/Aug/11 ] |
|
Fixed in master by this commit: https://github.com/doctrine/common/commit/486169851ea87b3e14ed45d5bfd7d07b1d41af65 |
| Comment by Przemek Sobstel [ 28/Mar/12 ] |
|
@Guilherme, your fix introduced big performance issue as now for each fetch() call there are always 2 additional calls, which is kind of big overhead. See https://github.com/doctrine/common/pull/125 for details. |
[DCOM-76] switch license to MIT Created: 09/Nov/11 Updated: 09/Jun/12 Resolved: 09/Jun/12 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Improvement | Priority: | Major |
| Reporter: | Lukas Kahwe | Assignee: | Benjamin Eberlei |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
since common was mostly written by a small group of people and not based on Doctrine 1.x it seems possible to switch the license which imho would really boost the use cases. |
| Comments |
| Comment by Guilherme Blanco [ 09/Jun/12 ] |
|
Successfully migrated to MIT!!! \o/ |
[DCOM-71] Add save get_class() to Debug Util Created: 22/Oct/11 Updated: 23/Oct/11 Resolved: 23/Oct/11 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | 2.2 |
| Type: | Improvement | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Benjamin Eberlei |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Comments |
| Comment by Benjamin Eberlei [ 23/Oct/11 ] |
|
Added. |
[DCOM-70] [CacheProvider] missing functions Created: 27/Sep/11 Updated: 06/Mar/12 Resolved: 03/Oct/11 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | Caching |
| Affects Version/s: | 2.2 |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Jérôme Forêt | Assignee: | Guilherme Blanco |
| Resolution: | Won't Fix | Votes: | 0 |
| Labels: | None | ||
| Description |
|
Why delete functions in CacheProvider like deleteByPrefix deleteByPostfix deleteByRegex ? |
| Comments |
| Comment by Guilherme Blanco [ 03/Oct/11 ] |
|
The deleteBy*() aswell as getIds() methods cannot be brought back. Since we keep the Least Common Multiple (LCM) in our Cache platform, these drivers started to be affected in latest *NIX releases (like for example, Memcache 1.6.5+ that does not bring cachedump anymore). We started to have many reports here because cache was not working, or they were not clearing or even they were getting partially cleared. So we re-worked on Cache package to bring the LCM again. Based on that, individual drivers like APC may still support the cache Id retrieval, but our approach differed and we can't bring this back. You may override into your own driver (composition) extending our ApcCache and implemented your desired functions. Marking the ticket as won't fix. Cheers, |
| Comment by Peter Mitchell [ 06/Mar/12 ] |
|
The documentation still refers to these deprecated elements which is a little confusing as there is no indication of this in the Abstract Classes/Interfaces http://docs.doctrine-project.org/projects/doctrine-orm/en/latest/reference/caching.html |
[DCOM-68] Add @codeCoverageIgnoreStart and @codeCoverageIgnoreEnd to annotation ignore map Created: 25/Sep/11 Updated: 25/Sep/11 Resolved: 25/Sep/11 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | 2.1.1 |
| Fix Version/s: | 2.1.2 |
| Type: | Improvement | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Benjamin Eberlei |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Comments |
| Comment by Benjamin Eberlei [ 25/Sep/11 ] |
|
Done |
[DCOM-66] Github-PR-55 by shesek: Use stream_resolve_include_path Created: 25/Aug/11 Updated: 28/Aug/11 Resolved: 28/Aug/11 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | 2.2 |
| Type: | Improvement | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Guilherme Blanco |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of {username}: Url: https://github.com/doctrine/common/pull/55 Message: `Doctrine\Common\ClassLoader::fileExistsInIncludePath` behaves the same as `stream_resolve_include_path`, use that instead when available (PHP >= 5.3.2). It should be faster than doing that manually. |
| Comments |
| Comment by Guilherme Blanco [ 28/Aug/11 ] |
|
Fixed in trunk. |
[DCOM-62] Github-PR-53 by shawndellysse: ArrayCollection#join Created: 21/Aug/11 Updated: 14/Sep/11 Resolved: 14/Sep/11 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | 2.1.2 |
| Type: | Improvement | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Guilherme Blanco |
| Resolution: | Won't Fix | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of {username}: Url: https://github.com/doctrine/common/pull/53 Message: Added the `join` method to `ArrayCollection`. |
| Comments |
| Comment by Guilherme Blanco [ 14/Sep/11 ] |
|
This can't be easily implemented by ORM because join() would require more than a single delimiter. |
[DCOM-60] SimpleAnnotationReader get*Annotations Created: 12/Aug/11 Updated: 28/Aug/11 Resolved: 28/Aug/11 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Ryan Hutchison | Assignee: | Guilherme Blanco |
| Resolution: | Invalid | Votes: | 0 |
| Labels: | None | ||
| Description |
|
<br /> Doctrine/Common/Annotations/SimpleAnnotationReader.php public function getMethodAnnotations(\ReflectionMethod $method) { - return $this->parser->parse($method->getDocComment(), 'method '.$class->getName().'::'.$method->getName().'()'); + return $this->parser->parse($method->getDocComment(), 'method '.$method->getName().'::'.$method->getName().'()'); } public function getPropertyAnnotations(\ReflectionProperty $property) { - return $this->parser->parse($property->getDocComment(), 'property '.$class->getName().'::$'.$property->getName()); + return $this->parser->parse($property->getDocComment(), 'property '.$property->getName().'::$'.$property->getName()); } |
| Comments |
| Comment by Guilherme Blanco [ 28/Aug/11 ] |
|
This issue is already fixed in master. Closing the ticket. |
[DCOM-127] [GH-206] Debug::export ArrayIterator dumps the internal storage variable Created: 19/Oct/12 Updated: 14/Jan/13 Resolved: 14/Jan/13 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Benjamin Eberlei |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of Slamdunk: Url: https://github.com/doctrine/common/pull/206 Message: Following my previous PR https://github.com/doctrine/common/pull/191 I found also ArrayIterator needs special behaviour. |
[DCOM-126] [GH-205] Fixed a typo in PHPdoc Created: 17/Oct/12 Updated: 14/Jan/13 Resolved: 14/Jan/13 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Benjamin Eberlei |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of michaelperrin: Url: https://github.com/doctrine/common/pull/205 Message: A unnecessary new line was inserted in ClassLoader.php |
| Comments |
| Comment by Benjamin Eberlei [ 17/Oct/12 ] |
|
A related Github Pull-Request [GH-205] was closed |
[DCOM-125] [GH-204] Bad function call in Debug::toString() Created: 17/Oct/12 Updated: 14/Jan/13 Resolved: 14/Jan/13 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Benjamin Eberlei |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of touki653: Url: https://github.com/doctrine/common/pull/204 Message: Fixed an (obviously) over used function which were calling [method_exists](http://php.net/method_exists) function the wrong way. In `Doctrine\Common\Util\Debug::toString($obj)` |
| Comments |
| Comment by Benjamin Eberlei [ 17/Oct/12 ] |
|
A related Github Pull-Request [GH-204] was closed |
[DCOM-122] [GH-200] ClassMetadataFactory child classes can now filter the metadata when calling getAllMetadata Created: 07/Oct/12 Updated: 07/Oct/12 Resolved: 07/Oct/12 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Benjamin Eberlei |
| Resolution: | Won't Fix | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of theUniC: Url: https://github.com/doctrine/common/pull/200 Message: This is due mainly, because we have found performance issues when trying to generate a complete schema (annotation based) from a legacy database with tons of tables with the ConvertMapping command. This will let filter table names to the ```Doctrine\ORM\Mapping\Driver\DatabaseDriver::getAllClassNames``` and ```Doctrine\ORM\Mapping\Driver\DatabaseDriver::loadMetadataForClass``` methods, and extract class metadata from a smaller subset of classes (I'm doing another PR for this in the ORM repository). |
| Comments |
| Comment by Benjamin Eberlei [ 07/Oct/12 ] |
|
A related Github Pull-Request [GH-200] was closed |
[DCOM-116] [GH-193] Optimize autoload prefix in composer.json Created: 28/Sep/12 Updated: 14/Jan/13 Resolved: 14/Jan/13 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Benjamin Eberlei |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of Slamdunk: Url: https://github.com/doctrine/common/pull/193 Message: By having more specific autoload prefixes it is possible to reduce the number of stat calls made. |
| Comments |
| Comment by Benjamin Eberlei [ 28/Sep/12 ] |
|
A related Github Pull-Request [GH-193] was closed |
[DCOM-115] [GH-191] Debug::export ArrayObject dumps the internal storage variable Created: 27/Sep/12 Updated: 01/Oct/12 Resolved: 01/Oct/12 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Benjamin Eberlei |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of Slamdunk: Url: https://github.com/doctrine/common/pull/191 Message: Until now, exporting `ArrayObject` hid the internal storage variable, but `print_r` and `var_dump` show it. With this PR the `ArrayObject::storage` variable is exported too. |
| Comments |
| Comment by Benjamin Eberlei [ 01/Oct/12 ] |
|
A related Github Pull-Request [GH-191] was closed |
[DCOM-96] Extract a common ProxyFactory Created: 12/Feb/12 Updated: 10/Jan/13 Resolved: 10/Jan/13 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | 2.4 |
| Type: | New Feature | Priority: | Major |
| Reporter: | Christophe Coevoet | Assignee: | Marco Pivetta |
| Resolution: | Fixed | Votes: | 1 |
| Labels: | None | ||
| Description |
|
Currently, each Doctrine project implements its own ProxyFactory. But the most part of the logic is simply copy-pasted from the ORM implementation (or from an older version of the ORM implementation). Extracting the common code would be a good idea to avoid having to maintain 4 places (or even more) containing the same logic |
| Comments |
| Comment by Marco Pivetta [ 22/Oct/12 ] |
|
I have a working implementation of public properties lazy loading at https://github.com/Ocramius/doctrine2/compare/master...DCOM-96-restarted I am still trying to figure out performance issues, since this PR adds 5% overhead on top of Hydrators/Persisters/UnitOfWork, since it turned out that $reflectionProperty->getValue($object); actually triggers PHP's magic __get method. |
[DCOM-93] Add Reflection Abstraction Created: 28/Dec/11 Updated: 03/Jan/12 Resolved: 02/Jan/12 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | 2.2 |
| Type: | New Feature | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Benjamin Eberlei |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Issue Links: |
|
||||||||
| Description |
|
The Reflection code in ClassMetadata(Info*)s is getting out of control. I want to remove the dependency by introducing a ReflectionService interface: interface ReflectionService { public function getClassShortName($class); public function getClassNamespace($class); public function getClass($class); public function getAccessibleProperty($class, $property); public function hasPublicMethod($class, $method); } The reflection methods are specifically allowed to return NULL, so that we can create a StaticReflectionService that works without the classes actually existing. |
| Comments |
| Comment by Benjamin Eberlei [ 28/Dec/11 ] |
|
This issue is referenced in Github Pull-Request GH-89 |
| Comment by Benjamin Eberlei [ 29/Dec/11 ] |
|
Related Pull Request was closed: https://github.com/doctrine/common/pull/89 |
| Comment by Benjamin Eberlei [ 02/Jan/12 ] |
|
Implemented |
[DCOM-91] GH-87: typos Created: 23/Dec/11 Updated: 16/Jan/12 Resolved: 16/Jan/12 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Guilherme Blanco |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
Pull-Request was automatically synchronized: https://github.com/doctrine/common/pull/87
|
| Comments |
| Comment by Guilherme Blanco [ 16/Jan/12 ] |
|
Fixed as per PR resolution |
[DCOM-90] GH-86: class_exists is great, use it. Created: 21/Dec/11 Updated: 16/Jan/12 Resolved: 16/Jan/12 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Guilherme Blanco |
| Resolution: | Invalid | Votes: | 0 |
| Labels: | None | ||
| Description |
|
Pull-Request was automatically synchronized: https://github.com/doctrine/common/pull/86 |
| Comments |
| Comment by Guilherme Blanco [ 16/Jan/12 ] |
|
As per PR's resolution |
[DCOM-89] GH-85: php annotations Created: 15/Dec/11 Updated: 09/Jun/12 Resolved: 09/Jun/12 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Guilherme Blanco |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
Pull-Request was automatically synchronized: https://github.com/doctrine/common/pull/85 Hello all, This patch add support for php annotations, I think that is very useful to collect class metadata. @schmittjoh can you take a look please ? Any suggestion are welcome. Thanks |
| Comments |
| Comment by Guilherme Blanco [ 09/Jun/12 ] |
|
Synchronizing with PR. It was closed. |
[DCOM-88] GH-84: Fixed phpdoc for the persistence interfaces Created: 13/Dec/11 Updated: 16/Jan/12 Resolved: 16/Jan/12 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Guilherme Blanco |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
Pull-Request was automatically synchronized: https://github.com/doctrine/common/pull/84 |
| Comments |
| Comment by Guilherme Blanco [ 16/Jan/12 ] |
|
Fixed since https://github.com/doctrine/common/commit/52c3882633b3cf11a694f2e8d9aaacb449bf5c6c |
[DCOM-87] Add a method to retrieve the identifier values in the Common interfaces Created: 12/Dec/11 Updated: 02/Jan/12 Resolved: 02/Jan/12 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Improvement | Priority: | Major |
| Reporter: | Christophe Coevoet | Assignee: | Benjamin Eberlei |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
Currently, https://github.com/symfony/symfony/blob/master/src/Symfony/Bridge/Doctrine/Security/User/EntityUserProvider.php is tied to the ORM, forcing bundle integrating other Doctrine projects to reimplement it. The only place which is not (or cannot be) implemented using only methods from the Common interfaces is retrieving the current id. `getIdentifierValues` is now implemented by the ClassMetadata in all ORM, MongoDB and CouchDB but not in the interface. Note that the tricky point about adding it is the fact that the DisconnectedMetadataFactory (used when generating entities) returns a ClassMetadataInfo instead, which does not contain this method (as it relies on the existence of the class) but implements the interface. |
| Comments |
| Comment by Benjamin Eberlei [ 02/Jan/12 ] |
|
This was implemented |
[DCOM-85] GH-81: Add Proxy#__load() Created: 03/Dec/11 Updated: 12/Dec/11 Resolved: 12/Dec/11 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | 2.2 |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Benjamin Eberlei |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
Pull-Request was automatically synchronized: https://github.com/doctrine/common/pull/81 |
| Comments |
| Comment by Benjamin Eberlei [ 12/Dec/11 ] |
|
Implemented in https://github.com/doctrine/common/pull/83 |
[DCOM-82] Fix composer.json in 2.1.x releases missing autoloader Created: 26/Nov/11 Updated: 26/Nov/11 Resolved: 26/Nov/11 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | 2.1.3 |
| Fix Version/s: | 2.1.4 |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Benjamin Eberlei |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
[DCOM-81] Attempt to create Annotation File Cache directory Created: 23/Nov/11 Updated: 23/Nov/11 Resolved: 23/Nov/11 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | Annotations |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Improvement | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Fabio B. Silva |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Comments |
| Comment by Fabio B. Silva [ 23/Nov/11 ] |
[DCOM-79] Move Lifecycle Events into Doctrine\Common\Persistence\Events Created: 19/Nov/11 Updated: 12/Dec/11 Resolved: 12/Dec/11 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | 2.2 |
| Type: | Improvement | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Benjamin Eberlei |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Comments |
| Comment by Benjamin Eberlei [ 12/Dec/11 ] |
|
Implemented in 29dbb7070058c8e7bb81bc5f9ef79d877b058887 |
[DCOM-78] ZendDataCache, Can't use method return value in write context Created: 19/Nov/11 Updated: 19/Nov/11 Resolved: 19/Nov/11 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | Caching |
| Affects Version/s: | 2.2 |
| Fix Version/s: | 2.2 |
| Type: | Bug | Priority: | Major |
| Reporter: | Matti Niemelä | Assignee: | Benjamin Eberlei |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
On line 70, empty($this->getNamespace()). empty() works only with variables so you need to assign the namespace to something before using empty(). Fatal error: Can't use method return value in write context in Doctrine/Common/Cache/ZendDataCache.php on line 70 |
| Comments |
| Comment by Benjamin Eberlei [ 19/Nov/11 ] |
|
Fixed |
[DCOM-101] Implement FilesystemCache Created: 08/Jun/12 Updated: 25/Jun/12 Resolved: 25/Jun/12 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | 2.3 |
| Type: | New Feature | Priority: | Major |
| Reporter: | Guilherme Blanco | Assignee: | Fabio B. Silva |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
Implement FilesystemCache, storing var exported pieces that could be loaded on demand. |
| Comments |
| Comment by Fabio B. Silva [ 25/Jun/12 ] |
|
Fixed By : https://github.com/doctrine/common/commit/8df9cdf3b921a3b59bbba51d5ba9063509ef6a1a |
[DCOM-172] [GH-254] Update lib/Doctrine/Common/Proxy/ProxyGenerator.php Created: 18/Feb/13 Updated: 19/Feb/13 Resolved: 19/Feb/13 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Benjamin Eberlei |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of mmarksnippety: Url: https://github.com/doctrine/common/pull/254 Message: Added missed semicolon |
| Comments |
| Comment by Benjamin Eberlei [ 18/Feb/13 ] |
|
A related Github Pull-Request [GH-254] was opened |
| Comment by Benjamin Eberlei [ 18/Feb/13 ] |
|
A related Github Pull-Request [GH-254] was closed |
| Comment by Marco Pivetta [ 19/Feb/13 ] |
|
Continuing in |
| Comment by Benjamin Eberlei [ 19/Feb/13 ] |
|
A related Github Pull-Request [GH-255] was closed |
[DCOM-171] [GH-253] Proxy Generation Bug Created: 16/Feb/13 Updated: 16/Feb/13 Resolved: 16/Feb/13 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Benjamin Eberlei |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of odiaseo: Url: https://github.com/doctrine/common/pull/253 Message: Added missing semi colon and removed backslashes previously used to escape function arguments |
| Comments |
| Comment by Benjamin Eberlei [ 16/Feb/13 ] |
|
A related Github Pull-Request [GH-253] was closed |
[DCOM-169] [GH-249] Namespaced the PR246 test case Created: 27/Jan/13 Updated: 29/Jan/13 Resolved: 29/Jan/13 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Benjamin Eberlei |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of BenMorel: Url: https://github.com/doctrine/common/pull/249 Message: Sorry, I've forgot the namespace in the test case of my previous PR, which has just been merged. |
| Comments |
| Comment by Benjamin Eberlei [ 29/Jan/13 ] |
|
A related Github Pull-Request [GH-249] was closed |
[DCOM-167] [GH-248] Hotfix/doctrine/common#247 fixes Created: 26/Jan/13 Updated: 26/Jan/13 Resolved: 26/Jan/13 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | 2.1.4 |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Benjamin Eberlei |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of Ocramius: Url: https://github.com/doctrine/common/pull/248 Message: Includes fixes suggested for #247 (plus a weird fix on a failure with `array_map` on PHP <5.4) |
| Comments |
| Comment by Benjamin Eberlei [ 26/Jan/13 ] |
|
A related Github Pull-Request [GH-248] was closed |
[DCOM-166] [GH-246] Undefined variable fix Created: 25/Jan/13 Updated: 26/Jan/13 Resolved: 26/Jan/13 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Benjamin Eberlei |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of BenMorel: Url: https://github.com/doctrine/common/pull/246 Message: |
| Comments |
| Comment by Benjamin Eberlei [ 26/Jan/13 ] |
|
A related Github Pull-Request [GH-246] was closed |
[DCOM-159] [GH-241] Minor performance optimization for lookups of `ArrayCollection#contains()` Created: 08/Jan/13 Updated: 08/Jan/13 Resolved: 08/Jan/13 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Marco Pivetta |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of Ocramius: Url: https://github.com/doctrine/common/pull/241 Message: |
| Comments |
| Comment by Benjamin Eberlei [ 08/Jan/13 ] |
|
A related Github Pull-Request [GH-241] was closed |
[DCOM-157] [GH-239] Update lib/Doctrine/Common/Cache/Cache.php Created: 06/Jan/13 Updated: 06/Jan/13 Resolved: 06/Jan/13 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Benjamin Eberlei |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of lmammino: Url: https://github.com/doctrine/common/pull/239 Message: Typo in interface documentation |
| Comments |
| Comment by Benjamin Eberlei [ 06/Jan/13 ] |
|
A related Github Pull-Request [GH-239] was closed |
[DCOM-158] [GH-240] [Cache/CouchbaseCache] Return false instead of null for compat. Created: 07/Jan/13 Updated: 07/Jan/13 Resolved: 07/Jan/13 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Benjamin Eberlei |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of daschl: Url: https://github.com/doctrine/common/pull/240 Message: This changeset fixes and verifies that instead of null, false is returned |
| Comments |
| Comment by Benjamin Eberlei [ 07/Jan/13 ] |
|
A related Github Pull-Request [GH-240] was closed |
[DCOM-155] [GH-237] Update tests/Doctrine/Tests/Common/Annotations/Fixtures/NamespaceWithClo... Created: 03/Jan/13 Updated: 10/Jan/13 Resolved: 10/Jan/13 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Benjamin Eberlei |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of vincequeiroz: Url: https://github.com/doctrine/common/pull/237 Message: ...sureDeclaration.php Statement duplicate $var = 1; |
| Comments |
| Comment by Benjamin Eberlei [ 10/Jan/13 ] |
|
A related Github Pull-Request [GH-237] was closed |
[DCOM-154] [GH-236] Adding Support for Couchbase as Caching Infrastructure. Created: 20/Dec/12 Updated: 06/Jan/13 Resolved: 06/Jan/13 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | 2.4 |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Benjamin Eberlei |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of daschl: Url: https://github.com/doctrine/common/pull/236 Message: This changeset brings in support for Couchbase Server 2.0 as |
[DCOM-153] [GH-235] Improve performance of if key exists in the array Created: 17/Dec/12 Updated: 18/Dec/12 Resolved: 18/Dec/12 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Benjamin Eberlei |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of basico: Url: https://github.com/doctrine/common/pull/235 Message: So, here are few indications: |
| Comments |
| Comment by Benjamin Eberlei [ 18/Dec/12 ] |
|
A related Github Pull-Request [GH-235] was closed |
[DCOM-149] [GH-231] Fixing CS Created: 04/Dec/12 Updated: 14/Jan/13 Resolved: 14/Jan/13 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Benjamin Eberlei |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of ruian: Url: https://github.com/doctrine/common/pull/231 Message: |
| Comments |
| Comment by Benjamin Eberlei [ 04/Dec/12 ] |
|
A related Github Pull-Request [GH-231] was closed |
[DCOM-148] [GH-229] Decorator base class for object manager decorators Created: 25/Nov/12 Updated: 20/Jan/13 Resolved: 20/Jan/13 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | 2.4 |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Benjamin Eberlei |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of lstrojny: Url: https://github.com/doctrine/common/pull/229 Message: As discussed on IRC, the first PR for decorator base classes. This time for ObjectManager. |
[DCOM-147] [GH-227] [DDC-2160] Smart Pluralize/Singularize support for Doctrine/Common/Util/Inflector Created: 23/Nov/12 Updated: 14/Jan/13 Resolved: 14/Jan/13 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Benjamin Eberlei |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of jbergler: Url: https://github.com/doctrine/common/pull/227 Message: Doctrine/ORM/Tools/EntityGenerator should pluralize/signularize correctly. This PR adds functionality to Doctrine/Common/Util/Inflector to singularize/pluralize. The code is largely borrowed from a similar class in the CakePHP project - I'm not sure if the updates to the class doc covers the requirements for this. Test coverage also added. |
[DCOM-146] [GH-226] Added error suppression to unlink() calls Created: 22/Nov/12 Updated: 22/Nov/12 Resolved: 22/Nov/12 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Benjamin Eberlei |
| Resolution: | Fixed | Votes: | 1 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of SalmanPK: Url: https://github.com/doctrine/common/pull/226 Message: Added error suppression to unlink() calls in the getPropertyAnnotations and getMethodAnnotations methods to be consistent with the getClassAnnotations method. |
| Comments |
| Comment by Benjamin Eberlei [ 22/Nov/12 ] |
|
A related Github Pull-Request [GH-226] was closed |
| Comment by Fabio B. Silva [ 22/Nov/12 ] |
|
Merged : https://github.com/doctrine/common/commit/a836c86c13e964051549e234250cf665a5f5a190 |
[DCOM-145] [GH-225] Replace file_exists() calls with is_file() where it is needed Created: 20/Nov/12 Updated: 21/Nov/12 Resolved: 21/Nov/12 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Benjamin Eberlei |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of fruit: Url: https://github.com/doctrine/common/pull/225 Message: The function `file_exists()` checks whether file or directory exists. And `is_file()` checks only files for the existence. All places, where `file_exists()` is replaced with `is_file()` needs only to check for file existence. |
| Comments |
| Comment by Benjamin Eberlei [ 20/Nov/12 ] |
|
A related Github Pull-Request [GH-225] was closed |
[DCOM-144] [GH-224] Use preg_quote() to escape text before inserting into regexp Created: 20/Nov/12 Updated: 21/Nov/12 Resolved: 21/Nov/12 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Benjamin Eberlei |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of fruit: Url: https://github.com/doctrine/common/pull/224 Message: PHP has build-in function `preg_quote()` in order to escape strings witch are dynamically inserted into regular expression. |
| Comments |
| Comment by Benjamin Eberlei [ 21/Nov/12 ] |
|
A related Github Pull-Request [GH-224] was closed |
[DCOM-143] [GH-223] Fix for DCOM-106 Created: 20/Nov/12 Updated: 21/Nov/12 Resolved: 21/Nov/12 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Benjamin Eberlei |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of nemekzg: Url: https://github.com/doctrine/common/pull/223 Message: Both fixme and TODO become ignored. |
| Comments |
| Comment by Benjamin Eberlei [ 20/Nov/12 ] |
|
A related Github Pull-Request [GH-223] was closed |
[DCOM-142] [GH-222] make Base LifecycleEventArgs usable in orm and odm Created: 19/Nov/12 Updated: 05/Dec/12 Resolved: 05/Dec/12 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Benjamin Eberlei |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of docteurklein: Url: https://github.com/doctrine/common/pull/222 Message: Pull requests are to come for both orm and odm to make use of this. The main goal is to make more abstract listeners, compatible with both orm and odm. |
| Comments |
| Comment by Florian Klein [ 05/Dec/12 ] |
|
@Benjamin Eberlei, any news on this ? |
[DCOM-141] [GH-221] strip invalid characters Created: 17/Nov/12 Updated: 14/Jan/13 Resolved: 14/Jan/13 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Benjamin Eberlei |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of FabioBatSilva: Url: https://github.com/doctrine/common/pull/221 Message: This patch is proposal to fix #180 |
[DCOM-136] [GH-216] Adding failing test for silent autoloaders Created: 15/Nov/12 Updated: 10/Jan/13 Resolved: 10/Jan/13 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Marco Pivetta |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of Ocramius: Url: https://github.com/doctrine/common/pull/216 Message: Fixing support for silent autoloaders |
[DCOM-43] Cache Stats Created: 05/Apr/11 Updated: 21/Sep/11 Resolved: 21/Sep/11 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | Caching |
| Affects Version/s: | 2.0.1 |
| Fix Version/s: | 2.2 |
| Type: | New Feature | Priority: | Major |
| Reporter: | Otavio Ferreira | Assignee: | Guilherme Blanco |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
Doctrine should be able to retrieve stats from cache providers, such as Memcache and APC. Stats may list cache hits, cache misses, memory, and so forth. |
| Comments |
| Comment by Guilherme Blanco [ 21/Sep/11 ] |
|
Implemented this support since this commit: https://github.com/doctrine/common/commit/34e060309ee1ae06f4be610d39d8721d2cfb1b90 |
[DCOM-41] Make annotation parser a bit cleverer Created: 09/Mar/11 Updated: 07/Apr/11 Resolved: 07/Apr/11 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | 2.0.2 |
| Type: | Bug | Priority: | Major |
| Reporter: | Johannes Schmitt | Assignee: | Benjamin Eberlei |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
From an initial look that I had at the annotation parser, it simply search for anything starting with an "@" somewhere in the doc comment and assumes that it is an annotation. Now, if someone uses the @ somewhere in his doc comment but not as an annotation, the parser breaks. An example for this can be found in the Doctrine code base, the following comment will result in a parse error: /**
* Annotation ::= "@" AnnotationName ["(" [Values] ")"]
* AnnotationName ::= QualifiedName | SimpleName | AliasedName
* QualifiedName ::= NameSpacePart "\" {NameSpacePart "\"}* SimpleName
* AliasedName ::= Alias ":" SimpleName
* NameSpacePart ::= identifier
* SimpleName ::= identifier
* Alias ::= identifier
*
* @return mixed False if it is not a valid annotation.
*/
Obviously the first @ is not used to refer to an annotation here. I think it makes sense to allow new annotations only to start at a new line, what do you think? |
| Comments |
| Comment by Johannes Schmitt [ 09/Mar/11 ] |
|
The pull request is here: |
| Comment by Benjamin Eberlei [ 09/Mar/11 ] |
|
Does this still work with nested annotations? /**
* @annot({@annot2})
*/
|
| Comment by Johannes Schmitt [ 09/Mar/11 ] |
|
Sure, my patch only changes the way how the first @ is found. |
| Comment by Roman S. Borschel [ 09/Mar/11 ] |
|
First of all, thanks for the patch. I'm just not sure whether the added complexity (nontrivial regexp vs substr/strpos) and performance penalty (to be tested) can justify fixing these such edge-cases where an @ appears in the comment block that is not one of the already stripped inline docblocks. Just my two cents, I think this needs further investigation and more extensive testing. Edit: Since the regex is "only" applied once per parsed docblock the perf. difference might be negligible but should be tested anyway. Remains the verification of the correctness of the regex, given more extensive testing and test-cases. |
| Comment by Johannes Schmitt [ 09/Mar/11 ] |
|
I think performance should not be an issue since this data is cached anyway. As for the necessity of this, it's a pain if you parse third party files and they use @ somewhere which then breaks the parser. Since Symfony2 is heavily relying on the annotation parser not only for Doctrine metadata, but for annotation metadata in general, imo this needs to be fixed. I'm not 100% happy with my solution since it covers not all, but only the most likely cases. Ideally, the lexer would have a better way to detect if an @ is used to mark the beginning of an annotation, and simply ignore the @ if it does not. I'm not familar with the lexer code, but you probably have a better understand of how it works and whether this would make sense. EDIT: I've made an alternative implementation which you can find here: https://github.com/schmittjoh/common/commit/123315e21aff6d7bce7cb77ab798660d0e68b139 |
| Comment by Benjamin Eberlei [ 05/Apr/11 ] |
|
Fixed formatting of code block |
| Comment by Benjamin Eberlei [ 07/Apr/11 ] |
|
Fixed |
[DCOM-40] Using shared references with the SharedFixtureInterface with the DataFixtures extension will not work. Created: 06/Mar/11 Updated: 14/Sep/11 Resolved: 14/Sep/11 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | 2.1.2 |
| Type: | Bug | Priority: | Major |
| Reporter: | Steven Rosato | Assignee: | Guilherme Blanco |
| Resolution: | Fixed | Votes: | 1 |
| Labels: | None | ||
| Attachments: |
|
| Description |
|
I did not know where to issue that component, but since this extension using the Doctrine Common namespace I thought it relevant to issue the bug here. Consider the following shared fixures (as stated on jwage's github repo here: https://github.com/doctrine/data-fixtures)
namespace MyDataFixtures; use Doctrine\Common\DataFixtures\AbstractFixture; class LoadUserRoleData extends AbstractFixture { public function load($manager) { $adminRole = new Role(); $adminRole->setName('admin'); $anonymousRole = new Role; $anonymousRole->setName('anonymous'); $manager->persist($adminRole); $manager->persist($anonymousRole); $manager->flush(); // store reference to admin role for User relation to Role $this->addReference('admin-role', $adminRole); } } namespace MyDataFixtures; use Doctrine\Common\DataFixtures\AbstractFixture; class LoadUserData extends AbstractFixture { public function load($manager) { $user = new User(); $user->setUsername('jwage'); $user->setPassword('test'); $user->setRole( $this->getReference('admin-role') // load the stored reference ); $manager->persist($user); $manager->flush(); // store reference of admin-user for other Fixtures $this->addReference('admin-user', $user); } } This will not use the last reference as a MANAGED entity but whether as a NEW one since the manager gets cleared (thus the unit of work) on each call to load() for the AbstractExecutor and thus marking any new references to the 'admin-user' considered a NEW entity, which should not be the case. The current workaround is to directly fetch the entity using the EM's find() function, but that completely eliminates the main goal SharedFixtures' references are bringing. I have provided the small patch that adress this issue, tests still pass. |
| Comments |
| Comment by Steven Rosato [ 06/Mar/11 ] |
|
Added patch that addresses the issue. |
| Comment by Guilherme Blanco [ 14/Sep/11 ] |
|
Not related to Common package (do we have a project for that?), but it seems this issue was already addressed when I looked at data-fixture repository. Closing as fixed. |
[DCOM-39] It is not possible to load multiple directories under the same namespace Created: 04/Mar/11 Updated: 04/Mar/11 Resolved: 04/Mar/11 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | Class Loading |
| Affects Version/s: | 2.0.1 |
| Fix Version/s: | None |
| Type: | Improvement | Priority: | Major |
| Reporter: | Steven Rosato | Assignee: | Benjamin Eberlei |
| Resolution: | Invalid | Votes: | 0 |
| Labels: | None | ||
| Description |
|
Consider the following code snippet: $loader = new ClassLoader('DoctrineExtensions', "/path/to/vendor/doctrine2-extensions-beberlei/lib"); $loader->register(); $loader = new ClassLoader('DoctrineExtensions', "/path/to/vendor/doctrine2-extensions-srosato/lib"); $loader->register(); The latter will not be able to be loaded since the documentation specifies (with good reason) that class loaders do not fail silently. Is there a workaround for this issue? |
| Comments |
| Comment by Steven Rosato [ 04/Mar/11 ] |
|
Or maybe this is intentional, such as authors that write separate doctrine extensions (according to this exemple) must define their own namespace. |
| Comment by Benjamin Eberlei [ 04/Mar/11 ] |
|
This is desired behavior, you need to pass a more specific path like "DoctrineExtensions/Versionable" + "DoctrineExtensions/Paginate" and so on... |
[DCOM-98] Fix bug with memcache/memcached and 0 as expire Created: 30/Mar/12 Updated: 30/Mar/12 Resolved: 30/Mar/12 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | 2.2.2 |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Benjamin Eberlei |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
[DCOM-3] Public value property in Base annotation class Created: 22/Apr/10 Updated: 14/Jun/10 Resolved: 14/Jun/10 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | 2.0.0-BETA2 |
| Type: | Improvement | Priority: | Major |
| Reporter: | Kirill chEbba Chebunin | Assignee: | Roman S. Borschel |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
1) If our annotation doesn't need any parameters, it stll can accept one ('value'). class Annotation extends \Doctrine\Common\Annotations\Annotation
{
private $someProperty;
public function __set($name, $value)
{
$setMethod = 'set' . ucfirst($name);
if (method_exists($this, $setMethod)) {
return $this->{$setMethod}($value);
}
return parent::__set($name, $value);
}
public function __get($name)
{
$getMethod = 'get' . ucfirst($name);
if (method_exists($this, $getMethod)) {
return $this->{$getMethod}();
}
return parent::__get($name);
}
public function getSomeProperty()
{
//some logic
return $this->someProperty;
}
protected function setSomeProperty($someProperty)
{
//some logic
$this->someProperty = $someProperty;
}
}
|
| Comments |
| Comment by Benjamin Eberlei [ 22/Apr/10 ] |
|
Why is this even relevant? can't you just ignore the value property? |
| Comment by Roman S. Borschel [ 22/Apr/10 ] |
|
I think there is something not clear here. __get and __set on Annotation are not used to set or get values but to intercept calls to non-existant values. Second, you don't need to extend from Annotation (not in HEAD at least). Any class can be used as an annotation as long as it has a constructor that takes an array with values. Annotation values are set through the constructor, not through setters or public properties. This allows you to even use immutable classes as annotations: class MyClass {
private $a, $b;
public function __construct(array $values) {
$this->a = $values['a'];
$this->b = $values['b'];
}
//... only getters...
}
/** @MyClass(a="Hello", b="World") */ class Other { //... } The default "value" will still be in $values['value'] if set. So this should work, too: class MyClass {
private $value;
public function __construct(array $values) {
$this->value = $values['value'];
}
//...
}
/** @MyClass("Hello World") */ class Other { //... } |
| Comment by Roman S. Borschel [ 22/Apr/10 ] |
|
So my suggestion would be: Just don't extend from Doctrine\Common\Annotations\Annotation and you don't have the public $value property. |
| Comment by Kirill chEbba Chebunin [ 22/Apr/10 ] |
|
Oh, i got it. It was my miss, because there was subclass checking in previous versions. interface SomeCommonAnnotationInterface { public function __construct(array $values); } |
[DCOM-21] Bug with annotations parser and tags that are not annotations (stripped tags) Created: 18/Aug/10 Updated: 18/Aug/10 Resolved: 18/Aug/10 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | 2.0.0-BETA4 |
| Fix Version/s: | 2.0.0-RC1 |
| Type: | Bug | Priority: | Major |
| Reporter: | Jonathan H. Wage | Assignee: | Roman S. Borschel |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Comments |
| Comment by Jonathan H. Wage [ 18/Aug/10 ] |
|
Fixed in http://github.com/doctrine/common/commit/df50f65ee707bb148682232c516d5168cf46d987 |
[DCOM-20] ClassLoader should check before require()... Created: 12/Aug/10 Updated: 12/Aug/10 Resolved: 12/Aug/10 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | Class Loading |
| Affects Version/s: | 2.0.0-BETA4 |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Alexander Trauzzi | Assignee: | Roman S. Borschel |
| Resolution: | Invalid | Votes: | 0 |
| Labels: | None | ||
| Environment: |
Ubuntu 10.04 |
||
| Description |
|
I noticed that prior to the require function call in loadClass(), no attempt is made to see if the file can be loaded, or to trap the result of the require attempt. This means that when I chain together class loaders on the autoload stack, the first one that specifies a namespace of null effectively terminates the process, preventing any others from being run. |
| Comments |
| Comment by Alexander Trauzzi [ 12/Aug/10 ] |
|
One solution I propose (and have used in my own class loaders in the past) is to check and see if the file exists and/or is accessible prior to the require() or include(). — if ($this->canLoadClass()) { require ($this->includePath !== null ? $this->includePath . DIRECTORY_SEPARATOR : '') . str_replace($this->namespaceSeparator, DIRECTORY_SEPARATOR, $className) . $this->fileExtension; return true; }return false; } Another might be to catch any errors thrown by the require statement if possible. This effectively guarantees that in the event of a failure, the natural PHP mechanism of the class autoloader can follow up or terminate, resulting in a Class Not Found error, rather than a failed include - which might be potentially misleading?? |
| Comment by Alexander Trauzzi [ 12/Aug/10 ] |
|
I should note that it isn't up to ClassLoader to trigger a failure in class loading, otherwise class instantiation requires every call to the "new" keyword to be prefixed by a check to verify the class is available. ClassLoader should for the most part fail silently with the one exception of notifying the autoload stack with the boolean return value. Any other errors force developers to get into the plumbing and breaks the contract between PHP's class loading behaviour and the autoload stack. |
| Comment by Roman S. Borschel [ 12/Aug/10 ] |
|
Hi. This is by design. We consider the default "contract" for autoloaders inferior as checks for file existence are unnecessary and expensive in 99.9% of the classes loaded. The ClassLoader of the Common project separates the responsibilities for a) checking whether a class can be loaded and b) actually loading the class. Furthermore, it is by design that each class loader is responsible for classes in a certain namespace. Only 1 classloader can thus be responsible for a single class. If a class loader is asked to load a class, and he is responsible for loading that class, any failure to do so is a fatal error. A missing class that is requested to be loaded is a fatal error. Silently ignoring such cases is a very bad approach from our point of view and it requires slow(er) implementations due to checks for file existence. If you specify NULL as the namespace, that means this class loader should be responsible for all classes. Thus it is obvious that a class loader that is configured as such can only be used a) as the only one or b) at the end of the autoload stack (as the last one). This approach to class loading and this implementation is designed for best efficiency. If you do not like this approach to class loading you are free to use any other implementations, Doctrine classes don't care which autoloader loads them. ps. return values don't matter at all in autoload functions for PHP, they only matter if you invoke them directly. The SPL autoload stack continues to invoke the next loader until the class is defined/loaded, then it stops, irrespective of what a loader returns. It only matters whether the class definition is now available to PHP. |
[DCOM-19] Transitive persistence on collections doesn't work when cascade is set to "all" Created: 10/Aug/10 Updated: 11/Aug/10 Resolved: 11/Aug/10 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | Collections |
| Affects Version/s: | 2.0.0-BETA4 |
| Fix Version/s: | None |
| Type: | Improvement | Priority: | Major |
| Reporter: | akeem philbert | Assignee: | Roman S. Borschel |
| Resolution: | Invalid | Votes: | 0 |
| Labels: | None | ||
| Description |
|
In documentation it says that cascade needs be set to persist for transitive persistence to work (http://www.doctrine-project.org/projects/orm/2.0/docs/reference/working-with-associations/en#transitive-persistence-/-cascade-operations:persistence-by-reachability:-cascade-persist) , but since "all" setting is a superset of "persist" it should work for that setting as well (but it doesn't ) |
| Comments |
| Comment by akeem philbert [ 11/Aug/10 ] |
|
It seems there is an issue with persisting new elements to a collection with existing elements and I've created a separate ticket (http://www.doctrine-project.org/jira/browse/DDC-742) so this one is invalid. |
[DCOM-17] Add Collection::slice($offset, $length) Created: 08/Aug/10 Updated: 14/Jan/11 Resolved: 24/Aug/10 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | Collections |
| Affects Version/s: | 2.0.0-BETA4 |
| Fix Version/s: | 2.0.0-RC1 |
| Type: | Improvement | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Benjamin Eberlei |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
Since we are still at a point were bc breaks are potentially not so harming: We need a slice() method on the Collection for forward compatibility, the support for large and very large collections using FETCH_EXTRA would heavily benefit from a method like this. /** * Extract a slice of $length elements starting at position $offset from the Collection. * * If $length is null it returns all elements from $offset to the end of the Collection. * Keys have to be preserved by this method. * * @param int $offset * @param int $length * @return array */ public function slice($offset, $length = null); The ArrayCollection implement would be: public function slice($offset, $length = null); { return array_slice($this->_elements, $offset, $length, true); // preserve keys } |
| Comments |
| Comment by Benjamin Eberlei [ 08/Aug/10 ] |
|
Updated preserve paragraph |
| Comment by Benjamin Eberlei [ 24/Aug/10 ] |
|
Implemented |
| Comment by Jan Pieper [ 14/Jan/11 ] |
|
Is there any reason why slice() returns an array although methods like filter() and map() return an instance of Doctrine\Common\Collections\ArrayCollection? |
[DCOM-18] ArrayCollection::removeElement() violates Interface Contract Created: 09/Aug/10 Updated: 09/Aug/10 Resolved: 09/Aug/10 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | Collections |
| Affects Version/s: | 2.0.0-BETA4 |
| Fix Version/s: | 2.0.0-RC1 |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Benjamin Eberlei |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
It return the element, not true. |
| Comments |
| Comment by Benjamin Eberlei [ 09/Aug/10 ] |
|
Fixed |
[DCOM-13] Better flexibility when the Annotation is created by the Parser Created: 24/Jul/10 Updated: 02/Aug/10 Resolved: 02/Aug/10 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | Annotations |
| Affects Version/s: | None |
| Fix Version/s: | 2.0.0-BETA4 |
| Type: | Improvement | Priority: | Major |
| Reporter: | Fabien Potencier | Assignee: | Roman S. Borschel |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Attachments: |
|
| Description |
|
The creation of the Annotation class is done at the end in Parser::Annotation(). It assumes that the Annotation class constructor takes an array of values. But if this is not the case, you are out of luck. So, I propose to move the logic of Annotation creation to is own method for better flexibility. |
| Comments |
| Comment by Jonathan H. Wage [ 31/Jul/10 ] |
|
What is the reason your annotation class can't have a single argument array constructor? |
| Comment by Jonathan H. Wage [ 31/Jul/10 ] |
|
Currently it is by design that Annotation classes take a single argument array constructor and the Reader and Parser are not designed for inheritance. |
| Comment by Fabien Potencier [ 01/Aug/10 ] |
|
To sum up:
So, basically, you say that the Doctrine Annotation library is not designed to be used outside Doctrine? That's fine, but then I will need to create my own Annotation component, which makes me sad. |
| Comment by Roman S. Borschel [ 01/Aug/10 ] |
|
@"You force me to design my Annotation class is a certain way (for no obvious reason)" It is a contract of the implementation, nothing more, nothing less. An annotation class must have a single argument array constructor. Would you feel better if there were an interface with such a constructor? Any contract always "forces" you to design your class that implements that contract in a certain way. @"You don't want the Parser and Reader to be extensible." They simply are not designed to be inherited right now which simply means we don't care about backwards compatibility with regards to subclasses when changing these classes and we're not documenting and telling people it is a good idea to subclass them. And frankly, inhertiance just to swap out the annotation construction process is a bad idea. It reveals & couples the subclasses to all the details of the parent class even though all they actually want is exchange the construction process. Moreover you would right now need to extend both, the parser and and reader to swap out the construction process. At least the parser would then need to become an (optional) constructor argument of a reader in order not to need to subclass the reader. Inheritance => strong coupling => hard to maintain backwards compatibility. If there is strong desire to replace the annotation construction process, a factory (method/closure) approach would be much better. Please try to be more constructive. Neither did you show concrete use-cases nor is your suggested solution a good idea as it is now because it requires 2 classes to be extended plus 1 constructor and 1 method to be overridden just to exchange the annotation construction process. This can surely be done simpler and will be done simpler if there is enough need for this enhancement. |
| Comment by Jonathan H. Wage [ 02/Aug/10 ] |
|
This was fixed in http://github.com/doctrine/common/commit/66dad3e22205d812911adeb32b9f8bab8879d4b7 |
[DCOM-12] Annotation caching causes application instance mixups Created: 13/Jul/10 Updated: 13/Jul/10 Resolved: 13/Jul/10 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | Annotations |
| Affects Version/s: | 2.0.0-BETA2, 2.0.0-BETA3, 2.0.0-BETA4 |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | John Kleijn | Assignee: | Roman S. Borschel |
| Resolution: | Invalid | Votes: | 0 |
| Labels: | None | ||
| Description |
|
Take a look at lib/Doctrine/Common/Annotations/AnnotationReader.php:137
/**
* Gets the annotations applied to a class.
*
* @param string|ReflectionClass $class The name or ReflectionClass of the class from which
* the class annotations should be read.
* @return array An array of Annotations.
*/
public function getClassAnnotations(ReflectionClass $class)
{
$cacheKey = $class->getName() . self::$CACHE_SALT;
// Attempt to grab data from cache
if (($data = $this->cache->fetch($cacheKey)) !== false) {
return $data;
}
$annotations = $this->parser->parse($class->getDocComment(), 'class ' . $class->getName());
$this->cache->save($cacheKey, $annotations, null);
return $annotations;
}
It uses the class name and a static salt to create a cache key. Actually, everything in that class uses a class name to assemble a cache key. This makes it impossible to have mulitple instances of the same application in different states. Practically: it makes it impossible to have testing and staging, or staging and production versions on the same host if they use the same type of caching (which you sort of need in a staging environment). |
| Comments |
| Comment by John Kleijn [ 13/Jul/10 ] |
|
Confused "fix" with "affects", sorry |
| Comment by Roman S. Borschel [ 13/Jul/10 ] |
|
Why not just use the namespacing facilities of the cache drivers? |
| Comment by John Kleijn [ 13/Jul/10 ] |
|
Cause I didn't read the caching docs? |
[DCOM-6] Non existant namespace alias throws a PHP Notice Created: 27/May/10 Updated: 01/Sep/10 Resolved: 01/Sep/10 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | 2.0.0-BETA2 |
| Fix Version/s: | 2.0.0-RC1 |
| Type: | Bug | Priority: | Major |
| Reporter: | Tim Nagel | Assignee: | Benjamin Eberlei |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
@nonalias:Annot results in a php notice. |
| Comments |
| Comment by Tim Nagel [ 27/May/10 ] |
|
Proposed tests and fix http://github.com/merk/common/commit/65e8c10b74201c39dbe291c36230205d9b08ed65 |
| Comment by Guilherme Blanco [ 31/Aug/10 ] |
|
In commit: http://github.com/doctrine/common/commit/ad49a676269af368563bd9a848c904b81a825622 I fixed this issue. |
| Comment by Tim Nagel [ 31/Aug/10 ] |
|
What will your change do if there are multiple implementations of the Reader working on entities that dont have common namespaces, but still use namespaces? Would it not make more sense to skip something that the Reader doesnt understand, rather than throwing an error? (For example, Symfony2's validator system might have namespaced validators, which would then cause the 'Doctrine' reader to throw an exception) |
| Comment by Guilherme Blanco [ 01/Sep/10 ] |
|
Yes, you're right... I think we'll have to silently bypass unknown aliases... this makes debug harder, but we don't have any other option. =( Reopening it |
| Comment by Benjamin Eberlei [ 01/Sep/10 ] |
|
Fixed to skip the unknown alias annotation. |
[DCOM-181] [GH-260] Hotfix/issue #259 Created: 07/Mar/13 Updated: 08/Mar/13 Resolved: 08/Mar/13 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Marco Pivetta |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of Ocramius: Url: https://github.com/doctrine/common/pull/260 Message: Hotfix for doctrine/common#259 |
| Comments |
| Comment by Benjamin Eberlei [ 07/Mar/13 ] |
|
A related Github Pull-Request [GH-260] was closed |
[DCOM-183] [GH-262] Fixed travis build Created: 11/Mar/13 Updated: 11/Mar/13 Resolved: 11/Mar/13 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Benjamin Eberlei |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of pborreli: Url: https://github.com/doctrine/common/pull/262 Message: since composer/composer#1005 composer updates --dev by default. |
| Comments |
| Comment by Benjamin Eberlei [ 11/Mar/13 ] |
|
A related Github Pull-Request [GH-262] was closed |
[DCOM-182] [GH-261] Fixed typos Created: 11/Mar/13 Updated: 11/Mar/13 Resolved: 11/Mar/13 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Benjamin Eberlei |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of pborreli: Url: https://github.com/doctrine/common/pull/261 Message: |
| Comments |
| Comment by Benjamin Eberlei [ 11/Mar/13 ] |
|
A related Github Pull-Request [GH-261] was opened |
| Comment by Benjamin Eberlei [ 11/Mar/13 ] |
|
A related Github Pull-Request [GH-261] was closed |
[DCOM-170] [GH-250] Adding export attributes Created: 27/Jan/13 Updated: 16/Apr/13 Resolved: 16/Apr/13 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Marco Pivetta |
| Resolution: | Won't Fix | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of Ocramius: Url: https://github.com/doctrine/common/pull/250 Message: |
| Comments |
| Comment by Doctrine Bot [ 16/Apr/13 ] |
|
A related Github Pull-Request [GH-250] was closed: |
| Comment by Marco Pivetta [ 16/Apr/13 ] |
|
No good positive feedback - no need to force it in |
[DCOM-188] [GH-272] MappingDriverChain: the default driver wasn't called for getAllClassNames() Created: 16/Apr/13 Updated: 16/Apr/13 Resolved: 16/Apr/13 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Doctrine Bot | Assignee: | Marco Pivetta |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of mnapoli: Url: https://github.com/doctrine/common/pull/272 Message: `MappingDriverChain::getAllClassNames()` would call and merge sub-drivers `getAllClassNames()` results, but not for the default driver. I added a test that reproduced the problem, and then fixed it. |
| Comments |
| Comment by Doctrine Bot [ 16/Apr/13 ] |
|
A related Github Pull-Request [GH-272] was closed: |
| Comment by Marco Pivetta [ 16/Apr/13 ] |
|
Merged |
[DCOM-192] [GH-274] Improve code on loadMetadata() to verify if class exists Created: 07/May/13 Updated: 08/May/13 Resolved: 08/May/13 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Doctrine Bot | Assignee: | Marco Pivetta |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of entering: Url: https://github.com/doctrine/common/pull/274 Message: Improve code on loadMetadata() to verify if class exists, avoid a later warning when calling class_parents() Instead throws a \RuntimeException if class doesn't exists. Before changing code, just after add test: /home/www/common/lib/Doctrine/Common/Persistence/Mapping/RuntimeReflectionService.php:38 |
| Comments |
| Comment by Doctrine Bot [ 08/May/13 ] |
|
A related Github Pull-Request [GH-274] was closed: |
| Comment by Marco Pivetta [ 08/May/13 ] |
|
Merged |
[DCOM-193] [GH-275] Improve code to throw exception getting parents class instead of php warning Created: 09/May/13 Updated: 09/May/13 Resolved: 09/May/13 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | 2.4 |
| Type: | Bug | Priority: | Major |
| Reporter: | Doctrine Bot | Assignee: | Benjamin Eberlei |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of entering: Url: https://github.com/doctrine/common/pull/275 Message: Related to https://github.com/doctrine/common/pull/274 |
| Comments |
| Comment by Doctrine Bot [ 09/May/13 ] |
|
A related Github Pull-Request [GH-275] was closed: |
[DCOM-190] [GH-273] Added visibility in the methods Interfaces Created: 06/May/13 Updated: 21/May/13 Resolved: 21/May/13 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Doctrine Bot | Assignee: | Guilherme Blanco |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of ramonornela: Url: https://github.com/doctrine/common/pull/273 Message: This adjustment aims to bring to the default PSR2. Thanks, |
| Comments |
| Comment by Doctrine Bot [ 21/May/13 ] |
|
A related Github Pull-Request [GH-273] was closed: |
| Comment by Marco Pivetta [ 21/May/13 ] |
|
merged |
[DCOM-123] [GH-202] Add sqlite cache driver Created: 08/Oct/12 Updated: 23/May/13 Resolved: 23/May/13 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Benjamin Eberlei | Assignee: | Benjamin Eberlei |
| Resolution: | Incomplete | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of Baachi: Url: https://github.com/doctrine/common/pull/202 Message: |
| Comments |
| Comment by Doctrine Bot [ 23/May/13 ] |
|
A related Github Pull-Request [GH-202] was closed: |
[DCOM-201] [GH-284] Adding failing test demonstrating DCOM-175 Created: 19/Jun/13 Updated: 19/Jun/13 Resolved: 19/Jun/13 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major |
| Reporter: | Doctrine Bot | Assignee: | Marco Pivetta |
| Resolution: | Duplicate | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of Ocramius: Url: https://github.com/doctrine/common/pull/284 Message: Private properties of parent classes are not serialized correctly, therefore PHP throws a notice during serialization |
| Comments |
| Comment by Marco Pivetta [ 19/Jun/13 ] |
|
Duplicate of DCOM-175 |
[DCOM-49] Debug::dump/export for ODM documents Created: 26/Apr/11 Updated: 16/Jan/12 Resolved: 16/Jan/12 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | 2.0.2 |
| Fix Version/s: | None |
| Type: | Task | Priority: | Minor |
| Reporter: | Andrew Cobby | Assignee: | Guilherme Blanco |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
Doctrine\Common\Util\Debug has code to deal with Proxy objects from the ORM, but nothing for other Doctrine projects. Maybe the Common package should introduce a base Proxy interface so the Debug class isn't dependant on the ORM? This would also mean standardising Proxy objects, particularly the private property names... ORM proxy objects have $identifier and $_entityPersister while ODM proxy objects have $identifier_ and $_documentPersister. I think they should both use $identifier_ and $_persister_ and $_isInitialized_. I suppose the team is wait for Doctrine ODM to become stable before changing this? |
| Comments |
| Comment by Christophe Coevoet [ 12/Dec/11 ] |
|
This should be closed as https://github.com/doctrine/common/pull/83 decouples the Debug util from the ORM (the ODM does not uses the new interface but this is not a Doctrine Common issue) |
| Comment by Guilherme Blanco [ 16/Jan/12 ] |
|
Fixed since https://github.com/doctrine/common/commit/97d9ef41a2f8dc0ee23670b4eb6ea74a780878b8 |
[DCOM-37] orm:convert-d1-schema not working Created: 22/Feb/11 Updated: 14/Sep/11 Resolved: 14/Sep/11 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | 2.0.1 |
| Fix Version/s: | 2.1.2 |
| Type: | Bug | Priority: | Minor |
| Reporter: | Jon Johnson | Assignee: | Guilherme Blanco |
| Resolution: | Invalid | Votes: | 0 |
| Labels: | None | ||
| Environment: |
Ubuntu 10.04 PEAR install of DoctrineORM |
||
| Description |
|
orm:convert-d1-schema ~/schema.yml yml ~/newyml returns The helper "em" is not defined |
| Comments |
| Comment by Guilherme Blanco [ 14/Sep/11 ] |
|
You are not providing the EntityManagerHelper to Symfony Console. Marking as invalid. Please reopen if you have already addressed that and issue is still valid. |
[DCOM-63] CacheReader does not take in account parent classes Created: 21/Aug/11 Updated: 14/Sep/11 Resolved: 14/Sep/11 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | Annotations |
| Affects Version/s: | 2.1 |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Minor |
| Reporter: | Filip Procházka | Assignee: | Guilherme Blanco |
| Resolution: | Won't Fix | Votes: | 0 |
| Labels: | None | ||
| Description |
|
As the title says, Doctrine\Common\Annotations\CachedReaded is buggy. It takes in account only modification time of file of the class it processes. But it ignores it's parents. Pull: https://github.com/doctrine/common/pull/54 Shoud I change the commit message or something? |
| Comments |
| Comment by Guilherme Blanco [ 14/Sep/11 ] |
|
As per Johannes Smith comment: "Since we are only reading the annotations of one file, I don't see why we need this." Closed as won't fix. |
[DCOM-59] ArrayCollection contains function - switch from in_array to foreach Created: 10/Aug/11 Updated: 28/Aug/11 Resolved: 28/Aug/11 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | Collections |
| Affects Version/s: | 2.1 |
| Fix Version/s: | 2.2 |
| Type: | Improvement | Priority: | Minor |
| Reporter: | PEM | Assignee: | Guilherme Blanco |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Attachments: |
|
| Description |
|
The function contains uses in_array to determine if an element provided as parameter is found in the array $this->_elements, and performs a strict comparison. In attachement you can find a small bench file to show the differences between in_array and foreach on object search. Maybe we could provide two functions, one for smaller than 40-50k items (using foreach), and one for bigger arrays (using in_array) ? |
| Comments |
| Comment by Guilherme Blanco [ 28/Aug/11 ] |
|
I created more test cases and indeed foreach is around 40% faster than in_array. I applied the change in our suite, this should be available in new versions of Doctrine Common. |
[DCOM-58] Having class named Entity in the global namespace, interferes with the new annotation reader. Created: 04/Aug/11 Updated: 07/Sep/11 Resolved: 07/Sep/11 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | Annotations |
| Affects Version/s: | 2.1 |
| Fix Version/s: | 2.2 |
| Type: | Bug | Priority: | Minor |
| Reporter: | Michael Nielsen | Assignee: | Guilherme Blanco |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Environment: |
Ubuntu 10.04, Zend Server CE 5.1.0 (Apache 2.2.14, PHP 5.3.5), Doctrine 2.1 |
||
| Description |
|
Having a class named Entity in the global namespace, results in exceptions: "Class xxx is not a valid entity or mapped super class." The problem: \Doctrine\Common\Annotations\DocParser.php line 421: $reflClass = new \ReflectionClass($name);
$name is "Entity", and the reflection finds the non-doctrine Entity-class in the global namespace, and so doesn't find the "@Annotation" it's looking for when it examines the class. If I force it to reflect on \Doctrine\ORM\Mapping\Entity instead, the next problem is instantiation: \Doctrine\Common\Annotations\DocParser.php line 435: return new $name($values); Forcing that to the right class, brings a "Failed opening required 'Doctrine/ORM/Mapping/Doctrine/ORM/Mapping/Id.php' " - I haven't investigated further (yet at least). /Michael |
| Comments |
| Comment by Guilherme Blanco [ 07/Sep/11 ] |
|
Fixed https://github.com/doctrine/common/commit/481083226477b325decfd7202ff59c252397c392 |
[DCOM-106] Add @todo and @fixme to AnnotationReader::$globalIgnoredNames Created: 12/Sep/12 Updated: 21/Nov/12 Resolved: 21/Nov/12 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | Annotations |
| Affects Version/s: | 2.3 |
| Fix Version/s: | None |
| Type: | Improvement | Priority: | Minor |
| Reporter: | Stephen Ostrow | Assignee: | Benjamin Eberlei |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
I was wondering if you would consider adding @todo and @fixme After doing some research, I'm not sure if @fixme is used anywhere other than being in Eclipse's PDT. However, @todo is definitely on the common tags of wiki page about PHPdoc as well as the phpDoc manual. http://en.wikipedia.org/wiki/PHPDoc#Tags |
| Comments |
| Comment by Marco Pivetta [ 12/Sep/12 ] |
|
Todo is already built in: |
| Comment by Stephen Ostrow [ 12/Sep/12 ] |
|
Sorry about that. I normally write them as @TODO so the standout more. Then when I got that exception and started doing research I swear I had tried @todo. But now looking back, I bet I tried @todo and still got exceptions which were from other bugs I had going on. I guess we can close this unless anyone thinks @fixme should be in there as well. But like I said in the description, I'm not sure if @fixme is a common or just from Eclipse. |
| Comment by Marco Pivetta [ 12/Sep/12 ] |
|
Netbeans matches that one too |
| Comment by Paweł Nowak [ 20/Nov/12 ] |
|
I've prepared a fix for this issue that makes both @fixme and @TODO ignored. Pull request: https://github.com/doctrine/common/pull/223. |
[DCOM-103] Debug::toString issue with swapped parameters Created: 04/Aug/12 Updated: 28/Dec/12 Resolved: 28/Dec/12 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Minor |
| Reporter: | Oleg Namaka | Assignee: | Marco Pivetta |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
Debug::toString has an issue with swapped parameters:
method_exists('__toString', $obj)
should be method_exists($obj, '__toString') |
| Comments |
| Comment by Marco Pivetta [ 28/Dec/12 ] |
|
Fixed in master @ https://github.com/doctrine/common/commit/301228e3a52d5259a341423daf75b25366895f17 |
[DCOM-94] Support for constants on annotation reader Created: 06/Feb/12 Updated: 15/Mar/12 Resolved: 15/Mar/12 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | Annotations |
| Affects Version/s: | None |
| Fix Version/s: | 2.3 |
| Type: | New Feature | Priority: | Minor |
| Reporter: | Fabio B. Silva | Assignee: | Fabio B. Silva |
| Resolution: | Fixed | Votes: | 1 |
| Labels: | None | ||
| Description |
|
Would be nice get support for constants on annotation reader. Usage : /**
* @SomeAnnotation(PHP_EOL)
* @SomeAnnotation(SomeClass::SOME_VALUE)
* @SomeAnnotation({SomeClass::VALUE1,SomeClass::VALUE2})
* @SomeAnnotation({SomeClass::SOME_KEY = SomeClass::SOME_VALUE})
*/
|
| Comments |
| Comment by gabriel sancho [ 22/Feb/12 ] |
|
file doctrine-2.2.0/Doctrine/Common/Lexer.php
define('_db_clase_05', '"test.Clase_05"'); if(is_string($match[0]) && ($match[0][0] == '_') && defined($match[0])) { $aux_val = constant($match[0]); $match[0] = $aux_val; } |
| Comment by Fabio B. Silva [ 22/Feb/12 ] |
|
hello gabriel, I have a pull request opened : https://github.com/doctrine/common/pull/104 feel free to join us and comment ... |
| Comment by Fabio B. Silva [ 15/Mar/12 ] |
|
Fixed : https://github.com/doctrine/common/commit/970912eec0a1371e03de7010556d9280c26d8083 |
[DCOM-83] Rename ComparableInterface Created: 01/Dec/11 Updated: 12/Dec/11 Resolved: 12/Dec/11 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | 2.2 |
| Type: | Improvement | Priority: | Minor |
| Reporter: | Johannes Schmitt | Assignee: | Benjamin Eberlei |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
see https://github.com/doctrine/common/commit/fce661a041aa1dc3634bd1c04cacd684619579fc for reasoning I didn't want to do it myself, don't know what depends on this. |
| Comments |
| Comment by Benjamin Eberlei [ 12/Dec/11 ] |
|
Fixed in 3ee9aea |
[DCOM-100] bad filename for WincacheCahe Created: 02/Jun/12 Updated: 09/Jun/12 Resolved: 09/Jun/12 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | Caching |
| Affects Version/s: | 2.2 |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Minor |
| Reporter: | Vladimír Náprstek | Assignee: | Guilherme Blanco |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
object WincacheCache object resides in file WinCacheCache.php and it confuses autoloading. |
| Comments |
| Comment by Guilherme Blanco [ 09/Jun/12 ] |
|
Fixed in https://github.com/doctrine/common/commit/380ca1d2dcf353a7a768f8086bd0fe05199fbb56 |
[DCOM-15] ClassLoader does not autoload when namespace starts with \ Created: 03/Aug/10 Updated: 01/Sep/10 Resolved: 01/Sep/10 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | Class Loading |
| Affects Version/s: | 2.0.0-BETA2 |
| Fix Version/s: | None |
| Type: | Improvement | Priority: | Minor |
| Reporter: | Bas K | Assignee: | Roman S. Borschel |
| Resolution: | Won't Fix | Votes: | 0 |
| Labels: | None | ||
| Environment: |
osx, php5.3.2 |
||
| Description |
|
Instantiating a fully qualified namespace (with a prefixed ) will not autoload modules, even while the canLoadClass reports it can and loadClass will load it... Will NOT work Will work Some sanitization or an exception on this would improve things a bit. |
| Comments |
| Comment by Roman S. Borschel [ 01/Sep/10 ] |
|
I think this is a non-issue. You need to consider that the first argument is simply a namespace prefix that is checked against and PHP itself never passes class names with leading backslashes to an autoload function. Thus it is relatively obvious that a leading backslash in a namespace prefix for a ClassLoader makes no sense. ps. Leading backslashes in strings in general are unnecessary, as namespaces in strings are always treated as "absolute" and never "relative". That might also be the reason why PHP itself passes class names to autoload functions without a leading backslash. |
[DCOM-11] Impossible to skip annotations Created: 08/Jul/10 Updated: 02/Aug/10 Resolved: 02/Aug/10 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | Annotations |
| Affects Version/s: | 2.0.0-BETA4 |
| Fix Version/s: | 2.0.0-BETA4 |
| Type: | Bug | Priority: | Minor |
| Reporter: | Brandon Turner | Assignee: | Jonathan H. Wage |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Attachments: |
|
| Description |
|
It is currently impossible to skip annotations of the form: When a doc block comment begins with an "@" and has an open parenthesis it is assumed to be an exist annotation even if the corresponding annotation class doesn't exist or can't be autoloaded. If you are trying to use the AnnotationReader on a file, you have to make sure all annotations are loaded or can be autoloaded - even the ones you don't care about In a comment to So, if I want to add my own annotations and store them in a non-autoloader friendly way as Doctrine ORM does, I need to ensure that every AnnotationReader acting on that file knows about my annotations. This is not always possible or desirable. Removing the parenthesis check and relying solely on class_exists fixes this problem. |
| Comments |
| Comment by Tim Nagel [ 15/Jul/10 ] |
|
I have come across another case where this bug causes a fatal PHP Error when you nest a non existant annotation: /**
PHP Fatal error: Doctrine\Common\ClassLoader::loadClass(): Failed opening required 'Doctrine/Tests/Common/Annotations/InnerNonexistant.php' Test case and fix provided in github: http://github.com/merk/common/commit/95388a5febee95dc0483cf35d991b2b227e89069 |
| Comment by Jonathan H. Wage [ 16/Jul/10 ] |
|
Roman, what are your thoughts on this issue? It has been a problem for us with the Symfony integration. |
| Comment by Jonathan H. Wage [ 31/Jul/10 ] |
|
Brandon, can you help me understand better? In your case why is the class not present and why can it not be autoloaded? |
| Comment by Roman S. Borschel [ 31/Jul/10 ] |
|
@"Removing the parenthesis check and relying solely on class_exists fixes this problem." The main problem with such an approach is that an AnnotationReader works (and caches) under the assumption that all annotations of a doc-block are processed at once. That means the "undefined" annotations would never be visible and not accessible if a cache is used unless the cache is cleared and the annotations requested again, this time with all annotations defined. |
| Comment by Brandon Turner [ 31/Jul/10 ] |
|
Let's say I'm writing an extension that supports annotations. I want my extension to work on the same entity classes that Doctrine ORM uses. It is not possible to hook in to the ORM to read my annotations (http://groups.google.com/group/doctrine-dev/browse_thread/thread/4d478a32f8a12a57/c3fce8707becce5c?lnk=gst&q=brandon#c3fce8707becce5c) so I will need to do it with my own code. That is fine, but I've got three problems: 1) When I process my annotations, I have to make sure I load all the annotation classes needed by Doctrine ORM. This is simple and easy. 2) When Doctrine ORM trys to process entities with my custom annotations, it needs to be able to load my extension's annotation classes. How does it know about them (if not autoloading) 3) What happens if someone else writes an extension that uses custom annotations. And say a user wants a single entity to implement my extension, another extension, and of course Doctrine ORM. Now all three need to know about each other. Now we could make all classes able to be autoloaded and that may fix the problem, but Roman recommends against that here: http://www.doctrine-project.org/jira/browse/DCOM-2?focusedCommentId=13070&page=com.atlassian.jira.plugin.system.issuetabpanels%3Acomment-tabpanel#action_13070 So in summary, the annotation class would be present when I process the entity, but not when Doctrine ORM does. |
| Comment by Roman S. Borschel [ 01/Aug/10 ] |
|
After some discussion, the current consensus is that we will apply the suggested change and clearly document how caching works with an AnnotationReader. |
| Comment by Jonathan H. Wage [ 02/Aug/10 ] |
|
Fixed in http://github.com/doctrine/common/commit/5c90f7b513579bf14603621564db6b4da3fd5665 Commit updating the documentation is coming today. |
| Comment by Jonathan H. Wage [ 02/Aug/10 ] |
|
Added docs for annotations here: http://github.com/doctrine/common-documentation/commit/896cc3bace84b6dc891a3d050a425fc99249359e |
[DCOM-197] [GH-280] Typo in MappingException Created: 10/Jun/13 Updated: 10/Jun/13 Resolved: 10/Jun/13 |
|
| Status: | Resolved |
| Project: | Doctrine Common |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Minor |
| Reporter: | Doctrine Bot | Assignee: | Marco Pivetta |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This issue is created automatically through a Github pull request on behalf of halaxa: Url: https://github.com/doctrine/common/pull/280 Message: |
| Comments |
| Comment by Doctrine Bot [ 10/Jun/13 ] |
|
A related Github Pull-Request [GH-280] was closed: |