Skip to content

Conversation

@gabsow
Copy link
Collaborator

@gabsow gabsow commented Dec 16, 2025

Also allow PYTHON override for flow tests, and add a regression test for ts-num-threads module args.


Note

Support ts-num-threads as a load-time module argument (validated, preferred over NUM_THREADS), add a regression test, and allow overriding the Python interpreter in flow tests.

  • Config:
    • Support ts-num-threads as a load-time argument with bounds validation; prefer it over deprecated NUM_THREADS when both provided; initialize default and tighten error logging on parse/range failures.
  • Tests:
    • Add regression test ensuring ts-num-threads module argument sets CONFIG ts-num-threads and is not flagged deprecated.
    • Flow runner tests/flow/tests.sh: allow overriding Python via PYTHON env (resolving relative paths) and use it to invoke RLTest.

Written by Cursor Bugbot for commit 4bf8d4e. This will update automatically on new commits. Configure here.

Also allow PYTHON override for flow tests, and add a regression test for ts-num-threads module args.
src/config.c Outdated
if (argc > 1 && RMUtil_ArgIndex("ts-num-threads", argv, argc) >= 0) {
long long parsed = TSGlobalConfig.numThreads;
if (RMUtil_ParseArgsAfter("ts-num-threads", argv, argc, "l", &parsed) != REDISMODULE_OK) {
RedisModule_Log(ctx, "warning", "Unable to parse argument after ts-num-threads");
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should probably be an error log, not warning.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fixed

src/config.c Outdated
}
if (parsed < NUM_THREADS_MIN || parsed > NUM_THREADS_MAX) {
RedisModule_Log(ctx,
"warning",
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same (and all cases below that lead to a TSDB_ERROR)

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fixed

@gabsow gabsow changed the title config: accept ts-num-threads as load-time arg MOD-13142 config: accept ts-num-threads as load-time arg Dec 21, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants