jdf / Processing.py-Bugs

A home for all bugs and feature requests about Python Mode for the Processing Development Environment.
41 stars 8 forks source link

loadStrings returns None in Processing 3.3.6 on Windows 10 #193

Closed awmartin closed 6 years ago

awmartin commented 6 years ago

A new sketch with the following contents:

content = loadStrings("hello.txt")
print content

Prints the value None when executed. This behavior is the same whether the relevant code is placed in setup() or in the root level of an empty sketch. The "hello.txt" file is present in the data/ folder of the sketch folder.

loadstrings bug in python mode 3 3 6

This is the case in both the 64-bit and 32-bit versions of Processing for Windows 3.3.6.

awmartin commented 6 years ago

I should also add that the Python open() command also fails, but with file not found, where it succeeds on macOS. I've also tried with "data\hello.txt" and the full path: "C:\Users\awmartin\Documents\Processing\pytest\data\hello.txt"

open bug in python mode 3 3 6

villares commented 6 years ago

I can confirm loadStrings() is OK on Mac OS, so can anyone else test on Windows, please?

screen shot 2017-10-09 at 10 11 22 pm

jdf commented 6 years ago

I've tested it on Windows 10 and cannot reproduce the bug.

awmartin commented 6 years ago

I filed a parallel issue on the processing.py repo. I produced it on two Windows machines but not on a third I tested. I'm assuming it has to do with something specific to those machines though, until I find a more consistent repro. Closing this one and keeping the other open.