How do I disable notice log entries on wkhtmltopdf? - wkhtmltopdf

The Setup
I have a LAMP stack site that uses wkhtmltopdf to convert several html templates to pdf on demand by the customer. This is working fine.
Version: wkhtmltopdf 0.12.4 (with patched qt)
CentOS 6
The Problem
I occasionally review my error log to make sure the system is working and to debug errors that happen on the live server. However my log is filled with entries from wkhtmltopdf that look like this:
Loading pages (1/6)
Counting pages (2/6)
Resolving links (4/6)
Loading headers and footers (5/6)
Printing pages (6/6)
Done
I'm using the command like: wkhtmltopdf /temp/source/file.html
My Attempt
According to the documentation I can turn this off with the direction --log-level error. However If I include this the entire command fails.
The question
How do I turn off these notices to stop cluttering my log (nearly 80% of my log)? Was the command renamed and the documentation not updated? Is theri a different way to capture command line log entries and prevent them from writing to the log or redirect to a different log that I can cron scrape?

Related

Can't get Crashlytics to Process dSYMs

I've been using Crashlytics for some years quite successfully. This was with the web interface for processing symbols. However, I cannot seem to get the processing of symbols to work such that the web page stops showing that required symbols are missing. These are the specific approaches I have taken within Xcode and the terminal.
First, as part of the Build Phases tab, I have added the following as a Run Script
"${PODS_ROOT}/FirebaseCrashlytics/run" -gsp "${PROJECT_DIR}/Resources/GoogleService-Info.plist"
This does not cause any errors or warnings but also doesn't seem to do anything.
Second, since the above doesn't do anything, I use the terminal to manually upload the symbols. To make things easier I get the dSYMs folder for the build and put it directly into the Pods/FirebaseCrashlytics directory. I do the same with the GoogleService-Info.plist file. I then execute the following command:
sudo ./upload-symbols -gsp GoogleService-Info.plist -p ios dSYMs
The process runs and the output shows that symbols are being successfully uploaded. There are no errors thrown with every line being a success. Checking the dashboard, however, and the required symbols remain the same and nothing is processed. I know processing can take some time but it stays this way for days. When I have uploaded via the web page in the past, it was a matter of minutes. Of course there is nothing on the web page to indicate that it has received and is processing anything so I have no idea what's happening.
What am I missing here and how can I get symbols to process again?

Using wkhtmltopdf from a web page

I am looking for a solution to producing a pdf document from a web page and have read the good reviews of wkhtmltopdf. I might be missing something but it appears that it is only run from the command line on the machine being used. I have a site that is predominantly php, for which there is a log in, and a number of session variables and queries from a database are used to produce the html output. What I am looking for is a means by which I can add a single button on the html page created to generate the pdf version.
Also, while I have installed wkhtmltopdf locally and tested it out from the command line I can't see how can you call on the function from where my site is hosted.
I have used HTML2PDf in the past but it struggled with tables and so thought I would give wkhtmltopdf a go but I am not sure it will meet my needs. Can it do what I am asking of it?

Can't save when running "jekyll serve" on Windows 8.1, Notepad++

I am trying to use jekyll locally to build my website. It is all set up, and I can build and serve and see results at localhost:4000. There are no errors.
The problem is that when I run "Jekyll serve" I can't save files. The save option is greyed out and "ctrl + s" wont work.
I can open and edit the files, can do "Save As" and do other things - basically anything except saving.
I can save files when I am not serving them.
From what I understand, Jekyll is intended to be used to allow saving while serving so we can see our changes as we go. The auto-regenerate function (now a default with serve) supports that use.
I suspect the problem relates to some sort of permissions-type rule stopping me from editing files that are in use.
But because I am self-taught newbie and am not a developer/programmer, I don't know if it is something to do with how I have set up jekyll, notepad++, permissions or something else entirely.
Here is my environment:
Windows 8.1 64-bit
Ruby v2.1.5p
Jekyll v2.5.1
wdm v0.1.0
RubyDevKit
Notepad++ (in admin mode)
Here is what I have tried:
Scaled back the listen gem from v2.10.0 to v2.7.11 (the earlier was listed as safe/tested on a jekyll on windows website)
Scaled back Jekyll from v2.5.3 to v2.5.1 (the earlier was listed as safe/tested on a jekyll on windows website)
Opened Notepad++ in admin mode instead of normal mode.
Tried executing jekyll serve --watch (in case watch enabled saving)
I have not tried re-installing ruby v2.1.3 (listed as safe/tested on a Jekyll on windows website) because Jekyll is otherwise working I don't want to try a re-install except as a last resort - as a newbie I found it a pain to install it on Windows in the first place.
Can anyone help me with this (probably simple) issue?
I thank you for any assistance in advance.
Okay. So I feel really stupid.
But instead of pretending this never happened, I had better post this answer in case anyone else has a blonde 'moment' (read: an entire day) like I did:
Firstly, you can't edit the _config.yml files while serving. You can edit the other files - html, markdown, etc - but not the config file.
Secondly, in Notepad++ you need to make an actual change to a document before the saving option will appear.
I was using the _config file as my 'test' document for regeneration. While I did open up other files to check when I first thought I had an issue, I THINK I may not have made any changes to them - so the option to save them was never activated. After that, I only looked at the config file after making changes.
So, I THINK I may have been able to save while serving all along.
However, if I am wrong and it wasn't my own stupidity (which I strongly doubt), the steps I took which fixed it were:
Those steps outlined in my question; and
A reinstall of Notepad++ (as kindly recommended by 'nerver nerver' who has since removed his/her comment after I said that did not work).
SORRY ... and excuse me while I go and crawl away and hide in shame ...
If the files you were editing at that time was only _config.yml then the expected behavior is that the saved changes are not reflected when the Jekyll server is running/watching.
This is because the server is started after reading the configuration settings in _config.yml, and then changes that happen to that special file after that are not monitored by Jekyll (this is current as of May 2015, in case this gets changed in the future). Currently this is by design. see this SO question as well
What that means is, you have been saving the file when Jekyll is running just fine, the changes just do not get updated. A way to check this is to make some changes, close the file, then open it again (if you want to be extra sure, open in another editor) and see if reflected changes show up.
Changes made to other files in Jekyll when the server is running will be reflected. For example, if I edit a typo in a blog post, edit CSS files or change some formatting, and save in any text editor, Jekyll will regenerate the file from scratch and you should be able to see the changes by refreshing the localhost:4000 page (or whereever your server is running at).
I'm not sure about running Jekyll on Windows, but on a Linux terminal, Jekyll actually notified the number of files that have changed (with a timestamp) and that it regenerated X number of files. Something like
<timestamp> 3 files have changed. Regenerated 3 files in 0.0536 sec..
Lastly, this is probably not your issue, but I thought I might add this here for future reference, do not edit the files inside the _site folder, as they are always deleted and regenerated whenever the server is started again. Editing those files by hand might save and display changes, but the changes will be lost (because they are, statically generated every time by Jekyll)
TL;DR You most probably have been saving your files! The changes in _config.yml are just not reflected once the server is running, and has to be restarted for the new configuration parameters to take effect.

I can't log into magento

I can't log into Magento,
I installed GTSPEED extension. I logged out from admin and now I can't log in, but it doesn't show any kind of error.
How could I solve it? My site is running and I need to operate. Thank You!
just check weather you comment this line or not
app\code\core\Mage\Core\Model\Session\Abstract\Varien.php
just comment this line if you not comment it find following line and comment it
call_user_func_array('session_set_cookie_params', $cookieParams);
and then check weather it's work or not
Before installing modules like this, it's imperative that you shut off caching (and if you use it, the compiler) and only reenable after the module has properly installed itself.
After-the-fact recovery says that you will need to clear the cache (manually by deleting all the mage--? folders in var/cache) so all the old Magento code gets flushed so Magento can properly re-read all the config files and properly integrate the module into its running system and then remove all active sessions by deleting files in var/session. Once this is done, you will have to log into the admin panel and back out about two or three times so it starts loading the menus and config setups.

magento - $ is not a function. But only on local dev server

I took a backup of my live Magento site yesterday (zipped up the files and took a DB dump then created the site from those dumps).
Oddly though, on my local machine I get a firebug error that states "$ is not a function" and this error occurs every 500ms or so. So after a minute or 2 I have thousands of errors in the console all the same.
The site is an exact replica of my live site and I don't get the error on that so I'm stumped!
Usually I would think this is a prototype/jquery conflict, but it only seems to happen on my local machine.
Any one have a clue what might be going on?
Thanks
Load a page where you see the error.
View the source of the page.
Find the line that's supposed to load prototype.js by searching for the string prototype.js.
ex. http://magento.example.com/js/prototype/prototype.js
Discover that, for one of myriad reasons, the file isn't loading. (wrong URL, permissions, corrupt file, etc.)
Address problem discovered above.
Ok so this was the problem:
The reason it worked on live and not dev was because I had merge JS enabled on live and not on dev. Live was therefore looking at an old cached bunch of js. Disabling merge js on live highlighted that the problem did in fact occur on the live site.
This knowledge allowed me to debug further and I discovered that the problem lay with my jquery.hove.intent.js file. I updated this to the latest version and it solved everything! :)
Thanks all for your help and input though.

Resources