MCPcopy Create free account
hub / github.com/cdgriffith/Box / _set_ruamel_comment

Function _set_ruamel_comment

box/comments.py:275–280  ·  view source on GitHub ↗
(out, key, comment, indent)

Source from the content-addressed store, hash-verified

273
274
275def _set_ruamel_comment(out, key, comment, indent):
276 # ruamel quirk: on a CommentedSeq the end of line comment must be set before the before comment
277 if comment.get("eol"):
278 _add_eol_comment(out, key, comment["eol"])
279 if comment.get("before"):
280 out.yaml_set_comment_before_after_key(key, before="\n".join(comment["before"]), indent=indent)
281
282
283def commented_tree(obj, plain, column=0, _seen=None):

Callers 1

commented_treeFunction · 0.85

Calls 2

_add_eol_commentFunction · 0.85
getMethod · 0.80

Tested by

no test coverage detected