I found a old report of this bug :
https://bbpress.trac.wordpress.org/ticket/2739
So it’s a known issue. My workaround (manually hacking the str_replace) seems to work so I’ll just manage that until it gets solved.
I dug down into bbpress/includes/core/template-functions.php and inspected a couple of variables there in the enqueue_script call to see what’s going on.
$content_dir (from the constant ‘WP_CONTENT_DIR’) resolves as:
/var/lib/openshift/hexkey/app-root/data/current/wp-content
content_url gives mydomain/wp-content
and the file location starts out as :
/var/lib/openshift/hexkey/app-root/data/plugins/bbpress/templates/default/js/editor.js
So the string replace is going to fail – because that constant content-dir isn’t where you expect it to be – which is maybe something stupid openshift has done. Or goodness knows.
Seems like if I edit this file to trim the “current/wp-content” piece off the content dir location I’ll be in business.
I’m seeing this in WordPress 4.5.3 and bbPress 2.5.10.