-
Notifications
You must be signed in to change notification settings - Fork 45
Description
When I try to get all my found caches with the function my_finds()
the generator stops at a cache that can only be seen by premium members. (I'm not a premium member, so when I found the cache, it wasn't premium but now it is.) However it would be nice to at least see the caches found before the premium cache if not also the information about the premium cache that is available.
I think the problem is in the function my_logs()
of the Geocaching
class where it yields the cache by calling yield self.get_cache(guid=guid)
as loading by guid does not work for premium caches. I would suggest catching this exception here and do "normal loading" of the cache, i.e. by get_cache(wp)
.
In order to do this the GC code (wp) has to be parsed from the website. I haven't tried that yet but I wrote a quickfix where it just returns a string when the PMOnlyException is thrown.
So the end of the my_logs()
function looks like that:
try: yield self.get_cache(guid=guid) except PMOnlyException: # better: yield self.get_cache(gccode) yield "PMOnlyException" yielded += 1
If I find the time I will try to get a better solution.