nghung270192 / colorama

Automatically exported from code.google.com/p/colorama
BSD 3-Clause "New" or "Revised" License
0 stars 0 forks source link

any() keyword misusagfe #27

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. install latest pypi-uploaded colorama
2. call the init() function

What is the expected output? What do you see instead?
I expect nothing and I get a traceback:
Traceback (most recent call last):
  File "/usr/local/bin/pyg", line 9, in <module>
    load_entry_point('pyg==0.6', 'console_scripts', 'pyg')()
  File "/home/fab/progs/pyg/pyg/__init__.py", line 15, in main
    from pyg.core import PygError, InstallationError, AlreadyInstalled, args_manager
  File "/home/fab/progs/pyg/pyg/core.py", line 10, in <module>
    from pyg.utils import TempDir, ZipFile, call_subprocess, call_setup, run_setup, name_from_egg
  File "/home/fab/progs/pyg/pyg/utils.py", line 15, in <module>
    from pyg.log import logger
  File "/home/fab/progs/pyg/pyg/log.py", line 9, in <module>
    init(autoreset=False)
  File "/usr/local/lib/python2.7/site-packages/colorama/initialise.py", line 22, in init
    if wrap and any(autoreset, convert, strip):
TypeError: any() takes exactly one argument (3 given)

What version of the product are you using? On what operating system?

Please provide any additional information below.

changing colorama/initialise.py file to use any((X,Y,Z)) instead of any(X,Y,Z) 
fixed my problem.

Original issue reported on code.google.com by fdev31@gmail.com on 20 Jun 2011 at 10:04

GoogleCodeExporter commented 9 years ago
Thanks for the report. Sorry it was broken. Should be fixed now.

That'll teach me to push changes late at night. Clearly I forgot to run the 
'tests' (the demo script)

Original comment by tart...@gmail.com on 20 Jun 2011 at 3:38