]> matita.cs.unibo.it Git - helm.git/blobdiff - helm/searchEngine/searchEngine.ml
removed spurious dependency on Dbi_mysql
[helm.git] / helm / searchEngine / searchEngine.ml
index 111c9b804400d4f555c105b3bbfcd82dc0223258..87546b1ffdff61fbdd0a73e93a859aa087427674 100644 (file)
@@ -25,8 +25,6 @@
 
 open Printf
 
-module DB = Dbi_mysql
-
 let debug = true
 let debug_print s = if debug then prerr_endline s
 let _ = Http_common.debug := false
@@ -37,6 +35,7 @@ exception Invalid_action of string  (* invalid action for "/search" method *)
 
 let daemon_name = "Moogle"
 let configuration_file = "/projects/helm/etc/moogle.conf.xml" 
+(*let configuration_file = "searchEngine.conf.xml" *)
 
 let placeholders = [
   "EXPRESSION"; "ACTION"; "ADVANCED"; "ADVANCED_CHECKED"; "SIMPLE_CHECKED";
@@ -273,7 +272,7 @@ let exec_action dbd (req: Http_types.request) outchan =
     match
       Disambiguate'.disambiguate_term dbd context metasenv ast id_to_uris
     with
-    | [id_to_uris,metasenv,term] -> id_to_uris,metasenv,term
+    | [id_to_uris,metasenv,term,_] -> id_to_uris,metasenv,term
     | _ -> assert false
   in
   let uris =
@@ -359,7 +358,7 @@ let callback dbd (req: Http_types.request) outchan =
   | Chat_unfinished -> ()
   | Http_types.Param_not_found attr_name ->
       bad_request (sprintf "Parameter '%s' is missing" attr_name) outchan
-  | CicTextualParser2.Parse_error msg ->
+  | CicTextualParser2.Parse_error (_, msg) ->
       send_results (`Error (MooglePp.pp_error "Parse_error" msg)) req outchan
   | Unbound_identifier id ->
       send_results (`Error (MooglePp.pp_error "Unbound identifier" id)) req