GSoC 2016: Draft Proposal on SQLAlchemy Integration with django

161 views
Skip to first unread message

Asif Saifuddin

unread,
Mar 18, 2016, 8:11:12 AM3/18/16
to Django developers (Contributions to Django itself)
Hi,

I have been working for preparing a proposal on SqlAlchemy integration with django. While I haven't done with in detail proposal and in depth technical specs, I'm posting my very draft proposal to understand If the broader strokes of my approach are nearly OK and I should proceed with the current approach. Critiques and suggestions are very much appreciated.


Regards,

Asif

Tim Graham

unread,
Mar 22, 2016, 8:57:01 AM3/22/16
to Django developers (Contributions to Django itself)
I've never used SQLAlchemy myself, so I can't really comment on it without the technical details of what you would actually be doing.

Asif Saifuddin

unread,
Mar 22, 2016, 12:05:49 PM3/22/16
to Django developers (Contributions to Django itself)
Hi Tim,

I have been sick for few days so couldn't work fully on the proposal. To give you have some idea on what I will be doing:

* creating a django-sqlalchemy package like flask-alchemy/pyramid_alchemy which user can use on any regular django project under installed app. The package will need different type of configurations specific to sqlalchemy and django to work properly.
* sqlalchemy has core, orm and declarative systax[more identical to django]. core is more like django expressions API based on which the ORM is built. But recently to make sqlalchemy more user friendly declarative syntax extension has been added to the library and user can use any one of the three according to there need. for regular business logic declarative sysntax is OK. but for more flexibility the ORM layer could be used, and for different advanced sql features core sql expression language is best way. these three can be used simultenuously in a project according to the need. to manage sqlalchemy there are different 3rd party tools like django has different utility in DB/ORM, management commands, migration handling, form generator, admin app etc.

From the suggestions of Russel keith-magee and Ansi, integrating sqlalchemy with django actualy means having sqlalchemy utilities which are related to table definition to work like django model/fields etc through model._meta API, that means the SQLalcmey table definitions could work smoothly with django form.model form and can be manipulated through admin app. For that I have to map sqlallchemy table definitions to work like django model fields so tht they can easily used by _meta API.

There are some parts of django which also need work to the alchemy package. many details needed to be in the proposal on how I should approach to gain the desired goal. about technical detail some are I think I have figured out but there could be more room to figure out and at the time of working there might be some new thing could be found. 

For technical detail do you have any specific suggestions following those will let the core devs properly understand and comment on?

Best Reagards,

Asif
Reply all
Reply to author
Forward
0 new messages