How to fix the exception like this?

How to fix the exception like this?

beom_gi_l
Not applicable
21 Views
6 Replies
Message 1 of 7

How to fix the exception like this?

beom_gi_l
Not applicable

[ FlexSim 20.1.3 ]

Hi, All.

Sometimes I got the message in the System Console, not every time to run same model.

How to fix? or get the information about cause?


time: 100492.703350 exception: FlexScript exception: MODEL:/Tools/ProcessFlow/OutPort/Custom Code>variables/codeNode

Regrads,

planner

0 Likes
Accepted solutions (1)
22 Views
6 Replies
Replies (6)
Message 2 of 7

jeff_nordgren
Not applicable

Hi @beom_gi.l,

It's hard to know how to help without looking at your model. To receive a more accurate solution, please post your model or a sample model that demonstrates your question.

Proprietary models can be posted as a private question visible only to FlexSim U.S. support staff. You can also contact your local FlexSim distributor for phone or email help.

Thanks.

0 Likes
Message 3 of 7

beom_gi_l
Not applicable

Hi jeff,


Unfortunately, it is impossible to upload the model you mentioned because the security policy of company.


Thanks.

0 Likes
Message 4 of 7

tanner_p
Not applicable
Accepted solution

@beom_gi.l,

If the model can't be posted, then you'll have to debug it yourself. The information below indicates where the problem is:

MODEL:/Tools/ProcessFlow/OutPort/Custom Code

Go to your Custom Code activities and debug them. If there's more than one, I suggest giving them unique names so it's easier to track them. It's likely that there's an error in some of the code. You can use break points to debug the model, which is all we would do to debug something like this. Break points can be inserted by clicking in the area shown in a Custom Code window.

32600-break-points.png

Hope these tools help you solve it!

Message 5 of 7

beom_gi_l
Not applicable

@tanner.p

The other problem in this issue is not occurred regularly when run same model.

Almost run this exception is not occurred. This exception is occurred very rarely.


Thanks.

0 Likes
Message 6 of 7

tanner_p
Not applicable

@beom_gi.l

This makes it a little more tricky to debug. Do you have many Custom Code activities?

You must ensure that all the variables and labels used in each activity exist for every token, otherwise an exception like this may occur. For example, if the Custom Code activity uses a token's "Type" label, and then a token passes through without a "Type" label, the activity will be confused and throw an exception. Same thing if it tries to access an object that has moved or been destroyed.

Check these things and see if they help. I'm afraid that's the most I can offer without seeing the model.

0 Likes
Message 7 of 7

Ben_WilsonADSK
Community Manager
Community Manager

Hi @beom_gi.l, was tanner.p's answer helpful? If so, please click the red "Accept" button on their answer. Or if you still have questions, add a comment and we'll continue the conversation.

If we haven't heard back from you within 3 business days we'll auto-accept an answer, but you can always unaccept and comment back to reopen your question.

0 Likes