# Should I turn on/off repeatedly to reflect changes of currently developing packages?

**URL:** https://discourse.julialang.org/t/should-i-turn-on-off-repeatedly-to-reflect-changes-of-currently-developing-packages/47560
**Category:** New to Julia
**Tags:** package, revise
**Created:** [September 30, 2020, 11:26pm UTC](https://discourse.julialang.org/t/should-i-turn-on-off-repeatedly-to-reflect-changes-of-currently-developing-packages/47560 "2020-09-30T23:26:28Z")
**Posts on this page:** 1
**Showing post:** 5

<div class="post-metadata">

### Author: ![iHany](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/ihany/32/18151_2.png) [@iHany](https://discourse.julialang.org/u/iHany)
#### Post date: [October 1, 2020, 12:21am UTC](https://discourse.julialang.org/t/should-i-turn-on-off-repeatedly-to-reflect-changes-of-currently-developing-packages/47560/5 "2020-10-01T00:21:27Z")

</div>

1. A part of source code

```julia
function reset!(clock::Clock)
    error("test") # to check Revise.jl
    clock.t = 0.0
    return clock
end

```

1. `reset!` gives an error

```julia
julia> using FymEnvs
[Info: Precompiling FymEnvs [d6fd7ba0-2ca9-4676-ba23-5bed9e863cfb]
using
julia> clock = Clock(0.01, 1)
Clock(0.0, 0.01, 10.0, 1001, [0.0, 0.01], 1)

julia> reset!(clock)
ERROR: test
Stacktrace:
 [1] error(::String) at ./error.jl:33
 [2] reset!(::Clock) at /home/jinrae/github/julia/FymEnvs/src/FymCore.jl:58
 [3] top-level scope at REPL[3]:1

```

1. `dev` and `using Revise; using FymEnvs`

```julia
(@v1.5) pkg> dev .
[ Info: Resolving package identifier `.` as a directory at `~/github/julia/FymEnvs`.
Path `.` exists and looks like the correct package. Using existing path.
  Resolving package versions...
No Changes to `~/.julia/environments/v1.5/Project.toml`
No Changes to `~/.julia/environments/v1.5/Manifest.toml`

julia> using Revise

julia> using FymEnvs

julia> clock = Clock(0.01, 1)
Clock(2.0e-323, 0.01, 10.0, 1001, [0.0, 0.01], 1)

julia> reset!(clock)
ERROR: test
Stacktrace:
 [1] error(::String) at ./error.jl:33
 [2] reset!(::Clock) at /home/jinrae/github/julia/FymEnvs/src/FymCore.jl:58
 [3] top-level scope at REPL[5]:1

julia> reset!(clock) # error msg removed in script
ERROR: test
Stacktrace:
 [1] error(::String) at ./error.jl:33
 [2] reset!(::Clock) at /home/jinrae/github/julia/FymEnvs/src/FymCore.jl:58
 [3] top-level scope at REPL[5]:1

```

Still does not work for me.

Note: of course it works after turning off/on REPL with changes.

```julia
julia> using FymEnvs
[Info: Precompiling FymEnvs [d6fd7ba0-2ca9-4676-ba23-5bed9e863cfb]

julia> clock = Clock(0.01, 1)
Clock(3.0e-323, 0.01, 10.0, 1001, [0.0, 0.01], 1)

julia> reset!(clock)
Clock(0.0, 0.01, 10.0, 1001, [0.0, 0.01], 1)

```

---

_[View the full topic](https://discourse.julialang.org/t/should-i-turn-on-off-repeatedly-to-reflect-changes-of-currently-developing-packages/47560)._
