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

ranger crashed when trying to delete files #2300

Closed
lakshyabijarnia opened this issue Apr 2, 2021 · 3 comments
Closed

ranger crashed when trying to delete files #2300

lakshyabijarnia opened this issue Apr 2, 2021 · 3 comments

Comments

@lakshyabijarnia
Copy link

lakshyabijarnia commented Apr 2, 2021

Runtime Environment

  • Operating system and version: ubuntu 20.04
  • Terminal emulator and version: GNOME Terminal version 3.36.2 A terminal emulator for the GNOME desktop
    Using VTE version 0.60.3 +BIDI +GNUTLS +ICU +SYSTEMD
  • Python version: 3.8.5 (default, Jan 27 2021, 15:41:15) [GCC 9.3.0]
  • Ranger version/commit: ranger 1.9.3
  • Locale: en_IN.ISO8859-1

Current Behavior

Expected Behavior

Context

I was trying to trash two files with help of ranger but as soon as i confirmed and entered y in the confirmation space it crashed and the file did not get trashed

Possible Solutions

Steps to reproduce

  1. open ranger in terminal
  2. select any file for trash
  3. enter y in the conformation space.

Traceback

    fm.loop()
  File "/usr/lib/python3/dist-packages/ranger/core/fm.py", line 383, in loop
    ui.handle_input()
  File "/usr/lib/python3/dist-packages/ranger/gui/ui.py", line 266, in handle_input
    self.handle_key(key)
  File "/usr/lib/python3/dist-packages/ranger/gui/ui.py", line 196, in handle_key
    elif not DisplayableContainer.press(self, key):
  File "/usr/lib/python3/dist-packages/ranger/gui/displayable.py", line 275, in press
    focused_obj.press(key)
  File "/usr/lib/python3/dist-packages/ranger/gui/widgets/console.py", line 188, in press
    self.type_key(key)
  File "/usr/lib/python3/dist-packages/ranger/gui/widgets/console.py", line 214, in type_key
    self._answer_question(answer)
  File "/usr/lib/python3/dist-packages/ranger/gui/widgets/console.py", line 197, in _answer_question
    callback(answer)
  File "/usr/lib/python3/dist-packages/ranger/config/commands.py", line 759, in _question_callback
    self.fm.execute_file(files, label='trash')
  File "/usr/lib/python3/dist-packages/ranger/core/actions.py", line 459, in execute_file
    filenames = [f.path for f in files]
  File "/usr/lib/python3/dist-packages/ranger/core/actions.py", line 459, in <listcomp>
    filenames = [f.path for f in files]
AttributeError: 'str' object has no attribute 'path'

ranger crashed.

@toonn
Copy link
Member

toonn commented Apr 3, 2021

Are you sure this was with delete and not trash? Trash had problems that have recently been fixed on master.

@lakshyabijarnia
Copy link
Author

lakshyabijarnia commented Apr 18, 2021

sorry this was problem with trash

@toonn
Copy link
Member

toonn commented Apr 18, 2021

Then I'll go ahead and close this because that issue was fixed in #1871.

@toonn toonn closed this as completed Apr 18, 2021
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

No branches or pull requests

2 participants