Skip to content

Commit

Permalink
refacotor: leave access private
Browse files Browse the repository at this point in the history
Signed-off-by: Henry Schreiner <[email protected]>
  • Loading branch information
henryiii committed Nov 20, 2024
1 parent 34d05ea commit dc395d1
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
3 changes: 0 additions & 3 deletions src/tox/config/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -123,9 +123,6 @@ def core(self) -> CoreConfigSet:
self._core_set = core
return core

def all_section_configs(self) -> Iterator[tuple[tuple[str, str, str], ConfigSet]]:
yield from self._key_to_conf_set.items()

def get_section_config(
self,
section: Section,
Expand Down
5 changes: 4 additions & 1 deletion src/tox/session/cmd/schema.py
Original file line number Diff line number Diff line change
Expand Up @@ -99,9 +99,12 @@ def gen_schema(state: State) -> int:

properties = _get_schema(core, path="#/properties")

# This accesses plugins that register new sections (like tox-gh)
# Accessing a private member since this is not exposed yet and the
# interface includes the internal storage tuple
sections = {
key: conf
for s, conf in state.conf.all_section_configs()
for s, conf in state.conf._key_to_conf_set.items() # noqa: SLF001
if (key := s[0].split(".")[0]) not in {"env_run_base", "env_pkg_base", "env"}
}
for key, conf in sections.items():
Expand Down

0 comments on commit dc395d1

Please sign in to comment.