code: def black_invariant(text, chars=None):
      """Remove characters that may be changed when reformatting the text with black"""
      if chars is None:
          chars = [" ", "\t", "\n", ",", "'", '"', "(", ")", "\\"]
  
      for char in chars:
          text = text.replace(char, "")
      return text
  
file_path: jupytext/src/jupytext/combine.py
imports: import re
  from copy import copy
  from nbformat import NotebookNode
  from .cell_metadata import _IGNORE_CELL_METADATA
  from .formats import long_form_one_format
  from .header import _DEFAULT_NOTEBOOK_METADATA
  from .metadata_filter import restore_filtered_metadata
label_desc: Use image node_id 1 for calling a global function with example usage: black_invariant(text, chars) and returns: text