Parsing issue #1

Closed
opened 2021-05-18 00:39:57 +00:00 by kake26 · 6 comments
kake26 commented 2021-05-18 00:39:57 +00:00 (Migrated from codeberg.org)

It seems at a particular point durning a month the offset of the parsed data goes up or down by one. I've seen this twice now but I don't know what part of the month or the conditions are yet. Logging it here to keep an eye on this mess. Currently I noticed it about 10 days into the month of May. I will review the log data and see if that tells me anything.

It seems at a particular point durning a month the offset of the parsed data goes up or down by one. I've seen this twice now but I don't know what part of the month or the conditions are yet. Logging it here to keep an eye on this mess. Currently I noticed it about 10 days into the month of May. I will review the log data and see if that tells me anything.
kake26 commented 2021-05-22 21:23:46 +00:00 (Migrated from codeberg.org)

No sign of the bug so far. So maybe its around the point where the month rolls over.

No sign of the bug so far. So maybe its around the point where the month rolls over.
kake26 commented 2021-05-30 01:26:36 +00:00 (Migrated from codeberg.org)

Quick update 29th and still good.

Quick update 29th and still good.
kake26 commented 2021-06-02 00:26:24 +00:00 (Migrated from codeberg.org)

Looks like when it hits the first it kicks over and misaligns the expected fields. So now the question becomes when does this go the other way. Part #1 solved now part 2.

Looks like when it hits the first it kicks over and misaligns the expected fields. So now the question becomes when does this go the other way. Part #1 solved now part 2.
kake26 commented 2021-06-02 00:29:42 +00:00 (Migrated from codeberg.org)

Perhaps I'll do it based off a length check of the parsed array. Seems like a plan as it all only shifts up or down by one digit.

Perhaps I'll do it based off a length check of the parsed array. Seems like a plan as it all only shifts up or down by one digit.
kake26 commented 2022-11-19 02:46:25 +00:00 (Migrated from codeberg.org)

I haven't forgotten about this just things have gotten in the way.

I haven't forgotten about this just things have gotten in the way.
kake26 commented 2023-01-10 01:45:00 +00:00 (Migrated from codeberg.org)

I think this has been finally resolved. It appears the issue was in the OpenWRT bash script component. Apprently, the date +%d would give you the day of the month with a leading 0 when the day was less then 10. Also anything past 07 was causing and error. Bash interpreted numbers with a leading zero as a octal therefore breaking the math. Fix was found by setting ${md#0}.

I think this has been finally resolved. It appears the issue was in the OpenWRT bash script component. Apprently, the date +%d would give you the day of the month with a leading 0 when the day was less then 10. Also anything past 07 was causing and error. Bash interpreted numbers with a leading zero as a octal therefore breaking the math. Fix was found by setting ${md#0}.
Sign in to join this conversation.
No description provided.