News:

Do you need help?
Simutrans Wiki Manual can help you to play and extend Simutrans. In 9 languages.

All industries lose connections without warning, usually a crash after.

Started by merry, March 14, 2024, 05:50:56 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

merry

Having recently returned to Simutrans-Extended, i am finding that maps can suddenly, and with no identifiable reason, lose all connections between industries (whether there is a transport conenction or not). Most times, after viewing an industry where the 'missing connections' are warned of, the game crashes shortly afterwards (crash = unscheduled immediate termination of process, in this case).
Version in use: 123.0.1 build 14.21
This is making games frustratingly unplayable, even if saved regularly.

I am working in about 1853, but haven't built railways yet so transport is primarily road carriages, ships, and canals. If that has any bearing on the matter.

i have searched bug reports and scrolled through bug lists, and can't see this reported, so forgive me if it is a known issue, I couldn't find the report when I searched.

Ranran

Developers appreciate that you take the trouble to report a bug.
It will improve the game.

I think one cause I can think of is related to the new just_in_time=5 that was added about two years ago.
The configuration is not playable, it has not been extensively tested, and there is no one to fix it.
That setup will cause mass factory closures anyway.
I think the phenomenon you reported is similar to what occurs in that setting.
(However, the root cause may also be the closure and regeneration of the industry)

Can you check what just_in_time is set to?
You can check it by pressing the shortcut key i to open the settings dialog, then open the economy tab.

Also, submitting reproducible save data will almost always lead to early resolution of bugs.
pak.256やpak.nipponのような複数タイル市内建築物があるpakセットはextendedではちゃんと遊べません。それどころかextendedの追い越し機能はバグまみれで修正が難しくなっており、都市機能および道路機能というゲーム土台部分を壊し、開発作業&コードメンテナンスの足かせになっている。それは最終的にプレイヤーの損失に他ならない。その原因は全て1人の日本人=ひめし@himeshi_hob(THleaderH)によるもの。再びフォーラムの先輩方のアドバイスをガン無視し、結局ほとんど修正されないままExtendedに実装されてしまった。彼は問題を認識しつつ5年以上放置して今なおOTRPの開発を続けている。あまりにも身勝手で無責任。日本の人達はそういう事実にちゃんと目を向けるべき (´・ω・`)

merry

A couple of updates:
(1) just_in_time = 4 (this will have come from defaults)
(2) recently, I left the game running for a few game-months - the connections disappeared during that time but it didn't crash (perhaps I didn't open a dialog at a critical point? So I have before & after saves (links in onedrive) if that helps.
Save before (link)
Save after (link)
Hopefully someone will be able to use these to improve the situation (either a fix or workaround). Unfortunately i'm not much of a coder... 'tinkerer' is about my limit these days.

Ranran

I tried using the before save to advance to Feb.1858, but was unable to reproduce the game crash...
However, no industry closures occurred during that time.
pak.256やpak.nipponのような複数タイル市内建築物があるpakセットはextendedではちゃんと遊べません。それどころかextendedの追い越し機能はバグまみれで修正が難しくなっており、都市機能および道路機能というゲーム土台部分を壊し、開発作業&コードメンテナンスの足かせになっている。それは最終的にプレイヤーの損失に他ならない。その原因は全て1人の日本人=ひめし@himeshi_hob(THleaderH)によるもの。再びフォーラムの先輩方のアドバイスをガン無視し、結局ほとんど修正されないままExtendedに実装されてしまった。彼は問題を認識しつつ5年以上放置して今なおOTRPの開発を続けている。あまりにも身勝手で無責任。日本の人達はそういう事実にちゃんと目を向けるべき (´・ω・`)

jamespetts

Thank you very much for your report and apologies for not having had the chance to respond hitherto. Generally, finding and fixing bugs is only really possible (within the resources of amateur developers such as those who work on Simutrans, at least) with a reliable reproduction case. That means a saved game in which the fault can reliably be reproduced (if necessary, by following specific instructions) within a reasonable time so that we can look inside the game code when the problem occurs or get a backtrace for any crash.

I note that Ranran has had trouble reproducing the crash from the saved game, suggesting that the bug may be hard to find. Unfortunately, intermittent bugs are typically difficult to reproduce and track down. If we can get a reliable reproduction case, especially for the crash, that would be very helpful (although it might turn out that the crash is just a symptom of all the industries losing their connexions, and that what we need to track down is the earlier point in time when this happens).
Download Simutrans-Extended.

Want to help with development? See here for things to do for coding, and here for information on how to make graphics/objects.

Follow Simutrans-Extended on Facebook.

Modular6638

I'm having the same issue in every map I make. Here are some things I observed
- It does not matter the year or map.
- It seems to happen more often when placing a new stop & line near the end of the month.
- The game doesn't always crash immediately, it only does so when opening a factory info window and clicking on the empty space where the missing supplier/consumer are supposed to be, early on it also seemed to happen if I kept the factory window open.

I tried debugging, and in gui_factory_connection_stat_t::infowin_event the variable target_fab is null and is being accessed. My understanding is that if another factory is not linked, its not supposed to be in fab_list, but the missing connection is still in there. So that is the cause of the crash. Looking into it more, the reason fabrik_t::get_fab(fab_list[line]) returns null is because of the is_factory flag of the associated gebaeude_t is false. I think there might be a problem in the newmonth update because of when the crashes seem to happen and that is also one of the few points where is_factory is modified. Still trying to look into it but my first time looking at the code.

Ranran

Thank you for confirming.
fab_list was originally vector_tpl<koord>, but PJMack changed it to a different type, so it won't get the correct koord if there is no factory.
pak.256やpak.nipponのような複数タイル市内建築物があるpakセットはextendedではちゃんと遊べません。それどころかextendedの追い越し機能はバグまみれで修正が難しくなっており、都市機能および道路機能というゲーム土台部分を壊し、開発作業&コードメンテナンスの足かせになっている。それは最終的にプレイヤーの損失に他ならない。その原因は全て1人の日本人=ひめし@himeshi_hob(THleaderH)によるもの。再びフォーラムの先輩方のアドバイスをガン無視し、結局ほとんど修正されないままExtendedに実装されてしまった。彼は問題を認識しつつ5年以上放置して今なおOTRPの開発を続けている。あまりにも身勝手で無責任。日本の人達はそういう事実にちゃんと目を向けるべき (´・ω・`)

Ranran

Quote from: Ranran(retired) on April 13, 2024, 10:53:08 AMfab_list was originally vector_tpl<koord>, but PJMack changed it to a different type, so it won't get the correct koord if there is no factory.
I suppose I have taken measures for this problem.
Please check pull request #649 to see if it is working properly.
pak.256やpak.nipponのような複数タイル市内建築物があるpakセットはextendedではちゃんと遊べません。それどころかextendedの追い越し機能はバグまみれで修正が難しくなっており、都市機能および道路機能というゲーム土台部分を壊し、開発作業&コードメンテナンスの足かせになっている。それは最終的にプレイヤーの損失に他ならない。その原因は全て1人の日本人=ひめし@himeshi_hob(THleaderH)によるもの。再びフォーラムの先輩方のアドバイスをガン無視し、結局ほとんど修正されないままExtendedに実装されてしまった。彼は問題を認識しつつ5年以上放置して今なおOTRPの開発を続けている。あまりにも身勝手で無責任。日本の人達はそういう事実にちゃんと目を向けるべき (´・ω・`)

jamespetts

Quote from: Ranran(retired) on April 28, 2024, 12:38:44 PMI suppose I have taken measures for this problem.
Please check pull request #649 to see if it is working properly.

Thank you very much for this - now incorporated. This should hopefully address the crashing, but will not solve the underlying problem, which originates outside the UI code.

If anyone has a reliable reproduction case for this, that would be very helpful.
Download Simutrans-Extended.

Want to help with development? See here for things to do for coding, and here for information on how to make graphics/objects.

Follow Simutrans-Extended on Facebook.