summary
- I had a bug that I didnât understand, so I asked for help with a problem.
- The initially perceived âlog breakdownâ turned out to be an incorrect perception of the phenomenon.
- Correct: âThe log splits into two conversations.â
- Itâs a relief to know that the logs havenât been lost.
What would you like to see happen in this conversation? Iâd like to discuss a bug that caused a mysterious log breakdown. What kind of âbugâ is this âbugâ? The first few lines of the log were lost. Even the data stored on the server lost the beginning of the log. What kind of âlogâ is that âlogâ? Conversation Log. A list of what the user typed into the chat and what the bot responded to. Is there anything else about that âlogâ? In the first place, the server is supposed to send a single line of statements to the server, and the server side is supposed to do the postscript, so itâs puzzling why it breaks off in the middle of the statement.
-
Conversation logs. A list of what the user typed into the chat and what the bot responded to.
- Where is this âlogâ located? on the server. What kind of âserverâ is this âserverâ? Receive a string on Heroku and return a reply response. The status is stored in Firestore. What kind of âsaveâ is that âsaveâ? The KVS is keyed to the talk ID, and the internal state necessary to continue the conversation is converted to JSON and stored there. JSON is the historical background, and when actually used, it is necessary to convert it into a form that can be entered into the Firestore before saving it. What is it that you value? I would like to see the bugs worked out. Losing logs is a loss, and I canât use it safely if I think it might be lost. Iâve tried a few quick and suspicious operations, but I canât reproduce them and Iâm having a hard time keeping my head above water. Where is that âlogâ located? Firestore.
-
I would like to see the bug resolved. Losing logs is a loss, and I canât use it with confidence if I think it might be lost. Iâve tried a few quick and suspicious operations, but I canât reproduce them, and Iâm having a hard time keeping my head above water.
- What does this âlogâ look like? Files to be appended. If the log disappears, youâd think it was overwritten, but itâs inexplicable that it disappears because it should have been loaded, added, and written back in the first place. Where do these âlogsâ come from? Letâs see, the feature that I think is suspicious this time is the âopen and continue past conversationsâ feature that I recently added, and I was using it all the time when the logs actually disappeared. When I used this feature, I first accessed Firestore with the conversation ID in the browserâs IndexedDB to retrieve the past logs and display them. How do you know its âlogâ? Iâll send the conversation ID to Firestore and say, âGive me the log of this conversation.â What would you like to see happen with respect to that âlogâ? I wish it would not disappear, or at least know how to reproduce the disappearing phenomenon. If you canât reproduce it, you canât debug it. What needs to happen to the âlogâ for that to happen? I donât know!
-
Iâll send the conversation ID to Firestore and say, âGive me the log of this conversation.â
- What kind of âFirestoreâ is this âFirestoreâ? Just a KVS on a server Is there anything else you can tell us about that âserverâ? I have a script that downloads the values on the server locally to make it easier to investigate, and I did see that the beginning of the log in question was broken using that, but then a few other things were downloaded. I should also see what kind of data those are. How do you know its âserverâ? Thatâs the best way to know what the servers are up to. Where is this âserverâ located? Iâm going to go observe a local copy.
-
Thatâs the best way to know whatâs going on with the servers.
- What do you hope will happen regarding this âserverâ? Okay, the log isnât missing, itâs split into two conversations. What kind of âconversationâ is that âconversationâ? In other words, I thought I was having one conversation, but some kind of malfunction or something caused me to start another new conversation in the middle of the first one. Is there anything else about that âconversationâ? I just looked at the list of past conversations saved in my browser, and sure enough, there were two conversations. I didnât notice that, and I displayed the log at the time the second conversation ended, so only the log of the second half of the conversation was displayed, and I thought, âThe first half is lost? I guess I misunderstood. I could see the log of the first half without any problem. How do you know its a âconversationâ? Good thing I added the past conversation list feature. You can see it there. What does that âconversationâ sound like? Unlike verbal conversations, which can be erased, I think itâs important to keep a log and be able to read it back later. So itâs a written image. Thatâs why I was so worried when I heard, âThe log is gone? but I am relieved to know that it has not disappeared for the time being. Where does this âconversationâ come from?
This page is auto-translated from /nishio/èŹăźăă°ăéćăăăă°ăè”·ăăăźă§çžè«ăăă using DeepL. If you looks something interesting but the auto-translated English is not good enough to understand it, feel free to let me know at @nishio_en. Iâm very happy to spread my thought to non-Japanese readers.