Muriel-Salvan / modsvaskr

Stronghold for mods acting like companions: The Modsvaskr
Other
5 stars 3 forks source link

Unhandled exception: invalid byte sequence in UTF-8 #79

Open ricardocaracante opened 1 year ago

ricardocaracante commented 1 year ago

Hi, can someone help me with this problem?

[ 2023-04-08 16:11:56 ] - [ Ui ] - Launch Modsvaskr UI v0.1.12 - Logs in C:/Modsvaskr/Modsvaskr.log [ 2023-04-08 16:12:08 ] - [ InGameTestsRunner ] - [ In-game testing Skyrim SE ] - 3 available in-game tests suites: npcs, locations, npcshead [ 2023-04-08 16:12:12 ] - [ InGameTestsRunner ] - [ In-game testing Skyrim SE ] - 1 tests suites have statuses changes: [ 2023-04-08 16:12:12 ] - [ InGameTestsRunner ] - [ In-game testing Skyrim SE ] * locations: [ 2023-04-08 16:12:12 ] - [ InGameTestsRunner ] - [ In-game testing Skyrim SE ] - First test to run should be locations / dlc2solstheimworld/16/18. [ 2023-04-08 16:12:12 ] - [ SkyrimSe ] - [ Game Skyrim SE ] - Launch game (#0) using configured launcher (skse64_loader.exe)... [ 2023-04-08 16:12:22 ] - [ SkyrimSe ] - [ Game Skyrim SE ] - SkyrimSE.exe is not running. Wait for its startup... [ 2023-04-08 16:12:23 ] - [ SkyrimSe ] - [ Game Skyrim SE ] - SkyrimSE.exe is not running. Wait for its startup... [ 2023-04-08 16:12:24 ] - [ SkyrimSe ] - [ Game Skyrim SE ] - SkyrimSE.exe is not running. Wait for its startup... [ 2023-04-08 16:12:25 ] - [ SkyrimSe ] - [ Game Skyrim SE ] - SkyrimSE.exe is not running. Wait for its startup... [ 2023-04-08 16:12:26 ] - [ SkyrimSe ] - [ Game Skyrim SE ] - SkyrimSE.exe is not running. Wait for its startup... [ 2023-04-08 16:12:27 ] - [ SkyrimSe ] - [ Game Skyrim SE ] - SkyrimSE.exe is not running. Wait for its startup... [ 2023-04-08 16:12:28 ] - [ SkyrimSe ] - [ Game Skyrim SE ] - SkyrimSE.exe is not running. Wait for its startup... [ 2023-04-08 16:12:29 ] - [ SkyrimSe ] - [ Game Skyrim SE ] - SkyrimSE.exe is not running. Wait for its startup... [ 2023-04-08 16:12:30 ] - [ SkyrimSe ] - [ Game Skyrim SE ] - SkyrimSE.exe is not running. Wait for its startup... [ 2023-04-08 16:12:32 ] - [ SkyrimSe ] - [ Game Skyrim SE ] - SkyrimSE.exe is not running. Wait for its startup... [ 2023-04-08 16:12:33 ] - [ SkyrimSe ] - [ Game Skyrim SE ] - SkyrimSE.exe is not running. Wait for its startup... [ 2023-04-08 16:12:34 ] - [ SkyrimSe ] - [ Game Skyrim SE ] - SkyrimSE.exe is not running. Wait for its startup... [ 2023-04-08 16:12:35 ] - [ SkyrimSe ] - [ Game Skyrim SE ] - SkyrimSE.exe is not running. Wait for its startup... [ 2023-04-08 16:12:36 ] - [ SkyrimSe ] - [ Game Skyrim SE ] - SkyrimSE.exe is not running. Wait for its startup... [ 2023-04-08 16:12:37 ] - [ SkyrimSe ] - [ Game Skyrim SE ] - SkyrimSE.exe is not running. Wait for its startup... [ 2023-04-08 16:12:38 ] - [ SkyrimSe ] - [ Game Skyrim SE ] - SkyrimSE.exe is not running. Wait for its startup... [ 2023-04-08 16:12:39 ] - [ Ui ] - Unhandled exception: invalid byte sequence in UTF-8 C:/Modsvaskr/vendor/bundle/ruby/2.6.0/gems/modsvaskr-0.1.12/lib/modsvaskr/game.rb:137:in split' C:/Modsvaskr/vendor/bundle/ruby/2.6.0/gems/modsvaskr-0.1.12/lib/modsvaskr/game.rb:137:inlaunch' C:/Modsvaskr/vendor/bundle/ruby/2.6.0/gems/modsvaskr-0.1.12/lib/modsvaskr/in_game_tests_runner.rb:151:in block (2 levels) in run' C:/Modsvaskr/vendor/bundle/ruby/2.6.0/gems/modsvaskr-0.1.12/lib/modsvaskr/in_game_tests_runner.rb:120:inloop' C:/Modsvaskr/vendor/bundle/ruby/2.6.0/gems/modsvaskr-0.1.12/lib/modsvaskr/in_game_tests_runner.rb:120:in block in run' C:/Modsvaskr/vendor/bundle/ruby/2.6.0/gems/modsvaskr-0.1.12/lib/modsvaskr/in_game_tests_runner.rb:252:inwith_auto_test_monitoring' C:/Modsvaskr/vendor/bundle/ruby/2.6.0/gems/modsvaskr-0.1.12/lib/modsvaskr/in_game_tests_runner.rb:112:in run' C:/Modsvaskr/vendor/bundle/ruby/2.6.0/gems/modsvaskr-0.1.12/lib/modsvaskr/tests_runner.rb:148:inrun' C:/Modsvaskr/vendor/bundle/ruby/2.6.0/gems/modsvaskr-0.1.12/lib/modsvaskr/ui.rb:154:in block (7 levels) in run' C:/Modsvaskr/vendor/bundle/ruby/2.6.0/gems/curses_menu-0.2.0/lib/curses_menu.rb:136:inblock in initialize' C:/Modsvaskr/vendor/bundle/ruby/2.6.0/gems/curses_menu-0.2.0/lib/curses_menu.rb:48:in loop' C:/Modsvaskr/vendor/bundle/ruby/2.6.0/gems/curses_menu-0.2.0/lib/curses_menu.rb:48:ininitialize' C:/Modsvaskr/vendor/bundle/ruby/2.6.0/gems/modsvaskr-0.1.12/lib/modsvaskr/ui.rb:62:in new' C:/Modsvaskr/vendor/bundle/ruby/2.6.0/gems/modsvaskr-0.1.12/lib/modsvaskr/ui.rb:62:inblock (5 levels) in run' C:/Modsvaskr/vendor/bundle/ruby/2.6.0/gems/curses_menu-0.2.0/lib/curses_menu.rb:136:in block in initialize' C:/Modsvaskr/vendor/bundle/ruby/2.6.0/gems/curses_menu-0.2.0/lib/curses_menu.rb:48:inloop' C:/Modsvaskr/vendor/bundle/ruby/2.6.0/gems/curses_menu-0.2.0/lib/curses_menu.rb:48:in initialize' C:/Modsvaskr/vendor/bundle/ruby/2.6.0/gems/modsvaskr-0.1.12/lib/modsvaskr/ui.rb:52:innew' C:/Modsvaskr/vendor/bundle/ruby/2.6.0/gems/modsvaskr-0.1.12/lib/modsvaskr/ui.rb:52:in block (3 levels) in run' C:/Modsvaskr/vendor/bundle/ruby/2.6.0/gems/curses_menu-0.2.0/lib/curses_menu.rb:136:inblock in initialize' C:/Modsvaskr/vendor/bundle/ruby/2.6.0/gems/curses_menu-0.2.0/lib/curses_menu.rb:48:in loop' C:/Modsvaskr/vendor/bundle/ruby/2.6.0/gems/curses_menu-0.2.0/lib/curses_menu.rb:48:ininitialize' C:/Modsvaskr/vendor/bundle/ruby/2.6.0/gems/modsvaskr-0.1.12/lib/modsvaskr/ui.rb:46:in new' C:/Modsvaskr/vendor/bundle/ruby/2.6.0/gems/modsvaskr-0.1.12/lib/modsvaskr/ui.rb:46:inrun' C:/Modsvaskr/vendor/bundle/ruby/2.6.0/gems/modsvaskr-0.1.12/bin/modsvaskr:7:in <top (required)>' bin/modsvaskr:29:inload' bin/modsvaskr:29:in `

' [ 2023-04-08 16:12:39 ] - [ Ui ] - Close Modsvaskr UI

(I dont't have any skills in coding)

Thanks!

rostalan commented 1 year ago

Hi, Might have figured out a fix for the byte sequence error: In file: C:/Modsvaskr/vendor/bundle/ruby/2.6.0/gems/modsvaskr-0.1.12/lib/modsvaskr/game.rb (this location is user specific, I have it somewhere else...) on line 137 replace the entire line with: @pid = Integer(tasklist_stdout.force_encoding("iso-8859-1").split[1]). This enforces encoding to European character set as described here: link This fixed the Unhandled Exception for me and allowed me to run the tests (until I ran into other issues... :) ).