fixed issue with shard and state data structures, passing TestBasic