# Issue with updating ModelingToolkit and remake command

**URL:** https://discourse.julialang.org/t/issue-with-updating-modelingtoolkit-and-remake-command/112164
**Category:** Modelling & Simulations
**Created:** [March 26, 2024, 11:41pm UTC](https://discourse.julialang.org/t/issue-with-updating-modelingtoolkit-and-remake-command/112164 "2024-03-26T23:41:20Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![Nick1](https://avatars.discourse-cdn.com/v4/letter/n/47e85d/32.png) [@Nick1](https://discourse.julialang.org/u/Nick1)
#### Post date: [March 26, 2024, 11:41pm UTC](https://discourse.julialang.org/t/issue-with-updating-modelingtoolkit-and-remake-command/112164/1 "2024-03-26T23:41:20Z")

</div>

I am trying to run the following code but I get the following error when I run the `remake` command at the end:

> ERROR: MethodError: Cannot `convert` an object of type Pair{SymbolicUtils.BasicSymbolic{Real}, Float64} to an object of type Float64

I suspect the reason is the outdated version of ModelingToolkit.jl (current version v8.75.0). However, when I try to update I get the following:

> ┌ Warning: attempting to remove probably stale pidfile  
> │ path = “C:\Users\name\.julia\compiled\v1.10\LanguageServer\ite7n\_OKxyi.ji.pidfile”  
> └ @ FileWatching.Pidfile C:\Users\name.julia\juliaup\julia-1.10.2+0.x64.w64.mingw32\share\julia\stdlib\v1.10\FileWatching\src\pidfile.jl:244  
> Precompiling project…  
> Progress [\>] 0/1  
> ◓ LanguageServer Waiting for background task / IO / timer. Interrupt to inspect

This issue also affects the update of other packages, such as Catalyst, DiffEqCallbacks, SteadyStateDiffEq, StructuralIdentifiability. How can I resolve this issue?

```julia
using DifferentialEquations
using SBMLToolkit
using ModelingToolkit

SBMLToolkit.checksupport_file("toy_model_sbml.xml")
mdl = readSBML("toy_model_sbml.xml", doc -> begin
    set_level_and_version(3, 2)(doc)
    convert_promotelocals_expandfuns(doc)
end);

rn = ReactionSystem(mdl);

odesys = convert(ODESystem, rn);

T=300.0; 
tspan = (0.0, T);
prob = ODEProblem(odesys, Float64[], tspan, Float64[]);

defs = ModelingToolkit.defaults(odesys);
getval(v) = defs[v];
pmap = parameters(odesys) .=> getval.(parameters(odesys));
u0map = states(odesys) .=> getval.(states(odesys));

p = getval.(parameters(odesys));
p[1] = 10.0 ; 

for (idx, param) in enumerate(p)
    pmap[idx] = pmap[idx][1] => param
end

prob2 = remake(prob; p=pmap, u0=u0map);

```

---

<div class="post-metadata">

### Author: ![ChrisRackauckas](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/chrisrackauckas/32/77_2.png) [@ChrisRackauckas](https://discourse.julialang.org/u/ChrisRackauckas)
#### Post date: [March 27, 2024, 8:09am UTC](https://discourse.julialang.org/t/issue-with-updating-modelingtoolkit-and-remake-command/112164/2 "2024-03-27T08:09:31Z")

</div>

Open an issue on ModelingToolkit. We’re almost done with the v9 updates and I think there’s a few stragglers on the remake end that we’re fixing up this week.

---

<div class="post-metadata">

### Author: ![isaacsas](https://avatars.discourse-cdn.com/v4/letter/i/f6c823/32.png) [@isaacsas](https://discourse.julialang.org/u/isaacsas)
#### Post date: [March 28, 2024, 2:41pm UTC](https://discourse.julialang.org/t/issue-with-updating-modelingtoolkit-and-remake-command/112164/3 "2024-03-28T14:41:05Z")

</div>

Though the current updates would only fix things if they are compatible with Catalyst v13 – otherwise this may require downgrading SciMLBase to an older version before SymbolicIndexingInterface (maybe 2.3?), or waiting for Catalyst v14.

---

<div class="post-metadata">

### Author: ![Nick1](https://avatars.discourse-cdn.com/v4/letter/n/47e85d/32.png) [@Nick1](https://discourse.julialang.org/u/Nick1)
#### Post date: [May 28, 2024, 6:50pm UTC](https://discourse.julialang.org/t/issue-with-updating-modelingtoolkit-and-remake-command/112164/4 "2024-05-28T18:50:25Z")

</div>

I would like to report that the problem regarding the ModelingToolkit persists
