Project

General

Profile

Actions

Bug #1455

closed

WAxis asser failure

Added by Gaetano Mendola about 12 years ago. Updated about 12 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Target version:
Start date:
10/05/2012
Due date:
% Done:

0%

Estimated time:

Description

I'm getting this assert from time to time:

src/Wt/Chart/WAxis.C:714: void Wt::Chart::WAxis::computeRange(Wt::Chart::WChart2DRenderer&, const Wt::Chart::WAxis::Segment&) const: Assertion `segment.renderMinimum < segment.renderMaximum' failed.

Gaetano

Actions #1

Updated by Koen Deforche about 12 years ago

  • Status changed from New to Feedback
  • Assignee set to Koen Deforche

Hey,

With what version of Wt ?

Regards,

koen

Actions #2

Updated by Gaetano Mendola about 12 years ago

3.2.1, we can not use the 3.2.2 because the layout is totaly not working for our application.

Actions #3

Updated by Gaetano Mendola about 12 years ago

This is the complete back trace:

#0  0x00007fcc620f8a75 in *__GI_raise (sig=<value optimized out>) at ../nptl/sysdeps/unix/sysv/linux/raise.c:64
#1  0x00007fcc620fc5c0 in *__GI_abort () at abort.c:92
#2  0x00007fcc620f1941 in *__GI___assert_fail (assertion=0x7fcc754ab718 "segment.renderMinimum < segment.renderMaximum", file=<value optimized out>, line=714, 
    function=0x7fcc754ab7c0 "void Wt::Chart::WAxis::computeRange(Wt::Chart::WChart2DRenderer&, const Wt::Chart::WAxis::Segment&) const") at assert.c:81
#3  0x00007fcc75320b9c in Wt::Chart::WAxis::computeRange (this=0x7fcc540d3910, renderer=<value optimized out>, segment=...)
    at /root/ToInstall/wt-3.2.1-patched/src/Wt/Chart/WAxis.C:714
#4  0x00007fcc75320c35 in Wt::Chart::WAxis::prepareRender (this=0x7fcc540d3910, renderer=...) at /root/ToInstall/wt-3.2.1-patched/src/Wt/Chart/WAxis.C:325
#5  0x00007fcc7533476e in Wt::Chart::WChart2DRenderer::prepareAxes (this=<value optimized out>)
    at /root/ToInstall/wt-3.2.1-patched/src/Wt/Chart/WChart2DRenderer.C:775
#6  0x00007fcc7533224e in Wt::Chart::WChart2DRenderer::render (this=0x7fcc40013c80) at /root/ToInstall/wt-3.2.1-patched/src/Wt/Chart/WChart2DRenderer.C:758
#7  0x00007fcc7532c2cb in Wt::Chart::WCartesianChart::paint (this=<value optimized out>, painter=..., rectangle=...)
    at /root/ToInstall/wt-3.2.1-patched/src/Wt/Chart/WCartesianChart.C:231
#8  0x00007fcc7532bcab in Wt::Chart::WCartesianChart::paintEvent (this=0x7fcc540d3530, paintDevice=<value optimized out>)
    at /root/ToInstall/wt-3.2.1-patched/src/Wt/Chart/WCartesianChart.C:249
#9  0x00007fcc7520b5af in Wt::WPaintedWidget::getDomChanges (this=0x7fcc540d3530, result=..., app=<value optimized out>)
    at /root/ToInstall/wt-3.2.1-patched/src/Wt/WPaintedWidget.C:353
#10 0x00007fcc752d3e42 in Wt::WWebWidget::getSDomChanges (this=0x7fcc540d3530, result=..., app=0x7fcc541240f0)
    at /root/ToInstall/wt-3.2.1-patched/src/Wt/WWebWidget.C:1786
#11 0x00007fcc753e15bf in Wt::WebRenderer::collectChanges (this=0x7fcc4807a2c8, changes=<value optimized out>)
    at /root/ToInstall/wt-3.2.1-patched/src/web/WebRenderer.C:1494
#12 0x00007fcc753e99e1 in Wt::WebRenderer::collectJS (this=0x43a6, js=<value optimized out>) at /root/ToInstall/wt-3.2.1-patched/src/web/WebRenderer.C:1575
#13 0x00007fcc753ea6e8 in Wt::WebRenderer::collectJavaScriptUpdate (this=0x7fcc4807a2c8, out=...) at /root/ToInstall/wt-3.2.1-patched/src/web/WebRenderer.C:1507
#14 0x00007fcc753eb1cb in Wt::WebRenderer::collectJavaScript (this=0x7fcc4807a2c8) at /root/ToInstall/wt-3.2.1-patched/src/web/WebRenderer.C:742
#15 0x00007fcc753ed874 in Wt::WebRenderer::serveJavaScriptUpdate (this=0x7fcc4807a2c8, response=...) at /root/ToInstall/wt-3.2.1-patched/src/web/WebRenderer.C:551
#16 0x00007fcc753c9e51 in Wt::WebSession::serveResponse (this=0x7fcc4807a1d0, handler=...) at /root/ToInstall/wt-3.2.1-patched/src/web/WebSession.C:2262
#17 0x00007fcc753d5716 in Wt::WebSession::render (this=0x7fcc4807a1d0, handler=...) at /root/ToInstall/wt-3.2.1-patched/src/web/WebSession.C:2212
#18 0x00007fcc753d5e5c in Wt::WebSession::notify (this=0x7fcc4807a1d0, event=...) at /root/ToInstall/wt-3.2.1-patched/src/web/WebSession.C:2097
#19 0x00007fcc753d1eaa in Wt::WebSession::handleRequest (this=0x7fcc4807a1d0, handler=...) at /root/ToInstall/wt-3.2.1-patched/src/web/WebSession.C:1416
#20 0x00007fcc753bed0e in Wt::WebController::handleRequest (this=0x7fcc54006cc0, request=0x7fcc48176c80)
    at /root/ToInstall/wt-3.2.1-patched/src/web/WebController.C:612
#21 0x00007fcc74caf915 in http::server::WtReply::consumeRequestBody (this=<value optimized out>, begin=0x3e <Address 0x3e out of bounds>, 
    end=0x3e <Address 0x3e out of bounds>, state=<value optimized out>) at /root/ToInstall/wt-3.2.1-patched/src/http/WtReply.C:137
#22 0x00007fcc74c73c9e in http::server::RequestParser::parseBody (this=<value optimized out>, req=<value optimized out>, reply=DWARF-2 expression error: DW_OP_reg operations must be used either alone or in conjuction with DW_OP_piece.
)
    at /root/ToInstall/wt-3.2.1-patched/src/http/RequestParser.C:141
#23 0x00007fcc74c57827 in http::server::Connection::handleReadBody (this=0x7fcc54009880) at /root/ToInstall/wt-3.2.1-patched/src/http/Connection.C:226
#24 0x00007fcc74c5a2f1 in http::server::Connection::handleReadRequest0 (this=0x7fcc54009880) at /root/ToInstall/wt-3.2.1-patched/src/http/Connection.C:165
#25 0x00007fcc74ca5831 in call<boost::shared_ptr<http::server::Connection>, boost::system::error_code const, unsigned long> (base=<value optimized out>)
    at /usr/include/boost/bind/mem_fn_template.hpp:265
#26 operator()<boost::shared_ptr<http::server::Connection> > (base=<value optimized out>) at /usr/include/boost/bind/mem_fn_template.hpp:279
#27 operator()<boost::_mfi::mf2<void, http::server::Connection, const asio_error_code&, long unsigned int>, boost::_bi::list2<boost::system::error_code&, long unsigned int&> > (base=<value optimized out>) at /usr/include/boost/bind/bind.hpp:385
#28 operator()<boost::system::error_code, long unsigned int> (base=<value optimized out>) at /usr/include/boost/bind/bind_template.hpp:61
#29 boost::asio::detail::binder2<boost::_bi::bind_t<void, boost::_mfi::mf2<void, http::server::Connection, boost::system::error_code const&, unsigned long>, boost::_bi::list3<boost::_bi::value<boost::shared_ptr<http::server::Connection> >, boost::arg<1> (*)(), boost::arg<2> (*)()> >, boost::system::error_code, unsigned long>::operator() (base=<value optimized out>) at /usr/include/boost/asio/detail/bind_handler.hpp:96
#30 asio_handler_invoke<boost::asio::detail::binder2<boost::_bi::bind_t<void, boost::_mfi::mf2<void, http::server::Connection, asio_error_code const&, unsigned long>, boost::_bi::list3<boost::_bi::value<boost::shared_ptr<http::server::Connection> >, boost::arg<1> (*)(), boost::arg<2> (*)()> >, boost::system::error_code, unsigned long> > (base=<value optimized out>) at /usr/include/boost/asio/handler_invoke_hook.hpp:62
#31 invoke<boost::asio::detail::binder2<boost::_bi::bind_t<void, boost::_mfi::mf2<void, http::server::Connection, asio_error_code const&, unsigned long>, boost::_bi::list3<boost::_bi::value<boost::shared_ptr<http::server::Connection> >, boost::arg<1> (*)(), boost::arg<2> (*)()> >, boost::system::error_code, unsigned long>, boost::_bi::bind_t<void, boost::_mfi::mf2<void, http::server::Connection, asio_error_code const&, unsigned long>, boost::_bi::list3<boost::_bi::value<boost::shared_ptr<http::server::Connection> >, boost::arg<1> (*)(), boost::arg<2> (*)()> > > (base=<value optimized out>) at /usr/include/boost/asio/detail/handler_invoke_helpers.hpp:39
#32 asio_handler_invoke<boost::asio::detail::binder2<boost::_bi::bind_t<void, boost::_mfi::mf2<void, http::server::Connection, asio_error_code const&, unsigned long>, boost::_bi::list3<boost::_bi::value<boost::shared_ptr<http::server::Connection> >, boost::arg<1> (*)(), boost::arg<2> (*)()> >, boost::system::error_code, unsigned long>, boost::_bi::bind_t<void, boost::_mfi::mf2<void, http::server::Connection, asio_error_code const&, unsigned long>, boost::_bi::list3<boost::_bi::value<boost::shared_ptr<http::server::Connection> >, boost::arg<1> (*)(), boost::arg<2> (*)()> >, boost::system::error_code, unsigned long> (base=<value optimized out>)
    at /usr/include/boost/asio/detail/bind_handler.hpp:130
#33 invoke<boost::asio::detail::binder2<boost::_bi::bind_t<void, boost::_mfi::mf2<void, http::server::Connection, asio_error_code const&, unsigned long>, boost::_bi::list3<boost::_bi::value<boost::shared_ptr<http::server::Connection> >, boost::arg<1> (*)(), boost::arg<2> (*)()> >, boost::system::error_code, unsigned long>, boost::---Type <return> to continue, or q <return> to quit---
asio::detail::binder2<boost::_bi::bind_t<void, boost::_mfi::mf2<void, http::server::Connection, asio_error_code const&, unsigned long>, boost::_bi::list3<boost::_bi::value<boost::shared_ptr<http::server::Connection> >, boost::arg<1> (*)(), boost::arg<2> (*)()> >, boost::system::error_code, unsigned long> > (
    base=<value optimized out>) at /usr/include/boost/asio/detail/handler_invoke_helpers.hpp:39
#34 boost::asio::detail::handler_queue::handler_wrapper<boost::asio::detail::binder2<boost::_bi::bind_t<void, boost::_mfi::mf2<void, http::server::Connection, boost::system::error_code const&, unsigned long>, boost::_bi::list3<boost::_bi::value<boost::shared_ptr<http::server::Connection> >, boost::arg<1> (*)(), boost::arg<2> (*)()> >, boost::system::error_code, unsigned long> >::do_call (base=<value optimized out>) at /usr/include/boost/asio/detail/handler_queue.hpp:192
#35 0x00007fcc767bf3f8 in boost::asio::detail::handler_queue::handler::invoke (this=0x7fcc540073e0, ec=<value optimized out>)
    at /usr/include/boost/asio/detail/handler_queue.hpp:39
#36 boost::asio::detail::task_io_service<boost::asio::detail::epoll_reactor<false> >::do_one (this=0x7fcc540073e0, ec=<value optimized out>)
    at /usr/include/boost/asio/detail/task_io_service.hpp:268
#37 boost::asio::detail::task_io_service<boost::asio::detail::epoll_reactor<false> >::run (this=0x7fcc540073e0, ec=<value optimized out>)
    at /usr/include/boost/asio/detail/task_io_service.hpp:103
#38 0x00007fcc751bbc44 in boost::asio::io_service::run (this=0x7fcc54007780) at /usr/include/boost/asio/impl/io_service.ipp:58
#39 Wt::WIOService::run (this=0x7fcc54007780) at /root/ToInstall/wt-3.2.1-patched/src/Wt/WIOService.C:128
#40 0x00007fcc73c92b70 in thread_proxy () from /usr/lib/libboost_thread.so.1.40.0
#41 0x00007fcc6244e9ca in start_thread (arg=<value optimized out>) at pthread_create.c:300
#42 0x00007fcc621ab70d in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:112
#43 0x0000000000000000 in ?? ()
Actions #4

Updated by Gaetano Mendola about 12 years ago

so inspecting the variables I have:

(gdb) p segment.renderMinimum
$1 = 1997
(gdb) p segment.renderMaximum
$2 = 1997
(gdb) p scale_
$3 = Wt::Chart::LinearScale
(gdb) p segment
$4 = (const Wt::Chart::WAxis::Segment &) @0x7fcc540e33d0: {minimum = -1.7976931348623157e+308, maximum = 1.7976931348623157e+308, renderMinimum = 1997, 
  renderMaximum = 1997, renderLength = 1.7976931348623157e+308, renderStart = 1.7976931348623157e+308, dateTimeRenderUnit = 1970973440, 
  dateTimeRenderInterval = 32716}
(gdb) p AUTO_MINIMUM
$5 = -1.7976931348623157e+308
(gdb) p AUTO_MAXIMUM
$6 = 1.7976931348623157e+308
(gdb) p resolution_
$7 = 0

and that is the problem look at this indeed:

$ cat main33.cpp 
#include <cassert>
#include <limits>

int main() {
  double resolution = 1E3 * std::numeric_limits<double>::epsilon();

  double average = 1997;

  double max = average + resolution / 2;
  double min = average - resolution / 2;

  assert (min < max);
}
$ g++ main33.cpp
$ ./a.out 
a.out: main33.cpp:12: int main(): Assertion `min < max' failed.
Aborted (core dumped)
Actions #5

Updated by Koen Deforche about 12 years ago

  • Status changed from Feedback to Resolved

Hey,

This has been resolved recently in git. And as we are about to release the a new version, it would be worthwile to re-evaluate if the work we did on layout managers makes them usable again for your application.

REgards,

koen

Actions #6

Updated by Gaetano Mendola about 12 years ago

I will give it a shot and I'll let you know. The layout change have killed us, we are spending lot of time to dig into it, we are even paying users...

Actions #7

Updated by Koen Deforche about 12 years ago

  • Status changed from Resolved to Closed
  • Target version set to 3.2.3

Fixed in Wt 3.2.3 RC1.

Actions #8

Updated by Gaetano Mendola about 12 years ago

Koen,

I due the layout change we can not use the 3.2.3 yet, I have backported the WAxis.C from it to our 3.2.1, we had the assert failure again I was able to only find this:

segment.renderMinimum was 0

segment.renderMinimum was 0

resolution_ was 0

I'm going to instrument that method due the fact most variable have a scope already closed when the assert happen.

Actions #9

Updated by Koen Deforche about 12 years ago

Hey Gaetano,

You may want to consider more changes to the whole Chart namespace to backport to 3.2.1 in that case ?

Regards,

koen

Actions

Also available in: Atom PDF