mteodoro / mmutils

Tools for working with MaxMind GeoIP csv and dat files
MIT License
95 stars 47 forks source link

Except: Duplicate IPs #2

Closed coolacid closed 10 years ago

coolacid commented 10 years ago

I've run the conversion a few times, and I find that the script doesn't handle when there is duplicate IPs.

Line 205 gets an except when there is a duplicate start IP address

Line 189 gets an except if you define overlapping IP address

mteodoro commented 10 years ago

csv2dat expects input to be a valid MM csv file that consists only of sorted, non-overlapping IP ranges, but I agree that the error handling should be better in cases of invalid input.