Uploaded image for project: 'Beam'
  1. Beam
  2. BEAM-9574

NamedTuple instances generated from schemas cannot be pickled

Details

    • Bug
    • Status: Resolved
    • P2
    • Resolution: Fixed
    • None
    • 2.21.0
    • sdk-py-core
    • None

    Description

      Attempting to pickle an instance of a generated NamedTuple class results in the following:

      _pickle.PicklingError: Can't pickle <class 'apache_beam.typehints.schemas.BeamSchema_a7de91e0_ae11_4c52_a041_0b58ada35ac1'>: attribute lookup BeamSchema_a7de91e0_ae11_4c52_a041_0b58ada35ac1 on apache_beam.typehints.schemas failed
      

      In general, we shouldn't be pickling these instances, but occasionally it may be necessary, and we should just do it rather than failing hard.

      Attachments

        Issue Links

          Activity

            People

              bhulette Brian Hulette
              bhulette Brian Hulette
              Votes:
              0 Vote for this issue
              Watchers:
              1 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 - 50m
                  50m