deployment-tools icon indicating copy to clipboard operation
deployment-tools copied to clipboard

manifest.EntryPoint is null net6

Open Cornmarket opened this issue 2 years ago • 1 comments

Getting NRE in Command.cs (line 1640) because manifest.EntryPoint is null.

Reproduce the error by building a simple application like this:

<Project Sdk="Microsoft.NET.Sdk">
 <PropertyGroup Label="Globals">
  <WebView2LoaderPreference>Static</WebView2LoaderPreference>
 </PropertyGroup>
 <PropertyGroup>
  <OutputType>WinExe</OutputType>
   <TargetFramework>net6.0-windows</TargetFramework>
    <RuntimeIdentifier>win10-x64</RuntimeIdentifier>
     <UseWPF>true</UseWPF>
      <LangVersion>latest</LangVersion>
      <StartupObject>FHCDocumentImportExport.App</StartupObject>
      <NoWin32Manifest>true</NoWin32Manifest>
...

Then build it with

dotnet build yourproject.csproj /p:Version=1.2.3.4 /p:OutputPath=...

Then finally run:

deployment-tools\artifacts\bin\MageCLI\Debug\net7.0\dotnet-mage.exe -new Application  -t client\FHCDocumentImportExport.manifest -fd client -v 1.2.3.4  -p amd64

Actual result:

Internal error, please try again. Object reference not set to an instance of an object.

Expected result:

should generate properly the app manifest

Cornmarket avatar Mar 02 '23 15:03 Cornmarket

@Cornmarket have you tried adding Launcher first? Complete list of steps is available at: https://github.com/dotnet/deployment-tools/tree/main/Documentation/dotnet-mage

NikolaMilosavljevic avatar May 30 '23 17:05 NikolaMilosavljevic