feat: support groups.ignore-submitter
All checks were successful
build / build (push) Successful in 2m20s
build / trigger-build-image (push) Successful in 13s

This commit is contained in:
张泊明518370910136 2025-10-30 19:52:08 -07:00
parent f570ea5aca
commit 4b2e818538
GPG Key ID: D47306D7062CDA9D
3 changed files with 11 additions and 0 deletions

View File

@ -20,6 +20,9 @@ class Groups(StrictBaseModel):
time_period_hour: List[int] = Field(
[], validation_alias=AliasChoices("time-period-hour", "time_period_hour")
)
ignore_submitter: bool = Field(
False, validation_alias=AliasChoices("ignore-submitter", "ignore_submitter")
)
class Label(StrictBaseModel):

View File

@ -153,6 +153,8 @@ def get_teapot_check_args(repo_conf: repo.Config, task_conf: task.Config) -> Lis
)
)
res.extend(["--penalty-config", penalty_config])
if task_conf.groups.ignore_submitter:
res.append("--ignore-submitter")
return res

View File

@ -33,6 +33,12 @@ groups.name = ["joj", "run"]
groups.max-count = [1000, 100]
groups.time-period-hour = [24, 1]
# default: false
# when set to true, even if the submitter is different,
# it will still count toward the submission count
# valid for task.toml only
groups.ignore-submitter = false
# list of stages
[[stages]]
# stage name, content in the `[]` set the group