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

Fix #8822 - new warning to explain why Standard62.1Summary may not be available in Output:Table:SummaryReports #8831

Merged
merged 5 commits into from
Jul 26, 2021

Conversation

jmarrec
Copy link
Contributor

@jmarrec jmarrec commented Jun 18, 2021

Pull request overview

Pull Request Author

Add to this list or remove from it as applicable. This is a simple templated set of guidelines.

  • Title of PR should be user-synopsis style (clearly understandable in a standalone changelog context)
  • Label the PR with at least one of: Defect, Refactoring, NewFeature, Performance, and/or DoNoPublish
  • Pull requests that impact EnergyPlus code must also include unit tests to cover enhancement or defect repair
  • Author should provide a "walkthrough" of relevant code changes using a GitHub code review comment process
  • If any diffs are expected, author must demonstrate they are justified using plots and descriptions
  • If changes fix a defect, the fix should be demonstrated in plots and descriptions
  • If any defect files are updated to a more recent version, upload new versions here or on DevSupport
  • If IDD requires transition, transition source, rules, ExpandObjects, and IDFs must be updated, and add IDDChange label
  • If structural output changes, add to output rules file and add OutputChange label
  • If adding/removing any LaTeX docs or figures, update that document's CMakeLists file dependencies

Reviewer

This will not be exhaustively relevant to every PR.

  • Perform a Code Review on GitHub
  • If branch is behind develop, merge develop and build locally to check for side effects of the merge
  • If defect, verify by running develop branch and reproducing defect, then running PR and reproducing fix
  • If feature, test running new feature, try creative ways to break it
  • CI status: all green or justified
  • Check that performance is not impacted (CI Linux results include performance check)
  • Run Unit Test(s) locally
  • Check any new function arguments for performance impacts
  • Verify IDF naming conventions and styles, memos and notes and defaults
  • If new idf included, locally check the err file and other outputs

@jmarrec jmarrec added the Defect Includes code to repair a defect in EnergyPlus label Jun 18, 2021
@jmarrec jmarrec self-assigned this Jun 18, 2021
Comment on lines 1697 to 1707
if (UtilityRoutines::SameString(AlphArray(iReport), "Standard62.1Summary")) {
ShowWarningError(state,
format("{} Field[{}]=\"Standard62.1Summary\", Report is not enabled.", CurrentModuleObject, iReport));
ShowContinueError(state, "Do Zone Sizing or Do System Sizing must be enabled in SimulationControl.");

} else {
ShowSevereError(
state,
format("{} Field[{}]=\"{}\", invalid report name -- will not be reported.", CurrentModuleObject, iReport, AlphArray(iReport)));
// ErrorsFound=.TRUE.
}
Copy link
Contributor Author

Choose a reason for hiding this comment

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

New warning to explain.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

ref code :

// Standard62Report
if (state.dataGlobal->DoZoneSizing || state.dataGlobal->DoSystemSizing) {
s->pdrStd62 = newPreDefReport(state, "Standard62.1Summary", "Std62", "Standard 62.1 Summary");

Comment on lines +9784 to +9798
TEST_F(EnergyPlusFixture, OutputReportTabularTest_PredefinedTable_Standard62_1_NoSizing)
{
// Test for #8822 - new warning to explain why Standard62.1 report is not enabled
std::string const idf_objects = delimited_string({
"Output:Table:SummaryReports,",
" Standard62.1Summary; !- Report 1 Name",
});

ASSERT_TRUE(process_idf(idf_objects));

// These are already set to these values, but be explicit.
// Because DoZoneSizing and DoSystemSizing are both false Standard62.1Summary is **not** enabled
state->files.outputControl.tabular = true;
state->dataGlobal->DoZoneSizing = false;
state->dataGlobal->DoSystemSizing = false;
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Test that the warning is issued when sizing calcs are NOT requested

Comment on lines +9819 to +9832
TEST_F(EnergyPlusFixture, OutputReportTabularTest_PredefinedTable_Standard62_1_WithSizing)
{
// Test for #8822 - ensures that when Zone/System sizing is requested, the report is there and the warning isn't.
std::string const idf_objects = delimited_string({
"Output:Table:SummaryReports,",
" Standard62.1Summary; !- Report 1 Name",
});

ASSERT_TRUE(process_idf(idf_objects));

// Because DoZoneSizing is true Standard62.1Summary **is** enabled
state->files.outputControl.tabular = true;
state->dataGlobal->DoZoneSizing = true;
state->dataGlobal->DoSystemSizing = false;
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Test that the warning is NOT issued when sizing calcs are requested

Comment on lines +400 to +404
The Standard 62.1 Summary (key: Standard62.1Summary) produces a report that is consistent with many of the outputs needed when doing calculations consistent with ASHRAE Standard 62.1-2010.

\textbf{Note: The report is only generated when sizing calculations are specified.}: in \hyperref[simulationcontrol]{SimulationControl}, ``Do Zone Sizing'' or ``Do System Sizing'' must be set to ``Yes''.

The abbreviations used in the report are consistent with the abbreviations used in Appendix A4 of the Standard. The following tables are part of the report:
Copy link
Contributor Author

Choose a reason for hiding this comment

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

image

Comment on lines +2754 to +2758
This report is more fully described in the Input Output Reference. The Standard 62.1 Summary produces a report that is consistent with many of the outputs needed when doing calculations consistent with ASHRAE Standard 62.1-2010.

The abbreviations used in the report are consistent with the abbreviations used in Appendix A4 of the Standard. Directly following is an example of the report. The key used to obtain this report is Standard62.1Summary.

\textbf{Note: The report is only generated when sizing calculations are specified.}: in \hyperref[simulationcontrol]{SimulationControl}, ``Do Zone Sizing'' or ``Do System Sizing'' must be set to ``Yes''.
Copy link
Contributor Author

Choose a reason for hiding this comment

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

image

@nrel-bot-2c
Copy link

@jmarrec @lgentile it has been 28 days since this pull request was last updated.

@JasonGlazer
Copy link
Contributor

@jmarrec I was going to start reviewing this but noticed that it had some formatting checks failing. Can you fix those and the merge conflict? Thanks.

@jmarrec
Copy link
Contributor Author

jmarrec commented Jul 23, 2021

@JasonGlazer Merged develop and clang-formatted.

@JasonGlazer
Copy link
Contributor

Thanks @jmarrec

@JasonGlazer JasonGlazer self-requested a review July 23, 2021 16:32
Copy link
Contributor

@JasonGlazer JasonGlazer 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 @jmarrec

@JasonGlazer
Copy link
Contributor

This is ready to be merged.

@jmarrec
Copy link
Contributor Author

jmarrec commented Jul 26, 2021

Thanks for the review @JasonGlazer !

@mjwitte mjwitte merged commit 2955d1c into develop Jul 26, 2021
@mjwitte mjwitte deleted the 8822_Standard621_SummaryReports branch July 26, 2021 14:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Defect Includes code to repair a defect in EnergyPlus
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Standard62.1Summary not be treated as valid report name in Output:Table:SummaryReports
8 participants