code: def roc_auc_score(y_true, y_score):
      """
      This functions is a wrapper to the scikit-learn roc_auc_score function.
      It was created because the scikit version utilizes array of scores and
      may raise a ValueError if there is only one class present in y_true.
      This wrapper returns 0 if y_true has only one class and
      deals with the scores.
      """
      nonzero = np.count_nonzero(y_true)
      if nonzero == 0 or nonzero == len(y_true):
          return 0
  
      scores = [s[True] for s in y_score]
  
      return sk_metrics.roc_auc_score(y_true, scores)
  
imports: from __future__ import annotations
  import collections
  import copy
  import functools
  import importlib
  import inspect
  import pickle
  import platform
  import random
  import numpy
  import pytest
  from sklearn import metrics
  from river import metrics, utils
label_desc: Use image node_id 6 for calling a global function with example usage: roc_auc_score(y_true, y_score) and returns: sk_metrics, int