You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
wait_for does not work as expected for calls on remote localities. Even after the remote call successfully completes, wait_for returns "deferred". The bug can be reproduced with many examples, e.g. this one:
#include <hpx/hpx_init.hpp>
#include <hpx/include/lcos.hpp>
#include <hpx/include/actions.hpp>
#include <chrono>
#include <iostream>
void f();
HPX_PLAIN_ACTION(f, f_action);
void f()
{
std::cout << "Calling empty f\n";
}
int hpx_main(boost::program_options::variables_map &vm)
{
auto remotes = hpx::find_remote_localities();
if (remotes.size() == 0) {
std::cout << "Need at least 2 localities!\n";
return -1;
}
auto fut = hpx::async<f_action>(remotes[0]);
auto status = fut.wait_for(std::chrono::seconds(3));
if (status == hpx::lcos::future_status::deferred)
std::cout << "Status deferred after waiting for 3 seconds in a trivial function!\n";
hpx::finalize();
return 0;
}
int main(int argc, char* argv[])
{
boost::program_options::options_description description("Bug");
return hpx::init(description, argc, argv);
}
The text was updated successfully, but these errors were encountered:
wait_for does not work as expected for calls on remote localities. Even after the remote call successfully completes, wait_for returns "deferred". The bug can be reproduced with many examples, e.g. this one:
The text was updated successfully, but these errors were encountered: