docs: def create_sciobj(request, sysmeta_pyxb):
      """Create object file and database entries for a new native locally stored (non-
      proxied) science object.
  
      This method takes a request object and is only called from the views that
      handle:
  
      - MNStorage.create()
      - MNStorage.update()
  
      Various sanity checking is performed. Raises D1 exceptions that are returned
      directly to the client. Adds create event to the event log.
  
      Preconditions:
      - None. This method should check everything.
  
      Postconditions:
      - A new file containing sciobj bytes, and models (database rows) for the newly
      added object.
  
      """
      pid = d1_common.xml.get_req_val(sysmeta_pyxb.identifier)
  
      set_mn_controlled_values(request, sysmeta_pyxb, is_modification=False)
      d1_gmn.app.views.assert_db.is_valid_pid_for_create(pid)
      d1_gmn.app.views.assert_sysmeta.sanity(request, sysmeta_pyxb)
  
      if _is_proxy_sciobj(request):
          sciobj_url = _get_sciobj_proxy_url(request)
          _sanity_check_proxy_url(sciobj_url)
      else:
          sciobj_url = d1_gmn.app.sciobj_store.get_rel_sciobj_file_url_by_pid(pid)
  
      if not _is_proxy_sciobj(request):
          if d1_gmn.app.resource_map.is_resource_map_sysmeta_pyxb(sysmeta_pyxb):
              _create_resource_map(pid, request, sysmeta_pyxb, sciobj_url)
          else:
              _save_sciobj_bytes_from_request(request, pid)
              d1_gmn.app.scimeta.assert_valid(sysmeta_pyxb, pid)
  
      d1_gmn.app.sysmeta.create_or_update(sysmeta_pyxb, sciobj_url)
  
      d1_gmn.app.event_log.create(
          d1_common.xml.get_req_val(sysmeta_pyxb.identifier),
          request,
          timestamp=d1_common.date_time.normalize_datetime_to_utc(
              sysmeta_pyxb.dateUploaded
          ),
      )