Automapping cannot work if not set the "class" attribute for the tiles

Automapping cannot work if I don’t set the “class” attribute for the tiles. Moreover, Tiled did not issue any warnings or prompts either.

Hmm, it should not be necessary to set the “class” attribute for the tiles. Automapping does not care about this value at all. Can you provide more details about the problem you’ve run into?

I can’t reproduce it now. Automapping works fine after I remove the “class” attribute now. However, I did solve the problem of automapping failing before by setting the class attribute of the tile. Perhaps I accidentally did something else at that time.
When I encountered this issue, I attempted an auto-mapping operation using Ctrl+M, but nothing happened. I’m certain I didn’t mistakenly select an empty area, as the map tab didn’t display an “*”. However, Tiled was clearly detecting my rule.tmx file—when I intentionally modified the tile layer in rule.tmx incorrectly and then used automapping, Tiled immediately threw an error.

Are you perhaps using embedded tilesets? Each embedded tileset is a separate tileset, and Automapping tries to consider identical embedded tilesets as the same, but perhaps adding a class to one copy but not another makes them too different.

No, I’m not using an embedded tileset. My tileset is stored in a separate *.tsx file, located in the same directory as both my map file and project file.