hoffstadt / DearPyGui

Dear PyGui: A fast and powerful Graphical User Interface Toolkit for Python with minimal dependencies
https://dearpygui.readthedocs.io/en/latest/
MIT License
12.63k stars 669 forks source link

file_dialog crashes when navigating to folder without read permissions #1351

Open peterjolles opened 2 years ago

peterjolles commented 2 years ago

Version of Dear PyGui

Version: 1.0.2 Operating System: Windows 10

My Issue/Question

When using file_dialog and browsing to a folder that the current user does not have access to, dpg will crash.

To Reproduce

Steps to reproduce the behavior:

  1. Open dearpygui.dearpygui.add_file_dialog
  2. Navigate to a folder you don't have permissions to
  3. Try to get into the folder, dpg will crash

Expected behavior

Expectation that dpg will not crash when attempting to navigate into folder one doesn't have permissions to. Behavior should be to stay in the parent directory.

Standalone, minimal, complete and verifiable example

# Here's some code anyone can copy and paste to reproduce your issue
import dearpygui.dearpygui as dpg

dpg.create_context()
dpg.create_viewport()
dpg.setup_dearpygui()

dpg.add_file_dialog(label="File Dialog", show=True)

dpg.show_viewport()
dpg.start_dearpygui()
dpg.destroy_context()
xexpanderx commented 2 years ago

Is this still in consideration? I just got this problem myself when trying to navigate to "My Documents", which ironically I do have permissions for...

hoffstadt commented 1 year ago

Sorry for the late response. This will be fixed.

Mark-AImagineers commented 4 months ago

Version of Dear PyGui

Version 1.10.1 Operating System Windows 10 and 11

My question / Issue

Hello team, i know this is an old thread but I'm having exactly this issue. App crashes when navigating to MyDocuments. I don't know how to fix. I tried using python package elevate, but didn't do anything.

Steps to reproduce the behavior:

Open dearpygui.dearpygui.add_file_dialog Navigate to a folder you don't have permissions to Try to get into the folder, dpg will crash

Expected Behaviour

Expectation that dpg will not crash when attempting to navigate into MyDocuments