Ben Chuanlong Du's Blog

It is never too late to learn.

Misc Tips on Java

Tips and Traps

  1. Use == (instead of the method Object.equals) to compare objects is a common and tricky mistake for beginner.

  2. You cannot define an abstract static method. This is because "abstract" means that no functionality is implemented while "static" means that functionality exists even there is no object. The two conflict in concept.

Distributed Programming in Python

Things on this page are fragmentary and immature notes/thoughts of the author. Please read with your own judgement!

https://github.com/rq/rq

https://python-rq.org/

Measure Python Code Coverage

Things on this page are fragmentary and immature notes/thoughts of the author. Please read with your own judgement!

Measure Python Code Coverage using coverage.py

pip3 install coverage

poetry run coverage run -m pytest

poetry run coverage report -m

poetry run coverage html

PyTest

$ pip install pytest-cov $ py.test …