Phase 3: Add Self type annotations to fluent/clone methods#4907
Closed
Balandat wants to merge 1 commit intofacebook:mainfrom
Closed
Phase 3: Add Self type annotations to fluent/clone methods#4907Balandat wants to merge 1 commit intofacebook:mainfrom
Balandat wants to merge 1 commit intofacebook:mainfrom
Conversation
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #4907 +/- ##
==========================================
- Coverage 96.80% 96.80% -0.01%
==========================================
Files 595 595
Lines 63143 63148 +5
==========================================
+ Hits 61127 61131 +4
- Misses 2016 2017 +1 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
83f550a to
93e35b1
Compare
Balandat
added a commit
to Balandat/Ax
that referenced
this pull request
Feb 19, 2026
…4907) Summary: Add Self type annotation from typing module to methods that return self or cloned instances of the same class. This enables better type inference for subclasses and improves IDE support. Files changed: - ax/core/base_trial.py - run(), stop(), complete(), mark_*() methods - ax/core/batch_trial.py - mark_arm_abandoned() - ax/core/experiment.py - add_tracking_metric(), update_tracking_metric(), etc. - ax/core/multi_type_experiment.py - add_trial_type(), update_runner(), metric methods - ax/core/arm.py - clone() - ax/core/objective.py - clone() on Objective, MultiObjective, ScalarizedObjective - ax/core/optimization_config.py - clone() - ax/core/runner.py - clone() - ax/core/parameter.py - clone() abstract method Reviewed By: saitcakmak Differential Revision: D93186334
93e35b1 to
d0fb5b7
Compare
Balandat
added a commit
to Balandat/Ax
that referenced
this pull request
Feb 20, 2026
…4907) Summary: Add Self type annotation from typing module to methods that return self or cloned instances of the same class. This enables better type inference for subclasses and improves IDE support. Files changed: - ax/core/base_trial.py - run(), stop(), complete(), mark_*() methods - ax/core/batch_trial.py - mark_arm_abandoned() - ax/core/experiment.py - add_tracking_metric(), update_tracking_metric(), etc. - ax/core/multi_type_experiment.py - add_trial_type(), update_runner(), metric methods - ax/core/arm.py - clone() - ax/core/objective.py - clone() on Objective, MultiObjective, ScalarizedObjective - ax/core/optimization_config.py - clone() - ax/core/runner.py - clone() - ax/core/parameter.py - clone() abstract method Reviewed By: saitcakmak Differential Revision: D93186334
Balandat
added a commit
to Balandat/Ax
that referenced
this pull request
Feb 20, 2026
…4907) Summary: Add Self type annotation from typing module to methods that return self or cloned instances of the same class. This enables better type inference for subclasses and improves IDE support. Files changed: - ax/core/base_trial.py - run(), stop(), complete(), mark_*() methods - ax/core/batch_trial.py - mark_arm_abandoned() - ax/core/experiment.py - add_tracking_metric(), update_tracking_metric(), etc. - ax/core/multi_type_experiment.py - add_trial_type(), update_runner(), metric methods - ax/core/arm.py - clone() - ax/core/objective.py - clone() on Objective, MultiObjective, ScalarizedObjective - ax/core/optimization_config.py - clone() - ax/core/runner.py - clone() - ax/core/parameter.py - clone() abstract method Reviewed By: saitcakmak Differential Revision: D93186334
d0fb5b7 to
560345c
Compare
…4907) Summary: Add Self type annotation from typing module to methods that return self or cloned instances of the same class. This enables better type inference for subclasses and improves IDE support. Files changed: - ax/core/base_trial.py - run(), stop(), complete(), mark_*() methods - ax/core/batch_trial.py - mark_arm_abandoned() - ax/core/experiment.py - add_tracking_metric(), update_tracking_metric(), etc. - ax/core/multi_type_experiment.py - add_trial_type(), update_runner(), metric methods - ax/core/arm.py - clone() - ax/core/objective.py - clone() on Objective, MultiObjective, ScalarizedObjective - ax/core/optimization_config.py - clone() - ax/core/runner.py - clone() - ax/core/parameter.py - clone() abstract method Reviewed By: saitcakmak Differential Revision: D93186334
560345c to
98d6b20
Compare
|
This pull request has been merged in ff18218. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary:
Add Self type annotation from typing module to methods that return self
or cloned instances of the same class. This enables better type inference
for subclasses and improves IDE support.
Files changed:
Differential Revision: D93186334