Home

Warning: 'xxx.deps.json' may be required, but is not present

edited August 2022

We recently upgraded to LINQPad 7 and are seeing warnings like the following in the first row of all our scripts:

Is it possible to suppress this warning in LINQPad?

Comments

  • That happens when the folder in question contains more than one .deps.json file, but none for the DLL that you're referencing. It's quite likely that LINQPad won't be able to resolve transitive dependencies in this scenario. Do you perhaps have .deps.json files in that folder that are left over from an old build?

  • Some of our projects are multitargeting .Net Framework and .Net Standard, while others target .Net 5. The former category does not generate .deps.json files (unless I am missing something). If I delete the various .deps.json files I no longer get the warning, but of course this is not a solution. Is there something I can do about this?

  • I still unsure as to why there would need to be more than one .deps.json file in a single folder. Have you configured multiple projects to build to the same output folder?

  • No, I have definitely not done that. I cleaned up the bin folder and rebuilt. This time I only ended up with just a single .deps.json for the primary project being build. However, I am still getting the warning (unless I delete the .deps.json file).

  • That's very strange. Are you able to PM me a zip with your folder?

  • I can't reproduce this.

    In your folder, there are two .deps.json files:

    TestApp.Core.deps.json
    OE.S1.Oadr.deps.json

    With both of those files present, I get the warning you describe. But after deleting either file and closing/reopening the query, the warning goes away.

  • Thank you for looking into this Joe. I did confirm that if I delete OE.S1.Oadr.deps.json, I no longer get the warning. The question is why this file is added to the bin folder of the referencing project. Could it be because this project has an Exe output type? Clearly this is not a LINQPad issue, so I do not expect you to solve it.

Sign In or Register to comment.