遵循将托盘添加到您的运行时教程时出现的“外部失败”

问题描述

我在 Add a Pallet to Your Runtime 教程中添加了刻痕托盘

我的更改在这里https://github.com/led73/substrate-node-template/commit/8f3025a73b35804edf7c8dd7cd5630b387f2d344

但是当我尝试与托盘和 $ git add app/ The following paths are ignored by one of your .gitignore files: myAngularapp/src/app 交互时,它因事件而失败

setName

我应该在哪里查看哪里出了问题?

Screenshot is here

解决方法

您的问题很容易解决,请检查您的缺刻托盘代码的 this line,您定义的最小长度为 8 个字符,但是您对 larry 的测试将失败,因为它没有达到最小请求长度。

对于未来的情况,当发生调度错误时,它会提示。 index:9error:0 是抛出错误的 construct_runtime! 中托盘的索引,以及相关托盘的 #[pallet::error] 定义中的错误索引。>

缺口托盘的索引 0 错误为 this one