First off, I am no programmer by any means. I’ve inherited a BIM Management role at my company and we have been using a customised clone of pyRevit located on a local server.
While I have been able to fix some issues that the users are having, one has stumped me for some time now. When I run pyrevit clones add <clone name> "<path>" it shows as a clone correctly in the CLI.
However, when I run pyrevit attach <clone name> default --installed --all users and check the attached clones it reads as something like this:
The clone name that gets reported does not match the expected clone name. The version that is being used is 5.1.0.25094+1133. It works on many other users machine’s no problem. The path is a server at our office. However when installing a pyRevit master on the machine directly, the attachment works no problem.
Below is a screenshot of the error message that comes up when opening up Revit, regardless of the year.
Well - line 53 is coming up and persona non grata. No attachment or no engine. (Last line.)
Not enough iinfo to answer your question - but if I had to guess -
pyRevitLoader.py is the wrong version or the pyRevit version is not for your version of Revit.
D*mn clones.
if attachment and attachment.Clone:
envvars.set_pyrevit_env_var(envvars.CLONENAME_ENVVAR, attachment.Clone.Name)
envvars.set_pyrevit_env_var(
envvars.IPYVERSION_ENVVAR, str(attachment.Engine.Version)
)
Is what you’ve attached how it should look? If so, from what I can tell the code looks the same compared to a separate master file I have installed on my own workstation, and I do not have this issue.
This is also just a unique circumstance for this one user. Other users don’t have this same issue popping up. We are running Revit 2022, 2024, and 2026 without much complication (or at least not this type of error has been reported). To clarify as well, the Unnamed clone name and engine version issue applies to all Revit installations for this user, not just 2024.
If providing debug information would be helpful, which debug information should I provide? Through the attachment command?
No - the code is the code from pyRevit where your error is coming from.
If the others are working - you need to figure out what is different. All same pyRevit versions? All same python versions? .Net versions? etc, etc… Something is differnt.
Running pyrevit env on both machines and comparing the output may be a good start.
Runnint pyrevit attach with the --log flag may also help.
Also AllUsers indicates a admin install, which puts some stuff into ProgramData and is known to cause troubles on some machines. 6.5.5 tried to fix some of these issues.