Hacker News new | past | comments | ask | show | jobs | submit login

There is a Python library/tool called Bowler (https://pybowler.io/docs/basics-intro) that allows selecting and transforming elements on a concrete syntax tree. From my limited experience with it, I guess it would have been a nice fit for this refactoring.



I was going to suggest libCST, it works really well and is much less of a hassle to set up than this.

https://github.com/Instagram/LibCST


Great suggestion! Bowler seems to be abandoned actually. Its README mentions wanting to rewrite on top of LibCST though (https://github.com/facebookincubator/Bowler?tab=readme-ov-fi...).




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: