Home Download Buy Blog Forum Support

Error using set_timeout

Error using set_timeout

Postby shmuelfomberg on Thu Jul 10, 2014 4:30 am

Inside my plugin, sometimes I get the following error:

Code: Select all
Boost.Python.ArgumentError: Python argument types in
    sublime.set_timeout(function, float)
did not match C++ signature:
    set_timeout(boost::python::api::object, int)


I call it such as:

Code: Select all
        new_delay = changed + 2 - time.time()
        func = lambda: deferred_get_list(view, changed)
        sublime.set_timeout(func, new_delay)


Can anyone spot what I'm doing wrong? thanks!
shmuelfomberg
 
Posts: 2
Joined: Thu Jul 10, 2014 4:27 am

Re: Error using set_timeout

Postby shmuelfomberg on Tue Jul 15, 2014 2:41 am

Thanks FichteFoll for correcting me on github - I was suppling float to a function that expected int.
shmuelfomberg
 
Posts: 2
Joined: Thu Jul 10, 2014 4:27 am


Return to Plugin Development

Who is online

Users browsing this forum: No registered users and 2 guests