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

[C4GT] Add extrinsic documentation #443

Open
9 tasks
vatsa287 opened this issue May 7, 2024 · 0 comments
Open
9 tasks

[C4GT] Add extrinsic documentation #443

vatsa287 opened this issue May 7, 2024 · 0 comments
Labels

Comments

@vatsa287
Copy link
Member

vatsa287 commented May 7, 2024

Description

Improve documentation for extrinsics with brief writeup on what it does, parameters it takes, what it returns & errors if emitted.

Goals

  • create
  • vc_create
  • issue
  • vc_issue
  • transfer
  • vc_transfer
  • status_change
  • vc_status_change

Expected Outcome

  • Should have the method documentation in the below format
/// Adds a delegate with the ability to assert new entries to a space.
///
/// The `ASSERT` permission allows the delegate to sign and add new
/// entries within the space. This function is called to grant a
/// delegate this specific permission. It checks that the caller has the
/// necessary authorization (admin rights) to add a delegate to the
/// space. If the caller is authorized, the delegate is added with the
/// `ASSERT` permission using the `space_delegate_addition`
/// internal function.
///
/// # Parameters
/// - `origin`: The origin of the call, which must be signed by an admin of the space.
/// - `space_id`: The identifier of the space to which the delegate is being added.
/// - `delegate`: The identifier of the delegate being added to the space.
/// - `authorization`: The authorization ID used to validate the addition.
///
/// # Returns
/// Returns `Ok(())` if the delegate was successfully added with
/// `ASSERT` permission, or an `Err` with an appropriate error if the
/// operation fails.
///
/// # Errors
/// - `UnauthorizedOperation`: If the caller is not an admin of the space.
/// - Propagates errors from `space_delegate_addition` if it fails.
#[pallet::call_index(0)]
#[pallet::weight(<T as pallet::Config>::WeightInfo::add_delegate())]
pub fn add_delegate(

Story Points

2

Time Constraint

3 Days

Mockups / Wireframes

NA

Implementation Details

Go to file pallets/asset/src/lib.rs and write the documentation.


Product Name

CORD

Organization Name

Dhiway

Domain

Blockchain

Tech Skills Needed

Rust

Mentor(s)

@vatsa287 @amarts @NiranjanAP

Complexity

[Low]

Category

[Documentation]

Sub Category

[Beginner friendly]

NOTE:

Contributors can submit to a part or for all of the required methods.
Assignees will be re-assigned if no PRs are opened after 3 days.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant