github markus-wa/demoinfocs-golang v6.0.0-alpha.3

pre-release3 hours ago

Go Get

go get -u github.com/markus-wa/demoinfocs-golang/v6/pkg/demoinfocs@v6.0.0-alpha.3

To upgrade from v5, this may be useful to update import paths (use at your own risk):

sed -i 's/demoinfocs-golang\/v5/demoinfocs-golang\/v6/' **/*.go

See the v6.0.0-alpha.0, v6.0.0-alpha.1 and v6.0.0-alpha.2 release notes for the changes since v5 (import path /v5 → /v6, Go 1.27 requirement, the v6 API cleanup, etc.).

This is a small release so that v6 can be linked into one program with demoinfocs v4 (CS:GO) or v5, which CS Demo Analyzer needs to parse CS:GO demos with v4 and CS2 demos with v6 (#749).

Breaking Changes

  • The v6 protos can coexist with v4's and v5's by @markus-wa in #748 — a program importing both v4 and v6 used to panic at init (extension number 61000 is already registered on message google.protobuf.MessageOptions)
    • Proto full names in package msg use the package com.github.markus_wa.demoinfocs_golang.v6 and files are registered as v6/*.proto, e.g. com.github.markus_wa.demoinfocs_golang.v6.CSVCMsg_ServerInfo in v6/netmessages.proto. This affects protoregistry lookups, anypb type URLs and logged descriptor names
    • The generated file descriptor variables are renamed: File_<x>_proto → File_v6_<x>_proto (17 of them; message types like msg.CSVCMsg_ServerInfo keep their names)
    • Valve's custom option extensions (E_CodegenDeltaEncoder, E_MaximumSizeBytes, … 20 in total) are removed. demoinfocs never read them, they were only descriptor metadata
    • Go types, fields, the wire format and protojson field names are unchanged, so code that only uses the message types isn't affected
  • The v5 line continues to be maintained on the v5 branch for users not ready to upgrade

Fixes

  • Fix user command warnings never reaching event handlers by @l0rem in #752 (part 1 of #751) — WarnTypeUserCommandDeltaDecodeFailed, WarnTypeUserCommandBaselineMissing and WarnTypeUserCommandBaselineMismatch went to the net-message dispatcher, so RegisterEventHandler(func(events.ParserWarn)) never saw them (0 of 800 and 0 of 18,967 on the two demos from #751)

Changes

  • CI: test-csda runs CS2 demos only, in 2 shards, race tests and the -short run in parallel, coverage split into 2 jobs and docs-only PRs skip CI in #747 (slowest job on a cache hit ~140 s → ~85 s); CSDA's CS:GO demos run again in a third test-csda shard, as a smoke test of CSDA's combined v4 + v6 build against this repo, in #750
  • Protos: prepare-protos.py applies the package, import prefixes and option stripping before generate.sh, and the nightly "Update Protobufs" workflow uses it (#748)

New Contributors

Full Changelog: v6.0.0-alpha.2...v6.0.0-alpha.3

Discussions / Chat / Announcements

Discord Chat

Don't miss a new demoinfocs-golang release

NewReleases is sending notifications on new releases.