[ 
https://issues.apache.org/jira/browse/BEAM-13386?focusedWorklogId=697971&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-697971
 ]

ASF GitHub Bot logged work on BEAM-13386:
-----------------------------------------

                Author: ASF GitHub Bot
            Created on: 17/Dec/21 16:12
            Start Date: 17/Dec/21 16:12
    Worklog Time Spent: 10m 
      Work Description: ryanthompson591 commented on a change in pull request 
#16250:
URL: https://github.com/apache/beam/pull/16250#discussion_r771516598



##########
File path: sdks/python/apache_beam/internal/cloudpickle_pickler.py
##########
@@ -99,6 +103,14 @@ def _create_absl_flags():
   return flags.FLAGS
 
 
+def _pickle_rlock(obj):
+  return _create_rlock, tuple([])
+
+
+def _create_rlock():
+  return RLOCK_TYPE()

Review comment:
       I added two tests. One for the default lib (dill) and one for 
cloudpickle.
   
   Also I want to return RLOCK_TYPE() which makes a new instance of the type.  
Dill does it similarily here:
   
https://github.com/uqfoundation/dill/blob/04aba03432955f64c05441ffe0553af987c087ff/dill/_dill.py#L744
   
   What dill does that doesn't make any sense for cloud pickle is it also tries 
to populate whether or not the lock is locked. That might make sense for save 
session but makes no sense when it is just a class




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


Issue Time Tracking
-------------------

    Worklog Id:     (was: 697971)
    Time Spent: 1h 20m  (was: 1h 10m)

> Make cloudpickle the default pickle library
> -------------------------------------------
>
>                 Key: BEAM-13386
>                 URL: https://issues.apache.org/jira/browse/BEAM-13386
>             Project: Beam
>          Issue Type: Improvement
>          Components: sdk-py-core
>            Reporter: Ryan Thompson
>            Assignee: Ryan Thompson
>            Priority: P3
>          Time Spent: 1h 20m
>  Remaining Estimate: 0h
>
> Make cloudpickle the default pickle library.
>  
> See change [https://github.com/apache/beam/pull/15472] and docs 
> [_https://s.apache.org/beam-picklers_].
>  



--
This message was sent by Atlassian Jira
(v8.20.1#820001)

Reply via email to