move special imports into helper function
This commit is contained in:
parent
e438015ba8
commit
50db5b9192
1 changed files with 3 additions and 2 deletions
|
|
@ -1,8 +1,6 @@
|
|||
import logging
|
||||
import re
|
||||
import uuid
|
||||
|
||||
from natsort import natsorted
|
||||
from sqlmodel import (
|
||||
Field, # pyright: ignore[reportUnknownVariableType]
|
||||
SQLModel,
|
||||
|
|
@ -24,6 +22,9 @@ class Teilchen(TeilchenCreate, table=True):
|
|||
|
||||
|
||||
def make_teilchen_input(text: str) -> TeilchenCreate | None:
|
||||
import re
|
||||
from natsort import natsorted
|
||||
|
||||
if not text:
|
||||
logger.error("Empty text.")
|
||||
return None
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue