jbaiter / gphoto2-cffi

Python bindings for libgphoto2 with an idiomatic API
GNU Lesser General Public License v3.0
38 stars 17 forks source link

24.toggle debugging #25

Open define-private-public opened 7 years ago

define-private-public commented 7 years ago

Addressing #24, the programmer can now toggle logging on and off. I did this without using statics. Instead I created a wrapper function (inside of __init__) that will check if self.enable_logging is True or False. And dependent upon that, it will actually log the message.

Also it bumps up the version number to 0.4.2. If this looks good, please do a push to PyPi.

define-private-public commented 7 years ago

After some testing I think this solution might have been incorrect. I swear it was working last night where it would let me toggle logging in my application.

Could you try pulling down this branch and see if it works for you?

define-private-public commented 7 years ago

I'm thinking that there might have been some threading issue with this.