Skip to content

Fix gocycle in chain.go#434

Open
zhugelianglongming wants to merge 6 commits intoOpenAtomFoundation:masterfrom
zhugelianglongming:dev-gocycle_chain
Open

Fix gocycle in chain.go#434
zhugelianglongming wants to merge 6 commits intoOpenAtomFoundation:masterfrom
zhugelianglongming:dev-gocycle_chain

Conversation

@zhugelianglongming
Copy link
Collaborator

see #402

kernel/engines/xuperos/chain.go
Line 118: warning: cyclomatic complexity 23 of function (*Chain).PreExec() is high (> 15) (gocyclo)


// 交易预执行
func (t *Chain) PreExec(ctx xctx.XContext, reqs []*protos.InvokeRequest, initiator string, authRequires []string) (*protos.InvokeResponse, error) {
func (t *Chain) PreExec(ctx xctx.XContext, reqs []*protos.InvokeRequest, initiator string,
Copy link
Collaborator

Choose a reason for hiding this comment

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

这个接口改完本地跑过 reserved contract 相关测试吗

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

本地跑的测试相当于是 reserved contract 为空的环境
现在 5.* 一般如何在测试/本地环境 测试 reserved contract ?看代码好像没有给 put 的更新接口。

Copy link
Collaborator

Choose a reason for hiding this comment

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

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Good!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants