New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Better feature detection for DoctrineExtractor #884
Conversation
@dunglas Alot of tests failing, you have an what is going on? |
@kimhemsoe I believe #882 should fix them. |
@alcaeus not totally, I use PHP features that aren't supported by PHP5. I need to take a deeper look |
@dunglas Could you give this another look please? |
Still failing, I'm afraid you will have to rebase. |
@greg0ire This fix should go into 1.10.x, where we still have 5.5. That is unless @doctrine/team-symfony-integration agrees that we can leave this as is for 1.10? |
That would mean red builds on that branch, or dropping php 5 there |
With "as is" I meant "as is in 1.10.x currently", not "as is in this PR". It's probably best to completely fix it in 1.10.x as well though. |
I changed the target branch which makes the build slightly look better. But it seems that the fix still needs some work (see the failing tests). 👍 for me to release 1.10.1 without this PR (and release 1.10.2 once this one is ready). |
Yeah, thought of that as well. Will do 👍 |
@dunglas can you take another look at this please? |
I'll try to take a look asap, unfortunately it's not on top of my todo list right now tbh |
That's fine - I'm just not aware of what the issue is and how to fix it. Maybe @doctrine/team-symfony-integration can advise how to proceed here? |
Does this not just need a rebase now as the travis config has been updated to reflect the new php minimum requirements? I might be wrong but I think I'll try creating a PR with the new travis config and this update and see if it works to help get this resolved. |
Sorry, missed the conversation regarding 1.10.x as well. |
I've just created an alternative PR where tests pass and could be merged to 1.10.x if you think it is acceptable. |
Thanks @silverbackdan - I'll take a look tomorrow. @dunglas maybe you could take a quick look as well? |
After taking a look, I can see why it's not at the top of your todo list. We can't reliably detect whether the Doctrine Bridge is installed in version 4.2 (or newer) by checking features. The check introduced here won't work as there is no parameter type in the The only check I came up with was checking the type hint of the We could use a package like |
How about using this: Something like |
Good catch, that would work. I'll test that later today unless somebody else wants to try it earlier. |
I'm working on a PR, but will not have time to test it :P |
Although it is in the PropertyInfo sub namespace, the DoctrineExtractor class is in the doctrine bridge, which means we should detect the doctrine bridge version and not the PropertyInfo component version. Fixes doctrine#883, Closes doctrine#884
See #917 |
see #918 |
How about an approach where we detect this property: |
This comment has been minimized.
This comment has been minimized.
BTW, I don't really understand your point, @alcaeus :
There is a parameter type… in v 4.1 , and the code in this PR checks that.
This will return true when using v4.1, right? @xabbuh told me the actual issue is with |
Although it is in the PropertyInfo sub namespace, the DoctrineExtractor class is in the doctrine bridge, which means we should detect the doctrine bridge version and not the PropertyInfo component version. Fixes doctrine#883, Closes doctrine#884
I reused #917 for this |
Although it is in the PropertyInfo sub namespace, the DoctrineExtractor class is in the doctrine bridge, which means we should detect the doctrine bridge version and not the PropertyInfo component version. Fixes doctrine#883, Closes doctrine#884
Although it is in the PropertyInfo sub namespace, the DoctrineExtractor class is in the doctrine bridge, which means we should detect the doctrine bridge version and not the PropertyInfo component version. Fixes doctrine#883, Closes doctrine#884
Closing in favour of #917. |
Fixes #883