Skip to content

Commit

Permalink
Updated the content and the links due to mono repo changes. (#2050)
Browse files Browse the repository at this point in the history
* updated build process file.

* Updated the content due to mono repo changes.

* Updated the content due to mono repo changes.

* monorepo changes - updated links

* Updated links in the files, mono repo updates.

* Update content/md/en/docs/build/remote-procedure-calls.md

Co-authored-by: Kevin Krone <[email protected]>

* Update content/md/en/docs/learn/accounts-addresses-keys.md

Co-authored-by: Kevin Krone <[email protected]>

* Update content/md/en/docs/maintain/runtime-upgrades.md

Co-authored-by: Kevin Krone <[email protected]>

* Update content/md/en/docs/reference/command-line-tools/srtool.md

Co-authored-by: Kevin Krone <[email protected]>

* Update content/md/en/docs/reference/glossary.md

Co-authored-by: Kevin Krone <[email protected]>

* Update content/md/en/docs/reference/how-to-guides/pallet-design/incorporate-randomness.md

Co-authored-by: Kevin Krone <[email protected]>

* Update content/md/en/docs/reference/how-to-guides/pallet-design/use-loose-coupling.md

Co-authored-by: Kevin Krone <[email protected]>

* Update content/md/en/docs/reference/how-to-guides/parachains/connect-to-a-relay-chain.md

Co-authored-by: Kevin Krone <[email protected]>

* Update content/md/en/docs/reference/how-to-guides/weights/use-conditional-weights.md

Co-authored-by: Kevin Krone <[email protected]>

* Update content/md/en/docs/reference/xcm-reference.md

Co-authored-by: Kevin Krone <[email protected]>

---------

Co-authored-by: Kevin Krone <[email protected]>
  • Loading branch information
Rashmirreddy and wentelteefje authored Sep 4, 2023
1 parent 9bf4723 commit ce7a798
Show file tree
Hide file tree
Showing 58 changed files with 126 additions and 14,819 deletions.
8 changes: 4 additions & 4 deletions content/md/en/docs/build/build-process.md
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ include!(concat!(env!("OUT_DIR"), "/wasm_binary.rs"));

This code includes the compact WebAssembly binary (`WASM_BINARY`) and the uncompressed WebAssembly binary generated by the compiler (`WASM_BINARY_BLOATY`) in its compilation result, and the final executable binary for the project is generated.

At each stage of the build process, the WebAssembly binary is compressed to a smaller and smaller size.
At each stage of the build process, the WebAssembly binary is compressed to a smaller size than earlier.
For example, you can compare the sizes of each WebAssembly binary artifact for Polkadot:

```bash
Expand Down Expand Up @@ -118,7 +118,7 @@ For example, you might want to use the native runtime for initial synchronizatio
To use the native runtime for synchronizing blocks, you can start the node using the `--execution-syncing native` or `--execution-syncing native-else-wasm` command-line option.

For information about using the command-line options to specify an execution strategy for all or specific operations, see [node-template](/reference/command-line-tools/node-template).
For information about the execution strategy variant, see [ExecutionStrategy](https://paritytech.github.io/substrate/master/sp_state_machine/enum.ExecutionStrategy.html)
For information about the execution strategy variant, see [ExecutionStrategy](https://paritytech.github.io/substrate/master/sc_cli/arg_enums/enum.ExecutionStrategy.html)

## Building WebAssembly without a native runtime

Expand All @@ -127,7 +127,7 @@ After an initial WebAssembly runtime is provided, the blob that represents the W
In some rare cases, you might want to compile the WebAssembly target without the native runtime.
For example, if you're testing a WebAssembly runtime to prepare for a forkless upgrade, you might want to compile just the new WebAssembly binary.

Although it's a rare use case, you can use the [build-only-wasm.sh](https://github.com/paritytech/substrate/blob/master/.maintain/build-only-wasm.sh) script to build the `no_std` WebAssembly binary without compiling the native runtime.
Although it's a rare use case, you can use the [build-only-wasm.sh](https://github.com/paritytech/polkadot-sdk/blob/master/substrate/.maintain/build-only-wasm.sh) script to build the `no_std` WebAssembly binary without compiling the native runtime.

You can also use the `wasm-runtime-overrides` command-line option to load the WebAssembly from the file system.

Expand All @@ -138,6 +138,6 @@ This option is primarily used for faster compile time when you don't need to upd

## Where to go next

- [Wasm-builder README](https://github.com/paritytech/substrate/blob/master/utils/wasm-builder/README.md)
- [Wasm-builder README](https://github.com/paritytech/polkadot-sdk/blob/master/substrate/utils/wasm-builder/README.md)
- [Rust compilation options](https://doc.rust-lang.org/cargo/commands/cargo-build.html#compilation-options)
- [Discussion: Removing the native runtime](https://github.com/paritytech/substrate/issues/10579)
2 changes: 1 addition & 1 deletion content/md/en/docs/build/genesis-configuration.md
Original file line number Diff line number Diff line change
Expand Up @@ -193,7 +193,7 @@ pub struct RuntimeGenesisConfig {

Ultimately, the `RuntimeGenesisConfig` is exposed by way of the [`ChainSpec`](https://paritytech.github.io/substrate/master/sc_chain_spec/trait.ChainSpec.html) trait.

For a more complete example of genesis storage configuration for Substrate, see the [chain specification that ships with the Substrate code base](https://github.com/paritytech/substrate/blob/master/bin/node/cli/src/chain_spec.rs).
For a more complete example of genesis storage configuration for Substrate, see the [chain specification that ships with the Substrate code base](https://github.com/paritytech/polkadot-sdk/blob/master/substrate/bin/node/cli/src/chain_spec.rs).

## Initialize storage items within a pallet

Expand Down
8 changes: 4 additions & 4 deletions content/md/en/docs/build/origins.md
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ You can look at the source code of the [Sudo module](https://paritytech.github.i
In addition to the three core origin types, runtime developers are also able to define custom origins.
These can be used as authorization checks inside functions from specific modules in your runtime, or to define custom access-control logic around the sources of runtime requests.

Customizing origins allows runtime developers to specify valid origins depending on their runtime logic. For example, it may be desirable to restrict access of certain functions to special custom origins and authorize dispatch calls only from members of a [collective](https://github.com/paritytech/substrate/tree/master/frame/collective). The advantage of using custom origins is that it provides runtime developers a way to configure privileged access over dispatch calls to the runtime.
Customizing origins allows runtime developers to specify valid origins depending on their runtime logic. For example, it may be desirable to restrict access of certain functions to special custom origins and authorize dispatch calls only from members of a [collective](https://github.com/paritytech/polkadot-sdk/tree/master/substrate/frame/collective). The advantage of using custom origins is that it provides runtime developers a way to configure privileged access over dispatch calls to the runtime.

## Next steps

Expand All @@ -60,11 +60,11 @@ Customizing origins allows runtime developers to specify valid origins depending

### Examples

- View the [Sudo pallet](https://github.com/paritytech/substrate/tree/master/frame/sudo) to see how it allows a user to call with `Root` and `Signed` origin.
- View the [Sudo pallet](https://github.com/paritytech/polkadot-sdk/tree/master/substrate/frame/sudo) to see how it allows a user to call with `Root` and `Signed` origin.

- View the [Timestamp pallet](https://github.com/paritytech/substrate/tree/master/frame/timestamp) to see how it validates an a call with `None` origin.
- View the [Timestamp pallet](https://github.com/paritytech/polkadot-sdk/tree/master/substrate/frame/timestamp) to see how it validates an a call with `None` origin.

- View the [Collective pallet](https://github.com/paritytech/substrate/tree/master/frame/collective) to see how it constructs a custom `Member` origin.
- View the [Collective pallet](https://github.com/paritytech/polkadot-sdk/tree/master/substrate/frame/collective) to see how it constructs a custom `Member` origin.

- View our recipe for creating and using a custom origin.

Expand Down
6 changes: 3 additions & 3 deletions content/md/en/docs/build/pallet-coupling.md
Original file line number Diff line number Diff line change
Expand Up @@ -104,10 +104,10 @@ In general, loose coupling provides more flexibility than tight coupling and is
It guarantees better maintainability, reusability, and extensibility of your code.
However, tight coupling can be useful for pallets that are less complex or that have more overlap in methods and types than differences.

In FRAME, there are two pallets that are tightly coupled to [`pallet_treasury`](https://github.com/paritytech/substrate/tree/master/frame/treasury):
In FRAME, there are two pallets that are tightly coupled to [`pallet_treasury`](https://github.com/paritytech/polkadot-sdk/tree/master/substrate/frame/treasury):

- [Bounties pallet](https://github.com/paritytech/substrate/tree/master/frame/bounties)
- [Tipping pallet](https://github.com/paritytech/substrate/tree/master/frame/tips)
- [Bounties pallet](https://github.com/paritytech/polkadot-sdk/tree/master/substrate/frame/bounties)
- [Tipping pallet](https://github.com/paritytech/polkadot-sdk/tree/master/substrate/frame/tips)

As a general rule, the more complex a pallet is, the less desirable it is to tightly couple it.
This evokes a concept in computer science called [cohesion](<https://en.wikipedia.org/wiki/Cohesion_(computer_science)>), a metric used to examine the overall quality of a software system.
Expand Down
2 changes: 1 addition & 1 deletion content/md/en/docs/build/remote-procedure-calls.md
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ The way to do it is through a [JSON-RPC](/reference/glossary#json-rpc) proxy tha

## RPCs for remote_externalities

Substrate also provides some specialized RPC methods to call [`remote_externalities`](https://github.com/paritytech/substrate/blob/master/utils/frame/remote-externalities/src/lib.rs#L320-#L764) for a node.
Substrate also provides some specialized RPC methods to call [`remote_externalities`](https://github.com/paritytech/polkadot-sdk/blob/master/substrate/utils/frame/remote-externalities/src/lib.rs#L347-#L746) for a node.
These specialized methods for remote externalities enable you to make one-off RPC calls to a Substrate node to get information about blocks and headers.
The information returned by these calls can be useful for testing purposes with tools like [`try-runtime`](/reference/command-line-tools/try-runtime/).

Expand Down
6 changes: 3 additions & 3 deletions content/md/en/docs/build/tx-weights-fees.md
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ To account for this variability, the Transaction Payment pallet provides the [`F
The default update function is inspired by the Polkadot network and implements a targeted adjustment in which a target saturation level of block weight is defined.
If the previous block is more saturated, then the fees are slightly increased.
Similarly, if the previous block has fewer transactions than the target, fees are decreased by a small amount.
For more information about fee multiplier adjustments, see the [Web3 research page](https://w3f-research.readthedocs.io/en/latest/polkadot/overview/2-token-economics.html#relay-chain-transaction-fees-and-per-block-transaction-limits).
For more information about fee multiplier adjustments, see the [Web3 research page](https://research.web3.foundation/Polkadot/overview/token-economics#relay-chain-transaction-fees-and-per-block-transaction-limits).

## Transactions with special requirements

Expand Down Expand Up @@ -397,7 +397,7 @@ You can use Substrate **benchmarking functions** and `frame-benchmarking` calls

- [Benchmark](/test/benchmark/)
- [SignedExtension](https://paritytech.github.io/substrate/master/sp_runtime/traits/trait.SignedExtension.html)
- [Custom weights for the Example pallet](https://github.com/paritytech/substrate/blob/master/frame/examples/basic/src/weights.rs)
- [Web3 Foundation Research](https://w3f-research.readthedocs.io/en/latest/polkadot/overview/2-token-economics.html#relay-chain-transaction-fees-and-per-block-transaction-limits)
- [Custom weights for the Example pallet](https://github.com/paritytech/polkadot-sdk/blob/master/substrate/frame/examples/basic/src/weights.rs)
- [Web3 Foundation Research](https://research.web3.foundation/Polkadot/overview/token-economics#relay-chain-transaction-fees-and-per-block-transaction-limits)

<!-- - [Calculate weight](/reference/how-to-guides/weights/) -->
2 changes: 1 addition & 1 deletion content/md/en/docs/deploy/deployment-options.md
Original file line number Diff line number Diff line change
Expand Up @@ -412,7 +412,7 @@ ENTRYPOINT ["/usr/local/bin/node-template"]

### Automated build pipeline

The following sample [GitHub action](https://github.com/substrate-developer-hub/substrate-node-template/blob/main/.github/workflows/build-publish-image.yml) builds and publishes a Docker image to DockerHub.
The following sample [GitHub action](https://github.com/substrate-developer-hub/substrate-node-template/blob/main/.github/workflows/release.yml) builds and publishes a Docker image to DockerHub.
In most cases, you trigger this action using a manual workflow or when a new release is published.

Note that you must add secrets to your GitHub repository or organization as described in [Encrypted secrets](https://docs.github.com/en/actions/security-guides/encrypted-secrets) to publish images securely.
Expand Down
2 changes: 1 addition & 1 deletion content/md/en/docs/design/substrate-empowers-builders.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ For example, you can build a Substrate runtime:
- Using smart contracts and predefined FRAME pallets.
- With a combination of predefined and custom pallets and smart contracts.

As part of your design process, you can explore the predefined [FRAME pallets](https://github.com/paritytech/substrate/tree/master/frame) to see if they provide features that you want to use or customize and identify any custom pallets you might need.
As part of your design process, you can explore the predefined [FRAME pallets](https://github.com/paritytech/polkadot-sdk/tree/master/substrate/frame) to see if they provide features that you want to use or customize and identify any custom pallets you might need.

## Where to go next

Expand Down
2 changes: 1 addition & 1 deletion content/md/en/docs/learn/accounts-addresses-keys.md
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@ Polkadot enables you to restrict transactions for a proxy account using the foll
- CancelProxy
- Auction

The enumerated list of proxy types and the logic for matching proxy types to transaction is defined in the [Polkadot runtime](https://github.com/paritytech/polkadot/blob/master/runtime/polkadot/src/lib.rs).
The enumerated list of proxy types and the logic for matching proxy types to transaction is defined in the [Polkadot runtime](https://github.com/polkadot-fellows/runtimes/blob/main/relay/polkadot/src/lib.rs).

#### Anonymous proxy account

Expand Down
4 changes: 2 additions & 2 deletions content/md/en/docs/learn/consensus.md
Original file line number Diff line number Diff line change
Expand Up @@ -133,5 +133,5 @@ See [AlephBFT](https://github.com/aleph-zero-foundation/aleph-node) for such an

## Where to go next

- [BABE research](https://research.web3.foundation/en/latest/polkadot/block-production/Babe.html)
- [GRANDPA research](https://research.web3.foundation/en/latest/polkadot/finality.html)
- [BABE research](https://research.web3.foundation/Polkadot/protocols/block-production/Babe)
- [GRANDPA research](https://research.web3.foundation/Polkadot/protocols/finality)
4 changes: 2 additions & 2 deletions content/md/en/docs/learn/cryptography.md
Original file line number Diff line number Diff line change
Expand Up @@ -92,12 +92,12 @@ It is carefully engineered at several levels of design and implementation to ach

#### SR25519

[SR25519](https://research.web3.foundation/en/latest/polkadot/keys/1-accounts-more.html) is based on the same underlying curve as [Ed25519](#ed25519).
[SR25519](https://research.web3.foundation/Polkadot/security/keys/accounts-more) is based on the same underlying curve as [Ed25519](#ed25519).
However, it uses Schnorr signatures instead of the EdDSA scheme.

## Where to go next

- [Cryptography on Polkadot](https://wiki.polkadot.network/docs/en/learn-cryptography).
- [Research at W3F: Cryptography](https://research.web3.foundation/en/latest/crypto.html).
- [Research at W3F: Cryptography](https://research.web3.foundation/crypto).
- [`Hash`](https://paritytech.github.io/substrate/master/sp_runtime/traits/trait.Hash.html) trait for implementing new hashing algorithms.
- [`Pair`](https://paritytech.github.io/substrate/master/sp_core/crypto/trait.Pair.html) trait for implementing new cryptographic schemes.
2 changes: 1 addition & 1 deletion content/md/en/docs/learn/offchain-operations.md
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ By populating the data at every block, offchain indexing ensures that the data i

Now that you are familiar with how offchain workers, offchain storage, and offchain indexing enable you to work with data not stored on-chain, you might want to explore the following examples of offchain workers and how to use them in runtime development:

- [Example: Offchain worker](https://github.com/paritytech/substrate/tree/master/frame/examples/offchain-worker)
- [Example: Offchain worker](https://github.com/paritytech/polkadot-sdk/tree/master/substrate/frame/examples/offchain-worker)
- [Example: Submit transactions](https://github.com/JoshOrndorff/recipes/blob/master/text/off-chain-workers/transactions.md)
- [Example: Use HTTP requests to fetch data](https://github.com/JoshOrndorff/recipes/blob/master/text/off-chain-workers/http-json.md)
- [Example: Offchain storage](https://github.com/JoshOrndorff/recipes/blob/master/text/off-chain-workers/storage.md)
Expand Down
2 changes: 1 addition & 1 deletion content/md/en/docs/learn/runtime-development.md
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ In addition to the library of pre-built FRAME pallets, you can use the FRAME lib
With custom pallets, you have the flexibility to define the runtime behavior that best suits your purposes.
Because each pallet has its own discrete logic, you can combine pre-built and custom pallets to control the features and functionality your blockchain provides and achieve the results you want.

For example, you might include the [Balances pallet](https://github.com/paritytech/substrate/tree/master/frame/balances) in your runtime to use its cryptocurrency-related storage items and functions for managing tokens, but add custom logic to call a pallet you write when an account balance changes.
For example, you might include the [Balances pallet](https://github.com/paritytech/polkadot-sdk/tree/master/substrate/frame/balances) in your runtime to use its cryptocurrency-related storage items and functions for managing tokens, but add custom logic to call a pallet you write when an account balance changes.

Most pallets are composed with some combination of the following sections:

Expand Down
6 changes: 3 additions & 3 deletions content/md/en/docs/quick-start/explore-the-code.md
Original file line number Diff line number Diff line change
Expand Up @@ -88,11 +88,11 @@ Before you start to customize the runtime for your own project, you should spend
You've already seen how the default manifest for the runtime lists the default dependencies and features for the runtime in lines similar to the following:

```rust
pallet-balances = { version = "4.0.0-dev", default-features = false, git = "https://github.com/paritytech/substrate.git", branch = "polkadot-vX.Y.Z" }
pallet-balances = { version = "4.0.0-dev", default-features = false, git = "https://github.com/paritytech/polkadot-sdk.git", branch = "polkadot-vX.Y.Z" }

pallet-sudo = { version = "4.0.0-dev", default-features = false, git = "https://github.com/paritytech/substrate.git", branch = "polkadot-vX.Y.Z" }
pallet-sudo = { version = "4.0.0-dev", default-features = false, git = "https://github.com/paritytech/polkadot-sdk.git", branch = "polkadot-vX.Y.Z" }

pallet-transaction-payment = { version = "4.0.0-dev", default-features = false, git = "https://github.com/paritytech/substrate.git", branch = "polkadot-vX.Y.Z" }
pallet-transaction-payment = { version = "4.0.0-dev", default-features = false, git = "https://github.com/paritytech/polkadot-sdk.git", branch = "polkadot-vX.Y.Z" }
```

There are also dependencies on core packages—such as `frame-system`, `frame-support`, and `frame-executive`.
Expand Down
2 changes: 1 addition & 1 deletion content/md/en/docs/quick-start/modify-the-runtime.md
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ To add the Utility pallet:
For example, you should add a single line similar to the following.

```toml
pallet-utility = { version = "4.0.0-dev", default-features = false, git = "https://github.com/paritytech/substrate.git", branch = "polkadot-vX.Y.Z" }
pallet-utility = { version = "4.0.0-dev", default-features = false, git = "https://github.com/paritytech/polkadot-sdk.git", branch = "polkadot-vX.Y.Z" }
```

Be sure to replace `branch = "polkadot-vX.Y.Z"` with the Polkadot branch used for other pallets.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -382,7 +382,7 @@ Writing weights to "rocksdb_weights.rs"

To get benchmarking information for the `paritydb` database instead of the default `rocksdb` database, use the `--db paritydb` command-line option.
TO get storage benchmarking information for Polkadot or any other real chain snapshot, use the command-line option `--state-version 0`.
For more information about using the benchmark storage subcommand, see [benchmark storage command](https://github.com/paritytech/substrate/tree/master/utils/frame/benchmarking-cli/src/storage#the-benchmark-storage-command).
For more information about using the benchmark storage subcommand, see [benchmark storage command](https://github.com/paritytech/polkadot-sdk/tree/master/substrate/utils/frame/benchmarking-cli/src/storage).

For more information about how to add benchmarking to the runtime, see [Benchmark](/test/benchmark/) and [Add benchmarks](/reference/how-to-guides/weights/add-benchmarks/).

Expand Down
Loading

0 comments on commit ce7a798

Please sign in to comment.