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

dev(hansbug): add unpack #80

Merged
merged 1 commit into from
Feb 27, 2023
Merged

dev(hansbug): add unpack #80

merged 1 commit into from
Feb 27, 2023

Conversation

HansBug
Copy link
Member

@HansBug HansBug commented Feb 27, 2023

Description

from treevalue import FastTreeValue

t1 = FastTreeValue({
    'a': 21, 'b': {'x': 'f-49', 'y': 7.7},
})

print(t1.unpack('a', 'b'))
print(t1.b.unpack('x', 'y'))
print(t1.b.unpack('x', 'y', 'z'))  # KeyError
print(t1.b.unpack('x', 'y', 'z', default=None))

Check List

  • merge the latest version source branch/repo, and resolve all the conflicts
  • pass style check
  • pass all the tests

@HansBug HansBug self-assigned this Feb 27, 2023
@codecov
Copy link

codecov bot commented Feb 27, 2023

Codecov Report

Merging #80 (28c99a4) into main (b61551a) will increase coverage by 0.00%.
The diff coverage is 100.00%.

@@           Coverage Diff           @@
##             main      #80   +/-   ##
=======================================
  Coverage   98.95%   98.95%           
=======================================
  Files          39       39           
  Lines        2578     2587    +9     
=======================================
+ Hits         2551     2560    +9     
  Misses         27       27           
Flag Coverage Δ
unittests 98.95% <100.00%> (+<0.01%) ⬆️

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

Impacted Files Coverage Δ
treevalue/tree/tree/tree.pyx 99.30% <100.00%> (+0.02%) ⬆️

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

@HansBug HansBug merged commit ac90658 into main Feb 27, 2023
@HansBug HansBug deleted the dev/unpack branch February 27, 2023 10:18
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.

1 participant