Uploaded image for project: 'Apache Arrow'
  1. Apache Arrow
  2. ARROW-14255

[Python] FlightClient.do_action is a generator instead of returning one.

    XMLWordPrintableJSON

Details

    Description

      According to the documentation ( https://arrow.apache.org/docs/python/generated/pyarrow.flight.FlightClient.html#pyarrow.flight.FlightClient.do_action ) I would expect to be able to invoke client.do_action and get back an iterator. While it seems that the function is in fact a generator itself.

      This makes a big difference because if it returns an iterator I expect to be able to do client.do_action(...) and just ignore the result if I don't care. But if it's a generator ignoring the results makes so that it actually doesn't get invoked at all and thus that the server won't do anything.

      It would make sense to make do_action return a generator instead of being a generator itself, that would keep backward compatibility and would avoid puzzled users that don't see their code being invoked when they do client.do_action(...)

      Attachments

        Issue Links

          Activity

            People

              amol- Alessandro Molina
              amol- Alessandro Molina
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0h
                  0h
                  Logged:
                  Time Spent - 2h 10m
                  2h 10m