Details
-
Type:
Bug
-
Status:
Resolved
-
Priority:
Major
-
Resolution: Invalid
-
Affects Version/s: None
-
Fix Version/s: None
-
Component/s: ORM
-
Security Level: All
-
Labels:None
-
Environment:Doctrine 2.2.2, Symfony 2.0.17
Description
In Symfony I got this exception when I access the page after cleaning the cache:
PHP Fatal error: Uncaught exception 'ReflectionException' with message 'Class integer does not exist' in C:\projects\osl\trunk\vendor\doctrine\lib\Doctrine\ORM\Proxy\ProxyFactory.php:226 Stack trace: #0 C:\projects\osl\trunk\vendor\doctrine\lib\Doctrine\ORM\Proxy\ProxyFactory.php(226): ReflectionParameter->getClass() #1 C:\projects\osl\trunk\vendor\doctrine\lib\Doctrine\ORM\Proxy\ProxyFactory.php(160): Doctrine\ORM\Proxy\ProxyFactory->_generateMethods(Object(Doctrine\ORM\Mapping\ClassMetadata)) #2 C:\projects\osl\trunk\vendor\doctrine\lib\Doctrine\ORM\Proxy\ProxyFactory.php(144): Doctrine\ORM\Proxy\ProxyFactory->_generateProxyClass(Object(Doctrine\ORM\Mapping\ClassMetadata), 'C:/projects/osl...', '<?php??namespac...') #3 C:\projects\osl\trunk\vendor\symfony\src\Symfony\Bridge\Doctrine\CacheWarmer\ProxyCacheWarmer.php(68): Doctrine\ORM\Proxy\ProxyFactory->generateProxyClasses(Array) #4 C:\projects\osl\trunk\vendor\symfony\src\Symfony\Component\HttpKernel\CacheWarmer\CacheWarmerAggregate.php(47): Symfony\Bridge\Doctrine\CacheWa in C:\projects\osl\trunk\vendor\doctrine\lib\Doctrine\ORM\Proxy\ProxyFactory.php on line 226
The reason was a wrong type hint in the setter method of a property:
public function setAdrid(\integer $adrid)
{
$this->adrid = $adrid;
return $this;
}
Is it possible to merge this fix also into 2.2 branch? Or should I do that myself?
I made a pull request on github
https://github.com/doctrine/doctrine2/pull/469
Message:
ProxyFactory: Catch exception if a type hint of an entity's method parameter is invalid and forward the exception with a better readable and more helpful message.
Activity
Christian Stoller
made changes -
| Field | Original Value | New Value |
|---|---|---|
| Environment | Doctrine 2.2.2, Symfony 2.0.17 | |
| Description |
This issue is created automatically through a Github pull request on behalf of naitsirch: Url: https://github.com/doctrine/doctrine2/pull/469 Message: ProxyFactory: Catch exception if a type hint of an entity's method parameter is invalid and forward the exception with a better readable and more helpful message. |
In Symfony I got this exception when I access the page after cleaning the cache:
{code} PHP Fatal error: Uncaught exception 'ReflectionException' with message 'Class integer does not exist' in C:\projects\osl\trunk\vendor\doctrine\lib\Doctrine\ORM\Proxy\ProxyFactory.php:226 Stack trace: #0 C:\projects\osl\trunk\vendor\doctrine\lib\Doctrine\ORM\Proxy\ProxyFactory.php(226): ReflectionParameter->getClass() #1 C:\projects\osl\trunk\vendor\doctrine\lib\Doctrine\ORM\Proxy\ProxyFactory.php(160): Doctrine\ORM\Proxy\ProxyFactory->_generateMethods(Object(Doctrine\ORM\Mapping\ClassMetadata)) #2 C:\projects\osl\trunk\vendor\doctrine\lib\Doctrine\ORM\Proxy\ProxyFactory.php(144): Doctrine\ORM\Proxy\ProxyFactory->_generateProxyClass(Object(Doctrine\ORM\Mapping\ClassMetadata), 'C:/projects/osl...', '<?php??namespac...') #3 C:\projects\osl\trunk\vendor\symfony\src\Symfony\Bridge\Doctrine\CacheWarmer\ProxyCacheWarmer.php(68): Doctrine\ORM\Proxy\ProxyFactory->generateProxyClasses(Array) #4 C:\projects\osl\trunk\vendor\symfony\src\Symfony\Component\HttpKernel\CacheWarmer\CacheWarmerAggregate.php(47): Symfony\Bridge\Doctrine\CacheWa in C:\projects\osl\trunk\vendor\doctrine\lib\Doctrine\ORM\Proxy\ProxyFactory.php on line 226 {code} The reason was a wrong type hint in the setter method of a property: {code} public function setAdrid(\integer $adrid) { $this->adrid = $adrid; return $this; } {code} Is it possible to merge this fix also into 2.2 branch? Or should I do that myself? I made a pull request on github https://github.com/doctrine/doctrine2/pull/469 Message: ProxyFactory: Catch exception if a type hint of an entity's method parameter is invalid and forward the exception with a better readable and more helpful message. |
| Component/s | ORM [ 10012 ] |
Christian Stoller
made changes -
| Comment |
[ In Symfony I got this exception when I access the page after cleaning the cache:
{code} PHP Fatal error: Uncaught exception 'ReflectionException' with message 'Class integer does not exist' in C:\projects\osl\trunk\vendor\doctrine\lib\Doctrine\ORM\Proxy\ProxyFactory.php:226 Stack trace: #0 C:\projects\osl\trunk\vendor\doctrine\lib\Doctrine\ORM\Proxy\ProxyFactory.php(226): ReflectionParameter->getClass() #1 C:\projects\osl\trunk\vendor\doctrine\lib\Doctrine\ORM\Proxy\ProxyFactory.php(160): Doctrine\ORM\Proxy\ProxyFactory->_generateMethods(Object(Doctrine\ORM\Mapping\ClassMetadata)) #2 C:\projects\osl\trunk\vendor\doctrine\lib\Doctrine\ORM\Proxy\ProxyFactory.php(144): Doctrine\ORM\Proxy\ProxyFactory->_generateProxyClass(Object(Doctrine\ORM\Mapping\ClassMetadata), 'C:/projects/osl...', '<?php??namespac...') #3 C:\projects\osl\trunk\vendor\symfony\src\Symfony\Bridge\Doctrine\CacheWarmer\ProxyCacheWarmer.php(68): Doctrine\ORM\Proxy\ProxyFactory->generateProxyClasses(Array) #4 C:\projects\osl\trunk\vendor\symfony\src\Symfony\Component\HttpKernel\CacheWarmer\CacheWarmerAggregate.php(47): Symfony\Bridge\Doctrine\CacheWa in C:\projects\osl\trunk\vendor\doctrine\lib\Doctrine\ORM\Proxy\ProxyFactory.php on line 226 {code} The reason was a wrong type hint in the setter method of a property: {code} public function setAdrid(\integer $adrid) { $this->adrid = $adrid; return $this; } {code} Is it possible to merge this fix also into 2.2 branch? Or should I do that myself? ] |
Benjamin Eberlei
made changes -
| Status | Open [ 1 ] | Resolved [ 5 ] |
| Resolution | Invalid [ 6 ] |
This list may be incomplete, as errors occurred whilst retrieving source from linked applications:
- Request to http://www.doctrine-project.org/fisheye/ failed: Error in remote call to 'FishEye 0 (http://www.doctrine-project.org/fisheye/)' (http://www.doctrine-project.org/fisheye) [AbstractRestCommand{path='/rest-service-fe/search-v1/crossRepositoryQuery', params={query=DDC-2064, expand=changesets[-21:-1].revisions[0:29],reviews}, methodType=GET}] : Received status code 503 (Service Temporarily Unavailable)
Problem will be fixed in refactoring that Marco Pivetta is currently doing.