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

Mission run refactor #864

Closed
wants to merge 10 commits into from
Closed

Mission run refactor #864

wants to merge 10 commits into from

Conversation

andchiind
Copy link
Contributor

No description provided.

@github-actions
Copy link

🔔 Changes in database folder detected 🔔
Do these changes require adding new migrations? 🤔 In that case follow these steps.
If you are uncertain, ask a database admin on the team 😄

@andchiind
Copy link
Contributor Author

In this PR the Area attribute is currently nullable whilst the AssetCode value is used instead. In the future AssetCode should be removed in favour of Area, which contains the AssetCode, but populating the Area values is left for another PR.

@andchiind andchiind linked an issue Jun 19, 2023 that may be closed by this pull request
@andchiind andchiind added this to the Inspection Plan milestone Jun 19, 2023
backend/api/Controllers/AreaController.cs Outdated Show resolved Hide resolved
backend/api/Controllers/AreaController.cs Outdated Show resolved Hide resolved
backend/api/Controllers/AreaController.cs Outdated Show resolved Hide resolved
@aeshub aeshub removed this from the Inspection Plan milestone Jun 23, 2023
{
[Key]
[DatabaseGenerated(DatabaseGeneratedOption.Identity)]
public string Id { get; set; }

[MaxLength(200)]
public int? EchoMissionId { get; set; }
public string? MissionId { get; set; }
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
public string? MissionId { get; set; }
public MissionDefinition MissionDefinition { get; set; }

I don't think this should be optional, please correct me if I'm wrong. Also if we are pointing to the ID it makes more sense to point straight to the model.

Copy link
Contributor

Choose a reason for hiding this comment

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

In addition, I think this field will be breaking for all old missions in the database.

Copy link
Contributor

Choose a reason for hiding this comment

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

You could set the MissionDefinition as optional for now such that this does not break compatability with old missions and then create an issue which is to add a MissionDefinition for all old missions such that this one may be made required.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I also think it would be nice to include MissionDefinition here. See this comment for why I have not yet implemented it: #864 (comment)

@andchiind andchiind force-pushed the mission-run-refactor branch 4 times, most recently from 9348cbe to 54782ac Compare July 18, 2023 12:11
Copy link
Contributor

@mrica-equinor mrica-equinor left a comment

Choose a reason for hiding this comment

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

LGTM :)

@andchiind andchiind dismissed aeshub’s stale review July 24, 2023 09:15

Requests have been addressed while reviewer is on holiday

@andchiind
Copy link
Contributor Author

/UpdateDatabase

@github-actions
Copy link

⛔ Cannot update database until the Pull Request is approved! ⛔

@andchiind
Copy link
Contributor Author

/UpdateDatabase

@github-actions
Copy link

⛔ Cannot update database until the Pull Request is approved! ⛔

@andchiind
Copy link
Contributor Author

/UpdateDatabase

@github-actions
Copy link

⛔ Cannot update database until the Pull Request is approved! ⛔

@andchiind
Copy link
Contributor Author

Merged branch in another PR

@andchiind andchiind closed this Jul 27, 2023
@andchiind andchiind deleted the mission-run-refactor branch August 3, 2023 10:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backend Backend related functionality breaking-change A breaking change which introduces changes to the public APIs database-change Will require migration frontend Frontend related functionality
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add "source" to "missionDefinition"
4 participants