-
Notifications
You must be signed in to change notification settings - Fork 90
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[BUG]: method error when used in the debugger #218
Comments
Do you know what debug mode is changing in the code? (Does it remove those error checks?) Or is there some way I could reproduce the bug? |
It seems like it might be a bug in the VSCode debugger. There are no symbol types in the evaluation code, so that error must be from the debugger trying to print some diagnostics. Maybe post this on the Julia vscode GitHub issues as well? |
Thank you for the reply. Using your DynamicExpression.jl code, you could debug the following example code (https://github.com/SymbolicML/DynamicExpressions.jl) in Linux or Windows using vscode + julia extension by pressing F5, you could reproduce similar errors:
|
May I ask what debug mode or IDE do you use in writing these codes? I could make a comparion between vscode and others, and pin down the problems. |
I use vscode as well but I haven’t seen this issue before. What is your Julia version? |
It is quite strange. I used julia of Version 1.9.0 (2023-05-07). |
Oh, wait, I was just able to reproduce it. I think I just haven't ran the code in the Julia debugger before. This is very strange. What variable is the |
It is great that the error could be reproduced. It's indeed very strange. |
Dear MilesCranmer and wenpw. I encountered the same problem when using VScode Debugger or Debugger.jl [REPL] to debug code. How do you usually debug code? My development environment is Ubuntu22.04, Julia 1.9.4. Have you solved this problem? |
Unfortunately I don't know what the issue is. Not sure if @wenpw has solved it either? I usually use VSCode but I tend to not use the Julia debugger. However I think it's important that others can use it so I'm interested to solve this. It seems unrelated to SymbolicRegression.jl though. If you post an issue on https://github.com/julia-vscode/julia-vscode and/or https://github.com/JuliaDebug/Debugger.jl they might know what it is from? I'm happy to help lobby there for support. |
@MilesCranmer @zzccchen Sorry that it is still not solved. And I have tested several versions of SymbolicRegression.jl, they all have the same debug error. |
Sorry to hear this, thank you for your replies @MilesCranmer @wenpw |
To help narrow it down, maybe see if the same issue shows up when using DynamicExpressions.jl alone? |
@MilesCranmer Yes, the same issue shows up when using DynamicExpressions.jl alone. You could try to debug the following test_tree_constrcution.jl at vscode. https://github.com/SymbolicML/DynamicExpressions.jl/blob/master/test/test_tree_construction.jl The same error will appear. |
I wonder if it has to do with the |
I wonder why debug mode and directly run the code has so large difference? |
Hm... Can you try to keep reducing it? So that it is the minimal code possible that still gives an error? |
I could try but I am not sure if I could find the minimal code that still gives an error. |
Hey @wenpw, Have you tried https://github.com/JuliaDebug/Infiltrator.jl? It seems to be a much more robust debugger for Julia than the built-in one in VSCode. I've been trying it and it works quite well for debugging SymbolicRegression.jl! Cheers, |
@MilesCranmer Thank you very much. This would be of great help. |
@MilesCranmer Thank you very much for your code which are very helpful.
I am trying to debug the code using the test_fast_cycle.jl.
There is no problem when I directly run the code.
However, if I use debug mode in Vscode and Julia extensions to check some middle variables, the following bug happens:
[EvaluateEquation.jl]
The Bug is
And even for the example code in DynamicExpressions, using debug mode, the above similar error happens.
Thank you in advance.
Best regards
Version
0.18.0
Operating System
Windows
Interface
Other (specify below)
Relevant log output
Extra Info
No response
The text was updated successfully, but these errors were encountered: