-
Notifications
You must be signed in to change notification settings - Fork 103
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
If the chaincode input and output functions have different packages but the same structure name then variable conflict issue in the chaincode #109
Comments
I can confirm a similar error. I modified the asset-transfer-basic sample chaincode so that
|
Yes, that’s the bug. I forgot to write an error message. May i know when it will be fixed? |
I prototyped a fix in pull request #118. It fails the contract metadata tests from the Fabric integration tests in fabric-test. I am not sure whether the change to the generated contract metadata is acceptable and the tests can be updated to be less specific about the element names present, or if the inconsistency across contract implementation languages is a blocker to this fix approach. From an application perspective the workaround might be to ensure that you use uniquely (short) named data types as parameter and return values. |
Ok, i understand. I will fix it using the method you suggested. Thanks for your help. |
Using spec
Literally, If the chaincode input and output functions have different packages but the same structure name then variable conflict issue in the chaincode.
Example
test1.go
test.go
In the case above, if Test2 is called after calling Test1, ‘Test’, the output of Test2, is recognized as ‘test1.Test’
If the structure name is different, no conflict will occur.
Please reply after confirmantion.
The text was updated successfully, but these errors were encountered: