On 14-2-2017 23:44, Makoto Kuwata wrote: > Hi, > > Is there any *just right* python code to refactor? > In other words, I'm finding bad code example in python. > > (background) > I'm teaching Python to some novice programmer, and > want to show refactoring example to them. > > (required) > * not good code > * not too large (for novice programmer) > * not too complex (for novice programmer) > * released under open source license > > If you know good material in github or bitbucket to refactor, > let me know it. > > -- > regards, > kwatch >
No code in text form, but I find the following video by Raymond Hettinger very clear about the values of refactoring otherwise seemingly fine code https://youtu.be/wf-BqAjZb8M?t=12m39s code starts at 12 min. 40 sec. It does require a bit of background knowledge about Python and the PEP8 code style and API design. Irmen -- https://mail.python.org/mailman/listinfo/python-list