code: def columns_listed_in_columns_to_encode_should_not_be_ignored_in_x():
      ds = load_dataset(incl_test=True)
      categoricals = list(
          {n for n, t in ds.train.types.items() if t == "enum"}
          - {ds.target}
      )
      assert len(categoricals) > 3
      ignored = categoricals[0]
      two_inter = [ignored, categoricals[1]]
      te = H2OTargetEncoderEstimator(columns_to_encode=[two_inter])
      x = list(set(ds.train.names) - {ignored})
      try:
          te.train(x=x, y=ds.target, training_frame=ds.train)
      except Exception as e:
          assert "Column `{}` from interaction [{}] is not categorical or is missing from the training frame".format(
              ignored, ", ".join(two_inter)
          ) in str(
              e
          )
  
file_path: h2o-3/h2o-py/tests/testdir_algos/targetencoder/pyunit_targetencoder_training.py
imports: import os
  import sys
  import h2o
  from h2o.estimators import H2OTargetEncoderEstimator
  from h2o.exceptions import H2OResponseError
  from tests import pyunit_utils
label_desc: Use image node_id 9 for calling a global function with example usage: columns_listed_in_columns_to_encode_should_not_be_ignored_in_x() without return types