code: def test_from_params_does_not_pass_extras_to_non_from_params_registered_class(
      self,
  ):
      class Bar(Registrable):
          pass
  
      class Baz:
          def __init__(self, a: int, c: Dict[str, str] = None) -> None:
              self.a = a
              self.c = c
  
      @Bar.register("foo")
      class Foo(Baz):
          def __init__(self, a: int, b: str = None, **kwargs) -> None:
              super().__init__(a, **kwargs)
              self.b = b
  
      foo = Bar.from_params(Params({"type": "foo", "a": 2, "b": "hi"}))
      assert foo.a == 2
      assert foo.b == "hi"
      assert foo.c is None
  
      foo = Bar.from_params(
          params=Params(
              {"type": "foo", "a": 2, "b": "hi", "c": {"2": "3"}}
          ),
          extra="4",
      )
      assert foo.a == 2
      assert foo.b == "hi"
      assert foo.c == {"2": "3"}
  
imports: from typing import Dict, Iterable, List, Mapping, Optional, Set, Tuple, Union
  import pytest
  import torch
  from allennlp.common import Lazy, Params, Registrable
  from allennlp.common.from_params import FromParams, takes_arg, remove_optional, create_kwargs
  from allennlp.common.testing import AllenNlpTestCase
  from allennlp.data import DataLoader, DatasetReader, Tokenizer
  from allennlp.models import Model
  from allennlp.models.archival import load_archive
  from allennlp.common.checks import ConfigurationError
label_desc: Use image node_id 37 for calling the TestFromParams obj's underlying member method code with example usage: obj.test_from_params_does_not_pass_extras_to_non_from_params_registered_class() without return types