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

Add tox config example #1856

Merged
merged 1 commit into from
Nov 23, 2021
Merged

Add tox config example #1856

merged 1 commit into from
Nov 23, 2021

Conversation

umonaca
Copy link
Contributor

@umonaca umonaca commented Nov 23, 2021

When I set the following config in tox.ini

[isort]
profile = "black"
multi_line_output = 3

I am getting the following error when running tox on py39:

  py39 run-test: commands[1] | poetry run isort obplatform -c
  Traceback (most recent call last):
    File "/home/runner/work/obplatform/obplatform/.tox/py39/bin/isort", line 8, in <module>
      sys.exit(main())
    File "/home/runner/work/obplatform/obplatform/.tox/py39/lib/python3.9/site-packages/isort/main.py", line 1108, in main
      config = Config(**config_dict)
    File "/home/runner/work/obplatform/obplatform/.tox/py39/lib/python3.9/site-packages/isort/settings.py", line 365, in __init__
      raise ProfileDoesNotExist(profile_name)
  isort.exceptions.ProfileDoesNotExist: Specified profile of "black" does not exist. Available profiles: black,django,pycharm,google,open_stack,plone,attrs,hug,wemake,appnexus.

I fixed it by removing the quotes around "black":

[isort]
profile = black
multi_line_output = 3

I think this example could be useful in the documentation.

@timothycrosley timothycrosley merged commit 86c0ee0 into PyCQA:main Nov 23, 2021
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