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

Dokan failed with error -7 for dokany 0.8.0 and -5 for 0.7.4 #236

Closed
kitsmag opened this issue Jan 7, 2016 · 8 comments
Closed

Dokan failed with error -7 for dokany 0.8.0 and -5 for 0.7.4 #236

kitsmag opened this issue Jan 7, 2016 · 8 comments

Comments

@kitsmag
Copy link

kitsmag commented Jan 7, 2016

https://github.com/dokan-dev/dokany 's release 0.8.0 makes some severe changes, which cause fs.expose.dokan.mount to yield error -7, which means

#define DOKAN_VERSION_ERROR -7 /* Requested an incompatible version */

@Liryna
Copy link
Contributor

Liryna commented Jan 7, 2016

👍

@kitsmag
Copy link
Author

kitsmag commented Jan 7, 2016

...and as I mentioned in dokan-dev/dokany#115

0.7.4 also yields a -5 (DOKAN_MOUNT_ERROR) for a simple example such as

from fs.osfs import OSFS
from fs.expose import dokan
fs = OSFS('.')
mp = dokan.mount(fs, 'Q')

@kitsmag kitsmag changed the title Dokan failed with error -7 for dokany 0.8.0 Dokan failed with error -7 for dokany 0.8.0 and -5 for 0.7.4 Jan 7, 2016
@Liryna
Copy link
Contributor

Liryna commented Jan 7, 2016

PyFilesystem has to be updated to work with dokany 0.8.0
https://github.com/dokan-dev/dokany/wiki/Update-dokan-legacy-application-to-Dokany

About 0.7.4, I have no idea, it should work if it was working with dokan 0.6.0

@zommuter
Copy link

zommuter commented Jan 8, 2016

Ok, I started #241 for this, currently it's messed up and e.g.

from fs.expose import dokan
from fs.osfs import OSFS
osfs = OSFS('.')
#dm = dokan.mount(osfs, 'Q:\\', flags=dokan.DOKAN_OPTION_DEBUG)
dm = dokan.mount(osfs, 'Q:\\', flags = 0x1234)

yields

Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "fs\expose\dokan\__init__.py", line 1018, in _do_mount
    mount(fs,drive,**opts)
  File "fs\expose\dokan\__init__.py", line 922, in mount
    res = libdokan.DokanMain(ctypes.byref(opts),ctypes.byref(opstruct))
WindowsError: exception: access violation reading 0x0000123400000000
Traceback (most recent call last):
  File "test_dokan.py", line 5, in <module>
    dm = dokan.mount(osfs, 'Q:\\', flags = 0x1234)
  File "C:\Users\kit\Documents\src\pyfilesystem\fs\expose\dokan\__init__.py", line 931, in mount
    check_ready(mp)
  File "C:\Users\kit\Documents\src\pyfilesystem\fs\expose\dokan\__init__.py", line 898, in check_ready
    check_alive(mp)
  File "C:\Users\kit\Documents\src\pyfilesystem\fs\expose\dokan\__init__.py", line 890, in check_alive
    raise OSError("dokan mount process exited prematurely")
OSError: dokan mount process exited prematurely

Note how the flag (0x1234) seems to be misinterpreted as a pointer...

@zommuter
Copy link

zommuter commented Jan 8, 2016

Concerning 0.7.4, maybe 0.8.0 didn't cleanly uninstall, I haven't bothered too much trying 0.6.0 etc

@zommuter zommuter mentioned this issue Jan 8, 2016
@lurch
Copy link
Contributor

lurch commented Jan 8, 2016

Concerning 0.7.4, maybe 0.8.0 didn't cleanly uninstall...

To make different versions easier to test, you could try testing inside a VM, using VM images from https://dev.windows.com/en-us/microsoft-edge/tools/vms/

@arekbulski
Copy link

arekbulski commented Aug 1, 2016

I advise this issue be closed. @Liryna is already working on Dokan support #256 and old verions should be of no concern. We should consolidate.

@lurch
Copy link
Contributor

lurch commented Aug 1, 2016

Consolidation sounds good to me. And it's good to see that Dokan itself is being actively maintained again, removing the need for supporting old (ancient) versions.

@lurch lurch closed this as completed Aug 1, 2016
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

5 participants