Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow for progress_cb_obj to be a callable or None #47

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

roddehugo
Copy link

Check the progress object with PyCallable_Check which has the same signature than PyFunction_Check.

int PyFunction_Check(PyObject *o)
Return true if o is a function object (has type PyFunction_Type). The parameter must not be NULL.

vs

int PyCallable_Check(PyObject *o)
Determine if the object o is callable. Return 1 if the object is callable and 0 otherwise. This function always succeeds.

This commit closes #46

Check the `progress` object with `PyCallable_Check` which has the same signature than `PyFunction_Check`.

> `int PyFunction_Check(PyObject *o)`
> Return true if o is a function object (has type PyFunction_Type). The parameter must not be NULL.

vs

> `int PyCallable_Check(PyObject *o)`
> Determine if the object o is callable. Return 1 if the object is callable and 0 otherwise. This function always succeeds.

This commit closes smihica#46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

API for compress_multiple is too restrictive on progress argument
1 participant