# S-S Scripting broken

**URL:** <https://community.dreamfactory.com/t/s-s-scripting-broken/701>\
**Category:** Server-Side Scripting\
**Created:** [December 27, 2014, 11:48pm UTC](https://community.dreamfactory.com/t/s-s-scripting-broken/701 "2014-12-27T23:48:59Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![rbleeker](https://yyz1.discourse-cdn.com/flex035/user_avatar/community.dreamfactory.com/rbleeker/32/192_2.png) [@rbleeker](https://community.dreamfactory.com/u/rbleeker)\
**Post date:** [December 27, 2014, 11:48pm UTC](https://community.dreamfactory.com/t/s-s-scripting-broken/701/1 "2014-12-27T23:48:59Z")

</div>

Seems that on my instance of DSP any attempt on server-side scripting breaks.  
Even adding a single line comment breaks the relevant calls.  
Anybody seen this before, could it be install related or script engine related?

---

<div class="post-metadata">

**Author:** ![jeffreystables](https://yyz1.discourse-cdn.com/flex035/user_avatar/community.dreamfactory.com/jeffreystables/32/173_2.png) [@jeffreystables](https://community.dreamfactory.com/u/jeffreystables)\
**Post date:** [December 29, 2014, 3:58pm UTC](https://community.dreamfactory.com/t/s-s-scripting-broken/701/2 "2014-12-29T15:58:07Z")

</div>

I have not seen this before, @rbleeker. Could you provide us some more details?

1. Was scripting working previously, but now whenever you modify a script it breaks?
2. What error or other behavior are you seeing when it breaks? What is logged in your `web.*.log` file (found in `/htdocs/log/`) when it breaks?
3. What steps can we take to replicate this behavior? What environment are you using so that we may replicate that too?

---

<div class="post-metadata">

**Author:** ![rbleeker](https://yyz1.discourse-cdn.com/flex035/user_avatar/community.dreamfactory.com/rbleeker/32/192_2.png) [@rbleeker](https://community.dreamfactory.com/u/rbleeker)\
**Post date:** [December 30, 2014, 8:48am UTC](https://community.dreamfactory.com/t/s-s-scripting-broken/701/3 "2014-12-30T08:48:28Z")

</div>

Hi @jeffreystables,

It sounds a similar issue to this: [get system user crashes swagger](https://community.dreamfactory.com/t/custom-script-calling-get-system-user-api-crashes-swagger-fails/670 "get system user crashes swagger")

1. Didn’t work for me at any stage. Tried re-installing DSP (1.8.2) several times, on brand new instances of Ubuntu14.04, 14.10, and now on Debian 7.7. No difference, system works fine until I add any text to a Server-Side script… I do mean it breaks only the Server-Side script associated calls. It breaks both the online and iOS API calls. Tried the both DSP ios-sdk and AFNetworking classes in the native iOS app.

2. I add a single comment “//hello” (or anything at all without the quotes) in a GET pre-processor (same issues for pre & post), then make a call with the associated GET API “db.bsoc\_applaunch.get” (using online interface as it’s easiest to test) just to get a list of records, then it thinks for a while and reloads the API doc’s iframe with a error’ed copy of the DSP site (or part of the site). See log extract below.

3. probably already explained in 1 &2 above.

Main culprit seems to point to V8Js.php???

## LOG EXTRACT: [2014-12-30 08:04:46][app][ERROR] REST Exception #404 \> “db.bsoc\_applaunch.get.pre\_process” was not found. {“host”:“[MYDOMAIN.info](http://MYDOMAIN.info)”,"req$ [2014-12-30 08:04:51][app][ERROR] \* System error deleting swagger cache file: portal.json [2014-12-30 08:04:51][app][INFO] Building Swagger cache [2014-12-30 08:04:51][app][DEBUG] \* Discovered 17 event(s). [2014-12-30 08:04:51][app][DEBUG] \* Discovered 82 event(s). [2014-12-30 08:04:51][app][DEBUG] \* Discovered 73 event(s). [2014-12-30 08:04:51][app][DEBUG] \* Discovered 1 event(s). [2014-12-30 08:04:51][app][DEBUG] \* Discovered 30 event(s). [2014-12-30 08:04:51][app][INFO] \* No Swagger content found for service “portal” [2014-12-30 08:04:51][app][INFO] Swagger cache build process complete [2014-12-30 08:04:51][app][DEBUG] Dispatcher: event “swagger.cache\_rebuilt” triggered by /system/script/db.bsoc\_applaunch.get.pre\_proces$ [2014-12-30 08:04:55][app][ERROR] exception ‘CHttpException’ with message ‘Unable to resolve the request “admin/{{iframeUrl}}”.’ in /opt$ Stack trace: 0 /opt/dreamfactory/platform/vendor/dreamfactory/yii/framework/yiilite.php(1665): CWebApplication-\>runController(‘admin/{{iframeU…’) 1 /opt/dreamfactory/platform/vendor/dreamfactory/yii/framework/yiilite.php(1190): CWebApplication-\>processRequest() 2 /opt/dreamfactory/platform/vendor/dreamfactory/lib-php-common-yii/src/Utility/Pii.php(218): CApplication-\>run() 3 /opt/dreamfactory/platform/web/index.php(69): DreamFactory\Yii\Utility\Pii::run(’/opt/dreamfacto…’, Object(Composer\Autoload\ClassLoade$ 4 {main} REQUEST\_URI=/admin/%7B%7BiframeUrl%7D%7D HTTP\_REFERER=http://MYDOMAIN.info/admin/

[2014-12-30 08:05:22][app][ERROR] include(V8Js.php): failed to open stream: No such file or directory (/opt/dreamfactory/platform/vendor$  
Stack trace:  
0 unknown(0): spl\_autoload\_call()  
1 /opt/dreamfactory/platform/vendor/dreamfactory/lib-php-common-platform/src/Scripting/ScriptEngine.php(193): ReflectionClass-\>\_\_construct()  
2 - 28 … removed for space  
REQUEST\_URI=/rest/db/bsoc\_applaunch

---

<div class="post-metadata">

**Author:** ![rbleeker](https://yyz1.discourse-cdn.com/flex035/user_avatar/community.dreamfactory.com/rbleeker/32/192_2.png) [@rbleeker](https://community.dreamfactory.com/u/rbleeker)\
**Post date:** [December 30, 2014, 9:43am UTC](https://community.dreamfactory.com/t/s-s-scripting-broken/701/4 "2014-12-30T09:43:34Z")

</div>

Hi, following up more on the V8Js error, I found some previous mention about this missing library from the git install of DSP.

Found the linked article on how to install the V8Js library: [Installing-V8js](https://github.com/dreamfactorysoftware/dsp-core/wiki/Installing-V8js)

I stumbled my way though the instructions and got it installed, did have to adjust a missing directory path error but with a little ‘ls’ directory searching I found what file was trying to be copied.

I haven’t tried a full Server-Side script yet, but at least it doesn’t break with the simple comment text in the pre-process script.

Tomorrow I will test a full script, but expect it to be fine now… fingers crossed.

Thanks @jeffreystables for prompting me to dig a little more in the error logs 😄
