Skip to content
This repository has been archived by the owner on Nov 15, 2023. It is now read-only.

use proper intra doc link #10271

Merged

Conversation

dharjeezy
Copy link
Contributor

@dharjeezy dharjeezy commented Nov 15, 2021

Use proper intra doc link as mentioned in issue #9962 @thiolliere

Polkadot address: 12ZNas89oEagaxLVNbpqmvfMxdrGrqN7gJKSpwthTUPZsrku

@@ -182,15 +182,15 @@ pub fn expand_outer_origin(
// For backwards compatibility and ease of accessing these functions.
#[allow(dead_code)]
impl Origin {
/// Create with system none origin and `frame-system::Config::BaseCallFilter`.
/// Create with system none origin and [`frame_system::Config::BaseCallFilter`].
Copy link
Member

Choose a reason for hiding this comment

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

You need to use #system_path

Copy link
Contributor Author

@dharjeezy dharjeezy Nov 15, 2021

Choose a reason for hiding this comment

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

Oh... Can you elaborate more what you mean by system_path? @bkchr

Copy link
Member

Choose a reason for hiding this comment

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

@thiolliere already has written this for you: #9962 (comment)

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I actually tried out what @thiolliere suggested, it wasn't outputting the right docs and I ran into errors too

Copy link
Member

Choose a reason for hiding this comment

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

Then you need to fix this.

Copy link
Contributor

Choose a reason for hiding this comment

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

it doesn't work for me, did you tested your PR manually before requesting review ?
PR

Copy link
Contributor Author

Choose a reason for hiding this comment

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

my bad. @thiolliere will push a fix for this

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@thiolliere i have fix this in my latest push. You can check now

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Still awaiting your reviews @thiolliere @bkchr

Copy link
Contributor

Choose a reason for hiding this comment

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

we will review when we get time

@dharjeezy dharjeezy requested a review from bkchr November 17, 2021 22:43
@dharjeezy dharjeezy requested a review from gui1117 November 18, 2021 11:55
Copy link
Contributor

@gui1117 gui1117 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 to me

Copy link
Member

@bkchr bkchr left a comment

Choose a reason for hiding this comment

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

One nitpick, otherwise looks good.

let system_path_name = system_path.module_name();

let doc_string = get_intra_doc_string(
" Origin is always created with the base filter configured in",
Copy link
Member

Choose a reason for hiding this comment

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

Can we please get rid of the leading whitespaces in all these codes.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Alright. Will do

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@bkchr i have done that

Copy link
Member

Choose a reason for hiding this comment

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

Ty

Damilare added 2 commits November 21, 2021 11:01
…-for-macro' into dharjeezy/proper-intra-doc-links-for-macro

# Conflicts:
#	frame/support/procedural/src/construct_runtime/expand/origin.rs
@dharjeezy dharjeezy requested a review from bkchr November 21, 2021 10:05
let system_path_name = system_path.module_name();

let doc_string = get_intra_doc_string(
"Origin is always created with the base filter configured in",
Copy link
Member

Choose a reason for hiding this comment

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

One last question, so this leading whitespace was never needed? I would have thought that you may need to add it in your function below, but there is already one.

I just want to have this clarified and then I'm going to merge this.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yes... The leading whitespace was never needed. You can go ahead and merge

@dharjeezy dharjeezy requested a review from bkchr November 21, 2021 10:50
@bkchr bkchr added B0-silent Changes should not be mentioned in any release notes C1-low PR touches the given topic and has a low impact on builders. D3-trivial 🧸 PR contains trivial changes in a runtime directory that do not require an audit A0-please_review Pull request needs code review. labels Nov 21, 2021
@bkchr bkchr merged commit 541a72f into paritytech:master Nov 21, 2021
@bkchr
Copy link
Member

bkchr commented Nov 21, 2021

/tip small

@substrate-tip-bot
Copy link

Please fix the following problems before calling the tip bot again:

  • Contributor did not properly post their Polkadot or Kusama address. Make sure the pull request has: "{network} address: {address}".

@dharjeezy
Copy link
Contributor Author

I have added my Polkadot address correctly now.
Can you try tipping again.
Thanks @bkchr

@bkchr
Copy link
Member

bkchr commented Nov 21, 2021

/tip small

@substrate-tip-bot
Copy link

A small tip was successfully submitted for dharjeezy (12ZNas89oEagaxLVNbpqmvfMxdrGrqN7gJKSpwthTUPZsrku on polkadot).

https://polkadot.js.org/apps/#/treasury/tips

grishasobol pushed a commit to gear-tech/substrate that referenced this pull request Mar 28, 2022
* use proper intra doc link

* use proper intra doc link

* get system path name from path module name function for the docs

* used format macro in formatting doc string for better output

* helper function to get intra doc string

* helper function to get intra doc string

* use helper function on expand_origin_pallet_conversions

* remove duplicates

* Update frame/support/procedural/src/construct_runtime/expand/origin.rs

Co-authored-by: Guillaume Thiolliere <[email protected]>

* remove leading white space

Co-authored-by: Damilare <[email protected]>
Co-authored-by: Guillaume Thiolliere <[email protected]>
ark0f pushed a commit to gear-tech/substrate that referenced this pull request Feb 27, 2023
* use proper intra doc link

* use proper intra doc link

* get system path name from path module name function for the docs

* used format macro in formatting doc string for better output

* helper function to get intra doc string

* helper function to get intra doc string

* use helper function on expand_origin_pallet_conversions

* remove duplicates

* Update frame/support/procedural/src/construct_runtime/expand/origin.rs

Co-authored-by: Guillaume Thiolliere <[email protected]>

* remove leading white space

Co-authored-by: Damilare <[email protected]>
Co-authored-by: Guillaume Thiolliere <[email protected]>
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
A0-please_review Pull request needs code review. B0-silent Changes should not be mentioned in any release notes C1-low PR touches the given topic and has a low impact on builders. D3-trivial 🧸 PR contains trivial changes in a runtime directory that do not require an audit
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants