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

Pylint fixes #41

Merged
merged 7 commits into from Nov 27, 2014
Merged

Pylint fixes #41

merged 7 commits into from Nov 27, 2014

Conversation

mithro
Copy link
Member

@mithro mithro commented Nov 24, 2014

No description provided.

 * Adding PYTHONPATH, allows linting without having to install the package.

 * Adding PYTHONWARNINGS=ignore, suppresses the following warnings;
```
/usr/lib/python2.7/inspect.py:65: Warning: g_param_spec_boxed: assertion 'G_TYPE_IS_BOXED (boxed_type)' failed
  return isinstance(object, (type, types.ClassType))
/usr/lib/python2.7/inspect.py:65: Warning: g_object_class_install_property: assertion 'G_IS_PARAM_SPEC (pspec)' failed
  return isinstance(object, (type, types.ClassType))
```
Fixed `Warning: option include-ids is deprecated and ignored.`
@mithro
Copy link
Member Author

mithro commented Nov 27, 2014

@hyades poke

@hyades
Copy link
Member

hyades commented Nov 27, 2014

@mithro I ran make lint and got this -

pylint --rcfile=.pylintrc_gstswitch gstswitch
/usr/lib/python2.7/inspect.py:65: Warning: g_param_spec_boxed: assertion 'G_TYPE_IS_BOXED (boxed_type)' failed
  return isinstance(object, (type, types.ClassType))
/usr/lib/python2.7/inspect.py:65: Warning: g_object_class_install_property: assertion 'G_IS_PARAM_SPEC (pspec)' failed
  return isinstance(object, (type, types.ClassType))
pylint --rcfile=.pylintrc_unittests tests/unittests/*
************* Module unittests.test_connection_unit
F:  6, 0: Unable to import 'gstswitch.connection' (import-error)
F:  7, 0: Unable to import 'gstswitch.exception' (import-error)
************* Module unittests.test_controller_unit
F:  6, 0: Unable to import 'gstswitch.controller' (import-error)
F:  7, 0: Unable to import 'gstswitch.exception' (import-error)
F: 10, 0: Unable to import 'gstswitch.connection' (import-error)
************* Module unittests.test_helpers_unit
F:  6, 0: Unable to import 'gstswitch.helpers' (import-error)
F:  7, 0: Unable to import 'gstswitch.exception' (import-error)
F:  9, 0: Unable to import 'gstswitch' (import-error)
************* Module unittests.test_server_unit
F:  6, 0: Unable to import 'gstswitch.server' (import-error)
F:  8, 0: Unable to import 'gstswitch.exception' (import-error)
************* Module unittests.test_testsource_unit
F:  6, 0: Unable to import 'gstswitch.exception' (import-error)
F:  7, 0: Unable to import 'gstswitch.testsource' (import-error)
F:  8, 0: Unable to import 'gstswitch.testsource' (import-error)
make: *** [lint] Error 1

@mithro
Copy link
Member Author

mithro commented Nov 27, 2014

Did you run "make lint" in the top level directory or in the python-api directory?

@hyades
Copy link
Member

hyades commented Nov 27, 2014

@mithro inside gst-switch/python-api. Don't think there is any entry in the top one

@mithro
Copy link
Member Author

mithro commented Nov 27, 2014

Can you paste the complete output of the updated "make lint" target?

On 27 November 2014 at 23:18, Aayush Ahuja notifications@github.com wrote:

@mithro https://github.com/mithro inside gst-switch/python-api. Don't
think there is any entry in the top one


Reply to this email directly or view it on GitHub
#41 (comment).

@hyades
Copy link
Member

hyades commented Nov 27, 2014

aahuja@ubuntu:~/gst-switch$ cd python-api/
aahuja@ubuntu:~/gst-switch/python-api$ make lint
pylint --rcfile=.pylintrc_gstswitch gstswitch
/usr/lib/python2.7/inspect.py:65: Warning: g_param_spec_boxed: assertion 'G_TYPE_IS_BOXED (boxed_type)' failed
  return isinstance(object, (type, types.ClassType))
/usr/lib/python2.7/inspect.py:65: Warning: g_object_class_install_property: assertion 'G_IS_PARAM_SPEC (pspec)' failed
  return isinstance(object, (type, types.ClassType))
pylint --rcfile=.pylintrc_unittests tests/unittests/*
************* Module unittests.test_connection_unit
F:  6, 0: Unable to import 'gstswitch.connection' (import-error)
F:  7, 0: Unable to import 'gstswitch.exception' (import-error)
************* Module unittests.test_controller_unit
F:  6, 0: Unable to import 'gstswitch.controller' (import-error)
F:  7, 0: Unable to import 'gstswitch.exception' (import-error)
F: 10, 0: Unable to import 'gstswitch.connection' (import-error)
************* Module unittests.test_helpers_unit
F:  6, 0: Unable to import 'gstswitch.helpers' (import-error)
F:  7, 0: Unable to import 'gstswitch.exception' (import-error)
F:  9, 0: Unable to import 'gstswitch' (import-error)
************* Module unittests.test_server_unit
F:  6, 0: Unable to import 'gstswitch.server' (import-error)
F:  8, 0: Unable to import 'gstswitch.exception' (import-error)
************* Module unittests.test_testsource_unit
F:  6, 0: Unable to import 'gstswitch.exception' (import-error)
F:  7, 0: Unable to import 'gstswitch.testsource' (import-error)
F:  8, 0: Unable to import 'gstswitch.testsource' (import-error)
make: *** [lint] Error 1
aahuja@ubuntu:~/gst-switch/python-api$ 

@mithro
Copy link
Member Author

mithro commented Nov 27, 2014

That output shows you are not running with my latest patches. You should have gotten something like;

$ make lint
PYTHONWARNINGS=ignore
PYTHONPATH=:/home/tansell/foss/gst-switch/python-api
pylint --rcfile=.pylintrc_gstswitch gstswitch
pylint --rcfile=.pylintrc_unittests tests/unittests/*
pylint --rcfile=.pylintrc_integrationtests tests/integrationtests/*.py
Code style is okay!!

@hyades
Copy link
Member

hyades commented Nov 27, 2014

Works fine. Not sure what happened that time.

hyades added a commit that referenced this pull request Nov 27, 2014
@hyades hyades merged commit 21b1d45 into timvideos:master Nov 27, 2014
@coveralls
Copy link

Coverage Status

Coverage remained the same when pulling 9d5faf0 on mithro:pylint-fixes into 02c1a54 on timvideos:master.

@mithro mithro deleted the pylint-fixes branch November 28, 2014 03:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
3 participants