I'm getting a series of 4 errors every time my code runs this script:
var drop = load("res://data/scenes/items/passives/pa_" + equipment + ".tscn").instance()
drop.position = self.position + Vector2(50.0, 0.0).rotated(randf() * TAU)
get_parent().get_node("Pa_items").add_child(drop)
Yes, it is spawning a new node everytime it runs.
But I get micro-freezes in my game and also I get these errors:

How do I fix it?
I have no idea why this is happening.
This is what is written in each error (in order):
First:
E 0:00:05.337 bodysetshapedisabled: Can't change this state while flushing queries. Use calldeferred() or setdeferred() to change monitoring state instead.
<C++ Error> Condition "body->getspace() && flushingqueries" is true.
<C++ Source> servers/physics2d/physics2dserversw.cpp:730 @ bodysetshapedisabled()
Character.gd:149 @ droppassiveitem()
Character.gd:128 @ updateequipment()
Character.gd:446 @ _onCollisioninteracitonsarea_entered()
Second:
E 0:00:05.341 bodysetshapeasonewaycollision: Can't change this state while flushing queries. Use calldeferred() or setdeferred() to change monitoring state instead.
<C++ Error> Condition "body->getspace() && flushingqueries" is true.
<C++ Source> servers/physics2d/physics2dserversw.cpp:739 @ bodysetshapeasonewaycollision()
Character.gd:149 @ droppassiveitem()
Character.gd:128 @ updateequipment()
Character.gd:446 @ _onCollisioninteracitonsarea_entered()
Third:
E 0:00:05.349 bodysetshapeasonewaycollision: Can't change this state while flushing queries. Use calldeferred() or setdeferred() to change monitoring state instead.
<C++ Error> Condition "body->getspace() && flushingqueries" is true.
<C++ Source> servers/physics2d/physics2dserversw.cpp:739 @ bodysetshapeasonewaycollision()
Character.gd:149 @ droppassiveitem()
Character.gd:128 @ updateequipment()
Character.gd:446 @ _onCollisioninteracitonsarea_entered()
Fourth
E 0:00:05.354 areasetshapedisabled: Can't change this state while flushing queries. Use calldeferred() or setdeferred() to change monitoring state instead.
<C++ Error> Condition "area->getspace() && flushingqueries" is true.
<C++ Source> servers/physics2d/physics2dserversw.cpp:409 @ areasetshapedisabled()
Character.gd:149 @ droppassiveitem()
Character.gd:128 @ updateequipment()
Character.gd:446 @ _onCollisioninteracitonsarea_entered()