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

entering '%' produces an error #455

Closed
zanchey opened this issue Dec 17, 2012 · 4 comments
Closed

entering '%' produces an error #455

zanchey opened this issue Dec 17, 2012 · 4 comments

Comments

@zanchey
Copy link
Member

zanchey commented Dec 17, 2012

Log in to a clean session running 3d2b12e.
Enter the % character.
The first error message appears, then a new prompt, then the % character, then the second error.

zanchey@mussel ~> Warning: signal_block called off of main thread. Break on debug_thread_error to debug.
zanchey@mussel ~]> %Warning: signal_block called off of main thread. Break on debug_thread_error to debug.

These errors are produced no matter where the character appears in the line.

You also can't submit the command using the enter key if there is a % sign at the beginning of the line.

Debian and Ubuntu.

@xiaq
Copy link
Contributor

xiaq commented Dec 17, 2012

Reproduced here too, latest Archlinux, latest fish.

@xiaq
Copy link
Contributor

xiaq commented Dec 18, 2012

Should be related to process expansion. Stack trace:

#0  debug_thread_error () at common.cpp:2026
#1  0x000000000054cbba in assert_is_main_thread (who=0x58158d "signal_block")
    at common.cpp:2091
#2  0x0000000000541c08 in signal_block () at signal.cpp:662
#3  0x00000000004da11a in process_iterator_t::next_process (this=0x7ffff5ec5aa0,
    out_str=0x7ffff5ec5ab0, out_pid=0x7ffff5ec5aac) at expand.cpp:515
#4  0x00000000004deae5 in find_process (proc=0x7ffff0000acc L"", flags=259,
    out=std::vector of length 0, capacity 1) at expand.cpp:711
Python Exception <class 'gdb.error'> No type named std::basic_string<wchar_t>::_Rep.:
#5  0x00000000004ddbf2 in expand_pid (instr_with_sep=, flags=259,
    out=std::vector of length 0, capacity 1) at expand.cpp:791
Python Exception <class 'gdb.error'> No type named std::basic_string<wchar_t>::_Rep.:
#6  0x00000000004db8ca in expand_string (input=,
    output=std::vector of length 0, capacity 0, flags=259) at expand.cpp:1672
Python Exception <class 'gdb.error'> No type named std::basic_string<wchar_t>::_Rep.:
#7  0x00000000004ddeaf in expand_one (string=, flags=259) at expand.cpp:1780
#8  0x00000000004e5cb7 in tokenize (buff=0x60f1f8 L"%",
    color=std::vector of length 1, capacity 1 = {...}, pos=0, error=0x0,
Python Exception <class 'gdb.error'> No type named std::basic_string<wchar_t>::_Rep.:
    working_directory=, vars=...) at highlight.cpp:1026
Python Exception <class 'gdb.error'> No type named std::basic_string<wchar_t>::_Rep.:
#9  0x00000000004e463f in highlight_shell (buff=,
    color=std::vector of length 1, capacity 1 = {...}, pos=0, error=0x0, vars=...)
    at highlight.cpp:1324
#10 0x000000000051d6f0 in background_highlight_context_t::threaded_highlight (
    this=0x6187b0) at reader.cpp:2428
#11 0x0000000000516435 in threaded_highlight (ctx=0x6187b0) at reader.cpp:2475
#12 0x000000000055bfd2 in iothread_worker (threadPtr=0x5db7e0 <threads+16>)
    at iothread.cpp:117
#13 0x00007ffff766fe0f in start_thread () from /usr/lib/libpthread.so.0
#14 0x00007ffff6e8f31d in clone () from /usr/lib/libc.so.6

@ridiculousfish
Copy link
Member

Should be fixed here:

To git@github.com:fish-shell/fish-shell.git
f9697c8..882a62a master -> master

Process expansion on Linux seems to be working well.

@ridiculousfish
Copy link
Member

Thanks to everyone who reported this.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Apr 19, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants