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

Separate "indexed objects" by type #2572

Merged
merged 2 commits into from
Nov 26, 2024
Merged

Conversation

erikbern
Copy link
Contributor

We have a few Dict[str, _Object] where the object is either a function or a class. It makes sense to separate these by type. Starting with App.indexed_objects. I'll do Running_app.tag_to_object_id later.

@erikbern erikbern requested a review from mwaskom November 25, 2024 23:49
Copy link
Contributor

@mwaskom mwaskom left a comment

Choose a reason for hiding this comment

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

👍 we have some very annoying code to unmix the tag_to_object_ids into the separate function_ids / class_ids for the AppPublishRequest, will be nice to clean that up!

return self._indexed_objects
deprecation_warning(
(2024, 11, 25),
"`app.indexed_objects` is deprecated! Use `app.registered_functions` or `app.registered_classes` instead.",
Copy link
Contributor

Choose a reason for hiding this comment

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

I think we might be planning on deprecating those too? 😁

@@ -177,7 +177,8 @@ def foo():

_name: Optional[str]
_description: Optional[str]
_indexed_objects: Dict[str, _Object]
_functions: Dict[str, _Function]
_classes: Dict[str, _Cls]
Copy link
Contributor

@mwaskom mwaskom Nov 26, 2024

Choose a reason for hiding this comment

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

classes? Or ... clses? 🤔 😭

Copy link
Contributor Author

Choose a reason for hiding this comment

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

yeah idk, no strong feelings

@erikbern erikbern merged commit 406b5f3 into main Nov 26, 2024
23 checks passed
@erikbern erikbern deleted the erikbern/remove-indexed-objects-i branch November 26, 2024 14:42
@erikbern
Copy link
Contributor Author

will continue sporadically over the next few weeks

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