[Enter steps to reproduce:]
Atom: 1.15.0 ia32
Electron: 1.3.13
OS: Microsoft Windows 10 Pro
Thrown From: file-icons package 2.1.1
Uncaught TypeError: Cannot read property 'onDidChangeIcon' of undefined
At C:\Users\TheBrenny\.atom\packages\file-icons\lib\service\icon-node.js:30
TypeError: Cannot read property 'onDidChangeIcon' of undefined
at /packages/file-icons/lib/service/icon-node.js:30:12)
at /packages/file-icons/lib/consumers/tree-entry.js:41:19)
at TreeView.track (/packages/file-icons/lib/consumers/tree-view.js:82:25)
at TreeView.rebuild (/packages/file-icons/lib/consumers/tree-view.js:73:9)
at disposables.add.atom.project.onDidChangePaths (/packages/file-icons/lib/consumers/tree-view.js:48:45)
at Function.module.exports.Emitter.simpleDispatch (/app.asar/node_modules/event-kit/lib/emitter.js:25:14)
at Emitter.module.exports.Emitter.emit (/app.asar/node_modules/event-kit/lib/emitter.js:129:28)
at Project.module.exports.Project.addPath (/app.asar/src/project.js:288:29)
at /app.asar/src/atom-environment.js:1011:40
at /app.asar/src/application-delegate.js:31:16)
at emitTwo (events.js:106:13)
at EventEmitter.emit (events.js:191:7)
-6:57.9.0 intentions:highlight (input.hidden-input)
-6:57.7.0 core:save (input.hidden-input)
13x -6:47.4.0 core:move-up (input.hidden-input)
24x -6:44.4.0 core:move-down (input.hidden-input)
19x -6:43.2.0 core:move-up (input.hidden-input)
-6:40.5.0 intentions:highlight (input.hidden-input)
4x -6:40.4.0 core:undo (input.hidden-input)
2x -6:37.4.0 core:redo (input.hidden-input)
-6:36.8.0 core:undo (input.hidden-input)
-6:36.2.0 intentions:highlight (input.hidden-input)
-6:36.1.0 core:save (input.hidden-input)
5x -6:32.8.0 core:move-left (input.hidden-input)
3x -6:31.9.0 core:move-up (input.hidden-input)
-6:15 tree-view:remove-project-folder (div.header.list-item.project-root-header)
-0:46.9.0 application:add-project-folder (div.header.list-item.project-root-header)
-0:23.2.0 tree-view:show (atom-workspace.workspace.scrollbars-visible-always.compact-tab-bar.panel-shadows.use-animations.compact-tree-view.blend-tree-view.theme-genesis-syntax.theme-atom-material-ui.has-custom-icons)
atom-beautify 0.29.17
atom-commander 0.8.8
atom-material-syntax 1.0.2
atom-material-ui 1.3.9
busy-signal 1.3.0
emmet 2.4.3
file-icons 2.1.1
firepad 0.8.0
genesis-syntax 1.0.9
genesis-ui 0.5.0
git-plus 7.3.3
intentions 1.1.2
linter 2.1.0
linter-jsonlint 1.3.0
linter-pylint 1.2.3
linter-ui-default 1.2.1
minimap 4.26.8
package-sync 1.1.0
pigments 0.39.1
platformio-ide-terminal 2.5.0
script 3.14.1
SFTP-deployment 1.0.2
@TheBrenny Sorry for the slow response.
Could you please install v2.1.2 and let me know if this issue persists?
@Alhadis I'm using the v2.1.2 already and i'm facing the same issue
@dyaa Does clearing the cache help? Are your system specs the same as the OP's?
I can't reproduce this one. Was able to reproduce #568 (which v2.1.2 was mainly cut to fix) but I'm in the dark here.
Actually, Im new to Atom how can i clear the cache sry
@dyaa https://github.com/file-icons/atom#troubleshooting
file-icons:clear-cacheSteps:
1. Creating an index.js file under a Directory

Atom: 1.15.0 x64
Electron: 1.3.13
OS: Mac OS X 10.12.3
Thrown From: file-icons package 2.1.2
Uncaught TypeError: Cannot read property 'onDidChangeIcon' of undefined
At /Users/raghib/.atom/packages/file-icons/lib/service/icon-node.js:30
TypeError: Cannot read property 'onDidChangeIcon' of undefined
at /packages/file-icons/lib/service/icon-node.js:30:12)
at /packages/file-icons/lib/consumers/tab.js:18:19)
at Tabs.add (/packages/file-icons/lib/consumers/tabs.js:85:16)
at disposables.add.UI.delay.onOpenEditor.editor (/packages/file-icons/lib/consumers/tabs.js:36:10)
at Immediate.setImmediate (/packages/file-icons/lib/ui.js:95:40)
at runCallback (timers.js:574:20)
at tryOnImmediate (timers.js:554:5)
at processImmediate [as _immediateCallback] (timers.js:533:5)
-2:02.8.0 core:confirm (input.hidden-input)
-2:02.8.0 file-icons:clear-cache (input.hidden-input)
-1:56.6.0 tree-view:remove (li.file.entry.list-item.selected)
-1:51.3.0 tree-view:add-file (span.name.icon.icon-file-directory)
-1:49.5.0 core:confirm (input.hidden-input)
-1:31.8.0 command-palette:toggle (input.hidden-input)
-1:30.2.0 core:confirm (input.hidden-input)
-1:30.2.0 window:reload (input.hidden-input)
-1:21.7.0 command-palette:toggle (input.hidden-input)
6x -1:18.4.0 core:backspace (input.hidden-input)
-1:13 core:confirm (input.hidden-input)
-1:12.9.0 window:reload (input.hidden-input)
-0:55.4.0 tree-view:remove (li.file.entry.list-item.selected)
-0:47.7.0 tree-view:add-file (span.name.icon.icon-file-directory)
-0:46.4.0 core:backspace (input.hidden-input)
-0:44.8.0 core:confirm (input.hidden-input)
ariake-dark-syntax 0.1.3
ariake-light-syntax 0.0.0
atom-elixir 0.2.3
atom-focus-mode 0.7.0
atom-hipster-ui 0.1.0
atom-ternjs 0.18.2
auto-detect-indentation 1.3.0
auto-update-packages 1.0.1
autocomplete-elixir 1.5.14
autocomplete-emojis 2.5.0
autocomplete-java 1.2.5
autocomplete-modules 1.6.8
browser-plus 0.0.87
busy-signal 1.3.0
file-icons 2.1.2
flow 0.5.3
intentions 1.1.2
language-babel 2.57.1
language-elixir 0.17.0
language-markdown 0.20.0
language-rust 0.4.10
language-scala 1.1.8
linter 2.1.2
linter-elixirc 1.4.0
linter-eslint 8.1.4
linter-flow 5.5.1
linter-ui-default 1.2.2
minimap-pigments 0.2.2
open-in-browsers 0.0.19
peacocks-in-space-syntax 0.7.0
pigments 0.39.1
platformio-ide-terminal 2.5.0
prettier-atom 0.24.0
seti-syntax 1.0.1
seti-ui 1.7.0
Does restarting Atom help at all?
@Alhadis Yes Restarting fixed the problem, not sure if file-icons:clear-cache had anything to do with it
*Sigh* It's one of those insurmountable issues that's hard impossible/unreasonable to fix. See atom/tabs#412 for an explanation on why.
Bottom-line: restarting will smooth everything over after installation.
I'd like to add that I was using the unfancy-file-icons package, as well as this one, and for me the error happened when I tried to use advanced-open-file. Disabling unfancy-file-icons, clearing the cache, and restarting Atom fixed it. It seems that unfancy-file-icons conflicts with this package, but this one is better anyway.
Most helpful comment
@dyaa https://github.com/file-icons/atom#troubleshooting
file-icons:clear-cache