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

refactor(config): Move configs to components #5460

Merged
merged 4 commits into from
Oct 24, 2022
Merged

Conversation

oxarbitrage
Copy link
Contributor

Motivation

This was inspired by #5436 where there is a broken link and we don't know why.

I am not sure if this will fix the link issue but in my opinion the docs about the config and also the code will be a bit more clear if each Config is where it needs to be.

config

Solution

  • Move the config code to each component (c21d0be) and make needed fixes to make them work that way.
  • Remove trailing slash from zebrad Cargo.toml when importing consensus (68a681e)
  • Remove a doc warning that will be visible when running cargo doc. This is because the code the link is pointing to is behind a rust feature, so i prefer to just remove the link in those cases (5572f74)

Review

I think anyone can review. In regards to the priority i think it can depend, we could want to add it to the new audit tag we are going to do. If so the priority can be medium, low otherwise.

Reviewer Checklist

  • Will the PR name make sense to users?
    • Does it need extra CHANGELOG info? (new features, breaking changes, large changes)
  • Are the PR labels correct?
  • Does the code do what the ticket and PR says?
  • How do you know it works? Does it have tests?

Follow Up Work

@oxarbitrage oxarbitrage requested review from a team as code owners October 21, 2022 21:29
@oxarbitrage oxarbitrage requested review from upbqdn and removed request for a team October 21, 2022 21:29
@codecov
Copy link

codecov bot commented Oct 21, 2022

Codecov Report

Merging #5460 (f889dd6) into main (c1bebea) will increase coverage by 0.13%.
The diff coverage is 96.77%.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #5460      +/-   ##
==========================================
+ Coverage   79.01%   79.14%   +0.13%     
==========================================
  Files         308      309       +1     
  Lines       39279    39325      +46     
==========================================
+ Hits        31035    31125      +90     
+ Misses       8244     8200      -44     

Copy link
Contributor

@teor2345 teor2345 left a comment

Choose a reason for hiding this comment

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

Looks good, just wondering if we can make a submodule to keep a file from getting too big?

What's the priority of this PR?

@teor2345
Copy link
Contributor

I am not sure if this will fix the link issue but in my opinion the docs about the config and also the code will be a bit more clear if each Config is where it needs to be.

Can we build the docs and check if it fixes the links?

@oxarbitrage
Copy link
Contributor Author

Can we build the docs and check if it fixes the links?

I don't think we should spend time doing this right now. Links work locally and making the CI build docs for this PR, push them to the website (https://doc.zebra.zfnd.org) could be hard (i honestly don't know).

The idea here is to make the refactor because i think it is the right thing to do, then when the CI build the docs we can figure out if the link was fixed and close the related issue or keep it open, but we will have the refactor done (which i think we should do anyway).

@teor2345
Copy link
Contributor

Can we build the docs and check if it fixes the links?

I don't think we should spend time doing this right now. Links work locally and making the CI build docs for this PR, push them to the website (https://doc.zebra.zfnd.org) could be hard (i honestly don't know).

The idea here is to make the refactor because i think it is the right thing to do, then when the CI build the docs we can figure out if the link was fixed and close the related issue or keep it open, but we will have the refactor done (which i think we should do anyway).

Sure, that makes sense, let's give it a shot!

mergify bot added a commit that referenced this pull request Oct 24, 2022
@mergify mergify bot merged commit 868ba13 into main Oct 24, 2022
@mergify mergify bot deleted the move-configs-to-components branch October 24, 2022 23:39
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.

3 participants