mapeditor/tiled

Do you want to work on this issue?

You can request for a bounty in order to promote it!

Tiled sometimes opens the same map in two separate tabs, causing confusing behaviour (especially in Worlds) #3099

floral-qua-floral posted onGitHub

Took me a while to figure out what was going on - I ended up writing out a whole issue report about the various things I was noticing, such as disappearing maps, changes being reverted/restored seemingly at random, the currently selected layer changing inappropriately when I switch between maps, etc. However when reviewing the video clips I recorded for the bug report, I realized that the issues I was observing seemed to be caused entirely by the fact that Tiled had opened up the same map in multiple tabs. It appears to have been picking between the tabs randomly when deciding what to render whenever I had a different map in the same world selected, and also picking randomly when I click on the world to focus it (the tab it ends up focusing is not always the same one that it was rendering).

Here are the two video clips I recorded, which I initially believed were recordings of some sort of data-loss bug, but I now realize just display the extremely confusing consequences of having the same map open in multiple tabs. Keeping a close eye on the tab bar at the top during these clips sheds light on what's going on here.

Video 1: Changes appearing and disappearing as I swap between maps. https://user-images.githubusercontent.com/49110090/124789780-9069e400-df18-11eb-984b-84905c1a82b1.mp4

Video 2: Maps appearing and disappearing as I swap between maps. A single cluster of ground tiles also appears and disappears at random - at one point when I click on the map with the disappearing tiles, it opens the version that does have them, and immediately afterwards I focus it again, opening the version that doesn't have them. Looking at the tab bar reveals that it is in fact opening two different tabs. About 75% of the way through the clip, I close and reopen Tiled, which syncs them all, superficially fixing the issue - however if I were to continue making changes without closing the duplicate tabs, I would likely end up running into these same problems again. https://user-images.githubusercontent.com/49110090/124792401-f9eaf200-df1a-11eb-9ab3-23815989fa4c.mp4

I'm not sure what exactly resulted in multiple tabs of the same map being opened, though - I'll keep a careful eye out for this and update the report if I figure out how to reproduce that.


Fund this Issue

$0.00
Funded
Only logged in users can fund an issue

Pull requests