title: Calling Fragment constructor caused an exception. Navigation Architecture Component
body: <p>I am using navigation architecture component library and my app's starting point is this fragment:</p>
  
  <pre><code>class MainFragment : BaseFragment() {
  
      override fun onCreateView(inflater: LayoutInflater, container: ViewGroup?, savedInstanceState: Bundle?): View? {
          return inflater.inflate(R.layout.fragment_main, container, false)
      }
  
      override fun onCreate(savedInstanceState: Bundle?) {
          super.onCreate(savedInstanceState)
      }
  }
  </code></pre>
  
  <p>Which inherits from an abstract class which is <code>BaseFragment</code>:</p>
  
  <pre><code>abstract class BaseFragment : Fragment() {
  
  }
  </code></pre>
  
  <p>When I run my app I get: </p>
  
  <pre><code> Unable to instantiate fragment io.example.MainFragment: calling Fragment constructor caused an exception
  </code></pre>
  
  <p>But this does not happen if <code>MainFragment</code> extends <code>Fragment</code> instead of <code>BaseFragment</code>. What is the reason? Does this have something to do with how the Navigation Architecture Component works?</p>