potiuk commented on code in PR #37757:
URL: https://github.com/apache/airflow/pull/37757#discussion_r1505062170


##########
.pre-commit-config.yaml:
##########
@@ -855,7 +855,7 @@ repos:
         files: ^dev/breeze/.*$
         pass_filenames: false
         require_serial: true
-        additional_dependencies: ['click', 'rich>=12.4.4', 'pyyaml']
+        additional_dependencies: ['click', 'rich>=12.4.4', 'pyyaml', 
'methodtools']

Review Comment:
   Indeed. Really bad idea to use lru_cache on class methods. 
   
   But... Do we need to add methodtools? 
   
   Why don't we replace all those usages with @cached_property actually ?
   
   The only problematic one is I think __hash__ in `io` but it could be rather 
easily fixed without adding methodtools:
   
   ```python
     @cached_property
     def _hash(self):
         return hash(str(self))
   
     def __hash__(self):
         return self._hash
   ```
   
   



-- 
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: commits-unsubscr...@airflow.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to