cylc.job_submission.job_submit: improve pylint score

This pull request contains changes that I have done as part of the log and work restructure change, but should really be separate.

The change is mainly to increase the pylint score and pep8 compliance for `cylc.job_submission.job_submit`.

I have also introduced a small change in `cylc.task_types.task.py` to create the remote job log directory at the point when it installs the suite contact environment file. (This prevents job submission failures when we have `mkdir -p` race condition - which can happen quite regularly on our AIX system.)
I always find this kind of rules strange, because third party libraries can in time become standard libraries. The same is true for local application libraries.

It is much more future proof to list them in alphabetical order of the module names.

(But then again, I should live with the rules of the tool I am using.)