Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

KCL: More ways to reference paths #4387

Merged
merged 5 commits into from
Nov 5, 2024
Merged

KCL: More ways to reference paths #4387

merged 5 commits into from
Nov 5, 2024

Conversation

adamchalmers
Copy link
Collaborator

@adamchalmers adamchalmers commented Nov 4, 2024

Closes #4382

Copy link

vercel bot commented Nov 4, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Updated (UTC)
modeling-app ✅ Ready (Inspect) Visit Preview Nov 5, 2024 7:17pm

Copy link

qa-wolf bot commented Nov 4, 2024

QA Wolf here! As you write new code it's important that your test coverage is keeping up.
Click here to request test coverage for this PR!

Copy link

codecov bot commented Nov 4, 2024

Codecov Report

Attention: Patch coverage is 81.13208% with 20 lines in your changes missing coverage. Please review.

Project coverage is 86.09%. Comparing base (aceb805) to head (346b44f).

Files with missing lines Patch % Lines
src/wasm-lib/kcl/src/std/segment.rs 77.77% 16 Missing ⚠️
src/wasm-lib/kcl/src/std/args.rs 84.61% 4 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #4387      +/-   ##
==========================================
- Coverage   86.09%   86.09%   -0.01%     
==========================================
  Files          78       78              
  Lines       27755    27829      +74     
==========================================
+ Hits        23897    23959      +62     
- Misses       3858     3870      +12     
Flag Coverage Δ
wasm-lib 86.09% <81.13%> (-0.01%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@adamchalmers adamchalmers changed the title New KCL stdlib function 'segEnd' KCL: More ways to reference paths Nov 4, 2024
@@ -181,47 +181,39 @@ impl Args {
Ok(())
}

fn make_user_val_from_json(&self, j: serde_json::Value) -> Result<KclValue, KclError> {
Ok(KclValue::UserVal(crate::executor::UserVal {
fn make_user_val_from_json(&self, j: serde_json::Value) -> KclValue {
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I realized this function always returned Ok, so I removed the Result wrapper from the return type. That change cascaded through to some other functions.

@adamchalmers adamchalmers merged commit 897205a into main Nov 5, 2024
29 of 30 checks passed
@adamchalmers adamchalmers deleted the achalmers/seg-end-fn branch November 5, 2024 20:10
lf94 pushed a commit that referenced this pull request Nov 5, 2024
Adds new stdlib functions segStart, segStartX, segStartY, segEnd

Part of <#4382>
@franknoirot franknoirot mentioned this pull request Nov 7, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

KCL: More ways to reference points of paths
2 participants