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

[MRG] Bunch of Rust refactors #1058

Merged
merged 24 commits into from
Jul 14, 2020
Merged

[MRG] Bunch of Rust refactors #1058

merged 24 commits into from
Jul 14, 2020

Conversation

luizirber
Copy link
Member

@luizirber luizirber commented Jun 28, 2020

(These were in 6 or 7 different branches here, so I'm making a grab bag)

  • Migrate from failure (deprecated) to thiserror
    • Still keep failure around for now, until the .backtrace() support is available. This is useful when debugging FFI.
  • Cache md5sum calculation, which is a huge performance improvement for gather and search
  • remove serde_derive and use the derive feature in serde (small paper cut)
  • Use the nohash-hasher crate instead of the copy-pasted NoHashHasher from finch.
  • Expose a bit more of the API for wasm (signature and ComputeParameters).
  • Bump typed-builder (now that MSRV is 1.37)
  • Add getters and setters for ComputeParameters instead of exposing struct.

TODO

  • actually write a wasm test

Checklist

  • Is it mergeable?
  • make test Did it pass the tests?
  • make coverage Is the new code covered?
  • Did it change the command-line interface? Only additions are allowed
    without a major version increment. Changing file formats also requires a
    major version number increment.
  • Was a spellchecker run on the source code and documentation after
    changes were made?

@codecov
Copy link

codecov bot commented Jun 28, 2020

Codecov Report

Merging #1058 into master will increase coverage by 9.34%.
The diff coverage is n/a.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #1058      +/-   ##
==========================================
+ Coverage   83.94%   93.29%   +9.34%     
==========================================
  Files          99       74      -25     
  Lines        9065     5963    -3102     
==========================================
- Hits         7610     5563    -2047     
+ Misses       1455      400    -1055     
Flag Coverage Δ
#rusttests ?
Impacted Files Coverage Δ
sourmash/sourmash_args.py 95.27% <0.00%> (-0.30%) ⬇️
sourmash/cli/sig/cat.py 100.00% <0.00%> (ø)
src/core/src/from.rs
src/core/src/ffi/mod.rs
src/core/tests/test.rs
src/core/src/ffi/minhash.rs
src/core/src/index/search.rs
src/core/src/ffi/nodegraph.rs
sourmash/sig/__main__.py 96.54% <0.00%> (+3.28%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update c5320b7...fc0eeeb. Read the comment docs.

@luizirber luizirber force-pushed the refactor/thiserror branch 3 times, most recently from 997a5e0 to e03d2e9 Compare July 8, 2020 16:10
@luizirber luizirber force-pushed the refactor/thiserror branch from e03d2e9 to 58bbaac Compare July 11, 2020 01:43
@luizirber luizirber force-pushed the refactor/thiserror branch from 14c56da to 6651c42 Compare July 13, 2020 20:10
@luizirber luizirber changed the title [WIP] Bunch of Rust refactors [MRG] Bunch of Rust refactors Jul 13, 2020
@luizirber
Copy link
Member Author

Ready for review and merge @ctb

Copy link
Contributor

@ctb ctb left a comment

Choose a reason for hiding this comment

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

Nothing in the Python code or UX was changed, and I did a light skim of the Rust code 👍

@luizirber luizirber merged commit 17123ba into master Jul 14, 2020
@luizirber luizirber deleted the refactor/thiserror branch July 14, 2020 00:32
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.

2 participants