Skip to content

Commit

Permalink
Revert "detect cause of #16091"
Browse files Browse the repository at this point in the history
This reverts commit 6359f1d.
  • Loading branch information
amitmurthy committed May 9, 2016
1 parent b1da999 commit 833f365
Showing 1 changed file with 1 addition and 25 deletions.
26 changes: 1 addition & 25 deletions test/examples.jl
Original file line number Diff line number Diff line change
Expand Up @@ -47,37 +47,13 @@ end
dc_path = joinpath(dir, "dictchannel.jl")
myid() == 1 || include(dc_path)

# The checks to see if DictChannel is defined is to identify the root cause of
# https://github.com/JuliaLang/julia/issues/16091 .
# To be removed once fixed.
defined_on_worker = false
if (myid() != 1) && !isdefined(:DictChannel)
error("myid : $(myid()). DictChannel not defined.")
else
defined_on_worker = true
end

# Run the remote on pid 1, since runtests may terminate workers
# at any time depending on memory usage
remotecall_fetch(1, dc_path) do f
include(f)
nothing
end

defined_on_master = false
if remotecall_fetch(isdefined, 1, :DictChannel) == false
error("myid : $(myid()). DictChannel not defined on 1")
else
defined_on_master = true
end

dc = nothing
try
dc=RemoteChannel(()->DictChannel(), 1)
catch e
println("myid : ", myid(), ", dc_path : ", dc_path, ", defined_on_worker:", defined_on_worker, ", defined_on_master: ", defined_on_master)
rethrow(e)
end
dc=RemoteChannel(()->DictChannel(), 1)
@test typeof(dc) == RemoteChannel{DictChannel}

@test isready(dc) == false
Expand Down

0 comments on commit 833f365

Please sign in to comment.