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

Fixes #2244 PK-Analysis for multiple administration corrupted #2245

Merged

Conversation

rwmcintosh
Copy link
Member

Fixes #2244

Description

The location of the applications container has changed. I think we have to look in two places now for applications

Type of change

Please mark relevant options with an x in the brackets.

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • This change requires documentation changes (link at least one user or developer documentation issue):
  • Algorithm update - updates algorithm documentation/questions/answers etc.
  • Other (please describe):

How Has This Been Tested?

Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce. Please also list any relevant details for your test configuration

  • Integration tests
  • Unit tests
  • Manual tests
  • No tests required

Reviewer checklist

Mark everything that needs to be checked before merging the PR.

  • Check if the code is well documented
  • Check if the behavior is what is expected
  • Check if the code is well tested
  • Check if the code is readable and well formatted
  • Additional checks (document below if any)
  • Check if documentation update issue(s) are created if the option This change requires a documentation update above is selected

Screenshots (if appropriate):

Questions (if appropriate):

I'm unsure on the best implementation. The PR is just for discussion until then.

@rwmcintosh rwmcintosh added this to the Version 12 milestone May 10, 2024
@rwmcintosh rwmcintosh self-assigned this May 10, 2024
private static IReadOnlyList<IContainer> allApplicationsForMolecule(IModelCoreSimulation simulation, string moleculeName)
{
var applicationEventGroup = simulation.Model.Root.GetChildren<EventGroup>().ToList();
var applicationsFromEventContainer = getEventGroupsFrom(simulation.Model.Root.GetSingleChildByName<IContainer>(Constants.EVENTS));
Copy link
Member Author

Choose a reason for hiding this comment

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

So, yeah, for now, I just combined the two known locations where we might find applications.

Copy link
Member Author

Choose a reason for hiding this comment

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

Try to remove the knowledge of container name by getting all children of type eventgroup. Check that this method is called sparingly.

Copy link
Member Author

Choose a reason for hiding this comment

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

Or maybe the 'Events' container should be of type 'EventGroup' instead of other

@rwmcintosh rwmcintosh requested a review from msevestre May 13, 2024 15:52
@msevestre msevestre merged commit 01a9d4c into develop May 15, 2024
1 check passed
@msevestre msevestre deleted the 2244-v12-pk-analysis-for-multiple-administration-corrupted branch May 15, 2024 18:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
No open projects
Status: Verified
Development

Successfully merging this pull request may close these issues.

V12: PK-Analysis for multiple administration corrupted
2 participants