Falcor
Falcor copied to clipboard
Crash in python
I just pulled the project and it built fine in visual studio, however at runtime I encountered this crash:
Falcor calling line, ScriptBindings:149:
vec.def_readwrite("y", &VecT::y);
Call stack:
python39_d.dll!type_qualname(_typeobject * type, void * context) Line 479 C
python39_d.dll!getset_get(PyGetSetDescrObject * descr, _object * obj, _object * type) Line 185 C
python39_d.dll!type_getattro(_typeobject * type, _object * name) Line 3345 C
Falcor.dll!pybind11_meta_getattro(_object * obj, _object * name) Line 167 C++
python39_d.dll!PyObject_GetAttr(_object * v, _object * name) Line 890 C
python39_d.dll!PyObject_GetAttrString(_object * v, const char * name) Line 795 C
Falcor.dll!pybind11::getattr(pybind11::handle obj, const char * name) Line 491 C++
Falcor.dll!pybind11::detail::accessor_policies::str_attr::get(pybind11::handle obj, const char * key) Line 656 C++
Falcor.dll!pybind11::detail::accessor<pybind11::detail::accessor_policies::str_attr>::get_cache() Line 634 C++
Falcor.dll!pybind11::detail::accessor<pybind11::detail::accessor_policies::str_attr>::cast<std::string>() Line 630 C++
Falcor.dll!pybind11::cpp_function::initialize_generic(std::unique_ptr<pybind11::detail::function_record,pybind11::cpp_function::InitializingFunctionRecordDeleter> && unique_rec, const char * text, const type_info * const * types, unsigned __int64 args) Line 389 C++
Falcor.dll!pybind11::cpp_function::initialize<const bool & <lambda>(const glm::vec<2,bool,0> &),bool const &,glm::vec<2,bool,0> const &,pybind11::is_method>(pybind11::class_<glm::vec<2,bool,0>>::def_readwrite::__l2::const bool & <lambda>(const glm::vec<2,bool,0> &) && f, const bool &(*)(const glm::vec<2,bool,0> &) __formal, const pybind11::is_method & <extra_0>) Line 274 C++
Falcor.dll!pybind11::cpp_function::cpp_function<const bool & <lambda>(const glm::vec<2,bool,0> &),pybind11::is_method,void>(pybind11::class_<glm::vec<2,bool,0>>::def_readwrite::__l2::const bool & <lambda>(const glm::vec<2,bool,0> &) && f, const pybind11::is_method & <extra_0>) Line 100 C++
Falcor.dll!pybind11::class_<glm::vec<2,bool,0>>::def_readwrite<glm::vec<2,bool,0>,bool>(const char * name, bool * pm) Line 1482 C++
> Falcor.dll!Falcor::ScriptBindings::addVecType<glm::vec<2,bool,0>,0>(pybind11::module_ & m, const std::string name) Line 149 C++
Falcor.dll!Falcor::ScriptBindings::pybind11_init_falcor(pybind11::module_ & m) Line 247 C++
Falcor.dll!Falcor::ScriptBindings::pybind11_init_wrapper_falcor() Line 243 C++
Falcor.dll!pybind11_init_impl_falcor() Line 243 C++
python39_d.dll!_imp_create_builtin(_object * module, _object * spec) Line 1298 C
python39_d.dll!cfunction_vectorcall_O(_object * func, _object * const * args, unsigned __int64 nargsf, _object * kwnames) Line 512 C
python39_d.dll!PyVectorcall_Call(_object * callable, _object * tuple, _object * kwargs) Line 231 C
python39_d.dll!_PyObject_Call(_ts * tstate, _object * callable, _object * args, _object * kwargs) Line 266 C
python39_d.dll!PyObject_Call(_object * callable, _object * args, _object * kwargs) Line 294 C
python39_d.dll!do_call_core(_ts * tstate, _object * func, _object * callargs, _object * kwdict) Line 5092 C
python39_d.dll!_PyEval_EvalFrameDefault(_ts * tstate, _frame * f, int throwflag) Line 3581 C
[Inline Frame] python39_d.dll!_PyEval_EvalFrame(_ts *) Line 40 C
python39_d.dll!_PyEval_EvalCode(_ts * tstate, _object * _co, _object * globals, _object * locals, _object * const * args, __int64 argcount, _object * const * kwnames, _object * const * kwargs, __int64 kwcount, int kwstep, _object * const * defs, __int64 defcount, _object * kwdefs, _object * closure, _object * name, _object * qualname) Line 4327 C
python39_d.dll!_PyFunction_Vectorcall(_object * func, _object * const * stack, unsigned __int64 nargsf, _object * kwnames) Line 404 C
python39_d.dll!_PyObject_VectorcallTstate(_ts * tstate, _object * callable, _object * const * args, unsigned __int64 nargsf, _object * kwnames) Line 119 C
[Inline Frame] python39_d.dll!PyObject_Vectorcall(_object *) Line 127 C
python39_d.dll!call_function(_ts * tstate, _object * * * pp_stack, __int64 oparg, _object * kwnames) Line 5075 C
python39_d.dll!_PyEval_EvalFrameDefault(_ts * tstate, _frame * f, int throwflag) Line 3519 C
python39_d.dll!function_code_fastcall(_ts * tstate, PyCodeObject * co, _object * const * args, __int64 nargs, _object * globals) Line 330 C
python39_d.dll!_PyFunction_Vectorcall(_object * func, _object * const * stack, unsigned __int64 nargsf, _object * kwnames) Line 367 C
python39_d.dll!_PyObject_VectorcallTstate(_ts * tstate, _object * callable, _object * const * args, unsigned __int64 nargsf, _object * kwnames) Line 118 C
python39_d.dll!method_vectorcall(_object * method, _object * const * args, unsigned __int64 nargsf, _object * kwnames) Line 53 C
python39_d.dll!_PyObject_VectorcallTstate(_ts * tstate, _object * callable, _object * const * args, unsigned __int64 nargsf, _object * kwnames) Line 119 C
[Inline Frame] python39_d.dll!PyObject_Vectorcall(_object *) Line 127 C
python39_d.dll!call_function(_ts * tstate, _object * * * pp_stack, __int64 oparg, _object * kwnames) Line 5075 C
python39_d.dll!_PyEval_EvalFrameDefault(_ts * tstate, _frame * f, int throwflag) Line 3489 C
python39_d.dll!function_code_fastcall(_ts * tstate, PyCodeObject * co, _object * const * args, __int64 nargs, _object * globals) Line 330 C
python39_d.dll!_PyFunction_Vectorcall(_object * func, _object * const * stack, unsigned __int64 nargsf, _object * kwnames) Line 367 C
python39_d.dll!_PyObject_VectorcallTstate(_ts * tstate, _object * callable, _object * const * args, unsigned __int64 nargsf, _object * kwnames) Line 119 C
[Inline Frame] python39_d.dll!PyObject_Vectorcall(_object *) Line 127 C
python39_d.dll!call_function(_ts * tstate, _object * * * pp_stack, __int64 oparg, _object * kwnames) Line 5075 C
python39_d.dll!_PyEval_EvalFrameDefault(_ts * tstate, _frame * f, int throwflag) Line 3519 C
python39_d.dll!function_code_fastcall(_ts * tstate, PyCodeObject * co, _object * const * args, __int64 nargs, _object * globals) Line 330 C
python39_d.dll!_PyFunction_Vectorcall(_object * func, _object * const * stack, unsigned __int64 nargsf, _object * kwnames) Line 367 C
python39_d.dll!_PyObject_VectorcallTstate(_ts * tstate, _object * callable, _object * const * args, unsigned __int64 nargsf, _object * kwnames) Line 119 C
[Inline Frame] python39_d.dll!PyObject_Vectorcall(_object *) Line 127 C
python39_d.dll!call_function(_ts * tstate, _object * * * pp_stack, __int64 oparg, _object * kwnames) Line 5075 C
python39_d.dll!_PyEval_EvalFrameDefault(_ts * tstate, _frame * f, int throwflag) Line 3519 C
python39_d.dll!function_code_fastcall(_ts * tstate, PyCodeObject * co, _object * const * args, __int64 nargs, _object * globals) Line 330 C
python39_d.dll!_PyFunction_Vectorcall(_object * func, _object * const * stack, unsigned __int64 nargsf, _object * kwnames) Line 367 C
python39_d.dll!_PyObject_VectorcallTstate(_ts * tstate, _object * callable, _object * const * args, unsigned __int64 nargsf, _object * kwnames) Line 119 C
[Inline Frame] python39_d.dll!PyObject_Vectorcall(_object *) Line 127 C
python39_d.dll!call_function(_ts * tstate, _object * * * pp_stack, __int64 oparg, _object * kwnames) Line 5075 C
python39_d.dll!_PyEval_EvalFrameDefault(_ts * tstate, _frame * f, int throwflag) Line 3519 C
python39_d.dll!function_code_fastcall(_ts * tstate, PyCodeObject * co, _object * const * args, __int64 nargs, _object * globals) Line 330 C
python39_d.dll!_PyFunction_Vectorcall(_object * func, _object * const * stack, unsigned __int64 nargsf, _object * kwnames) Line 367 C
python39_d.dll!_PyObject_VectorcallTstate(_ts * tstate, _object * callable, _object * const * args, unsigned __int64 nargsf, _object * kwnames) Line 118 C
python39_d.dll!object_vacall(_ts * tstate, _object * base, _object * callable, char * vargs) Line 792 C
python39_d.dll!_PyObject_CallMethodIdObjArgs(_object * obj, _Py_Identifier * name, ...) Line 883 C
python39_d.dll!import_find_and_load(_ts * tstate, _object * abs_name) Line 1774 C
python39_d.dll!PyImport_ImportModuleLevelObject(_object * name, _object * globals, _object * locals, _object * fromlist, int level) Line 1875 C
python39_d.dll!import_name(_ts * tstate, _frame * f, _object * name, _object * fromlist, _object * level) Line 5199 C
python39_d.dll!_PyEval_EvalFrameDefault(_ts * tstate, _frame * f, int throwflag) Line 3098 C
[Inline Frame] python39_d.dll!_PyEval_EvalFrame(_ts *) Line 40 C
python39_d.dll!_PyEval_EvalCode(_ts * tstate, _object * _co, _object * globals, _object * locals, _object * const * args, __int64 argcount, _object * const * kwnames, _object * const * kwargs, __int64 kwcount, int kwstep, _object * const * defs, __int64 defcount, _object * kwdefs, _object * closure, _object * name, _object * qualname) Line 4327 C
python39_d.dll!_PyEval_EvalCodeWithName(_object * _co, _object * globals, _object * locals, _object * const * args, __int64 argcount, _object * const * kwnames, _object * const * kwargs, __int64 kwcount, int kwstep, _object * const * defs, __int64 defcount, _object * kwdefs, _object * closure, _object * name, _object * qualname) Line 4366 C
python39_d.dll!PyEval_EvalCodeEx(_object * _co, _object * globals, _object * locals, _object * const * args, int argcount, _object * const * kws, int kwcount, _object * const * defs, int defcount, _object * kwdefs, _object * closure) Line 4382 C
python39_d.dll!PyEval_EvalCode(_object * co, _object * globals, _object * locals) Line 832 C
python39_d.dll!run_eval_code_obj(_ts * tstate, PyCodeObject * co, _object * globals, _object * locals) Line 1219 C
python39_d.dll!run_mod(_mod * mod, _object * filename, _object * globals, _object * locals, PyCompilerFlags * flags, _arena * arena) Line 1240 C
python39_d.dll!PyRun_StringFlags(const char * str, int start, _object * globals, _object * locals, PyCompilerFlags * flags) Line 1106 C
Falcor.dll!pybind11::eval<2>(const pybind11::str & expr, pybind11::object global, pybind11::object local) Line 66 C++
Falcor.dll!pybind11::exec(const pybind11::str & expr, pybind11::object global, pybind11::object local) Line 81 C++
Falcor.dll!Falcor::runScript(const std::string & script, pybind11::dict & globals, bool captureOutput) Line 129 C++
Falcor.dll!Falcor::Scripting::runScript(const std::string & script, Falcor::Scripting::Context & context, bool captureOutput) Line 137 C++
Falcor.dll!Falcor::Scripting::start() Line 56 C++
Falcor.dll!Falcor::Sample::startScripting() Line 638 C++
Falcor.dll!Falcor::Sample::run(const Falcor::SampleConfig & config, std::unique_ptr<Falcor::IRenderer,std::default_delete<Falcor::IRenderer>> & pRenderer, unsigned int argc, char * * argv) Line 203 C++
FalcorTest.exe!main(int argc, char * * argv) Line 124 C++
FalcorTest.exe!invoke_main() Line 79 C++
FalcorTest.exe!__scrt_common_main_seh() Line 288 C++
FalcorTest.exe!__scrt_common_main() Line 331 C++
FalcorTest.exe!mainCRTStartup(void * __formal) Line 17 C++
kernel32.dll!00007ffbd88d7034() Unknown
ntdll.dll!00007ffbda822651() Unknown
What were you trying to call @timluther ?
Hi there, I was just trying to build the falcor project and run it.
@timluther still having this problem?
Hi, I just tried pulling and building again but I had to upgrade the project (using visual studio community 2022 now). This resulted in a number of 'static_asserts' where it seems to be checking to see if a type is supported.
e.g.
1>C:\prog\engines\Falcor\Source\Falcor\Utils\UI\Gui.cpp(762,27): error C2338: Unsupported data type
1>C:\prog\engines\Falcor\Source\Falcor\Utils\UI\Gui.cpp(137,14): message : This diagnostic occurred in the compiler generated function 'bool Falcor::GuiImpl::addScalarSlider(const char [],T &,T,T,bool,const char *)'
1>C:\prog\engines\Falcor\Source\Falcor\Utils\UI\Gui.cpp(806,27): error C2338: Unsupported data typereference manual.
in 'BufferTests.cpp', line 63 and some more in 'Gui.cpp' when creating a vector slider. I tried fixing it myself but unfortunately, the error message doesn't give a call stack, so I can't see exactly what invoked the template function.
Sorry that this is a different problem!
The "Project upgrades" do not usually go well for me. For the time being I am keeping both 2019 and 2022 VS on my machine to have less trouble. Also the Readme points out Visual Studio 2019 as an requirement.
We just released Falcor 5.2 which now uses CMake as the build system. Maybe you can try compiling the new version? It should support both VS2019/VS2022 and can also build using Ninja in VSCode. Please follow the README for instructions.