Closed KellerKev closed 3 years ago
@Kkeller83 , I will be glad to add support for pydal. I will check docs to see examples - if you have more examples of pydal usage - it will be helpful.
I have separate project - https://github.com/xnuinside/omymodels I planned to add conversion between different models type on it. I can start from sqlalchemy to pydal :) if need exists
Yes, it would help py4web and the web2py community a lot.
The thing is that those frameworks are not as popular as flask or django, but thanks to the pydal orm and generators for html crud grids and html forms as well as out of the authentication and authorization, they make it incredbily easy to create CRUD based applications fast. There is also documentation how to use HTMX so you avoid JS to get interactivity.
Its really great especially for beginners and protyping, while full fledged apps are also no problem.
Now the biggest drawback for beginners is that they are afreaid to learn an ORM that is not the Django or SQLAlchemy ORM, because they are afraid they cant use the examples on the internet using sqlalchemly or they cant get support if they dont use that ORM etc.
A convert would really bridge that and would make a huge difference getting people into developing web apps with python.
Here is main material around pydal I can give you:
http://www.web2py.com/books/default/chapter/29/06/the-database-abstraction-layer https://zetcode.com/python/pydal/ http://www.trilhaspython.com.br/2020/11/26/pydal-pandas-e-jupyter-notebook-o-padrao-mvc-em-data-science-engineering/ https://www.youtube.com/watch?v=tkxExOXAeZw
@Kkeller83 version 0.5.0 https://pypi.org/project/py-models-parser/ released with Pydal support, tests samples are here: https://github.com/xnuinside/py-models-parser/blob/main/tests/test_pydal.py
If you will see any issues, please report about them with examples.
About converter - I will mention you here when I add it to OMyModels
WOW WOW WOW WOW WOW WOW WOW Thank you so much!!!!!! Will test it out. Once pydal support is added to OMyModels I can make a video and share it so you see in action what your work will enable!
@Kkeller83 I will close the issue, if you will find the bug - please report in new :) and thank you!
Yes, I will need run some tests on the weekend. Thank you!
https://github.com/web2py/pydal
its the ORM layer of web2py and py4web which can be used standalone as well.
https://py4web.com/ http://web2py.com/books/default/chapter/29/06/the-database-abstraction-layer
This would really help and the web2py community.
Is it also possible to generate modesl from the output of your parser?
As in doing conversions of models from e.g. sqlalchemy to pydal?