unexpectedpanda / retool

Retool: a better filter tool for Redump and No-Intro DAT files.
BSD 3-Clause "New" or "Revised" License
355 stars 23 forks source link

Unhandled AttributeError exception thrown #217

Closed FranticOrange closed 2 years ago

FranticOrange commented 2 years ago

Running the latest version of retool (GUI 0.11, CLI 1.16) on Windows 10 x64.

Processing an unedited TOSEC Atari 2600 dat file throws the following exception:

Traceback (most recent call last):ael [100%] File "retool-gui.py", line 1020, in File "retool-gui.py", line 622, in main File "retool.py", line 279, in main File "modules\xml.py", line 184, in dat_to_dict File "modules\classes.py", line 73, in init File "modules\titleutils.py", line 183, in remove_regions AttributeError: 'NoneType' object has no attribute 'group' [15164] Failed to execute script 'retool-gui' due to unhandled exception!

I've tracked this down to the following single rom entry in the dat file as removing it entirely allows retool to complete normally:

<game name="FlapPing (2005)(Israel, Kirk)(NTSC)">
    <description>FlapPing (2005)(Israel, Kirk)(NTSC)</description>
    <rom name="FlapPing (2005)(Israel, Kirk)(NTSC).bin" size="4096" crc="33bc76bd" md5="163ff70346c5f4ce4048453d3a2381db" sha1="08555905609caf43fe6e16e65a5fb1804e42646c"/>
</game>

Admittedly, the dat file is an old version from 2011 but it's the one I've used to build and audit my current collection. At first glance, it may be the (Israel, Kirk) section that's causing the issue. I can easily edit this single case but I have some other much larger dat files to process once I've finished evaluating retool.

Thanks for what looks to be a very good tool so far.

Are you using custom global or system filters? If so, list them below

Global excludes: [a [o [b

Global includes: [!]

System excludes:

System includes:

What other settings are you using? Filtering for English language only.

unexpectedpanda commented 2 years ago

Hi there!

Retool doesn't support TOSEC's naming system. It's only been designed for No-Intro and Redump DATs.

I suspect you're right that it's the odd region tag that's causing the issue, but I wouldn't be surprised to see other issues cropping up elsewhere. If you've managed to get something out of TOSEC DATs, then it's luck I'm afraid.

Maybe one day in the future there will be support -- but there's plenty of problems left to solve for the other two groups first.

FranticOrange commented 2 years ago

Hi.

Thanks for the quick response. I hadn't noticed that retool doesn't support TOSEC so apologies for that.

I'm currently in the process of re-auditing my rom collections against the No-Intro DATs which may take some time given the number of platforms I have. They actually serve my purposes better than TOSEC, not sure why I originally picked those way back all those years ago.

Once I've done all of that, I'll revisit retool again.

Thanks.