catch unicode error listing profiles

there can be garbage files on the filesystem, and we shouldn't be bothered by them.
limit random ports to positive values
catch EACCES when binding notebook app

can come up for low ports on *ix, or user access control restrictions on Windows.

closes #4308
underscore missing on notebook_p4

Related with issue https://github.com/ipython/ipython/issues/4312
fix initial sys.path

recent change caused initial sys.path to lose '' as the first element in the notebook.

closes #4317
Merge pull request #4316 from pvilas/master

underscore missing on notebook_p4
test first element of sys.path in Kernel

both when `--profile-dir` is specified, and when it is not.
Deleted commented addthis toolbar.
Deleted loading of addthis-specific js file and other references.
Use the with statement to open a file.
Merge pull request #4315 from jdfreder/docs_pandoc_version

Explicitly state what version of Pandoc is supported in docs/install
Merge pull request #4318 from minrk/sys.path

fix initial sys.path
Merge pull request #4327 from abhinav-upadhyay/use-with-to-read-file

Use the with statement to open a file.
Merge pull request #4324 from damianavila/remove_addthis

Remove commented addthis toolbar
Merge pull request #4314 from minrk/eaccess

catch EACCES when binding notebook app

can come up for low ports on *ix, or user access control restrictions on Windows.

closes #4308
Merge pull request #4264 from minrk/unicode-list-profiles

catch unicode error listing profiles
Improvements to kernel.js

- dispatch iopub handlers by msg_type
- add Kernel.send_shell_message public API
- use strict (and related fixes)
add Kernel-side widgets
add javascript-side widgets
document widget messages