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

REPL: Handle message from complete_methods! when max methods is hit #57138

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

IanButterworth
Copy link
Member

It appears #56963 wasn't a proper fix (although curiously it did appear to work #56963 (comment))

Reported on 1.11.3 https://discourse.julialang.org/t/sympy-makes-repl-to-stuck/124814/11

julia> using SymPy
Precompiling SymPy...
  19 dependencies successfully precompiled in 11 seconds. 33 already precompiled.

julia> sympy.apart(33/4)
8.25000000000000

julia> @syms n
(n,)

julia> ex = 1/(n*(n+3))
    1    
─────────
n⋅(n + 3)

julia> sympy.apart(e┌ Error: Error in the keymap
│   exception =
│    TypeError: in typeassert, expected REPL.REPLCompletions.MethodCompletion, got a value of type REPL.REPLCompletions.TextCompletion
│    Stacktrace:
│      [1] complete_keyword_argument
│        @ ~/.julia/juliaup/julia-1.11.3+0.x64.linux.gnu/share/julia/stdlib/v1.11/REPL/src/REPLCompletions.jl:1040
│      [2] completions(string::String, pos::Int64, context_module::Module, shift::Bool, hint::Bool)
│        @ REPL.REPLCompletions ~/.julia/juliaup/julia-1.11.3+0.x64.linux.gnu/share/julia/stdlib/v1.11/REPL/src/REPLCompletions.jl:1379
│      [3] complete_line(c::REPL.REPLCompletionProvider, s::REPL.LineEdit.PromptState, mod::Module; hint::Bool)
│        @ REPL ~/.julia/juliaup/julia-1.11.3+0.x64.linux.gnu/share/julia/stdlib/v1.11/REPL/src/REPL.jl:637
│      [4] #complete_line#14
│        @ ~/.julia/juliaup/julia-1.11.3+0.x64.linux.gnu/share/julia/stdlib/v1.11/REPL/src/LineEdit.jl:428
│      [5] complete_line
│        @ ~/.julia/juliaup/julia-1.11.3+0.x64.linux.gnu/share/julia/stdlib/v1.11/REPL/src/LineEdit.jl:427
│      [6] complete_line
│        @ ~/.julia/juliaup/julia-1.11.3+0.x64.linux.gnu/share/julia/stdlib/v1.11/REPL/src/LineEdit.jl:369
│      [7] edit_tab (repeats 2 times)
│        @ ~/.julia/juliaup/julia-1.11.3+0.x64.linux.gnu/share/julia/stdlib/v1.11/REPL/src/LineEdit.jl:2419
│      [8] #118
│        @ ~/.julia/juliaup/julia-1.11.3+0.x64.linux.gnu/share/julia/stdlib/v1.11/REPL/src/LineEdit.jl:2465
│      [9] #invokelatest#2
│        @ ./essentials.jl:1055 [inlined]
│     [10] invokelatest
│        @ ./essentials.jl:1052 [inlined]
│     [11] #30
│        @ ~/.julia/juliaup/julia-1.11.3+0.x64.linux.gnu/share/julia/stdlib/v1.11/REPL/src/LineEdit.jl:1711
│     [12] macro expansion
│        @ ~/.julia/juliaup/julia-1.11.3+0.x64.linux.gnu/share/julia/stdlib/v1.11/REPL/src/LineEdit.jl:2861 [inlined]
│     [13] macro expansion
│        @ ./lock.jl:273 [inlined]
│     [14] #282
│        @ ~/.julia/juliaup/julia-1.11.3+0.x64.linux.gnu/share/julia/stdlib/v1.11/REPL/src/LineEdit.jl:2851
└ @ REPL.LineEdit ~/.julia/juliaup/julia-1.11.3+0.x64.linux.gnu/share/julia/stdlib/v1.11/REPL/src/LineEdit.jl:2863

@IanButterworth IanButterworth added the REPL Julia's REPL (Read Eval Print Loop) label Jan 23, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
REPL Julia's REPL (Read Eval Print Loop)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant