These are chat archives for django/django

3rd
Jun 2018
Janusz Kamieński
@ivellios
Jun 03 2018 08:02

Well I hit the wall...
I have added my own ManyToMany model and added it to another model for a relation. I have locally (and also tried on stage) generated automatic migration, but on migrate it tells me:

django.db.utils.IntegrityError: (1215, 'Cannot add foreign key constraint')

The migration is: https://github.com/ivellios/django-rotv-apps/blob/feature/slug_for_episodes_and_playlists/rotv_apps/program/migrations/0009_auto_20180603_0958.py

And my M2M model is currently: https://github.com/ivellios/django-rotv-apps/blob/feature/slug_for_episodes_and_playlists/rotv_apps/program/models.py#L81

It is being used here: https://github.com/ivellios/django-rotv-apps/blob/feature/slug_for_episodes_and_playlists/rotv_apps/program/models.py#L135

It passes smoothly on localhost (sqlite), but not on staging (MySQL).

What am I doing wrong?

Janusz Kamieński
@ivellios
Jun 03 2018 09:28
Looks like Mysql has some issue with creating FK index, but created table properly and it works when I skip the migration with fake again... weird stuff, but works
Roel
@roelzkie15
Jun 03 2018 12:29
@ThomasDang93 If you only want your app/site to "LOOK" good for mobile then bootstrap is enough, you wont need any REST except if you need a MOBILE APP
to get its data from your website.

some simple question to ask:

What JavaScript framework is best for Django Multiple Page App architecture?

ThomasDang93
@ThomasDang93
Jun 03 2018 12:37
Thanks, people keep telling me that react pairs well with Django. From my perspective it feels a little overwhelming to know all these frameworks. I don't feel the same way when it comes to choosing databases or programming languages
People also keep telling me Django is dying. But since python is one of the most popular languages, I just can't see it fading away anytime soon
Roel
@roelzkie15
Jun 03 2018 12:49
@ThomasDang93 django is not dying, it became more stable and powerful framework than ever