1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Not a Bug Errors when using Debug Mode, Beta 4

Discussion in 'Resolved Bug Reports' started by The Dark Wizard, Jul 4, 2013.

  1. The Dark Wizard

    The Dark Wizard Well-Known Member

    All errors appear, like 20+ times, will only paste one of each.

    Template Errors: node_forum_level_2

    1. preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/rpdev/public_html/library/Zend/Filter/PregReplace.php, line 171
    2. preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/rpdev/public_html/library/Zend/Filter/PregReplace.php, line 171
    Template Errors: forum_list
    1. preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/rpdev/public_html/library/Zend/Filter/PregReplace.php, line 171
    2. preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/rpdev/public_html/library/Zend/Filter/PregReplace.php, line 171
    3. preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/rpdev/public_html/library/Zend/Filter/PregReplace.php, line 171
    4. preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/rpdev/public_html/library/Zend/Filter/PregReplace.php, line 171
    5. preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/rpdev/public_html/library/Zend/Filter/PregReplace.php, line 171
    6. preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/rpdev/public_html/library/Zend/Filter/PregReplace.php, line 171
    Template Errors: PAGE_CONTAINER
    1. preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/rpdev/public_html/library/Zend/Filter/PregReplace.php, line 171
    2. preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/rpdev/public_html/library/Zend/Filter/PregReplace.php, line 171
    3. preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/rpdev/public_html/library/Zend/Filter/PregReplace.php, line 171
    4. preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/rpdev/public_html/library/Zend/Filter/PregReplace.php, line 171
    5. preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/rpdev/public_html/library/Zend/Filter/PregReplace.php, line 171
    6. preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/rpdev/public_html/library/Zend/Filter/PregReplace.php, line 171
    7. preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/rpdev/public_html/library/Zend/Filter/PregReplace.php, line 171
    8. preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/rpdev/public_html/library/Zend/Filter/PregReplace.php, line 171
    9. preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/rpdev/public_html/library/Zend/Filter/PregReplace.php, line 171
    10. preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/rpdev/public_html/library/Zend/Filter/PregReplace.php, line 171
    11. preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/rpdev/public_html/library/Zend/Filter/PregReplace.php, line 171
    12. preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /home/rpdev/public_html/library/Zend/Filter/PregReplace.php, line 171
     
  2. Chris D

    Chris D XenForo Developer Staff Member

    Can't reproduce this at all.

    Have you any other details as to when it happens? Is it just when debug mode is enabled? Or is it when you go into the extended debug output?

    Do you have any add-ons installed at all? What if you disable them all, does this make the problem go away?
     
  3. The Dark Wizard

    The Dark Wizard Well-Known Member

    The problem does not go away with addons disabled(I turn them off via config file).

    Also just debug mode enabled.
     
  4. Chris D

    Chris D XenForo Developer Staff Member

    Are you running PHP 5.5?
     
    Jeremy P and pegasus like this.
  5. RoldanLT

    RoldanLT Well-Known Member

  6. pegasus

    pegasus Well-Known Member

    He's not the only one
     
    silence and Jeremy P like this.
  7. MattW

    MattW Well-Known Member

    Where do these errors occur? I'm using PHP 5.5 on my home Ubuntu install, and haven't seen any of them with debug enabled.
     
  8. Mike

    Mike XenForo Developer Staff Member

    This was happening in debug mode in 1.1 for you -- I saw it when debugging that permissions issue.

    It's not something that I've seen or that I can reproduce -- I don't see us using Zend_Filter anywhere. I swore that turning off add-ons via config.php did fix it for me on your site (also part of my debugging process).
     
  9. The Dark Wizard

    The Dark Wizard Well-Known Member

    I have turned off all addons, and you were right. However there is still one error left, even after turning off addons.

    Template Errors: PAGE_CONTAINER
    1. array_key_exists() expects parameter 2 to be array, null given in /home/rpdev/public_html/internal_data/templates/S.79,L.1,PAGE_CONTAINER.php, line 1827
    Any ideas?

    Edit: This is talking about Beta 4 on our Dev environment, by the way. Not our live site. For this new error.
     
  10. The Dark Wizard

    The Dark Wizard Well-Known Member

    Ah. Did not see your post earlier, things have been hectic for me for the past few days(Been having comcast issues . . . )

    The answer to that is yes, however I don't understand how any of this works, and I now tag our system administrator @Ghan_04
     
  11. Chris D

    Chris D XenForo Developer Staff Member

    The left over error after all add-ons disabled would suggest a customised PAGE_CONTAINER template.

    As for the errors that disappeared, you could do with finding out what add-on caused those. That add-on isn't compatible with PHP 5.5.
     
  12. The Dark Wizard

    The Dark Wizard Well-Known Member

    I can try to find out which addon it is by disabling them all one at a time.

    However as for the Page_Container, The default style on our Beta Envirnment has not been touched(Only the custom style we are working on) and they both have it. The page_container for Default is not touched.
     
  13. Mike

    Mike XenForo Developer Staff Member

    It could be any of the templates included by page_container - header, footer, etc.
     
  14. Chris D

    Chris D XenForo Developer Staff Member

    I think to properly debug this:

    1) Go to /install and rebuild master data.
    2) Once complete create a new style with no parent (this will create it from the newly rebuilt master data).
    3) Activate that style and try again.

    If you still get it then, with it being a template error, the error could be caused by a template helper function. A few of them use array_key_exists, but I think ruling out the style is the first step.
     
  15. The Dark Wizard

    The Dark Wizard Well-Known Member

    Found it.

    That helped me figure it out, thanks!
     
  16. The Dark Wizard

    The Dark Wizard Well-Known Member

  17. Adam Howard

    Adam Howard Well-Known Member

    Don't think there is any need for you or anyone else to apologize. Sometimes errors are not so forthcoming, straight forward, or clear; even when you know what to look for.

    Things happen and its best that you attempt to report things, rather than be fearful of "getting it wrong". That's how things don't get fixed.... People worrying that its just then & remaining silent (until a mass release is made & then everyone is affected).

    You honestly thought there was a bug. And you did the right thing in trying to report it. :)
     
    mjda and shenmuee like this.
  18. Robbo

    Robbo Well-Known Member

    Well it is still caused by the packaged XenForo code so you could call it a XenForo bug still. But there could be a lot of bugs like this caused from Zend Framework since it isn't all used obviously. I'll replace my calls to Zend_Filter like requested.
     
  19. Mike

    Mike XenForo Developer Staff Member

    In this case, though, the regex isn't in ZF -- it's passed into the filter. You can still use Zend_Filter, you just can't use /e in PHP 5.5. As such, you'd need need to flip the regex to not use /e (and still use Zend_Filter) or flip to use preg_replace_callback (which isn't supported by the filter).
     
    SneakyDave and Jeremy like this.
  20. Robbo

    Robbo Well-Known Member

    These are still from within Zend though, I convert the criteria rules to camel case so I can call a method per rule, so the call is
    PHP:
    Zend_Filter::filterStatic($rule'Word_UnderscoreToCamelCase')
    . Something I can easily do by replacing underscores with spaces, then call ucwords() then remove the spaces anyway. I should probably not use Zend calls as much as I do because of things like this.
     

Share This Page