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

py2deb does not seem to work with the latest coloredlogs #4

Closed
maikelwever opened this issue Jan 19, 2016 · 4 comments
Closed

py2deb does not seem to work with the latest coloredlogs #4

maikelwever opened this issue Jan 19, 2016 · 4 comments

Comments

@maikelwever
Copy link

Reverting to coloredlogs v4.0 makes it work fine. Since the requirements.txt of py2deb specifies >=0.5, coloredlogs v5.0 is installed. Which does not work, because of:

File "xxxx/py2deb/cli.py", line 215, in usage
    lines[i] = coloredlogs.ansi_text(line, color='green')
AttributeError: 'module' object has no attribute 'ansi_text'

Steps to reproduce: run py2deb without arguments. Running py2deb --help hides the traceback, but still fails. Running a valid command does not seem to break py2deb, because the help text printing logic does not seem to be called.

Error is present on both Python 2.7.11 and Python 3.5.1. Both installs were done with pip install py2deb in a clean virtualenv.

@xolox
Copy link
Member

xolox commented Jan 19, 2016

Thanks for the heads up Maikel, coincidentally I noticed this myself yesterday evening. I'll fix this ASAP. That's what I get for not constraining the maximum version and breaking backwards compatibility in coloredlogs between different major versions!

@maikelwever
Copy link
Author

I've pushed a temporary fix to my fork of py2deb that resolves this issue by depending on coloredlogs versions < 5.0.

Feel free to PR this as a temporary fix until the problem is resolved in a better way.

https://github.com/maikelwever/py2deb/tree/fix/issue4

@xolox xolox closed this as completed in e9dedc2 Jan 19, 2016
@xolox
Copy link
Member

xolox commented Jan 19, 2016

Hey Maikel,

Thanks again for the feedback and sorry for ignoring your short term fix, when I got a mail notification about your reply I had already implemented and pushed the long term fix :-). The just released py2deb 0.24.2 should no longer have this problem (Travis CI seems to agree).

@maikelwever
Copy link
Author

No problem, a long term fix is always better than a short term one.

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

2 participants