-
Notifications
You must be signed in to change notification settings - Fork 40
Open
Labels
Needs triageUsed in auto labelling of new issuesUsed in auto labelling of new issues
Description
I am unsure how to reproduce this without xwidgets.
Minimal example (Can be tried here).
- Change value to
0,1,2,3, everything going as planned; - Set value to
33, an exception message is shown; - Change value to
0, the exception message is not cleared. - Change value to
1, the message for0is cleared, the exception message is not cleared.
#include <iostream>
#include <stdexcept>
#include <xwidgets/xall.hpp>
#include <xcpp/xdisplay.hpp>
auto num = xw::number<std::uint32_t>();
auto out = xw::output();
XOBSERVE(num, value, [&](const auto& s) {
auto g = out.guard();
xcpp::clear_output();
if(s.value() == 33){
throw std::runtime_error("Exception");
}
std::cout << "Value: " << s.value() << std::endl;
});
xcpp::display(num);
xcpp::display(out);Metadata
Metadata
Assignees
Labels
Needs triageUsed in auto labelling of new issuesUsed in auto labelling of new issues