I prepared all the things to make the invoice run today, but when it came to printing the invoices, I ran into a problem I don’t understand.
I didn’t realized there is a problem with my phantomjs local installation, because the tests have been done by invoice ninja via phantomjs cloud, so I didn’t notice there were problems.
No I generated 100 invoices and the pdfs are broken because of the demo key limitation, which is the reason why I now noticed that there is a problem.
Well, the problem is that the local phantomjs doesn’t seem to do its job. The builtin test page on https://my.invoiceninja.local/test_headless just states “Failed to load PDF document.”
Testing with the test.pjs on the commandline says:
root@ninja:~# phantomjs /var/www/html/invoiceninja/resources/test.pjs
\n{
“content”: “”,
“console”: []
}TypeError: Attempting to change the setter of an unconfigurable property.
TypeError: Attempting to change the setter of an unconfigurable property.
root@ninja:~#
I don’t have a clue what phantomjs wants to tell me.
But I need to get the invoices out today, so HELP PLEASE
Edit: Invoice Ninja v4.5.19, phantomjs v2.1.1, on debian 10
Yes. the phantomjscloud service works. The problem is, that the local phantomjs installation doesn’t, and for obvious reasons I don’t want to rely on an external service for invoice generation.
Hmmm, any other info about that?
I can not imagine that there is no way in debugging this - there MUST be a way to find out why phantomjs is working fine when called on commandline but results in an unnamed error when called via invoice ninja…
It’s quite a deal breaker if I have to render all PDFs via phantomjs cloud service. Management will not allow this as a permanent solution and thus throws me back for months of work to integrate invoice ninja in our company…
Never heard of headless chrome, but sounds promising… however, since I can’t wait for v5 with our migration, I need a solution for phantomjs… and it’s possible that I just found one.
I know it sounds extremely strange, but I have no clue what’s different compared to yesterday, but now:
root@host:~# phantomjs /var/www/html/invoiceninja/resources/test.pjs
qt.qpa.screen: QXcbConnection: Could not connect to display
I installed phantomjs as package from phantomjs.org, and there: