Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Refactor systems #660

Merged
merged 12 commits into from
Oct 4, 2023
Prev Previous commit
Next Next commit
Fix docs build
  • Loading branch information
stefsmeets committed Oct 4, 2023
commit ee175e7a689f7f8028e624350558521855d91563
11 changes: 5 additions & 6 deletions docs/gendocs.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,6 @@

import mkdocs_gen_files

from duqtools.ets import Ets6System
from duqtools.jetto import BaseJettoSystem, JettoSystemV210921, JettoSystemV220922
from duqtools.schema import (
ARange,
IDSOperationDim,
Expand All @@ -21,13 +19,14 @@
JettoVariableModel,
LinSpace,
OperationDim,
StatusConfigModel,
SubmitConfigModel,
)
from duqtools.schema._jetto import JsetField, NamelistField
from duqtools.schema.cli import ConfigModel, CreateConfigModel
from duqtools.schema.data_location import DataLocation
from duqtools.system import NoSystem
from duqtools.systems.ets import Ets6System
from duqtools.systems.jetto import BaseJettoSystem, JettoSystemV210921, JettoSystemV220922
from duqtools.systems.models import StatusConfigModel, SubmitConfigModel
from duqtools.systems.no_system import NoSystem

this_dir = Path(__file__).parent
sys.path.append(str(this_dir))
Expand Down Expand Up @@ -59,7 +58,7 @@
Ets6System,
}
schemas = {
f'schema_{obj.__name__}': obj.schema() # type: ignore
f'schema_{obj.__name__}': obj.model_json_schema() # type: ignore
for obj in objects
}
for page in 'index', 'status', 'submit', 'create':
Expand Down
4 changes: 2 additions & 2 deletions src/duqtools/schema/cli.py
Original file line number Diff line number Diff line change
Expand Up @@ -136,5 +136,5 @@ class ConfigModel(BaseModel):
)
from .variables import VariableConfigModel # noqa

CreateConfigModel.update_forward_refs()
ConfigModel.update_forward_refs()
CreateConfigModel.model_rebuild()
ConfigModel.model_rebuild()