]> matita.cs.unibo.it Git - helm.git/blobdiff - matitaB/components/ng_library/nCicLibrary.ml
Matitaweb: Fixed netplex.conf (which was changed by mistake in the previous commit).
[helm.git] / matitaB / components / ng_library / nCicLibrary.ml
index b775bff001b2e80caab3fb7f8c8785fafaf1c7ec..201b5ac082b8a425726a4859db1c6c2f371f9a62 100644 (file)
@@ -56,7 +56,7 @@ let ng_path_of_baseuri ?(no_suffix=false) user baseuri =
  let path = String.sub uri 4 (String.length uri - 4) in
  let path = match user with
  | Some u -> "/" ^ u ^ path
- | _ -> path
+ | _ -> prerr_endline "WARNING: ng_path_of_baseuri called without a uid"; path
  in
  let path = Helm_registry.get "matita.basedir" ^ path in
  let dirname = Filename.dirname path in
@@ -156,6 +156,7 @@ type db = {
 
 class type g_status =
   object
+    inherit NCicEnvironment.g_status
     method lib_db : db
   end
 
@@ -175,7 +176,7 @@ class virtual status uid =
   method set_timestamp v = {< timestamp = v >}
   method set_lib_db v = {< lib_db = v >}
   method set_lib_status : 's.#g_status as 's -> 'self
-   = fun o -> {< lib_db = o#lib_db >}  
+   = fun o -> {< lib_db = o#lib_db >}#set_env_status o
  end
 
 let reset_timestamp st =
@@ -360,7 +361,9 @@ let resolve st name =
    (fun (_,name',nref) -> if name'=name then Some nref else None)
    (!(st#lib_db.local_aliases) @ get_global_aliases ())
  with
-  Not_found -> raise (NCicEnvironment.ObjectNotFound (lazy name))
+  Not_found -> 
+   (prerr_endline ("can't resolve object " ^ name);
+    raise (NCicEnvironment.ObjectNotFound (lazy name)))
 ;;
 
 let aliases_of st uri =
@@ -427,7 +430,8 @@ let get_obj status u =
  with Not_found ->*)
   try fetch_obj (status#user) status u
   with Sys_error _ ->
-   raise (NCicEnvironment.ObjectNotFound (lazy (NUri.string_of_uri u)))
+   (prerr_endline ("can't fetch object " ^ NUri.string_of_uri u);
+   raise (NCicEnvironment.ObjectNotFound (lazy (NUri.string_of_uri u))))
 ;;
 
 NCicEnvironment.set_get_obj