zielu / GitToolBox

GitToolBox IntelliJ plugin
GNU General Public License v3.0
604 stars 71 forks source link

[BUG] inline blame timezone issue #432

Closed edwardchenchen closed 1 year ago

edwardchenchen commented 1 year ago

Describe the bug

I expect the inline blame to show relative time in my local timezone and that should match the pycharm git blame in this case should be yesterday

 2022-12-01 at 10 53 42

the commit is made on 8953e20d Edward <> on 30/11/2022 at 14:41 committed on 30/11/2022 at 14:44

when screenshot the local time is 01/12/2022 10:56:34 AEDT +11:00

To Reproduce Steps to reproduce the behavior:

  1. Go to '...'
  2. Click on '....'
  3. Scroll down to '....'
  4. See error

Expected behavior

I expect the inline blame to show relative time in my local timezone

Plugin version 213.10.2

IDE version

PyCharm 2022.2.4 (Professional Edition)
Build #PY-222.4459.20, built on November 18, 2022
Licensed to <>
Runtime version: 17.0.5+7-b469.71 x86_64
VM: OpenJDK 64-Bit Server VM by JetBrains s.r.o.
macOS 13.0
GC: G1 Young Generation, G1 Old Generation
Memory: 2048M
Cores: 12
Metal Rendering is ON
Registry:
    debugger.watches.in.variables=false

Non-Bundled Plugins:
    org.intellij.plugins.hcl (222.4459.16)
    com.github.copilot (1.1.36.2164)
    zielu.gittoolbox (213.10.2)
    com.atlassian.bitbucket.references (2022.1.214)
    ru.meanmail.plugin.requirements (2022.4)
    izhangzhihao.rainbow.brackets (2022.3.5-ij)

Screenshots If applicable, add screenshots to help explain your problem.

edwardchenchen commented 1 year ago
 2022-12-01 at 11 09 40

it's 11:09 now, UTC is alos in 01/12/2022 and now it shows Yesterday

zielu commented 1 year ago

Hi, I'll look into this.

zielu commented 1 year ago

There were some unnecessary time conversions and plugin was using author date instead of commiter date

zielu commented 1 year ago

Done in 500.0.0+213