transferring the edit loop code from _form_edit_loop.py to __init__.py, this may or may not be restructured