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

feat: dont simulate if there are no plots or secondary params #574

Merged
merged 5 commits into from
Nov 21, 2024

Conversation

martinjrobins
Copy link
Contributor

No description provided.

Copy link

codecov bot commented Nov 21, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 76.17%. Comparing base (c227f57) to head (34c94a4).
Report is 12 commits behind head on ui-enhancements.

Additional details and impacted files
@@               Coverage Diff                @@
##           ui-enhancements     #574   +/-   ##
================================================
  Coverage            76.17%   76.17%           
================================================
  Files                  108      108           
  Lines                 5600     5600           
================================================
  Hits                  4266     4266           
  Misses                1334     1334           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.


🚨 Try these New Features:

Copy link
Collaborator

@eatyourgreens eatyourgreens left a comment

Choose a reason for hiding this comment

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

LGTM! I think there's a useEffect that you can remove. Maybe run yarn format if you haven't already got VSCode set up to run Prettier when you save changes.

@@ -17,8 +17,11 @@ import UnitField from "../../components/UnitField";
import SimulationSliderView from "./SimulationSliderView";
import HelpButton from "../../components/HelpButton";
import { ExpandLess, ExpandMore } from "@mui/icons-material";
import { ChangeEvent, useState } from "react";
import { ChangeEvent, useEffect, useState } from "react";
Copy link
Collaborator

Choose a reason for hiding this comment

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

I don't think this component uses any effect hooks.

@@ -70,6 +76,7 @@ export default function useSimulation(
simulate,
JSON.stringify(simInputs),
page,
runSimulation,
]);
Copy link
Collaborator

Choose a reason for hiding this comment

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

At some point, I think I should rewrite this hook, to see if I can reduce the number of dependencies for this effect.

@eatyourgreens
Copy link
Collaborator

I'll wait for this to merge before merging #575, to avoid conflicts.

Copy link

Copy link

Quality Gate Failed Quality Gate failed for 'pkpdapp-team_pkpdapp_frontend'

Failed conditions
0.0% Coverage on New Code (required ≥ 80%)

See analysis details on SonarQube Cloud

@eatyourgreens eatyourgreens merged commit daa80f2 into ui-enhancements Nov 21, 2024
8 of 9 checks passed
@eatyourgreens eatyourgreens deleted the no-simulate-no-plot branch November 21, 2024 10:22
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.

2 participants