Failed with exception value cannot be null

Hi,
One of my multi target libraries is now failing with this

                    -> Task RemObjects.EBuild.Elements.ElementsResolveToffeeReferencesForTarget started for Moshine.Api.Weather, Toffee.iOS.
                     Reference 'Foundation' was resolved to '/Users/JohnMoshakis/Library/Application Support/RemObjects Software/EBuild/SDKs/Island/Darwin/iOS 16.0/Foundation.fx' for target 'Toffee.iOS'.
                     Reference 'Foundation' was resolved to '/Users/JohnMoshakis/Library/Application Support/RemObjects Software/EBuild/SDKs/Island/Darwin/iOS 16.0/Foundation.fx' for target 'Toffee.iOS' (Device).
                     Reference 'Foundation' was resolved to '/Users/JohnMoshakis/Library/Application Support/RemObjects Software/EBuild/SDKs/Island/Darwin/iOS 16.0 Simulator/Foundation.fx' for target 'Toffee.iOS' (Simulator).
                     Added implicit reference to '/Users/JohnMoshakis/Library/Application Support/RemObjects Software/EBuild/SDKs/Island/Darwin/iOS 16.0/Foundation.fx'
                     Reference 'UIKit' was resolved to '/Users/JohnMoshakis/Library/Application Support/RemObjects Software/EBuild/SDKs/Island/Darwin/iOS 16.0/UIKit.fx' for target 'Toffee.iOS'.
                     Reference 'UIKit' was resolved to '/Users/JohnMoshakis/Library/Application Support/RemObjects Software/EBuild/SDKs/Island/Darwin/iOS 16.0/UIKit.fx' for target 'Toffee.iOS' (Device).
                     Reference 'UIKit' was resolved to '/Users/JohnMoshakis/Library/Application Support/RemObjects Software/EBuild/SDKs/Island/Darwin/iOS 16.0 Simulator/UIKit.fx' for target 'Toffee.iOS' (Simulator).
                     Added implicit reference to '/Users/JohnMoshakis/Library/Application Support/RemObjects Software/EBuild/SDKs/Island/Darwin/iOS 16.0/UIKit.fx'
                     Reference 'libToffee' was resolved to '/Users/JohnMoshakis/Documents/Elements/References/Toffee/iOS/libToffee.fx' via XML for target 'Toffee.iOS'.
                     Reference 'libToffee' was resolved to '/Users/JohnMoshakis/Documents/Elements/References/Toffee/iOS/libToffee.fx' for target 'Toffee.iOS' (Device).
                     Reference 'libToffee' was resolved to '/Users/JohnMoshakis/Documents/Elements/References/Toffee/iOS Simulator/libToffee.fx' for target 'Toffee.iOS' (Simulator).
                     Added implicit reference to '/Users/JohnMoshakis/Documents/Elements/References/Toffee/iOS/libToffee.fx'
                     Project 'Moshine.Foundation' referenced from 'Moshine.Api.Weather' is not enabled, reusing cached output.
D:                   Project Reference 'Moshine.Foundation' will resolve using target 'Toffee.iOS'.
                     Project Reference 'Moshine.Foundation' was resolved to '/Users/JohnMoshakis/Documents/Elements/References/Toffee/iOS/libElements.fx' via target 'Toffee.iOS' (but is already referenced).
E:                   Value cannot be null.
Parameter name: aFileName
D:                   |   at RemObjects.Elements.RTL.Path.GetFileName (System.String aFileName) [0x00003] in <1f96089c4d1e43c8b828eaaae4f15d51>:0 .
D:                   |   at RemObjects.EBuild.Elements.ElementsResolveToffeeReferencesForTarget.AdjustReferenceIfNeeded (RemObjects.EBuild.EBuildObject aReference) [0x00186] in <b6bde7d939804b83910b3aa6cc34d27d>:0 .
D:                   |   at RemObjects.EBuild.Elements.ElementsResolveReferencesForTarget.ProcessProjectReference____ToProject__WithMatchingTarget__Cirrus (RemObjects.EBuild.EBuildObject aReference, RemObjects.EBuild.EBuildProject aProject, RemObjects.EBuild.EBuildTarget aTarget, System.Boolean aCirrus) [0x00453] in <b6bde7d939804b83910b3aa6cc34d27d>:0 .
D:                   |   at RemObjects.EBuild.Elements.ElementsResolveReferencesForTarget.ProcessProjectReference____ToProject__WithMatchingTarget (RemObjects.EBuild.EBuildObject aReference, RemObjects.EBuild.EBuildProject aProject, RemObjects.EBuild.EBuildTarget aTarget) [0x00000] in <b6bde7d939804b83910b3aa6cc34d27d>:0 .
D:                   |   at RemObjects.EBuild.Elements.ElementsResolveToffeeReferencesForTarget.ProcessProjectReference____ToProject__WithMatchingTarget (RemObjects.EBuild.EBuildObject aReference, RemObjects.EBuild.EBuildProject aProject, RemObjects.EBuild.EBuildTarget aTarget) [0x00239] in <b6bde7d939804b83910b3aa6cc34d27d>:0 .
D:                   |   at RemObjects.EBuild.Elements.ElementsResolveReferencesForTarget.ProcessProjectReference____ToProject__WithTarget (RemObjects.EBuild.EBuildObject aReference, RemObjects.EBuild.EBuildProject aProject, RemObjects.EBuild.EBuildTarget aTarget) [0x00033] in <b6bde7d939804b83910b3aa6cc34d27d>:0 .
D:                   |   at RemObjects.EBuild.Elements.ElementsResolveReferencesForTarget.ProcessProjectReferences () [0x00a3a] in <b6bde7d939804b83910b3aa6cc34d27d>:0 .
D:                   |   at RemObjects.EBuild.Elements.ElementsResolveReferencesForTarget.Execute () [0x0001c] in <b6bde7d939804b83910b3aa6cc34d27d>:0 .
D:                   |   at RemObjects.EBuild.EBuildContext.RunTask________forTarget (RemObjects.EBuild.EBuildTask+MetaClass aTask, RemObjects.EBuild.EBuildValues aSettings, RemObjects.EBuild.EBuildObjects aObjects, RemObjects.EBuild.EBuildTarget aTarget) [0x003b0] in <8432fbfcac84477d887551dbbbd1c409>:0 .
                  <- Task RemObjects.EBuild.Elements.ElementsResolveToffeeReferencesForTarget failed with exception Value cannot be null.

Any idea where I should start looking ?

Cheers,
John

MultiTargetLibrary.zip (194.0 KB)

This project highlights the issue. I have a multi target library with one target and it references my remote project.

  <ItemGroup>
    <Reference Include="#" />
    <Reference Include="Elements">
      <Private>True</Private>
    </Reference>
    <RemoteProjectReference Include="github.com/Mosh/Moshine.Foundation/Moshine.Foundation.elements:*">
      <Private>True</Private>
    </RemoteProjectReference>
  </ItemGroup>

If I delete the elements reference then it builds without the error. Also while the remote project reference is present it says it cant resolve the reference to elements.

Cheers,
John

Could this one be looked into ?

It will be, yes.

Fixed, was a bad side effect from the fix for bugs://E26003: No path for Reference when switching between device and simulator

2 Likes