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

Convert v1.9 to v2.0 #15938

Merged
merged 16 commits into from
May 2, 2024
Merged

Convert v1.9 to v2.0 #15938

merged 16 commits into from
May 2, 2024

Conversation

MikeAlhayek
Copy link
Member

@MikeAlhayek MikeAlhayek commented May 1, 2024

Part of #15892

Summary by CodeRabbit

  • New Features
    • Introduced explicit upgrade instructions and highlighted breaking changes for a smoother transition.
  • Refactor
    • Reorganized constructor parameters and replaced dependencies with IShellReleaseManager for consistency.
  • Bug Fixes
    • Resolved issues related to method signatures and parameter usage for improved functionality.

Copy link
Contributor

coderabbitai bot commented May 1, 2024

Walkthrough

The transition from Orchard Core version 1.9.0 to 2.0.0 signifies significant improvements and changes. Key updates include the version prefix alteration, detailed upgrade instructions, and the removal of Newtonsoft.Json support. Modules and configurations have been adjusted to align with these changes.

Changes

File Path Change Summary
src/OrchardCore.Build/OrchardCore.Commons.props Updated VersionPrefix from 1.9.0 to 2.0.0, indicating a significant version increment.
src/docs/releases/2.0.0.md Introduced explicit upgrade instructions, highlighted breaking changes, and added new features for version 2.0.0.
mkdocs.yml Updated exclusion of releases/1.9.0.md from navigation to releases/2.0.0.md.
.github/workflows/community_metrics.yml Renamed job from "build" to "generate-community-metrics" in the workflow file.
src/OrchardCore.Build/Dependencies.props Updated versions of various packages related to GraphQL, Jint, NLog, NodaTime, OpenIddict, and OrchardCore libraries.
.../AzureEmailSettingsDisplayDriver.cs,
.../AzureAISearch...,
.../SecuritySettings...,
.../DefaultSiteSettings...,
.../SmsSettings...,
.../TwitterSettings...
Replaced IShellHost and ShellSettings dependencies with IShellReleaseManager in multiple modules.
.../RegistrationSettingsDisplayDriver.cs,
.../ResetPasswordSettings...,
.../RoleLoginSettings...,
.../TwoFactorLoginSettings...
Minor adjustments in various user-related drivers.
src/OrchardCore.Abstractions/Shell/IShellReleaseManager.cs Introduced IShellReleaseManager interface with RequestRelease() and SuspendReleaseRequest() methods.
src/OrchardCore.Abstractions/Shell/Scope/ShellScope.cs Adjusted initialization of Dictionary<object, object> _items in ShellScope class.

Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media?

Share
Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>.
    • Generate unit testing code for this file.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai generate unit testing code for this file.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai generate interesting stats about this repository and render them as a table.
    • @coderabbitai show all the console.log statements in this repository.
    • @coderabbitai read src/utils.ts and generate unit testing code.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (invoked as PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger a review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai help to get help.

Additionally, you can add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.

CodeRabbit Configration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

src/docs/releases/2.0.0.md Outdated Show resolved Hide resolved
Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

Out of diff range and nitpick comments (4)
src/docs/releases/2.0.0.md (4)

Line range hint 13-13: Add spaces between sentences for better readability.

- Instead, we have transitioned to utilize `System.Text.Json` due to its enhanced performance capabilities. To ensure compatibility with `System.Text.Json` during the serialization or deserialization of objects, the following steps need to be undertaken:
+ Instead, we have transitioned to utilize `System.Text.Json` due to its enhanced performance capabilities. To ensure compatibility with `System.Text.Json` during the serialization or deserialization of objects, the following steps need to be undertaken:

Line range hint 29-29: Correct the typo for accuracy.

- custom admin menu nodep like this:
+ custom admin menu node like this:

Line range hint 88-88: Consider adding a comma for clarity.

- The `OrchardCore_Twitter` key continues to work but will be deprecated in a future release.
+ The `OrchardCore_Twitter` key continues to work, but will be deprecated in a future release.

Line range hint 199-199: Add a space after the period for better readability.

- If you want to continue to index `.PDF` file you'll need to enable the `OrchardCore.Media.Indexing.Pdf` feature.
+ If you want to continue to index `.PDF` file, you'll need to enable the `OrchardCore.Media.Indexing.Pdf` feature.

src/docs/releases/2.0.0.md Outdated Show resolved Hide resolved
Co-authored-by: Zoltán Lehóczky <[email protected]>
Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

Out of diff range and nitpick comments (5)
src/docs/releases/2.0.0.md (5)

Line range hint 13-13: Add a space after the period for better readability.

- The utilization of [Newtonsoft.Json](https://www.nuget.org/packages/Newtonsoft.Json) has been discontinued in both **YesSql** and **OrchardCore**. Instead, we have transitioned to utilize `System.Text.Json` due to its enhanced performance capabilities.
+ The utilization of [Newtonsoft.Json](https://www.nuget.org/packages/Newtonsoft.Json) has been discontinued in both **YesSql** and **OrchardCore**. Instead, we have transitioned to utilize `System.Text.Json` due to its enhanced performance capabilities. 

Line range hint 29-29: The word "nodep" seems to be a typo. Consider correcting it to "node".

- services.AddSingleton<IAdminNodeProviderFactory>(new AdminNodeProviderFactory<PlaceholderAdminNode>());
+ services.AddSingleton<IAdminNodeProviderFactory>(new AdminNodeProviderFactory<PlaceholderAdminNode>());

Line range hint 43-43: The term "sub-classes" is typically written as one word: "subclasses".

- Any serializable object that contains a polymorphic property (a base type that can contain sub-classes instances) needs to register all possible sub-classes this way:
+ Any serializable object that contains a polymorphic property (a base type that can contain subclasses instances) needs to register all possible subclasses this way:

Line range hint 199-199: Add a space after the period for better readability.

- Previously, `.pdf` files were automatically indexed in the search providers (Elasticsearch, Lucene or Azure AI Search). Now, if you want to continue to index `.PDF` file you'll need to enable the `OrchardCore.Media.Indexing.Pdf` feature.
+ Previously, `.pdf` files were automatically indexed in the search providers (Elasticsearch, Lucene or Azure AI Search). Now, if you want to continue to index `.PDF` file you'll need to enable the `OrchardCore.Media.Indexing.Pdf` feature. 

Line range hint 335-335: Consider using a comma before 'so' to connect two independent clauses.

- This means you don't have to define these admin routes in your module's `Startup` class anymore, but that option is still available and supported.
+ This means you don't have to define these admin routes in your module's `Startup` class anymore, but that option is still available and supported, so the names can be unique for each action.

@MikeAlhayek
Copy link
Member Author

@Piedone look at that failing test. This should not fail since we purposely not add the latest release notes to the navbar. Do you want to fix the Workflow or should be add it to the navbar?

@Piedone
Copy link
Member

Piedone commented May 1, 2024

@MikeAlhayek
Copy link
Member Author

MikeAlhayek commented May 1, 2024

Passed! Thank you

Copy link
Contributor

github-actions bot commented May 1, 2024

This pull request has merge conflicts. Please resolve those before requesting a review.

Copy link
Member

@Piedone Piedone left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good after the nit and resolving merge conflicts.

src/docs/releases/2.0.0.md Show resolved Hide resolved

Release date: Not yet released

## Upgrade Instructions

Before upgrading to Orchard Core 2.0, you should first upgrade to 1.8, address any warnings, and only then upgrade to 2.0. Be sure to review the list of breaking changes documented below to ensure a seamless transition.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Add a space after the period for better readability.

- Before upgrading to Orchard Core 2.0, you should first upgrade to 1.8, address any warnings, and only then upgrade to 2.0. Be sure to review the list of breaking changes documented below to ensure a seamless transition.
+ Before upgrading to Orchard Core 2.0, you should first upgrade to 1.8, address any warnings, and only then upgrade to 2.0. Be sure to review the list of breaking changes documented below to ensure a seamless transition. 

Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation.

Suggested change
Before upgrading to Orchard Core 2.0, you should first upgrade to 1.8, address any warnings, and only then upgrade to 2.0. Be sure to review the list of breaking changes documented below to ensure a seamless transition.
Before upgrading to Orchard Core 2.0, you should first upgrade to 1.8, address any warnings, and only then upgrade to 2.0. Be sure to review the list of breaking changes documented below to ensure a seamless transition.

@MikeAlhayek MikeAlhayek merged commit c967b5d into main May 2, 2024
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants