Skip to content

feat: remove datacenter property from server and primary_ip#1460

Open
lukasmetzner wants to merge 3 commits into
mainfrom
feat/remove-datacenter-property
Open

feat: remove datacenter property from server and primary_ip#1460
lukasmetzner wants to merge 3 commits into
mainfrom
feat/remove-datacenter-property

Conversation

@lukasmetzner

Copy link
Copy Markdown
Contributor

Remove the datacenter property from Server and Primary IP resource where
possible. The property was deprecated ~6 months ago, and because the property
is removed from the API, removing it from our code is not considered a breaking
change.

Changelog entry: https://docs.hetzner.cloud/changelog#2026-07-01-removing-datacenters

Remove the `datacenter` property from Server and Primary IP resource where
possible. The property was deprecated ~6 months ago, and because the property
is removed from the API, removing it from our code is not considered a breaking
change.

Changelog entry: https://docs.hetzner.cloud/changelog#2026-07-01-removing-datacenters
@lukasmetzner
lukasmetzner requested a review from a team as a code owner July 21, 2026 14:09
@codecov

codecov Bot commented Jul 21, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 73.12%. Comparing base (6f2fcae) to head (9d35d87).

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1460      +/-   ##
==========================================
+ Coverage   72.89%   73.12%   +0.23%     
==========================================
  Files         300      300              
  Lines       11127    11081      -46     
==========================================
- Hits         8111     8103       -8     
+ Misses       2118     2084      -34     
+ Partials      898      894       -4     
Flag Coverage Δ
e2e 51.50% <85.71%> (+0.14%) ⬆️
unit 67.97% <100.00%> (+0.20%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.


Create a Primary IP.

The --datacenter flag is deprecated. Use --location or --assignee-id instead.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Could we maybe keep a little reference to the --datacenter in the docs? .e.g that is has been removed?

@lukasmetzner lukasmetzner Jul 22, 2026

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Added a little note to PrimaryIP and Server with a link to the changelog.

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.

2 participants