fix #595 and fix #550

Some markdown formatting before: cls.__name__ -> `cls.__name__`