# \#debug

**URL:** https://discourse.julialang.org/tag/debug/64.md?page=1

[Latest](https://discourse.julialang.org/latest.md) · [Categories](https://discourse.julialang.org/categories.md) · [Tags](https://discourse.julialang.org/tags.md)

**Page:** 2

---

## [3 Layered Neural Network for a simple curve fit not working](https://discourse.julialang.org/t/3-layered-neural-network-for-a-simple-curve-fit-not-working/94078)

<div class="topic-metadata">

**Author:** [@RSH](https://discourse.julialang.org/u/RSH)\
**Replies:** 2\
**Last updated:** [February 6, 2023, 12:30am UTC](https://discourse.julialang.org/t/3-layered-neural-network-for-a-simple-curve-fit-not-working/94078 "2023-02-06T00:30:29Z")

</div>

I am currently attempting to utilize a three-layered neural network to model the function cos(x). Despite extensive efforts to debug my code, I have been unable to identify and rectify the source of error. It is my belie…

---

## [How to get a stacktrace](https://discourse.julialang.org/t/how-to-get-a-stacktrace/9960)

<div class="topic-metadata">

**Author:** [@leoll2](https://discourse.julialang.org/u/leoll2)\
**Replies:** 5\
**Last updated:** [January 12, 2023, 1:15pm UTC](https://discourse.julialang.org/t/how-to-get-a-stacktrace/9960 "2023-01-12T13:15:18Z")

</div>

My question is simple: When I perform an operation, I need to get a list of all the functions that get called during its execution. For example: function foo() ... rand(Int32) end function bar() foo() end …

---

## [After using VS Code debugger (compiled mode), error message of Optimization.jl appeared for a previously working code](https://discourse.julialang.org/t/after-using-vs-code-debugger-compiled-mode-error-message-of-optimization-jl-appeared-for-a-previously-working-code/89374)

<div class="topic-metadata">

**Author:** [@tlyim](https://discourse.julialang.org/u/tlyim)\
**Replies:** 0\
**Last updated:** [October 27, 2022, 2:12pm UTC](https://discourse.julialang.org/t/after-using-vs-code-debugger-compiled-mode-error-message-of-optimization-jl-appeared-for-a-previously-working-code/89374 "2022-10-27T14:12:56Z")

</div>

I have a working Julia code, which was converted from a working Matlab code. There were some minor differences in the results. I wanted to confirm whether they were due to an imperfect conversion of Matlab’s fmincon func…

---

## [Debugging a segfault with lldb](https://discourse.julialang.org/t/debugging-a-segfault-with-lldb/89103)

<div class="topic-metadata">

**Author:** [@jules](https://discourse.julialang.org/u/jules)\
**Replies:** 2\
**Last updated:** [October 22, 2022, 5:05pm UTC](https://discourse.julialang.org/t/debugging-a-segfault-with-lldb/89103 "2022-10-22T17:05:05Z")

</div>

I’m trying to find out why RadeonProRender.jl segfaults on Mac. I put the code at the bottom into a script rpr.jl and then ran this: lldb julia -- rpr.jl (lldb) target create "julia" Current executable set to 'julia' (…

---

## [VSCode Debugger Crashing On Working Code](https://discourse.julialang.org/t/vscode-debugger-crashing-on-working-code/89096)

<div class="topic-metadata">

**Author:** [@HashBrown](https://discourse.julialang.org/u/HashBrown)\
**Replies:** 0\
**Last updated:** [October 22, 2022, 1:46am UTC](https://discourse.julialang.org/t/vscode-debugger-crashing-on-working-code/89096 "2022-10-22T01:46:34Z")

</div>

I have code that works when I execute it in the REPL and when I use the julia command from the command line directly. However, when I run the debugger on an attempted dispatch the debugger crashes with: ┌ Error: Some …

---

## [An easy way to debug the julia code in base/](https://discourse.julialang.org/t/an-easy-way-to-debug-the-julia-code-in-base/44914)

<div class="topic-metadata">

**Author:** [@mitsuruk](https://discourse.julialang.org/u/mitsuruk)\
**Replies:** 10\
**Last updated:** [September 14, 2022, 4:41pm UTC](https://discourse.julialang.org/t/an-easy-way-to-debug-the-julia-code-in-base/44914 "2022-09-14T16:41:45Z")

</div>

Hi, Julian expert people. What is the easiest way to debug a modification to the source code in julia/base if I change the Julia code in base/string/? Specifically, I would like to know how to easily debugging way the …

---

## [Debugging Julia code in VSCode opens Python debugger instead](https://discourse.julialang.org/t/debugging-julia-code-in-vscode-opens-python-debugger-instead/87198)

<div class="topic-metadata">

**Author:** [@Shayan](https://discourse.julialang.org/u/Shayan)\
**Replies:** 1\
**Last updated:** [September 13, 2022, 10:27am UTC](https://discourse.julialang.org/t/debugging-julia-code-in-vscode-opens-python-debugger-instead/87198 "2022-09-13T10:27:40Z")

</div>

I’m trying to debug a Julia script in VSCode, But the debugger opens the Python debugger instead: There isn’t an option for debugging .jl files. According to the official doc, I can hit F5 to trigger the debugger…

---

## [Julia debugging](https://discourse.julialang.org/t/julia-debugging/86512)

<div class="topic-metadata">

**Author:** [@AbhimanyuAryan](https://discourse.julialang.org/u/AbhimanyuAryan)\
**Replies:** 4\
**Last updated:** [August 30, 2022, 4:04pm UTC](https://discourse.julialang.org/t/julia-debugging/86512 "2022-08-30T16:04:37Z")

</div>

Can someone point me into Julia’s VSCode debugging Guide/Tutorial(if possible a video tutorial) like C++ in Visual Studio? I want to run the script and step out, step in, and set breakpoints. See values of variables etc …

---

## [Some way to debug syntax errors?](https://discourse.julialang.org/t/some-way-to-debug-syntax-errors/86336)

<div class="topic-metadata">

**Author:** [@nsajko](https://discourse.julialang.org/u/nsajko)\
**Replies:** 1\
**Last updated:** [August 25, 2022, 5:12pm UTC](https://discourse.julialang.org/t/some-way-to-debug-syntax-errors/86336 "2022-08-25T17:12:46Z")

</div>

I’ve got a syntax error in my code (in a function in a module) and I can’t seem to figure it out. The expression goes something like this: ntuple( let a = b i -\> expr(a, i) end, Val{c}()) According to the err…

---

## [Infiltrator and Revise](https://discourse.julialang.org/t/infiltrator-and-revise/83539)

<div class="topic-metadata">

**Author:** [@TI36XPro](https://discourse.julialang.org/u/TI36XPro)\
**Replies:** 1\
**Last updated:** [July 28, 2022, 4:12pm UTC](https://discourse.julialang.org/t/infiltrator-and-revise/83539 "2022-07-28T16:12:08Z")

</div>

Hello, I am currently debugging some functions in a package I am writing for myself. I do the actual code writing in VSCode but I have a REPL open with the package loaded (using MyPackage) as well as Infiltrator.jl. The…

---

## [VSCode Julia debugger usability](https://discourse.julialang.org/t/vscode-julia-debugger-usability/58121)

<div class="topic-metadata">

**Author:** [@Zhong\_Pan](https://discourse.julialang.org/u/Zhong_Pan)\
**Replies:** 19\
**Last updated:** [July 20, 2022, 12:16pm UTC](https://discourse.julialang.org/t/vscode-julia-debugger-usability/58121 "2022-07-20T12:16:46Z")

</div>

This is not a new topic, and I am aware progress is being made… Just would like to bump its priority if possible. :slight\_smile: Currently the VSCode Julia debugger’s standard mode is too slow for practical use if large…

---

## [Debugging code in Pluto.jl notebook](https://discourse.julialang.org/t/debugging-code-in-pluto-jl-notebook/83945)

<div class="topic-metadata">

**Author:** [@Naadiyaar](https://discourse.julialang.org/u/Naadiyaar)\
**Replies:** 1\
**Last updated:** [July 8, 2022, 12:24pm UTC](https://discourse.julialang.org/t/debugging-code-in-pluto-jl-notebook/83945 "2022-07-08T12:24:02Z")

</div>

Hello there, I’m trying to create a simple application in Pluto. As I use Pluto for all my DS work, and it is my main code writing tool in Julia, thought it would be good to use it for software development, but I’m faci…

---

## [How can I debug an "include("file")'d script?](https://discourse.julialang.org/t/how-can-i-debug-an-include-file-d-script/25143)

<div class="topic-metadata">

**Author:** [@j4ksch](https://discourse.julialang.org/u/j4ksch)\
**Replies:** 3\
**Last updated:** [June 8, 2022, 3:18pm UTC](https://discourse.julialang.org/t/how-can-i-debug-an-include-file-d-script/25143 "2022-06-08T15:18:04Z")

</div>

Hi there, thanks for all of your great work. I love the fact that there is a debugger now and I’m trying to use it to debug a file that I would normally run via $ julia "script.jl" Lets assume the content of the file …

---

## [I couldn't debug codes that ran normally](https://discourse.julialang.org/t/i-couldnt-debug-codes-that-ran-normally/82311)

<div class="topic-metadata">

**Author:** [@Ouyuan](https://discourse.julialang.org/u/Ouyuan)\
**Replies:** 1\
**Last updated:** [June 6, 2022, 1:27pm UTC](https://discourse.julialang.org/t/i-couldnt-debug-codes-that-ran-normally/82311 "2022-06-06T13:27:38Z")

</div>

I could run my code correctly. But when I wanted to debugger and check some variables, it seemed that the debugger couldn’t get through function fft! in the FFTW package. The debugger broke down in FFTW package and I cou…

---

## [Precompiling ImageView generates an infinite cascade of windows](https://discourse.julialang.org/t/precompiling-imageview-generates-an-infinite-cascade-of-windows/81575)

<div class="topic-metadata">

**Author:** [@gdalle](https://discourse.julialang.org/u/gdalle)\
**Replies:** 3\
**Last updated:** [May 25, 2022, 7:04am UTC](https://discourse.julialang.org/t/precompiling-imageview-generates-an-infinite-cascade-of-windows/81575 "2022-05-25T07:04:00Z")

</div>

Hi there! I’m trying to install ImageView but precompilation doesn’t work. Instead, it spawns an infinite sequence of other (terminal?) windows and I have no choice but to interrupt the process. Has anyone encountered a…

---

## [\*\* On entry to DLASCLS parameter number 4 had an illegal value](https://discourse.julialang.org/t/on-entry-to-dlascls-parameter-number-4-had-an-illegal-value/80657)

<div class="topic-metadata">

**Author:** [@fredrikpaues](https://discourse.julialang.org/u/fredrikpaues)\
**Replies:** 2\
**Last updated:** [May 14, 2022, 5:37am UTC](https://discourse.julialang.org/t/on-entry-to-dlascls-parameter-number-4-had-an-illegal-value/80657 "2022-05-14T05:37:05Z")

</div>

I have some code that works perfectly when run sequentially. But when I decorate a for loop with Threads.@threads I get a scrambled error message which I presume is the following written several times by different thread…

---

## [Debugging in VS Code has difference variable scope behavior](https://discourse.julialang.org/t/debugging-in-vs-code-has-difference-variable-scope-behavior/80226)

<div class="topic-metadata">

**Author:** [@msena](https://discourse.julialang.org/u/msena)\
**Replies:** 6\
**Last updated:** [May 13, 2022, 1:02am UTC](https://discourse.julialang.org/t/debugging-in-vs-code-has-difference-variable-scope-behavior/80226 "2022-05-13T01:02:02Z")

</div>

Hi, I am trying to debug some code and upon some experimentation it seems that the debugger in visual studio code has a different scoping behavior than when running stuff no the REPL? Consider the following example (may…

---

## [File not found in workspace](https://discourse.julialang.org/t/file-not-found-in-workspace/79926)

<div class="topic-metadata">

**Author:** [@Naadiyaar](https://discourse.julialang.org/u/Naadiyaar)\
**Replies:** 1\
**Last updated:** [April 24, 2022, 3:08am UTC](https://discourse.julialang.org/t/file-not-found-in-workspace/79926 "2022-04-24T03:08:21Z")

</div>

I created a .jl file in a regular directory, but when ever i chose “Debug file in new process” or “run file in new process” give me this error =\> File not found in workspace. Using Julia version 1.7.2 with VS Code exte…

---

## [Segfault when invoking Julia callback function from C](https://discourse.julialang.org/t/segfault-when-invoking-julia-callback-function-from-c/79541)

<div class="topic-metadata">

**Author:** [@Octogonapus](https://discourse.julialang.org/u/Octogonapus)\
**Replies:** 10\
**Last updated:** [April 20, 2022, 3:51pm UTC](https://discourse.julialang.org/t/segfault-when-invoking-julia-callback-function-from-c/79541 "2022-04-20T15:51:50Z")

</div>

I am trying to pass a Julia function to a C library (aws-c-mqtt) which will use it as a callback when an asynchronous event occurs. I am running in to trouble because some of the parameters passed to this callback appear…

---

## [JULIA\_DEBUG environment variable](https://discourse.julialang.org/t/julia-debug-environment-variable/73278)

<div class="topic-metadata">

**Author:** [@e3c6](https://discourse.julialang.org/u/e3c6)\
**Replies:** 5\
**Last updated:** [April 19, 2022, 3:05pm UTC](https://discourse.julialang.org/t/julia-debug-environment-variable/73278 "2022-04-19T15:05:30Z")

</div>

I don’t understand how JULIA\_DEBUG environment variable works. module A foo() = @debug "foo" end A.foo() # nothing printed ENV\["JULIA\_DEBUG"\] = Main.A A.foo() # nothing printed Why nothing is printed there? However…

---

## [Multithreading and "silent errors"](https://discourse.julialang.org/t/multithreading-and-silent-errors/78983)

<div class="topic-metadata">

**Author:** [@unis](https://discourse.julialang.org/u/unis)\
**Replies:** 1\
**Last updated:** [April 4, 2022, 6:39am UTC](https://discourse.julialang.org/t/multithreading-and-silent-errors/78983 "2022-04-04T06:39:43Z")

</div>

Consider the following MWE: using Base.Threads: @spawn function f() error("Some error") end function g() while true sleep(1) end end @info "Initialize multi-threaded processing ($(Threads.nthreads…

---

## [Debugging distributed code](https://discourse.julialang.org/t/debugging-distributed-code/78857)

<div class="topic-metadata">

**Author:** [@Casper](https://discourse.julialang.org/u/Casper)\
**Replies:** 0\
**Last updated:** [April 1, 2022, 9:23am UTC](https://discourse.julialang.org/t/debugging-distributed-code/78857 "2022-04-01T09:23:41Z")

</div>

The build in debugger from VSCode gets lost once a distributed process is started, is there a way to debug distributed code?

---

## [How to reset GPU after launch failure](https://discourse.julialang.org/t/how-to-reset-gpu-after-launch-failure/28768)

<div class="topic-metadata">

**Author:** [@Michael\_Benton](https://discourse.julialang.org/u/Michael_Benton)\
**Replies:** 8\
**Last updated:** [March 18, 2022, 1:49pm UTC](https://discourse.julialang.org/t/how-to-reset-gpu-after-launch-failure/28768 "2022-03-18T13:49:16Z")

</div>

If I write a kernel that fails for whatever reason, julia becomes unable to use the GPU for the remainder of the session example : julia\>cu(\[1.,2.\]) CUDA error: unspecified launch failure (code #719, ERROR\_LAUNCH\_FAIL…

---

## [Debugger status and future plans?](https://discourse.julialang.org/t/debugger-status-and-future-plans/43638)

<div class="topic-metadata">

**Author:** [@tue](https://discourse.julialang.org/u/tue)\
**Replies:** 122\
**Last updated:** [February 7, 2022, 3:52am UTC](https://discourse.julialang.org/t/debugger-status-and-future-plans/43638 "2022-02-07T03:52:37Z")

</div>

I am a big fan of Julia as a programming language, but the lack of a decent debugger keeps turning me away every time I seriously consider changing to it. Now last time I tested the debugging environment out was last su…

---

## [VSCode Debugging Question](https://discourse.julialang.org/t/vscode-debugging-question/74301)

<div class="topic-metadata">

**Author:** [@TI36XPro](https://discourse.julialang.org/u/TI36XPro)\
**Replies:** 1\
**Last updated:** [January 9, 2022, 10:32pm UTC](https://discourse.julialang.org/t/vscode-debugging-question/74301 "2022-01-09T22:32:04Z")

</div>

I’m not sure I am doing this properly - maybe I am missing something and someone wiser than me can steer me right. I am using Julia 1.6.2 in VsCode 1.63.2 on Windows Subsystem for Linux 1 (WSL1), running Ubuntu. When I …

---

## [Check if current file is "main" when debugging](https://discourse.julialang.org/t/check-if-current-file-is-main-when-debugging/73893)

<div class="topic-metadata">

**Author:** [@Yue-Zhengyuan](https://discourse.julialang.org/u/Yue-Zhengyuan)\
**Replies:** 2\
**Last updated:** [January 3, 2022, 9:14am UTC](https://discourse.julialang.org/t/check-if-current-file-is-main-when-debugging/73893 "2022-01-03T09:14:56Z")

</div>

In Julia documentation, it is said that to determine that a file is run as the main script, one can check if abspath(PROGRAM\_FILE) == @\_\_FILE\_\_ is true. When directly running the file, this works fine. However, when debu…

---

## [Another Debugger Problem](https://discourse.julialang.org/t/another-debugger-problem/72870)

<div class="topic-metadata">

**Author:** [@kw\_martin](https://discourse.julialang.org/u/kw_martin)\
**Replies:** 1\
**Last updated:** [December 18, 2021, 6:29pm UTC](https://discourse.julialang.org/t/another-debugger-problem/72870 "2021-12-18T18:29:49Z")

</div>

Still trying to figure out a reasonable debugging strategy. I keep going back and forth between Debugger and VSCode and can’t get either to work adequately. Biggest problem with VSCode is I can’t understand error message…

---

## [Different behavior for same \`@code\_llvm\` for voxel traversal](https://discourse.julialang.org/t/different-behavior-for-same-code-llvm-for-voxel-traversal/71695)

<div class="topic-metadata">

**Author:** [@goretkin](https://discourse.julialang.org/u/goretkin)\
**Replies:** 14\
**Last updated:** [November 20, 2021, 12:33am UTC](https://discourse.julialang.org/t/different-behavior-for-same-code-llvm-for-voxel-traversal/71695 "2021-11-20T00:33:51Z")

</div>

I have a function that takes in a line segment. I wanted to benchmark the performance and see if there is a difference whether the line segment is specified with endpoints given in integers or floats. The function has an…

---

## [Tab complete for unicode variables in VS Code debug console?](https://discourse.julialang.org/t/tab-complete-for-unicode-variables-in-vs-code-debug-console/69450)

<div class="topic-metadata">

**Author:** [@thompsonmj](https://discourse.julialang.org/u/thompsonmj)\
**Replies:** 2\
**Last updated:** [November 7, 2021, 8:04pm UTC](https://discourse.julialang.org/t/tab-complete-for-unicode-variables-in-vs-code-debug-console/69450 "2021-11-07T20:04:24Z")

</div>

I can’t seem to use variables containing special Unicode characters (e.g. \\alpha\<tab\>) at the debug console because pressing Tab jumps to the next object rather than completing the character. Is this an issue with VS Co…

---

## [Automatically close "Julia Debugger" terminal after program ends](https://discourse.julialang.org/t/automatically-close-julia-debugger-terminal-after-program-ends/56351)

<div class="topic-metadata">

**Author:** [@luc-j-bourhis](https://discourse.julialang.org/u/luc-j-bourhis)\
**Replies:** 1\
**Last updated:** [October 31, 2021, 2:46pm UTC](https://discourse.julialang.org/t/automatically-close-julia-debugger-terminal-after-program-ends/56351 "2021-10-31T14:46:45Z")

</div>

By default, every time a debug session is started, a new terminal “Julia Debugger” is started. When the program finishes, one has to hit “enter” to close it as instructed by the message “Julia debuggee finished. Press EN…

[Previous page](https://discourse.julialang.org/tag/debug/64.md?match_all_tags=true&tags%5B%5D=debug)

[Next page](https://discourse.julialang.org/tag/debug/64.md?match_all_tags=true&page=2&tags%5B%5D=debug)
