[Failed update] error: failed to commit transaction (conflicting files)

To understand why @cscs has accessed the situation correct one must understand the package manager within the realms of an ArchLinux based system.

The package manager - pacman and the supporting library libalpm - keeps track of files which exists as a part of the system.

When pacman encounters files - in system locations - which is not registered within the pacman registry - the package manager refuses to commit the transaction.

This is a very reasonable behavior and the only way to avoid such situations is to avoid using arbitrary applications as root to install files to system locations.

This includes various common development tools like npm, pip, bower, grunt and probably additional tools I haven’t thought of.

Always avoid commands like sudo npm or sudo pip as it will - sooner or later create issues like this.

I have copied one the FAQs from the archived forum - read on below

4 Likes