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

"HVACTemplate Any Number". Overwriting existing object #174

Open
atahosseini opened this issue Oct 25, 2019 · 3 comments
Open

"HVACTemplate Any Number". Overwriting existing object #174

atahosseini opened this issue Oct 25, 2019 · 3 comments
Labels

Comments

@atahosseini
Copy link

Hello all

I tried to use eppy for adding some building blocks. The problem is that as soon as I reach this part of the code which is also used in the document of the "geomeppy" I get an error. I'm talking about this part:

stat = idf.newidfobject(
"HVACTEMPLATE:THERMOSTAT",
Name="Zone Stat",
Constant_Heating_Setpoint=20,
Constant_Cooling_Setpoint=25,)

and the error I get is this:

** Severe ** Duplicate name found. name: "HVACTemplate Any Number". Overwriting existing object.

idf.run(expandobjects=True) didn't solve the problem

Any help is appreciated.

@jamiebull1
Copy link
Owner

What does your IDF look like? It looks like you've added two ScheduleTypeLimits objects with the same name, "HVACTemplate Any Number", but can't be sure.

@atahosseini
Copy link
Author

atahosseini commented Oct 28, 2019

Hi Jamie

I haven't defined any "scheduletypelimit". Not sure why I get this weird error

@atahosseini
Copy link
Author

I found the problem and the solution. When eppy or "geomeppy" runs the file, sometimes, it doesn't replace the previous file with the new one. Therefore, it tries to overwrite the previous file which contributes to an error. This may be rather the EnergyPlus problem. Anyways, What I did in my code I just added a line to delete the previous file before "geomeppy" runs the file like this:

import os
os.remove("eplustbl.htm")
os.remove("eplusout.expidf")

IDF.setiddname("C:\EnergyPlusV8-9-0\Energy+.idd")
idf = IDF("C:\EnergyPlusV8-9-0\EVTEST.idf")
idf.epw = ("C:\EnergyPlusV8-9-0\WeatherData\Vancouver\CAN_BC_Vancouver.718920_CWEC.epw")

@jamiebull1 jamiebull1 added the bug label Nov 11, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants