# MethodError Exception, GtkReactive drawing.jl example using Debugger

**URL:** <https://discourse.julialang.org/t/methoderror-exception-gtkreactive-drawing-jl-example-using-debugger/57317>\
**Category:** General Usage\
**Tags:** plotting\
**Created:** [March 16, 2021, 5:00pm UTC](https://discourse.julialang.org/t/methoderror-exception-gtkreactive-drawing-jl-example-using-debugger/57317 "2021-03-16T17:00:56Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![nelsonah](https://avatars.discourse-cdn.com/v4/letter/n/7993a0/32.png) [@nelsonah](https://discourse.julialang.org/u/nelsonah)\
**Post date:** [March 16, 2021, 5:00pm UTC](https://discourse.julialang.org/t/methoderror-exception-gtkreactive-drawing-jl-example-using-debugger/57317/1 "2021-03-16T17:00:56Z")

</div>

I was trying to use the debugger to understand GtkReacttive coding. I stripped down the drawing.jl example as follows:

# File: drawing.jl from [https://raw.githubusercontent.com/JuliaGizmos/GtkReactive.jl/master/examples/drawing.jl](https://raw.githubusercontent.com/JuliaGizmos/GtkReactive.jl/master/examples/drawing.jl)

using Gtk.ShortNames, GtkReactive, Graphics, Colors  
win = Window(“Drawing”) # line 5  
c = canvas(UserUnit) # create a canvas with user-specified coordinates  
push!(win, c)  
sleep(5)  
I’m using VS Code on a Win 10 machine: Just running it, all is good.  
Using Run and Debug: it fails on the "win = Window(… line.  
Are GtkReactive and the debugger incompatible?  
Should I just use the REPL? and/or lots of println statements?  
Thanks, Harvey

Exception has occurred: MethodError  
MethodError: no method matching iterate(::Type{Nothing})  
Closest candidates are:  
iterate(!Matched::Cmd) at process.jl:638  
iterate(!Matched::Cmd, !Matched::Any) at process.jl:642  
iterate(!Matched::DataStructures.EnumerateAll) at C:\Users\Harvey.julia\packages\DataStructures\ixwFs\src\multi\_dict.jl:98  
…

Stacktrace:  
[1] gobject\_ref(::Gtk.GtkWindowLeaf) at C:\Users\Harvey.julia\packages\Gtk\TgEIW\src\GLib\gtype.jl:428  
[2] Gtk.GtkWindowLeaf(::Ptr{GObject}) at C:\Users\Harvey.julia\packages\Gtk\TgEIW\src\GLib\gtype.jl:210  
[3] Gtk.GtkWindowLeaf(::String, ::Int64, ::Int64, ::Bool, ::Bool) at C:\Users\Harvey.julia\packages\Gtk\TgEIW\src\windows.jl:13  
[4] Gtk.GtkWindowLeaf(::String) at C:\Users\Harvey.julia\packages\Gtk\TgEIW\src\windows.jl:2  
[5] Gtk.GtkWindow(::Tuple{String}; kwargs::Base.Iterators.Pairs{Union{},Union{},Tuple{},NamedTuple{(),Tuple{}}}) at C:\Users\Harvey.julia\packages\Gtk\TgEIW\src\GLib\gtype.jl:226  
[6] Gtk.GtkWindow(::Tuple{String}) at C:\Users\Harvey.julia\packages\Gtk\TgEIW\src\GLib\gtype.jl:226  
[7] top-level scope at c:\Users\Harvey\Documents\My Files\Programming\Julia\JuliaTutorials\GtkReactive\_Examples\debug\_example.jl:5
