cfg.puzzle.random_pepper -> cfg.puzzle.random_seed
This commit is contained in:
parent
0337c659a2
commit
d5d99caeb2
3 changed files with 3 additions and 3 deletions
|
@ -36,7 +36,7 @@ class Puzzle(BaseModel):
|
||||||
calendar: str = "default.toml"
|
calendar: str = "default.toml"
|
||||||
|
|
||||||
# Serverseitiger zusätzlicher "random" seed
|
# Serverseitiger zusätzlicher "random" seed
|
||||||
random_pepper: str = ""
|
random_seed: str = ""
|
||||||
|
|
||||||
|
|
||||||
class Config(BaseModel):
|
class Config(BaseModel):
|
||||||
|
|
|
@ -9,7 +9,7 @@ class Random(random.Random):
|
||||||
@classmethod
|
@classmethod
|
||||||
async def get(cls, bonus_salt: Any = "") -> Self:
|
async def get(cls, bonus_salt: Any = "") -> Self:
|
||||||
cfg = await get_config()
|
cfg = await get_config()
|
||||||
return cls(f"{cfg.puzzle.solution}{cfg.puzzle.random_pepper}{bonus_salt}")
|
return cls(f"{cfg.puzzle.solution}{cfg.puzzle.random_seed}{bonus_salt}")
|
||||||
|
|
||||||
|
|
||||||
async def shuffle(seq: Sequence, rnd: random.Random | None = None) -> list:
|
async def shuffle(seq: Sequence, rnd: random.Random | None = None) -> list:
|
||||||
|
|
|
@ -69,7 +69,7 @@ async def get_private_config(
|
||||||
begin=date.today(),
|
begin=date.today(),
|
||||||
end=date.today(),
|
end=date.today(),
|
||||||
closing=date.today(),
|
closing=date.today(),
|
||||||
seed=cfg.puzzle.random_pepper,
|
seed=cfg.puzzle.random_seed,
|
||||||
),
|
),
|
||||||
calendar=PrivateCalendar(
|
calendar=PrivateCalendar(
|
||||||
config_file=cfg.puzzle.calendar,
|
config_file=cfg.puzzle.calendar,
|
||||||
|
|
Loading…
Reference in a new issue