Skip to content

Commit

Permalink
docs: fix dead links
Browse files Browse the repository at this point in the history
  • Loading branch information
julienrbrt committed Nov 7, 2024
1 parent 028730a commit a19a3fd
Show file tree
Hide file tree
Showing 14 changed files with 99 additions and 103 deletions.
4 changes: 0 additions & 4 deletions contributing.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,6 @@ Before submitting a PR to the Ignite CLI repository, please review and follow th

If you have suggestions or want to propose changes to these guidelines, start a new [Discussion topic](https://github.com/ignite/cli/discussions/new) to gather feedback.

For setup instructions, see [Set Up Your Ignite CLI Development Environment](dev-env-setup.md).

To contribute to docs and tutorials, see [Contributing to Ignite CLI Docs](https://docs.ignite.com/contributing).

We appreciate your contribution!
Expand Down Expand Up @@ -120,8 +118,6 @@ We use Git Flow as our branch strategy, with each MAJOR release linked to a mile
- **Next Milestone:**
The **Next** milestone is used for issues or features that are not tied to a specific release but are still relevant to the project’s roadmap. These issues will be addressed when higher-priority work has been completed, or as part of future planning.

Check the [project board](https://github.com/ignite/cli/projects/7) to see what we're working on and what’s planned.

## Issue Title Conventions and Labeling

To maintain consistency across issues and PRs, follow these guidelines for issue titles:
Expand Down
172 changes: 86 additions & 86 deletions docs/docs/02-guide/04-ibc.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ end-to-end, connection-oriented, stateful protocol provides reliable, ordered,
and authenticated communication between heterogeneous blockchains.

The [IBC protocol in the Cosmos
SDK](https://ibc.cosmos.network/main/ibc/overview.html) is the standard for the
SDK](https://ibc.cosmos.network/main/ibc/overview) is the standard for the
interaction between two blockchains. The IBCmodule interface defines how packets
and messages are constructed to be interpreted by the sending and the receiving
blockchain.
Expand Down Expand Up @@ -223,48 +223,48 @@ the `msg.Creator` value to the IBC `packet`.
package keeper

func (k msgServer) SendIbcPost(goCtx context.Context, msg *types.MsgSendIbcPost) (*types.MsgSendIbcPostResponse, error) {
// validate incoming message
if _, err := k.addressCodec.StringToBytes(msg.Creator); err != nil {
return nil, errorsmod.Wrap(sdkerrors.ErrInvalidAddress, fmt.Sprintf("invalid address: %s", err))
}

if msg.Port == "" {
return nil, errorsmod.Wrap(sdkerrors.ErrInvalidRequest, "invalid packet port")
}

if msg.ChannelID == "" {
return nil, errorsmod.Wrap(sdkerrors.ErrInvalidRequest, "invalid packet channel")
}

if msg.TimeoutTimestamp == 0 {
return nil, errorsmod.Wrap(sdkerrors.ErrInvalidRequest, "invalid packet timeout")
}

// TODO: logic before transmitting the packet

// Construct the packet
var packet types.IbcPostPacketData

packet.Title = msg.Title
packet.Content = msg.Content
// highlight-next-line
packet.Creator = msg.Creator

// Transmit the packet
ctx := sdk.UnwrapSDKContext(goCtx)
_, err := k.TransmitIbcPostPacket(
ctx,
packet,
msg.Port,
msg.ChannelID,
clienttypes.ZeroHeight(),
msg.TimeoutTimestamp,
)
if err != nil {
return nil, err
}

return &types.MsgSendIbcPostResponse{}, nil
// validate incoming message
if _, err := k.addressCodec.StringToBytes(msg.Creator); err != nil {
return nil, errorsmod.Wrap(sdkerrors.ErrInvalidAddress, fmt.Sprintf("invalid address: %s", err))
}

if msg.Port == "" {
return nil, errorsmod.Wrap(sdkerrors.ErrInvalidRequest, "invalid packet port")
}

if msg.ChannelID == "" {
return nil, errorsmod.Wrap(sdkerrors.ErrInvalidRequest, "invalid packet channel")
}

if msg.TimeoutTimestamp == 0 {
return nil, errorsmod.Wrap(sdkerrors.ErrInvalidRequest, "invalid packet timeout")
}

// TODO: logic before transmitting the packet

// Construct the packet
var packet types.IbcPostPacketData

packet.Title = msg.Title
packet.Content = msg.Content
// highlight-next-line
packet.Creator = msg.Creator

// Transmit the packet
ctx := sdk.UnwrapSDKContext(goCtx)
_, err := k.TransmitIbcPostPacket(
ctx,
packet,
msg.Port,
msg.ChannelID,
clienttypes.ZeroHeight(),
msg.TimeoutTimestamp,
)
if err != nil {
return nil, err
}

return &types.MsgSendIbcPostResponse{}, nil
}
```

Expand Down Expand Up @@ -315,11 +315,11 @@ Then modify the `OnRecvIbcPostPacket` keeper function with the following code:
package keeper

func (k Keeper) OnRecvIbcPostPacket(ctx sdk.Context, packet channeltypes.Packet, data types.IbcPostPacketData) (packetAck types.IbcPostPacketAck, err error) {
packetAck.PostId, err = k.PostSeq.Next(ctx)
if err != nil {
return packetAck, err
}
return packetAck, k.Post.Set(ctx, packetAck.PostId, types.Post{Title: data.Title, Content: data.Content})
packetAck.PostId, err = k.PostSeq.Next(ctx)
if err != nil {
return packetAck, err
}
return packetAck, k.Post.Set(ctx, packetAck.PostId, types.Post{Title: data.Title, Content: data.Content})
}
```

Expand All @@ -339,33 +339,33 @@ from the packet.
package keeper

func (k Keeper) OnAcknowledgementIbcPostPacket(ctx sdk.Context, packet channeltypes.Packet, data types.IbcPostPacketData, ack channeltypes.Acknowledgement) error {
switch dispatchedAck := ack.Response.(type) {
case *channeltypes.Acknowledgement_Error:
// We will not treat acknowledgment error in this tutorial
return nil
case *channeltypes.Acknowledgement_Result:
// Decode the packet acknowledgment
var packetAck types.IbcPostPacketAck
if err := types.ModuleCdc.UnmarshalJSON(dispatchedAck.Result, &packetAck); err != nil {
// The counter-party module doesn't implement the correct acknowledgment format
return errors.New("cannot unmarshal acknowledgment")
}

seq, err := k.SentPostSeq.Next(ctx)
if err != nil {
return err
}

return k.SentPost.Set(ctx, seq,
types.SentPost{
PostId: packetAck.PostId,
Title: data.Title,
Chain: packet.DestinationPort + "-" + packet.DestinationChannel,
},
)
default:
return errors.New("the counter-party module does not implement the correct acknowledgment format")
}
switch dispatchedAck := ack.Response.(type) {
case *channeltypes.Acknowledgement_Error:
// We will not treat acknowledgment error in this tutorial
return nil
case *channeltypes.Acknowledgement_Result:
// Decode the packet acknowledgment
var packetAck types.IbcPostPacketAck
if err := types.ModuleCdc.UnmarshalJSON(dispatchedAck.Result, &packetAck); err != nil {
// The counter-party module doesn't implement the correct acknowledgment format
return errors.New("cannot unmarshal acknowledgment")
}

seq, err := k.SentPostSeq.Next(ctx)
if err != nil {
return err
}

return k.SentPost.Set(ctx, seq,
types.SentPost{
PostId: packetAck.PostId,
Title: data.Title,
Chain: packet.DestinationPort + "-" + packet.DestinationChannel,
},
)
default:
return errors.New("the counter-party module does not implement the correct acknowledgment format")
}
}
```

Expand All @@ -376,17 +376,17 @@ posts. This logic follows the same format as `sentPost`.

```go title="x/blog/keeper/ibc_post.go"
func (k Keeper) OnTimeoutIbcPostPacket(ctx sdk.Context, packet channeltypes.Packet, data types.IbcPostPacketData) error {
seq, err := k.TimeoutPostSeq.Next(ctx)
if err != nil {
return err
}

return k.TimeoutPost.Set(ctx, seq,
types.TimeoutPost{
Title: data.Title,
Chain: packet.DestinationPort + "-" + packet.DestinationChannel,
},
)
seq, err := k.TimeoutPostSeq.Next(ctx)
if err != nil {
return err
}

return k.TimeoutPost.Set(ctx, seq,
types.TimeoutPost{
Title: data.Title,
Chain: packet.DestinationPort + "-" + packet.DestinationChannel,
},
)
}
```

Expand Down
2 changes: 1 addition & 1 deletion docs/docs/06-migration/v0.24.0.md
Original file line number Diff line number Diff line change
Expand Up @@ -193,7 +193,7 @@ If you have IBC-enabled modules (for example, added with `ignite scaffold module
the following changes to the source code.

Cosmos SDK expects IBC modules
to [implement the `IBCModule` interface](https://ibc.cosmos.network/main/ibc/apps/ibcmodule.html). Create a `IBCModule`
to [implement the `IBCModule` interface](https://ibc.cosmos.network/main/ibc/apps/ibcmodule/). Create a `IBCModule`
type that embeds the module's keeper and a method that returns a new `IBCModule`. Methods in this file will be defined
on this type.

Expand Down
2 changes: 1 addition & 1 deletion docs/versioned_docs/version-v0.25/06-bounty.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ description: Ignite CLI bounty program incentives and rewards.

Our Ignite CLI bounty program provides incentives for your participation and pays rewards. If you know Golang, follow the bounty issues, write code, close issues, and get rewarded.

Do your bounty hunting in our repo. Track new, in-progress, and completed bounties on the [Bounty board](https://github.com/ignite/cli/projects/5) in GitHub.
Do your bounty hunting in our repo. Track new, in-progress, and completed bounties in the [GitHub Issues](https://github.com/ignite/cli/issues?q=is%3Aissue+is%3Aopen+label%3Abounty).

For details on the Ignite CLI bounty program, join the #bounty channel in [Ignite Discord](https://discord.com/invite/ignite).

Expand Down
2 changes: 1 addition & 1 deletion docs/versioned_docs/version-v0.25/guide/07-ibc.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ The Inter-Blockchain Communication protocol (IBC) is an important part of the Co

The Inter-Blockchain Communication protocol (IBC) allows blockchains to talk to each other. IBC handles transport across different sovereign blockchains. This end-to-end, connection-oriented, stateful protocol provides reliable, ordered, and authenticated communication between heterogeneous blockchains.

The [IBC protocol in the Cosmos SDK](https://ibc.cosmos.network/main/ibc/overview.html) is the standard for the interaction between two blockchains. The IBCmodule interface defines how packets and messages are constructed to be interpreted by the sending and the receiving blockchain.
The [IBC protocol in the Cosmos SDK](https://ibc.cosmos.network/main/ibc/overview) is the standard for the interaction between two blockchains. The IBCmodule interface defines how packets and messages are constructed to be interpreted by the sending and the receiving blockchain.

The IBC relayer lets you connect between sets of IBC-enabled chains. This tutorial teaches you how to create two blockchains and then start and use the relayer with Ignite CLI to connect two blockchains.

Expand Down
2 changes: 1 addition & 1 deletion docs/versioned_docs/version-v0.25/kb/04-genesis.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ genesis:

## Genesis file

For genesis file details and field definitions, see Cosmos Hub documentation for the [Genesis File](https://hub.cosmos.network/resources/genesis).
For genesis file details and field definitions, see Cosmos Hub documentation for the [Genesis File](https://hub.cosmos.network/main/resources/genesis).

## Genesis block summary

Expand Down
2 changes: 1 addition & 1 deletion docs/versioned_docs/version-v0.25/migration/v0.24.0.md
Original file line number Diff line number Diff line change
Expand Up @@ -193,7 +193,7 @@ If you have IBC-enabled modules (for example, added with `ignite scaffold module
the following changes to the source code.

Cosmos SDK expects IBC modules
to [implement the `IBCModule` interface](https://ibc.cosmos.network/main/ibc/apps/ibcmodule.html). Create a `IBCModule`
to [implement the `IBCModule` interface](https://ibc.cosmos.network/main/ibc/apps/ibcmodule/). Create a `IBCModule`
type that embeds the module's keeper and a method that returns a new `IBCModule`. Methods in this file will be defined
on this type.

Expand Down
2 changes: 1 addition & 1 deletion docs/versioned_docs/version-v0.26/02-guide/06-ibc.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ end-to-end, connection-oriented, stateful protocol provides reliable, ordered,
and authenticated communication between heterogeneous blockchains.

The [IBC protocol in the Cosmos
SDK](https://ibc.cosmos.network/main/ibc/overview.html) is the standard for the
SDK](https://ibc.cosmos.network/main/ibc/overview) is the standard for the
interaction between two blockchains. The IBCmodule interface defines how packets
and messages are constructed to be interpreted by the sending and the receiving
blockchain.
Expand Down
2 changes: 1 addition & 1 deletion docs/versioned_docs/version-v0.26/06-migration/v0.24.0.md
Original file line number Diff line number Diff line change
Expand Up @@ -193,7 +193,7 @@ If you have IBC-enabled modules (for example, added with `ignite scaffold module
the following changes to the source code.

Cosmos SDK expects IBC modules
to [implement the `IBCModule` interface](https://ibc.cosmos.network/main/ibc/apps/ibcmodule.html). Create a `IBCModule`
to [implement the `IBCModule` interface](https://ibc.cosmos.network/main/ibc/apps/ibcmodule/). Create a `IBCModule`
type that embeds the module's keeper and a method that returns a new `IBCModule`. Methods in this file will be defined
on this type.

Expand Down
2 changes: 1 addition & 1 deletion docs/versioned_docs/version-v0.27/02-guide/06-ibc.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ end-to-end, connection-oriented, stateful protocol provides reliable, ordered,
and authenticated communication between heterogeneous blockchains.

The [IBC protocol in the Cosmos
SDK](https://ibc.cosmos.network/main/ibc/overview.html) is the standard for the
SDK](https://ibc.cosmos.network/main/ibc/overview) is the standard for the
interaction between two blockchains. The IBCmodule interface defines how packets
and messages are constructed to be interpreted by the sending and the receiving
blockchain.
Expand Down
2 changes: 1 addition & 1 deletion docs/versioned_docs/version-v0.27/06-migration/v0.24.0.md
Original file line number Diff line number Diff line change
Expand Up @@ -193,7 +193,7 @@ If you have IBC-enabled modules (for example, added with `ignite scaffold module
the following changes to the source code.

Cosmos SDK expects IBC modules
to [implement the `IBCModule` interface](https://ibc.cosmos.network/main/ibc/apps/ibcmodule.html). Create a `IBCModule`
to [implement the `IBCModule` interface](https://ibc.cosmos.network/main/ibc/apps/ibcmodule/). Create a `IBCModule`
type that embeds the module's keeper and a method that returns a new `IBCModule`. Methods in this file will be defined
on this type.

Expand Down
2 changes: 1 addition & 1 deletion docs/versioned_docs/version-v28/02-guide/06-ibc.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ end-to-end, connection-oriented, stateful protocol provides reliable, ordered,
and authenticated communication between heterogeneous blockchains.

The [IBC protocol in the Cosmos
SDK](https://ibc.cosmos.network/main/ibc/overview.html) is the standard for the
SDK](https://ibc.cosmos.network/main/ibc/overview) is the standard for the
interaction between two blockchains. The IBCmodule interface defines how packets
and messages are constructed to be interpreted by the sending and the receiving
blockchain.
Expand Down
2 changes: 1 addition & 1 deletion docs/versioned_docs/version-v28/06-migration/v0.24.0.md
Original file line number Diff line number Diff line change
Expand Up @@ -193,7 +193,7 @@ If you have IBC-enabled modules (for example, added with `ignite scaffold module
the following changes to the source code.

Cosmos SDK expects IBC modules
to [implement the `IBCModule` interface](https://ibc.cosmos.network/main/ibc/apps/ibcmodule.html). Create a `IBCModule`
to [implement the `IBCModule` interface](https://ibc.cosmos.network/main/ibc/apps/ibcmodule/). Create a `IBCModule`
type that embeds the module's keeper and a method that returns a new `IBCModule`. Methods in this file will be defined
on this type.

Expand Down
4 changes: 2 additions & 2 deletions readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -253,8 +253,8 @@ create a pull request, or maintain your own fork and submit a cross-repository
pull request.

Our Ignite CLI bounty program provides incentives for your participation and
pays rewards. Track new, in-progress, and completed bounties on the [Bounty
board](https://github.com/ignite/cli/projects/5) in GitHub.
pays rewards. Track new, in-progress, and completed bounties in the [GitHub Issues
board](https://github.com/ignite/cli/issues?q=is%3Aissue+is%3Aopen+label%3Abounty).

**Important** Before you start implementing a new Ignite CLI feature, the first
step is to create an issue on GitHub that describes the proposed changes.
Expand Down

0 comments on commit a19a3fd

Please sign in to comment.