# Weird behavior using Jupyter and Gridap/GridapMakie

**URL:** <https://discourse.julialang.org/t/weird-behavior-using-jupyter-and-gridap-gridapmakie/50875>\
**Category:** New to Julia\
**Tags:** jupyter\
**Created:** [November 27, 2020, 7:53pm UTC](https://discourse.julialang.org/t/weird-behavior-using-jupyter-and-gridap-gridapmakie/50875 "2020-11-27T19:53:43Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![jmura](https://avatars.discourse-cdn.com/v4/letter/j/71e660/32.png) [@jmura](https://discourse.julialang.org/u/jmura)\
**Post date:** [November 27, 2020, 7:53pm UTC](https://discourse.julialang.org/t/weird-behavior-using-jupyter-and-gridap-gridapmakie/50875/1 "2020-11-27T19:53:43Z")

</div>

Dear All,

I’m using Julia 1.5.0 and Gridap v0.13.4 in Windows 10, and I was replicating the elasticity tutorial in Jupyter to learn how it works. Here is the code snippet:

```julia
using Gridap

# Creating a grid as the mesh
n = 10
domain = (0,1,0,1)
partition = (n,n)
model = CartesianDiscreteModel(domain,partition)

labels = get_face_labeling(model)
add_tag_from_tags!(labels,"diri1",[6,])
add_tag_from_tags!(labels,"diri0",[1,2,3,4,5,7,8])

println("These are the labels:");
println("entities: $(labels.tag_to_entities)")
println("names : $(labels.tag_to_name)") 

```

text … explaining to myself what is this …

```julia
# GridapMakie.jl is an experimental package for plotting
# https://github.com/gridap/GridapMakie.jl
using Makie, GridapMakie
AbstractPlotting.inline!(true) # required in Jupyter to show inside the notebook (otherwise opens a new window to the plot)
scene = plot(model) 
display(scene)

```

some other blocks in Jupyter with text, and then

```julia
# GridapMakie.jl is an experimental package for plotting
# https://github.com/gridap/GridapMakie.jl
using Makie, GridapMakie
AbstractPlotting.inline!(true) # required in Jupyter to show inside the notebook (otherwise opens a new window to the plot)
scene = plot(model) 
display(scene)

```

Everything goes great, including GridapMakie, until _suddenly_, (and I wish to remark the “suddenly”),

```julia
V1 = TestFESpace(
    reffe=:Lagrangian, conformity=:H1, valuetype=VectorValue{2,Float64},
    model=model, labels=labels, order=1, dirichlet_tags=["diri0","diri1"]
    )

```

```julia
UndefVarError: Args not defined

Stacktrace:
 [1] Base.Broadcast.Broadcasted{Base.Broadcast.Style{Tuple},Axes,F,Args} where Args<:Tuple where F where Axes(::typeof(==), ::Tuple{Tuple{var"#s302",var"#s302"} where var"#s302"<:Int64,Int64}, ::Nothing) at .\broadcast.jl:179

```

I restarted the kernel several times, and the same happens. But what’s surprising, at least to me, is that copying **all** the same code in REPL, runs perfectly and the last line throws `UnconstrainedFESpace()`

Restarting (again) the kernel in Jupyter, removing the block with GridMakie runs ok. I know GridapMakie is still experimental, but I’m curious about why it worked, and then the following sentence crashed just in Jupyter.

Any advice or comment is welcome, of course. And many thanks to the creators of Gridap: great PDE toolbox/solver/package for research and applications!
