qsef1256 / DacoBot

Discord Bot made by Diamond
1 stars 0 forks source link

Failed to use InventoryCommand #32

Closed qsef1256 closed 9 months ago

qsef1256 commented 9 months ago
21:35:52.678 JDA MainWS-ReadThread                InventoryCommand     ERROR  인벤토리 로드 실패
org.hibernate.LazyInitializationException: failed to lazily initialize a collection of role: net.qsef1256.dacobot.game.explosion.domain.inventory.InventoryEntity.items, could not initialize proxy - no Session
    at org.hibernate.collection.internal.AbstractPersistentCollection.throwLazyInitializationException(AbstractPersistentCollection.java:614)
    at org.hibernate.collection.internal.AbstractPersistentCollection.withTemporarySessionIfNeeded(AbstractPersistentCollection.java:218)
    at org.hibernate.collection.internal.AbstractPersistentCollection.initialize(AbstractPersistentCollection.java:591)
    at org.hibernate.collection.internal.AbstractPersistentCollection.read(AbstractPersistentCollection.java:149)
    at org.hibernate.collection.internal.PersistentMap.entrySet(PersistentMap.java:264)
    at java.base/java.util.Map.forEach(Map.java:703)
    at net.qsef1256.dacobot.game.explosion.command.InventoryCommand$SeeCommand.getInventoryEmbed(InventoryCommand.java:86)
    at net.qsef1256.dacobot.game.explosion.command.InventoryCommand$SeeCommand.execute(InventoryCommand.java:69)
    at com.jagrosh.jdautilities.command.SlashCommand.run(SlashCommand.java:322)
    at com.jagrosh.jdautilities.command.impl.CommandClientImpl.onSlashCommand(CommandClientImpl.java:936)
    at com.jagrosh.jdautilities.command.impl.CommandClientImpl.onEvent(CommandClientImpl.java:626)
    at net.dv8tion.jda.api.hooks.InterfacedEventManager.handle(InterfacedEventManager.java:96)
    at net.dv8tion.jda.internal.hooks.EventManagerProxy.handleInternally(EventManagerProxy.java:88)
    at net.dv8tion.jda.internal.hooks.EventManagerProxy.handle(EventManagerProxy.java:70)
    at net.dv8tion.jda.internal.JDAImpl.handleEvent(JDAImpl.java:173)
    at net.dv8tion.jda.internal.handle.InteractionCreateHandler.handleCommand(InteractionCreateHandler.java:112)
    at net.dv8tion.jda.internal.handle.InteractionCreateHandler.handleInternally(InteractionCreateHandler.java:83)
    at net.dv8tion.jda.internal.handle.SocketHandler.handle(SocketHandler.java:39)
    at net.dv8tion.jda.internal.requests.WebSocketClient.onDispatch(WebSocketClient.java:1007)
    at net.dv8tion.jda.internal.requests.WebSocketClient.onEvent(WebSocketClient.java:893)
    at net.dv8tion.jda.internal.requests.WebSocketClient.handleEvent(WebSocketClient.java:871)
    at net.dv8tion.jda.internal.requests.WebSocketClient.onBinaryMessage(WebSocketClient.java:1046)
    at com.neovisionaries.ws.client.ListenerManager.callOnBinaryMessage(ListenerManager.java:385)
    at com.neovisionaries.ws.client.ReadingThread.callOnBinaryMessage(ReadingThread.java:276)
    at com.neovisionaries.ws.client.ReadingThread.handleBinaryFrame(ReadingThread.java:996)
    at com.neovisionaries.ws.client.ReadingThread.handleFrame(ReadingThread.java:755)
    at com.neovisionaries.ws.client.ReadingThread.main(ReadingThread.java:108)
    at com.neovisionaries.ws.client.ReadingThread.runMain(ReadingThread.java:64)
    at com.neovisionaries.ws.client.WebSocketThread.run(WebSocketThread.java:45)

LazyInitializationException, @Transactional 확인이 필요해보임 (혹은 다른 해결책이 필요할 수도 있음)