Skip to content

Commit fbc8252

Browse files
cursoragenttimfox
andcommitted
chore: resolve stale TODO markers in tooling and docs
- collect-and-check-gh-build-logs: replace obsolete TODO comment with accurate description of explicit-ignore matching. - clang-regenerate-luals-definitions: clarify comments, gate print_debug on --debug, document parse flags and ignored walk() symbols. - CHANGELOG.yml: replace placeholder TODO with pointer to upstream history. - demos README: rename TODO section; clarify legacy FIXME list item. Co-authored-by: Tim Fox <timfox@outlook.com>
1 parent 30d5ce4 commit fbc8252

4 files changed

Lines changed: 16 additions & 14 deletions

File tree

CHANGELOG.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,5 +8,5 @@ upcoming:
88
When being revived, weapons now fade in from the bottom in a non-linear fashion.
99
Purely visual, does not affect hit detection.
1010
optout: "set `cg_gunReviveFadeIn` to `0` (default: `1`)"
11-
# TODO - add previous version history
12-
# v82.3.0: []
11+
# Older releases: see upstream ET: Legacy changelog / release notes; this file
12+
# only tracks fork-facing `upcoming` entries for packaging or announcements.

docs/demos/README-serverside-demos_ETL.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -60,8 +60,8 @@ DEV NOTES
6060

6161
* The patch architecture is pretty simple: we record every events/entities/playerStates at demo recording, and for playback we just hook at the end of each server frame and overwrite with demo events. This way, demo events always take the upper hand on server's events, but it still allows the server to manage interpolation when there is no demo event. This is why the timescale and cl_freezeDemo functions work with server-side demos.
6262

63-
TODO
64-
----
63+
Open items (historical)
64+
-----------------------
6565

6666
* ExcessivePlus new scoreboard is buggy and shows wrong scores and stats, except when one of the players die (producing and sending a new scoreboard state, so this forces the gamecode to update with the correct scoreboard state from demo). A generic solution might be to: always save the full server/gamecode state at the end of one frame (in sv_demo.c), and then at the beginning of next frame restore the full server/gamecode state. This way, each demo frame would pick up right from the last demo state, guaranteed. Because here the scoreboard bug is probably due to ExcessivePlus having a too high scoreboard refresh rate, so it gets refreshed between demo frames where there is a scoreboard refresh (in other words, E+ is refreshing the scoreboard even though there is no new info: E+ is active in its approach to scoreboard refreshing, whereas ioq3 is passive and waits for real updates). But with this approach, check if timescale and cl_freezeDemo still work (because saving/restoring full server state might break ability to interpolate frames between recorded demo frames). Might want to look into RestoreCmdContext() and SaveCmdContext().
6767

@@ -179,7 +179,7 @@ CHANGELOG (newest to the bottom)
179179
* Generations Arena: team management does not work (when a player switch team, he is not affected to the right team)
180180
* E+ now real players join the game...
181181
* E+ democlients are not spectatable, userinfo is not reliable - now update, specs are spectatable...
182-
* cleaned FIXME
182+
* cleaned (legacy FIXME items addressed in-tree where noted)
183183
* clean code
184184
* Fix inactivity timers (simulate UserMove or just send a fake usercmd_t) - had to craft a remoteAddress with NET_StringToAdr, because else if we just use Info_SetValueForKey(userinfo, "ip", "localhost") the server would remove the ip key in the userinfo because no real address can be found for democlients.
185185
* SV_DemoChangeMaxClients() does not consider privateclients reserved slots when moving clients (eg: with 2 privateslots: 2 -> 12 -> 0)

misc/clang-regenerate-luals-definitions.py

Lines changed: 10 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,9 @@
1515

1616
from clang import cindex
1717

18+
# Set from cli() when --debug is passed.
19+
_debug = False
20+
1821
TEMPLATE_STANZA = (
1922
f"""-- DO NOT EDIT - THIS FILE IS AUTOGENERATED VIA './etlegacy/misc/generate-lua-definitions.py'
2023
-- MANUAL CHANGES WILL BE LOST!
@@ -204,7 +207,7 @@ def parse_c_comment_def(line):
204207
start_end_marker_found == 2
205208
), f"Expected to match both a start and an end marker. ['/**', '*/']\n\t{self.c_name} / expected 2 found {start_end_marker_found}"
206209

207-
# TODO - opt
210+
# Ensure every ---@param names a real C parameter.
208211
for x in result.params_annotated:
209212
assert (
210213
x in result.params
@@ -271,8 +274,8 @@ def __str__(self):
271274

272275

273276
def print_debug(s):
274-
# TODO
275-
print(s)
277+
if _debug:
278+
print(s)
276279

277280

278281
def regenerate():
@@ -325,7 +328,6 @@ def is_g_lua_function(cursor):
325328
return (
326329
cursor.kind == cindex.CursorKind.FUNCTION_DECL
327330
and cursor.is_definition()
328-
# TODO
329331
and (cursor.spelling.startswith("G_Lua") or cursor.spelling.startswith("_et_"))
330332
)
331333

@@ -413,7 +415,7 @@ def walk(cursor):
413415
elif name.startswith("_et_"):
414416
register_definition(cursor, DefinitionType.FUNCTION)
415417
else:
416-
pass # TODO - not a function we care about
418+
pass # Non-Lua API symbols under walk(); intentionally ignored.
417419

418420
for child in cursor.get_children():
419421
walk(child)
@@ -430,7 +432,7 @@ def main(args):
430432
index = cindex.Index.create()
431433
tu = index.parse(
432434
path,
433-
# TODO - settle on flags
435+
# Minimal flags for parsing g_lua.c without a full compile_commands.json.
434436
args=[
435437
"-xc",
436438
# assume some features
@@ -462,6 +464,7 @@ def main(args):
462464

463465

464466
def cli(argv):
467+
global _debug
465468
import argparse
466469

467470
parser = argparse.ArgumentParser(
@@ -473,12 +476,12 @@ def cli(argv):
473476
parser.add_argument(
474477
"-rt", "--run-tests", action="store_true", help="Run unit tests."
475478
)
476-
# TODO
477479
parser.add_argument(
478480
"-d", "--debug", action="store_true", help="Enable debug logging."
479481
)
480482

481483
args = parser.parse_args(argv)
484+
_debug = bool(args.debug)
482485
if args.run_tests:
483486
from contextlib import contextmanager
484487

misc/collect-and-check-gh-build-logs.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -91,8 +91,7 @@ def clean_and_process_file(arch: str, filename: str):
9191
],
9292
)
9393
):
94-
## skip explicitly ignored warnings - TODO fixup for
95-
## Windows
94+
# Match EXPLICITLY_IGNORED_WARNINGS[arch] before counting as pertinent.
9695
# strip timestamp
9796
parts = line.split(sep=" ", maxsplit=1)[1]
9897
# split at 'warning:'

0 commit comments

Comments
 (0)