Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: allow returning root_password in servers rebuild #276

Merged
merged 1 commit into from
Nov 17, 2023

Conversation

jooola
Copy link
Member

@jooola jooola commented Aug 7, 2023

Fixes #181

Allow returning a full response during the server rebuild by passing an option to the rebuild method. The main reason for this is to not break user land and give users time to upgrade. We also don't want to introduce a new method rebuild2 or rebuild_with_full_response to keep the API clean.

The deprecation timeline is the following:

  • Introduce the return_response argument and deprecated the default behavior (return_response=False)
  • Wait for the next major release to remove the ability to only return the action and deprecated the usage of the return_response argument.
  • Wait for the next+1 major release to fully remove the return_response argument, or simply leave it unused.

@jooola jooola force-pushed the server_rebuild_password branch 2 times, most recently from b1559a9 to 703a476 Compare August 8, 2023 15:46
Copy link
Member

@apricote apricote left a comment

Choose a reason for hiding this comment

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

Looks fine code wise.

Regarding returning different responses based on an argument i think its fine. With the typing people should be informed about it when we change the default.

hcloud/servers/client.py Outdated Show resolved Hide resolved
hcloud/servers/client.py Outdated Show resolved Hide resolved
Copy link

This PR has been marked as stale because it has not had recent activity. The bot will close the PR if no further action occurs.

@github-actions github-actions bot added the Stale label Nov 12, 2023
@jooola jooola merged commit 38e098a into hetznercloud:main Nov 17, 2023
9 checks passed
@jooola jooola deleted the server_rebuild_password branch November 17, 2023 14:06
jooola pushed a commit that referenced this pull request Nov 17, 2023
🤖 I have created a release *beep* *boop*
---


##
[1.32.0](v1.31.0...v1.32.0)
(2023-11-17)


### Features

* allow returning root_password in servers rebuild
([#276](#276))
([38e098a](38e098a))


### Dependencies

* update dependency mypy to >=1.7,<1.8
([#325](#325))
([7b59a2d](7b59a2d))
* update pre-commit hook pre-commit/mirrors-prettier to v3.1.0
([#326](#326))
([213b661](213b661))
* update pre-commit hook psf/black-pre-commit-mirror to v23.10.1
([#322](#322))
([999afe3](999afe3))
* update pre-commit hook psf/black-pre-commit-mirror to v23.11.0
([#324](#324))
([7b2a24e](7b2a24e))

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Rebuild does not return root_password
2 participants