\nDEBU[0007] cache: parsing https://feeds.twtxt.net/tiktok/twtxt.txt for tiktok\thttps://feeds.twtxt.net/tiktok/twtxt.txt\nDEBU[0007] twts: [I am @<tiktok https://feeds.twtxt.net/tiktok/twtxt.txt> an automated feed that twts every 30m with the current time (UTC) π’ The time is now seven thirty π]\nDEBU[0007] new: []\nDEBU[0007] old: [π’ The time is now seven thirty π I am @<tiktok https://feeds.twtxt.net/tiktok/twtxt.txt> an automated feed that twts every 30m with the current time (UTC)]\n
DEBU[0007] cache: parsing https://feeds.twtxt.net/tiktok/twtxt.txt for tiktok https://feeds.twtxt.net/tiktok/twtxt.txt
DEBU[0007] twts: [I am @<tiktok https://feeds.twtxt.net/tiktok/twtxt.txt> an automated feed that twts every 30m with the current time (UTC) π’ The time is now seven thirty π]
DEBU[0007] new: []
DEBU[0007] old: [π’ The time is now seven thirty π I am @<tiktok https://feeds.twtxt.net/tiktok/twtxt.txt> an automated feed that twts every 30m with the current time (UTC)]
\nDEBU[0007] cache: parsing https://feeds.twtxt.net/tiktok/twtxt.txt for tiktok\thttps://feeds.twtxt.net/tiktok/twtxt.txt\nDEBU[0007] twts: [I am @<tiktok https://feeds.twtxt.net/tiktok/twtxt.txt> an automated feed that twts every 30m with the current time (UTC) π’ The time is now seven thirty π]\nDEBU[0007] new: []\nDEBU[0007] old: [π’ The time is now seven thirty π I am @<tiktok https://feeds.twtxt.net/tiktok/twtxt.txt> an automated feed that twts every 30m with the current time (UTC)]\n
DEBU[0007] cache: parsing https://feeds.twtxt.net/tiktok/twtxt.txt for tiktok https://feeds.twtxt.net/tiktok/twtxt.txt
DEBU[0007] twts: [I am @<tiktok https://feeds.twtxt.net/tiktok/twtxt.txt> an automated feed that twts every 30m with the current time (UTC) π’ The time is now seven thirty π]
DEBU[0007] new: []
DEBU[0007] old: [π’ The time is now seven thirty π I am @<tiktok https://feeds.twtxt.net/tiktok/twtxt.txt> an automated feed that twts every 30m with the current time (UTC)]
pos--
in SplitTwts()
seems to fix this, I've been debugging this for an hour or so now, but maybe you can confirm. I _smell_ an off-by-one error here? π€ I'm just not 100% sure π€£
pos--
in SplitTwts()
seems to fix this, I've been debugging this for an hour or so now, but maybe you can confirm. I _smell_ an off-by-one error here? π€ I'm just not 100% sure π€£
pos--
in SplitTwts()
seems to fix this, I've been debugging this for an hour or so now, but maybe you can confirm. I _smell_ an off-by-one error here? π€ I'm just not 100% sure π€£
pos--
produces an "off-by-one" error here. Here's why I think this.Say you have Twts:
A, B, C, D
ordered from oldest to newest (_from left to right_).Let's say C and D exceed
MaxTTLCache
. Therefore pos
lands on C and we break out of the loop. But if we decrement pos
again here with pos--
, then we pos points to B.So we return new twts as A and old twts as B, C and D. Hence an off-by-one error since the older twtst were in fact C and D.
Make sense?
pos--
produces an "off-by-one" error here. Here's why I think this.\n\nSay you have Twts: A, B, C, D
ordered from oldest to newest (_from left to right_).\n\nLet's say C and D exceed MaxTTLCache
. Therefore pos
lands on C and we break out of the loop. But if we decrement pos
again here with pos--
, then we pos points to B.\n\nSo we return new twts as A and old twts as B, C and D. Hence an off-by-one error since the older twtst were in fact C and D.\n\nMake sense?
pos--
produces an "off-by-one" error here. Here's why I think this.\n\nSay you have Twts: A, B, C, D
ordered from oldest to newest (_from left to right_).\n\nLet's say C and D exceed MaxTTLCache
. Therefore pos
lands on C and we break out of the loop. But if we decrement pos
again here with pos--
, then we pos points to B.\n\nSo we return new twts as A and old twts as B, C and D. Hence an off-by-one error since the older twtst were in fact C and D.\n\nMake sense?
pos--
produces an "off-by-one" error here. Here's why I think this.Say you have Twts:
A, B, C, D
ordered from oldest to newest (_from left to right_).Let's say C and D exceed
MaxTTLCache
. Therefore pos
lands on C and we break out of the loop. But if we decrement pos
again here with pos--
, then we pos points to B.So we return new twts as A and old twts as B, C and D. Hence an off-by-one error since the older twtst were in fact C and D.
Make sense?