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

Turn numalgos into child module of peer_did module #1035

Merged
merged 2 commits into from
Oct 31, 2023

Conversation

Patrik-Stas
Copy link
Contributor

@Patrik-Stas Patrik-Stas commented Oct 28, 2023

  • Turn numalgos to be child model of peer_did. A "numalgo" abstraction doesn't exist outside of peer dids, now this is reflected via the structure itself. It also removes some discrepancy, as we had both src/numalgos and src/peer_did/numalgos

old/new directory structure compared:
image

image

I would further suggest to pull everything in src/peer_did a level up, pulling those files to the root. That will make imports in 3rd party pkgs nicer, is it won't duplicate peer_did token in the import path twice.

Additionally

  • Merge file did_peer/src/peer_did/regex.rs and did_peer/src/peer_did/validate.rs
  • Rename module peer_did_resolver to resolver as the prefix seemed redundant, given we operate in did_peer package
  • Renamed GenericPeerDid to AnyPeerDid - this is bit more speculative and shall this change be accepted, we should probably do the same thing with Connection (perhaps AnyStateConnection instead of GenericConnection. I personally don't like the type name to contain "Generic" as it's makes spoken speech more difficult to understand - easy to confuse someone saying "GenericFoobar" as type GenericFoobar or "Generic Foobar", as in terms of generic, the language feature.

@codecov-commenter
Copy link

codecov-commenter commented Oct 28, 2023

Codecov Report

Merging #1035 (d75475e) into refactor/did_peer (8ed979d) will not change coverage.
The diff coverage is n/a.

@@                Coverage Diff                @@
##           refactor/did_peer   #1035   +/-   ##
=================================================
  Coverage               0.05%   0.05%           
=================================================
  Files                    383     383           
  Lines                  21288   21288           
  Branches                3837    3837           
=================================================
  Hits                      12      12           
  Misses                 21275   21275           
  Partials                   1       1           
Flag Coverage Δ
unittests-aries-vcx 0.05% <ø> (ø)

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

@bobozaur bobozaur merged commit 9f08da7 into refactor/did_peer Oct 31, 2023
@bobozaur bobozaur deleted the restructure/did_peer branch October 31, 2023 09:03
@Patrik-Stas Patrik-Stas restored the restructure/did_peer branch November 1, 2023 11:35
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.

4 participants