-
Notifications
You must be signed in to change notification settings - Fork 142
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
Windows mmap test failures #89
Comments
I agree with you that it seems most likely that this is a problem in base julia. What's funny about that code is that I wrote it without having a working build system on a Windows machine. I managed to install one of the binaries, and then by "inserting" my functions into I will try to get to this at some point, but it may take a while. |
Okay, no rush at all. I don't have a pressing need for this, I was just on a kick looking for packages that already had Travis set up and where Windows-specific testing would be valuable. I don't know enough of the details to be of much help on fixing this one (we could ping a few people for help who would, but probably best to wait until after 0.3 is out), but I'm happy to test things out if you come up with any ideas and don't have access to a Windows machine. |
this can happen in the Windows mmap code and it would be much nicer if it just worked.
I wrote JuliaLang/julia#7242 to partially address this problem. Now And oddly I still get The data corruption when I'm in the REPL could maybe have something to do with byte endianness of the HDF5 library on Windows? Not sure, but reading works fine and consistently when |
Nice work! Two thoughts:
As far as the difference between the REPL and cmd, that's odd. I don't have any ideas. |
I traced through the implementations to get the offset for
The offset for Oh, but hm, if I add another array to the end of the file that is past 65536, then I get a failure to create mapping view. So yeah there are likely some issues. |
Thanks to Jameson's super-useful extra error message info, the difference between REPL and cmd is something to do with permissions:
And on writing
Here's what the resulting test.jld looks like in binary: https://gist.github.com/tkelman/d1f99cde5c143aefc7a9 |
Since the
where (if I've calculated correctly) If it works when you treat it as a regular file but not within HDF5/JLD, then can I ask you to wrap this function in
and step through it, examining all the different variables. (See instructions if you've never used Debug.jl before.) If you do that on both Linux and Windows, hopefully the problem would quickly become apparent. |
Comes back right as a regular file. Will try stepping through with debug. |
What is
|
I take it that One little thing I noticed: |
Wait, my suggestion was borked, and had one too many |
|
Thanks for the confirmation that http://hdf-forum.184993.n3.nabble.com/getting-back-the-full-with-path-filename-from-a-hid-t-td914238.html is interesting, but it suggests that this should work. |
Actually, can you comment out the |
commenting out try, finally, end doesn't make any difference edit: no difference from replacing |
The initialization idea was just simply to check for errors, but (duh) I confess I'm a bit stuck. I'm not sure how one goes about finding out whether that file descriptor is really the right one. I guess within Julia you could could run a test something like this:
just to check whether going from IOStream->file descriptor->IOStream gives you the right answer. |
I guess you could also check that the value of |
Your little test with |
Works for me. |
Not sure if this is still an issue? |
I think it is, the mmap tests are still disabled for Windows https://github.com/timholy/HDF5.jl/blob/d8300406ed619b5cca754919a32edb87a94982cb/test/jld.jl#L350 |
Fixed by #545 |
Was trying to set up AppVeyor Windows CI for this package and uncovered this issue in the process:
This is probably an issue in base Julia's mmap on Windows, but git blame tells me you wrote that section of code.
An AppVeyor build here https://ci.appveyor.com/project/tkelman/hdf5-jl/build/1.0.2/job/04fw9ibhdhlv8tup shows the same issue (except with a messed up backtrace pointing to
process_options at client.jl:282
for some reason?) with the most recent 32 bit Windows binary too.The text was updated successfully, but these errors were encountered: