Why are losses different when logging from '_step' (with on_epoch=True) compared to logging from '_epoch_end'?
🐛 Bug
When logging losses from {prefix}_step with self.log("{prefix}_loss", loss, on_step=False, on_epoch=True), they are different from losses logged in {prefix}_epoch_end, using
avg_loss = torch.stack([x["loss"] for x in outputs]).mean()
self.log(
      name="loss/" + prefix,
      value=avg_loss,
      prog_bar=False,
      logger=True,
      on_step=False,
      on_epoch=True
  )

Please reproduce using the BoringModel
https://colab.research.google.com/drive/1Sz9kgGuMWxcAPOZ7SPcm4XYhsoWgwOFt?usp=sharing
To Reproduce
Run the code from the link (I copied it into a .py-file and ran it from commandline) and see csv-file with logged losses (under ./default/version_{int}/metrics.csv).
Expected behavior
{prefix}_loss (logged from {prefix}_step) and loss/{prpefix} (logged from {prefix}_epoch_end) should be equal.
Environment

CUDA:
- GPU:
- available:         False
- version:           10.2
Packages:
- numpy:             1.19.5
- pyTorch_debug:     False
- pyTorch_version:   1.7.1
- pytorch-lightning: 1.1.4
- tqdm:              4.56.0
System:
- OS:                Linux
- architecture:
- 64bit
- ELF
- processor:         x86_64
- python:            3.8.5
- version:           #1 SMP Tue Jun 23 12:58:10 UTC 2020

Additional context
The differences in losses seem marginally using this boring model, however, to me it is unclear, why this happens.
From my understanding, there should be no differences at all when logging losses from steps with on_epoch=True or from epoch_ends.