Neko uncaught exception (can't create folder)

classic Classic list List threaded Threaded
11 messages Options
Reply | Threaded
Open this post in threaded view
|

Neko uncaught exception (can't create folder)

dlots
I am attempting to use As3ToHaxe.hx converter by Tarwin located here:

http://haxe.org/doc/flash/usingas3classes

Neko is failing on created a folder with FileSystem.createDirectory(folder)

Here is the exception:

Called from S:\_flash\Motion-Twin\haxe/std/neko/FileSystem.hx line 83
Uncaught exception - std@sys_create_dir

--
haXe - an open source web programming language
http://haxe.org
Reply | Threaded
Open this post in threaded view
|

Re: Neko uncaught exception (can't create folder)

dlots
neko As3ToHaxe.n -from "s:/_flash/proj_flash_src/src" -to "s:/_flash/proj_haxe_flash_src/src"

Is what I am executing.
Reply | Threaded
Open this post in threaded view
|

Re: Neko uncaught exception (can't create folder)

Cauê W.
hey, I haven't looked at the source code, but for sure it can't create a folder. Maybe it's security/permissions issue, mabe it's because the directory already exists

cheers!

2011/9/26 daegulma <[hidden email]>
neko As3ToHaxe.n -from "s:/_flash/proj_flash_src/src" -to
"s:/_flash/proj_haxe_flash_src/src"

Is what I am executing.

--
View this message in context: http://haxe.1354130.n2.nabble.com/Neko-uncaught-exception-can-t-create-folder-tp6831112p6831118.html
Sent from the Haxe mailing list archive at Nabble.com.

--
haXe - an open source web programming language
http://haxe.org


--
haXe - an open source web programming language
http://haxe.org
Reply | Threaded
Open this post in threaded view
|

Re: Neko uncaught exception (can't create folder)

dlots
In reply to this post by dlots
Also, does Haxe/Neko need forward or back slash path seperators? If executing with backslash it fails with sys_read_dir
Reply | Threaded
Open this post in threaded view
|

Re: Neko uncaught exception (can't create folder)

Cauê W.
2011/9/26 daegulma <[hidden email]>
Also, does Haxe/Neko need forward or back slash path seperators? If executing
with backslash it fails with sys_read_dir

I've never had any problems with backslashes on windows with neko. Maybe it's the last backslash? I think there is a problem when you have the last backslash set to read the dir.

--
haXe - an open source web programming language
http://haxe.org
Reply | Threaded
Open this post in threaded view
|

Re: Neko uncaught exception (can't create folder)

dlots
Okay, here are the answers to this problem:

For one thing, neko and/or flash requires forward slashes only. Back slashes appear to be stripped and the resulting path is condensed into one folder name.

Regarding this issue... In the As3ToHaxe createFolder path, on Windows, it is attempting to create the root drive path. Ie, it attempts to:

FileSystem.create("s:");

So... why does FileSystem.exists fail on root drive path: FileSystem.exists("s:");
Reply | Threaded
Open this post in threaded view
|

Re: Neko uncaught exception (can't create folder)

dlots
and/or haxe*
Reply | Threaded
Open this post in threaded view
|

Re: Neko uncaught exception (can't create folder)

Cauê W.
does S: exist? Because if it doesn't then it makes sense ; )

Anyway, it really won't be able to "create" an S: drive with createFolder, so really there's your problem ; )

2011/9/26 daegulma <[hidden email]>
and/or haxe*

--
View this message in context: http://haxe.1354130.n2.nabble.com/Neko-uncaught-exception-can-t-create-folder-tp6831112p6831226.html
Sent from the Haxe mailing list archive at Nabble.com.

--
haXe - an open source web programming language
http://haxe.org


--
haXe - an open source web programming language
http://haxe.org
Reply | Threaded
Open this post in threaded view
|

Re: Neko uncaught exception (can't create folder)

Tarwin Stroh-Spijer
Hi,

Sorry I haven't really tested it that much. I hope it's useful though. If you find a bug in it you can easily edit the source on the wiki as that's "repository" at the moment. LOL!


Tarwin Stroh-Spijer
_______________________

Touch My Pixel
http://www.touchmypixel.com/
phone: +61 3 8060 5321
_______________________


On Mon, Sep 26, 2011 at 7:15 PM, Cauê Waneck <[hidden email]> wrote:
does S: exist? Because if it doesn't then it makes sense ; )

Anyway, it really won't be able to "create" an S: drive with createFolder, so really there's your problem ; )

2011/9/26 daegulma <[hidden email]>
and/or haxe*

--
View this message in context: http://haxe.1354130.n2.nabble.com/Neko-uncaught-exception-can-t-create-folder-tp6831112p6831226.html
Sent from the Haxe mailing list archive at Nabble.com.

--
haXe - an open source web programming language
http://haxe.org


--
haXe - an open source web programming language
http://haxe.org


--
haXe - an open source web programming language
http://haxe.org
Reply | Threaded
Open this post in threaded view
|

Re: Neko uncaught exception (can't create folder)

dlots
I just added  if (!FileSystem.exists(folder) && folder.charAt(folder.length-1)!=":") { at line 347. Not sure why FileSystem.exists fails on the drive.

On Mon, Sep 26, 2011 at 7:48 AM, Tarwin Stroh-Spijer <[hidden email]> wrote:
Hi,

Sorry I haven't really tested it that much. I hope it's useful though. If you find a bug in it you can easily edit the source on the wiki as that's "repository" at the moment. LOL!


Tarwin Stroh-Spijer
_______________________

Touch My Pixel
http://www.touchmypixel.com/
phone: <a href="tel:%2B61%203%208060%205321" value="+61380605321" target="_blank">+61 3 8060 5321
_______________________



On Mon, Sep 26, 2011 at 7:15 PM, Cauê Waneck <[hidden email]> wrote:
does S: exist? Because if it doesn't then it makes sense ; )

Anyway, it really won't be able to "create" an S: drive with createFolder, so really there's your problem ; )

2011/9/26 daegulma <[hidden email]>
and/or haxe*

--
View this message in context: http://haxe.1354130.n2.nabble.com/Neko-uncaught-exception-can-t-create-folder-tp6831112p6831226.html
Sent from the Haxe mailing list archive at Nabble.com.

--
haXe - an open source web programming language
http://haxe.org


--
haXe - an open source web programming language
http://haxe.org


--
haXe - an open source web programming language
http://haxe.org


--
haXe - an open source web programming language
http://haxe.org
Reply | Threaded
Open this post in threaded view
|

Re: Neko uncaught exception (can't create folder)

singmajesty
If you are running Windows, you need to use /d to change to a different  
drive than the current one. Is this the problem?

I had no idea of this requirement until a couple weeks ago, when I started  
working primarily from a second hard drive


On Mon, 26 Sep 2011 06:10:16 -0700, [hidden email]  
<[hidden email]> wrote:

> I just added  if (!FileSystem.exists(folder) &&
> folder.charAt(folder.length-1)!=":") { at line 347. Not sure why
> FileSystem.exists fails on the drive.
>
> On Mon, Sep 26, 2011 at 7:48 AM, Tarwin Stroh-Spijer <
> [hidden email]> wrote:
>
>> Hi,
>>
>> Sorry I haven't really tested it that much. I hope it's useful though.  
>> If
>> you find a bug in it you can easily edit the source on the wiki as  
>> that's
>> "repository" at the moment. LOL!
>>
>>
>> Tarwin Stroh-Spijer
>> _______________________
>>
>> Touch My Pixel
>> http://www.touchmypixel.com/
>> phone: +61 3 8060 5321
>> _______________________
>>
>>
>>
>> On Mon, Sep 26, 2011 at 7:15 PM, Cauê Waneck <[hidden email]> wrote:
>>
>>> does S: exist? Because if it doesn't then it makes sense ; )
>>>
>>> Anyway, it really won't be able to "create" an S: drive with  
>>> createFolder,
>>> so really there's your problem ; )
>>>
>>>  2011/9/26 daegulma <[hidden email]>
>>>
>>>> and/or haxe*
>>>>
>>>> --
>>>> View this message in context:
>>>> http://haxe.1354130.n2.nabble.com/Neko-uncaught-exception-can-t-create-folder-tp6831112p6831226.html
>>>> Sent from the Haxe mailing list archive at Nabble.com.
>>>>
>>>> --
>>>> haXe - an open source web programming language
>>>> http://haxe.org
>>>>
>>>
>>>
>>> --
>>> haXe - an open source web programming language
>>> http://haxe.org
>>>
>>
>>
>> --
>> haXe - an open source web programming language
>> http://haxe.org

--
haXe - an open source web programming language
http://haxe.org