Skip to content

Commit

Permalink
tidy up, add comments
Browse files Browse the repository at this point in the history
  • Loading branch information
wxtim committed Aug 17, 2020
1 parent 75e242a commit 9c89175
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 5 deletions.
5 changes: 2 additions & 3 deletions cylc/flow/cfgspec/suite.py
Original file line number Diff line number Diff line change
Expand Up @@ -1260,8 +1260,6 @@ def upg(cfg, descr):
except KeyError:
pass

# cfg = host_to_platform_upgrader(cfg)


def host_to_platform_upgrader(cfg):
"""Upgrade a config with host settings to a config with platform settings
Expand Down Expand Up @@ -1289,7 +1287,7 @@ def host_to_platform_upgrader(cfg):
| +-------------------------------+
| |YES |NO
| | +--------------v-------+
| | | Platforms = |
| | | platform = |
| | | 'localhost' |
| | +----------------------+
| |
Expand All @@ -1316,6 +1314,7 @@ def host_to_platform_upgrader(cfg):
if 'runtime' not in cfg:
return None

# Put the task section and key in a tuple for ease of use later.
forbidden_with_platform = (
('remote', 'host'),
('job', 'batch system'),
Expand Down
3 changes: 1 addition & 2 deletions cylc/flow/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@
from cylc.flow.graph_parser import GraphParser
from cylc.flow.param_expand import NameExpander
from cylc.flow.cfgspec.glbl_cfg import glbl_cfg
from cylc.flow.cfgspec.suite import RawSuiteConfig
from cylc.flow.cfgspec.suite import RawSuiteConfig, host_to_platform_upgrader
from cylc.flow.cycling.loader import (
get_point, get_point_relative, get_interval, get_interval_cls,
get_sequence, get_sequence_cls, init_cyclers, INTEGER_CYCLING_TYPE,
Expand Down Expand Up @@ -305,7 +305,6 @@ def __init__(
self.mem_log("config.py: before inheritance")
self.compute_inheritance()
self.mem_log("config.py: after inheritance")
from cylc.flow.cfgspec.suite import host_to_platform_upgrader
self.cfg = host_to_platform_upgrader(self.cfg)
# self.print_inheritance() # (debugging)

Expand Down

0 comments on commit 9c89175

Please sign in to comment.