# Using python to save into .mrb file, got a warning message

**URL:** <https://discourse.slicer.org/t/using-python-to-save-into-mrb-file-got-a-warning-message/28735>\
**Category:** Support\
**Tags:** python\
**Created:** [April 4, 2023, 3:09am UTC](https://discourse.slicer.org/t/using-python-to-save-into-mrb-file-got-a-warning-message/28735 "2023-04-04T03:09:28Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![derekcbr](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/derekcbr/32/18793_2.png) [@derekcbr](https://discourse.slicer.org/u/derekcbr)\
**Post date:** [April 4, 2023, 3:09am UTC](https://discourse.slicer.org/t/using-python-to-save-into-mrb-file-got-a-warning-message/28735/1 "2023-04-04T03:09:28Z")

</div>

output\_file = os.path.join(file\_dir, “test.mrb”)  
licer.util.saveScene(output\_file)  
I got the warnings from Slicer:[Qt] class QList\<class qSlicerFileWriter \*\> \_\_cdecl qSlicerCoreIOManagerPrivate::writers(const class QString &,const class QMap\<class QString,class QVariant\> &,class vtkMRMLScene \*) const warning: Unable to find node with ID “” in the given scene.  
How to solve this problem? Thanks a lot!

---

<div class="post-metadata">

**Author:** ![pieper](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/pieper/32/8_2.png) [@pieper](https://discourse.slicer.org/u/pieper)\
**Post date:** [April 4, 2023, 8:28pm UTC](https://discourse.slicer.org/t/using-python-to-save-into-mrb-file-got-a-warning-message/28735/2 "2023-04-04T20:28:59Z")

</div>

Try with incremental amounts of data in the scene. First empty, then with sample data, etc. and see what steps lead to a scene that leads to the error and let us know.

---

<div class="post-metadata">

**Author:** ![derekcbr](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/derekcbr/32/18793_2.png) [@derekcbr](https://discourse.slicer.org/u/derekcbr)\
**Post date:** [April 5, 2023, 2:09pm UTC](https://discourse.slicer.org/t/using-python-to-save-into-mrb-file-got-a-warning-message/28735/3 "2023-04-05T14:09:32Z")

</div>

Thank you for the message. First empty and then with sample data, I still got the same warnings. Thanks!

---

<div class="post-metadata">

**Author:** ![pieper](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/pieper/32/8_2.png) [@pieper](https://discourse.slicer.org/u/pieper)\
**Post date:** [April 5, 2023, 2:17pm UTC](https://discourse.slicer.org/t/using-python-to-save-into-mrb-file-got-a-warning-message/28735/4 "2023-04-05T14:17:07Z")

</div>

Thanks for the report. I see that warning too, testing with my local build on mac. But at least for me `slicer.util.loadScene` reads back the file as expected so I think you can ignore the warning.

It would be good if you could file an issue on github for this and ideally someone with a debug build can step through and figure out why this is being triggered.

---

<div class="post-metadata">

**Author:** ![derekcbr](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/derekcbr/32/18793_2.png) [@derekcbr](https://discourse.slicer.org/u/derekcbr)\
**Post date:** [April 5, 2023, 11:13pm UTC](https://discourse.slicer.org/t/using-python-to-save-into-mrb-file-got-a-warning-message/28735/5 "2023-04-05T23:13:51Z")

</div>

Alright! Thank you for the message!
