Revise Not Working with DrWatson Use Case

TI36XPro
Fri, 13 Sep 2024 05:34:23 +0000
General Usage

Hello,

I am having an issue with Revise. I’ll lay out some context and hopefully that will help illustrate the problem.

Let’s say I have a package I am developing called MyPackage. Since I am developing it and frequently changing it, I add it to the current environment by doing Pkg.develop(path="src/MyPackage/").

I also have a project setup using DrWatson. I have a set of functions and variables I always wanted loaded so I follow the guidance discussed here on converting these files into a module.MyPackage is also part of this environment. So my project environment, lets called it MyEnv, looks like this

Status `~/projects/MyEnv/Project.toml`
⌃ [13f3f980] CairoMakie v0.11.4
⌃ [634d3b9d] DrWatson v2.15.0
  [f67ccb44] HDF5 v0.17.2
  [23992714] MAT v0.10.7
  [a7d1346e] MyPackage v0.4.0 `src/MyPackage.jl`
  [189a3867] Reexport v1.2.2
  [de0858da] Printf

And inside src/MyEnv.jl I have

module MyEnv

using Reexport, DrWatson, Printf
@reexport using HDF5, MyPackage, CairoMakie, Printf, MAT

# more code ...

At the top of all my analysis files within this project I do the following as described in the DrWatson docs (linked above).

using DrWatson
@quickactivate :MyEnv

The issue is the following. If I add a new method to MyPackage and update the export list (within MyPackage.jl), I can’t access it without fully qualifying the method name. Why is that? Because I added to the export list, I shouldn’t have to fully qualify it right? Or is something going on here related to the reexporting of MyPackage?

Is there something I should be doing differently here? Does this make sense or have I not described the problem adequately?

Edit: typo

2 posts - 2 participants