-
-
Notifications
You must be signed in to change notification settings - Fork 704
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
cannot import name properties #10
Comments
The |
Is this the whole output? No, but everything else is related to Django. I noticed something else: when I load my django view for the first time (after starting the dev server), I get a Are you using the same Python as the one Homebrew installed pygtk in? I don't think so, as
Did you create the virtualenv with --system-site-packages? Can you import pango from a Python shell? What about import lxml.etree? Yes, yes, and yes. I double checked that. |
This is it. WeasyPrint fails to import Pango, either from I really don’t know how Homebrew handles Python and Python libs. How do you start Django? Can you |
Ok, you pointed out the right issue (I was importing
In
Is a |
There is no |
I have the same
Any thoughts ? |
I finally got it working ! Analyzing this PyGTK OSX package, I noticed that the postinstall script was adding the install path to
I think that brew just assume python to be installed with a brew package. Could you please add this step to the installation tutorial ? |
I’m not sure what happened on your system, but in any case WeasyPrint’s documentation is not the place to fix Homebrew’s PyGTK formula. I see that it has a warning about "non-Homebrew Python": Does that help, as an alternative to your fix? |
If you undo these changes to your PyGTK install and got back to the default, does 35540be fix the issue? (It’s in git master.) |
Closing, as I believe that 35540be fixed the issue. |
I had this problem today while i was upgrading my django code on a server. The problem was that i didn't have pango1.0-dev installed on my system. I installed that library and everything works well now. |
@marianobianchi I think yours was not exactly the same problem, since we’re not using PyGTK anymore. But thanks for sharing, I’ll remember to check the dependencies when debugging similar problems. |
I know it is closed but after one year i run into the same problem again. I installed pycparser and everything seems to work fine again. |
@marianobianchi Was pycparser not already installed as a (recursive) dependency? |
I was having another problem and was installing all packages with "--no-deps" option in pip. That made me run into this problem again and found this old bug report. I thought it was a good idea to comment the solution that worked for me this time, but wasn't sure if this was the correct place to do it. I have just installed using "pip install weasyprint" and it installed all the dependencies fine. So i think it's nothing to worry about... |
Although the error message could definitely be better, I’m not too surprised that installing without dependencies doesn’t work. |
I'm trying to use WeasyPrint in my virtualenv. I followed the Homebrew steps from the installation instructions, but I get an error while trying to generate a simple PDF:
The error comes from
weasyprint/css/__init__.py
:The text was updated successfully, but these errors were encountered: