Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
M
MetaProtocol
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Nebula
MetaProtocol
Commits
c5023e6c
Commit
c5023e6c
authored
Nov 30, 2022
by
Ubuntu
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix any type
parent
f2a034dd
Changes
4
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
290 additions
and
15 deletions
+290
-15
resource.proto
baseapi/base/v1/resource.proto
+7
-1
buf.yaml
baseapi/buf.yaml
+3
-0
grcp-tx_test.go
grcp-tx_test.go
+279
-14
main.go
main.go
+1
-0
No files found.
baseapi/base/v1/resource.proto
View file @
c5023e6c
...
@@ -4,6 +4,12 @@ package base.v1;
...
@@ -4,6 +4,12 @@ package base.v1;
import
"google/protobuf/timestamp.proto"
;
import
"google/protobuf/timestamp.proto"
;
import
"google/protobuf/any.proto"
;
import
"google/protobuf/any.proto"
;
import
"google/protobuf/descriptor.proto"
;
import
"github.com/gogo/protobuf/gogoproto/gogo.proto"
;
// import "base/v1/options.proto";
// import "base/v1/options.proto";
message
Bytes32
{
message
Bytes32
{
...
@@ -86,7 +92,7 @@ message TxProof{
...
@@ -86,7 +92,7 @@ message TxProof{
message
Transaction
{
message
Transaction
{
TxProof
tx_proof
=
1
;
TxProof
tx_proof
=
1
;
int64
timeout_block_num
=
2
;
int64
timeout_block_num
=
2
;
google.protobuf.Any
tx
=
3
;
// EthTx StdTx
google.protobuf.Any
tx
=
3
[(
gogoproto.customtype
)
=
"InterfaceType"
]
;
// EthTx StdTx
}
}
//2. eth std: proto3 eth tx --> grpc --->proto3 eth tx
//2. eth std: proto3 eth tx --> grpc --->proto3 eth tx
...
...
baseapi/buf.yaml
View file @
c5023e6c
version
:
v1
version
:
v1
deps
:
-
buf.build/googleapis/googleapis
-
buf.build/acme/paymentapis
breaking
:
breaking
:
use
:
use
:
-
FILE
-
FILE
...
...
grcp-tx_test.go
View file @
c5023e6c
This diff is collapsed.
Click to expand it.
main.go
View file @
c5023e6c
...
@@ -100,5 +100,6 @@ func pbany(v interface{}) (*anypb.Any, error) {
...
@@ -100,5 +100,6 @@ func pbany(v interface{}) (*anypb.Any, error) {
if
!
ok
{
if
!
ok
{
return
&
anypb
.
Any
{},
fmt
.
Errorf
(
"%v is not proto.Message"
,
pv
)
return
&
anypb
.
Any
{},
fmt
.
Errorf
(
"%v is not proto.Message"
,
pv
)
}
}
return
anypb
.
New
(
pv
)
return
anypb
.
New
(
pv
)
}
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment