why don't the lichess pgns have milliseconds recorded in their timestamps?
Because PGN doesn't support milliseconds.
chesscom's pgn has milliseconds
1. e4 {[%clk 0:03:00]} 1... c5 {[%clk 0:03:00]} 2. Nf3 {[%clk 0:02:58.9]} 2...
d6 {[%clk 0:02:58.8]} 3. c3 {[%clk 0:02:56.6]} 3... Nf6 {[%clk 0:02:58.2]} 4. h3
{[%clk 0:02:54.7]} 4... e5 {[%clk 0:02:55]} 5. Bd3 {[%clk 0:02:53.1]} 5... Nc6
{[%clk 0:02:54.6]} 6. Bc2 {[%clk 0:02:51.6]} 6... Be7 {[%clk 0:02:51.4]} 7. d3
{[%clk 0:02:50.7]} 7... O-O {[%clk 0:02:50.9]} 8. Nbd2 {[%clk 0:02:50.1]} 8...
h6 {[%clk 0:02:50.7]} 9. g4 {[%clk 0:02:45.8]} 9... Nh7 {[%clk 0:02:41.5]} 10.
Nf1 {[%clk 0:02:44.3]} 10... Ng5 {[%clk 0:02:40.9]} 11. Ng3 {[%clk 0:02:42.1]}
11... d5 {[%clk 0:02:34.4]} 12. h4 {[%clk 0:02:35.4]} 12... Nxf3+ {[%clk
0:02:13.8]} 13. Qxf3 {[%clk 0:02:34.5]} 13... dxe4 {[%clk 0:02:13.7]} 14. Nxe4
{[%clk 0:02:31.4]} 14... f5 {[%clk 0:02:11.5]} 15. gxf5 {[%clk 0:02:25.9]} 15...
Bxf5 {[%clk 0:02:11.1]} 16. Qg3 {[%clk 0:02:23.3]} 16... Kh8 {[%clk 0:02:07.8]}
17. Be3 {[%clk 0:02:21.1]} 17... Rc8 {[%clk 0:01:49.3]} 18. O-O-O {[%clk
0:02:18.3]} 18... Nd4 {[%clk 0:01:46.3]} 19. Qxe5 {[%clk 0:02:10.7]} 19... Nxc2
{[%clk 0:01:44.6]} 20. Kxc2 {[%clk 0:02:10.6]} 20... Qc7 {[%clk 0:01:39]} 21.
Qxc7 {[%clk 0:02:08.3]} 21... Rxc7 {[%clk 0:01:38.9]} 22. c4 {[%clk 0:02:05.7]}
22... Bh7 {[%clk 0:01:13.3]} 23. Rdg1 {[%clk 0:02:01.2]} 23... b6 {[%clk
0:01:06.1]} 24. b3 {[%clk 0:02:00.3]} 24... Rd7 {[%clk 0:01:03.7]} 25. Rd1
{[%clk 0:01:52.8]} 25... Rfd8 {[%clk 0:00:58.1]} 26. f3 {[%clk 0:01:51.5]} 26...
Rf8 {[%clk 0:00:56.8]} 27. Rdf1 {[%clk 0:01:47.2]} 27... Bd8 {[%clk 0:00:55.1]}
28. Kd2 {[%clk 0:01:42.1]} 28... Bc7 {[%clk 0:00:47.9]} 29. Ke2 {[%clk
0:01:41.3]} 29... Rfd8 {[%clk 0:00:46.8]} 30. Rd1 {[%clk 0:01:40.3]} 30... Be5
{[%clk 0:00:46.4]} 31. Bg1 {[%clk 0:01:33]} 31... Rf8 {[%clk 0:00:43.5]} 32. Bh2
{[%clk 0:01:31.8]} 32... Bd4 {[%clk 0:00:41.7]} 33. Bg1 {[%clk 0:01:30.1]} 33...
Be5 {[%clk 0:00:41]} 34. Be3 {[%clk 0:01:29.8]} 34... Rdf7 {[%clk 0:00:39.6]}
35. Rdf1 {[%clk 0:01:29]} 35... Rd8 {[%clk 0:00:38.5]} 36. Rhg1 {[%clk
0:01:26.2]} 36... Rfd7 {[%clk 0:00:37.9]} 37. Rd1 {[%clk 0:01:25.6]} 37... Rf7
{[%clk 0:00:37.2]} 38. Bd2 {[%clk 0:01:22.1]} 38... Rfd7 {[%clk 0:00:35.4]} 39.
Bc3 {[%clk 0:01:14.1]} 39... Bxc3 {[%clk 0:00:31.5]} 40. Nxc3 {[%clk 0:01:14]}
40... Bxd3+ {[%clk 0:00:30.2]} 41. Kf2 {[%clk 0:01:12.6]} 41... Bc2 {[%clk
0:00:27.9]} 42. Rxd7 {[%clk 0:01:11.6]} 42... Rxd7 {[%clk 0:00:27.8]} 43. Nd5
{[%clk 0:01:11.4]} 43... Bf5 {[%clk 0:00:25.6]} 44. Re1 {[%clk 0:01:11.1]} 44...
Kh7 {[%clk 0:00:19.8]} 45. Re5 {[%clk 0:01:10.2]} 45... Bb1 {[%clk 0:00:19.2]}
46. Nc3 {[%clk 0:01:07.8]} 46... Bg6 {[%clk 0:00:18.8]} 47. h5 {[%clk
0:01:06.8]} 47... Bf7 {[%clk 0:00:18.6]} 48. Ke3 {[%clk 0:01:04.3]} 48... g6
{[%clk 0:00:18]} 49. Ne4 {[%clk 0:01:03.9]} 49... Kg7 {[%clk 0:00:17.3]} 50.
hxg6 {[%clk 0:01:01.2]} 50... Bxg6 {[%clk 0:00:17.2]} 51. f4 {[%clk 0:01:00.9]}
51... Rf7 {[%clk 0:00:16.4]} 52. Nd6 {[%clk 0:00:59.3]} 52... Rd7 {[%clk
0:00:16.2]} 53. Re6 {[%clk 0:00:57.4]} 53... Bf7 {[%clk 0:00:15.2]} 54. Nf5+
{[%clk 0:00:56.1]} 1-0
d6 {[%clk 0:02:58.8]} 3. c3 {[%clk 0:02:56.6]} 3... Nf6 {[%clk 0:02:58.2]} 4. h3
{[%clk 0:02:54.7]} 4... e5 {[%clk 0:02:55]} 5. Bd3 {[%clk 0:02:53.1]} 5... Nc6
{[%clk 0:02:54.6]} 6. Bc2 {[%clk 0:02:51.6]} 6... Be7 {[%clk 0:02:51.4]} 7. d3
{[%clk 0:02:50.7]} 7... O-O {[%clk 0:02:50.9]} 8. Nbd2 {[%clk 0:02:50.1]} 8...
h6 {[%clk 0:02:50.7]} 9. g4 {[%clk 0:02:45.8]} 9... Nh7 {[%clk 0:02:41.5]} 10.
Nf1 {[%clk 0:02:44.3]} 10... Ng5 {[%clk 0:02:40.9]} 11. Ng3 {[%clk 0:02:42.1]}
11... d5 {[%clk 0:02:34.4]} 12. h4 {[%clk 0:02:35.4]} 12... Nxf3+ {[%clk
0:02:13.8]} 13. Qxf3 {[%clk 0:02:34.5]} 13... dxe4 {[%clk 0:02:13.7]} 14. Nxe4
{[%clk 0:02:31.4]} 14... f5 {[%clk 0:02:11.5]} 15. gxf5 {[%clk 0:02:25.9]} 15...
Bxf5 {[%clk 0:02:11.1]} 16. Qg3 {[%clk 0:02:23.3]} 16... Kh8 {[%clk 0:02:07.8]}
17. Be3 {[%clk 0:02:21.1]} 17... Rc8 {[%clk 0:01:49.3]} 18. O-O-O {[%clk
0:02:18.3]} 18... Nd4 {[%clk 0:01:46.3]} 19. Qxe5 {[%clk 0:02:10.7]} 19... Nxc2
{[%clk 0:01:44.6]} 20. Kxc2 {[%clk 0:02:10.6]} 20... Qc7 {[%clk 0:01:39]} 21.
Qxc7 {[%clk 0:02:08.3]} 21... Rxc7 {[%clk 0:01:38.9]} 22. c4 {[%clk 0:02:05.7]}
22... Bh7 {[%clk 0:01:13.3]} 23. Rdg1 {[%clk 0:02:01.2]} 23... b6 {[%clk
0:01:06.1]} 24. b3 {[%clk 0:02:00.3]} 24... Rd7 {[%clk 0:01:03.7]} 25. Rd1
{[%clk 0:01:52.8]} 25... Rfd8 {[%clk 0:00:58.1]} 26. f3 {[%clk 0:01:51.5]} 26...
Rf8 {[%clk 0:00:56.8]} 27. Rdf1 {[%clk 0:01:47.2]} 27... Bd8 {[%clk 0:00:55.1]}
28. Kd2 {[%clk 0:01:42.1]} 28... Bc7 {[%clk 0:00:47.9]} 29. Ke2 {[%clk
0:01:41.3]} 29... Rfd8 {[%clk 0:00:46.8]} 30. Rd1 {[%clk 0:01:40.3]} 30... Be5
{[%clk 0:00:46.4]} 31. Bg1 {[%clk 0:01:33]} 31... Rf8 {[%clk 0:00:43.5]} 32. Bh2
{[%clk 0:01:31.8]} 32... Bd4 {[%clk 0:00:41.7]} 33. Bg1 {[%clk 0:01:30.1]} 33...
Be5 {[%clk 0:00:41]} 34. Be3 {[%clk 0:01:29.8]} 34... Rdf7 {[%clk 0:00:39.6]}
35. Rdf1 {[%clk 0:01:29]} 35... Rd8 {[%clk 0:00:38.5]} 36. Rhg1 {[%clk
0:01:26.2]} 36... Rfd7 {[%clk 0:00:37.9]} 37. Rd1 {[%clk 0:01:25.6]} 37... Rf7
{[%clk 0:00:37.2]} 38. Bd2 {[%clk 0:01:22.1]} 38... Rfd7 {[%clk 0:00:35.4]} 39.
Bc3 {[%clk 0:01:14.1]} 39... Bxc3 {[%clk 0:00:31.5]} 40. Nxc3 {[%clk 0:01:14]}
40... Bxd3+ {[%clk 0:00:30.2]} 41. Kf2 {[%clk 0:01:12.6]} 41... Bc2 {[%clk
0:00:27.9]} 42. Rxd7 {[%clk 0:01:11.6]} 42... Rxd7 {[%clk 0:00:27.8]} 43. Nd5
{[%clk 0:01:11.4]} 43... Bf5 {[%clk 0:00:25.6]} 44. Re1 {[%clk 0:01:11.1]} 44...
Kh7 {[%clk 0:00:19.8]} 45. Re5 {[%clk 0:01:10.2]} 45... Bb1 {[%clk 0:00:19.2]}
46. Nc3 {[%clk 0:01:07.8]} 46... Bg6 {[%clk 0:00:18.8]} 47. h5 {[%clk
0:01:06.8]} 47... Bf7 {[%clk 0:00:18.6]} 48. Ke3 {[%clk 0:01:04.3]} 48... g6
{[%clk 0:00:18]} 49. Ne4 {[%clk 0:01:03.9]} 49... Kg7 {[%clk 0:00:17.3]} 50.
hxg6 {[%clk 0:01:01.2]} 50... Bxg6 {[%clk 0:00:17.2]} 51. f4 {[%clk 0:01:00.9]}
51... Rf7 {[%clk 0:00:16.4]} 52. Nd6 {[%clk 0:00:59.3]} 52... Rd7 {[%clk
0:00:16.2]} 53. Re6 {[%clk 0:00:57.4]} 53... Bf7 {[%clk 0:00:15.2]} 54. Nf5+
{[%clk 0:00:56.1]} 1-0
"PGN" doesn't support movetimes at all. The PGN spec makes no requirements on what goes into the comment fields in the {} delimiters, it's entirely up to the platform what to put in the comments and on the reader to figure out what they mean.
The times in the comments in that PGN in #4 are only showing tenths of a second anyway. I don't know if chessdotcom really shows milliseconds, but that PGN score doesn't illustrate it.
Displaying milliseconds would be overkill in my opinion. Gimmicky at best.
Displaying milliseconds would be overkill in my opinion. Gimmicky at best.
While PGN specifications do not, a supplement backed by major chess software companies, that is de-facto part of the standard now, have these specs:
github.com/mliebelt/pgn-spec-commented/blob/main/pgn-spec-supplement.md#42-the-clk-command
and milliseconds are not there. P in PGN stands for portable and it won't be if you do not adhere to agreed specifications.
github.com/mliebelt/pgn-spec-commented/blob/main/pgn-spec-supplement.md#42-the-clk-command
and milliseconds are not there. P in PGN stands for portable and it won't be if you do not adhere to agreed specifications.
BTW, if you need clock times with precision, export in NDJSON format instead:
lichess.org/api#tag/Games/operation/apiGamesUser
For example:
curl -G -H "Accept: application/x-ndjson" -d "clocks=true" -d "max=2" https:// lichess.org/ api/games/user/username
lichess.org/api#tag/Games/operation/apiGamesUser
For example:
curl -G -H "Accept: application/x-ndjson" -d "clocks=true" -d "max=2" https:// lichess.org/ api/games/user/username