MEPover Connector.Shape Nulls in Revit 2023

Hey there! If the MEPover package author is on here, first off your package is a god-send. It’s helped out a ton and I really appreciate the efforts you’ve put into creating it and maintaining it. Thank you, thank you, thank you. Here’s the situation…

I’m QC’ing my company’s scripts as we get things ready for R23 and the Connector.Shape node is spitting out null where in previous Revit versions it used to output “Rectangular”, “Round”, etc.

Looking under the hood in the Python node, if I take out the try and except error handling there’s a warning about ToString().

If I take out the ToString(), then it outputs some integers (or maybe those are IDs?). Not sure if that helps at all in troubleshooting.

I’ve scoured the Revit API docs website and tried everything I could think of to find the solution on my own, but I’ve hit the limits of my API / Python knowledge.

Thanks for any help you all can provide!

1 Like

@jpclark ,

you are using correct template ?

import clr

clr.AddReference('RevitAPI')
from Autodesk.Revit.DB import *
from Autodesk.Revit.DB.Structure import *

clr.AddReference('RevitAPIUI')
from Autodesk.Revit.UI import *

clr.AddReference('System')
from System.Collections.Generic import List

clr.AddReference('RevitNodes')
import Revit
clr.ImportExtensions(Revit.GeometryConversion)
clr.ImportExtensions(Revit.Elements)

clr.AddReference('RevitServices')
import RevitServices
from RevitServices.Persistence import DocumentManager
from RevitServices.Transactions import TransactionManager

doc = DocumentManager.Instance.CurrentDBDocument
uidoc=DocumentManager.Instance.CurrentUIApplication.ActiveUIDocument

#Preparing input from dynamo to revit
element = UnwrapElement(IN[0])

#Do some action in a Transaction
TransactionManager.Instance.EnsureInTransaction(doc)

TransactionManager.Instance.TransactionTaskDone()

OUT = element

That’s odd. I’m also returning the same integer values from the enumerable, but Lookup still shows them as shapes (as does API documentation). Not sure what’s going on here.

Just in case you’re stuck at the moment, the enumerables are as follows:

-1 - None
 0 - Round
 1 - Rectangular
 2 - Oval
1 Like

@Draxl_Andreas Yes. All the Python headers look correct. Good idea though. The node has worked great in the last 4 Revit versions prior to 2023, so my guess is some thing changed with the new version, like @Nick_Boyts alluded to.

For any people have same case. Try with this : Class Connector | Open MEP

1 Like

I think i may have stumbled upon the same problem, im getting nulls in R2013 too.

I dont see a resolution here, was it resolved?