10000 Raise exception for instance_or_null by itsmemattchung · Pull Request #632 · sigmavirus24/github3.py · GitHub
[go: up one dir, main page]

Skip to content

Raise exception for instance_or_null #632

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

Merged
merged 1 commit into from
Jul 27, 2016

Conversation

itsmemattchung
Copy link
Contributor

When the wrong data type is passed to the method, like a list or string,
an exception is returned. Instead, we should be raising the exception.

I added a single unit test, which asserts that an error is raised.

Fixes #628 and
#627.

When the wrong data type is passed to the method, like a list or string,
an exception is returned.  Instead, we should be raising the exception.

I added a single unit test, which asserts that an error is raised.

Fixes sigmavirus24#628 and
sigmavirus24#627.
@sigmavirus24
Copy link
Owner

I'll recheck those flake8 jobs after I release Flake8 3.0.2 tonight. Thanks @itsmemattchung!

@itsmemattchung
Copy link
Contributor Author

Weird. Running the tests (flake8), locally, succeeds. When travis runs, however, the tests fail. I'll dig deeper; not sure why at the moment.

$ tox -e py27-flake8
GLOB sdist-make: /Users/mattchung/Development/github3.py/setup.py
py27-flake8 inst-nodeps: /Users/mattchung/Development/github3.py/.tox/dist/github3.py-1.0.0a4.zip
py27-flake8 installed: flake8==2.6.2,github3.py==1.0.0a4,mccabe==0.5.0,pycodestyle==2.0.0,pyflakes==1.2.3,requests==2.10.0,uritemplate.py==0.3.0
py27-flake8 runtests: PYTHONHASHSEED='2943006827'
py27-flake8 runtests: commands[0] | flake8 github3/ tests/unit/ tests/integration/
_______________________________________________________________________ summary ________________________________________________________________________
  py27-flake8: commands succeeded
  congratulations :)
py27-flake8 runtests: commands[0] | flake8 github3/ tests/unit/ tests/integration/
github3/decorators.py:100:4: F811 redefinition of unused 'requires_auth' from line 28
github3/decorators.py:100:20: F811 redefinition of unused 'requires_basic_auth' from line 44
ERROR: InvocationError: '/home/travis/build/sigmavirus24/github3.py/.tox/py27-flake8/bin/flake8 github3/ tests/unit/ tests/integration/'

@itsmemattchung
Copy link
Contributor Author

I'll recheck those flake8 jobs after I release Flake8 3.0.2 tonight. Thanks @itsmemattchung!

Got it, thanks @sigmavirus24 . Just noticed that I'm running flake8 2.6.2, locally, while travis runs flake8 3.0.1. Good catch.

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.

2 participants
0