# Error compiling source code

**URL:** https://community.haxe.org/t/error-compiling-source-code/3737
**Category:** Haxe
**Created:** [October 30, 2022, 10:09pm UTC](https://community.haxe.org/t/error-compiling-source-code/3737 "2022-10-30T22:09:25Z")
**Posts on this page:** 8
**Page:** 1

<div class="post-metadata">

### Author: ![TechSecWasTaken](https://community.haxe.org/user_avatar/community.haxe.org/techsecwastaken/32/2010_2.png) [@TechSecWasTaken](https://community.haxe.org/u/TechSecWasTaken)
#### Post date: [October 30, 2022, 10:09pm UTC](https://community.haxe.org/t/error-compiling-source-code/3737/1 "2022-10-30T22:09:26Z")

</div>

I was trying to compile source code for my friend’s FNF mod, and I get this in response after running it with `-verbose`:

```haxe
Initializing project...
Using project file: F:\VS HD 3.0\vs-hd-v3-source-code/project.xml
Reading Lime config: C:\Users\moose\.lime\config.xml
Called from ? line 1
Called from CommandLineTools.hx line 1904
Called from CommandLineTools.hx line 22
Called from a C function
Called from CommandLineTools.hx line 124
Called from CommandLineTools.hx line 1705
Called from lime/tools/ProjectXMLParser.hx line 21
Called from a C function
Called from lime/tools/ProjectXMLParser.hx line 50
Called from lime/tools/ProjectXMLParser.hx line 2041
Called from lime/tools/ProjectXMLParser.hx line 1538
Called from lime/tools/ProjectXMLParser.hx line 608
Called from a C function
Called from lime/tools/ProjectXMLParser.hx line 719
Called from a C function
Called from lime/tools/ProjectXMLParser.hx line 719
Called from a C function
Called from lime/tools/ProjectXMLParser.hx line 709
Called from /Users/runner/hostedtoolcache/haxe/4.2.5/x64/std/neko/_std/sys/FileSystem.hx line 69
Called from /Users/runner/hostedtoolcache/haxe/4.2.5/x64/std/neko/_std/sys/FileSystem.hx line 60
Uncaught exception - std@sys_file_type

```

---

<div class="post-metadata">

### Author: ![runkan\_renchu](https://community.haxe.org/user_avatar/community.haxe.org/runkan_renchu/32/1731_2.png) [@runkan\_renchu](https://community.haxe.org/u/runkan_renchu)
#### Post date: [October 30, 2022, 10:13pm UTC](https://community.haxe.org/t/error-compiling-source-code/3737/2 "2022-10-30T22:13:13Z")

</div>

Try a clean build.

---

<div class="post-metadata">

### Author: ![TechSecWasTaken](https://community.haxe.org/user_avatar/community.haxe.org/techsecwastaken/32/2010_2.png) [@TechSecWasTaken](https://community.haxe.org/u/TechSecWasTaken)
#### Post date: [October 30, 2022, 10:20pm UTC](https://community.haxe.org/t/error-compiling-source-code/3737/3 "2022-10-30T22:20:33Z")

</div>

How would I do that?

---

<div class="post-metadata">

### Author: ![joshtynjala](https://community.haxe.org/user_avatar/community.haxe.org/joshtynjala/32/792_2.png) [@joshtynjala](https://community.haxe.org/u/joshtynjala)
#### Post date: [October 31, 2022, 3:58pm UTC](https://community.haxe.org/t/error-compiling-source-code/3737/4 "2022-10-31T15:58:06Z")

</div>

Similar to running with `-verbose`, you run with `-clean`.

---

<div class="post-metadata">

### Author: ![TechSecWasTaken](https://community.haxe.org/user_avatar/community.haxe.org/techsecwastaken/32/2010_2.png) [@TechSecWasTaken](https://community.haxe.org/u/TechSecWasTaken)
#### Post date: [October 31, 2022, 7:20pm UTC](https://community.haxe.org/t/error-compiling-source-code/3737/5 "2022-10-31T19:20:07Z")

</div>

Ah okay! Thank you!

---

<div class="post-metadata">

### Author: ![TechSecWasTaken](https://community.haxe.org/user_avatar/community.haxe.org/techsecwastaken/32/2010_2.png) [@TechSecWasTaken](https://community.haxe.org/u/TechSecWasTaken)
#### Post date: [October 31, 2022, 7:20pm UTC](https://community.haxe.org/t/error-compiling-source-code/3737/6 "2022-10-31T19:20:42Z")

</div>

Still an uncaught exception

---

<div class="post-metadata">

### Author: ![runkan\_renchu](https://community.haxe.org/user_avatar/community.haxe.org/runkan_renchu/32/1731_2.png) [@runkan\_renchu](https://community.haxe.org/u/runkan_renchu)
#### Post date: [November 1, 2022, 6:53pm UTC](https://community.haxe.org/t/error-compiling-source-code/3737/7 "2022-11-01T18:53:25Z")

</div>

Try deleting export directory and rebuilding. Apparently it’s not the same than `-clean` so that might help.

std@sys\_file\_type is an issue that sometimes has to do with special characters in file names. So make sure no files have non-english characters in their names.

---

<div class="post-metadata">

### Author: ![joshtynjala](https://community.haxe.org/user_avatar/community.haxe.org/joshtynjala/32/792_2.png) [@joshtynjala](https://community.haxe.org/u/joshtynjala)
#### Post date: [November 1, 2022, 7:33pm UTC](https://community.haxe.org/t/error-compiling-source-code/3737/8 "2022-11-01T19:33:06Z")

</div>

> [@TechSecWasTaken](#):
>
> `lime/tools/ProjectXMLParser.hx line 709`

For reference, this is the code on line 709 in _ProjectXMLParser.hx_ (in a method named `parseAssetsElementDirectory`):

```haxe
if (FileSystem.isDirectory(path + "/" + file))

```

The documentation for `FileSystem.isDirectory()` mentions this:

> If path is not a valid file system entry or if its destination is not accessible, an exception is thrown.

I can’t tell you exactly what’s wrong, but the problem seems to be related to one of the files in the directory that contains your project’s assets.
