Basic Solidity functionality not working in blockapps 0.4.5. while Remix and 0.4.2 have no issues compiling


#1

Hi,

I have been using Blockapps for a while now but was surprised by the compiler behavior of its latest version for the following simple but common use cases:

CASE 1 Using structs:


contract TestContract {

struct TestStruct {
    address referenceAddress;
    uint balance;
}

address owner;
uint currentDate;
TestStruct structInstance;

}


Does compile fine on both remix and blockapps 0.4.2 while 0.4.5 raises:
src:5:5: Error: Identifier not found or not unique.
TestStruct structInstance;
^--------^

CASE 2: Using arrays as function parameters:


contract TestContract {

address owner;
uint currentDate;

function testFunction(uint[] dummyArray) {

}

}


Does compile fine on both remix and blockapps 0.4.2 while 0.4.5 raises:
src:8:27: Error: Identifier not found or not unique.
function testFunction(TYPE_NOT_IMPLEMENED dummyArray) public {
^-----------------^
I haven’t tested 0.4.3 or 0.4.4

the strato_bloch_1 logs:

                                                                  CallStack:
                                                                    blocError, called at BlockApps.Bloc22.Database.Solc:56:34

172.18.0.13 - - [20/Feb/2018:14:22:48 +0000] “POST /bloc/v2.2/contracts/compile HTTP/1.0” 400 - “http://ec2-34-250-160-40.eu-west-1.compute.amazonaws.com/dashboard/” “Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/64.0.3282.167 Safari/537.36”
[Error] [BlockApps.Bloc22.Database.Solc:56] [2018-02-20T14:33:53] UserError "src:1:1: Warning: Source file does not specify required compiler version!Consider adding “pragma solidity ^0.4.8\ncontract TestContract {\n^\nSpanning multiple lines.\nsrc:5:5: Error: Identifier not found or not unique.\n TestStruct structInstance;\n ^--------^\n”
CallStack:
blocError, called at BlockApps.Bloc22.Database.Solc:56:34
172.18.0.13 - - [20/Feb/2018:14:33:53 +0000] “POST /bloc/v2.2/contracts/compile HTTP/1.0” 400 - “http://ec2-34-250-160-40.eu-west-1.compute.amazonaws.com/dashboard/” “Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/64.0.3282.167 Safari/537.36”
[Error] [BlockApps.Bloc22.Database.Solc:56] [2018-02-20T14:35:23] UserError "src:1:1: Warning: Source file does not specify required compiler version!Consider adding “pragma solidity ^0.4.8\ncontract TestContract {\n^\nSpanning multiple lines.\nsrc:8:27: Error: Identifier not found or not unique.\n function testFunction(TYPE_NOT_IMPLEMENED dummyArray) public {\n ^-----------------^\n”

Cheers,

Joris


Address Mapping Struct Compilation Error
#2

Hi Joris,
Thanks for taking the time to provide a detailed analysis - I’m glad you’re getting use out of the product.
We’re looking into this and will provide an update here.


#3

Thanks, looking forward to the solution.


#4

The above issue is solved in 0.5.0