# How to run a Julia package using Visual Studio Code?

**URL:** https://discourse.julialang.org/t/how-to-run-a-julia-package-using-visual-studio-code/135338
**Category:** Specific Domains
**Tags:** question, package
**Created:** [January 30, 2026, 9:45am UTC](https://discourse.julialang.org/t/how-to-run-a-julia-package-using-visual-studio-code/135338 "2026-01-30T09:45:22Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![xulongxu](https://avatars.discourse-cdn.com/v4/letter/x/439d5e/32.png) [@xulongxu](https://discourse.julialang.org/u/xulongxu)
#### Post date: [January 30, 2026, 9:45am UTC](https://discourse.julialang.org/t/how-to-run-a-julia-package-using-visual-studio-code/135338/1 "2026-01-30T09:45:22Z")

</div>

I am reading the article -  
“Quasinormal mode/grey-body factor correspondence for Kerr black holes”, which use the the following pacakge

> **[GitHub - Potatoasad/KerrQuasinormalModes.jl: A Package to Compute mode functions for Kerr Black...](https://github.com/Potatoasad/KerrQuasinormalModes.jl)**
>
> A Package to Compute mode functions for Kerr Black Hole Quasinormal modes, as well as their frequencies, seperation constants and more. Additionally provides an interface for cheap differentiation of such modes.

to compute the the QNM frequencies of the fundamental mode and the  
first overtone of gravitational perturbations (s = −2) for Kerr Black Holes, e.g. Table I.

I have never used Julia before, and I tried to run this package using VS Code. However, I keep encountering error messages when running the code, and it fails to compute any results.

 ![image](https://global.discourse-cdn.com/julialang/original/3X/8/2/820bc307539e61ea4c859984e0e21e0a7813f5af.png)  
This image shows some error messages.

---

<div class="post-metadata">

### Author: ![karei](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/karei/32/214809_2.png) [@karei](https://discourse.julialang.org/u/karei)
#### Post date: [January 30, 2026, 10:18am UTC](https://discourse.julialang.org/t/how-to-run-a-julia-package-using-visual-studio-code/135338/2 "2026-01-30T10:18:41Z")

</div>

Welcome to the Julia community!

The tests call `qnmfunction(; s,l,m,n,a)` but that method is commented out. Only `qnmfunction(::Custom; ...)` exists, so Julia throws a `MethodError` for the keyword-only call.

Also, the old `qnmfunction` depends on `qnm(...)` from `QnmRotationSeries.jl`, and the entire legacy include chain in `src/KerrQuasinormalModes.jl` is commented out, so that dependency chain is broken. 🫠

## Fix

Restore a keyword `qnmfunction` wrapper. A simple solution is to add the following in `src/ModeFunctionInterface/Interface.jl` right after the block comment that ends around line ~188 (just above `struct Custom end`):

```julia
function qnmfunction(; s=-2,l=2,m=2,n=0,a=0.00, N=150)
    seq = ModeSequence(; s=s, l=l, m=m, n=n)
    seq(a; N=N)
end

```

This keeps the old interface working while routing through the internal solver stack. After adding it, Pkg.test() passes. 😉

---

<div class="post-metadata">

### Author: ![xulongxu](https://avatars.discourse-cdn.com/v4/letter/x/439d5e/32.png) [@xulongxu](https://discourse.julialang.org/u/xulongxu)
#### Post date: [January 30, 2026, 11:14am UTC](https://discourse.julialang.org/t/how-to-run-a-julia-package-using-visual-studio-code/135338/3 "2026-01-30T11:14:04Z")

</div>

Thank you for your help！ Can you tell me how to use the package to compute the quasi-normal modes, for example, the author’s instruction:

> Ω = ModeSequence(s=-2,l=2,m=2,n=0) # Pick a mode  
> ψ = Ω(0.8) # Get the QNM mode function at a = 0.8

> ψ.ω # = 0.5860169749084593 - 0.0756295523345646im  
> ψ.Alm # = 2.5852939720024275 + 0.20529748567633602im.

I can’t get these results.

---

<div class="post-metadata">

### Author: ![karei](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/karei/32/214809_2.png) [@karei](https://discourse.julialang.org/u/karei)
#### Post date: [January 30, 2026, 11:31am UTC](https://discourse.julialang.org/t/how-to-run-a-julia-package-using-visual-studio-code/135338/4 "2026-01-30T11:31:58Z")

</div>

Sorry, I can’t help with that. I can only fix structural errors in the code, but I know nothing about Quasinormal Modes for Kerr Black holes.

I suggest you _modify the title of this post_ now to accurately describe your question, thereby attracting experts who can answer it.

For example: “How to use KerrQuasinormalModes.jl to compute the quasi-normal modes.”
