I am trying to to use pdfkit in python to generate pdf from string . But its not working . But then I get the following error :-
OSError: No wkhtmltopdf executable found: "b''"
I am using ubuntu 16 and python3.6.6
I installed the wkhtmltopdf by using sudo apt-get wkhtmltopdf and tried implementing the pdfkit again , but then I get the error COULD NOT CONNECT THE X DISPLAY . 
I also tried putting export DISPLAY=:0 in environment, but still getting the error 
COULD NOT CONNECT TO DISPLAY 0
you need to do export DISPLAY=localhost:10.0
Getting Error Could Not Connect to display