You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Refactor titles of the structured configs documentation (omry#790)
The objective is to make it easier to understand that all content in the
`structured_config.rst` file is related to structured configs, when
looking at the left navigation pane. More precisely, the main changes
are that:
- The "Lists" and "Dicts" sections are now moved inside the "Structured
configs" main section (getting rid of the intermediate "Containers"
section to reduce nesting)
- The "Misc" section is also moved inside the "Structured Configs" main
section (and is also renamed to give a better idea of what's inside
it, now that its detailed content isn't shown anymore in the left
navigation pane)
- Finally the "Merging with other configs" section is also moved inside
the "Structured Configs" main section so as to make it clear that it
is related to structured configs.
Fields assigned the constant ``MISSING`` do not have a value and the value must be set prior to accessing the field.
299
294
Otherwise a ``MissingMandatoryValue`` exception is raised.
@@ -307,7 +302,7 @@ Otherwise a ``MissingMandatoryValue`` exception is raised.
307
302
308
303
309
304
Optional fields
310
-
^^^^^^^^^^^^^^^
305
+
+++++++++++++++
311
306
312
307
.. doctest::
313
308
@@ -321,7 +316,7 @@ Optional fields
321
316
322
317
323
318
Interpolations
324
-
^^^^^^^^^^^^^^
319
+
++++++++++++++
325
320
326
321
:ref:`interpolation` works normally with Structured configs, but static type checkers may object to you assigning a string to another type.
327
322
To work around this, use the special functions ``omegaconf.SI`` and ``omegaconf.II`` described below.
@@ -380,8 +375,8 @@ Note however that this validation step is currently skipped for container node i
380
375
>>> assert cfg.some_dict ==0# type mismatch, but no error
381
376
382
377
383
-
Frozen
384
-
^^^^^^
378
+
Frozen classes
379
+
++++++++++++++
385
380
386
381
Frozen dataclasses and attr classes are supported via OmegaConf :ref:`read-only-flag`, which makes the entire config node and all if it's child nodes read-only.
387
382
@@ -404,7 +399,7 @@ The read-only flag is recursive:
404
399
... conf.list[0] =20
405
400
406
401
Merging with other configs
407
-
----------------------------
402
+
^^^^^^^^^^^^^^^^^^^^^^^^^^
408
403
409
404
Once an OmegaConf object is created, it can be merged with others regardless of its source.
410
405
OmegaConf configs created from Structured configs contains type information that is enforced at runtime.
0 commit comments