[Bug 1042] New: Scripting related tests fail

http://bugs.orocos.org/show_bug.cgi?id=1042

Summary: Scripting related tests fail
Product: Toolchain
Version: master
Platform: All
OS/Version: All
Status: NEW
Severity: blocker
Priority: P3
Component: RTT
AssignedTo: orocos-dev [..] ...
ReportedBy: ruben [dot] smits [..] ...
CC: orocos-dev [..] ...
Estimated Hours: 0.0

I'm using RTT master on Ubuntu 13.04 using gcc 4.7 and boost 1.49 and get the
following output from make check:

The following tests FAILED:
25 - scripting_test (Failed)
26 - types_test (Failed)
27 - program_test (Failed)
28 - state_test (Failed)
29 - rtstring_test (Failed)
30 - function_test (Failed)

Running the scripting test gives me:

./scripting_test
Running 3 test cases...
unknown location(0): fatal error in "TestGetProvider": memory access violation
at address: 0x00000001: no mapping at fault address
/home/rsmits/catkin_ws/src/orocos_toolchain/rtt/tests/scripting_test.cpp(55):
last checkpoint

Running in gdb gives me (be prepared, not for the faint hearted):

Program received signal SIGSEGV, Segmentation fault.
0x00007ffff6ad8071 in
boost::spirit::classic::impl::string_parser_parse<boost::spirit::classic::match char const*,
boost::spirit::classic::scanner<boost::spirit::classic::position_iterator<__gnu_cxx::__normal_iterator std::string>, boost::spirit::classic::file_position_base<std::string>,
boost::spirit::classic::nil_t>,
boost::spirit::classic::scanner_policies<boost::spirit::classic::no_skipper_iteration_policy const*>,
boost::spirit::classic::kleene_star<boost::spirit::classic::anychar_parser>,
boost::spirit::classic::alternative<boost::spirit::classic::eol_parser,
boost::spirit::classic::end_parser>,
boost::spirit::classic::unary_parser_category,
boost::spirit::classic::non_nested, boost::spirit::classic::is_lexeme>,
boost::spirit::classic::confix_parser<boost::spirit::classic::strlit const*>,
boost::spirit::classic::kleene_star<boost::spirit::classic::anychar_parser>,
boost::spirit::classic::alternative<boost::spirit::classic::eol_parser,
boost::spirit::classic::end_parser>,
boost::spirit::classic::unary_parser_category,
boost::spirit::classic::non_nested, boost::spirit::classic::is_lexeme> >,
boost::spirit::classic::confix_parser<boost::spirit::classic::strlit const*>,
boost::spirit::classic::kleene_star<boost::spirit::classic::anychar_parser>,
boost::spirit::classic::strlit<char const*>,
boost::spirit::classic::unary_parser_category,
boost::spirit::classic::non_nested, boost::spirit::classic::is_lexeme> >,
boost::spirit::classic::difference<boost::spirit::classic::space_parser,
boost::spirit::classic::eol_parser> >,
boost::spirit::classic::functor_parser<RTT::scripting::eol_skip_functor> >,
boost::spirit::classic::iteration_policy> >,
boost::spirit::classic::match_policy, boost::spirit::classic::action_policy> >
const> (str_first=0x7fff00000004 <Address 0x7fff00000004 out of bounds>,
str_last=0x69055d "", scan=...)
at
/usr/include/boost/spirit/home/classic/core/primitives/impl/primitives.ipp:67
67 if (scan.at_end() || (*str_first != *scan))
(gdb) bt
#0 0x00007ffff6ad8071 in
boost::spirit::classic::impl::string_parser_parse<boost::spirit::classic::match char const*,
boost::spirit::classic::scanner<boost::spirit::classic::position_iterator<__gnu_cxx::__normal_iterator std::string>, boost::spirit::classic::file_position_base<std::string>,
boost::spirit::classic::nil_t>,
boost::spirit::classic::scanner_policies<boost::spirit::classic::no_skipper_iteration_policy const*>,
boost::spirit::classic::kleene_star<boost::spirit::classic::anychar_parser>,
boost::spirit::classic::alternative<boost::spirit::classic::eol_parser,
boost::spirit::classic::end_parser>,
boost::spirit::classic::unary_parser_category,
boost::spirit::classic::non_nested, boost::spirit::classic::is_lexeme>,
boost::spirit::classic::confix_parser<boost::spirit::classic::strlit const*>,
boost::spirit::classic::kleene_star<boost::spirit::classic::anychar_parser>,
boost::spirit::classic::alternative<boost::spirit::classic::eol_parser,
boost::spirit::classic::end_parser>,
boost::spirit::classic::unary_parser_category,
boost::spirit::classic::non_nested, boost::spirit::classic::is_lexeme> >,
boost::spirit::classic::confix_parser<boost::spirit::classic::strlit const*>,
boost::spirit::classic::kleene_star<boost::spirit::classic::anychar_parser>,
boost::spirit::classic::strlit<char const*>,
boost::spirit::classic::unary_parser_category,
boost::spirit::classic::non_nested, boost::spirit::classic::is_lexeme> >,
boost::spirit::classic::difference<boost::spirit::classic::space_parser,
boost::spirit::classic::eol_parser> >,
boost::spirit::classic::functor_parser<RTT::scripting::eol_skip_functor> >,
boost::spirit::classic::iteration_policy> >,
boost::spirit::classic::match_policy, boost::spirit::classic::action_policy> >
const> (str_first=0x7fff00000004 <Address 0x7fff00000004 out of bounds>,
str_last=0x69055d "", scan=...)
at
/usr/include/boost/spirit/home/classic/core/primitives/impl/primitives.ipp:67
#1 0x00007ffff6ad7ec4 in boost::spirit::classic::chseq<char
const*>::parse<boost::spirit::classic::scanner std::string>, boost::spirit::classic::file_position_base<std::string>,
boost::spirit::classic::nil_t>,
boost::spirit::classic::scanner_policies<boost::spirit::classic::no_skipper_iteration_policy const*>,
boost::spirit::classic::kleene_star<boost::spirit::classic::anychar_parser>,
boost::spirit::classic::alternative<boost::spirit::classic::eol_parser,
boost::spirit::classic::end_parser>,
boost::spirit::classic::unary_parser_category,
boost::spirit::classic::non_nested, boost::spirit::classic::is_lexeme>,

....

#18 0x00007ffff6acbdad in
boost::spirit::classic::scanner<boost::spirit::classic::position_iterator<__gnu_cxx::__normal_iterator std::string>, boost::spirit::classic::file_position_base<std::string>,
boost::spirit::classic::nil_t>,
boost::spirit::classic::scanner_policies<boost::spirit::classic::skip_parser_iteration_policy const*>,
boost::spirit::classic::kleene_star<boost::spirit::classic::anychar_parser>,
boost::spirit::classic::alternative<boost::spirit::classic::eol_parser,
boost::spirit::classic::end_parser>,
boost::spirit::classic::unary_parser_category,
boost::spirit::classic::non_nested, boost::spirit::classic::is_lexeme>,
boost::spirit::classic::confix_parser<boost::spirit::classic::strlit const*>,
boost::spirit::classic::kleene_star<boost::spirit::classic::anychar_parser>,
boost::spirit::classic::alternative<boost::spirit::classic::eol_parser,
boost::spirit::classic::end_parser>,
boost::spirit::classic::unary_parser_category,
boost::spirit::classic::non_nested, boost::spirit::classic::is_lexeme> >,
boost::spirit::classic::confix_parser<boost::spirit::classic::strlit const*>,
boost::spirit::classic::kleene_star<boost::spirit::classic::anychar_parser>,
boost::spirit::classic::strlit<char const*>,
boost::spirit::classic::unary_parser_category,
boost::spirit::classic::non_nested, boost::spirit::classic::is_lexeme> >,
boost::spirit::classic::difference<boost::spirit::classic::space_parser,
boost::spirit::classic::eol_parser> >,
boost::spirit::classic::functor_parser<RTT::scripting::eol_skip_functor> >,
boost::spirit::classic::iteration_policy>,
boost::spirit::classic::match_policy, boost::spirit::classic::action_policy>
>::at_end (
this=0x7fffffffa6a0) at
/usr/include/boost/spirit/home/classic/core/scanner/scanner.hpp:252
#19 0x00007ffff6ac7afe in
boost::spirit::classic::scanner<boost::spirit::classic::position_iterator<__gnu_cxx::__normal_iterator std::string>, boost::spirit::classic::file_position_base<std::string>,
boost::spirit::classic::nil_t>,
boost::spirit::classic::scanner_policies<boost::spirit::classic::skip_parser_iteration_policy const*>,
boost::spirit::classic::kleene_star<boost::spirit::classic::anychar_parser>,
boost::spirit::classic::alternative<boost::spirit::classic::eol_parser,
boost::spirit::classic::end_parser>,
boost::spirit::classic::unary_parser_category,
boost::spirit::classic::non_nested, boost::spirit::classic::is_lexeme>,
boost::spirit::classic::confix_parser<boost::spirit::classic::strlit const*>,
boost::spirit::classic::kleene_star<boost::spirit::classic::anychar_parser>,
boost::spirit::classic::alternative<boost::spirit::classic::eol_parser,
boost::spirit::classic::end_parser>,
boost::spirit::classic::unary_parser_category,
boost::spirit::classic::non_nested, boost::spirit::classic::is_lexeme> >,
boost::spirit::classic::confix_parser<boost::spirit::classic::strlit const*>,
boost::spirit::classic::kleene_star<boost::spirit::classic::anychar_parser>,
boost::spirit::classic::strlit<char const*>,
boost::spirit::classic::unary_parser_category,
boost::spirit::classic::non_nested, boost::spirit::classic::is_lexeme> >,
boost::spirit::classic::difference<boost::spirit::classic::space_parser,
boost::spirit::classic::eol_parser> >,
boost::spirit::classic::functor_parser<RTT::scripting::eol_skip_functor> >,
boost::spirit::classic::iteration_policy>,
boost::spirit::classic::match_policy, boost::spirit::classic::action_policy>
>::scanner (
this=0x7fffffffa6a0, first_=..., last_=..., policies=...) at
/usr/include/boost/spirit/home/classic/core/scanner/scanner.hpp:235
#20 0x00007ffff6abcdc4 in RTT::scripting::ProgramGraphParser::parse
(this=0x7fffffffa8f0, begin=..., end=...)
at
/home/rsmits/catkin_ws/src/orocos_toolchain/rtt/rtt/scripting/ProgramGraphParser.cpp:681
#21 0x00007ffff6b5d973 in RTT::scripting::Parser::parseProgram
(this=0x7fffffffbb60, text=..., c=0x6479d0, filename=...)
at
/home/rsmits/catkin_ws/src/orocos_toolchain/rtt/rtt/scripting/Parser.cpp:105
#22 0x00007ffff6b6dd94 in RTT::scripting::ScriptingService::loadPrograms
(this=0x6852a0, code=..., filename=..., mrethrow=false)
at
/home/rsmits/catkin_ws/src/orocos_toolchain/rtt/rtt/scripting/ScriptingService.cpp:637
#23 0x00007ffff6b679ac in RTT::scripting::ScriptingService::doLoadProgramText
(this=0x6852a0, code=...)
at
/home/rsmits/catkin_ws/src/orocos_toolchain/rtt/rtt/scripting/ScriptingService.cpp:427
---Type <return> to continue, or q <return> to quit---
#24 0x00007ffff6b87814 in boost::_mfi::mf1<bool,
RTT::scripting::ScriptingService, std::string const&>::operator()
(this=0x68fb18, p=0x6852a0, a1=...)
at /usr/include/boost/bind/mem_fn_template.hpp:165
#25 0x00007ffff6b86b05 in
boost::_bi::list2<boost::_bi::value boost::arg<1> >::operator()<bool, boost::_mfi::mf1 RTT::scripting::ScriptingService, std::string const&>,
boost::_bi::list1<std::string const&> > (this=0x68fb28, f=..., a=...)
at /usr/include/boost/bind/bind.hpp:303
#26 0x00007ffff6b85f7c in boost::_bi::bind_t<boost::_bi::unspecified,
boost::_mfi::mf1 boost::_bi::list2<boost::_bi::value boost::arg<1> > >::operator()<std::string> (this=0x68fb18, a1=...)
at /usr/include/boost/bind/bind_template.hpp:47
#27 0x00007ffff6b85563 in
boost::detail::function::function_obj_invoker1<boost::_bi::bind_t boost::_mfi::mf1 boost::_bi::list2<boost::_bi::value boost::arg<1> > >, bool, std::string const&>::invoke (function_obj_ptr=...,
a0=...) at /usr/include/boost/function/function_template.hpp:132
#28 0x00007ffff7a6a90d in boost::function1<bool, std::string
const&>::operator() (this=0x68fb10, a0=...)
at /usr/include/boost/function/function_template.hpp:760
#29 0x00007ffff7a6330f in RTT::internal::LocalOperationCallerImpl<bool
(std::string const&)>::call_impl<std::string const&>(std::string const&) (
this=0x68fad0, a1=...) at
/home/rsmits/catkin_ws/src/orocos_toolchain/rtt/rtt/internal/../internal/LocalOperationCaller.hpp:356
#30 0x00007ffff7a5be45 in RTT::internal::InvokerImpl<1, bool (std::string
const&), RTT::internal::LocalOperationCallerImpl<bool (std::string const&)>
>::call(std::string const&) (this=0x68fad0, a1=...) at
/home/rsmits/catkin_ws/src/orocos_toolchain/rtt/rtt/internal/../internal/Invoker.hpp:96
#31 0x00000000004194df in RTT::internal::InvokerSignature<1, bool (std::string
const&), boost::shared_ptr<RTT::base::OperationCallerBase const&)> > >::operator()(std::string const&) (this=0x68ce10, a1=...) at
/home/rsmits/catkin_ws/src/orocos_toolchain/rtt/rtt/internal/InvokerSignature.hpp:110
#32 0x00000000004105f0 in ScriptingTestSuite::TestGetProvider::test_method
(this=0x7fffffffc250)
at
/home/rsmits/catkin_ws/src/orocos_toolchain/rtt/tests/scripting_test.cpp:57
#33 0x000000000041007d in ScriptingTestSuite::TestGetProvider_invoker () at
/home/rsmits/catkin_ws/src/orocos_toolchain/rtt/tests/scripting_test.cpp:42
#34 0x000000000041c4b6 in
boost::unit_test::ut_detail::invoker<boost::unit_test::ut_detail::unused>::invoke<void
(*)()> (this=0x7fffffffc2df,
f=@0x628b18: 0x41005c <ScriptingTestSuite::TestGetProvider_invoker()>) at
/usr/include/boost/test/utils/callback.hpp:56
#35 0x000000000041c304 in
boost::unit_test::ut_detail::callback0_impl_t<boost::unit_test::ut_detail::unused,
void (*)()>::invoke (this=0x628b10)
at /usr/include/boost/test/utils/callback.hpp:89
#36 0x00007ffff5dbe0b1 in ?? () from
/usr/lib/libboost_unit_test_framework.so.1.49.0
#37 0x00007ffff5d9bd1e in
boost::execution_monitor::catch_signals(boost::unit_test::callback0<int>
const&) ()
from /usr/lib/libboost_unit_test_framework.so.1.49.0
#38 0x00007ffff5d9c60b in
boost::execution_monitor::execute(boost::unit_test::callback0<int> const&) ()
from /usr/lib/libboost_unit_test_framework.so.1.49.0
#39 0x00007ffff5dbe199 in
boost::unit_test::unit_test_monitor_t::execute_and_translate(boost::unit_test::test_case
const&) ()
from /usr/lib/libboost_unit_test_framework.so.1.49.0
#40 0x00007ffff5da2fe8 in
boost::unit_test::framework_impl::visit(boost::unit_test::test_case const&) ()
from /usr/lib/libboost_unit_test_framework.so.1.49.0
#41 0x00007ffff5ddce5b in
boost::unit_test::traverse_test_tree(boost::unit_test::test_suite const&,
boost::unit_test::test_tree_visitor&) ()
from /usr/lib/libboost_unit_test_framework.so.1.49.0
#42 0x00007ffff5ddce5b in
boost::unit_test::traverse_test_tree(boost::unit_test::test_suite const&,
boost::unit_test::test_tree_visitor&) ()
from /usr/lib/libboost_unit_test_framework.so.1.49.0
#43 0x00007ffff5d9e1e6 in boost::unit_test::framework::run(unsigned long, bool)
() from /usr/lib/libboost_unit_test_framework.so.1.49.0
#44 0x00007ffff5dbbe6f in boost::unit_test::unit_test_main(bool (*)(), int,
char**) () from /usr/lib/libboost_unit_test_framework.so.1.49.0
#45 0x000000000040f706 in main (argc=1, argv=0x7fffffffd208) at
/usr/include/boost/test/unit_test.hpp:59

[Bug 1042] Scripting related tests fail

http://bugs.orocos.org/show_bug.cgi?id=1042

S Roderick <kiwi [dot] net [..] ...> changed:

What |Removed |Added
----------------------------------------------------------------------------
CC| |kiwi [dot] net [..] ...

Ruben Smits's picture

[Bug 1042] Scripting related tests fail