Fix comments and unittest for market.py and style

Trying to make the right commit to  the develop branch.
The fact that the key is stored in settings is an implementation detail, not part of the API. This should not be in the comment.