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

notice of erroneous argument #84

Open
KirstensGitHub opened this issue Nov 8, 2017 · 3 comments
Open

notice of erroneous argument #84

KirstensGitHub opened this issue Nov 8, 2017 · 3 comments

Comments

@KirstensGitHub
Copy link
Member

I've noticed that it's possible to pass arguments that aren't accepted by quail into quail.plot and still get the correct output without any error / warning.

It's really nice that the figure still generates as it should, but perhaps we should notify the user that he or she has passed an argument that is being ignored / is not used or accepted by quail

@jeremymanning
Copy link
Member

The code should fail if bad arguments are passed: http://www.martinfowler.com/ieeeSoftware/failFast.pdf

@andrewheusser
Copy link
Collaborator

thanks for noting this @KirstensGitHub . The reason why quail doesn't fail when non-quail args are passed is because all non-quail args are passed onto seaborn, and then non seaborn args are passed to matplotlib. This makes the quail API way more flexible, but also less predictable. To deal with this, we could:

  1. throw a warning if non-quail arguments are detected so the user is aware that behavior may be unpredictable
  2. remove support for non-quail arguments, making the API perfectly predictable, but way less flexible.
  3. something else

I'm leaning towards option 1, but open to suggestions.

@jeremymanning
Copy link
Member

i think the flexibility is useful, even though this violates the "fail fast" principle. so...let's go with 1. we should tell the user where their arguments are going at least (e.g. along the lines of "the following arguments will be passed to seaborn: ....")

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

No branches or pull requests

3 participants