Project reference not resolved

(Birger Buhl Dinesen) #1

I have not yet got it working with project references.

The project HDSMDB.Client references project HDSMDB.Common in the same solution:

If I click the HDSMDB.Common reference:

This it a code snippet from the HDSMDB.Client.elements file:

<ProjectReference Include="..\HDSMDB.Common\HDSMDB.Common.elements">

The solution file is attached.

HDSMDB.NET.sln.txt (3.2 KB)

The same solution works fine in Visual Studio 2015.

(Birger Buhl Dinesen) #2

Using the latest Water build 2317.

(marc hoffman) #3

is the project ID in the reference valid and matches the ID in the project? does the project build ok? can I see a full (diagnostic) build log?

(Birger Buhl Dinesen) #4

In the solution file the project ID is: {5DA3B460-FA95-4E9F-9725-50FFF9BA7E95}
In the HDSMDB.Client.elements file it is: {5da3b460-fa95-4e9f-9725-50fff9ba7e95}

So they are not in the same case, but same text.

The project builds fine.

(Birger Buhl Dinesen) #5 (93.8 KB)

(marc hoffman) #6
               -> Target Echoes started.
D:                Using cached data for ResolveReferences (19-03-2018 <= 27-03-2018)
               <- Target Echoes finished.

Can you send a “rebuild” log that does not used cached data is always useful for these scenarios. That said, since the project builds, the project reference is most likely fine. (the case does not matter, as it doesn’t affect the GUID value). So this sounds like an IDE-only issue.

Does this show for you with any project reference, eve in a simple test project? It does not reproduce here for me (tested Fire, will check in Water in a Biot, but thats the same logic):

(marc hoffman) #7

Fine for me in Water, too, for the attached project: (432.8 KB)

(marc hoffman) #8

(typo on that button is fixed btw :wink:

(Birger Buhl Dinesen) #9

It looks like you have an absolute path in your project reference?
Or maybe that is “calculated” by Fire/Water.
In my project there is only the project guid and the relative “path”. No hint path.

I will just check your project.

Here you have the rebuild log: (162.9 KB)

(Birger Buhl Dinesen) #10

Your project works fine - the reference is shown as valid.

So I am thinking it may have something to do with the relative path?
The "…\ " which is not in your project.

(Birger Buhl Dinesen) #11

Now I have tried this:

<ProjectReference Include="C:\SVN\Home\HD-SMDB\HDSMDB.Common\HDSMDB.Common.elements">

Uppercase GUID - just in “case” :wink:
Added the ProjectFile tag.
Added the HintPath again.
Full path in the Include attribute.

Same result - Water can not find the reference.

(marc hoffman) #12

This is odd, yeah, at build time it all resolves fine:

D:                   Project Reference 'HDSMDB.Common' will resolve using target 'Echoes'.
                     Project Reference 'HDSMDB.Common' was resolved to 'C:\Program Files (x86)\RemObjects Software\Elements\Echoes\Reference Assemblies\Delphi.dll' via target 'Echoes'.
                     Project Reference 'HDSMDB.Common' was resolved to 'C:\SVN\Home\HD-SMDB\packages\Digst.OioIdws.Wsc.2.0.0\lib\net45\Digst.OioIdws.Common.dll' via target 'Echoes'.
                     Project Reference 'HDSMDB.Common' was resolved to 'C:\SVN\Home\HD-SMDB\packages\Digst.OioIdws.Wsc.2.0.0\lib\net45\Digst.OioIdws.LibBas.dll' via target 'Echoes'.
                     Project Reference 'HDSMDB.Common' was resolved to 'C:\SVN\Home\HD-SMDB\packages\Digst.OioIdws.Wsc.2.0.0\lib\net45\Digst.OioIdws.OioWsTrust.dll' via target 'Echoes'.
                     Project Reference 'HDSMDB.Common' was resolved to 'C:\SVN\Home\HD-SMDB\packages\Digst.OioIdws.Wsc.2.0.0\lib\net45\Digst.OioIdws.Wsc.dll' via target 'Echoes'.
                     Project Reference 'HDSMDB.Common' was resolved to 'C:\SVN\Home\HD-SMDB\packages\NLog.4.5.3\lib\net45\NLog.dll' via target 'Echoes'.
                     Project Reference 'HDSMDB.Common' was resolved to 'C:\Users\hd\AppData\Local\RemObjects Software\EBuild\Obj\HDSMDB.Common-D4FB158BE1301046A8E7B5982B0D2F9E4DE1618B\Debug\Echoes\HDSMDB.Common.dll' via target 'Echoes'.
                     Project Reference 'HDSMDB.Common' was resolved to 'C:\Users\hd\AppData\Local\RemObjects Software\EBuild\Obj\HDSMDB.Service.Old-88DB814F517B029D5EFC6B24ACBC615891D1AC98\Debug\Echoes\HDSMDB.Service.Old.dll' via target 'Echoes'.
                     Project Reference 'HDSMDB.Common' was resolved to 'C:\Users\hd\AppData\Local\RemObjects Software\EBuild\Obj\HDSMDB.Service-12C7C7C715B4EBF5E3A8301F94A50C83C50543FC\Debug\Echoes\HDSMDB.Service.dll' via target 'Echoes'.
                  <- Task RemObjects.EBuild.Elements.ElementsResolveEchoesReferencesForTarget finished for HDSMDB.Client, Echoes, took 0,0190s (0,0190s).

oddly it’s also only the one project reference that fails, others are fine (your screenshot shows the other references in THAT project are dll references; but in the build log I see other project references (eg Project Reference 'HDSMDB.Service' will resolve using target 'Echoes'...).Do those fail in the IDE too?

Any chance I can see the full solution? (you can mail it to me, and I’ll keep it confidential, of course).

Oh and while I doubt that is, can you try changing the “Include” in the reference itself to just have the name, not the full path, like mine has:

<ProjectReference Include="ClassLibrary">

make yours

<ProjectReference Include="HDSMDB.Common">

(Birger Buhl Dinesen) #13

Well, that actually did help :slight_smile:

<ProjectReference Include="HDSMDB.Common">

Changing the include attribute that is.
So, this is different to how Visual Studio writes that Include attribute.

Now it shows fine, and all the implicit references are gone and nested under HDSMDB.Common.

Here is a fresh rebuild log after the change: (163.2 KB)

(marc hoffman) #14

OK, cool. I can probably easily reproduce and fix that…

(RemObjects) #15

Thanks, logged as bugs://80856

(RemObjects) #16

bugs://80856 got closed with status fixed.