Skip to content

Funogram 3.0.5 / Telegram 10.2.0: unwind ChatMember + JSON-options workarounds#211

Merged
Szer merged 2 commits into
mainfrom
funogram-305-unwind
Jul 16, 2026
Merged

Funogram 3.0.5 / Telegram 10.2.0: unwind ChatMember + JSON-options workarounds#211
Szer merged 2 commits into
mainfrom
funogram-305-unwind

Conversation

@Szer

@Szer Szer commented Jul 16, 2026

Copy link
Copy Markdown
Owner

Funogram 3.0.5 ships the ChatMember DU discriminator fix (upstream refactoring of our Dolfik1/Funogram#93, via Always-attribute discriminators) and makes Funogram.Tools.options public (Dolfik1/Funogram#95). This unwinds both workarounds:

Reflection over JSON options

  • BotInfra.FunogramJson and SerializationCompat.Tests/Fixtures.fs now use the public Funogram.Tools.options instead of a BindingFlags.NonPublic reflection grab.

ChatMember DU misdiscrimination

  • CouponHubBot membership check branches on ChatMember DU cases (Owner | Administrator | Member) instead of wire-status strings — same member set as before.
  • Dropped the "NEVER branch on ChatMember DU cases" warnings and vahter's now-unused chatMemberStatus helper (chatMemberUser stays — it's plain field extraction).
  • FakeTgApiSpikeTests flipped from characterizing the 3.0.4 bug to asserting {"status":"member"}ChatMember.Member.
  • New ChatMemberCompatTests theory pins discrimination for all six wire statuses through the real Funogram options.

Verification

  • dotnet build: clean, 0 warnings (Bot API 10.2 type changes absorbed).
  • SerializationCompat.Tests: 51/51 locally.
  • Red→green proof via dotnet fsi against Funogram 3.0.4: member/left/kicked all deserialized as ChatMember.Owner; the new theory passes on 3.0.5.
  • Container-based bot suites run in CI.

🤖 Generated with Claude Code

Szer and others added 2 commits July 16, 2026 21:04
…rkarounds

Funogram 3.0.5 fixes the DU converter misdiscrimination (status now picks
the ChatMember case, via Always-attribute discriminators — upstream
refactoring of our PR Dolfik1/Funogram#93) and exposes Funogram.Tools.options
publicly (Dolfik1/Funogram#95).

- FunogramJson (BotInfra) and SerializationCompat fixtures use the public
  Funogram.Tools.options instead of reflection over the internal field
- CouponHubBot membership check branches on ChatMember DU cases instead of
  wire-status strings; same member set as before (creator/admin/member)
- Drop the "NEVER branch on ChatMember DU cases" warnings and vahter's
  now-unused chatMemberStatus helper
- FakeTgApiSpikeTests now asserts correct case discrimination instead of
  characterizing the 3.0.4 bug

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Pins the Funogram 3.0.5 fix production now relies on. Verified red on
3.0.4 (member/left/kicked all deserialized as ChatMember.Owner) and
green on 3.0.5.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@Szer
Szer enabled auto-merge (squash) July 16, 2026 20:08
@Szer
Szer merged commit 0aa19ef into main Jul 16, 2026
3 checks passed
@Szer
Szer deleted the funogram-305-unwind branch July 16, 2026 20:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant