Skip to content

Add residential proxy data to Anonymizer#494

Merged
horgh merged 1 commit into
mainfrom
greg/stf-997-add-residential-to-anonymizer
Jul 16, 2026
Merged

Add residential proxy data to Anonymizer#494
horgh merged 1 commit into
mainfrom
greg/stf-997-add-residential-to-anonymizer

Conversation

@oschwald

@oschwald oschwald commented Jul 10, 2026

Copy link
Copy Markdown
Member

Summary

The GeoIP Insights web service is adding a residential sub-object to the anonymizer object. It contains residential proxy data for the network and may be populated even when no other anonymizer properties are set.

  • New reusable record for the feed shape (confidence, network_last_seen, provider_name) named AnonymizerFeed, so future anonymizer feeds can share it
  • New residential property on the Anonymizer record
  • Tests, fixtures, and changelog updated

Residential is non-nullable with an empty-object default, matching the library's existing sub-object pattern.

Testing

dotnet build (all target frameworks) and dotnet test pass.

🤖 Generated with Claude Code

@coderabbitai

coderabbitai Bot commented Jul 10, 2026

Copy link
Copy Markdown

Review Change Stack

Warning

Review limit reached

@oschwald, you've reached your PR review limit, so we couldn't start this review.

Next review available in: 59 minutes

Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available.
You're only billed for reviews past your plan's rate limits ($0.25/file).

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews.

How do review limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please refer docs for additional details.

Review details
⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Pro Plus

Run ID: 89a5eea5-f590-403c-8f3b-377b2efa376a

📥 Commits

Reviewing files that changed from the base of the PR and between 3692621 and 1691db3.

📒 Files selected for processing (5)
  • MaxMind.GeoIP2.UnitTests/DeserializationTests.cs
  • MaxMind.GeoIP2.UnitTests/ResponseHelper.cs
  • MaxMind.GeoIP2/Model/Anonymizer.cs
  • MaxMind.GeoIP2/Model/AnonymizerFeed.cs
  • releasenotes.md
📝 Walkthrough

Walkthrough

Adds residential proxy feed data to the Insights anonymizer model, including confidence, provider, and conditional last-seen date fields. Updates deserialization fixtures, assertions, and release notes.

Changes

Residential anonymizer feed

Layer / File(s) Summary
Residential feed model and wiring
MaxMind.GeoIP2/Model/Anonymizer.cs, MaxMind.GeoIP2/Model/AnonymizerFeed.cs
Adds Anonymizer.Residential and the AnonymizerFeed record with JSON-mapped feed fields.
Deserialization validation and release documentation
MaxMind.GeoIP2.UnitTests/*, releasenotes.md
Adds residential feed data to the Insights fixture, validates deserialized values including DateOnly on .NET 6+, and documents the API addition.

Estimated code review effort: 2 (Simple) | ~10 minutes

Poem

A rabbit found a proxy feed,
With dates and names and confidence keyed.
“Deserialize!” they danced with glee,
“Residential data now joins the spree!”
Ears up high, the tests all pass.

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately summarizes the main change: adding residential proxy data to the Anonymizer model.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch greg/stf-997-add-residential-to-anonymizer

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request adds a new Residential property of type AnonymizerFeed to the Anonymizer model, allowing the deserialization of GeoIP Residential Proxy database details (such as confidence, last seen date, and provider name) from the GeoIP Insights web service. It also includes corresponding unit tests and updates the release notes. The reviewer suggests adding an explicit null assertion for insights.Anonymizer.Residential in the unit tests before checking its properties to improve test failure diagnostics and avoid using null-conditional operators.

Important

The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.

Comment on lines +41 to +45
Assert.Equal(82, insights.Anonymizer.Residential?.Confidence);
#if NET6_0_OR_GREATER
Assert.Equal(new DateOnly(2026, 5, 11), insights.Anonymizer.Residential?.NetworkLastSeen);
#endif
Assert.Equal("quickshift", insights.Anonymizer.Residential?.ProviderName);

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

It is better to explicitly assert that insights.Anonymizer.Residential is not null before asserting its properties. This provides a clearer failure message if the deserialization fails or returns null, and allows us to avoid using the null-conditional operator (?.) in the subsequent assertions.

            Assert.NotNull(insights.Anonymizer.Residential);
            Assert.Equal(82, insights.Anonymizer.Residential.Confidence);
#if NET6_0_OR_GREATER
            Assert.Equal(new DateOnly(2026, 5, 11), insights.Anonymizer.Residential.NetworkLastSeen);
#endif
            Assert.Equal("quickshift", insights.Anonymizer.Residential.ProviderName);

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Claude, on behalf of Greg: Done in the current revision — the assertions now use Assert.NotNull(insights.Anonymizer.Residential) followed by direct property access, matching the convention used elsewhere in these tests.

Surface residential proxy data on the anonymizer object as a
Residential sub-object with Confidence, NetworkLastSeen, and
ProviderName. The anonymizer object may now be present even when
only residential proxy data is available for a network.

A new MaxMind.GeoIP2.Model.AnonymizerFeed record has been added to
represent this shape so it can be reused if the web service adds
similar sub-objects for other types of anonymizer detection (e.g.,
VPN, mobile, datacenter) in the future.

STF-997

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@oschwald
oschwald force-pushed the greg/stf-997-add-residential-to-anonymizer branch from 3692621 to 1691db3 Compare July 14, 2026 14:57
@horgh
horgh merged commit 46620e4 into main Jul 16, 2026
19 checks passed
@horgh
horgh deleted the greg/stf-997-add-residential-to-anonymizer branch July 16, 2026 15:01
@coderabbitai coderabbitai Bot mentioned this pull request Jul 17, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

2 participants