ncaught RangeError: Maximum call stack size exceeded

Hi, I’m having trouble when adding the dhtmlxgrid_math.js, when i add the library the page freezes and you can’t do nothing, I caught the exception with chrome and it says “Uncaught RangeError: Maximum call stack size exceeded”, this is the order of the js files

<script type="text/javascript" src="<?php echo base_url(); ?>dhtmlx/dhtmlx.js"></script>
        <script type="text/javascript" src="<?php echo base_url(); ?>dhtmlx/dhtmlxscheduler.js"></script>
        <script src="<?php echo base_url(); ?>dhtmlx/ext/dhtmlxscheduler_editors.js" type="text/javascript"></script>
        <script src="<?php echo base_url(); ?>dhtmlx/ext/dhtmlxscheduler_minical.js" type="text/javascript"></script>
        <script src="<?php echo base_url(); ?>dhtmlx/ext/dhtmlxscheduler_agenda_view.js" type="text/javascript"></script>
        <script src="<?php echo base_url(); ?>dhtmlx/ext/locale_es.js" type="text/javascript"></script>
        <script src="<?php echo base_url(); ?>dhtmlx/ext/locale_recurring_es.js" type="text/javascript"></script>
        <script src="<?php echo base_url(); ?>dhtmlx/ext/dhtmlxgrid_export.js" type="text/javascript"></script>
        <script src="<?php echo base_url(); ?>dhtmlx/ext/dhtmlxgrid_rowspan.js" type="text/javascript"></script>
<script src="<?php echo base_url(); ?>dhtmlx/ext/dhtmlxgrid_math.js" type="text/javascript"></script>
        <script src="<?php echo base_url(); ?>dhtmlx/excells/dhtmlxgrid_excell_acheck.js" type="text/javascript"></script>

I have tried in different orders and it keeps saying the same thing, I’m using dhtmlxSuite_v35_pro_120822, thanks in advance

Order is not really important ( you need to include extension after main grid files, and must not include the same file two times - that is all )

If issue still occurs - please provide any kind of sample where issue can be reconstructed.

Just in case someone else find this helpful, I was getting this when hooking into some events like so

gantt.attachEvent("onAfterTaskAdd", function (id, item) {
    self._manageTask(item, 'create');
});

In my manage task function I was altering the item.id property and setting it to zero, as that’s what the server-side was expecting as a value for a new task. Unfortunately this was making the gantt chart explode with this error.

The problem is that the “item” is passed by reference down to the this event, and then onto my own function. Altering it’s properties will have unknown issues and should be avoided. I simply cloned the item object and then used it as my data payload.