Skip to content
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

MadNLP breaks Julia logging macros #153

Closed
hshose opened this issue Mar 23, 2022 · 1 comment · Fixed by #154
Closed

MadNLP breaks Julia logging macros #153

hshose opened this issue Mar 23, 2022 · 1 comment · Fixed by #154

Comments

@hshose
Copy link

hshose commented Mar 23, 2022

I'm using Julia 1.7 with updated MadNLP 0.4.0:

(@v1.7) pkg> status MadNLP
      Status `~/.julia/environments/v1.7/Project.toml`
  [2621e9c9] MadNLP v0.4.0

Running @info "test" 1 in the REPL produces the following output (as expected):

julia> @info "TEST" 1
┌ Info: TEST
└   1 = 1

When I first import MadNLP and then @info "test" 1, I get the following error:

julia> import MadNLP
julia> @info "TEST" 1
ERROR: MethodError: no method matching get_level(::String)
Closest candidates are:
  get_level(::MadNLP.Logger) at ~/.julia/packages/MadNLP/OUcjZ/src/utils.jl:20
Stacktrace:
 [1] top-level scope
   @ ~/.julia/packages/MadNLP/OUcjZ/src/utils.jl:34

MadNLP seems to overwrite the default logging macros, which is not ideal when using the solver in larger projects.

@frapac
Copy link
Collaborator

frapac commented Mar 23, 2022

Indeed, I confirm that this is a bug in MadNLP (I am facing the same issue). I will try to find a workaround, that issue is indeed annoying.

@sshin23 sshin23 linked a pull request Mar 25, 2022 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants