[Zorba-coders] [Merge] lp:~danielturcanu/zorba/csv_conv_module into lp:zorba/data-converters-module
The proposal to merge lp:~danielturcanu/zorba/csv_conv_module into lp:zorba/data-converters-module has been updated. Commit Message changed to: Changed type in csv options from xs:string to xs:boolean For more details, see: https://code.launchpad.net/~danielturcanu/zorba/csv_conv_module/+merge/92072 -- https://code.launchpad.net/~danielturcanu/zorba/csv_conv_module/+merge/92072 Your team Zorba Coders is requested to review the proposed merge of lp:~danielturcanu/zorba/csv_conv_module into lp:zorba/data-converters-module. -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
[Zorba-coders] [Merge] lp:~danielturcanu/zorba/csv_conv_module into lp:zorba/data-converters-module
Daniel Turcanu has proposed merging lp:~danielturcanu/zorba/csv_conv_module into lp:zorba/data-converters-module. Requested reviews: Zorba Coders (zorba-coders) Cezar Andrei (cezar-andrei) Related bugs: Bug #925133 in Zorba: "replace string restriction with xs:boolean in csv-options.xsd" https://bugs.launchpad.net/zorba/+bug/925133 For more details, see: https://code.launchpad.net/~danielturcanu/zorba/csv_conv_module/+merge/92072 Changed type in csv options from xs:string to xs:boolean -- https://code.launchpad.net/~danielturcanu/zorba/csv_conv_module/+merge/92072 Your team Zorba Coders is requested to review the proposed merge of lp:~danielturcanu/zorba/csv_conv_module into lp:zorba/data-converters-module. === modified file 'src/com/zorba-xquery/www/modules/converters/csv-options.xsd' --- src/com/zorba-xquery/www/modules/converters/csv-options.xsd 2011-08-17 23:28:43 + +++ src/com/zorba-xquery/www/modules/converters/csv-options.xsd 2012-02-08 16:49:52 + @@ -35,20 +35,8 @@ - - - - - - - - - - - - - - + + -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
[Zorba-coders] [Bug 927630] [NEW] zorba/index/numbers fails in release and passes in debug
Public bug reported: Test zorba/index/numbers fails in release and passes in debug mode, although it seems to me that it should be the other way around (the expected result seems wrong). This is for Windows and linux. ** Affects: zorba Importance: Undecided Assignee: Markos Zaharioudakis (markos-za) Status: New ** Changed in: zorba Assignee: (unassigned) => Markos Zaharioudakis (markos-za) -- You received this bug notification because you are a member of Zorba Coders, which is the registrant for Zorba. https://bugs.launchpad.net/bugs/927630 Title: zorba/index/numbers fails in release and passes in debug Status in Zorba - The XQuery Processor: New Bug description: Test zorba/index/numbers fails in release and passes in debug mode, although it seems to me that it should be the other way around (the expected result seems wrong). This is for Windows and linux. To manage notifications about this bug go to: https://bugs.launchpad.net/zorba/+bug/927630/+subscriptions -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
[Zorba-coders] [Bug 925133] Re: replace string restriction with xs:boolean in csv-options.xsd
** Branch linked: lp:~danielturcanu/zorba/csv_conv_module -- You received this bug notification because you are a member of Zorba Coders, which is the registrant for Zorba. https://bugs.launchpad.net/bugs/925133 Title: replace string restriction with xs:boolean in csv-options.xsd Status in Zorba - The XQuery Processor: New Bug description: csv-options.xsd contains these attribute definitions: What is the reason it was defined using a string restriction and not xs:boolean? Like this: To manage notifications about this bug go to: https://bugs.launchpad.net/zorba/+bug/925133/+subscriptions -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
[Zorba-coders] [Merge] lp:~danielturcanu/zorba/csv_conv_module into lp:zorba/data-converters-module
The proposal to merge lp:~danielturcanu/zorba/csv_conv_module into lp:zorba/data-converters-module has been updated. Status: Needs review => Approved For more details, see: https://code.launchpad.net/~danielturcanu/zorba/csv_conv_module/+merge/91337 -- https://code.launchpad.net/~danielturcanu/zorba/csv_conv_module/+merge/91337 Your team Zorba Coders is requested to review the proposed merge of lp:~danielturcanu/zorba/csv_conv_module into lp:zorba/data-converters-module. -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
[Zorba-coders] [Merge] lp:~danielturcanu/zorba/csv_conv_module into lp:zorba/data-converters-module
Daniel Turcanu has proposed merging lp:~danielturcanu/zorba/csv_conv_module into lp:zorba/data-converters-module. Requested reviews: Cezar Andrei (cezar-andrei) Zorba Coders (zorba-coders) Related bugs: Bug #925133 in Zorba: "replace string restriction with xs:boolean in csv-options.xsd" https://bugs.launchpad.net/zorba/+bug/925133 For more details, see: https://code.launchpad.net/~danielturcanu/zorba/csv_conv_module/+merge/91337 Changed type in csv options from xs:string to xs:boolean -- https://code.launchpad.net/~danielturcanu/zorba/csv_conv_module/+merge/91337 Your team Zorba Coders is requested to review the proposed merge of lp:~danielturcanu/zorba/csv_conv_module into lp:zorba/data-converters-module. === modified file 'src/com/zorba-xquery/www/modules/converters/csv-options.xsd' --- src/com/zorba-xquery/www/modules/converters/csv-options.xsd 2011-08-17 23:28:43 + +++ src/com/zorba-xquery/www/modules/converters/csv-options.xsd 2012-02-02 19:36:21 + @@ -35,20 +35,8 @@ - - - - - - - - - - - - - - + + -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
[Zorba-coders] [Merge] lp:~danielturcanu/zorba/csv_conv_module into lp:zorba/data-converters-module
Daniel Turcanu has proposed merging lp:~danielturcanu/zorba/csv_conv_module into lp:zorba/data-converters-module. Requested reviews: Cezar Andrei (cezar-andrei) Daniel Turcanu (danielturcanu) For more details, see: https://code.launchpad.net/~danielturcanu/zorba/csv_conv_module/+merge/91335 Changed type in csvOptions from xs:string to xs:boolean. -- https://code.launchpad.net/~danielturcanu/zorba/csv_conv_module/+merge/91335 Your team Zorba Coders is subscribed to branch lp:zorba/data-converters-module. === modified file 'src/com/zorba-xquery/www/modules/converters/CMakeLists.txt' --- src/com/zorba-xquery/www/modules/converters/CMakeLists.txt 2012-01-23 19:28:30 + +++ src/com/zorba-xquery/www/modules/converters/CMakeLists.txt 2012-02-02 19:16:18 + @@ -40,6 +40,38 @@ ENDIF (ZORBA_SUPPRESS_LIBTIDY) MESSAGE (STATUS "") +<<<<<<< TREE +=== + +# +# Jansson +# +IF (ZORBA_SUPPRESS_JANSSON) + MESSAGE (STATUS "ZORBA_SUPPRESS_JANSSON is true - not searching for Jansson.") +ELSE (ZORBA_SUPPRESS_JANSSON) + + MESSAGE (STATUS "Looking for Jansson") + FIND_PACKAGE (Jansson) + + IF (Jansson_FOUND) +MESSAGE (STATUS "Found Jansson library -- " ${Jansson_LIBRARIES}) + +SET (JSON_LINK_LIBRARIES ${Jansson_LIBRARIES}) +INCLUDE_DIRECTORIES (${Jansson_INCLUDE_DIRS}) +INCLUDE_DIRECTORIES ("json.xq.src") +DECLARE_ZORBA_SCHEMA (FILE "json-options.xsd" + URI "http://www.zorba-xquery.com/modules/converters/json-options";) +DECLARE_ZORBA_MODULE (URI "http://www.zorba-xquery.com/modules/converters/json"; VERSION 1.0 FILE "json.xq" LINK_LIBRARIES "${Jansson_LIBRARIES}") +ADD_TEST_DIRECTORY ("${PROJECT_SOURCE_DIR}/test_json") + + ELSE (Jansson_FOUND) +MESSAGE (STATUS "Jansson library not found -- if you want to use Json functionality please set Jansson_INCLUDE_DIRS and Jansson_LIBRARIES cmake parameters.") + ENDIF (Jansson_FOUND) +ENDIF (ZORBA_SUPPRESS_JANSSON) +MESSAGE (STATUS "") + + +>>>>>>> MERGE-SOURCE # csv DECLARE_ZORBA_SCHEMA (FILE csv-options.xsd URI "http://www.zorba-xquery.com/modules/converters/csv-options";) @@ -59,7 +91,10 @@ ADD_TEST ("streamable_string_streambuf" StreambufUnitTests "streambuftest") ADD_TEST_DIRECTORY("${PROJECT_SOURCE_DIR}/test") +<<<<<<< TREE IF(ZORBA_NO_UNICODE) SET_TESTS_PROPERTIES(zorba_data-converters_module/converters/csv/csv_parse_utf8_11.xq PROPERTIES WILL_FAIL TRUE) ENDIF(ZORBA_NO_UNICODE) +=== +>>>>>>> MERGE-SOURCE === modified file 'src/com/zorba-xquery/www/modules/converters/csv-options.xsd' --- src/com/zorba-xquery/www/modules/converters/csv-options.xsd 2011-08-17 23:28:43 + +++ src/com/zorba-xquery/www/modules/converters/csv-options.xsd 2012-02-02 19:16:18 + @@ -35,20 +35,8 @@ - - - - - - - - - - - - - - + + === modified file 'test_html/Queries/converters/html/link_crawler2.xq2' --- test_html/Queries/converters/html/link_crawler2.xq2 2011-10-06 07:40:17 + +++ test_html/Queries/converters/html/link_crawler2.xq2 2012-02-02 19:16:18 + @@ -18,6 +18,7 @@ import module namespace map = "http://www.zorba-xquery.com/modules/store/data-structures/unordered-map";; import module namespace html = "http://www.zorba-xquery.com/modules/converters/html";; import module namespace parse-xml = "http://www.zorba-xquery.com/modules/xml";; +import module namespace file = "http://expath.org/ns/file";; declare namespace ann = "http://www.zorba-xquery.com/annotations";; declare namespace xhtml="http://www.w3.org/1999/xhtml";; @@ -25,16 +26,23 @@ declare namespace err="http://www.w3.org/2005/xqt-errors";; declare namespace httpsch = "http://expath.org/ns/http-client";; -declare variable $top-uri as xs:string := "http://www.zorba-xquery.com/site2/html/index.html";; -declare variable $uri-host as xs:string := "http://www.zorba-xquery.com/site2/";; - - -declare variable $supported-media-types as xs:string+ := ("text/xml", "application/xml", "text/xml-external-parsed-entity", "application/xml-external-parsed-entity", - "application/atom+xml", "text/html"); - - -declare variable $local:processed-internal-links:=xs:QName("processed-internal-links"); -declare variable $local:processed-external-links :=xs:QName("processed-extern
[Zorba-coders] [Bug 924205] Re: test converters/base64/binaryReadWrite.xq fails with plan serializer
** Branch linked: lp:~zorba-coders/zorba/plan-serializer -- You received this bug notification because you are a member of Zorba Coders, which is the registrant for Zorba. https://bugs.launchpad.net/bugs/924205 Title: test converters/base64/binaryReadWrite.xq fails with plan serializer Status in Zorba - The XQuery Processor: New Bug description: The test "converters/base64/binaryReadWrite.xq" fails with plan serializer in debug mode. In release mode on Win32 it seems to work. There is an assert in materialize_clause::clone() . The stack for the assert is: zorba_simplestore.dll!zorba::assertion_failed(const char * condition, const char * file, int line) Line 66 + 0x4c bytesC++ > zorba_simplestore.dll!zorba::materialize_clause::clone(std::map,std::less,std::allocator > > > & subst) Line 806 + 0x1d bytes C++ zorba_simplestore.dll!zorba::flwor_expr::clone(std::map,std::less,std::allocator > > > & subst) Line 1225 + 0x30 bytes C++ zorba_simplestore.dll!zorba::InlineFunctions::rewritePost(zorba::expr * node, zorba::RewriterContext & rCtx) Line 1083 + 0x3a bytesC++ zorba_simplestore.dll!zorba::PrePostRewriteRule::apply(zorba::RewriterContext & rCtx, zorba::expr * curExpr, bool & modified) Line 60 + 0x1e bytes C++ zorba_simplestore.dll!zorba::PrePostRewriteRule::apply(zorba::RewriterContext & rCtx, zorba::expr * curExpr, bool & modified) Line 51 + 0x31 bytes C++ zorba_simplestore.dll!zorba::PrePostRewriteRule::apply(zorba::RewriterContext & rCtx, zorba::expr * curExpr, bool & modified) Line 51 + 0x31 bytes C++ zorba_simplestore.dll!zorba::PrePostRewriteRule::apply(zorba::RewriterContext & rCtx, zorba::expr * curExpr, bool & modified) Line 51 + 0x31 bytes C++ zorba_simplestore.dll!zorba::PrePostRewriteRule::apply(zorba::RewriterContext & rCtx, zorba::expr * curExpr, bool & modified) Line 51 + 0x31 bytes C++ zorba_simplestore.dll!zorba::PrePostRewriteRule::apply(zorba::RewriterContext & rCtx, zorba::expr * curExpr, bool & modified) Line 51 + 0x31 bytes C++ zorba_simplestore.dll!zorba::RuleMajorDriver::rewrite(zorba::RewriterContext & rCtx) Line 61 + 0x55 bytes C++ zorba_simplestore.dll!zorba::DefaultOptimizer::rewrite(zorba::RewriterContext & rCtx) Line 83 + 0xf bytes C++ zorba_simplestore.dll!zorba::user_function::getPlan(zorba::CompilerCB * ccb, unsigned int & planStateSize) Line 388 + 0x4d bytes C++ zorba_simplestore.dll!zorba::user_function::prepare_for_serialize(zorba::CompilerCB * compilerCB) Line 102 + 0x14 bytesC++ zorba_simplestore.dll!zorba::CompilerCB::prepare_for_serialize() Line 182 C++ zorba_simplestore.dll!zorba::XQueryImpl::serialize(zorba::serialization::Archiver & ar) Line 200 C++ zorba_simplestore.dll!zorba::XQueryImpl::saveExecutionPlan(std::basic_ostream > & os, Zorba_binary_plan_format_t archive_format, Zorba_save_plan_options_t save_options) Line 922 C++ To manage notifications about this bug go to: https://bugs.launchpad.net/zorba/+bug/924205/+subscriptions -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
[Zorba-coders] [Bug 924177] Re: test converters/base64/binaryReadWrite.xq enters in infinite loop
With the latest trunk, it's no more entering in infinite loop ** Changed in: zorba Status: New => Invalid -- You received this bug notification because you are a member of Zorba Coders, which is the registrant for Zorba. https://bugs.launchpad.net/bugs/924177 Title: test converters/base64/binaryReadWrite.xq enters in infinite loop Status in Zorba - The XQuery Processor: Invalid Bug description: When using plan serializer, the test "converters/base64/binaryReadWrite.xq" enters in infinite loop", probably when preparing the plan for the UserFunctions. I tested that with the plan_serializer branch. To manage notifications about this bug go to: https://bugs.launchpad.net/zorba/+bug/924177/+subscriptions -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
[Zorba-coders] [Bug 924205] [NEW] test converters/base64/binaryReadWrite.xq fails with plan serializer
Public bug reported: The test "converters/base64/binaryReadWrite.xq" fails with plan serializer in debug mode. In release mode on Win32 it seems to work. There is an assert in materialize_clause::clone() . The stack for the assert is: zorba_simplestore.dll!zorba::assertion_failed(const char * condition, const char * file, int line) Line 66 + 0x4c bytesC++ > > zorba_simplestore.dll!zorba::materialize_clause::clone(std::map const *,zorba::rchandle,std::less *>,std::allocator const,zorba::rchandle > > > & subst) Line 806 + 0x1d bytes C++ zorba_simplestore.dll!zorba::flwor_expr::clone(std::map,std::less,std::allocator > > > & subst) Line 1225 + 0x30 bytes C++ zorba_simplestore.dll!zorba::InlineFunctions::rewritePost(zorba::expr * node, zorba::RewriterContext & rCtx) Line 1083 + 0x3a bytesC++ zorba_simplestore.dll!zorba::PrePostRewriteRule::apply(zorba::RewriterContext & rCtx, zorba::expr * curExpr, bool & modified) Line 60 + 0x1e bytes C++ zorba_simplestore.dll!zorba::PrePostRewriteRule::apply(zorba::RewriterContext & rCtx, zorba::expr * curExpr, bool & modified) Line 51 + 0x31 bytes C++ zorba_simplestore.dll!zorba::PrePostRewriteRule::apply(zorba::RewriterContext & rCtx, zorba::expr * curExpr, bool & modified) Line 51 + 0x31 bytes C++ zorba_simplestore.dll!zorba::PrePostRewriteRule::apply(zorba::RewriterContext & rCtx, zorba::expr * curExpr, bool & modified) Line 51 + 0x31 bytes C++ zorba_simplestore.dll!zorba::PrePostRewriteRule::apply(zorba::RewriterContext & rCtx, zorba::expr * curExpr, bool & modified) Line 51 + 0x31 bytes C++ zorba_simplestore.dll!zorba::PrePostRewriteRule::apply(zorba::RewriterContext & rCtx, zorba::expr * curExpr, bool & modified) Line 51 + 0x31 bytes C++ zorba_simplestore.dll!zorba::RuleMajorDriver::rewrite(zorba::RewriterContext & rCtx) Line 61 + 0x55 bytes C++ zorba_simplestore.dll!zorba::DefaultOptimizer::rewrite(zorba::RewriterContext & rCtx) Line 83 + 0xf bytes C++ zorba_simplestore.dll!zorba::user_function::getPlan(zorba::CompilerCB * ccb, unsigned int & planStateSize) Line 388 + 0x4d bytes C++ zorba_simplestore.dll!zorba::user_function::prepare_for_serialize(zorba::CompilerCB * compilerCB) Line 102 + 0x14 bytesC++ zorba_simplestore.dll!zorba::CompilerCB::prepare_for_serialize() Line 182 C++ zorba_simplestore.dll!zorba::XQueryImpl::serialize(zorba::serialization::Archiver & ar) Line 200 C++ zorba_simplestore.dll!zorba::XQueryImpl::saveExecutionPlan(std::basic_ostream > & os, Zorba_binary_plan_format_t archive_format, Zorba_save_plan_options_t save_options) Line 922 C++ ** Affects: zorba Importance: Undecided Assignee: Markos Zaharioudakis (markos-za) Status: New ** Changed in: zorba Assignee: (unassigned) => Markos Zaharioudakis (markos-za) -- You received this bug notification because you are a member of Zorba Coders, which is the registrant for Zorba. https://bugs.launchpad.net/bugs/924205 Title: test converters/base64/binaryReadWrite.xq fails with plan serializer Status in Zorba - The XQuery Processor: New Bug description: The test "converters/base64/binaryReadWrite.xq" fails with plan serializer in debug mode. In release mode on Win32 it seems to work. There is an assert in materialize_clause::clone() . The stack for the assert is: zorba_simplestore.dll!zorba::assertion_failed(const char * condition, const char * file, int line) Line 66 + 0x4c bytesC++ > zorba_simplestore.dll!zorba::materialize_clause::clone(std::map,std::less,std::allocator > > > & subst) Line 806 + 0x1d bytes C++ zorba_simplestore.dll!zorba::flwor_expr::clone(std::map,std::less,std::allocator > > > & subst) Line 1225 + 0x30 bytes C++ zorba_simplestore.dll!zorba::InlineFunctions::rewritePost(zorba::expr * node, zorba::RewriterContext & rCtx) Line 1083 + 0x3a bytesC++ zorba_simplestore.dll!zorba::PrePostRewriteRule::apply(zorba::RewriterContext & rCtx, zorba::expr * curExpr, bool & modified) Line 60 + 0x1e bytes C++ zorba_simplestore.dll!zorba::PrePostRewriteRule::apply(zorba::RewriterContext & rCtx, zorba::expr * curExpr, bool & modified) Line 51 + 0x31 bytes C++ zorba_simplestore.dll!zorba::PrePostRewriteRule::apply(zorba::RewriterContext & rCtx, zorba::expr * curExpr, bool & modified) Line 51 + 0x31 bytes C++ zorba_simplestore.dll!zorba::PrePostRewriteRule::apply(zorba::RewriterContext & rCtx, zorba::expr * curExpr, bool & modified) Line 51 + 0x31 bytes C++ zorba_simplestore.dll!zorba::PrePostRewriteRule::apply(zorba::RewriterContext & rCtx, zorba::expr * curExpr, bool & modified) Line 51 + 0x31 bytes C++ zorba_simplestore.dll!zorba::PrePostRewriteRule::apply(zorba::RewriterCon
[Zorba-coders] [Bug 924177] [NEW] test converters/base64/binaryReadWrite.xq enters in infinite loop
Public bug reported: When using plan serializer, the test "converters/base64/binaryReadWrite.xq" enters in infinite loop", probably when preparing the plan for the UserFunctions. I tested that with the plan_serializer branch. ** Affects: zorba Importance: Undecided Assignee: Matthias Brantner (matthias-brantner) Status: New ** Changed in: zorba Assignee: (unassigned) => Matthias Brantner (matthias-brantner) ** Branch linked: lp:~zorba-coders/zorba/plan-serializer -- You received this bug notification because you are a member of Zorba Coders, which is the registrant for Zorba. https://bugs.launchpad.net/bugs/924177 Title: test converters/base64/binaryReadWrite.xq enters in infinite loop Status in Zorba - The XQuery Processor: New Bug description: When using plan serializer, the test "converters/base64/binaryReadWrite.xq" enters in infinite loop", probably when preparing the plan for the UserFunctions. I tested that with the plan_serializer branch. To manage notifications about this bug go to: https://bugs.launchpad.net/zorba/+bug/924177/+subscriptions -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
[Zorba-coders] [Bug 866423] Re: Deadlock in Updates
In the newly commited stack module -- You received this bug notification because you are a member of Zorba Coders, which is the registrant for Zorba. https://bugs.launchpad.net/bugs/866423 Title: Deadlock in Updates Status in Zorba - The XQuery Processor: Incomplete Bug description: If some update expressions are executed in a certain order, Zorba ends up in a deadlock. Example Query: import module namespace coll = "http://www.zorba-xquery.com/zorba /collection-functions"; declare sequential function local:test() { coll:create-collection("test", Foo); replace value of node collection("test")[1]/b with "Bar"; coll:insert-nodes-at("test", 2, ); (); }; local:test(); To manage notifications about this bug go to: https://bugs.launchpad.net/zorba/+bug/866423/+subscriptions -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
[Zorba-coders] [Bug 866423] Re: Deadlock in Updates
Still hanging ** Changed in: zorba Status: Fix Released => Incomplete -- You received this bug notification because you are a member of Zorba Coders, which is the registrant for Zorba. https://bugs.launchpad.net/bugs/866423 Title: Deadlock in Updates Status in Zorba - The XQuery Processor: Incomplete Bug description: If some update expressions are executed in a certain order, Zorba ends up in a deadlock. Example Query: import module namespace coll = "http://www.zorba-xquery.com/zorba /collection-functions"; declare sequential function local:test() { coll:create-collection("test", Foo); replace value of node collection("test")[1]/b with "Bar"; coll:insert-nodes-at("test", 2, ); (); }; local:test(); To manage notifications about this bug go to: https://bugs.launchpad.net/zorba/+bug/866423/+subscriptions -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
[Zorba-coders] [Bug 866423] Re: Deadlock in Updates
Right now, the test zorba_stack_module/empty1 is hanging when executed in debug mode. In release mode it passes. The stack module uses the collections, and there is a deadlock between removeNode function which aquires Writelock and the collection iterator, which aquires Readlock. The collection iterator is not closed before the apply updates. -- You received this bug notification because you are a member of Zorba Coders, which is the registrant for Zorba. https://bugs.launchpad.net/bugs/866423 Title: Deadlock in Updates Status in Zorba - The XQuery Processor: Incomplete Bug description: If some update expressions are executed in a certain order, Zorba ends up in a deadlock. Example Query: import module namespace coll = "http://www.zorba-xquery.com/zorba /collection-functions"; declare sequential function local:test() { coll:create-collection("test", Foo); replace value of node collection("test")[1]/b with "Bar"; coll:insert-nodes-at("test", 2, ); (); }; local:test(); To manage notifications about this bug go to: https://bugs.launchpad.net/zorba/+bug/866423/+subscriptions -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
Re: [Zorba-coders] [Merge] lp:~zorba-coders/zorba/no_unicode into lp:zorba
Before commiting this branch, the branch lp:~danielturcanu/zorba/my_conv_module should be merged. -- https://code.launchpad.net/~zorba-coders/zorba/no_unicode/+merge/89104 Your team Zorba Coders is subscribed to branch lp:zorba. -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
[Zorba-coders] [Merge] lp:~danielturcanu/zorba/my_conv_module into lp:zorba/data-converters-module
The proposal to merge lp:~danielturcanu/zorba/my_conv_module into lp:zorba/data-converters-module has been updated. Status: Needs review => Approved For more details, see: https://code.launchpad.net/~danielturcanu/zorba/my_conv_module/+merge/89256 -- https://code.launchpad.net/~danielturcanu/zorba/my_conv_module/+merge/89256 Your team Zorba Coders is requested to review the proposed merge of lp:~danielturcanu/zorba/my_conv_module into lp:zorba/data-converters-module. -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
[Zorba-coders] [Merge] lp:~danielturcanu/zorba/my_conv_module into lp:zorba/data-converters-module
Daniel Turcanu has proposed merging lp:~danielturcanu/zorba/my_conv_module into lp:zorba/data-converters-module. Requested reviews: Zorba Coders (zorba-coders) For more details, see: https://code.launchpad.net/~danielturcanu/zorba/my_conv_module/+merge/89256 Upgraded web_crawler.xq . Plus removed some expected failures for ZORBA_NO_ICU, because the forcomming no_unicode branch already fixes those. -- https://code.launchpad.net/~danielturcanu/zorba/my_conv_module/+merge/89256 Your team Zorba Coders is requested to review the proposed merge of lp:~danielturcanu/zorba/my_conv_module into lp:zorba/data-converters-module. === modified file 'src/com/zorba-xquery/www/modules/converters/CMakeLists.txt' --- src/com/zorba-xquery/www/modules/converters/CMakeLists.txt 2011-12-06 08:05:27 + +++ src/com/zorba-xquery/www/modules/converters/CMakeLists.txt 2012-01-19 14:45:54 + @@ -62,11 +62,6 @@ DECLARE_ZORBA_MODULE (URI "http://www.zorba-xquery.com/modules/converters/json"; VERSION 1.0 FILE "json.xq" LINK_LIBRARIES "${Jansson_LIBRARIES}") ADD_TEST_DIRECTORY ("${PROJECT_SOURCE_DIR}/test_json") -IF(ZORBA_NO_UNICODE) - SET_TESTS_PROPERTIES(zorba_data-converters_module/converters/jansson/parse_json_03.xq - PROPERTIES WILL_FAIL TRUE) -ENDIF(ZORBA_NO_UNICODE) - ELSE (Jansson_FOUND) MESSAGE (STATUS "Jansson library not found -- if you want to use Json functionality please set Jansson_INCLUDE_DIRS and Jansson_LIBRARIES cmake parameters.") ENDIF (Jansson_FOUND) @@ -93,8 +88,3 @@ ADD_TEST ("streamable_string_streambuf" StreambufUnitTests "streambuftest") ADD_TEST_DIRECTORY("${PROJECT_SOURCE_DIR}/test") -IF(ZORBA_NO_UNICODE) - SET_TESTS_PROPERTIES(zorba_data-converters_module/converters/csv/csv_parse_utf8_11.xq - PROPERTIES WILL_FAIL TRUE) -ENDIF(ZORBA_NO_UNICODE) - === modified file 'test_html/Queries/converters/html/link_crawler2.xq2' --- test_html/Queries/converters/html/link_crawler2.xq2 2011-10-06 07:40:17 + +++ test_html/Queries/converters/html/link_crawler2.xq2 2012-01-19 14:45:54 + @@ -18,6 +18,7 @@ import module namespace map = "http://www.zorba-xquery.com/modules/store/data-structures/unordered-map";; import module namespace html = "http://www.zorba-xquery.com/modules/converters/html";; import module namespace parse-xml = "http://www.zorba-xquery.com/modules/xml";; +import module namespace file = "http://expath.org/ns/file";; declare namespace ann = "http://www.zorba-xquery.com/annotations";; declare namespace xhtml="http://www.w3.org/1999/xhtml";; @@ -25,16 +26,23 @@ declare namespace err="http://www.w3.org/2005/xqt-errors";; declare namespace httpsch = "http://expath.org/ns/http-client";; -declare variable $top-uri as xs:string := "http://www.zorba-xquery.com/site2/html/index.html";; -declare variable $uri-host as xs:string := "http://www.zorba-xquery.com/site2/";; - - -declare variable $supported-media-types as xs:string+ := ("text/xml", "application/xml", "text/xml-external-parsed-entity", "application/xml-external-parsed-entity", - "application/atom+xml", "text/html"); - - -declare variable $local:processed-internal-links:=xs:QName("processed-internal-links"); -declare variable $local:processed-external-links :=xs:QName("processed-external-links"); +declare variable $top-uri as xs:string := "http://www.zorba-xquery.com/site2/";; +declare variable $uri-host as xs:string := "http://www.zorba-xquery.com";; + + + +declare variable $local:processed-internal-links := xs:QName("processed-internal-links"); +declare variable $local:processed-external-links := xs:QName("processed-external-links"); +declare variable $local:tidy-options := http://www.zorba-xquery.com/modules/converters/html-options"; > + + + + + + + +; + declare %ann:sequential function local:create-containers() @@ -59,9 +67,19 @@ return if($sb = "") then $s1 else $sb }; -declare function local:get-real-link($href as xs:string, $start-uri as xs:string) as xs:string +declare %ann:sequential function local:get-real-link($href as xs:string, $start-uri as xs:string) as xs:string? { - local:my-substring-before(resolve-uri($href, $start-uri), "#") + variable $absuri; + try{ +$absuri := local:my-substring-before(resolve-uri(fn:no
[Zorba-coders] [Merge] lp:~danielturcanu/zorba/plan-serializer into lp:zorba
The proposal to merge lp:~danielturcanu/zorba/plan-serializer into lp:zorba has been updated. Commit Message changed to: Fix in plan serializer about preparing user_functions plan for serialization. For more details, see: https://code.launchpad.net/~danielturcanu/zorba/plan-serializer/+merge/89025 -- https://code.launchpad.net/~danielturcanu/zorba/plan-serializer/+merge/89025 Your team Zorba Coders is requested to review the proposed merge of lp:~danielturcanu/zorba/plan-serializer into lp:zorba. -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
[Zorba-coders] [Merge] lp:~danielturcanu/zorba/plan-serializer into lp:zorba
Daniel Turcanu has proposed merging lp:~danielturcanu/zorba/plan-serializer into lp:zorba. Requested reviews: Chris Hillery (ceejatec) Markos Zaharioudakis (markos-za) Zorba Coders (zorba-coders) For more details, see: https://code.launchpad.net/~danielturcanu/zorba/plan-serializer/+merge/89025 Fix in plan serializer about preparing user_functions plan for serialization. -- https://code.launchpad.net/~danielturcanu/zorba/plan-serializer/+merge/89025 Your team Zorba Coders is requested to review the proposed merge of lp:~danielturcanu/zorba/plan-serializer into lp:zorba. === modified file 'src/api/xqueryimpl.cpp' --- src/api/xqueryimpl.cpp 2012-01-11 17:30:25 + +++ src/api/xqueryimpl.cpp 2012-01-18 13:02:26 + @@ -193,7 +193,8 @@ } else { -ar.compiler_cb = theCompilerCB; +//ar.compiler_cb = theCompilerCB; +theCompilerCB->prepare_for_serialize(); } ar & theCompilerCB; === modified file 'src/compiler/api/compilercb.cpp' --- src/compiler/api/compilercb.cpp 2012-01-11 17:30:25 + +++ src/compiler/api/compilercb.cpp 2012-01-18 13:02:26 + @@ -27,6 +27,7 @@ #include "system/properties.h" #include "zorbaserialization/serialization_engine.h" +#include "functions/udf.h" namespace zorba @@ -120,6 +121,7 @@ theTimeout(timeout), theTempIndexCounter(0) { + theLocalUdfs = new rclist; } @@ -143,6 +145,7 @@ theTempIndexCounter(0), theConfig(cb.theConfig) { + theLocalUdfs = new rclist; } @@ -169,6 +172,20 @@ { } +//compile all the user_functions so the expr tree is stable at serialize +void CompilerCB::prepare_for_serialize() +{ + rclist::iterator udf_it; + for(udf_it=theLocalUdfs->begin(); udf_it != theLocalUdfs->end(); udf_it++) + { +(*udf_it)->prepare_for_serialize(this); + } +} + +rchandle > CompilerCB::get_local_udfs() +{ + return theLocalUdfs; +} /*** === modified file 'src/compiler/api/compilercb.h' --- src/compiler/api/compilercb.h 2012-01-11 17:30:25 + +++ src/compiler/api/compilercb.h 2012-01-18 13:02:26 + @@ -29,7 +29,7 @@ // without having the definition of static_context availble. # include "context/static_context.h" #endif - +#include "zorbatypes/rclist.h" #include "zorbaserialization/class_serializer.h" namespace zorba { @@ -39,7 +39,6 @@ #endif class static_context; - /*** There is one CompilerCB per query plus one CompilerCB per invocation of an eval or xqdoc expression that appears in the query. The query-level ccb is @@ -167,10 +166,14 @@ configtheConfig; + rchandle >theLocalUdfs;//for plan serializer + public: SERIALIZABLE_CLASS(CompilerCB); CompilerCB(::zorba::serialization::Archiver& ar); void serialize(::zorba::serialization::Archiver& ar); + void prepare_for_serialize(); + rchandle > get_local_udfs(); public: CompilerCB(XQueryDiagnostics*, long timeout = -1); === modified file 'src/compiler/expression/var_expr.cpp' --- src/compiler/expression/var_expr.cpp 2012-01-11 17:30:25 + +++ src/compiler/expression/var_expr.cpp 2012-01-18 13:02:26 + @@ -134,6 +134,7 @@ ar & theCopyClause; ar & theParamPos; ar & theUDF; + ar & theSetExprs; ar & theIsPrivate; ar & theIsExternal; ar & theIsMutable; === modified file 'src/compiler/translator/translator.cpp' --- src/compiler/translator/translator.cpp 2012-01-11 17:30:25 + +++ src/compiler/translator/translator.cpp 2012-01-18 13:02:26 + @@ -3331,7 +3331,7 @@ } else // Process UDF (non-external) function declaration { - f = new user_function(loc, sig, NULL, scriptKind); // no body for now + f = new user_function(loc, sig, NULL, scriptKind, theCCB); // no body for now } f->setAnnotations(theAnnotations); @@ -10424,7 +10424,8 @@ user_function* udf = new user_function(loc, fn->getSignature(), NULL, // no body for now - fn->getScriptingKind()); + fn->getScriptingKind(), + theCCB); std::vector foArgs(arity); std::vector udfArgs(arity); @@ -10632,7 +10633,8 @@ user_function_t udf(new user_function(loc, signature(0, paramTypes, returnType), body.getp(), -body->get_scripting_detail())); +body->get_scripting_detail(), +theCCB)); udf->setArgVars(argVar
Re: [Zorba-coders] [Merge] lp:~danielturcanu/zorba/plan-serializer into lp:zorba
In my debugging I saw that the flwor_expr is outside the udf. So when compiling a udf, probably the optimizer is changing the expression tree in other places as well, probably the caller of the udf, but I cannot say for sure. This woulnd't surprise me, it should be normal for an optimizer. -- https://code.launchpad.net/~danielturcanu/zorba/plan-serializer/+merge/88783 Your team Zorba Coders is requested to review the proposed merge of lp:~danielturcanu/zorba/plan-serializer into lp:zorba. -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
Re: [Zorba-coders] [Merge] lp:~danielturcanu/zorba/plan-serializer into lp:zorba
For example in one test, in flwor_expr object, theClauses was receiving another flwor_clause in the vector, which made the vector to increase and move to another space. But the initial flwor_clause had already been serialized, and its address was registered for address duplication detection. Sometimes another object would be allocated at the same address, and the plan serializer thought it is the same object. This only occured sometimes, so the problem was hard to debug. So as a rule, all the objects should freeze during plan serialization, nothing should change. -- https://code.launchpad.net/~danielturcanu/zorba/plan-serializer/+merge/88783 Your team Zorba Coders is requested to review the proposed merge of lp:~danielturcanu/zorba/plan-serializer into lp:zorba. -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
Re: [Zorba-coders] [Merge] lp:~danielturcanu/zorba/plan-serializer into lp:zorba
The user_functions were compiled during plan serialization, and this modified some expr trees that were already serialized. I had to ensure that all user_functions are compiled before plan serialization is started. -- https://code.launchpad.net/~danielturcanu/zorba/plan-serializer/+merge/88783 Your team Zorba Coders is requested to review the proposed merge of lp:~danielturcanu/zorba/plan-serializer into lp:zorba. -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
[Zorba-coders] [Merge] lp:~danielturcanu/zorba/plan-serializer into lp:zorba
The proposal to merge lp:~danielturcanu/zorba/plan-serializer into lp:zorba has been updated. Status: Approved => Needs review For more details, see: https://code.launchpad.net/~danielturcanu/zorba/plan-serializer/+merge/88783 -- https://code.launchpad.net/~danielturcanu/zorba/plan-serializer/+merge/88783 Your team Zorba Coders is requested to review the proposed merge of lp:~danielturcanu/zorba/plan-serializer into lp:zorba. -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
[Zorba-coders] [Merge] lp:~danielturcanu/zorba/plan-serializer into lp:zorba
The proposal to merge lp:~danielturcanu/zorba/plan-serializer into lp:zorba has been updated. Status: Needs review => Approved For more details, see: https://code.launchpad.net/~danielturcanu/zorba/plan-serializer/+merge/88783 -- https://code.launchpad.net/~danielturcanu/zorba/plan-serializer/+merge/88783 Your team Zorba Coders is requested to review the proposed merge of lp:~danielturcanu/zorba/plan-serializer into lp:zorba. -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
[Zorba-coders] [Merge] lp:~danielturcanu/zorba/plan-serializer into lp:zorba
Daniel Turcanu has proposed merging lp:~danielturcanu/zorba/plan-serializer into lp:zorba. Requested reviews: Markos Zaharioudakis (markos-za) Chris Hillery (ceejatec) Zorba Coders (zorba-coders) For more details, see: https://code.launchpad.net/~danielturcanu/zorba/plan-serializer/+merge/88783 Fix in plan serializer about preparing user_functions plan for serialization. -- https://code.launchpad.net/~danielturcanu/zorba/plan-serializer/+merge/88783 Your team Zorba Coders is requested to review the proposed merge of lp:~danielturcanu/zorba/plan-serializer into lp:zorba. === modified file 'src/api/xqueryimpl.cpp' --- src/api/xqueryimpl.cpp 2012-01-11 17:30:25 + +++ src/api/xqueryimpl.cpp 2012-01-16 22:20:30 + @@ -193,7 +193,8 @@ } else { -ar.compiler_cb = theCompilerCB; +//ar.compiler_cb = theCompilerCB; +theCompilerCB->prepare_for_serialize(); } ar & theCompilerCB; === modified file 'src/compiler/api/compilercb.cpp' --- src/compiler/api/compilercb.cpp 2012-01-11 17:30:25 + +++ src/compiler/api/compilercb.cpp 2012-01-16 22:20:30 + @@ -27,6 +27,7 @@ #include "system/properties.h" #include "zorbaserialization/serialization_engine.h" +#include "functions/udf.h" namespace zorba @@ -120,6 +121,7 @@ theTimeout(timeout), theTempIndexCounter(0) { + theLocalUdfs = new rclist; } @@ -143,6 +145,7 @@ theTempIndexCounter(0), theConfig(cb.theConfig) { + theLocalUdfs = new rclist; } @@ -169,6 +172,20 @@ { } +//compile all the user_functions so the expr tree is stable at serialize +void CompilerCB::prepare_for_serialize() +{ + rclist::iterator udf_it; + for(udf_it=theLocalUdfs->begin(); udf_it != theLocalUdfs->end(); udf_it++) + { +(*udf_it)->prepare_for_serialize(this); + } +} + +rchandle> CompilerCB::get_local_udfs() +{ + return theLocalUdfs; +} /*** === modified file 'src/compiler/api/compilercb.h' --- src/compiler/api/compilercb.h 2012-01-11 17:30:25 + +++ src/compiler/api/compilercb.h 2012-01-16 22:20:30 + @@ -29,7 +29,7 @@ // without having the definition of static_context availble. # include "context/static_context.h" #endif - +#include "zorbatypes/rclist.h" #include "zorbaserialization/class_serializer.h" namespace zorba { @@ -39,7 +39,6 @@ #endif class static_context; - /*** There is one CompilerCB per query plus one CompilerCB per invocation of an eval or xqdoc expression that appears in the query. The query-level ccb is @@ -167,10 +166,14 @@ configtheConfig; + rchandle>theLocalUdfs;//for plan serializer + public: SERIALIZABLE_CLASS(CompilerCB); CompilerCB(::zorba::serialization::Archiver& ar); void serialize(::zorba::serialization::Archiver& ar); + void prepare_for_serialize(); + rchandle> get_local_udfs(); public: CompilerCB(XQueryDiagnostics*, long timeout = -1); === modified file 'src/compiler/expression/var_expr.cpp' --- src/compiler/expression/var_expr.cpp 2012-01-11 17:30:25 + +++ src/compiler/expression/var_expr.cpp 2012-01-16 22:20:30 + @@ -134,6 +134,7 @@ ar & theCopyClause; ar & theParamPos; ar & theUDF; + ar & theSetExprs; ar & theIsPrivate; ar & theIsExternal; ar & theIsMutable; === modified file 'src/compiler/translator/translator.cpp' --- src/compiler/translator/translator.cpp 2012-01-11 17:30:25 + +++ src/compiler/translator/translator.cpp 2012-01-16 22:20:30 + @@ -3331,7 +3331,7 @@ } else // Process UDF (non-external) function declaration { - f = new user_function(loc, sig, NULL, scriptKind); // no body for now + f = new user_function(loc, sig, NULL, scriptKind, theCCB); // no body for now } f->setAnnotations(theAnnotations); @@ -10424,7 +10424,8 @@ user_function* udf = new user_function(loc, fn->getSignature(), NULL, // no body for now - fn->getScriptingKind()); + fn->getScriptingKind(), + theCCB); std::vector foArgs(arity); std::vector udfArgs(arity); @@ -10632,7 +10633,8 @@ user_function_t udf(new user_function(loc, signature(0, paramTypes, returnType), body.getp(), -body->get_scripting_detail())); +body->get_scripting_detail(), +theCCB)); udf->setArgVars(argVars);
Re: [Zorba-coders] [Merge] lp:~zorba-coders/zorba/bug-885512 into lp:zorba
Review: Approve Those warnings about secure strcpy_s should not appear in a normal build because there is a flag that disables them. -- https://code.launchpad.net/~zorba-coders/zorba/bug-885512/+merge/87459 Your team Zorba Coders is subscribed to branch lp:zorba. -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
[Zorba-coders] [Merge] lp:~zorba-coders/zorba/bug-885512 into lp:zorba
The proposal to merge lp:~zorba-coders/zorba/bug-885512 into lp:zorba has been updated. Status: Needs review => Approved For more details, see: https://code.launchpad.net/~zorba-coders/zorba/bug-885512/+merge/87459 -- https://code.launchpad.net/~zorba-coders/zorba/bug-885512/+merge/87459 Your team Zorba Coders is requested to review the proposed merge of lp:~zorba-coders/zorba/bug-885512 into lp:zorba. -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
[Zorba-coders] [Merge] lp:~zorba-coders/zorba/bug-885512 into lp:zorba
Daniel Turcanu has proposed merging lp:~zorba-coders/zorba/bug-885512 into lp:zorba. Requested reviews: Zorba Coders (zorba-coders) Related bugs: Bug #885512 in Zorba: "Windows 8 Developer Preview bugs" https://bugs.launchpad.net/zorba/+bug/885512 For more details, see: https://code.launchpad.net/~zorba-coders/zorba/bug-885512/+merge/87459 The bug was fixed in november. Paul did a fix, and the user had to do a clean rebuild. The bug was not related to Windows 8. -- https://code.launchpad.net/~zorba-coders/zorba/bug-885512/+merge/87459 Your team Zorba Coders is requested to review the proposed merge of lp:~zorba-coders/zorba/bug-885512 into lp:zorba. === modified file 'src/util/string_util.h' --- src/util/string_util.h 2011-10-11 17:59:20 + +++ src/util/string_util.h 2012-01-04 11:24:25 + @@ -28,6 +28,12 @@ #include "cxx_util.h" #include "stl_util.h" +#ifdef WIN32 +// Windows annoyingly defines these as macros. +#undef max +#undef min +#endif /* WIN32 */ + namespace zorba { namespace ztd { -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
Re: [Zorba-coders] [Merge] lp:~danielturcanu/zorba/link1_fix into lp:zorba
Review: Approve +one -- https://code.launchpad.net/~danielturcanu/zorba/link1_fix/+merge/87063 Your team Zorba Coders is subscribed to branch lp:zorba. -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
[Zorba-coders] [Merge] lp:~danielturcanu/zorba/link1_fix into lp:zorba
The proposal to merge lp:~danielturcanu/zorba/link1_fix into lp:zorba has been updated. Status: Needs review => Approved For more details, see: https://code.launchpad.net/~danielturcanu/zorba/link1_fix/+merge/87063 -- https://code.launchpad.net/~danielturcanu/zorba/link1_fix/+merge/87063 Your team Zorba Coders is subscribed to branch lp:zorba. -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
[Zorba-coders] [Merge] lp:~danielturcanu/zorba/link1_fix into lp:zorba
The proposal to merge lp:~danielturcanu/zorba/link1_fix into lp:zorba has been updated. Commit Message changed to: Removed test versioning/link1 to avoid bug 908062 on Windows For more details, see: https://code.launchpad.net/~danielturcanu/zorba/link1_fix/+merge/87063 -- https://code.launchpad.net/~danielturcanu/zorba/link1_fix/+merge/87063 Your team Zorba Coders is subscribed to branch lp:zorba. -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
[Zorba-coders] [Merge] lp:~danielturcanu/zorba/link1_fix into lp:zorba
Daniel Turcanu has proposed merging lp:~danielturcanu/zorba/link1_fix into lp:zorba. Requested reviews: Chris Hillery (ceejatec) For more details, see: https://code.launchpad.net/~danielturcanu/zorba/link1_fix/+merge/87063 Removed test versioning/link1 to avoid bug 908062 on Windows -- https://code.launchpad.net/~danielturcanu/zorba/link1_fix/+merge/87063 Your team Zorba Coders is subscribed to branch lp:zorba. === modified file 'test/rbkt/Queries/CMakeLists.txt' --- test/rbkt/Queries/CMakeLists.txt 2011-12-29 08:31:53 + +++ test/rbkt/Queries/CMakeLists.txt 2011-12-29 08:40:46 + @@ -168,6 +168,13 @@ SET (SKIP_TEST 1) ENDIF (NEEDS_FULL_TEXT) ENDIF (ZORBA_NO_FULL_TEXT) + IF(WIN32) +#this test fails on Windows because cannot find ourlib.dll +#bug 908062 +IF(${TESTNAME} MATCHES "test/rbkt/zorba/versioning/link1") + SET(SKIP_TEST 1) +ENDIF(${TESTNAME} MATCHES "test/rbkt/zorba/versioning/link1") + ENDIF(WIN32) # If WordNet thesaurus not found, skip ft-thesaurus-true tests IF (NOT ZORBA_WORDNET_FOUND) @@ -260,15 +267,6 @@ ENDIF(XVERMAJ EQUAL 2) IF(WIN32) - EXPECTED_FAILURE(test/rbkt/zorba/versioning/external1 870991) - EXPECTED_FAILURE(test/rbkt/zorba/versioning/external2 870991) - - EXPECTED_FAILURE(test/rbkt/zorba/versioning/link1 871061) - - # this is still an expected failure but has been commented out since the - # test is now completely disabled because of bug 871335 - #EXPECTED_FAILURE(test/rbkt/zorba/xqdoc/moduleDocumentation 871062) - EXPECTED_FAILURE(test/rbkt/zorba/file/createWriteReadDeleteSeries 866969) ENDIF(WIN32) -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
[Zorba-coders] [Merge] lp:~danielturcanu/zorba/plan-serializer into lp:zorba
The proposal to merge lp:~danielturcanu/zorba/plan-serializer into lp:zorba has been updated. Commit Message changed to: Fixing plan serializer memory leaks For more details, see: https://code.launchpad.net/~danielturcanu/zorba/plan-serializer/+merge/86959 -- https://code.launchpad.net/~danielturcanu/zorba/plan-serializer/+merge/86959 Your team Zorba Coders is subscribed to branch lp:zorba. -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
[Zorba-coders] [Merge] lp:~danielturcanu/zorba/xqueryx_fulltext into lp:zorba
The proposal to merge lp:~danielturcanu/zorba/xqueryx_fulltext into lp:zorba has been updated. Status: Needs review => Approved For more details, see: https://code.launchpad.net/~danielturcanu/zorba/xqueryx_fulltext/+merge/87018 -- https://code.launchpad.net/~danielturcanu/zorba/xqueryx_fulltext/+merge/87018 Your team Zorba Coders is requested to review the proposed merge of lp:~danielturcanu/zorba/xqueryx_fulltext into lp:zorba. -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
[Zorba-coders] [Merge] lp:~danielturcanu/zorba/xqueryx_fulltext into lp:zorba
Daniel Turcanu has proposed merging lp:~danielturcanu/zorba/xqueryx_fulltext into lp:zorba. Requested reviews: Zorba Coders (zorba-coders) For more details, see: https://code.launchpad.net/~danielturcanu/zorba/xqueryx_fulltext/+merge/87018 Fixed XQueryX for full text. Plus some other fixes for XQueryX. -- https://code.launchpad.net/~danielturcanu/zorba/xqueryx_fulltext/+merge/87018 Your team Zorba Coders is requested to review the proposed merge of lp:~danielturcanu/zorba/xqueryx_fulltext into lp:zorba. === modified file 'src/compiler/xqueryx/xqueryx_to_xquery.cpp' --- src/compiler/xqueryx/xqueryx_to_xquery.cpp 2011-09-05 20:08:30 + +++ src/compiler/xqueryx/xqueryx_to_xquery.cpp 2011-12-28 14:47:28 + @@ -53,7 +53,10 @@ if(!inited) { xmlDocPtr doc; -doc = xmlParseDoc((xmlChar*)xqueryx_update_xslt); +std::string xqueryx_full_xslt; +xqueryx_full_xslt += xqueryx3_0_update_xslt; +xqueryx_full_xslt += xqueryx_fulltext_xslt; +doc = xmlParseDoc((xmlChar*)xqueryx_full_xslt.c_str()); xqueryx_xslt = (xsltStylesheet*)xsltParseStylesheetDoc(doc); // xmlFreeDoc(doc); === modified file 'src/compiler/xqueryx/xqueryx_xslt.cpp' --- src/compiler/xqueryx/xqueryx_xslt.cpp 2011-07-07 07:20:10 + +++ src/compiler/xqueryx/xqueryx_xslt.cpp 2011-12-28 14:47:28 + @@ -23,9 +23,11 @@ namespace zorba { -//XQueryX 3.0 (draft 14 june 2011) http://www.w3.org/TR/xqueryx-30/#Stylesheet +//XQueryX 3.0 (draft 13 december 2011) http://www.w3.org/TR/xqueryx-30/#Stylesheet +//XQueryX update 1.0 +//XQueryX full text http://www.w3.org/TR/xpath-full-text-10/#id-xqft-xqueryx -const char xqueryx_update_xslt[] = +const char xqueryx3_0_update_xslt[] = "" "" "" @@ -75,13 +77,22 @@ "" "" "" +"" +"" +"" +"" +"" +"" +"" "" "http://www.w3.org/1999/XSL/Transform\""; " xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\""; " xmlns:xqx=\"http://www.w3.org/2005/XQueryX\""; -" xmlns:xqxuf=\"http://www.w3.org/2007/xquery-update-10\";>" -"" +" " " " " " -" ," -"" -" '" -" \"" +" " +" ," +"" +" " +" " +" '" +" " +" " +" \"" +" " " " " " " " @@ -121,11 +140,13 @@ " " " " " " +" " " " " " " " " " " " +" " " " " " " " @@ -134,12 +155,12 @@ " " " " " " -" " +" " " " -" " +" " " " " " -" " +" " " " " " " " @@ -199,8 +220,12 @@ " 
" " " " " -" \"" -" \"\"" +" " +" \"" +" " +" " +" \"\"" +" " " " " " " " @@ -280,7 +305,7 @@ " " " " " " -"" +" " " " " " " " @@ -293,13 +318,13 @@ " rootExpr is a stepExpr, then the parens must be" " omitted. -->" " " -" " +" " " " " " " " " " " " -" " +" " " " " " " " @@ -333,8 +358,8 @@ " " " " " " -"" -"" +" " +" " " " " " -" Incorrect XQueryX: function calls must not use unqualified \"reserved\" name \"\"" -" " +" " +" Incorrect XQueryX: function calls must not use unqualified \"reserved\" name \"" +" " +" \"" +" " +" " +" " +" " " " " " " " @@ -380,8 +411,12 @@ " " " " " " -" " -" " +" " +" " +" " +" " +" " +" " " " " " " " @@ -391,27 +426,60 @@ " " " " " " -" " -" " -" " -" div " -" idiv " -" mod " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" " +" div " +" " +" " +" i
[Zorba-coders] [Bug 909375] [NEW] some XQueryX full text test fail because of wrong spec file
Public bug reported: Some XQueryX test from w3c_full_text_testsuite fail because their spec file is not generated as the XQuery analog. All those tests use a stop word list from a URL which should be redirected to a local file. The spec file for the XQueryX test does not contain that redirection. The tests that fail are: 22310:test/rbkt/w3c_full_text_testsuite/XQueryX/Examples/3.4.7-StopWordOption/ft-5.2.11-examples-q4 22311:test/rbkt/w3c_full_text_testsuite/XQueryX/Examples/3.4.7-StopWordOption/ft-5.2.11-examples-q5 22608:test/rbkt/w3c_full_text_testsuite/XQueryX/Expressions/Operators/CompExpr/FTContainsExpr/FTSelection/MatchOptions/FTStopWord/ft-3.4.7-expressions-q4 22609:test/rbkt/w3c_full_text_testsuite/XQueryX/Expressions/Operators/CompExpr/FTContainsExpr/FTSelection/MatchOptions/FTStopWord/ft-3.4.7-expressions-q5 22610:test/rbkt/w3c_full_text_testsuite/XQueryX/Expressions/Operators/CompExpr/FTContainsExpr/FTSelection/MatchOptions/FTStopWord/ft-3.4.7-expressions-q6 22612:test/rbkt/w3c_full_text_testsuite/XQueryX/Expressions/Operators/CompExpr/FTContainsExpr/FTSelection/MatchOptions/FTStopWord/ft-3.4.7-expressions-q8 22613:test/rbkt/w3c_full_text_testsuite/XQueryX/Expressions/Operators/CompExpr/FTContainsExpr/FTSelection/MatchOptions/FTStopWord/ft-3.4.7-expressions-q9 22615:test/rbkt/w3c_full_text_testsuite/XQueryX/Expressions/Operators/CompExpr/FTContainsExpr/FTSelection/MatchOptions/FTStopWord/ft-5.2.11-expressions-q2 22617:test/rbkt/w3c_full_text_testsuite/XQueryX/Expressions/Operators/CompExpr/FTContainsExpr/FTSelection/MatchOptions/FTStopWord/ft-5.2.11-expressions-q4 22618:test/rbkt/w3c_full_text_testsuite/XQueryX/Expressions/Operators/CompExpr/FTContainsExpr/FTSelection/MatchOptions/FTStopWord/ft-5.2.11-expressions-q5 22619:test/rbkt/w3c_full_text_testsuite/XQueryX/Expressions/Operators/CompExpr/FTContainsExpr/FTSelection/MatchOptions/FTStopWord/ft-5.2.11-expressions-q6 22620:test/rbkt/w3c_full_text_testsuite/XQueryX/Expressions/Operators/CompExpr/FTContainsExpr/FTSelection/MatchOptions/FTStopWord/ft-5.2.11-expressions-q7 22621:test/rbkt/w3c_full_text_testsuite/XQueryX/Expressions/Operators/CompExpr/FTContainsExpr/FTSelection/MatchOptions/FTStopWord/ft-5.2.11-expressions-q8 22622:test/rbkt/w3c_full_text_testsuite/XQueryX/Expressions/Operators/CompExpr/FTContainsExpr/FTSelection/MatchOptions/FTStopWord/ft-5.2.11-expressions-q9 22898:test/rbkt/w3c_full_text_testsuite/XQueryX/UseCase/UseCase-STOP-WORD/stop-word-queries-results-q1 22899:test/rbkt/w3c_full_text_testsuite/XQueryX/UseCase/UseCase-STOP-WORD/stop-word-queries-results-q1b 22902:test/rbkt/w3c_full_text_testsuite/XQueryX/UseCase/UseCase-STOP-WORD/stop-word-queries-results-q3 22903:test/rbkt/w3c_full_text_testsuite/XQueryX/UseCase/UseCase-STOP-WORD/stop-word-queries-results-q3b ** Affects: zorba Importance: Medium Assignee: Sorin Marian Nasoi (sorin.marian.nasoi) Status: New -- You received this bug notification because you are a member of Zorba Coders, which is the registrant for Zorba. https://bugs.launchpad.net/bugs/909375 Title: some XQueryX full text test fail because of wrong spec file Status in Zorba - The XQuery Processor: New Bug description: Some XQueryX test from w3c_full_text_testsuite fail because their spec file is not generated as the XQuery analog. All those tests use a stop word list from a URL which should be redirected to a local file. The spec file for the XQueryX test does not contain that redirection. The tests that fail are: 22310:test/rbkt/w3c_full_text_testsuite/XQueryX/Examples/3.4.7-StopWordOption/ft-5.2.11-examples-q4 22311:test/rbkt/w3c_full_text_testsuite/XQueryX/Examples/3.4.7-StopWordOption/ft-5.2.11-examples-q5 22608:test/rbkt/w3c_full_text_testsuite/XQueryX/Expressions/Operators/CompExpr/FTContainsExpr/FTSelection/MatchOptions/FTStopWord/ft-3.4.7-expressions-q4 22609:test/rbkt/w3c_full_text_testsuite/XQueryX/Expressions/Operators/CompExpr/FTContainsExpr/FTSelection/MatchOptions/FTStopWord/ft-3.4.7-expressions-q5 22610:test/rbkt/w3c_full_text_testsuite/XQueryX/Expressions/Operators/CompExpr/FTContainsExpr/FTSelection/MatchOptions/FTStopWord/ft-3.4.7-expressions-q6 22612:test/rbkt/w3c_full_text_testsuite/XQueryX/Expressions/Operators/CompExpr/FTContainsExpr/FTSelection/MatchOptions/FTStopWord/ft-3.4.7-expressions-q8 22613:test/rbkt/w3c_full_text_testsuite/XQueryX/Expressions/Operators/CompExpr/FTContainsExpr/FTSelection/MatchOptions/FTStopWord/ft-3.4.7-expressions-q9 22615:test/rbkt/w3c_full_text_testsuite/XQueryX/Expressions/Operators/CompExpr/FTContainsExpr/FTSelection/MatchOptions/FTStopWord/ft-5.2.11-expressions-q2 22617:test/rbkt/w3c_full_text_testsuite/XQueryX/Expressions/Operators/CompExpr/FTContainsExpr/FTSelection/MatchOptions/FTStopWord/ft-5.2.11-expressions-q4 22618:test/rbkt/w3c_full_text_testsuite/XQueryX/Expressions/Operators/CompExpr/FTContainsExpr/FTSelection/MatchOptions/FTStopWord/ft-5.2.11-expressions-q5 22619:test/r
[Zorba-coders] [Bug 909303] Re: test w3c_testsuite/XQueryX/Construct/DirectConElem/DirectConElemContent/K2-DirectConElemContent-27.xqx fails
In the same category of failure is the test w3c_testsuite/XQueryX/Construct/DirectConElem/DirectConElemWhitespace/K2-DirectConElemWhitespace-25.xqx Again there are strange duplicates of text nodes in the element string value. -- You received this bug notification because you are a member of Zorba Coders, which is the registrant for Zorba. https://bugs.launchpad.net/bugs/909303 Title: test w3c_testsuite/XQueryX/Construct/DirectConElem/DirectConElemContent/K2-DirectConElemContent-27.xqx fails Status in Zorba - The XQuery Processor: New Bug description: The XQueryX version of the test K2-DirectConElemContent-27 fails, because the result is different than expected. The code is translated to xquery as: (string({ text {"str" } }{ "str" }{ text {"str" } }{ text {"str" } }{ text {"str" } }{ "strstr" }{ ("str","str","strstr","str") }{ "strstr" }{ text { "str" } }{ "s" }{ processing-instruction target{"str"} }{ "tr" }) eq "st rstrstrstrstrstrstrstr str strstr strstrstrstrstr") which is equivalent to the XQuery test, but the result is different. The first word of the result contains 10 "str" instead of 8 "str", so probably there is a bug in the text node constructor. To manage notifications about this bug go to: https://bugs.launchpad.net/zorba/+bug/909303/+subscriptions -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
[Zorba-coders] [Bug 909303] [NEW] test w3c_testsuite/XQueryX/Construct/DirectConElem/DirectConElemContent/K2-DirectConElemContent-27.xqx fails
Public bug reported: The XQueryX version of the test K2-DirectConElemContent-27 fails, because the result is different than expected. The code is translated to xquery as: (string({ text {"str" } }{ "str" }{ text {"str" } }{ text {"str" } }{ text {"str" } }{ "strstr" }{ ("str","str","strstr","str") }{ "strstr" }{ text { "str" } }{ "s" }{ processing-instruction target{"str"} }{ "tr" }) eq "st rstrstrstrstrstrstrstr str strstr strstrstrstrstr") which is equivalent to the XQuery test, but the result is different. The first word of the result contains 10 "str" instead of 8 "str", so probably there is a bug in the text node constructor. ** Affects: zorba Importance: High Assignee: Markos Zaharioudakis (markos-za) Status: New -- You received this bug notification because you are a member of Zorba Coders, which is the registrant for Zorba. https://bugs.launchpad.net/bugs/909303 Title: test w3c_testsuite/XQueryX/Construct/DirectConElem/DirectConElemContent/K2-DirectConElemContent-27.xqx fails Status in Zorba - The XQuery Processor: New Bug description: The XQueryX version of the test K2-DirectConElemContent-27 fails, because the result is different than expected. The code is translated to xquery as: (string({ text {"str" } }{ "str" }{ text {"str" } }{ text {"str" } }{ text {"str" } }{ "strstr" }{ ("str","str","strstr","str") }{ "strstr" }{ text { "str" } }{ "s" }{ processing-instruction target{"str"} }{ "tr" }) eq "st rstrstrstrstrstrstrstr str strstr strstrstrstrstr") which is equivalent to the XQuery test, but the result is different. The first word of the result contains 10 "str" instead of 8 "str", so probably there is a bug in the text node constructor. To manage notifications about this bug go to: https://bugs.launchpad.net/zorba/+bug/909303/+subscriptions -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
Re: [Zorba-coders] [Merge] lp:~danielturcanu/zorba/plan-serializer into lp:zorba
Review: Approve +one -- https://code.launchpad.net/~danielturcanu/zorba/plan-serializer/+merge/86959 Your team Zorba Coders is subscribed to branch lp:zorba. -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
[Zorba-coders] [Merge] lp:~danielturcanu/zorba/link1_fix into lp:zorba
The proposal to merge lp:~danielturcanu/zorba/link1_fix into lp:zorba has been updated. Status: Needs review => Approved For more details, see: https://code.launchpad.net/~danielturcanu/zorba/link1_fix/+merge/86994 -- https://code.launchpad.net/~danielturcanu/zorba/link1_fix/+merge/86994 Your team Zorba Coders is requested to review the proposed merge of lp:~danielturcanu/zorba/link1_fix into lp:zorba. -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
[Zorba-coders] [Merge] lp:~danielturcanu/zorba/link1_fix into lp:zorba
Daniel Turcanu has proposed merging lp:~danielturcanu/zorba/link1_fix into lp:zorba. Requested reviews: Zorba Coders (zorba-coders) For more details, see: https://code.launchpad.net/~danielturcanu/zorba/link1_fix/+merge/86994 Removed test versioning/link1 to avoid bug 908062 on Windows -- https://code.launchpad.net/~danielturcanu/zorba/link1_fix/+merge/86994 Your team Zorba Coders is requested to review the proposed merge of lp:~danielturcanu/zorba/link1_fix into lp:zorba. === modified file 'test/rbkt/Queries/CMakeLists.txt' --- test/rbkt/Queries/CMakeLists.txt 2011-12-22 20:34:53 + +++ test/rbkt/Queries/CMakeLists.txt 2011-12-28 09:05:31 + @@ -168,6 +168,11 @@ SET (SKIP_TEST 1) ENDIF (NEEDS_FULL_TEXT) ENDIF (ZORBA_NO_FULL_TEXT) + IF(WIN32) +IF(${TESTNAME} MATCHES "test/rbkt/zorba/versioning/link1") + SET(SKIP_TEST 1) +ENDIF(${TESTNAME} MATCHES "test/rbkt/zorba/versioning/link1") + ENDIF(WIN32) # If WordNet thesaurus not found, skip ft-thesaurus-true tests IF (NOT ZORBA_WORDNET_FOUND) @@ -260,10 +265,11 @@ ENDIF(XVERMAJ EQUAL 2) IF(WIN32) - EXPECTED_FAILURE(test/rbkt/zorba/versioning/external1 870991) - EXPECTED_FAILURE(test/rbkt/zorba/versioning/external2 870991) + #these tests now work on Windows + #EXPECTED_FAILURE(test/rbkt/zorba/versioning/external1 870991) + #EXPECTED_FAILURE(test/rbkt/zorba/versioning/external2 870991) - EXPECTED_FAILURE(test/rbkt/zorba/versioning/link1 871061) + #EXPECTED_FAILURE(test/rbkt/zorba/versioning/link1 871061) # this is still an expected failure but has been commented out since the # test is now completely disabled because of bug 871335 -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
[Zorba-coders] [Merge] lp:~danielturcanu/zorba/link1_fix into lp:zorba
The proposal to merge lp:~danielturcanu/zorba/link1_fix into lp:zorba has been updated. Status: Needs review => Approved For more details, see: https://code.launchpad.net/~danielturcanu/zorba/link1_fix/+merge/86960 -- https://code.launchpad.net/~danielturcanu/zorba/link1_fix/+merge/86960 Your team Zorba Coders is requested to review the proposed merge of lp:~danielturcanu/zorba/link1_fix into lp:zorba. -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
[Zorba-coders] [Merge] lp:~danielturcanu/zorba/link1_fix into lp:zorba
Daniel Turcanu has proposed merging lp:~danielturcanu/zorba/link1_fix into lp:zorba. Requested reviews: Zorba Coders (zorba-coders) For more details, see: https://code.launchpad.net/~danielturcanu/zorba/link1_fix/+merge/86960 Removed test versioning/link1 to avoid bug 908062 on Windows -- https://code.launchpad.net/~danielturcanu/zorba/link1_fix/+merge/86960 Your team Zorba Coders is requested to review the proposed merge of lp:~danielturcanu/zorba/link1_fix into lp:zorba. -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
[Zorba-coders] [Merge] lp:~danielturcanu/zorba/plan-serializer into lp:zorba
The proposal to merge lp:~danielturcanu/zorba/plan-serializer into lp:zorba has been updated. Status: Needs review => Approved For more details, see: https://code.launchpad.net/~danielturcanu/zorba/plan-serializer/+merge/86959 -- https://code.launchpad.net/~danielturcanu/zorba/plan-serializer/+merge/86959 Your team Zorba Coders is requested to review the proposed merge of lp:~danielturcanu/zorba/plan-serializer into lp:zorba. -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
[Zorba-coders] [Merge] lp:~danielturcanu/zorba/plan-serializer into lp:zorba
Daniel Turcanu has proposed merging lp:~danielturcanu/zorba/plan-serializer into lp:zorba. Requested reviews: Zorba Coders (zorba-coders) For more details, see: https://code.launchpad.net/~danielturcanu/zorba/plan-serializer/+merge/86959 Fixed memory leak in serialization of Diagnostic class. -- https://code.launchpad.net/~danielturcanu/zorba/plan-serializer/+merge/86959 Your team Zorba Coders is requested to review the proposed merge of lp:~danielturcanu/zorba/plan-serializer into lp:zorba. === modified file 'src/zorbaserialization/zorba_class_serializer.cpp' --- src/zorbaserialization/zorba_class_serializer.cpp 2011-09-30 14:06:33 + +++ src/zorbaserialization/zorba_class_serializer.cpp 2011-12-27 15:15:30 + @@ -1080,6 +1080,7 @@ ar & local; ar.set_is_temp_field(false); obj = internal::SystemDiagnosticBase::find(local); +free(local); ZORBA_ASSERT(obj); } else -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
[Zorba-coders] [Merge] lp:~danielturcanu/zorba/plan-serializer into lp:zorba
The proposal to merge lp:~danielturcanu/zorba/plan-serializer into lp:zorba has been updated. Status: Needs review => Approved For more details, see: https://code.launchpad.net/~danielturcanu/zorba/plan-serializer/+merge/86807 -- https://code.launchpad.net/~danielturcanu/zorba/plan-serializer/+merge/86807 Your team Zorba Coders is requested to review the proposed merge of lp:~danielturcanu/zorba/plan-serializer into lp:zorba. -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
[Zorba-coders] [Merge] lp:~danielturcanu/zorba/plan-serializer into lp:zorba
Daniel Turcanu has proposed merging lp:~danielturcanu/zorba/plan-serializer into lp:zorba. Requested reviews: Zorba Coders (zorba-coders) For more details, see: https://code.launchpad.net/~danielturcanu/zorba/plan-serializer/+merge/86807 Fixed memory leak in serialization of Diagnostic class. -- https://code.launchpad.net/~danielturcanu/zorba/plan-serializer/+merge/86807 Your team Zorba Coders is requested to review the proposed merge of lp:~danielturcanu/zorba/plan-serializer into lp:zorba. === modified file 'src/zorbaserialization/zorba_class_serializer.cpp' --- src/zorbaserialization/zorba_class_serializer.cpp 2011-09-30 14:06:33 + +++ src/zorbaserialization/zorba_class_serializer.cpp 2011-12-23 14:18:26 + @@ -1080,6 +1080,7 @@ ar & local; ar.set_is_temp_field(false); obj = internal::SystemDiagnosticBase::find(local); +free(local); ZORBA_ASSERT(obj); } else === modified file 'test/rbkt/Queries/CMakeLists.txt' --- test/rbkt/Queries/CMakeLists.txt 2011-12-22 20:34:53 + +++ test/rbkt/Queries/CMakeLists.txt 2011-12-23 14:18:26 + @@ -168,6 +168,11 @@ SET (SKIP_TEST 1) ENDIF (NEEDS_FULL_TEXT) ENDIF (ZORBA_NO_FULL_TEXT) + IF(WIN32) +IF(${TESTNAME} MATCHES "test/rbkt/zorba/versioning/link1") + SET(SKIP_TEST 1) +ENDIF(${TESTNAME} MATCHES "test/rbkt/zorba/versioning/link1") + ENDIF(WIN32) # If WordNet thesaurus not found, skip ft-thesaurus-true tests IF (NOT ZORBA_WORDNET_FOUND) @@ -260,10 +265,12 @@ ENDIF(XVERMAJ EQUAL 2) IF(WIN32) - EXPECTED_FAILURE(test/rbkt/zorba/versioning/external1 870991) - EXPECTED_FAILURE(test/rbkt/zorba/versioning/external2 870991) + #there tests now work on Windows + #EXPECTED_FAILURE(test/rbkt/zorba/versioning/external1 870991) + #EXPECTED_FAILURE(test/rbkt/zorba/versioning/external2 870991) - EXPECTED_FAILURE(test/rbkt/zorba/versioning/link1 871061) + #disabled this test on WIN32 + #EXPECTED_FAILURE(test/rbkt/zorba/versioning/link1 871061) # this is still an expected failure but has been commented out since the # test is now completely disabled because of bug 871335 === modified file 'test/rbkt/modules/CMakeLists.txt' --- test/rbkt/modules/CMakeLists.txt 2011-08-26 22:46:24 + +++ test/rbkt/modules/CMakeLists.txt 2011-12-23 14:18:26 + @@ -32,6 +32,7 @@ DECLARE_ZORBA_MODULE(URI "http://www.zorba-xquery.com/modules/ext"; VERSION 1.0 FILE "ext.xq" TEST_ONLY) +IF(NOT WIN32) #disable link + ourlib on Windows ADD_SUBDIRECTORY(ourlib) # For the moment, this test module depends on Xerces @@ -39,6 +40,7 @@ DECLARE_ZORBA_MODULE(URI "http://www.zorba-xquery.com/modules/link"; VERSION 1.0 LINK_LIBRARIES "ourlib" FILE "link.xq" TEST_ONLY) ENDIF (NOT ZORBA_NO_XMLSCHEMA) +ENDIF(NOT WIN32) DECLARE_ZORBA_SCHEMA(URI "http://www.zorba-xquery.com/modules/theschema"; FILE "schema.xsd" TEST_ONLY) -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
[Zorba-coders] [Bug 908062] [NEW] zorba/versioning/link1 test fails on Windows
Public bug reported: zorba/versioning/link1 test fails on Windows with the message box "ourlib.dll is not found". Then I have to press OK on the message box for the testing to continue. ** Affects: zorba Importance: Undecided Assignee: Chris Hillery (ceejatec) Status: New ** Changed in: zorba Assignee: (unassigned) => Chris Hillery (ceejatec) -- You received this bug notification because you are a member of Zorba Coders, which is the registrant for Zorba. https://bugs.launchpad.net/bugs/908062 Title: zorba/versioning/link1 test fails on Windows Status in Zorba - The XQuery Processor: New Bug description: zorba/versioning/link1 test fails on Windows with the message box "ourlib.dll is not found". Then I have to press OK on the message box for the testing to continue. To manage notifications about this bug go to: https://bugs.launchpad.net/zorba/+bug/908062/+subscriptions -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
[Zorba-coders] [Merge] lp:~danielturcanu/zorba/plan-serializer into lp:zorba
The proposal to merge lp:~danielturcanu/zorba/plan-serializer into lp:zorba has been updated. Status: Needs review => Approved For more details, see: https://code.launchpad.net/~danielturcanu/zorba/plan-serializer/+merge/86714 -- https://code.launchpad.net/~danielturcanu/zorba/plan-serializer/+merge/86714 Your team Zorba Coders is requested to review the proposed merge of lp:~danielturcanu/zorba/plan-serializer into lp:zorba. -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
[Zorba-coders] [Merge] lp:~danielturcanu/zorba/plan-serializer into lp:zorba
Daniel Turcanu has proposed merging lp:~danielturcanu/zorba/plan-serializer into lp:zorba. Requested reviews: Zorba Coders (zorba-coders) For more details, see: https://code.launchpad.net/~danielturcanu/zorba/plan-serializer/+merge/86714 Fixed plan serialization of udf_function -- https://code.launchpad.net/~danielturcanu/zorba/plan-serializer/+merge/86714 Your team Zorba Coders is requested to review the proposed merge of lp:~danielturcanu/zorba/plan-serializer into lp:zorba. === modified file 'src/functions/udf.cpp' --- src/functions/udf.cpp 2011-12-22 14:14:53 + +++ src/functions/udf.cpp 2011-12-22 14:45:56 + @@ -148,6 +148,7 @@ ar & theScriptingKind; ar & theIsExiting; ar & theIsLeaf; + ar & theMutuallyRecursiveUDFs; ar & theIsOptimized; //ar.set_is_temp_field(true); //ar & save_plan; @@ -156,6 +157,10 @@ ar & thePlan; ar & thePlanStateSize; ar & theArgVarsRefs; + + //+ar & theCache; + ar & theCacheResults; + ar & theCacheComputed; } === modified file 'src/functions/udf.h' --- src/functions/udf.h 2011-12-22 14:14:53 + +++ src/functions/udf.h 2011-12-22 14:45:56 + @@ -127,7 +127,7 @@ uint32_tthePlanStateSize; std::vector theArgVarsRefs; - store::Index_t theCache; + store::Index_t theCache; //note: not for serialization booltheCacheResults; booltheCacheComputed; === modified file 'src/runtime/core/flwor_iterator.h' --- src/runtime/core/flwor_iterator.h 2011-06-14 17:26:33 + +++ src/runtime/core/flwor_iterator.h 2011-12-22 14:45:56 + @@ -264,6 +264,7 @@ SERIALIZABLE_CLASS_CONSTRUCTOR(GroupByClause) void serialize(::zorba::serialization::Archiver& ar) { +ar & theLocation; ar & theGroupingSpecs; ar & theNonGroupingSpecs; } === modified file 'src/runtime/strings/strings_impl.cpp' --- src/runtime/strings/strings_impl.cpp 2011-12-21 14:40:33 + +++ src/runtime/strings/strings_impl.cpp 2011-12-22 14:45:56 + @@ -135,7 +135,7 @@ while ( !state->theStream->eof() ) { utf8::encoded_char_type ec; - ::bzero( ec, sizeof( ec ) ); + memset( ec, 0, sizeof( ec ) ); utf8::storage_type *p; p = ec; -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
Re: [Zorba-coders] [Merge] lp:~zorba-coders/zorba/fixes_xqdoc into lp:zorba
Review: Approve -- https://code.launchpad.net/~zorba-coders/zorba/fixes_xqdoc/+merge/86417 Your team Zorba Coders is subscribed to branch lp:zorba. -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
Re: [Zorba-coders] [Merge] lp:~zorba-coders/zorba/fixes_xqdoc into lp:zorba
Review: Approve Compiled and regenerated exi documentation and it went fine. -- https://code.launchpad.net/~zorba-coders/zorba/fixes_xqdoc/+merge/86103 Your team Zorba Coders is subscribed to branch lp:zorba. -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
[Zorba-coders] [Bug 904650] [NEW] some tests crash with plan serializer ON
Public bug reported: Some tests in zorba testsuite crash with ZORBA_TEST_PLAN_SERIALIZATION. The bug probably affects 2.1 release as well. ** Affects: zorba Importance: Undecided Assignee: Daniel Turcanu (danielturcanu) Status: New ** Changed in: zorba Milestone: None => 2.2 ** Changed in: zorba Assignee: (unassigned) => Daniel Turcanu (danielturcanu) -- You received this bug notification because you are a member of Zorba Coders, which is the registrant for Zorba. https://bugs.launchpad.net/bugs/904650 Title: some tests crash with plan serializer ON Status in Zorba - The XQuery Processor: New Bug description: Some tests in zorba testsuite crash with ZORBA_TEST_PLAN_SERIALIZATION. The bug probably affects 2.1 release as well. To manage notifications about this bug go to: https://bugs.launchpad.net/zorba/+bug/904650/+subscriptions -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
[Zorba-coders] [Merge] lp:~danielturcanu/zorba/web_crawler_tutorial into lp:zorba
The proposal to merge lp:~danielturcanu/zorba/web_crawler_tutorial into lp:zorba has been updated. Status: Needs review => Approved For more details, see: https://code.launchpad.net/~danielturcanu/zorba/web_crawler_tutorial/+merge/85669 -- https://code.launchpad.net/~danielturcanu/zorba/web_crawler_tutorial/+merge/85669 Your team Zorba Coders is requested to review the proposed merge of lp:~danielturcanu/zorba/web_crawler_tutorial into lp:zorba. -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
[Zorba-coders] [Merge] lp:~danielturcanu/zorba/web_crawler_tutorial into lp:zorba
Daniel Turcanu has proposed merging lp:~danielturcanu/zorba/web_crawler_tutorial into lp:zorba. Requested reviews: Zorba Coders (zorba-coders) For more details, see: https://code.launchpad.net/~danielturcanu/zorba/web_crawler_tutorial/+merge/85669 Updated the web crawler tutorial -- https://code.launchpad.net/~danielturcanu/zorba/web_crawler_tutorial/+merge/85669 Your team Zorba Coders is requested to review the proposed merge of lp:~danielturcanu/zorba/web_crawler_tutorial into lp:zorba. === added file 'doc/zorba/link_crawler2.dox' --- doc/zorba/link_crawler2.dox 1970-01-01 00:00:00 + +++ doc/zorba/link_crawler2.dox 2011-12-14 14:31:06 + @@ -0,0 +1,238 @@ +/** +\page link_crawler2 Web Crawler example in XQuery +\code +(: + : Copyright 2006-2011 The FLWOR Foundation. + : + : Licensed under the Apache License, Version 2.0 (the "License"); + : you may not use this file except in compliance with the License. + : You may obtain a copy of the License at + : + : http://www.apache.org/licenses/LICENSE-2.0 + : + : Unless required by applicable law or agreed to in writing, software + : distributed under the License is distributed on an "AS IS" BASIS, + : WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + : See the License for the specific language governing permissions and + : limitations under the License. +:) + +import module namespace http = "http://www.zorba-xquery.com/modules/http-client";; +import module namespace map = "http://www.zorba-xquery.com/modules/store/data-structures/unordered-map";; +import module namespace html = "http://www.zorba-xquery.com/modules/converters/html";; +import module namespace parse-xml = "http://www.zorba-xquery.com/modules/xml";; +import module namespace file = "http://expath.org/ns/file";; + +declare namespace ann = "http://www.zorba-xquery.com/annotations";; +declare namespace xhtml="http://www.w3.org/1999/xhtml";; +declare namespace output="http://www.w3.org/2010/xslt-xquery-serialization";; +declare namespace err="http://www.w3.org/2005/xqt-errors";; +declare namespace httpsch = "http://expath.org/ns/http-client";; + +declare variable $top-uri as xs:string := "http://www.zorba-xquery.com/site2/html/index.html";; +declare variable $uri-host as xs:string := "http://www.zorba-xquery.com";; + + + +declare variable $local:processed-internal-links := xs:QName("processed-internal-links"); +declare variable $local:processed-external-links := xs:QName("processed-external-links"); + + +declare %ann:sequential function local:create-containers() +{ + map:create($local:processed-internal-links, xs:QName("xs:string")); + map:create($local:processed-external-links, xs:QName("xs:string")); +}; + +declare %ann:sequential function local:delete-containers(){ + for $x in map:available-maps() + return map:delete($x); +}; + +declare function local:is-internal($x as xs:string) as xs:boolean +{ + starts-with($x, $uri-host) +}; + +declare function local:my-substring-before($s1 as xs:string, $s2 as xs:string) as xs:string +{ +let $sb := fn:substring-before($s1, $s2) +return if($sb = "") then $s1 else $sb +}; + +declare %ann:sequential function local:get-real-link($href as xs:string, $start-uri as xs:string) as xs:string? +{ + variable $absuri; + try{ +$absuri := local:my-substring-before(resolve-uri(fn:normalize-space($href), $start-uri), "#"); + } + catch * + { + map:insert($local:processed-external-links, ({$start-uri}, + malformed, + broken), $href); + } + $absuri +}; + + +declare function local:get-media-type ($http-call as node()) as xs:string +{ + local:my-substring-before($http-call/httpsch:header[@name = 'Content-Type'][1]/string(@value), ";") +}; + +declare function local:alive($http-call as item()*) as xs:boolean +{ + if((count($http-call) ge 1) and +($http-call[1]/@status eq 200)) + then true() else fn:trace(false(), "alive") +}; + + +declare %ann:sequential function local:get-out-links-parsed($content as node()*, $uri as xs:string) as xs:string* +{ distinct-values( for $y in ($content//*:a/string(@href), + $content//*:link/string(@href), + $content//*:script/string(@src), + $content//*:img/string(@src), + $content//*:area/string(@href) + ) +return local:get-real-link($y, $uri)) +}; + + +declare %ann:sequential function local:get-out-links-unparsed($content as xs:string, $uri as xs:string) as xs:string*{ + + distinct-values( + let $search := fn:analyze-string($content, "(<|<|<)(((a|link|area).+?hr
[Zorba-coders] [Merge] lp:~zorba-coders/zorba/no_unicode into lp:zorba
The proposal to merge lp:~zorba-coders/zorba/no_unicode into lp:zorba has been updated. Status: Needs review => Approved For more details, see: https://code.launchpad.net/~zorba-coders/zorba/no_unicode/+merge/85142 -- https://code.launchpad.net/~zorba-coders/zorba/no_unicode/+merge/85142 Your team Zorba Coders is subscribed to branch lp:zorba. -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
[Zorba-coders] [Merge] lp:~danielturcanu/zorba/mytrunk into lp:zorba
The proposal to merge lp:~danielturcanu/zorba/mytrunk into lp:zorba has been updated. Status: Needs review => Approved For more details, see: https://code.launchpad.net/~danielturcanu/zorba/mytrunk/+merge/83210 -- https://code.launchpad.net/~danielturcanu/zorba/mytrunk/+merge/83210 Your team Zorba Coders is subscribed to branch lp:zorba. -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
[Zorba-coders] [Merge] lp:~danielturcanu/zorba/mytrunk into lp:zorba
Daniel Turcanu has proposed merging lp:~danielturcanu/zorba/mytrunk into lp:zorba. Requested reviews: Chris Hillery (ceejatec) Matthias Brantner (matthias-brantner) For more details, see: https://code.launchpad.net/~danielturcanu/zorba/mytrunk/+merge/83210 fn:analyze-string fix Also removed useless test -- https://code.launchpad.net/~danielturcanu/zorba/mytrunk/+merge/83210 Your team Zorba Coders is subscribed to branch lp:zorba. === modified file 'ChangeLog' --- ChangeLog 2011-11-23 16:27:08 + +++ ChangeLog 2011-11-23 18:14:25 + @@ -59,6 +59,15 @@ * Fixed bug #867262 (allow reuse of iterator over ExtFuncArgItemSequence) * Fixed bug #869024 (segmentation fault with node-reference) * Fixed bug #869025 (segmentation fault with node-reference) + * New node-reference module. References can be obtained for any node, and + different nodes cannot have the same identifier. + * Fixed bug #872697 (segmentation fault with validation of NMTOKENS) + * Added undo for node revalidation + * Optimization for count(collection()) expressions + * Fixed bug #872796 (validate-in-place can interfere with other update primitives) + * Fixed bug #872799 (validate-in-place can set incorrect types) + * Fixed bug #855715 (Invalid escaped characters in regex not caught) + * Fixed bug #868325 (fn:analyze-string fails with some recursive subgroups) * Fixed bug #872697 (segmentation fault with validation of NMTOKENS) * General index cannot be declared as unique if the type of its key is xs:anyAtomicType or xs:untypedAtomic. === modified file 'src/diagnostics/dict_XX_cpp.xq' --- src/diagnostics/dict_XX_cpp.xq 2011-08-05 02:21:55 + +++ src/diagnostics/dict_XX_cpp.xq 2011-11-23 18:14:25 + @@ -64,6 +64,7 @@ return string-join( ( util:copyright(), '#include "stdafx.h"', +'#include "zorba/config.h"', '#include "diagnostics/dict_impl.h"', '', 'namespace zorba {', === modified file 'src/diagnostics/pregenerated/dict_en.cpp' --- src/diagnostics/pregenerated/dict_en.cpp 2011-11-15 08:23:20 + +++ src/diagnostics/pregenerated/dict_en.cpp 2011-11-23 18:14:25 + @@ -20,6 +20,7 @@ */ #include "stdafx.h" +#include "zorba/config.h" #include "diagnostics/dict_impl.h" namespace zorba { === modified file 'src/runtime/strings/strings_impl.cpp' --- src/runtime/strings/strings_impl.cpp 2011-11-18 17:42:47 + +++ src/runtime/strings/strings_impl.cpp 2011-11-23 18:14:25 + @@ -1830,7 +1830,7 @@ GENV_ITEMFACTORY->createString(strid_item, zstrid); store::Item_t id_attrib_item; GENV_ITEMFACTORY->createAttributeNode(id_attrib_item, group_elem.getp(), nr_attrib_name, untyped_type_name, strid_item); -if(match_startg < 0) +if((match_startg < 0) || (match_startg < match_endgood)) continue; match_endgood = match_endg; if((i+1)http://www.w3.org/2005/xpath-functions";>ac \ No newline at end of file === added directory 'test/rbkt/Queries/zorba/string/Regex' === added file 'test/rbkt/Queries/zorba/string/Regex/regex_a4.xq' --- test/rbkt/Queries/zorba/string/Regex/regex_a4.xq 1970-01-01 00:00:00 + +++ test/rbkt/Queries/zorba/string/Regex/regex_a4.xq 2011-11-23 18:14:25 + @@ -0,0 +1,1 @@ +fn:analyze-string("ac", "((a)|(c))+") \ No newline at end of file -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
Re: [Zorba-coders] [Merge] lp:~danielturcanu/zorba/mytrunk into lp:zorba
Yes, it would compile, but with the wrong error messages. The way Paul implemented it, it doesn't raise compile errors if the error messages are incorrect. I don't know if it raises runtime errors. So that include is necessary right now, it was necessary for some time ago. -- https://code.launchpad.net/~danielturcanu/zorba/mytrunk/+merge/79165 Your team Zorba Coders is subscribed to branch lp:zorba. -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
Re: [Zorba-coders] [Merge] lp:~zorba-coders/zorba/bug_882002 into lp:zorba
Review: Approve Ok -- https://code.launchpad.net/~zorba-coders/zorba/bug_882002/+merge/80454 Your team Zorba Coders is subscribed to branch lp:zorba. -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
Re: [Zorba-coders] [Merge] lp:~danielturcanu/zorba/mytrunk into lp:zorba
True, that change is not related to fn:analyze-string. It only solves the error messages included inside #if defined. -- https://code.launchpad.net/~danielturcanu/zorba/mytrunk/+merge/79165 Your team Zorba Coders is subscribed to branch lp:zorba. -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
[Zorba-coders] [Merge] lp:~danielturcanu/zorba/plan-serializer into lp:zorba
The proposal to merge lp:~danielturcanu/zorba/plan-serializer into lp:zorba has been updated. Status: Needs review => Approved For more details, see: https://code.launchpad.net/~danielturcanu/zorba/plan-serializer/+merge/79528 -- https://code.launchpad.net/~danielturcanu/zorba/plan-serializer/+merge/79528 Your team Zorba Coders is requested to review the proposed merge of lp:~danielturcanu/zorba/plan-serializer into lp:zorba. -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
[Zorba-coders] [Merge] lp:~danielturcanu/zorba/plan-serializer into lp:zorba
Daniel Turcanu has proposed merging lp:~danielturcanu/zorba/plan-serializer into lp:zorba. Requested reviews: Zorba Coders (zorba-coders) For more details, see: https://code.launchpad.net/~danielturcanu/zorba/plan-serializer/+merge/79528 Fixed bug #872850 about plan serializer crash Updated unit test -- https://code.launchpad.net/~danielturcanu/zorba/plan-serializer/+merge/79528 Your team Zorba Coders is requested to review the proposed merge of lp:~danielturcanu/zorba/plan-serializer into lp:zorba. === modified file 'ChangeLog' --- ChangeLog 2011-10-12 21:30:46 + +++ ChangeLog 2011-10-17 09:50:23 + @@ -52,6 +52,7 @@ * Added undo for node revalidation * Fixed bug #872796 (validate-in-place can interfere with other update primitives) * Fixed bug #872799 (validate-in-place can set incorrect types) + * Fixed bug #872850 (Serialization of Tumbling Window For fails) version 2.0.1 === modified file 'src/compiler/expression/expr.cpp' --- src/compiler/expression/expr.cpp 2011-09-16 19:36:18 + +++ src/compiler/expression/expr.cpp 2011-10-17 09:50:23 + @@ -1402,7 +1402,7 @@ void eval_expr::serialize(::zorba::serialization::Archiver& ar) { - serialize_baseclass(ar, (expr*)this); + serialize_baseclass(ar, (namespace_context_base_expr*)this); ar & theExpr; ar & theVars; ar & theArgs; === modified file 'src/compiler/expression/flwor_expr.cpp' --- src/compiler/expression/flwor_expr.cpp 2011-08-15 14:17:09 + +++ src/compiler/expression/flwor_expr.cpp 2011-10-17 09:50:23 + @@ -70,6 +70,12 @@ SERIALIZABLE_CLASS_VERSIONS(flwor_expr) END_SERIALIZABLE_CLASS_VERSIONS(flwor_expr) +SERIALIZABLE_CLASS_VERSIONS(flwor_wincond) +END_SERIALIZABLE_CLASS_VERSIONS(flwor_wincond) + +SERIALIZABLE_CLASS_VERSIONS(flwor_wincond::vars) +END_SERIALIZABLE_CLASS_VERSIONS(flwor_wincond::vars) + DEF_EXPR_ACCEPT (flwor_expr) @@ -530,6 +536,25 @@ set_flwor_clause(NULL); } +void flwor_wincond::serialize(::zorba::serialization::Archiver& ar) +{ + ar & theIsOnly; + ar & theInputVars; + ar & theOutputVars; + ar & theCondExpr; +} + +void flwor_wincond::vars::serialize(::zorba::serialization::Archiver& ar) +{ + ar & posvar; + ar & curr; + ar & prev; + ar & next; +} + +flwor_wincond::vars::vars() +{ +} flwor_wincond::vars::~vars() { === modified file 'src/compiler/expression/flwor_expr.h' --- src/compiler/expression/flwor_expr.h 2011-08-15 14:17:09 + +++ src/compiler/expression/flwor_expr.h 2011-10-17 09:50:23 + @@ -360,19 +360,24 @@ friend class ExprIterator; public: - struct vars + struct vars : public SerializeBaseClass { var_expr_t posvar; var_expr_t curr; var_expr_t prev; var_expr_t next; +vars(); ~vars(); void set_flwor_clause(flwor_clause* c); void clone(vars& cloneVars, expr::substitution_t& subst) const; std::ostream& put(std::ostream&) const; + public: +SERIALIZABLE_CLASS(vars) +SERIALIZABLE_CLASS_CONSTRUCTOR(vars) +void serialize(::zorba::serialization::Archiver& ar); }; protected: @@ -382,6 +387,11 @@ expr_t theCondExpr; public: + SERIALIZABLE_CLASS(flwor_wincond) + SERIALIZABLE_CLASS_CONSTRUCTOR2(flwor_wincond, SimpleRCObject) + void serialize(::zorba::serialization::Archiver& ar); + +public: flwor_wincond( static_context* sctx, bool isOnly, === added file 'test/rbkt/ExpQueryResults/zorba/windowing/windowing12.xml.res' --- test/rbkt/ExpQueryResults/zorba/windowing/windowing12.xml.res 1970-01-01 00:00:00 + +++ test/rbkt/ExpQueryResults/zorba/windowing/windowing12.xml.res 2011-10-17 09:50:23 + @@ -0,0 +1,1 @@ +1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 5253 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 3
Re: [Zorba-coders] [Merge] lp:~zorba-coders/zorba/geo-win-build into lp:zorba/geo-module
Now I found it, I added into the general FindGeos.cmake. -- https://code.launchpad.net/~zorba-coders/zorba/geo-win-build/+merge/78602 Your team Zorba Coders is subscribed to branch lp:zorba/geo-module. -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
Re: [Zorba-coders] [Merge] lp:~zorba-coders/zorba/geo-win-build into lp:zorba/geo-module
FindGEOS.cmake from Windows should be made to search for libgeos.lib . I looked into it but I don't know how to do that. -- https://code.launchpad.net/~zorba-coders/zorba/geo-win-build/+merge/78602 Your team Zorba Coders is subscribed to branch lp:zorba/geo-module. -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
Re: [Zorba-coders] [Merge] lp:~danielturcanu/zorba/plan-serializer into lp:zorba
1. What I did was fixing the plan serializer. This means running all the zorba tests and making them work. If it doesn't belong to the tumbling windows, then it's probably another failing test. 2. If that test already exist, I will delete it. -- https://code.launchpad.net/~danielturcanu/zorba/plan-serializer/+merge/79162 Your team Zorba Coders is requested to review the proposed merge of lp:~danielturcanu/zorba/plan-serializer into lp:zorba. -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
[Zorba-coders] [Merge] lp:~danielturcanu/zorba/web_crawler_tutorial into lp:zorba
Daniel Turcanu has proposed merging lp:~danielturcanu/zorba/web_crawler_tutorial into lp:zorba. Requested reviews: Sorin Marian Nasoi (sorin.marian.nasoi) For more details, see: https://code.launchpad.net/~danielturcanu/zorba/web_crawler_tutorial/+merge/79407 Updated the web crawler tutorial with the latest updates in link_crawler2.xq -- https://code.launchpad.net/~danielturcanu/zorba/web_crawler_tutorial/+merge/79407 Your team Zorba Coders is subscribed to branch lp:zorba. === added file 'doc/zorba/link_crawler2.dox' --- doc/zorba/link_crawler2.dox 1970-01-01 00:00:00 + +++ doc/zorba/link_crawler2.dox 2011-10-14 15:00:48 + @@ -0,0 +1,238 @@ +/** +\page link_crawler2 Web Crawler example in XQuery +\code +(: + : Copyright 2006-2011 The FLWOR Foundation. + : + : Licensed under the Apache License, Version 2.0 (the "License"); + : you may not use this file except in compliance with the License. + : You may obtain a copy of the License at + : + : http://www.apache.org/licenses/LICENSE-2.0 + : + : Unless required by applicable law or agreed to in writing, software + : distributed under the License is distributed on an "AS IS" BASIS, + : WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + : See the License for the specific language governing permissions and + : limitations under the License. +:) + +import module namespace http = "http://www.zorba-xquery.com/modules/http-client";; +import module namespace map = "http://www.zorba-xquery.com/modules/store/data-structures/unordered-map";; +import module namespace html = "http://www.zorba-xquery.com/modules/converters/html";; +import module namespace parse-xml = "http://www.zorba-xquery.com/modules/xml";; +import module namespace file = "http://expath.org/ns/file";; + +declare namespace ann = "http://www.zorba-xquery.com/annotations";; +declare namespace xhtml="http://www.w3.org/1999/xhtml";; +declare namespace output="http://www.w3.org/2010/xslt-xquery-serialization";; +declare namespace err="http://www.w3.org/2005/xqt-errors";; +declare namespace httpsch = "http://expath.org/ns/http-client";; + +declare variable $top-uri as xs:string := "http://www.zorba-xquery.com/site2/html/index.html";; +declare variable $uri-host as xs:string := "http://www.zorba-xquery.com";; + + + +declare variable $local:processed-internal-links := xs:QName("processed-internal-links"); +declare variable $local:processed-external-links := xs:QName("processed-external-links"); + + +declare %ann:sequential function local:create-containers() +{ + map:create($local:processed-internal-links, xs:QName("xs:string")); + map:create($local:processed-external-links, xs:QName("xs:string")); +}; + +declare %ann:sequential function local:delete-containers(){ + for $x in map:available-maps() + return map:delete($x); +}; + +declare function local:is-internal($x as xs:string) as xs:boolean +{ + starts-with($x, $uri-host) +}; + +declare function local:my-substring-before($s1 as xs:string, $s2 as xs:string) as xs:string +{ +let $sb := fn:substring-before($s1, $s2) +return if($sb = "") then $s1 else $sb +}; + +declare %ann:sequential function local:get-real-link($href as xs:string, $start-uri as xs:string) as xs:string? +{ + variable $absuri; + try{ +$absuri := local:my-substring-before(resolve-uri(fn:normalize-space($href), $start-uri), "#"); + } + catch * + { + map:insert($local:processed-external-links, ({$start-uri}, + malformed, + broken), $href); + } + $absuri +}; + + +declare function local:get-media-type ($http-call as node()) as xs:string +{ + local:my-substring-before($http-call/httpsch:header[@name = 'Content-Type'][1]/string(@value), ";") +}; + +declare function local:alive($http-call as item()*) as xs:boolean +{ + if((count($http-call) ge 1) and +($http-call[1]/@status eq 200)) + then true() else fn:trace(false(), "alive") +}; + + +declare %ann:sequential function local:get-out-links-parsed($content as node()*, $uri as xs:string) as xs:string* +{ distinct-values( for $y in ($content//*:a/string(@href), + $content//*:link/string(@href), + $content//*:script/string(@src), + $content//*:img/string(@src), + $content//*:area/string(@href) + ) +return local:get-real-link($y, $uri)) +}; + + +declare %ann:sequential function local:get-out-links-unparsed($content as xs:string, $uri as xs:string) as xs:string*{ + + distinct-values( + let $search := fn:analyze-string($content, "(<|<|<)(((a|link|area).+?href)|((scr
[Zorba-coders] [Merge] lp:~danielturcanu/zorba/my_conv_module into lp:zorba/data-converters-module
The proposal to merge lp:~danielturcanu/zorba/my_conv_module into lp:zorba/data-converters-module has been updated. Status: Needs review => Approved For more details, see: https://code.launchpad.net/~danielturcanu/zorba/my_conv_module/+merge/79390 -- https://code.launchpad.net/~danielturcanu/zorba/my_conv_module/+merge/79390 Your team Zorba Coders is requested to review the proposed merge of lp:~danielturcanu/zorba/my_conv_module into lp:zorba/data-converters-module. -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
[Zorba-coders] [Merge] lp:~danielturcanu/zorba/my_conv_module into lp:zorba/data-converters-module
Daniel Turcanu has proposed merging lp:~danielturcanu/zorba/my_conv_module into lp:zorba/data-converters-module. Requested reviews: Zorba Coders (zorba-coders) For more details, see: https://code.launchpad.net/~danielturcanu/zorba/my_conv_module/+merge/79390 Updated link_crawler to display FROM, STATUS, RESULT for each link -- https://code.launchpad.net/~danielturcanu/zorba/my_conv_module/+merge/79390 Your team Zorba Coders is requested to review the proposed merge of lp:~danielturcanu/zorba/my_conv_module into lp:zorba/data-converters-module. === modified file 'test_html/Queries/converters/html/link_crawler2.xq2' --- test_html/Queries/converters/html/link_crawler2.xq2 2011-10-06 07:40:17 + +++ test_html/Queries/converters/html/link_crawler2.xq2 2011-10-14 10:56:25 + @@ -18,6 +18,7 @@ import module namespace map = "http://www.zorba-xquery.com/modules/store/data-structures/unordered-map";; import module namespace html = "http://www.zorba-xquery.com/modules/converters/html";; import module namespace parse-xml = "http://www.zorba-xquery.com/modules/xml";; +import module namespace file = "http://expath.org/ns/file";; declare namespace ann = "http://www.zorba-xquery.com/annotations";; declare namespace xhtml="http://www.w3.org/1999/xhtml";; @@ -26,15 +27,12 @@ declare namespace httpsch = "http://expath.org/ns/http-client";; declare variable $top-uri as xs:string := "http://www.zorba-xquery.com/site2/html/index.html";; -declare variable $uri-host as xs:string := "http://www.zorba-xquery.com/site2/";; - - -declare variable $supported-media-types as xs:string+ := ("text/xml", "application/xml", "text/xml-external-parsed-entity", "application/xml-external-parsed-entity", - "application/atom+xml", "text/html"); - - -declare variable $local:processed-internal-links:=xs:QName("processed-internal-links"); -declare variable $local:processed-external-links :=xs:QName("processed-external-links"); +declare variable $uri-host as xs:string := "http://www.zorba-xquery.com";; + + + +declare variable $local:processed-internal-links := xs:QName("processed-internal-links"); +declare variable $local:processed-external-links := xs:QName("processed-external-links"); declare %ann:sequential function local:create-containers() @@ -59,9 +57,19 @@ return if($sb = "") then $s1 else $sb }; -declare function local:get-real-link($href as xs:string, $start-uri as xs:string) as xs:string +declare %ann:sequential function local:get-real-link($href as xs:string, $start-uri as xs:string) as xs:string? { - local:my-substring-before(resolve-uri($href, $start-uri), "#") + variable $absuri; + try{ +$absuri := local:my-substring-before(resolve-uri(fn:normalize-space($href), $start-uri), "#"); + } + catch * + { + map:insert($local:processed-external-links, ({$start-uri}, + malformed, + broken), $href); + } + $absuri }; @@ -70,13 +78,15 @@ local:my-substring-before($http-call/httpsch:header[@name = 'Content-Type'][1]/string(@value), ";") }; -declare function local:alive($http-call as node()*) as xs:boolean +declare function local:alive($http-call as item()*) as xs:boolean { - if(($http-call[1]/@status eq 200)) then true() else false() + if((count($http-call) ge 1) and +($http-call[1]/@status eq 200)) + then true() else fn:trace(false(), "alive") }; -declare function local:get-out-links-parsed($content as node()*, $uri as xs:string) as xs:string* +declare %ann:sequential function local:get-out-links-parsed($content as node()*, $uri as xs:string) as xs:string* { distinct-values( for $y in ($content//*:a/string(@href), $content//*:link/string(@href), $content//*:script/string(@src), @@ -87,30 +97,50 @@ }; -declare function local:get-out-links-unparsed($content as xs:string, $uri as xs:string) as xs:string*{ +declare %ann:sequential function local:get-out-links-unparsed($content as xs:string, $uri as xs:string) as xs:string*{ distinct-values( let $search := fn:analyze-string($content, "(<|<|<)(((a|link|area).+?href)|((script|img).+?src))=([""'])(.*?)\7") for $other-uri2 in $search//group[@nr=8]/string() - let $y:= fn:normalize-space($other-uri2) - return local:get-real-link($y, $uri) + return local:get-real-link($other-uri2, $uri) ) }; - -declare %ann:sequential function local:process-external-link($x as xs:string){ +declare %ann:sequential function local:map-insert-result($map-name as xs:QName, $url as
[Zorba-coders] [Merge] lp:~danielturcanu/zorba/mytrunk into lp:zorba
Daniel Turcanu has proposed merging lp:~danielturcanu/zorba/mytrunk into lp:zorba. Requested reviews: Chris Hillery (ceejatec) Matthias Brantner (matthias-brantner) For more details, see: https://code.launchpad.net/~danielturcanu/zorba/mytrunk/+merge/79165 fn:analyze-string fix Also removed useless test -- https://code.launchpad.net/~danielturcanu/zorba/mytrunk/+merge/79165 Your team Zorba Coders is subscribed to branch lp:zorba. === modified file 'ChangeLog' --- ChangeLog 2011-10-12 09:58:12 + +++ ChangeLog 2011-10-12 18:39:36 + @@ -50,6 +50,7 @@ different nodes cannot have the same identifier. * Fixed bug #872697 (segmentation fault with validation of NMTOKENS) * Added undo for node revalidation + * Fixed bug #868325 (fn:analyze-string fails with some recursive subgroups) version 2.0.1 === modified file 'src/diagnostics/dict_XX_cpp.xq' --- src/diagnostics/dict_XX_cpp.xq 2011-08-05 02:21:55 + +++ src/diagnostics/dict_XX_cpp.xq 2011-10-12 18:39:36 + @@ -64,6 +64,7 @@ return string-join( ( util:copyright(), '#include "stdafx.h"', +'#include "zorba/config.h"', '#include "diagnostics/dict_impl.h"', '', 'namespace zorba {', === modified file 'src/diagnostics/pregenerated/dict_en.cpp' --- src/diagnostics/pregenerated/dict_en.cpp 2011-10-05 17:49:48 + +++ src/diagnostics/pregenerated/dict_en.cpp 2011-10-12 18:39:36 + @@ -20,6 +20,7 @@ */ #include "stdafx.h" +#include "zorba/config.h" #include "diagnostics/dict_impl.h" namespace zorba { === modified file 'src/runtime/strings/strings_impl.cpp' --- src/runtime/strings/strings_impl.cpp 2011-08-10 18:58:11 + +++ src/runtime/strings/strings_impl.cpp 2011-10-12 18:39:36 + @@ -1688,7 +1688,7 @@ GENV_ITEMFACTORY->createString(strid_item, zstrid); store::Item_t id_attrib_item; GENV_ITEMFACTORY->createAttributeNode(id_attrib_item, group_elem.getp(), nr_attrib_name, untyped_type_name, strid_item); -if(match_startg < 0) +if((match_startg < 0) || (match_startg < match_endgood)) continue; match_endgood = match_endg; if((i+1)http://www.w3.org/2005/xpath-functions";>ac \ No newline at end of file === added directory 'test/rbkt/Queries/zorba/string/Regex' === added file 'test/rbkt/Queries/zorba/string/Regex/regex_a4.xq' --- test/rbkt/Queries/zorba/string/Regex/regex_a4.xq 1970-01-01 00:00:00 + +++ test/rbkt/Queries/zorba/string/Regex/regex_a4.xq 2011-10-12 18:39:36 + @@ -0,0 +1,1 @@ +fn:analyze-string("ac", "((a)|(c))+") \ No newline at end of file -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
[Zorba-coders] [Merge] lp:~danielturcanu/zorba/plan-serializer into lp:zorba
The proposal to merge lp:~danielturcanu/zorba/plan-serializer into lp:zorba has been updated. Status: Needs review => Approved For more details, see: https://code.launchpad.net/~danielturcanu/zorba/plan-serializer/+merge/79162 -- https://code.launchpad.net/~danielturcanu/zorba/plan-serializer/+merge/79162 Your team Zorba Coders is requested to review the proposed merge of lp:~danielturcanu/zorba/plan-serializer into lp:zorba. -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
[Zorba-coders] [Merge] lp:~danielturcanu/zorba/plan-serializer into lp:zorba
Daniel Turcanu has proposed merging lp:~danielturcanu/zorba/plan-serializer into lp:zorba. Requested reviews: Zorba Coders (zorba-coders) For more details, see: https://code.launchpad.net/~danielturcanu/zorba/plan-serializer/+merge/79162 Fixed bug #872850 about plan serializer crash -- https://code.launchpad.net/~danielturcanu/zorba/plan-serializer/+merge/79162 Your team Zorba Coders is requested to review the proposed merge of lp:~danielturcanu/zorba/plan-serializer into lp:zorba. === modified file 'ChangeLog' --- ChangeLog 2011-10-12 09:58:12 + +++ ChangeLog 2011-10-12 18:17:28 + @@ -50,6 +50,7 @@ different nodes cannot have the same identifier. * Fixed bug #872697 (segmentation fault with validation of NMTOKENS) * Added undo for node revalidation + * Fixed bug #872850 (Serialization of Tumbling Window For fails) version 2.0.1 === modified file 'src/compiler/expression/expr.cpp' --- src/compiler/expression/expr.cpp 2011-09-16 19:36:18 + +++ src/compiler/expression/expr.cpp 2011-10-12 18:17:28 + @@ -1402,7 +1402,7 @@ void eval_expr::serialize(::zorba::serialization::Archiver& ar) { - serialize_baseclass(ar, (expr*)this); + serialize_baseclass(ar, (namespace_context_base_expr*)this); ar & theExpr; ar & theVars; ar & theArgs; === modified file 'src/compiler/expression/flwor_expr.cpp' --- src/compiler/expression/flwor_expr.cpp 2011-08-15 14:17:09 + +++ src/compiler/expression/flwor_expr.cpp 2011-10-12 18:17:28 + @@ -70,6 +70,12 @@ SERIALIZABLE_CLASS_VERSIONS(flwor_expr) END_SERIALIZABLE_CLASS_VERSIONS(flwor_expr) +SERIALIZABLE_CLASS_VERSIONS(flwor_wincond) +END_SERIALIZABLE_CLASS_VERSIONS(flwor_wincond) + +SERIALIZABLE_CLASS_VERSIONS(flwor_wincond::vars) +END_SERIALIZABLE_CLASS_VERSIONS(flwor_wincond::vars) + DEF_EXPR_ACCEPT (flwor_expr) @@ -530,6 +536,25 @@ set_flwor_clause(NULL); } +void flwor_wincond::serialize(::zorba::serialization::Archiver& ar) +{ + ar & theIsOnly; + ar & theInputVars; + ar & theOutputVars; + ar & theCondExpr; +} + +void flwor_wincond::vars::serialize(::zorba::serialization::Archiver& ar) +{ + ar & posvar; + ar & curr; + ar & prev; + ar & next; +} + +flwor_wincond::vars::vars() +{ +} flwor_wincond::vars::~vars() { === modified file 'src/compiler/expression/flwor_expr.h' --- src/compiler/expression/flwor_expr.h 2011-08-15 14:17:09 + +++ src/compiler/expression/flwor_expr.h 2011-10-12 18:17:28 + @@ -360,19 +360,24 @@ friend class ExprIterator; public: - struct vars + struct vars : public SerializeBaseClass { var_expr_t posvar; var_expr_t curr; var_expr_t prev; var_expr_t next; +vars(); ~vars(); void set_flwor_clause(flwor_clause* c); void clone(vars& cloneVars, expr::substitution_t& subst) const; std::ostream& put(std::ostream&) const; + public: +SERIALIZABLE_CLASS(vars) +SERIALIZABLE_CLASS_CONSTRUCTOR(vars) +void serialize(::zorba::serialization::Archiver& ar); }; protected: @@ -382,6 +387,11 @@ expr_t theCondExpr; public: + SERIALIZABLE_CLASS(flwor_wincond) + SERIALIZABLE_CLASS_CONSTRUCTOR2(flwor_wincond, SimpleRCObject) + void serialize(::zorba::serialization::Archiver& ar); + +public: flwor_wincond( static_context* sctx, bool isOnly, === added file 'test/rbkt/ExpQueryResults/zorba/windowing/windowing12.xml.res' --- test/rbkt/ExpQueryResults/zorba/windowing/windowing12.xml.res 1970-01-01 00:00:00 + +++ test/rbkt/ExpQueryResults/zorba/windowing/windowing12.xml.res 2011-10-12 18:17:28 + @@ -0,0 +1,1 @@ +1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 5253 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343
[Zorba-coders] [Merge] lp:~danielturcanu/zorba/plan-serializer into lp:zorba
The proposal to merge lp:~danielturcanu/zorba/plan-serializer into lp:zorba has been updated. Status: Needs review => Approved For more details, see: https://code.launchpad.net/~danielturcanu/zorba/plan-serializer/+merge/79160 -- https://code.launchpad.net/~danielturcanu/zorba/plan-serializer/+merge/79160 Your team Zorba Coders is requested to review the proposed merge of lp:~danielturcanu/zorba/plan-serializer into lp:zorba. -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
[Zorba-coders] [Merge] lp:~danielturcanu/zorba/plan-serializer into lp:zorba
Daniel Turcanu has proposed merging lp:~danielturcanu/zorba/plan-serializer into lp:zorba. Requested reviews: Zorba Coders (zorba-coders) For more details, see: https://code.launchpad.net/~danielturcanu/zorba/plan-serializer/+merge/79160 Fixed bug #872850 about plan serializer crash -- https://code.launchpad.net/~danielturcanu/zorba/plan-serializer/+merge/79160 Your team Zorba Coders is requested to review the proposed merge of lp:~danielturcanu/zorba/plan-serializer into lp:zorba. === modified file 'ChangeLog' --- ChangeLog 2011-10-12 09:58:12 + +++ ChangeLog 2011-10-12 17:53:34 + @@ -49,7 +49,11 @@ * New node-reference module. References can be obtained for any node, and different nodes cannot have the same identifier. * Fixed bug #872697 (segmentation fault with validation of NMTOKENS) +<<<<<<< TREE * Added undo for node revalidation +=== + * Fixed bug #872850 (Serialization of Tumbling Window For fails) +>>>>>>> MERGE-SOURCE version 2.0.1 === modified file 'src/compiler/expression/expr.cpp' --- src/compiler/expression/expr.cpp 2011-09-16 19:36:18 + +++ src/compiler/expression/expr.cpp 2011-10-12 17:53:34 + @@ -1402,7 +1402,7 @@ void eval_expr::serialize(::zorba::serialization::Archiver& ar) { - serialize_baseclass(ar, (expr*)this); + serialize_baseclass(ar, (namespace_context_base_expr*)this); ar & theExpr; ar & theVars; ar & theArgs; === modified file 'src/compiler/expression/flwor_expr.cpp' --- src/compiler/expression/flwor_expr.cpp 2011-08-15 14:17:09 + +++ src/compiler/expression/flwor_expr.cpp 2011-10-12 17:53:34 + @@ -70,6 +70,12 @@ SERIALIZABLE_CLASS_VERSIONS(flwor_expr) END_SERIALIZABLE_CLASS_VERSIONS(flwor_expr) +SERIALIZABLE_CLASS_VERSIONS(flwor_wincond) +END_SERIALIZABLE_CLASS_VERSIONS(flwor_wincond) + +SERIALIZABLE_CLASS_VERSIONS(flwor_wincond::vars) +END_SERIALIZABLE_CLASS_VERSIONS(flwor_wincond::vars) + DEF_EXPR_ACCEPT (flwor_expr) @@ -530,6 +536,25 @@ set_flwor_clause(NULL); } +void flwor_wincond::serialize(::zorba::serialization::Archiver& ar) +{ + ar & theIsOnly; + ar & theInputVars; + ar & theOutputVars; + ar & theCondExpr; +} + +void flwor_wincond::vars::serialize(::zorba::serialization::Archiver& ar) +{ + ar & posvar; + ar & curr; + ar & prev; + ar & next; +} + +flwor_wincond::vars::vars() +{ +} flwor_wincond::vars::~vars() { === modified file 'src/compiler/expression/flwor_expr.h' --- src/compiler/expression/flwor_expr.h 2011-08-15 14:17:09 + +++ src/compiler/expression/flwor_expr.h 2011-10-12 17:53:34 + @@ -360,19 +360,24 @@ friend class ExprIterator; public: - struct vars + struct vars : public SerializeBaseClass { var_expr_t posvar; var_expr_t curr; var_expr_t prev; var_expr_t next; +vars(); ~vars(); void set_flwor_clause(flwor_clause* c); void clone(vars& cloneVars, expr::substitution_t& subst) const; std::ostream& put(std::ostream&) const; + public: +SERIALIZABLE_CLASS(vars) +SERIALIZABLE_CLASS_CONSTRUCTOR(vars) +void serialize(::zorba::serialization::Archiver& ar); }; protected: @@ -382,6 +387,11 @@ expr_t theCondExpr; public: + SERIALIZABLE_CLASS(flwor_wincond) + SERIALIZABLE_CLASS_CONSTRUCTOR2(flwor_wincond, SimpleRCObject) + void serialize(::zorba::serialization::Archiver& ar); + +public: flwor_wincond( static_context* sctx, bool isOnly, === added file 'test/rbkt/ExpQueryResults/zorba/windowing/windowing12.xml.res' --- test/rbkt/ExpQueryResults/zorba/windowing/windowing12.xml.res 1970-01-01 00:00:00 + +++ test/rbkt/ExpQueryResults/zorba/windowing/windowing12.xml.res 2011-10-12 17:53:34 + @@ -0,0 +1,1 @@ +1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 5253 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 30
Re: [Zorba-coders] [Merge] lp:~danielturcanu/zorba/mytrunk into lp:zorba
There are a lot of #if defined and #if !defined in that file. -- https://code.launchpad.net/~danielturcanu/zorba/mytrunk/+merge/79120 Your team Zorba Coders is subscribed to branch lp:zorba. -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
Re: [Zorba-coders] [Merge] lp:~danielturcanu/zorba/mytrunk into lp:zorba
The #include is necessary to have access to zorba settings. -- https://code.launchpad.net/~danielturcanu/zorba/mytrunk/+merge/79120 Your team Zorba Coders is subscribed to branch lp:zorba. -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
[Zorba-coders] [Merge] lp:~danielturcanu/zorba/mytrunk into lp:zorba
Daniel Turcanu has proposed merging lp:~danielturcanu/zorba/mytrunk into lp:zorba. Requested reviews: Chris Hillery (ceejatec) Matthias Brantner (matthias-brantner) For more details, see: https://code.launchpad.net/~danielturcanu/zorba/mytrunk/+merge/79120 fn:analyze-string fix Also removed useless test -- https://code.launchpad.net/~danielturcanu/zorba/mytrunk/+merge/79120 Your team Zorba Coders is subscribed to branch lp:zorba. === modified file 'ChangeLog' --- ChangeLog 2011-10-12 09:20:36 + +++ ChangeLog 2011-10-12 13:08:19 + @@ -48,7 +48,11 @@ * Fixed bug #869025 (segmentation fault with node-reference) * New node-reference module. References can be obtained for any node, and different nodes cannot have the same identifier. +<<<<<<< TREE * Fixed bug #872697 (segmentation fault with validation of NMTOKENS) +=== + * Fixed bug #868325 (fn:analyze-string fails with some recursive subgroups) +>>>>>>> MERGE-SOURCE version 2.0.1 === modified file 'src/diagnostics/dict_XX_cpp.xq' --- src/diagnostics/dict_XX_cpp.xq 2011-08-05 02:21:55 + +++ src/diagnostics/dict_XX_cpp.xq 2011-10-12 13:08:19 + @@ -64,6 +64,7 @@ return string-join( ( util:copyright(), '#include "stdafx.h"', +'#include "zorba/config.h"', '#include "diagnostics/dict_impl.h"', '', 'namespace zorba {', === modified file 'src/diagnostics/pregenerated/dict_en.cpp' --- src/diagnostics/pregenerated/dict_en.cpp 2011-10-05 17:49:48 + +++ src/diagnostics/pregenerated/dict_en.cpp 2011-10-12 13:08:19 + @@ -20,6 +20,7 @@ */ #include "stdafx.h" +#include "zorba/config.h" #include "diagnostics/dict_impl.h" namespace zorba { === modified file 'src/runtime/strings/strings_impl.cpp' --- src/runtime/strings/strings_impl.cpp 2011-08-10 18:58:11 + +++ src/runtime/strings/strings_impl.cpp 2011-10-12 13:08:19 + @@ -1688,7 +1688,7 @@ GENV_ITEMFACTORY->createString(strid_item, zstrid); store::Item_t id_attrib_item; GENV_ITEMFACTORY->createAttributeNode(id_attrib_item, group_elem.getp(), nr_attrib_name, untyped_type_name, strid_item); -if(match_startg < 0) +if((match_startg < 0) || (match_startg < match_endgood)) continue; match_endgood = match_endg; if((i+1)http://www.w3.org/2005/xpath-functions";>ac \ No newline at end of file === added directory 'test/rbkt/Queries/zorba/string/Regex' === added file 'test/rbkt/Queries/zorba/string/Regex/regex_a4.xq' --- test/rbkt/Queries/zorba/string/Regex/regex_a4.xq 1970-01-01 00:00:00 + +++ test/rbkt/Queries/zorba/string/Regex/regex_a4.xq 2011-10-12 13:08:19 + @@ -0,0 +1,1 @@ +fn:analyze-string("ac", "((a)|(c))+") \ No newline at end of file -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
Re: [Zorba-coders] [Merge] lp:~ceejatec/zorba/xslt-schema-w3c-bugfix into lp:zorba
Review: Approve Ok -- https://code.launchpad.net/~ceejatec/zorba/xslt-schema-w3c-bugfix/+merge/79068 Your team Zorba Coders is subscribed to branch lp:zorba. -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
[Zorba-coders] [Bug 867040] Re: Most Geo tests failing on Windows (segfaults + fail)
GEOS library is not prepared to be a DLL. Use the static library. -- You received this bug notification because you are a member of Zorba Coders, which is the registrant for Zorba. https://bugs.launchpad.net/bugs/867040 Title: Most Geo tests failing on Windows (segfaults + fail) Status in Zorba - The XQuery Processor: Unknown Bug description: There are 7 geo module tests which are failing. I don't know if these were already failing, or whether this might be a side-effect of moving the module outside of Zorba, but I need to register a bug to track them so I can mark them as EXPECTED_FAILURE(). To manage notifications about this bug go to: https://bugs.launchpad.net/zorba/+bug/867040/+subscriptions -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
[Zorba-coders] [Bug 868329] Re: URI resolver does not work well on Windows
A solution to this would be to add another function in file module for resolving a file path with a given absolute URI. file:path-to-uri($baseUri, $filePath) So file:path-to-uri("file:///C%3A/path/file1", "e:/path2/file2") would produce "file:///E%3A/path2/file2" ** Changed in: zorba Assignee: Daniel Turcanu (danielturcanu) => Gabriel Petrovay (gabipetrovay) -- You received this bug notification because you are a member of Zorba Coders, which is the registrant for Zorba. https://bugs.launchpad.net/bugs/868329 Title: URI resolver does not work well on Windows Status in Zorba - The XQuery Processor: New Bug description: When resolving a Windows absolute path relative to another URI, URI resolver cannot see that it is an absolute path (does not check for C:\) and treats it as relative path. It only checks for Linux style absolute paths. See test zorba/resolving/path_to_uri.xq in branch lp:~danielturcanu/zorba/mytrunk To manage notifications about this bug go to: https://bugs.launchpad.net/zorba/+bug/868329/+subscriptions -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
Re: [Zorba-coders] [Merge] lp:~danielturcanu/zorba/mytrunk into lp:zorba
See bug https://bugs.launchpad.net/zorba/+bug/868329 -- https://code.launchpad.net/~danielturcanu/zorba/mytrunk/+merge/78996 Your team Zorba Coders is subscribed to branch lp:zorba. -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
[Zorba-coders] [Merge] lp:~danielturcanu/zorba/mytrunk into lp:zorba
Daniel Turcanu has proposed merging lp:~danielturcanu/zorba/mytrunk into lp:zorba. Requested reviews: Zorba Coders (zorba-coders) For more details, see: https://code.launchpad.net/~danielturcanu/zorba/mytrunk/+merge/78996 fn:analyze-string fix -- https://code.launchpad.net/~danielturcanu/zorba/mytrunk/+merge/78996 Your team Zorba Coders is requested to review the proposed merge of lp:~danielturcanu/zorba/mytrunk into lp:zorba. === modified file 'ChangeLog' --- ChangeLog 2011-10-10 19:29:05 + +++ ChangeLog 2011-10-11 15:11:39 + @@ -46,6 +46,7 @@ * Fixed bug #869025 (segmentation fault with node-reference) * New node-reference module. References can be obtained for any node, and different nodes cannot have the same identifier. + * Fixed bug #868325 (fn:analyze-string fails with some recursive subgroups) version 2.0.1 === modified file 'src/diagnostics/dict_XX_cpp.xq' --- src/diagnostics/dict_XX_cpp.xq 2011-08-05 02:21:55 + +++ src/diagnostics/dict_XX_cpp.xq 2011-10-11 15:11:39 + @@ -64,6 +64,7 @@ return string-join( ( util:copyright(), '#include "stdafx.h"', +'#include "zorba/config.h"', '#include "diagnostics/dict_impl.h"', '', 'namespace zorba {', === modified file 'src/diagnostics/pregenerated/dict_en.cpp' --- src/diagnostics/pregenerated/dict_en.cpp 2011-10-05 17:49:48 + +++ src/diagnostics/pregenerated/dict_en.cpp 2011-10-11 15:11:39 + @@ -20,6 +20,7 @@ */ #include "stdafx.h" +#include "zorba/config.h" #include "diagnostics/dict_impl.h" namespace zorba { === modified file 'src/runtime/strings/strings_impl.cpp' --- src/runtime/strings/strings_impl.cpp 2011-08-10 18:58:11 + +++ src/runtime/strings/strings_impl.cpp 2011-10-11 15:11:39 + @@ -1688,7 +1688,7 @@ GENV_ITEMFACTORY->createString(strid_item, zstrid); store::Item_t id_attrib_item; GENV_ITEMFACTORY->createAttributeNode(id_attrib_item, group_elem.getp(), nr_attrib_name, untyped_type_name, strid_item); -if(match_startg < 0) +if((match_startg < 0) || (match_startg < match_endgood)) continue; match_endgood = match_endg; if((i+1) \ No newline at end of file === added directory 'test/rbkt/ExpQueryResults/zorba/string/Regex' === added file 'test/rbkt/ExpQueryResults/zorba/string/Regex/regex_a4.xml.res' --- test/rbkt/ExpQueryResults/zorba/string/Regex/regex_a4.xml.res 1970-01-01 00:00:00 + +++ test/rbkt/ExpQueryResults/zorba/string/Regex/regex_a4.xml.res 2011-10-11 15:11:39 + @@ -0,0 +1,1 @@ +http://www.w3.org/2005/xpath-functions";>ac \ No newline at end of file === added file 'test/rbkt/Queries/zorba/resolving/path_to_uri.spec' --- test/rbkt/Queries/zorba/resolving/path_to_uri.spec 1970-01-01 00:00:00 + +++ test/rbkt/Queries/zorba/resolving/path_to_uri.spec 2011-10-11 15:11:39 + @@ -0,0 +1,4 @@ +Args: +-x +input-context:=xs:string($RBKT_SRC_DIR/Queries/zorba/resolving/test.xml) + === added file 'test/rbkt/Queries/zorba/resolving/path_to_uri.xq' --- test/rbkt/Queries/zorba/resolving/path_to_uri.xq 1970-01-01 00:00:00 + +++ test/rbkt/Queries/zorba/resolving/path_to_uri.xq 2011-10-11 15:11:39 + @@ -0,0 +1,4 @@ +import module namespace file = "http://expath.org/ns/file";; +declare variable $input-context as xs:string external; + +fn:doc(fn:resolve-uri("test.xml")) === added file 'test/rbkt/Queries/zorba/resolving/test.xml' --- test/rbkt/Queries/zorba/resolving/test.xml 1970-01-01 00:00:00 + +++ test/rbkt/Queries/zorba/resolving/test.xml 2011-10-11 15:11:39 + @@ -0,0 +1,1 @@ + \ No newline at end of file === added directory 'test/rbkt/Queries/zorba/string/Regex' === added file 'test/rbkt/Queries/zorba/string/Regex/regex_a4.xq' --- test/rbkt/Queries/zorba/string/Regex/regex_a4.xq 1970-01-01 00:00:00 + +++ test/rbkt/Queries/zorba/string/Regex/regex_a4.xq 2011-10-11 15:11:39 + @@ -0,0 +1,1 @@ +fn:analyze-string("ac", "((a)|(c))+") \ No newline at end of file -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
[Zorba-coders] [Merge] lp:~danielturcanu/zorba/https-win into lp:zorba
The proposal to merge lp:~danielturcanu/zorba/https-win into lp:zorba has been updated. Status: Needs review => Approved For more details, see: https://code.launchpad.net/~danielturcanu/zorba/https-win/+merge/78982 -- https://code.launchpad.net/~danielturcanu/zorba/https-win/+merge/78982 Your team Zorba Coders is requested to review the proposed merge of lp:~danielturcanu/zorba/https-win into lp:zorba. -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
[Zorba-coders] [Merge] lp:~danielturcanu/zorba/https-win into lp:zorba
Daniel Turcanu has proposed merging lp:~danielturcanu/zorba/https-win into lp:zorba. Requested reviews: Zorba Coders (zorba-coders) For more details, see: https://code.launchpad.net/~danielturcanu/zorba/https-win/+merge/78982 Making https work on Windows. Possibly that it also needs fixing on Linux. -- https://code.launchpad.net/~danielturcanu/zorba/https-win/+merge/78982 Your team Zorba Coders is requested to review the proposed merge of lp:~danielturcanu/zorba/https-win into lp:zorba. === modified file 'modules/com/zorba-xquery/www/modules/http-client.xq.src/http_client.cpp' --- modules/com/zorba-xquery/www/modules/http-client.xq.src/http_client.cpp 2011-07-29 08:12:36 + +++ modules/com/zorba-xquery/www/modules/http-client.xq.src/http_client.cpp 2011-10-11 14:25:57 + @@ -53,7 +53,10 @@ # endif aPath = lPath.substr(0, lPath.rfind('\\')); aPath += "\\cacert.pem"; - curl_easy_setopt(lCurl, CURLOPT_CAINFO, aPath.c_str()); + if(GetFileAttributesA(aPath.c_str()) != INVALID_FILE_ATTRIBUTES) + curl_easy_setopt(lCurl, CURLOPT_CAINFO, aPath.c_str()); + else +curl_easy_setopt(lCurl, CURLOPT_SSL_VERIFYPEER, 0L); } #endif //WIN32 @@ -207,7 +210,7 @@ lOverrideContentType.c_str(), lStatusOnly)); int lRetCode = lRespParser->parse(); - if (lRetCode) { + if (lRetCode) { thrower.raiseException("http://expath.org/ns/error";, "HC001", "An HTTP error occurred"); } -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
[Zorba-coders] [Bug 872234] [NEW] problems with unordered map
Public bug reported: I guess there's a problem with the optimizer. Try the following code: import module namespace map = "http://www.zorba-xquery.com/modules/store/data-structures/unordered-map";; declare namespace ann = "http://www.zorba-xquery.com/annotations";; declare variable $local:processed-internal-links := xs:QName("processed-internal-links"); declare %ann:sequential function local:f1($n as xs:string) { map:insert($local:processed-internal-links, $n, $n); fn:trace($n, "n="); for $x in ("1", "2", "3") return if(fn:empty(map:get($local:processed-internal-links, $x))) then local:f1($x) else () }; map:create($local:processed-internal-links, xs:QName("xs:string")); local:f1("0") It should display 0 1 2 3 But it displays 0 1 2 3 3 2 3 ** Affects: zorba Importance: Undecided Assignee: Markos Zaharioudakis (markos-za) Status: New ** Changed in: zorba Assignee: (unassigned) => Markos Zaharioudakis (markos-za) -- You received this bug notification because you are a member of Zorba Coders, which is the registrant for Zorba. https://bugs.launchpad.net/bugs/872234 Title: problems with unordered map Status in Zorba - The XQuery Processor: New Bug description: I guess there's a problem with the optimizer. Try the following code: import module namespace map = "http://www.zorba-xquery.com/modules/store/data-structures/unordered-map";; declare namespace ann = "http://www.zorba-xquery.com/annotations";; declare variable $local:processed-internal-links := xs:QName("processed-internal-links"); declare %ann:sequential function local:f1($n as xs:string) { map:insert($local:processed-internal-links, $n, $n); fn:trace($n, "n="); for $x in ("1", "2", "3") return if(fn:empty(map:get($local:processed-internal-links, $x))) then local:f1($x) else () }; map:create($local:processed-internal-links, xs:QName("xs:string")); local:f1("0") It should display 0 1 2 3 But it displays 0 1 2 3 3 2 3 To manage notifications about this bug go to: https://bugs.launchpad.net/zorba/+bug/872234/+subscriptions -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
Re: [Zorba-coders] [Merge] lp:~gabipetrovay/zorba/geo-win-build into lp:zorba/geo-module
I set GEOS_LIBRARY to point to libgeos.lib instead of geos.lib. At least I prefer static libs. I didn't commit anything, I have to go through the same proposal process. Ok, good tip about install. -- https://code.launchpad.net/~gabipetrovay/zorba/geo-win-build/+merge/78602 Your team Zorba Coders is subscribed to branch lp:zorba/geo-module. -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
Re: [Zorba-coders] [Merge] lp:~gabipetrovay/zorba/geo-win-build into lp:zorba/geo-module
I updated geos to latest trunk, and indeed now it used CMake and builds the geos lib as dll. It is called geos.dll. But it also has geos_static project, so I used that for linking. I had to fix the build with the new code. You can leave FIND_PACKAGE_DLLS_WIN32 with geos.dll, it only raises a warning if it doesn't find it. One new issue I had is that now geos library has two include dirs: one in the source dir and one in the build directory. I had to add manualy the one from the build dir because it cannot be discovered. -- https://code.launchpad.net/~gabipetrovay/zorba/geo-win-build/+merge/78602 Your team Zorba Coders is subscribed to branch lp:zorba/geo-module. -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
[Zorba-coders] [Merge] lp:~danielturcanu/zorba/mytrunk into lp:zorba
The proposal to merge lp:~danielturcanu/zorba/mytrunk into lp:zorba has been updated. Status: Needs review => Approved For more details, see: https://code.launchpad.net/~danielturcanu/zorba/mytrunk/+merge/78621 -- https://code.launchpad.net/~danielturcanu/zorba/mytrunk/+merge/78621 Your team Zorba Coders is subscribed to branch lp:zorba. -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
[Zorba-coders] [Merge] lp:~danielturcanu/zorba/mytrunk into lp:zorba
Daniel Turcanu has proposed merging lp:~danielturcanu/zorba/mytrunk into lp:zorba. Requested reviews: Matthias Brantner (matthias-brantner) Chris Hillery (ceejatec) For more details, see: https://code.launchpad.net/~danielturcanu/zorba/mytrunk/+merge/78621 Removed changes for URI, left only changes for fn:analyze-string. -- https://code.launchpad.net/~danielturcanu/zorba/mytrunk/+merge/78621 Your team Zorba Coders is subscribed to branch lp:zorba. === modified file 'ChangeLog' --- ChangeLog 2011-10-05 22:39:18 + +++ ChangeLog 2011-10-07 15:18:36 + @@ -41,6 +41,8 @@ * Fixed bug #863730 (static delete-node* functions don't raise ZDDY0012) * Implemented the probe-index-range-value for general indexes * Fixed bug #867662 ("nullptr" warning) + * Fixed bug #868329 (URI resolver fails on Windows with absolute paths) + * Fixed bug #868325 (fn:analyze-string fails with some recursive subgroups) version 2.0.1 === modified file 'src/diagnostics/dict_XX_cpp.xq' --- src/diagnostics/dict_XX_cpp.xq 2011-08-05 02:21:55 + +++ src/diagnostics/dict_XX_cpp.xq 2011-10-07 15:18:36 + @@ -64,6 +64,7 @@ return string-join( ( util:copyright(), '#include "stdafx.h"', +'#include "zorba/config.h"', '#include "diagnostics/dict_impl.h"', '', 'namespace zorba {', === modified file 'src/diagnostics/pregenerated/dict_en.cpp' --- src/diagnostics/pregenerated/dict_en.cpp 2011-10-04 05:28:07 + +++ src/diagnostics/pregenerated/dict_en.cpp 2011-10-07 15:18:36 + @@ -20,6 +20,7 @@ */ #include "stdafx.h" +#include "zorba/config.h" #include "diagnostics/dict_impl.h" namespace zorba { === modified file 'src/runtime/strings/strings_impl.cpp' --- src/runtime/strings/strings_impl.cpp 2011-08-10 18:58:11 + +++ src/runtime/strings/strings_impl.cpp 2011-10-07 15:18:36 + @@ -1688,7 +1688,7 @@ GENV_ITEMFACTORY->createString(strid_item, zstrid); store::Item_t id_attrib_item; GENV_ITEMFACTORY->createAttributeNode(id_attrib_item, group_elem.getp(), nr_attrib_name, untyped_type_name, strid_item); -if(match_startg < 0) +if((match_startg < 0) || (match_startg < match_endgood)) continue; match_endgood = match_endg; if((i+1) -ZORBA_DLL_PUBLIC -unicode::code_point next_char( OctetIterator &i ); +ZORBA_DLL_PUBLIC unicode::code_point next_char( OctetIterator &i ); /** * Decodes the previous Unicode character. === modified file 'src/zorbatypes/URI.cpp' --- src/zorbatypes/URI.cpp 2011-06-24 23:00:33 + +++ src/zorbatypes/URI.cpp 2011-10-07 15:18:36 + @@ -1191,7 +1191,16 @@ return is_set(Scheme) && !theScheme.empty(); } - +bool URI::is_absolute_path(zstring &thePath) +{ +#ifndef WIN32 + return thePath[0] == '/'; +#else + return (thePath.length() > 2) && + ((thePath[1] == ':') || + ((thePath[1] == '%') && (thePath[2] == '3') && (thePath[3] == 'A'))); +#endif +} /*** @@ -1331,7 +1340,7 @@ // If the path component begins with a slash character ("/"), then // the reference is an absolute-path and we skip to step 7. - if ( (is_set(Path)) && (thePath[0] =='/') ) + if ( is_set(Path) && is_absolute_path(thePath) ) { invalidate_text(); return; @@ -1342,12 +1351,14 @@ if ( base_uri->is_set(Path) ) { -zstring::size_type last_slash = base_path.rfind("/"); -if ( last_slash != zstring::npos ) - path = base_path.substr(0, last_slash+1); -// else -//path = "/"; - +if(!is_absolute_path(thePath)) +{ + zstring::size_type last_slash = base_path.rfind("/"); + if ( last_slash != zstring::npos ) +path = base_path.substr(0, last_slash+1); + // else + //path = "/"; +} } // 6b - append the relative URI path === modified file 'src/zorbatypes/URI.h' --- src/zorbatypes/URI.h 2011-06-14 17:26:33 + +++ src/zorbatypes/URI.h 2011-10-07 15:18:36 + @@ -190,6 +190,8 @@ void unset_state(uint32_t s) const { theState &= ~s; } void invalidate_text() const; + + bool is_absolute_path(zstring &thePath); }; === added file 'test/rbkt/ExpQueryResults/zorba/resolving/path_to_uri.xml.res' --- test/rbkt/ExpQueryResults/zorba/resolving/path_to_uri.xml.res 1970-01-01 00:00:00 + +++ test/rbkt/ExpQueryResults/zorba/resolving/path_to_uri.xml.res 2011-10-07 15:18:36 + @@ -0,0 +1,1 @@ + \ No newline at end of file === added directory 'test/rbkt/ExpQueryResults/zorba/string/Regex' === added file 'test/rbkt/ExpQueryResults/zorba/s
[Zorba-coders] [Merge] lp:~danielturcanu/zorba/web_crawler_tutorial into lp:zorba
Daniel Turcanu has proposed merging lp:~danielturcanu/zorba/web_crawler_tutorial into lp:zorba. Requested reviews: Sorin Marian Nasoi (sorin.marian.nasoi) For more details, see: https://code.launchpad.net/~danielturcanu/zorba/web_crawler_tutorial/+merge/78614 Updated the web crawler tutorial with the latest fixes in link_crawler2.xq -- https://code.launchpad.net/~danielturcanu/zorba/web_crawler_tutorial/+merge/78614 Your team Zorba Coders is subscribed to branch lp:zorba. === added file 'doc/zorba/link_crawler2.dox' --- doc/zorba/link_crawler2.dox 1970-01-01 00:00:00 + +++ doc/zorba/link_crawler2.dox 2011-10-07 14:41:17 + @@ -0,0 +1,221 @@ +/** +\page link_crawler2 Web Crawler example in XQuery +\code +(: + : Copyright 2006-2011 The FLWOR Foundation. + : + : Licensed under the Apache License, Version 2.0 (the "License"); + : you may not use this file except in compliance with the License. + : You may obtain a copy of the License at + : + : http://www.apache.org/licenses/LICENSE-2.0 + : + : Unless required by applicable law or agreed to in writing, software + : distributed under the License is distributed on an "AS IS" BASIS, + : WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + : See the License for the specific language governing permissions and + : limitations under the License. +:) + +import module namespace http = "http://www.zorba-xquery.com/modules/http-client";; +import module namespace map = "http://www.zorba-xquery.com/modules/store/data-structures/unordered-map";; +import module namespace html = "http://www.zorba-xquery.com/modules/converters/html";; +import module namespace parse-xml = "http://www.zorba-xquery.com/modules/xml";; +import module namespace file = "http://expath.org/ns/file";; + +declare namespace ann = "http://www.zorba-xquery.com/annotations";; +declare namespace xhtml="http://www.w3.org/1999/xhtml";; +declare namespace output="http://www.w3.org/2010/xslt-xquery-serialization";; +declare namespace err="http://www.w3.org/2005/xqt-errors";; +declare namespace httpsch = "http://expath.org/ns/http-client";; + +declare variable $top-uri as xs:string := "http://www.zorba-xquery.com/site2/html/index.html";; +declare variable $uri-host as xs:string := "http://www.zorba-xquery.com/site2/";; + + + +declare variable $local:processed-internal-links := xs:QName("processed-internal-links"); +declare variable $local:processed-external-links := xs:QName("processed-external-links"); + + +declare %ann:sequential function local:create-containers() +{ + map:create($local:processed-internal-links, xs:QName("xs:string")); + map:create($local:processed-external-links, xs:QName("xs:string")); +}; + +declare %ann:sequential function local:delete-containers(){ + for $x in map:available-maps() + return map:delete($x); +}; + +declare function local:is-internal($x as xs:string) as xs:boolean +{ + starts-with($x, $uri-host) +}; + +declare function local:my-substring-before($s1 as xs:string, $s2 as xs:string) as xs:string +{ +let $sb := fn:substring-before($s1, $s2) +return if($sb = "") then $s1 else $sb +}; + +declare %ann:sequential function local:get-real-link($href as xs:string, $start-uri as xs:string) as xs:string? +{ + variable $absuri; + try{ +$absuri := local:my-substring-before(resolve-uri(fn:normalize-space($href), $start-uri), "#"); + } + catch * + { + map:insert($local:processed-external-links, fn:concat("malformed, referenced in page ", $start-uri), $href); + } + $absuri +}; + + +declare function local:get-media-type ($http-call as node()) as xs:string +{ + local:my-substring-before($http-call/httpsch:header[@name = 'Content-Type'][1]/string(@value), ";") +}; + +declare function local:alive($http-call as item()*) as xs:boolean +{ + if((count($http-call) ge 1) and +($http-call[1]/@status eq 200)) + then true() else fn:trace(false(), "alive") +}; + + +declare %ann:sequential function local:get-out-links-parsed($content as node()*, $uri as xs:string) as xs:string* +{ distinct-values( for $y in ($content//*:a/string(@href), + $content//*:link/string(@href), + $content//*:script/string(@src), + $content//*:img/string(@src), + $content//*:area/string(@href) + ) +return local:get-real-link($y, $uri)) +}; + + +declare %ann:sequential function local:get-out-links-unparsed($content as xs:string, $uri as xs:string) as xs:string*{ + + distinct-values( + let $search := fn:analyze-string($content, "(<|<|<)(((a|link|area).+?href)|((script|img).+?src))=([""'])(.*?)\7") + for $other-
[Zorba-coders] [Merge] lp:~danielturcanu/zorba/my_conv_module into lp:zorba/data-converters-module
Daniel Turcanu has proposed merging lp:~danielturcanu/zorba/my_conv_module into lp:zorba/data-converters-module. Requested reviews: Zorba Coders (zorba-coders) For more details, see: https://code.launchpad.net/~danielturcanu/zorba/my_conv_module/+merge/78608 Fixed the link crawler test -- https://code.launchpad.net/~danielturcanu/zorba/my_conv_module/+merge/78608 Your team Zorba Coders is requested to review the proposed merge of lp:~danielturcanu/zorba/my_conv_module into lp:zorba/data-converters-module. === modified file 'test_html/Queries/converters/html/link_crawler2.xq2' --- test_html/Queries/converters/html/link_crawler2.xq2 2011-10-06 07:40:17 + +++ test_html/Queries/converters/html/link_crawler2.xq2 2011-10-07 14:24:47 + @@ -18,6 +18,7 @@ import module namespace map = "http://www.zorba-xquery.com/modules/store/data-structures/unordered-map";; import module namespace html = "http://www.zorba-xquery.com/modules/converters/html";; import module namespace parse-xml = "http://www.zorba-xquery.com/modules/xml";; +import module namespace file = "http://expath.org/ns/file";; declare namespace ann = "http://www.zorba-xquery.com/annotations";; declare namespace xhtml="http://www.w3.org/1999/xhtml";; @@ -29,12 +30,9 @@ declare variable $uri-host as xs:string := "http://www.zorba-xquery.com/site2/";; -declare variable $supported-media-types as xs:string+ := ("text/xml", "application/xml", "text/xml-external-parsed-entity", "application/xml-external-parsed-entity", - "application/atom+xml", "text/html"); - - -declare variable $local:processed-internal-links:=xs:QName("processed-internal-links"); -declare variable $local:processed-external-links :=xs:QName("processed-external-links"); + +declare variable $local:processed-internal-links := xs:QName("processed-internal-links"); +declare variable $local:processed-external-links := xs:QName("processed-external-links"); declare %ann:sequential function local:create-containers() @@ -59,9 +57,17 @@ return if($sb = "") then $s1 else $sb }; -declare function local:get-real-link($href as xs:string, $start-uri as xs:string) as xs:string +declare %ann:sequential function local:get-real-link($href as xs:string, $start-uri as xs:string) as xs:string? { - local:my-substring-before(resolve-uri($href, $start-uri), "#") + variable $absuri; + try{ +$absuri := local:my-substring-before(resolve-uri(fn:normalize-space($href), $start-uri), "#"); + } + catch * + { + map:insert($local:processed-external-links, fn:concat("malformed, referenced in page ", $start-uri), $href); + } + $absuri }; @@ -70,13 +76,15 @@ local:my-substring-before($http-call/httpsch:header[@name = 'Content-Type'][1]/string(@value), ";") }; -declare function local:alive($http-call as node()*) as xs:boolean +declare function local:alive($http-call as item()*) as xs:boolean { - if(($http-call[1]/@status eq 200)) then true() else false() + if((count($http-call) ge 1) and +($http-call[1]/@status eq 200)) + then true() else fn:trace(false(), "alive") }; -declare function local:get-out-links-parsed($content as node()*, $uri as xs:string) as xs:string* +declare %ann:sequential function local:get-out-links-parsed($content as node()*, $uri as xs:string) as xs:string* { distinct-values( for $y in ($content//*:a/string(@href), $content//*:link/string(@href), $content//*:script/string(@src), @@ -87,22 +95,29 @@ }; -declare function local:get-out-links-unparsed($content as xs:string, $uri as xs:string) as xs:string*{ +declare %ann:sequential function local:get-out-links-unparsed($content as xs:string, $uri as xs:string) as xs:string*{ distinct-values( let $search := fn:analyze-string($content, "(<|<|<)(((a|link|area).+?href)|((script|img).+?src))=([""'])(.*?)\7") for $other-uri2 in $search//group[@nr=8]/string() - let $y:= fn:normalize-space($other-uri2) - return local:get-real-link($y, $uri) + return local:get-real-link($other-uri2, $uri) ) }; +declare %ann:sequential function local:process-link($x as xs:string, $n as xs:integer) as item()*{ + if(local:is-internal($x)) + then local:process-internal-link($x, $n); + else local:process-external-link($x); + +}; + declare %ann:sequential function local:process-external-link($x as xs:string){ if(not(empty(map:get($local:processed-external-links, $x then exit returning false(); else {} + fn:trace($x, "HEAD external link"); variable $http-call:=(); try{ $http-call:=http:send-request(,
Re: [Zorba-coders] [Merge] lp:~gabipetrovay/zorba/geo-win-build into lp:zorba/geo-module
I have geos built from source, and there is no geos_c.dll. I always have to remove that FIND_PACKAGE_DLL_WIN32. Do you need that dll? What geos do you have? -- https://code.launchpad.net/~gabipetrovay/zorba/geo-win-build/+merge/78602 Your team Zorba Coders is subscribed to branch lp:zorba/geo-module. -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
[Zorba-coders] [Merge] lp:~danielturcanu/zorba/my_conv_module into lp:zorba/data-converters-module
The proposal to merge lp:~danielturcanu/zorba/my_conv_module into lp:zorba/data-converters-module has been updated. Status: Needs review => Approved For more details, see: https://code.launchpad.net/~danielturcanu/zorba/my_conv_module/+merge/78588 -- https://code.launchpad.net/~danielturcanu/zorba/my_conv_module/+merge/78588 Your team Zorba Coders is requested to review the proposed merge of lp:~danielturcanu/zorba/my_conv_module into lp:zorba/data-converters-module. -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
[Zorba-coders] [Merge] lp:~danielturcanu/zorba/my_conv_module into lp:zorba/data-converters-module
Daniel Turcanu has proposed merging lp:~danielturcanu/zorba/my_conv_module into lp:zorba/data-converters-module. Requested reviews: Zorba Coders (zorba-coders) For more details, see: https://code.launchpad.net/~danielturcanu/zorba/my_conv_module/+merge/78588 Fixed the link crawler test -- https://code.launchpad.net/~danielturcanu/zorba/my_conv_module/+merge/78588 Your team Zorba Coders is requested to review the proposed merge of lp:~danielturcanu/zorba/my_conv_module into lp:zorba/data-converters-module. === modified file 'test_html/Queries/converters/html/link_crawler2.xq2' --- test_html/Queries/converters/html/link_crawler2.xq2 2011-10-06 07:40:17 + +++ test_html/Queries/converters/html/link_crawler2.xq2 2011-10-07 13:01:14 + @@ -18,6 +18,7 @@ import module namespace map = "http://www.zorba-xquery.com/modules/store/data-structures/unordered-map";; import module namespace html = "http://www.zorba-xquery.com/modules/converters/html";; import module namespace parse-xml = "http://www.zorba-xquery.com/modules/xml";; +import module namespace file = "http://expath.org/ns/file";; declare namespace ann = "http://www.zorba-xquery.com/annotations";; declare namespace xhtml="http://www.w3.org/1999/xhtml";; @@ -29,12 +30,9 @@ declare variable $uri-host as xs:string := "http://www.zorba-xquery.com/site2/";; -declare variable $supported-media-types as xs:string+ := ("text/xml", "application/xml", "text/xml-external-parsed-entity", "application/xml-external-parsed-entity", - "application/atom+xml", "text/html"); - - -declare variable $local:processed-internal-links:=xs:QName("processed-internal-links"); -declare variable $local:processed-external-links :=xs:QName("processed-external-links"); + +declare variable $local:processed-internal-links := xs:QName("processed-internal-links"); +declare variable $local:processed-external-links := xs:QName("processed-external-links"); declare %ann:sequential function local:create-containers() @@ -59,9 +57,13 @@ return if($sb = "") then $s1 else $sb }; -declare function local:get-real-link($href as xs:string, $start-uri as xs:string) as xs:string +declare function local:get-real-link($href as xs:string, $start-uri as xs:string) as xs:string? { - local:my-substring-before(resolve-uri($href, $start-uri), "#") + try{ +local:my-substring-before(resolve-uri(fn:normalize-space($href), $start-uri), "#") + } + catch* + { () } }; @@ -70,9 +72,11 @@ local:my-substring-before($http-call/httpsch:header[@name = 'Content-Type'][1]/string(@value), ";") }; -declare function local:alive($http-call as node()*) as xs:boolean +declare function local:alive($http-call as item()*) as xs:boolean { - if(($http-call[1]/@status eq 200)) then true() else false() + if((count($http-call) ge 1) and +($http-call[1]/@status eq 200)) + then true() else fn:trace(false(), "alive") }; @@ -92,17 +96,24 @@ distinct-values( let $search := fn:analyze-string($content, "(<|<|<)(((a|link|area).+?href)|((script|img).+?src))=([""'])(.*?)\7") for $other-uri2 in $search//group[@nr=8]/string() - let $y:= fn:normalize-space($other-uri2) - return local:get-real-link($y, $uri) + return local:get-real-link($other-uri2, $uri) ) }; +declare %ann:sequential function local:process-link($x as xs:string, $n as xs:integer) as item()*{ + if(local:is-internal($x)) + then local:process-internal-link($x, $n); + else local:process-external-link($x); + +}; + declare %ann:sequential function local:process-external-link($x as xs:string){ if(not(empty(map:get($local:processed-external-links, $x then exit returning false(); else {} + fn:trace($x, "HEAD external link"); variable $http-call:=(); try{ $http-call:=http:send-request(, (), ()); @@ -127,39 +138,42 @@ declare %ann:sequential function local:process-internal-link($x as xs:string, $n as xs:integer){ - if($n=3) then exit returning (); else {} + (: if($n=3) then exit returning (); else {} :) if(not(empty(map:get($local:processed-internal-links, $x then exit returning false(); else {} + fn:trace($x, "GET internal link"); variable $http-call:=(); try{ $http-call:=http:send-request(, (), ()); } - catch * {} - if( not(local:alive($http-call))) + catch * { } + if( not(local:alive($http-call))) then { map:insert($local:processed-internal-links, "broken", $x); exit returning ();} else {} - if(not (local:get-media-type($h
Re: [Zorba-coders] [Merge] lp:~danielturcanu/zorba/mytrunk into lp:zorba
So you propose a function like file:resolve-path-to-uri($baseUri, $filePath) ? I guess it's fine too. -- https://code.launchpad.net/~danielturcanu/zorba/mytrunk/+merge/78253 Your team Zorba Coders is subscribed to branch lp:zorba. -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
Re: [Zorba-coders] [Merge] lp:~danielturcanu/zorba/mytrunk into lp:zorba
Please stop giving arguments from the spec. I also know the spec. I am trying to come with a solution to the problem. This problem cannot be solved by sticking to the spec. So I want like this: have a variable that contains an absolute or relative file system path, and resolve it to a base absolute URI. There should be no if(is_absolute_path) and no if(win32) in the xquery code. Right now this doesn't work, because our URI implementation considers the absolute Win32 path as a relative path, because it doesn't start with slash. Maybe we shoud add another function in the file module, like file:path-to-uri-path, which should add a slash for absolute win32 paths, and leave the relative paths as they are. -- https://code.launchpad.net/~danielturcanu/zorba/mytrunk/+merge/78253 Your team Zorba Coders is subscribed to branch lp:zorba. -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
Re: [Zorba-coders] [Merge] lp:~danielturcanu/zorba/mytrunk into lp:zorba
Maybe W3C doesn't care about file systems, but URIs do. At least http, ftp and file all work with file system paths. We actually work with URL, not URI, we don't have general URIs so far. I tested now file:path-to-uri and it doesn't do what I want: if I give it an absolute path, then it returns a complete URI, and if I give it a relative path, then it also returns a complete URI, with the path relative to my rbkt dir in the build directory. This seems like a wrong thing. If my rbkt dir is hardcoded in the file module, then it won't work for other users if I deploy the file module. I still think that this is a job for fn:encode-for-uri. I need a function to encode a file system path into a path for URI. So if it is absolute path, make it absolute path for URI, not a full URI, and if it is relative path, make it relative path for URI. And then this path I can apply to fn:resolve-uri. -- https://code.launchpad.net/~danielturcanu/zorba/mytrunk/+merge/78253 Your team Zorba Coders is subscribed to branch lp:zorba. -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
Re: [Zorba-coders] [Merge] lp:~danielturcanu/zorba/mytrunk into lp:zorba
Ok, I guess you are right. I reread again the URI spec and it doesn't say anything about Windows paths. But how to transform Windows filepaths into file URI in a OS independent way? There is another function fn:encode-for-uri, which is supposed to encode a path to be used as uri, but that isn't prepared for Windows either. fn:encode-for-uri("C:\path1\file.xml") gives C%3Apath1%2Ffile.xml. I would expect /C%3A/path1/file.xml , meaning detect that is an absolute Windows path, and replace backslashes with slashes. I think the problem is in this function, it should be made to work differently for Windows. -- https://code.launchpad.net/~danielturcanu/zorba/mytrunk/+merge/78253 Your team Zorba Coders is subscribed to branch lp:zorba. -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
Re: [Zorba-coders] [Merge] lp:~danielturcanu/zorba/mytrunk into lp:zorba
For Windows, the absolute path for URI is still in the form C:/, only that it looks like C3A/. At least for file:// scheme. I guess I should add a check only for that scheme. About absolute and relative paths in URI, think about what fn:resolve-uri works with. It can receive a relative path, or absolute path or entire URI. When receiving absolute paths, it doesn't work now in Windows for file://. -- https://code.launchpad.net/~danielturcanu/zorba/mytrunk/+merge/78253 Your team Zorba Coders is subscribed to branch lp:zorba. -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp
[Zorba-coders] [Merge] lp:~danielturcanu/zorba/mytrunk into lp:zorba
The proposal to merge lp:~danielturcanu/zorba/mytrunk into lp:zorba has been updated. Status: Needs review => Approved For more details, see: https://code.launchpad.net/~danielturcanu/zorba/mytrunk/+merge/78253 -- https://code.launchpad.net/~danielturcanu/zorba/mytrunk/+merge/78253 Your team Zorba Coders is subscribed to branch lp:zorba. -- Mailing list: https://launchpad.net/~zorba-coders Post to : zorba-coders@lists.launchpad.net Unsubscribe : https://launchpad.net/~zorba-coders More help : https://help.launchpad.net/ListHelp