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

PyRevit PreFlight Checks doesn't execute #1289

Closed
Robbo1234 opened this issue Jul 1, 2021 · 2 comments
Closed

PyRevit PreFlight Checks doesn't execute #1289

Robbo1234 opened this issue Jul 1, 2021 · 2 comments

Comments

@Robbo1234
Copy link

Describe the bug
Replace these lines with your description. Be as specific as possible and list steps to reproduce the issue. If you have any suggestions for the solution please list that as well.

If you have installed pyRevit, and the installation completed with no errors but pyRevit doesn't load, please run the command below in terminal. This should fix the issue on your machine, however, please continue filing the issue with instructions below.

pyrevit attach master 277 --installed

To Reproduce
Steps to reproduce the behavior:

  1. Click on 'PreFlight Checks'

Desktop (please complete the following information):

  • OS: [Windows 10]
  • pyRevit Version [4.8.8]
  • pyRevit Environment: Microsoft Windows [Version 10.0.19041.985]
    (c) Microsoft Corporation. All rights reserved.

C:\Users\rob.cross>pyrevit env
==> Registered Clones (full git repos)
==> Registered Clones (deployed from archive/image)
master | Deploy: "basepublic" | Branch: "master" | Version: "4.8.8" | Path: "C:\Users\rob.cross\AppData\Roaming\pyRevit-Master"
==> Attachments
master | Product: "Autodesk Revit 2022" | Engine: IPY277 (277) | Path: "C:\Users\rob.cross\AppData\Roaming\pyRevit-Master"
master | Product: "Autodesk Revit 2021" | Engine: IPY277 (277) | Path: "C:\Users\rob.cross\AppData\Roaming\pyRevit-Master"
master | Product: "Autodesk Revit 2020" | Engine: IPY277 (277) | Path: "C:\Users\rob.cross\AppData\Roaming\pyRevit-Master"
master | Product: "Autodesk Revit 2019" | Engine: IPY277 (277) | Path: "C:\Users\rob.cross\AppData\Roaming\pyRevit-Master"
master | Product: "2018.3.3 Security Fix" | Engine: IPY277 (277) | Path: "C:\Users\rob.cross\AppData\Roaming\pyRevit-Master"
master | Product: "2017.2.5 Security Fix" | Engine: IPY277 (277) | Path: "C:\Users\rob.cross\AppData\Roaming\pyRevit-Master"
master | Product: "2016.1.9 Security Fix" | Engine: IPY277 (277) | Path: "C:\Users\rob.cross\AppData\Roaming\pyRevit-Master"
master | Product: "2015 Release 2 (Subscription only release)" | Engine: IPY277 (277) | Path: "C:\Users\rob.cross\AppData\Roaming\pyRevit-Master"
master | Product: "2014 Update Release 3" | Engine: IPY277 (277) | Path: "C:\Users\rob.cross\AppData\Roaming\pyRevit-Master"
==> Installed Extensions
==> Default Extension Search Path
C:\Users\rob.cross\AppData\Roaming\pyRevit\Extensions
==> Extension Search Paths
==> Extension Sources - Default
https://github.com/eirannejad/pyRevit/raw/master/extensions/extensions.json
==> Extension Sources - Additional
==> Installed Revits
Autodesk Revit 2022 | Version: 22.0.2.392 | Build: 20210224_1515(x64) | Language: 1033 | Path: "C:\Program Files\Autodesk\Revit 2022"
Autodesk Revit 2021 | Version: 21.1.30.74 | Build: 20210426_1515(x64) | Language: 1033 | Path: "C:\Program Files\Autodesk\Revit 2021"
Autodesk Revit 2020 | Version: 20.2.40.65 | Build: 20210420_1515(x64) | Language: 1033 | Path: "C:\Program Files\Autodesk\Revit 2020"
Autodesk Revit 2019 | Version: 19.2.30.41 | Build: 20210416_1515(x64) | Language: 1033 | Path: "C:\Program Files\Autodesk\Revit 2019"
2018.3.3 Security Fix | Version: 18.3.3.18 | Build: 20190510_1515(x64) | Language: 1033 | Path: "C:\Program Files\Autodesk\Revit 2018"
2017.2.5 Security Fix | Version: 17.0.1169.0 | Build: 20190508_0315(x64) | Language: 1033 | Path: "C:\Program Files\Autodesk\Revit 2017"
2016.1.9 Security Fix | Version: 16.0.1218.0 | Build: 20190508_0715(x64) | Language: 1033 | Path: "C:\Program Files\Autodesk\Revit 2016"
2015 Release 2 (Subscription only release) | Version: 15.0.1103.0 | Build: 20140905_0730(x64) | Language: 1033 | Path: "C:\Program Files\Autodesk\Revit 2015"
2014 Update Release 3 | Version: 13.11.4 | Build: 20140709_2115(x64) | Language: 1033 | Path: "C:\Program Files\Autodesk\Revit 2014"
==> Running Revit Instances
Error: Object reference not set to an instance of an object.
Run with "--debug" option to see debug messages

Additional context
IronPython Traceback:
Traceback (most recent call last):
File "C:\Users\rob.cross\AppData\Roaming\pyRevit\Extensions\pyRevitTools.extension\pyRevit.tab\Project.panel\Preflight Checks.pushbutton\script.py", line 32, in
File "C:\Users\rob.cross\AppData\Roaming\pyRevit\Extensions\pyRevitTools.extension\pyRevit.tab\Project.panel\Preflight Checks.pushbutton\script.py", line 16, in ask_for_preflight_checks
File "C:\Users\rob.cross\AppData\Roaming\pyRevit-Master\pyrevitlib\pyrevit\preflight_init_.py", line 81, in get_all_preflight_checks
File "C:\Users\rob.cross\AppData\Roaming\pyRevit-Master\extensions\pyRevitTools.extension\checks\modelchecker_Warnings_check.py", line 16, in
IOError: System.IO.IOException: Could not add reference to assembly RevitServices
at IronPython.Runtime.ClrModule.AddReference(CodeContext context, String name)
at IronPython.Runtime.ClrModule.AddReference(CodeContext context, Object[] references)
at Microsoft.Scripting.Interpreter.ActionCallInstruction2.Run(InterpretedFrame frame) at Microsoft.Scripting.Interpreter.Interpreter.Run(InterpretedFrame frame) at Microsoft.Scripting.Interpreter.LightLambda.Run4[T0,T1,T2,T3,TRet](T0 arg0, T1 arg1, T2 arg2, T3 arg3) at IronPython.Compiler.Ast.CallExpression.Invoke1Instruction.Run(InterpretedFrame frame) at Microsoft.Scripting.Interpreter.Interpreter.Run(InterpretedFrame frame) at Microsoft.Scripting.Interpreter.LightLambda.Run1[T0,TRet](T0 arg0) at IronPython.Compiler.RuntimeScriptCode.InvokeTarget(Scope scope) at IronPython.Runtime.PythonContext.InitializeModule(String fileName, ModuleContext moduleContext, ScriptCode scriptCode, ModuleOptions options) at IronPython.Modules.PythonImport.load_source(CodeContext context, String name, String pathname) at Microsoft.Scripting.Interpreter.FuncCallInstruction4.Run(InterpretedFrame frame)
at Microsoft.Scripting.Interpreter.Interpreter.Run(InterpretedFrame frame)
at Microsoft.Scripting.Interpreter.LightLambda.Run5[T0,T1,T2,T3,T4,TRet](T0 arg0, T1 arg1, T2 arg2, T3 arg3, T4 arg4)
at System.Dynamic.UpdateDelegates.UpdateAndExecute4[T0,T1,T2,T3,TRet](CallSite site, T0 arg0, T1 arg1, T2 arg2, T3 arg3)
at IronPython.Compiler.Ast.CallExpression.Invoke2Instruction.Run(InterpretedFrame frame)
at Microsoft.Scripting.Interpreter.Interpreter.Run(InterpretedFrame frame)
at Microsoft.Scripting.Interpreter.LightLambda.Run1[T0,TRet](T0 arg0)
at System.Dynamic.UpdateDelegates.UpdateAndExecute2[T0,T1,TRet](CallSite site, T0 arg0, T1 arg1)
at Microsoft.Scripting.Interpreter.DynamicInstruction3.Run(InterpretedFrame frame) at Microsoft.Scripting.Interpreter.Interpreter.Run(InterpretedFrame frame) at Microsoft.Scripting.Interpreter.LightLambda.Run1[T0,TRet](T0 arg0) at System.Dynamic.UpdateDelegates.UpdateAndExecute2[T0,T1,TRet](CallSite site, T0 arg0, T1 arg1) at Microsoft.Scripting.Interpreter.DynamicInstruction3.Run(InterpretedFrame frame)
at Microsoft.Scripting.Interpreter.Interpreter.Run(InterpretedFrame frame)
at Microsoft.Scripting.Interpreter.LightLambda.Run2[T0,T1,TRet](T0 arg0, T1 arg1)
at IronPython.Compiler.PythonScriptCode.RunWorker(CodeContext ctx)
at PyRevitLabs.PyRevit.Runtime.IronPythonEngine.Execute(ScriptRuntime& runtime)

Script Executor Traceback:
System.IO.IOException: Could not add reference to assembly RevitServices
at IronPython.Runtime.ClrModule.AddReference(CodeContext context, String name)
at IronPython.Runtime.ClrModule.AddReference(CodeContext context, Object[] references)
at Microsoft.Scripting.Interpreter.ActionCallInstruction2.Run(InterpretedFrame frame) at Microsoft.Scripting.Interpreter.Interpreter.Run(InterpretedFrame frame) at Microsoft.Scripting.Interpreter.LightLambda.Run4[T0,T1,T2,T3,TRet](T0 arg0, T1 arg1, T2 arg2, T3 arg3) at IronPython.Compiler.Ast.CallExpression.Invoke1Instruction.Run(InterpretedFrame frame) at Microsoft.Scripting.Interpreter.Interpreter.Run(InterpretedFrame frame) at Microsoft.Scripting.Interpreter.LightLambda.Run1[T0,TRet](T0 arg0) at IronPython.Compiler.RuntimeScriptCode.InvokeTarget(Scope scope) at IronPython.Runtime.PythonContext.InitializeModule(String fileName, ModuleContext moduleContext, ScriptCode scriptCode, ModuleOptions options) at IronPython.Modules.PythonImport.load_source(CodeContext context, String name, String pathname) at Microsoft.Scripting.Interpreter.FuncCallInstruction4.Run(InterpretedFrame frame)
at Microsoft.Scripting.Interpreter.Interpreter.Run(InterpretedFrame frame)
at Microsoft.Scripting.Interpreter.LightLambda.Run5[T0,T1,T2,T3,T4,TRet](T0 arg0, T1 arg1, T2 arg2, T3 arg3, T4 arg4)
at System.Dynamic.UpdateDelegates.UpdateAndExecute4[T0,T1,T2,T3,TRet](CallSite site, T0 arg0, T1 arg1, T2 arg2, T3 arg3)
at IronPython.Compiler.Ast.CallExpression.Invoke2Instruction.Run(InterpretedFrame frame)
at Microsoft.Scripting.Interpreter.Interpreter.Run(InterpretedFrame frame)
at Microsoft.Scripting.Interpreter.LightLambda.Run1[T0,TRet](T0 arg0)
at System.Dynamic.UpdateDelegates.UpdateAndExecute2[T0,T1,TRet](CallSite site, T0 arg0, T1 arg1)
at Microsoft.Scripting.Interpreter.DynamicInstruction3.Run(InterpretedFrame frame) at Microsoft.Scripting.Interpreter.Interpreter.Run(InterpretedFrame frame) at Microsoft.Scripting.Interpreter.LightLambda.Run1[T0,TRet](T0 arg0) at System.Dynamic.UpdateDelegates.UpdateAndExecute2[T0,T1,TRet](CallSite site, T0 arg0, T1 arg1) at Microsoft.Scripting.Interpreter.DynamicInstruction3.Run(InterpretedFrame frame)
at Microsoft.Scripting.Interpreter.Interpreter.Run(InterpretedFrame frame)
at Microsoft.Scripting.Interpreter.LightLambda.Run2[T0,T1,TRet](T0 arg0, T1 arg1)
at IronPython.Compiler.PythonScriptCode.RunWorker(CodeContext ctx)
at PyRevitLabs.PyRevit.Runtime.IronPythonEngine.Execute(ScriptRuntime& runtime).

@jmcouffin
Copy link
Contributor

this is doubled with #1297
@eirannejad

@eirannejad
Copy link
Collaborator

Merged with #1297

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

No branches or pull requests

3 participants