Skip to content

use try{...}catch(e){...} can crash #27

@GaN8373

Description

@GaN8373

Issue type:

  • 🐛 Bug

Short description:

Steps to reproduce the problem:

use script:

function f1(itemStackElement,networkStackExpr) {
    try {
        for (const element of itemStackElement) {
            let operatorApply = idContext.ops.operatorApply(networkStackExpr, element);
            if (operatorApply < 512) {
                console.log(`Operator Apply: ${operatorApply}`);

                return operatorApply;
            }

        }
    }catch(e) {
        console.log(e);
    }
}

Expected behaviour:


Versions:

  • This mod: 1.0.7-146
  • Minecraft: 1.21.1
  • Mod loader version: neoforge - 21.1.57

Log file:

crash-2024-12-23_00.02.08-server.txt

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    Status

    Done

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions