Closed mgerhardy closed 1 month ago
(0) Initialized metrics
> assert
(0) Stack trace (most recent call last):
(0) #1 Object "", at 000000C200000000, in ??
(0) #0 Source "C:\Users\marti\dev\engine\contrib\libs\backward\backward.h", line 1150, in backward::StackTraceImpl<backward::system_tag::windows_tag>::load_here
(0) 1147: RtlCaptureContext(ctx_);
(0) 1148: }
(0) 1149:
(0) >1150: if (!thd_) {
(0) 1151: thd_ = GetCurrentThread();
(0) 1152: }
Assertion failure at app::App::onConstruct::<lambda_9a61590487b62b6696263346d3d9ba8d>::operator () (C:\Users\marti\dev\engine\src\modules\app\App.cpp:494), triggered 1 time:
'assert triggered'
Applying this patch https://github.com/bombela/backward-cpp/pull/334 results in
(0) Initialized metrics
> assert
(0) Stack trace (most recent call last):
(0) #26 Object "", at 00007FFABB6C485B, in RtlUserThreadStart
(0) #25 Object "", at 00007FFAB98353E0, in BaseThreadInitThunk
(0) #24 Source "D:\a\_work\1\s\src\vctools\crt\vcstartup\src\startup\exe_winmain.cpp", line 17, in WinMainCRTStartup
(0) #23 Source "D:\a\_work\1\s\src\vctools\crt\vcstartup\src\startup\exe_common.inl", line 331, in __scrt_common_main
(0) #22 Source "D:\a\_work\1\s\src\vctools\crt\vcstartup\src\startup\exe_common.inl", line 288, in __scrt_common_main_seh
(0) #21 Source "D:\a\_work\1\s\src\vctools\crt\vcstartup\src\startup\exe_common.inl", line 107, in invoke_main
(0) #20 Source "C:\Users\marti\dev\engine\contrib\libs\sdl2\src\main\windows\SDL_windows_main.c", line 110, in WinMain
(0) 107: WinMain(HINSTANCE hInst, HINSTANCE hPrev, LPSTR szCmdLine, int sw) /* NOLINT(readability-inconsistent-declaration-parameter-name) */
(0) 108: {
(0) 109: return main_getcmdline();
(0) > 110: }
(0) 111:
(0) 112: #endif /* __WIN32__ */
(0) #19 Source "C:\Users\marti\dev\engine\contrib\libs\sdl2\src\main\windows\SDL_windows_main.c", line 80, in main_getcmdline
(0) 77: SDL_SetMainReady();
(0) 78:
(0) 79: /* Run the application main() code */
(0) > 80: result = SDL_main(argc, argv);
(0) 81:
(0) 82: /* Free argv, to avoid memory leak */
(0) 83: for (i = 0; i < argc; ++i) {
(0) #18 Source "C:\Users\marti\dev\engine\src\tools\voxedit\VoxEdit.cpp", line 566, in SDL_main
(0) 563: core::make_shared<voxedit::SceneManager>(timeProvider, filesystem, sceneRenderer, modifierRenderer);
(0) 564: const voxelcollection::CollectionManagerPtr &collectionMgr = core::make_shared<voxelcollection::CollectionManager>(filesystem, texturePool);
(0) 565: VoxEdit app(filesystem, timeProvider, sceneMgr, collectionMgr, texturePool);
(0) > 566: return app.startMainLoop(argc, argv);
(0) 567: }
(0) #17 Source "C:\Users\marti\dev\engine\src\modules\app\App.cpp", line 165, in app::App::startMainLoop
(0) 162: #else
(0) 163: while (AppState::InvalidAppState != _curState) {
(0) 164: onFrame();
(0) > 165: }
(0) 166: #endif
(0) 167: return _exitCode;
(0) 168: }
(0) #16 Source "C:\Users\marti\dev\engine\src\modules\app\App.cpp", line 303, in app::App::onFrame
(0) 300: core_trace_scoped(AppOnBeforeRunning);
(0) 301: onBeforeRunning();
(0) 302: }
(0) > 303: const AppState state = onRunning();
(0) 304: if (_nextState != AppState::Cleanup && _nextState != AppState::Destroy) {
(0) 305: _nextState = state;
(0) 306: }
(0) #15 Source "C:\Users\marti\dev\engine\src\tools\voxedit\VoxEdit.cpp", line 537, in VoxEdit::onRunning
(0) 534: }
(0) 535:
(0) 536: app::AppState VoxEdit::onRunning() {
(0) > 537: app::AppState state = Super::onRunning();
(0) 538: if (state != app::AppState::Running) {
(0) 539: return state;
(0) 540: }
(0) #14 Source "C:\Users\marti\dev\engine\src\modules\ui\IMGUIApp.cpp", line 609, in ui::IMGUIApp::onRunning
(0) 606: ImGuiTestEngine_ShowTestEngineWindows(_imguiTestEngine, nullptr);
(0) 607: #endif
(0) 608:
(0) > 609: if (_closeModalPopup) {
(0) 610: if (ImGui::GetTopMostPopupModal() != nullptr) {
(0) 611: GImGui->OpenPopupStack.resize(GImGui->OpenPopupStack.size() - 1);
(0) 612: }
(0) #13 Source "C:\Users\marti\dev\engine\src\modules\ui\IMGUIConsole.cpp", line 136, in ui::IMGUIConsole::render
(0) 133: ImGuiInputTextFlags_CallbackHistory,
(0) 134: _priv::ConsoleInputTextCallback, this)) {
(0) 135: executeCommandLine(&imguiApp()->commandListener());
(0) > 136: ImGui::SetKeyboardFocusHere(-1);
(0) 137: }
(0) 138: }
(0) 139: ImGui::End();
(0) #12 Source "C:\Users\marti\dev\engine\src\modules\util\Console.cpp", line 85, in util::Console::executeCommandLine
(0) 82: _historyPos = _history.size();
(0) 83:
(0) 84: command::executeCommands(_commandLine, listener);
(0) > 85: clearCommandLine();
(0) 86: }
(0) 87:
(0) 88: void Console::cursorUp() {
(0) #11 Source "C:\Users\marti\dev\engine\src\modules\command\CommandHandler.cpp", line 59, in command::executeCommands
(0) 56: if (listener && !listener->allowed(cmd, tokens)) {
(0) 57: continue;
(0) 58: }
(0) > 59: if (command::Command::execute(cmd, tokens)) {
(0) 60: if (n != -1) {
(0) 61: ++n;
(0) 62: if (listener) {
(0) #10 Source "C:\Users\marti\dev\engine\src\modules\command\Command.cpp", line 196, in command::Command::execute
(0) 193: }
(0) 194: Log::trace("execute %s with %i arguments", command.c_str(), (int)args.size());
(0) 195: cmd._func(args);
(0) > 196: return true;
(0) 197: }
(0) 198:
(0) 199: void Command::shutdown() {
(0) #9 Source "C:\Program Files\Microsoft Visual Studio\2022\Community\VC\Tools\MSVC\14.37.32822\include\functional", line 884, in std::_Func_class<void,core::DynamicArray<core::String,32> const &>::operator()
(0) 881: }
(0) 882: const auto _Impl = _Getimpl();
(0) 883: return _Impl->_Do_call(_STD forward<_Types>(_Args)...);
(0) > 884: }
(0) 885:
(0) 886: ~_Func_class() noexcept {
(0) 887: _Tidy();
(0) #8 Source "C:\Program Files\Microsoft Visual Studio\2022\Community\VC\Tools\MSVC\14.37.32822\include\functional", line 843, in std::_Func_impl_no_alloc<<lambda_9a61590487b62b6696263346d3d9ba8d>,void,core::DynamicArray<core::String,32> const &>::_Do_call
(0) 840: } else {
(0) 841: return _STD invoke(_Callee, _STD forward<_Types>(_Args)...);
(0) 842: }
(0) > 843: }
(0) 844:
(0) 845: const type_info& _Target_type() const noexcept override {
(0) 846: #if _HAS_STATIC_RTTI
(0) #7 Source "C:\Program Files\Microsoft Visual Studio\2022\Community\VC\Tools\MSVC\14.37.32822\include\type_traits", line 1777, in std::invoke<<lambda_9a61590487b62b6696263346d3d9ba8d> &,core::DynamicArray<core::String,32> const &>
(0) 1774: _STL_INTERNAL_STATIC_ASSERT(_Invoker1<_Callable, _Ty1>::_Strategy == _Invoker_strategy::_Pmd_pointer);
(0) 1775: return (*static_cast<_Ty1&&>(_Arg1)).*_Obj;
(0) 1776: }
(0) >1777: }
(0) 1778:
(0) 1779: #pragma warning(push)
(0) 1780: #pragma warning(disable : 4242) // '%s': conversion from '%s' to '%s', possible loss of data (/Wall)
(0) #6 Source "C:\Users\marti\dev\engine\src\modules\app\App.cpp", line 494, in <lambda_9a61590487b62b6696263346d3d9ba8d>::operator()
(0) 492: #ifdef DEBUG
(0) 493: command::Command::registerCommand("assert", [&](const command::CmdArgs &args) {
(0) > 494: core_assert_msg(false, "assert triggered");
(0) 495: }).setHelp(_("Trigger an assert"));
(0) 496: #endif
(0) #5 Source "C:\Users\marti\dev\engine\src\modules\core\Assert.cpp", line 51, in core_assert_impl_message
(0) 48: SDL_vsnprintf(buf, bufSize - 1, format, args);
(0) 49: va_end(args);
(0) 50: data.condition = buf; /* also let it work for following calls */
(0) > 51: const SDL_AssertState state = SDL_ReportAssertion((SDL_AssertData *)&data, function, file, line);
(0) 52: if (state == SDL_ASSERTION_BREAK) {
(0) 53: SDL_TriggerBreakpoint();
(0) 54: }
(0) #4 Source "C:\Users\marti\dev\engine\contrib\libs\sdl2\src\dynapi\SDL_dynapi_procs.h", line 93, in SDL_ReportAssertion
(0) 90: SDL_DYNAPI_PROC(void,SDL_QuitSubSystem,(Uint32 a),(a),)
(0) 91: SDL_DYNAPI_PROC(Uint32,SDL_WasInit,(Uint32 a),(a),return)
(0) 92: SDL_DYNAPI_PROC(void,SDL_Quit,(void),(),)
(0) > 93: SDL_DYNAPI_PROC(SDL_AssertState,SDL_ReportAssertion,(SDL_AssertData *a, const char *b, const char *c, int d),(a,b,c,d),return)
(0) 94: SDL_DYNAPI_PROC(void,SDL_SetAssertionHandler,(SDL_AssertionHandler a, void *b),(a,b),)
(0) 95: SDL_DYNAPI_PROC(const SDL_AssertData*,SDL_GetAssertionReport,(void),(),return)
(0) 96: SDL_DYNAPI_PROC(void,SDL_ResetAssertionReport,(void),(),)
(0) #3 Source "C:\Users\marti\dev\engine\contrib\libs\sdl2\src\SDL_assert.c", line 379, in SDL_ReportAssertion_REAL
(0) 376: }
(0) 377:
(0) 378: if (!data->always_ignore) {
(0) > 379: state = assertion_handler(data, assertion_userdata);
(0) 380: }
(0) 381:
(0) 382: switch (state) {
(0) #2 Source "C:\Users\marti\dev\engine\src\modules\core\Assert.cpp", line 22, in coreAssertionHandler
(0) 19: if (data->trigger_count <= 1 && data->always_ignore == 0) {
(0) 20: core_stacktrace();
(0) 21: }
(0) > 22: const SDL_AssertState state = SDL_GetDefaultAssertionHandler()(data, userdata);
(0) 23: if (state == SDL_ASSERTION_RETRY) {
(0) 24: return state;
(0) 25: }
(0) #1 Source "C:\Users\marti\dev\engine\src\modules\core\Assert.cpp", line 81, in core_stacktrace
(0) 78: std::ostringstream os;
(0) 79: backward::StackTrace st;
(0) 80: st.load_here(32);
(0) > 81: backward::Printer printer;
(0) 82: printer.print(st, os);
(0) 83: std::string str = os.str();
(0) 84: char *c = (char*)str.c_str();
(0) #0 Source "C:\Users\marti\dev\engine\contrib\libs\backward\backward.h", line 1142, in backward::StackTraceImpl<backward::system_tag::windows_tag>::load_here
(0) 1140: if (!context) {
(0) 1141: _stacktrace.resize(depth);
(0) >1142: const WORD capturedFrames = RtlCaptureStackBackTrace(
(0) 1143: 0, static_cast<DWORD>(depth), _stacktrace.data(), NULL);
(0) 1144: _stacktrace.resize(capturedFrames);
(0) 1145: return capturedFrames;
Assertion failure at app::App::onConstruct::<lambda_9a61590487b62b6696263346d3d9ba8d>::operator () (C:\Users\marti\dev\engine\src\modules\app\App.cpp:494), triggered 1 time:
'assert triggered'
merged manually
todo
for a weird reason the last tool that is added via add_subdirectory is not going to get included in the msi installer (I have seen the same problem on osx, that voxconvert is missing in the dmg)