eclipse-theia / theia

Eclipse Theia is a cloud & desktop IDE framework implemented in TypeScript.
http://theia-ide.org
Eclipse Public License 2.0
20.04k stars 2.5k forks source link

Windows UNC Path Handling #14387

Closed AlanGitMan closed 2 hours ago

AlanGitMan commented 3 hours ago

The version of Eclipse-theia included in Arduino IDE V2.3.3 is - according to Arduino support - causing a highly reproducible issue with the use of UNC filenames when a Windows client and a Windows fileshare server are in use. I believe this is a known problem of quite long standing - please take this as a request to expedite a fix. .

Bug Description:

My config: Windows 10 22H2 Build 19045.5011 16GB RAM 3.2GHz Intel processor. When Arduino IDE user opens an existing project which resides on a UNC network share like: \\windowserv\arduino\projects\myproject\myproject.ino

no error message is shown but the user only gets an empty template project. If the IDE is closed and restarted, then the project is correctly loaded. This affects any Arduino user who is using Windows to Windows file sharing using UNC. Arduino support says this is due to an issue with UNC filename handling in the Eclipse library.

Steps to Reproduce:

  1. In Arduino V2.3.3 click on file->Open
  2. Enter a UNC path like \\windowserv\arduino\projects\myproject\myproject.ino
  3. Click "Open" button.
  4. No error message occurs, but the user just gets a default empty project with just template "setup" and "loop" functions.
  5. Close the Arduino IDE.
  6. Open it up again - your project is NOW opened correctly.
  7. The same thing happens if you click File-->preferences and set your default sketchbook location to a UNC share and open a project.
  8. If you map the Arduino share to a local drive name (essentially mount the share as a drive letter) - for example map the share as drive "q:" then open q:\projects\myproject\myproject.ino"
    then it all works as it should. This is not an ideal workaround for reasons given below.

Additional Information

This potentially affects any users of Arduino IDE on Windows (which is reckoned to be 70% of users) though in reality it is those using Arduino IDE in shared environments (home networks, schools, colleges, universities) who will be affected. As shown above, the mapped drives workaround is available, but that workaround comes with its own set of issues which arise from thread blocking in the client Windows system when network or hardware problems can occur - even if the shared drive is not actually in use. So the workaround is less than ideal.

msujew commented 2 hours ago

It is indeed a known problem, as it is a duplicate of https://github.com/eclipse-theia/theia/issues/11997. Please continue the discussion in there.

Since the issue seems to be extra relevant to users of the Arduino IDE, I would advise the contributors of Arduino to work on this themselves. I've added the help wanted label quite a while ago to the issue.

AlanGitMan commented 2 hours ago

Well, they say they are waiting for you guys. So I am piggy in the middle here!

msujew commented 2 hours ago

I've listed the issue in our support epic https://github.com/eclipse-theia/theia/issues/13192. However, I find it a bit unexpected that a company (with people that have a history of contributing to Theia), just waits on us (maintainers of a free open source project) do to their work/bidding without any incentive. Not faulting you @AlanGitMan, but we just don't have enough time/resources to address everything in this repo without outside help.