Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Orchard Core - Incompatible with Remora.Sdk #15479

Open
Foxtrek64 opened this issue Mar 9, 2024 · 6 comments
Open

Orchard Core - Incompatible with Remora.Sdk #15479

Foxtrek64 opened this issue Mar 9, 2024 · 6 comments
Labels
Milestone

Comments

@Foxtrek64
Copy link

Describe the bug

As a matter of practice, I tend to use the Remora.Sdk library by @Nihlus. It appears as though this SDK library is incompatible with Orchard. It is responsible for adding several default nuget packages, providing default StyleCop rules, and for Class Library projects, adds tools for nuget package management.

When this SDK is included, Orchard will return a 404 page instead of displaying the Out Of Box initial setup wizard.

To Reproduce

Steps to reproduce the behavior:

  1. Follow the tutorial for creating a decoupled CMS Site until you reach the Out Of Box setup wizard.
  2. Stop the web app.
  3. Make the following changes to the csproj (forgive any typos, I made some changes by hand since some of this required data is held in other places, like Directory.Build.props or global.json).
<Project>

    <Import Project="Sdk.props" Sdk="Microsoft.NET.Sdk.Web" />
    <Import Project="Sdk.props" Sdk="Remora.Sdk" Version="3.0.1" />

    <PropertyGroup>
        <TargetFramework>net8.0</TargetFramework>
        <VersionPrefix>0.1.0</VersionPrefix>
        <Description>Lorem Ipsum</Description>
        <PackageReleaseNotes>Initial Release.</PackageReleaseNotes>
        <DockerDefaultTargetOS>Linux</DockerDefaultTargetOS>
        <LegalAuthor>John Doe</LegalAuthor>
	<LegalEmail>support@example.com</LegalEmail>
	<Company>Contoso, Inc.</Company>
	<LegalCopyrightHolder>Contoso</LegalCopyrightHolder>
    </PropertyGroup>
    
    <ItemGroup>
        <PackageReference Include="OrchardCore.Application.Cms.Core.Targets" Version="1.8.2" />
        <PackageReference Update="StyleCop.Analyzers" Version="1.2.0-beta.556" />
    </ItemGroup>

    <ItemGroup>
      <Content Include="..\..\.dockerignore">
        <Link>.dockerignore</Link>
      </Content>
    </ItemGroup>

    <ItemGroup>
        <ProjectReference Include="..\FoxDen.Common\FoxDen.Common.csproj" />
    </ItemGroup>

    <Import Project="Sdk.targets" Sdk="Microsoft.NET.Sdk.Web" />
    <Import Project="Sdk.targets" Sdk="Remora.Sdk" Version="3.0.1" />

</Project>
  1. Launch the application again.

Expected behavior

The Out Of Box setup wizard should display, allowing you to perform the initial setup of the site. Instead, a 404 status code is returned.

Additional Comments

I'm logging this as an issue just for tracking purposes. Once a solution is found, it will be provided here. If this requires a configuration change, I'll propose a change to the documentation. Otherwise, the appropriate PR will be filed with the appropriate library.

@hishamco
Copy link
Member

Please check the following:

https://www.nuget.org/packages/Remora.Sdk#readme-body-tab

@Foxtrek64
Copy link
Author

Please check the following:

https://www.nuget.org/packages/Remora.Sdk#readme-body-tab

Thanks for the suggestion, but this is a rather long readme. Are you referring to any section in particular? I can dig into that code more specifically.

@hishamco
Copy link
Member

Framework Targets

@Foxtrek64
Copy link
Author

Framework Targets

For executable projects such as an asp.net core website, the target framework is net8.0.
The target frameworks including netstandard2.1;net6.0;net7.0; are only included if the project is a class library and the TargetFramework or TargetFrameworks property has not been explicitly overridden.

You can see that here: https://github.com/Remora/Remora.Sdk/blob/4f0e06a411d65f36c6a460064b2a50faaee37961/Remora.Sdk/Sdk/Sdk.props#L11-L17

The defaults are only provided if the property is not set.

@sebastienros sebastienros added this to the backlog milestone Mar 14, 2024
@sebastienros
Copy link
Member

Someone from their project or you will have to investigate why it's not working.

@hishamco
Copy link
Member

I don't think there's something that we can do here. Can we close this?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants