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
CMB2_Hookup.php not found #1333
Comments
Well, oops. Yes the file name itself should have been renamed. I’ll get a hot fix pushed tomorrow. |
Hmm interesting. the file-name is correct here. I need to look into svn to see if it doesn't properly register the file-name case. |
Weird. It looks correct in .org SVN too. I wonder if something funky happened when I ran the upgrade on my end? |
Figured it out. Pantheon's workflow is Git-based, so when I updated the plugin and committed the change Git didn't view the filename change as a new file and didn't add it to the commit. |
Ah ok bummer. I did check the WP.org download and the file is properly cased. This is an unfortunate issue, but one I'm not sure we can really fix other than to put it back, and I'm not sure it's worth it. Hoping the developer-savvy audience that this may occur for will know well enough to find the issue, or to find this thread. |
Makes sense. At least now we have this thread for reference. Thanks for the hard work! |
On WordPress.com VIP Go hosting, I also ran into this issue upgrading 2.6.0 to 2.7.0. Automattic's workflow is probably similar to Pantheon's. Am I reading correctly that the fix is to delete the file and then re-add it, so that Git will realize that it is a change and commit it as such? |
Yes, I believe so. |
I just followed this from @galengidman above. Works to get Git to recognize file change. No need to delete and re-add: #1333 (comment) |
@damonsharp it kind of looks like I can do |
@jonathanstegall For me just running |
@jonathanstegall I initially ran |
I find that |
Not sure how this happened to us, but making the file name correct should fix customer issues. Re CMB2/CMB2#1333
Hit this issue as well. CMB2 in my plugin didn't commit the file case change, but |
This is really a nasty issue. I spent 6 hours yesterday to try to find out why metboxes worked in my dev environment on OSX but not in production at OVH. It turned out that CMB2_Hookup.php was still named CMB2_hookup.php. This did not break things on OSX with PHP 7.2 but it did on the OVH server with PHP 7.3. Renaming fixed the problem. I don't know why my file used the old spelling. Maybe because my dev environement is under git? It's annoying when this kind of problem only occurs in the production environment, and I suspect that other people may run into the same problem. Couldn't this particular issue, which is due to the unfortunate old naming of the class file, be resolved in helper-functions/cmb2_autoload_classes? |
@chrilleferna we may be able to put a shim in there to make sure it finds the old file, but it's not something I can easily test, as I don't have that issue on my file-system. Would you be willing to test this theory on your server? |
Yes, I would be happy to test! |
I just had the same problem today with my git workflow, so a shim might be good for others, too. |
Describe the bug
On Pantheon servers (I assume due to server configuration) the following errors are displayed post-2.7 upgrade:
Steps to reproduce (I have confirmed I can reproduce this issue on the
develop
branch):Possible Solution
Appears to be due to #1328 changing the name of the class but not the name of the file itself. Expect changing
CMB2_hookup.php
→CMB2_Hookup.php
would fix.Your Environment
Works = MacOS Valet + Homebrew PHP 7.3.
Broken = Pantheon.
The text was updated successfully, but these errors were encountered: