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

chore: Misc. typos #1740

Merged
merged 12 commits into from
Jan 28, 2025
Merged

chore: Misc. typos #1740

merged 12 commits into from
Jan 28, 2025

Conversation

oskogstad
Copy link
Collaborator

@oskogstad oskogstad commented Jan 27, 2025

This changes a domain event property name

There might be events in the db/on the bus with the old property name at the time of deployment, so for a time we need to check for both.

When we are certain there are no events with the old name left, we can remove the old property (and the nullability)

@oskogstad oskogstad requested a review from a team as a code owner January 27, 2025 09:44
Copy link
Contributor

coderabbitai bot commented Jan 27, 2025

📝 Walkthrough

Walkthrough

The pull request introduces various textual corrections across multiple files in the Dialogporten project. Key changes include correcting the spelling of "occured" to "occurred," adjusting hyphenation in phrases such as "up-to-date" to "up to date," and refining error messages for consistency. Additionally, property names have been updated to improve clarity, such as changing OccuredAt to OccurredAt. These adjustments are purely editorial and do not affect the functional behavior of the code.

Changes

File Path Change Summary
src/Digdir.Domain.Dialogporten.Application/...SyncSubjectMapCommand.cs Removed hyphen in logging message from "up-to-date" to "up to date."
src/Digdir.Domain.Dialogporten.Infrastructure/Persistence/Interceptors/...ConvertDomainEventsToOutboxMessagesInterceptor.cs Updated error message to include hyphen in "lazy-loaded" and corrected property name from OccuredAt to OccurredAt.
docs/schema/V1/swagger.verified.json Corrected spelling of "occurred" in multiple API response descriptions.
src/Digdir.Domain.Dialogporten.Domain/Common/EventPublisher/...IDomainEvent.cs Renamed property from OccuredAt to OccurredAt and updated comment grammar.
src/Digdir.Domain.Dialogporten.WebApi/Common/Constants.cs Corrected spelling from "occured" to "occurred" in error message constants.
src/Digdir.Domain.Dialogporten.WebApi/Endpoints/V1/ServiceOwner/Dialogs/Patch/...PatchDialogsController.cs Updated comments to use "occurred" instead of "occured."
src/Digdir.Domain.Dialogporten.Application/...AltinnForwarders/DialogActivityEventToAltinnForwarder.cs Changed assignment logic for Time property to use OccurredAt.
src/Digdir.Domain.Dialogporten.Application/...AltinnForwarders/DialogEventToAltinnForwarder.cs Updated assignment logic for Time property to use OccurredAt.
src/Digdir.Domain.Dialogporten.Domain/Common/DomainEvents/...DomainEvent.cs Added new OccurredAt property and retained OccuredAt property.
src/Digdir.Domain.Dialogporten.Domain/Outboxes/...OutboxMessage.cs Corrected assignment in Create method to use OccurredAt instead of OccuredAt.

Possibly related PRs

Suggested reviewers

  • MagnusSandgren
  • knuhau

📜 Recent review details

Configuration used: .coderabbit.yaml
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between d1318b7 and 0d7210f.

📒 Files selected for processing (5)
  • src/Digdir.Domain.Dialogporten.Application/Features/V1/Common/Events/AltinnForwarders/DialogActivityEventToAltinnForwarder.cs (1 hunks)
  • src/Digdir.Domain.Dialogporten.Application/Features/V1/Common/Events/AltinnForwarders/DialogEventToAltinnForwarder.cs (4 hunks)
  • src/Digdir.Domain.Dialogporten.Domain/Common/DomainEvents/DomainEvent.cs (1 hunks)
  • src/Digdir.Domain.Dialogporten.Domain/Common/EventPublisher/IDomainEvent.cs (1 hunks)
  • src/Digdir.Domain.Dialogporten.Domain/Outboxes/OutboxMessage.cs (1 hunks)
🚧 Files skipped from review as they are similar to previous changes (5)
  • src/Digdir.Domain.Dialogporten.Domain/Common/DomainEvents/DomainEvent.cs
  • src/Digdir.Domain.Dialogporten.Application/Features/V1/Common/Events/AltinnForwarders/DialogActivityEventToAltinnForwarder.cs
  • src/Digdir.Domain.Dialogporten.Application/Features/V1/Common/Events/AltinnForwarders/DialogEventToAltinnForwarder.cs
  • src/Digdir.Domain.Dialogporten.Domain/Outboxes/OutboxMessage.cs
  • src/Digdir.Domain.Dialogporten.Domain/Common/EventPublisher/IDomainEvent.cs
⏰ Context from checks skipped due to timeout of 90000ms (3)
  • GitHub Check: Dry run deploy apps / Deploy job sync-resource-policy-information-job to test
  • GitHub Check: Dry run deploy apps / Deploy job sync-subject-resource-mappings-job to test
  • GitHub Check: build / build-and-test

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>, please review it.
    • 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 gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @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.
    • @coderabbitai help me debug CodeRabbit configuration file.

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 using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai generate docstrings to generate docstrings for this PR. (Beta)
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

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.

@oskogstad oskogstad mentioned this pull request Jan 27, 2025
@oskogstad oskogstad changed the title chore: Fix typos and grammars chore: Misc. typos Jan 27, 2025
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: 4

🧹 Nitpick comments (1)
src/Digdir.Domain.Dialogporten.Domain/Common/EventPublisher/IDomainEvent.cs (1)

18-20: LGTM! Consider tracking the deprecation.

Good approach making the property nullable and adding clear documentation about the planned removal.

Would you like me to help create an issue to track the removal of this property once all message bus references are cleared?

📜 Review details

Configuration used: .coderabbit.yaml
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between ab9e532 and 40db30b.

📒 Files selected for processing (6)
  • src/Digdir.Domain.Dialogporten.Application/Features/V1/Common/Events/AltinnForwarders/DialogActivityEventToAltinnForwarder.cs (1 hunks)
  • src/Digdir.Domain.Dialogporten.Application/Features/V1/Common/Events/AltinnForwarders/DialogEventToAltinnForwarder.cs (4 hunks)
  • src/Digdir.Domain.Dialogporten.Domain/Common/DomainEvents/DomainEvent.cs (1 hunks)
  • src/Digdir.Domain.Dialogporten.Domain/Common/EventPublisher/IDomainEvent.cs (1 hunks)
  • src/Digdir.Domain.Dialogporten.Domain/Outboxes/OutboxMessage.cs (1 hunks)
  • src/Digdir.Domain.Dialogporten.Infrastructure/Persistence/Interceptors/ConvertDomainEventsToOutboxMessagesInterceptor.cs (2 hunks)
🚧 Files skipped from review as they are similar to previous changes (1)
  • src/Digdir.Domain.Dialogporten.Infrastructure/Persistence/Interceptors/ConvertDomainEventsToOutboxMessagesInterceptor.cs
⏰ Context from checks skipped due to timeout of 90000ms (1)
  • GitHub Check: build / build-and-test
🔇 Additional comments (1)
src/Digdir.Domain.Dialogporten.Domain/Common/EventPublisher/IDomainEvent.cs (1)

22-25: LGTM! Verify consumer updates.

The new property is well-documented and correctly typed.

Let's verify that consumers are updated to use the new property:

✅ Verification successful

Migration strategy for OccurredAt property is properly implemented

The codebase shows a well-thought-out transition:

  • Old property is maintained for message bus compatibility
  • Consumers handle both properties with proper fallback
  • New code correctly sets the new property
🏁 Scripts executed

The following scripts were executed for the analysis:

Script:

#!/bin/bash
# Search for any remaining direct usage of OccuredAt
rg -l "OccuredAt" --type cs

# Search for places where OccurredAt is used to ensure proper migration
rg -l "OccurredAt" --type cs

Length of output: 1027


Script:

#!/bin/bash
# Check actual usage context of both spellings
echo "=== Checking OccuredAt usage ==="
rg "OccuredAt" --type cs -C 2

echo -e "\n=== Checking OccurredAt usage ==="
rg "OccurredAt" --type cs -C 2

Length of output: 12662

knuhau
knuhau previously approved these changes Jan 27, 2025
arealmaas
arealmaas previously approved these changes Jan 27, 2025
@oskogstad oskogstad dismissed stale reviews from arealmaas and knuhau via c404d5c January 28, 2025 12:24
MagnusSandgren
MagnusSandgren previously approved these changes Jan 28, 2025
@oskogstad oskogstad merged commit d83c7a0 into main Jan 28, 2025
23 checks passed
@oskogstad oskogstad deleted the chore/fix-typos-and-grammars branch January 28, 2025 15:17
arealmaas pushed a commit that referenced this pull request Jan 29, 2025
🤖 I have created a release *beep* *boop*
---


##
[1.47.4](v1.47.3...v1.47.4)
(2025-01-29)


### Miscellaneous Chores

* **deps:** update dependency coverlet.collector to 6.0.4
([#1750](#1750))
([7d8bb26](7d8bb26))
* **deps:** update dependency vitest to v3.0.3
([#1748](#1748))
([6ee8d28](6ee8d28))
* **deps:** update otel/opentelemetry-collector-contrib docker tag to
v0.118.0 ([#1751](#1751))
([2e3ae4d](2e3ae4d))
* Misc. typos
([#1740](#1740))
([d83c7a0](d83c7a0))

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).
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.

4 participants