# Exception when saving files

**URL:** <https://discourse.jabref.org/t/exception-when-saving-files/3675>\
**Category:** Help\
**Created:** [December 21, 2022, 9:43am UTC](https://discourse.jabref.org/t/exception-when-saving-files/3675 "2022-12-21T09:43:16Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![Fabiana\_Machado](https://yyz2.discourse-cdn.com/flex030/user_avatar/discourse.jabref.org/fabiana_machado/32/1531_2.png) [@Fabiana\_Machado](https://discourse.jabref.org/u/Fabiana_Machado)\
**Post date:** [December 21, 2022, 9:43am UTC](https://discourse.jabref.org/t/exception-when-saving-files/3675/1 "2022-12-21T09:43:16Z")

</div>

Hi everyone,

I have been using JabRef for a while now. Today I edited a bib file and the following exception happened when saving it:

org.jabref.logic.exporter.SaveException: Problems saving: java.io.FileNotFoundException: /home/fmachado/snap/jabref/1852/pvd.bib.tmp (Permission denied)  
at org.jabref@5.8.60000/org.jabref.gui.exporter.SaveDatabaseAction.saveDatabase(Unknown Source)  
at org.jabref@5.8.60000/org.jabref.gui.exporter.SaveDatabaseAction.save(Unknown Source)  
at org.jabref@5.8.60000/org.jabref.gui.exporter.SaveDatabaseAction.saveAs(Unknown Source)  
at org.jabref@5.8.60000/org.jabref.gui.exporter.SaveDatabaseAction.saveAs(Unknown Source)  
at java.base/java.util.Optional.ifPresent(Unknown Source)  
at org.jabref@5.8.60000/org.jabref.gui.exporter.SaveDatabaseAction.saveAs(Unknown Source)  
at org.jabref@5.8.60000/org.jabref.gui.exporter.SaveAction.execute(Unknown Source)  
at org.jabref@5.8.60000/org.jabref.gui.actions.JabRefAction.lambda$new$3(Unknown Source)  
at org.jabref.merged.module@5.8.60000/org.controlsfx.control.action.Action.handle(Unknown Source)  
at org.jabref.merged.module@5.8.60000/org.controlsfx.control.action.Action.handle(Unknown Source)  
at org.jabref.merged.module@5.8.60000/com.sun.javafx.event.CompositeEventHandler.dispatchBubblingEvent(Unknown Source)  
at org.jabref.merged.module@5.8.60000/com.sun.javafx.event.EventHandlerManager.dispatchBubblingEvent(Unknown Source)  
at org.jabref.merged.module@5.8.60000/com.sun.javafx.event.EventHandlerManager.dispatchBubblingEvent(Unknown Source)  
at org.jabref.merged.module@5.8.60000/com.sun.javafx.event.BasicEventDispatcher.dispatchEvent(Unknown Source)  
at org.jabref.merged.module@5.8.60000/com.sun.javafx.event.EventDispatchChainImpl.dispatchEvent(Unknown Source)  
at org.jabref.merged.module@5.8.60000/com.sun.javafx.event.EventUtil.fireEventImpl(Unknown Source)  
at org.jabref.merged.module@5.8.60000/com.sun.javafx.event.EventUtil.fireEvent(Unknown Source)  
at org.jabref.merged.module@5.8.60000/javafx.event.Event.fireEvent(Unknown Source)  
at org.jabref.merged.module@5.8.60000/javafx.scene.control.MenuItem.fire(Unknown Source)  
at org.jabref.merged.module@5.8.60000/com.sun.javafx.scene.control.ContextMenuContent$MenuItemContainer.doSelect(Unknown Source)  
at org.jabref.merged.module@5.8.60000/com.sun.javafx.scene.control.ContextMenuContent$MenuItemContainer.lambda$createChildren$12(Unknown Source)  
at org.jabref.merged.module@5.8.60000/com.sun.javafx.event.CompositeEventHandler$NormalEventHandlerRecord.handleBubblingEvent(Unknown Source)  
at org.jabref.merged.module@5.8.60000/com.sun.javafx.event.CompositeEventHandler.dispatchBubblingEvent(Unknown Source)  
at org.jabref.merged.module@5.8.60000/com.sun.javafx.event.EventHandlerManager.dispatchBubblingEvent(Unknown Source)  
at org.jabref.merged.module@5.8.60000/com.sun.javafx.event.EventHandlerManager.dispatchBubblingEvent(Unknown Source)  
at org.jabref.merged.module@5.8.60000/com.sun.javafx.event.CompositeEventDispatcher.dispatchBubblingEvent(Unknown Source)  
at org.jabref.merged.module@5.8.60000/com.sun.javafx.event.BasicEventDispatcher.dispatchEvent(Unknown Source)  
at org.jabref.merged.module@5.8.60000/com.sun.javafx.event.EventDispatchChainImpl.dispatchEvent(Unknown Source)  
at org.jabref.merged.module@5.8.60000/com.sun.javafx.event.BasicEventDispatcher.dispatchEvent(Unknown Source)  
at org.jabref.merged.module@5.8.60000/com.sun.javafx.event.EventDispatchChainImpl.dispatchEvent(Unknown Source)  
at org.jabref.merged.module@5.8.60000/com.sun.javafx.event.BasicEventDispatcher.dispatchEvent(Unknown Source)  
at org.jabref.merged.module@5.8.60000/com.sun.javafx.event.EventDispatchChainImpl.dispatchEvent(Unknown Source)  
at org.jabref.merged.module@5.8.60000/com.sun.javafx.event.BasicEventDispatcher.dispatchEvent(Unknown Source)  
at org.jabref.merged.module@5.8.60000/com.sun.javafx.event.EventDispatchChainImpl.dispatchEvent(Unknown Source)  
at org.jabref.merged.module@5.8.60000/com.sun.javafx.event.EventUtil.fireEventImpl(Unknown Source)  
at org.jabref.merged.module@5.8.60000/com.sun.javafx.event.EventUtil.fireEvent(Unknown Source)  
at org.jabref.merged.module@5.8.60000/javafx.event.Event.fireEvent(Unknown Source)  
at org.jabref.merged.module@5.8.60000/javafx.scene.Scene$MouseHandler.process(Unknown Source)  
at org.jabref.merged.module@5.8.60000/javafx.scene.Scene.processMouseEvent(Unknown Source)  
at org.jabref.merged.module@5.8.60000/javafx.scene.Scene$ScenePeerListener.mouseEvent(Unknown Source)  
at org.jabref.merged.module@5.8.60000/com.sun.javafx.tk.quantum.GlassViewEventHandler$MouseEventNotification.run(Unknown Source)  
at org.jabref.merged.module@5.8.60000/com.sun.javafx.tk.quantum.GlassViewEventHandler$MouseEventNotification.run(Unknown Source)  
at java.base/java.security.AccessController.doPrivileged(Unknown Source)  
at org.jabref.merged.module@5.8.60000/com.sun.javafx.tk.quantum.GlassViewEventHandler.lambda$handleMouseEvent$2(Unknown Source)  
at org.jabref.merged.module@5.8.60000/com.sun.javafx.tk.quantum.QuantumToolkit.runWithoutRenderLock(Unknown Source)  
at org.jabref.merged.module@5.8.60000/com.sun.javafx.tk.quantum.GlassViewEventHandler.handleMouseEvent(Unknown Source)  
at org.jabref.merged.module@5.8.60000/com.sun.glass.ui.View.handleMouseEvent(Unknown Source)  
at org.jabref.merged.module@5.8.60000/com.sun.glass.ui.View.notifyMouse(Unknown Source)  
at org.jabref.merged.module@5.8.60000/com.sun.glass.ui.gtk.GtkApplication.\_runLoop(Native Method)  
at org.jabref.merged.module@5.8.60000/com.sun.glass.ui.gtk.GtkApplication.lambda$runLoop$11(Unknown Source)  
at java.base/java.lang.Thread.run(Unknown Source)  
Caused by: java.io.FileNotFoundException: /home/fmachado/snap/jabref/1852/pvd.bib.tmp (Permission denied)  
at java.base/java.io.FileOutputStream.open0(Native Method)  
at java.base/java.io.FileOutputStream.open(Unknown Source)  
at java.base/java.io.FileOutputStream.(Unknown Source)  
at java.base/java.io.FileOutputStream.(Unknown Source)  
at org.jabref@5.8.60000/org.jabref.logic.exporter.AtomicFileOutputStream.(Unknown Source)  
at org.jabref@5.8.60000/org.jabref.logic.exporter.AtomicFileWriter.(Unknown Source)  
… 51 more

this is now happening for any new or old file I try to save. I have no idea what is going on, I hope somebody can help me.  
Best,  
Fabiana

---

<div class="post-metadata">

**Author:** ![calixtus](https://yyz2.discourse-cdn.com/flex030/user_avatar/discourse.jabref.org/calixtus/32/579_2.png) [@calixtus](https://discourse.jabref.org/u/calixtus)\
**Post date:** [December 21, 2022, 11:39am UTC](https://discourse.jabref.org/t/exception-when-saving-files/3675/2 "2022-12-21T11:39:31Z")

</div>

Just tried it on my machine with newest (5.8) snap distribution on arch linux and worked.  
Java is complaining that a tmp file could not be saved. Is the actual bib file save correctly?

May have something to do with the new backup manager not having the right app / tmp dir configured when using snap

---

<div class="post-metadata">

**Author:** ![Siedlerchr](https://yyz2.discourse-cdn.com/flex030/user_avatar/discourse.jabref.org/siedlerchr/32/216_2.png) [@Siedlerchr](https://discourse.jabref.org/u/Siedlerchr)\
**Post date:** [December 21, 2022, 11:44am UTC](https://discourse.jabref.org/t/exception-when-saving-files/3675/3 "2022-12-21T11:44:02Z")

</div>

Hi,

thanks for the report, Can you try to check if the home folder connection is correctly set up?

> **[The home interface | Snapcraft documentation](https://snapcraft.io/docs/home-interface)**
>
> Snaps are containerised software packages that are simple to create and install. They auto-update and are safe to run. And because they bundle their dependencies, they work on all major Linux systems without modification.

---

<div class="post-metadata">

**Author:** ![Fabiana\_Machado](https://yyz2.discourse-cdn.com/flex030/user_avatar/discourse.jabref.org/fabiana_machado/32/1531_2.png) [@Fabiana\_Machado](https://discourse.jabref.org/u/Fabiana_Machado)\
**Post date:** [December 21, 2022, 11:52am UTC](https://discourse.jabref.org/t/exception-when-saving-files/3675/4 "2022-12-21T11:52:38Z")

</div>

Hi Christoph, thanks for your reply

the home folder should be correct. It is weird that this is happening out of nowhere and to anything I try to do with JabRef…

---

<div class="post-metadata">

**Author:** ![Fabiana\_Machado](https://yyz2.discourse-cdn.com/flex030/user_avatar/discourse.jabref.org/fabiana_machado/32/1531_2.png) [@Fabiana\_Machado](https://discourse.jabref.org/u/Fabiana_Machado)\
**Post date:** [December 21, 2022, 11:56am UTC](https://discourse.jabref.org/t/exception-when-saving-files/3675/5 "2022-12-21T11:56:07Z")

</div>

Hi Carl,

all was working until this morning, now the same error occurs for old bib files and if I try to create new ones from scratch. I am using the program without any problems for almost a year now.

---

<div class="post-metadata">

**Author:** ![calixtus](https://yyz2.discourse-cdn.com/flex030/user_avatar/discourse.jabref.org/calixtus/32/579_2.png) [@calixtus](https://discourse.jabref.org/u/calixtus)\
**Post date:** [December 21, 2022, 12:10pm UTC](https://discourse.jabref.org/t/exception-when-saving-files/3675/6 "2022-12-21T12:10:37Z")

</div>

We made a new release last friday. Did your snap refresh today? Can you try to roll back with to 5.7 with snap? Can you try the linux portable version of JabRef (should work at least as a workaround - [index - powered by h5ai v0.29.0 (https://larsjung.de/h5ai/)](https://builds.jabref.org/tags/v5.8/) )?

---

<div class="post-metadata">

**Author:** ![Fabiana\_Machado](https://yyz2.discourse-cdn.com/flex030/user_avatar/discourse.jabref.org/fabiana_machado/32/1531_2.png) [@Fabiana\_Machado](https://discourse.jabref.org/u/Fabiana_Machado)\
**Post date:** [December 21, 2022, 12:27pm UTC](https://discourse.jabref.org/t/exception-when-saving-files/3675/7 "2022-12-21T12:27:12Z")

</div>

By reverting to 5.7.6 I get to edit and save existing works, but if I create new ones and try save Jabref quits. I will try the portable version, should I uninstall the snap version before or it is irrelevant?

---

<div class="post-metadata">

**Author:** ![Siedlerchr](https://yyz2.discourse-cdn.com/flex030/user_avatar/discourse.jabref.org/siedlerchr/32/216_2.png) [@Siedlerchr](https://discourse.jabref.org/u/Siedlerchr)\
**Post date:** [December 22, 2022, 12:36pm UTC](https://discourse.jabref.org/t/exception-when-saving-files/3675/8 "2022-12-22T12:36:46Z")

</div>

You don’t have to uninstall the snap version, though it might be confusing if you have two JabRef installs on your computer
