-
-
Notifications
You must be signed in to change notification settings - Fork 719
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
KeyError when using distributed scheduler with __array_function__ #5224
Comments
As a heads up, Florian is heading out on PTO tomorrow, so Florian may not
have time to engage here. Also cc'ing @pentschev due to the array function
angle.
…On Tue, Aug 17, 2021 at 6:03 PM James Bourbeau ***@***.***> wrote:
Thanks for reporting @gforsyth <https://github.com/gforsyth>, I'm able to
reproduce. cc @fjetter <https://github.com/fjetter>
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#5224 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AACKZTHK77CRWAK466IVMBDT5LTCXANCNFSM5CKR73AQ>
.
Triage notifications on the go with GitHub Mobile for iOS
<https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675>
or Android
<https://play.google.com/store/apps/details?id=com.github.android&utm_campaign=notification-email>
.
|
Thanks Matt. I believe he'll be out starting the day after tomorrow, so I'm hoping he might be able to take a look at this tomorrow (though it's entirely possible he might be fully saturated with other things). A more thoughtful solution is definitely welcome, but we could always punt for now with this diff: diff --git a/distributed/client.py b/distributed/client.py
index e7389220..92f778a6 100644
--- a/distributed/client.py
+++ b/distributed/client.py
@@ -2522,7 +2522,7 @@ class Client:
for fr, _ in traceback.walk_stack(None):
if pattern is None or (
- not pattern.match(fr.f_globals["__name__"])
+ not pattern.match(fr.f_globals.get("__name__", ""))
and fr.f_code.co_name not in ("<listcomp>", "<dictcomp>")
):
try: |
It seems like @jrbourbeau has already a potential solution, but it's worth noting that although the |
Yep Peter is right this is unsupported by DataFrame libraries. For example see this Pandas issue ( pandas-dev/pandas#26380 ). There is a larger discussion about creating a common DataFrame API, but I don't think we have discussed using Array API functions on DataFrames. Have raised issue ( data-apis/dataframe-api#50 ) about this use case |
Thanks for the feedback @pentschev @jakirkham! I'm proposing the above solution over in #5236. While it's a great point that we can't assume FWIW I also ran into the same |
Off-topic, but that's neat Erik made a library for that. Saw some of the discussion, but didn't see there was now a library that did this. |
Closed via #5236 |
The
_get_computation_codes
introduced in #5001 causes errors if relying onnumpy
ducktyping on adask.dataframe
What happened: I get a
KeyError
when I usenumpy.where
on a column of adask.dataframe
What you expected to happen: Forced evaluation of column
Minimal Complete Verifiable Example:
No issue (without
distributed
scheduler)with
distributed
schedulerAnything else we need to know?:
Environment:
The text was updated successfully, but these errors were encountered: