Fix to not track operations when loading modules (#6083)
This commit is contained in:
@ -1175,7 +1175,7 @@ impl Node<CallExpressionKw> {
|
|||||||
));
|
));
|
||||||
}
|
}
|
||||||
|
|
||||||
let op = if func.feature_tree_operation() {
|
let op = if func.feature_tree_operation() && !ctx.is_isolated_execution().await {
|
||||||
let op_labeled_args = args
|
let op_labeled_args = args
|
||||||
.kw_args
|
.kw_args
|
||||||
.labeled
|
.labeled
|
||||||
@ -1245,6 +1245,7 @@ impl Node<CallExpressionKw> {
|
|||||||
// exec_state.
|
// exec_state.
|
||||||
let func = fn_name.get_result(exec_state, ctx).await?.clone();
|
let func = fn_name.get_result(exec_state, ctx).await?.clone();
|
||||||
|
|
||||||
|
if !ctx.is_isolated_execution().await {
|
||||||
// Track call operation.
|
// Track call operation.
|
||||||
let op_labeled_args = args
|
let op_labeled_args = args
|
||||||
.kw_args
|
.kw_args
|
||||||
@ -1263,6 +1264,7 @@ impl Node<CallExpressionKw> {
|
|||||||
labeled_args: op_labeled_args,
|
labeled_args: op_labeled_args,
|
||||||
source_range: callsite,
|
source_range: callsite,
|
||||||
});
|
});
|
||||||
|
}
|
||||||
|
|
||||||
let Some(fn_src) = func.as_fn() else {
|
let Some(fn_src) = func.as_fn() else {
|
||||||
return Err(KclError::Semantic(KclErrorDetails {
|
return Err(KclError::Semantic(KclErrorDetails {
|
||||||
@ -1289,8 +1291,10 @@ impl Node<CallExpressionKw> {
|
|||||||
})
|
})
|
||||||
})?;
|
})?;
|
||||||
|
|
||||||
|
if !ctx.is_isolated_execution().await {
|
||||||
// Track return operation.
|
// Track return operation.
|
||||||
exec_state.global.operations.push(Operation::UserDefinedFunctionReturn);
|
exec_state.global.operations.push(Operation::UserDefinedFunctionReturn);
|
||||||
|
}
|
||||||
|
|
||||||
Ok(result)
|
Ok(result)
|
||||||
}
|
}
|
||||||
@ -1327,7 +1331,7 @@ impl Node<CallExpression> {
|
|||||||
));
|
));
|
||||||
}
|
}
|
||||||
|
|
||||||
let op = if func.feature_tree_operation() {
|
let op = if func.feature_tree_operation() && !ctx.is_isolated_execution().await {
|
||||||
let op_labeled_args = func
|
let op_labeled_args = func
|
||||||
.args(false)
|
.args(false)
|
||||||
.iter()
|
.iter()
|
||||||
@ -1385,6 +1389,7 @@ impl Node<CallExpression> {
|
|||||||
// exec_state.
|
// exec_state.
|
||||||
let func = fn_name.get_result(exec_state, ctx).await?.clone();
|
let func = fn_name.get_result(exec_state, ctx).await?.clone();
|
||||||
|
|
||||||
|
if !ctx.is_isolated_execution().await {
|
||||||
// Track call operation.
|
// Track call operation.
|
||||||
exec_state.global.operations.push(Operation::UserDefinedFunctionCall {
|
exec_state.global.operations.push(Operation::UserDefinedFunctionCall {
|
||||||
name: Some(fn_name.to_string()),
|
name: Some(fn_name.to_string()),
|
||||||
@ -1394,6 +1399,7 @@ impl Node<CallExpression> {
|
|||||||
labeled_args: Default::default(),
|
labeled_args: Default::default(),
|
||||||
source_range: callsite,
|
source_range: callsite,
|
||||||
});
|
});
|
||||||
|
}
|
||||||
|
|
||||||
let Some(fn_src) = func.as_fn() else {
|
let Some(fn_src) = func.as_fn() else {
|
||||||
return Err(KclError::Semantic(KclErrorDetails {
|
return Err(KclError::Semantic(KclErrorDetails {
|
||||||
@ -1419,8 +1425,10 @@ impl Node<CallExpression> {
|
|||||||
})
|
})
|
||||||
})?;
|
})?;
|
||||||
|
|
||||||
|
if !ctx.is_isolated_execution().await {
|
||||||
// Track return operation.
|
// Track return operation.
|
||||||
exec_state.global.operations.push(Operation::UserDefinedFunctionReturn);
|
exec_state.global.operations.push(Operation::UserDefinedFunctionReturn);
|
||||||
|
}
|
||||||
|
|
||||||
Ok(result)
|
Ok(result)
|
||||||
}
|
}
|
||||||
|
@ -497,9 +497,13 @@ impl ExecutorContext {
|
|||||||
self.context_type == ContextType::Mock || self.context_type == ContextType::MockCustomForwarded
|
self.context_type == ContextType::Mock || self.context_type == ContextType::MockCustomForwarded
|
||||||
}
|
}
|
||||||
|
|
||||||
|
pub async fn is_isolated_execution(&self) -> bool {
|
||||||
|
self.engine.execution_kind().await.is_isolated()
|
||||||
|
}
|
||||||
|
|
||||||
/// Returns true if we should not send engine commands for any reason.
|
/// Returns true if we should not send engine commands for any reason.
|
||||||
pub async fn no_engine_commands(&self) -> bool {
|
pub async fn no_engine_commands(&self) -> bool {
|
||||||
self.is_mock() || self.engine.execution_kind().await.is_isolated()
|
self.is_mock() || self.is_isolated_execution().await
|
||||||
}
|
}
|
||||||
|
|
||||||
pub async fn send_clear_scene(
|
pub async fn send_clear_scene(
|
||||||
|
@ -2,43 +2,4 @@
|
|||||||
source: kcl-lib/src/simulation_tests.rs
|
source: kcl-lib/src/simulation_tests.rs
|
||||||
description: Operations executed import_function_not_sketch.kcl
|
description: Operations executed import_function_not_sketch.kcl
|
||||||
---
|
---
|
||||||
[
|
[]
|
||||||
{
|
|
||||||
"labeledArgs": {
|
|
||||||
"data": {
|
|
||||||
"value": {
|
|
||||||
"type": "String",
|
|
||||||
"value": "XY"
|
|
||||||
},
|
|
||||||
"sourceRange": []
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"name": "startSketchOn",
|
|
||||||
"sourceRange": [],
|
|
||||||
"type": "StdLibCall",
|
|
||||||
"unlabeledArg": null
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"labeledArgs": {
|
|
||||||
"axis": {
|
|
||||||
"value": {
|
|
||||||
"type": "String",
|
|
||||||
"value": "y"
|
|
||||||
},
|
|
||||||
"sourceRange": []
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"name": "revolve",
|
|
||||||
"sourceRange": [],
|
|
||||||
"type": "StdLibCall",
|
|
||||||
"unlabeledArg": {
|
|
||||||
"value": {
|
|
||||||
"type": "Sketch",
|
|
||||||
"value": {
|
|
||||||
"artifactId": "[uuid]"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"sourceRange": []
|
|
||||||
}
|
|
||||||
}
|
|
||||||
]
|
|
||||||
|
@ -2,86 +2,4 @@
|
|||||||
source: kcl-lib/src/simulation_tests.rs
|
source: kcl-lib/src/simulation_tests.rs
|
||||||
description: Operations executed import_side_effect.kcl
|
description: Operations executed import_side_effect.kcl
|
||||||
---
|
---
|
||||||
[
|
[]
|
||||||
{
|
|
||||||
"labeledArgs": {
|
|
||||||
"data": {
|
|
||||||
"value": {
|
|
||||||
"type": "String",
|
|
||||||
"value": "XY"
|
|
||||||
},
|
|
||||||
"sourceRange": []
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"name": "startSketchOn",
|
|
||||||
"sourceRange": [],
|
|
||||||
"type": "StdLibCall",
|
|
||||||
"unlabeledArg": null
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "UserDefinedFunctionCall",
|
|
||||||
"name": "circle",
|
|
||||||
"functionSourceRange": [
|
|
||||||
0,
|
|
||||||
0,
|
|
||||||
0
|
|
||||||
],
|
|
||||||
"unlabeledArg": null,
|
|
||||||
"labeledArgs": {
|
|
||||||
"center": {
|
|
||||||
"value": {
|
|
||||||
"type": "Array",
|
|
||||||
"value": [
|
|
||||||
{
|
|
||||||
"type": "Number",
|
|
||||||
"value": 0.0,
|
|
||||||
"ty": {
|
|
||||||
"type": "Default",
|
|
||||||
"len": {
|
|
||||||
"type": "Mm"
|
|
||||||
},
|
|
||||||
"angle": {
|
|
||||||
"type": "Degrees"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "Number",
|
|
||||||
"value": 0.0,
|
|
||||||
"ty": {
|
|
||||||
"type": "Default",
|
|
||||||
"len": {
|
|
||||||
"type": "Mm"
|
|
||||||
},
|
|
||||||
"angle": {
|
|
||||||
"type": "Degrees"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"sourceRange": []
|
|
||||||
},
|
|
||||||
"radius": {
|
|
||||||
"value": {
|
|
||||||
"type": "Number",
|
|
||||||
"value": 10.0,
|
|
||||||
"ty": {
|
|
||||||
"type": "Default",
|
|
||||||
"len": {
|
|
||||||
"type": "Mm"
|
|
||||||
},
|
|
||||||
"angle": {
|
|
||||||
"type": "Degrees"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"sourceRange": []
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"sourceRange": []
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "UserDefinedFunctionReturn"
|
|
||||||
}
|
|
||||||
]
|
|
||||||
|
@ -3,66 +3,6 @@ source: kcl-lib/src/simulation_tests.rs
|
|||||||
description: Operations executed multi-axis-robot.kcl
|
description: Operations executed multi-axis-robot.kcl
|
||||||
---
|
---
|
||||||
[
|
[
|
||||||
{
|
|
||||||
"type": "UserDefinedFunctionCall",
|
|
||||||
"name": "sin",
|
|
||||||
"functionSourceRange": [
|
|
||||||
0,
|
|
||||||
0,
|
|
||||||
0
|
|
||||||
],
|
|
||||||
"unlabeledArg": null,
|
|
||||||
"labeledArgs": {},
|
|
||||||
"sourceRange": []
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "UserDefinedFunctionReturn"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "UserDefinedFunctionCall",
|
|
||||||
"name": "cos",
|
|
||||||
"functionSourceRange": [
|
|
||||||
0,
|
|
||||||
0,
|
|
||||||
0
|
|
||||||
],
|
|
||||||
"unlabeledArg": null,
|
|
||||||
"labeledArgs": {},
|
|
||||||
"sourceRange": []
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "UserDefinedFunctionReturn"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "UserDefinedFunctionCall",
|
|
||||||
"name": "sin",
|
|
||||||
"functionSourceRange": [
|
|
||||||
0,
|
|
||||||
0,
|
|
||||||
0
|
|
||||||
],
|
|
||||||
"unlabeledArg": null,
|
|
||||||
"labeledArgs": {},
|
|
||||||
"sourceRange": []
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "UserDefinedFunctionReturn"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "UserDefinedFunctionCall",
|
|
||||||
"name": "cos",
|
|
||||||
"functionSourceRange": [
|
|
||||||
0,
|
|
||||||
0,
|
|
||||||
0
|
|
||||||
],
|
|
||||||
"unlabeledArg": null,
|
|
||||||
"labeledArgs": {},
|
|
||||||
"sourceRange": []
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "UserDefinedFunctionReturn"
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"labeledArgs": {
|
"labeledArgs": {
|
||||||
"data": {
|
"data": {
|
||||||
|
@ -3,36 +3,6 @@ source: kcl-lib/src/simulation_tests.rs
|
|||||||
description: Operations executed pipe-flange-assembly.kcl
|
description: Operations executed pipe-flange-assembly.kcl
|
||||||
---
|
---
|
||||||
[
|
[
|
||||||
{
|
|
||||||
"type": "UserDefinedFunctionCall",
|
|
||||||
"name": "cos",
|
|
||||||
"functionSourceRange": [
|
|
||||||
0,
|
|
||||||
0,
|
|
||||||
0
|
|
||||||
],
|
|
||||||
"unlabeledArg": null,
|
|
||||||
"labeledArgs": {},
|
|
||||||
"sourceRange": []
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "UserDefinedFunctionReturn"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "UserDefinedFunctionCall",
|
|
||||||
"name": "cos",
|
|
||||||
"functionSourceRange": [
|
|
||||||
0,
|
|
||||||
0,
|
|
||||||
0
|
|
||||||
],
|
|
||||||
"unlabeledArg": null,
|
|
||||||
"labeledArgs": {},
|
|
||||||
"sourceRange": []
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "UserDefinedFunctionReturn"
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"type": "UserDefinedFunctionCall",
|
"type": "UserDefinedFunctionCall",
|
||||||
"name": "flange",
|
"name": "flange",
|
||||||
|
@ -349,352 +349,6 @@ description: Operations executed walkie-talkie.kcl
|
|||||||
{
|
{
|
||||||
"type": "UserDefinedFunctionReturn"
|
"type": "UserDefinedFunctionReturn"
|
||||||
},
|
},
|
||||||
{
|
|
||||||
"type": "UserDefinedFunctionCall",
|
|
||||||
"name": "body",
|
|
||||||
"functionSourceRange": [
|
|
||||||
359,
|
|
||||||
2786,
|
|
||||||
6
|
|
||||||
],
|
|
||||||
"unlabeledArg": null,
|
|
||||||
"labeledArgs": {},
|
|
||||||
"sourceRange": []
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"labeledArgs": {
|
|
||||||
"data": {
|
|
||||||
"value": {
|
|
||||||
"type": "Plane",
|
|
||||||
"artifact_id": "[uuid]"
|
|
||||||
},
|
|
||||||
"sourceRange": []
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"name": "startSketchOn",
|
|
||||||
"sourceRange": [],
|
|
||||||
"type": "StdLibCall",
|
|
||||||
"unlabeledArg": null
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"labeledArgs": {
|
|
||||||
"length": {
|
|
||||||
"value": {
|
|
||||||
"type": "Number",
|
|
||||||
"value": 1.0,
|
|
||||||
"ty": {
|
|
||||||
"type": "Default",
|
|
||||||
"len": {
|
|
||||||
"type": "Inches"
|
|
||||||
},
|
|
||||||
"angle": {
|
|
||||||
"type": "Degrees"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"sourceRange": []
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"name": "extrude",
|
|
||||||
"sourceRange": [],
|
|
||||||
"type": "StdLibCall",
|
|
||||||
"unlabeledArg": {
|
|
||||||
"value": {
|
|
||||||
"type": "Sketch",
|
|
||||||
"value": {
|
|
||||||
"artifactId": "[uuid]"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"sourceRange": []
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"labeledArgs": {
|
|
||||||
"length": {
|
|
||||||
"value": {
|
|
||||||
"type": "Number",
|
|
||||||
"value": 0.325,
|
|
||||||
"ty": {
|
|
||||||
"type": "Default",
|
|
||||||
"len": {
|
|
||||||
"type": "Inches"
|
|
||||||
},
|
|
||||||
"angle": {
|
|
||||||
"type": "Degrees"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"sourceRange": []
|
|
||||||
},
|
|
||||||
"tags": {
|
|
||||||
"value": {
|
|
||||||
"type": "Array",
|
|
||||||
"value": [
|
|
||||||
{
|
|
||||||
"type": "Uuid",
|
|
||||||
"value": "[uuid]"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "Uuid",
|
|
||||||
"value": "[uuid]"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "Uuid",
|
|
||||||
"value": "[uuid]"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "Uuid",
|
|
||||||
"value": "[uuid]"
|
|
||||||
}
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"sourceRange": []
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"name": "chamfer",
|
|
||||||
"sourceRange": [],
|
|
||||||
"type": "StdLibCall",
|
|
||||||
"unlabeledArg": {
|
|
||||||
"value": {
|
|
||||||
"type": "Solid",
|
|
||||||
"value": {
|
|
||||||
"artifactId": "[uuid]"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"sourceRange": []
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"labeledArgs": {
|
|
||||||
"data": {
|
|
||||||
"value": {
|
|
||||||
"type": "Solid",
|
|
||||||
"value": {
|
|
||||||
"artifactId": "[uuid]"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"sourceRange": []
|
|
||||||
},
|
|
||||||
"tag": {
|
|
||||||
"value": {
|
|
||||||
"type": "String",
|
|
||||||
"value": "END"
|
|
||||||
},
|
|
||||||
"sourceRange": []
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"name": "startSketchOn",
|
|
||||||
"sourceRange": [],
|
|
||||||
"type": "StdLibCall",
|
|
||||||
"unlabeledArg": null
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "UserDefinedFunctionCall",
|
|
||||||
"name": "cos",
|
|
||||||
"functionSourceRange": [
|
|
||||||
0,
|
|
||||||
0,
|
|
||||||
0
|
|
||||||
],
|
|
||||||
"unlabeledArg": null,
|
|
||||||
"labeledArgs": {},
|
|
||||||
"sourceRange": []
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "UserDefinedFunctionReturn"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "UserDefinedFunctionCall",
|
|
||||||
"name": "cos",
|
|
||||||
"functionSourceRange": [
|
|
||||||
0,
|
|
||||||
0,
|
|
||||||
0
|
|
||||||
],
|
|
||||||
"unlabeledArg": null,
|
|
||||||
"labeledArgs": {},
|
|
||||||
"sourceRange": []
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "UserDefinedFunctionReturn"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "UserDefinedFunctionCall",
|
|
||||||
"name": "cos",
|
|
||||||
"functionSourceRange": [
|
|
||||||
0,
|
|
||||||
0,
|
|
||||||
0
|
|
||||||
],
|
|
||||||
"unlabeledArg": null,
|
|
||||||
"labeledArgs": {},
|
|
||||||
"sourceRange": []
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "UserDefinedFunctionReturn"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "UserDefinedFunctionCall",
|
|
||||||
"name": "cos",
|
|
||||||
"functionSourceRange": [
|
|
||||||
0,
|
|
||||||
0,
|
|
||||||
0
|
|
||||||
],
|
|
||||||
"unlabeledArg": null,
|
|
||||||
"labeledArgs": {},
|
|
||||||
"sourceRange": []
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "UserDefinedFunctionReturn"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"labeledArgs": {
|
|
||||||
"length": {
|
|
||||||
"value": {
|
|
||||||
"type": "Number",
|
|
||||||
"value": -0.0625,
|
|
||||||
"ty": {
|
|
||||||
"type": "Default",
|
|
||||||
"len": {
|
|
||||||
"type": "Inches"
|
|
||||||
},
|
|
||||||
"angle": {
|
|
||||||
"type": "Degrees"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"sourceRange": []
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"name": "extrude",
|
|
||||||
"sourceRange": [],
|
|
||||||
"type": "StdLibCall",
|
|
||||||
"unlabeledArg": {
|
|
||||||
"value": {
|
|
||||||
"type": "Sketch",
|
|
||||||
"value": {
|
|
||||||
"artifactId": "[uuid]"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"sourceRange": []
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"labeledArgs": {
|
|
||||||
"data": {
|
|
||||||
"value": {
|
|
||||||
"type": "Solid",
|
|
||||||
"value": {
|
|
||||||
"artifactId": "[uuid]"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"sourceRange": []
|
|
||||||
},
|
|
||||||
"tag": {
|
|
||||||
"value": {
|
|
||||||
"type": "String",
|
|
||||||
"value": "start"
|
|
||||||
},
|
|
||||||
"sourceRange": []
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"name": "startSketchOn",
|
|
||||||
"sourceRange": [],
|
|
||||||
"type": "StdLibCall",
|
|
||||||
"unlabeledArg": null
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"labeledArgs": {
|
|
||||||
"length": {
|
|
||||||
"value": {
|
|
||||||
"type": "Number",
|
|
||||||
"value": -0.0625,
|
|
||||||
"ty": {
|
|
||||||
"type": "Default",
|
|
||||||
"len": {
|
|
||||||
"type": "Inches"
|
|
||||||
},
|
|
||||||
"angle": {
|
|
||||||
"type": "Degrees"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"sourceRange": []
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"name": "extrude",
|
|
||||||
"sourceRange": [],
|
|
||||||
"type": "StdLibCall",
|
|
||||||
"unlabeledArg": {
|
|
||||||
"value": {
|
|
||||||
"type": "Sketch",
|
|
||||||
"value": {
|
|
||||||
"artifactId": "[uuid]"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"sourceRange": []
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"labeledArgs": {
|
|
||||||
"data": {
|
|
||||||
"value": {
|
|
||||||
"type": "Solid",
|
|
||||||
"value": {
|
|
||||||
"artifactId": "[uuid]"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"sourceRange": []
|
|
||||||
},
|
|
||||||
"tag": {
|
|
||||||
"value": {
|
|
||||||
"type": "String",
|
|
||||||
"value": "start"
|
|
||||||
},
|
|
||||||
"sourceRange": []
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"name": "startSketchOn",
|
|
||||||
"sourceRange": [],
|
|
||||||
"type": "StdLibCall",
|
|
||||||
"unlabeledArg": null
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"labeledArgs": {
|
|
||||||
"length": {
|
|
||||||
"value": {
|
|
||||||
"type": "Number",
|
|
||||||
"value": -0.5,
|
|
||||||
"ty": {
|
|
||||||
"type": "Default",
|
|
||||||
"len": {
|
|
||||||
"type": "Inches"
|
|
||||||
},
|
|
||||||
"angle": {
|
|
||||||
"type": "Degrees"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"sourceRange": []
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"name": "extrude",
|
|
||||||
"sourceRange": [],
|
|
||||||
"type": "StdLibCall",
|
|
||||||
"unlabeledArg": {
|
|
||||||
"value": {
|
|
||||||
"type": "Sketch",
|
|
||||||
"value": {
|
|
||||||
"artifactId": "[uuid]"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"sourceRange": []
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "UserDefinedFunctionReturn"
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"type": "UserDefinedFunctionCall",
|
"type": "UserDefinedFunctionCall",
|
||||||
"name": "antenna",
|
"name": "antenna",
|
||||||
|
@ -3,91 +3,6 @@ source: kcl-lib/src/simulation_tests.rs
|
|||||||
description: Operations executed pattern_circular_in_module.kcl
|
description: Operations executed pattern_circular_in_module.kcl
|
||||||
---
|
---
|
||||||
[
|
[
|
||||||
{
|
|
||||||
"type": "UserDefinedFunctionCall",
|
|
||||||
"name": "thing",
|
|
||||||
"functionSourceRange": [
|
|
||||||
15,
|
|
||||||
378,
|
|
||||||
5
|
|
||||||
],
|
|
||||||
"unlabeledArg": null,
|
|
||||||
"labeledArgs": {},
|
|
||||||
"sourceRange": []
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"labeledArgs": {
|
|
||||||
"data": {
|
|
||||||
"value": {
|
|
||||||
"type": "Plane",
|
|
||||||
"artifact_id": "[uuid]"
|
|
||||||
},
|
|
||||||
"sourceRange": []
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"name": "startSketchOn",
|
|
||||||
"sourceRange": [],
|
|
||||||
"type": "StdLibCall",
|
|
||||||
"unlabeledArg": null
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"labeledArgs": {
|
|
||||||
"length": {
|
|
||||||
"value": {
|
|
||||||
"type": "Number",
|
|
||||||
"value": 1.0,
|
|
||||||
"ty": {
|
|
||||||
"type": "Default",
|
|
||||||
"len": {
|
|
||||||
"type": "Mm"
|
|
||||||
},
|
|
||||||
"angle": {
|
|
||||||
"type": "Degrees"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"sourceRange": []
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"name": "extrude",
|
|
||||||
"sourceRange": [],
|
|
||||||
"type": "StdLibCall",
|
|
||||||
"unlabeledArg": {
|
|
||||||
"value": {
|
|
||||||
"type": "Array",
|
|
||||||
"value": [
|
|
||||||
{
|
|
||||||
"type": "Sketch",
|
|
||||||
"value": {
|
|
||||||
"artifactId": "[uuid]"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "Sketch",
|
|
||||||
"value": {
|
|
||||||
"artifactId": "[uuid]"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "Sketch",
|
|
||||||
"value": {
|
|
||||||
"artifactId": "[uuid]"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "Sketch",
|
|
||||||
"value": {
|
|
||||||
"artifactId": "[uuid]"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"sourceRange": []
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "UserDefinedFunctionReturn"
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"type": "UserDefinedFunctionCall",
|
"type": "UserDefinedFunctionCall",
|
||||||
"name": "thing",
|
"name": "thing",
|
||||||
|
@ -169,175 +169,6 @@ description: Operations executed pattern_linear_in_module.kcl
|
|||||||
"sourceRange": []
|
"sourceRange": []
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
|
||||||
"type": "UserDefinedFunctionReturn"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "UserDefinedFunctionCall",
|
|
||||||
"name": "thing",
|
|
||||||
"functionSourceRange": [
|
|
||||||
15,
|
|
||||||
221,
|
|
||||||
5
|
|
||||||
],
|
|
||||||
"unlabeledArg": null,
|
|
||||||
"labeledArgs": {},
|
|
||||||
"sourceRange": []
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"labeledArgs": {
|
|
||||||
"data": {
|
|
||||||
"value": {
|
|
||||||
"type": "Plane",
|
|
||||||
"artifact_id": "[uuid]"
|
|
||||||
},
|
|
||||||
"sourceRange": []
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"name": "startSketchOn",
|
|
||||||
"sourceRange": [],
|
|
||||||
"type": "StdLibCall",
|
|
||||||
"unlabeledArg": null
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "UserDefinedFunctionCall",
|
|
||||||
"name": "circle",
|
|
||||||
"functionSourceRange": [
|
|
||||||
0,
|
|
||||||
0,
|
|
||||||
0
|
|
||||||
],
|
|
||||||
"unlabeledArg": null,
|
|
||||||
"labeledArgs": {
|
|
||||||
"center": {
|
|
||||||
"value": {
|
|
||||||
"type": "Array",
|
|
||||||
"value": [
|
|
||||||
{
|
|
||||||
"type": "Number",
|
|
||||||
"value": 0.0,
|
|
||||||
"ty": {
|
|
||||||
"type": "Default",
|
|
||||||
"len": {
|
|
||||||
"type": "Mm"
|
|
||||||
},
|
|
||||||
"angle": {
|
|
||||||
"type": "Degrees"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "Number",
|
|
||||||
"value": 0.0,
|
|
||||||
"ty": {
|
|
||||||
"type": "Default",
|
|
||||||
"len": {
|
|
||||||
"type": "Mm"
|
|
||||||
},
|
|
||||||
"angle": {
|
|
||||||
"type": "Degrees"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"sourceRange": []
|
|
||||||
},
|
|
||||||
"radius": {
|
|
||||||
"value": {
|
|
||||||
"type": "Number",
|
|
||||||
"value": 1.0,
|
|
||||||
"ty": {
|
|
||||||
"type": "Default",
|
|
||||||
"len": {
|
|
||||||
"type": "Mm"
|
|
||||||
},
|
|
||||||
"angle": {
|
|
||||||
"type": "Degrees"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"sourceRange": []
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"sourceRange": []
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "UserDefinedFunctionReturn"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"labeledArgs": {
|
|
||||||
"length": {
|
|
||||||
"value": {
|
|
||||||
"type": "Number",
|
|
||||||
"value": 1.0,
|
|
||||||
"ty": {
|
|
||||||
"type": "Default",
|
|
||||||
"len": {
|
|
||||||
"type": "Mm"
|
|
||||||
},
|
|
||||||
"angle": {
|
|
||||||
"type": "Degrees"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"sourceRange": []
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"name": "extrude",
|
|
||||||
"sourceRange": [],
|
|
||||||
"type": "StdLibCall",
|
|
||||||
"unlabeledArg": {
|
|
||||||
"value": {
|
|
||||||
"type": "Array",
|
|
||||||
"value": [
|
|
||||||
{
|
|
||||||
"type": "Sketch",
|
|
||||||
"value": {
|
|
||||||
"artifactId": "[uuid]"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "Sketch",
|
|
||||||
"value": {
|
|
||||||
"artifactId": "[uuid]"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "Sketch",
|
|
||||||
"value": {
|
|
||||||
"artifactId": "[uuid]"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "Sketch",
|
|
||||||
"value": {
|
|
||||||
"artifactId": "[uuid]"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "Sketch",
|
|
||||||
"value": {
|
|
||||||
"artifactId": "[uuid]"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "Sketch",
|
|
||||||
"value": {
|
|
||||||
"artifactId": "[uuid]"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "Sketch",
|
|
||||||
"value": {
|
|
||||||
"artifactId": "[uuid]"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"sourceRange": []
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"type": "UserDefinedFunctionReturn"
|
"type": "UserDefinedFunctionReturn"
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user