MagerValp/AutoDMGUpdateProfiles

autodmg-rss.py failing

Closed this issue · 4 comments

 ./autodmg-rss.py updates.plist
Download macOS Sierra 10.12.3 Update
Download Security Update 2016-003 (10.11.6)
Download Security Update 2016-003 Supplemental (10.11.6)
Download Security Update 2016-003 (10.11.6)
Download Security Update 2016-007 (10.10.5)
Download macOS Sierra 10.12.2 Update
Download iTunes 12.5.4
Download macOS Sierra 10.12.1 Update
Download Security Update 2016-006 (10.10.5)
Download Security Update 2016-002 (10.11.6)
Digital Camera RAW Compatibility Update 6.21
Download iTunes 12.4.3 for OS X
Digital Camera RAW Compatibility Update 6.20
Download Security Update 2016-004 Mavericks
Download Security Update 2016-004 Yosemite
Download OS X El Capitan 10.11.6 Update
Download Security Update 2016-003 Yosemite
Download Security Update 2016-003 Mavericks
Download OS X El Capitan 10.11.5 Update
Digital Camera RAW Compatibility Update 6.19
Download Bluetooth Update for MacBook
Traceback (most recent call last):
  File "./autodmg-rss.py", line 132, in <module>
    sys.exit(main(sys.argv))
  File "./autodmg-rss.py", line 126, in main
    plistlib.writePlist(updates_found, args.updates)
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/plistlib.py", line 94, in writePlist
    writer.writeValue(rootObject)
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/plistlib.py", line 252, in writeValue
    self.writeDict(value)
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/plistlib.py", line 281, in writeDict
    self.writeValue(value)
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/plistlib.py", line 252, in writeValue
    self.writeDict(value)
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/plistlib.py", line 281, in writeDict
    self.writeValue(value)
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/plistlib.py", line 252, in writeValue
    self.writeDict(value)
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/plistlib.py", line 281, in writeDict
    self.writeValue(value)
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/plistlib.py", line 260, in writeValue
    raise TypeError("unsuported type: %s" % type(value))
TypeError: unsuported type: <type 'NoneType'>

I can check this out later, but wanted to get it filed so that I don't forget.

Looks like it's intermittent...

Agreed, appears to be working again for now. Closing issue.

We can keep it open, there's still a bug lurking in the code. It's trying to serialize a None value in the dictionary, and since we're printing the title, it has to be the url. I'll add some extra error checking.

43c2d0d makes fewer assumptions about what the rss feed returns.