Adaptive Time Stepping package error loading from toml
Los mantenedores suelen responder en 2 días
Nadie ha tomado este issue todavía.
Evaluación
- Dificultad
- 2/5
- Tiempo estimado
- 1-3 horas
- Aptitud para principiantes
- 72/100
Línea de trabajo
El fallo está en imod/mf6/simulation.py en Modflow6Simulation.from_file, donde la clave de sección de TOML se busca en un mapeo classes y falta AdaptiveTimeStepping. Reprodúcelo volcando un modelo que contiene un paquete ats y cargándolo de nuevo con from_file, y luego inspecciona cómo se registran y reconstruyen otros paquetes desde TOML. Hecho significa que un TOML que contiene [AdaptiveTimeStepping] se carga correctamente y las pruebas de simulación relevantes siguen pasando.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
Bug description
imod.mf6.Modflow6Simulation.from_file(model_toml) fails when an ats (adaptive time stepping) package is present in the model, that is written to netcdf files using model.dump('folder/to/dump')
Steps to reproduce
Error message:
KeyError Traceback (most recent call last)
Cell In[4], line 1
----> 1 model = imod.mf6.Modflow6Simulation.from_file(model_toml)
File c:\model_builder.pixi\envs\default\Lib\site-packages\imod\logging\logging_decorators.py:32, in standard_log_decorator..decorator..wrapper(*args, **kwargs)
29 logger.log(loglevel=start_level, message=start_message, additional_depth=2)
31 # run function
---> 32 return_value = fun(*args, **kwargs)
33 end_time = time()
35 # anounce end of function
File c:\model_builder.pixi\envs\default\Lib\site-packages\imod\mf6\simulation.py:1126, in Modflow6Simulation.from_file(toml_path)
1124 for key, entry in toml_content.items():
1125 if key not in ["gwtgwf_exchanges", "split_exchanges"]:
-> 1126 item_cls = classes[key]
1127 for name, filename in entry.items():
1128 path = toml_path.parent / filename
KeyError: 'AdaptiveTimeStepping'
Desktop (please complete the following information):
- iMOD Python Version '1.0.0.post1'
Additional context
In this case I want to load an existing model, use the spatial information and make additional changes for scenario development. This is now not automatically possible, as I can not simply load the data using the toml. The manual workaround is to remove the [AdaptiveTimeStepping] section from the toml manually, so i can at least load the other packages.
- Lenguaje dominante
- Python
- Estrellas
- 41
- Forks
- 10
- Merge medio
- 2 d 23 h
- PR fusionados (30 d)
- 15
Preparar el entorno
- Sin Dockerfile ni archivo de Docker Compose
- Tiene una plantilla de pull request
- Sin guía de contribución
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de Deltares/imod-python
-
backwards_compatibility bug Deltares
Dificultad 2/5 1-3 horas Aptitud para principiantes 68/100
Deltares/imod-python#1940 · 1 comentario ·
Los mantenedores suelen responder en 2 días
-
Deltares enhancement good first issue
Dificultad 2/5 1-3 horas Aptitud para principiantes 74/100
Deltares/imod-python#1843 ·
Los mantenedores suelen responder en 2 días
-
documentation
Dificultad 1/5 Menos de una hora Aptitud para principiantes 68/100
Deltares/imod-python#1684 ·
Los mantenedores suelen responder en 2 días
-
[Bug] - resample_timeseries: output shifted by one period when well records exist before the first timePosiblemente ocupada @ClaireDons la tomó hoy. Abiertobug
Deltares/imod-python#1952 · 1 comentario · 1 asignado ·
Los mantenedores suelen responder en 2 días
-
backwards_compatibility bug Deltares
Dificultad 3/5 Medio día Aptitud para principiantes 50/100
Deltares/imod-python#1939 · 1 comentario ·
Los mantenedores suelen responder en 2 días
Todos los issues de Deltares/imod-python
Issues similares
-
enhancement help wanted
Dificultad 2/5 1-3 horas Aptitud para principiantes 76/100
Git-Hospital/githealthcheck#61 ·
Los mantenedores suelen responder en 1 día
-
changelog investigate
Dificultad 2/5 1-3 horas Aptitud para principiantes 67/100
ramnes/notion-sdk-py#433 ·
-
Partial method descriptors raise on class accessPosiblemente ocupada @Gambit-Checkmate la tomó hoy. Abierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 76/100
Los mantenedores suelen responder en 19 días
-
docs pkg:core
Dificultad 1/5 Menos de una hora Aptitud para principiantes 84/100
pydantic/pydantic-ai#11929 ·
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
intake/intake-esm#789 ·