Re: [Django] #22319: ValueError: Related model cannot be resolved

2020-04-02 Thread Django
#22319: ValueError: Related model cannot be resolved
-+--
 Reporter:  efrinut@…|Owner:  nobody
 Type:  Bug  |   Status:  closed
Component:  Migrations   |  Version:  master
 Severity:  Release blocker  |   Resolution:  fixed
 Keywords:   | Triage Stage:  Unreviewed
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+--

Comment (by rvernica):

 I was able to move past this by adding the following to the `dependencies`
 field in the `Migration`:
 {{{
 class Migration(migrations.Migration):

   dependencies = [
 ('NAME_OF_RELATED_APP', 'LAST_MIGRATION_IN_THAT_APP'),
 ...
   ]
 }}}
 Now `sqlmigrate` works as expected.

 After looking around it seems that this problem has been encountered
 before and this solution worked in the past.

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/075.5aa346d8e881d7c124b63a137fa9f7cd%40djangoproject.com.


Re: [Django] #22319: ValueError: Related model cannot be resolved

2020-04-02 Thread Django
#22319: ValueError: Related model cannot be resolved
-+--
 Reporter:  efrinut@…|Owner:  nobody
 Type:  Bug  |   Status:  closed
Component:  Migrations   |  Version:  master
 Severity:  Release blocker  |   Resolution:  fixed
 Keywords:   | Triage Stage:  Unreviewed
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+--

Comment (by rvernica):

 I ran into this error when using `manage.py sqlmigrate` on Django `2.2.7`

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/075.6ad9b9695f613a7044b95284a5b09c4a%40djangoproject.com.


Re: [Django] #22319: ValueError: Related model cannot be resolved

2016-05-05 Thread Django
#22319: ValueError: Related model cannot be resolved
-+--
 Reporter:  efrinut@…|Owner:  nobody
 Type:  Bug  |   Status:  closed
Component:  Migrations   |  Version:  master
 Severity:  Release blocker  |   Resolution:  fixed
 Keywords:   | Triage Stage:  Unreviewed
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+--

Comment (by timgraham):

 Please open a new ticket with steps to reproduce the problem.

--
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/075.a9002e35f3d9ffa85893c6935b133470%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Django] #22319: ValueError: Related model cannot be resolved

2016-05-05 Thread Django
#22319: ValueError: Related model cannot be resolved
-+--
 Reporter:  efrinut@…|Owner:  nobody
 Type:  Bug  |   Status:  closed
Component:  Migrations   |  Version:  master
 Severity:  Release blocker  |   Resolution:  fixed
 Keywords:   | Triage Stage:  Unreviewed
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+--

Comment (by debugger22):

 I think this bug is still there in Django 1.9.3. Yesterday, I just added
 `null=True, blank=True` to a `ForeignKey` field and executed `python
 manage.py migrate` after `makemigrations` and it refused to migrate
 stating the same error.

--
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/075.242b0b4c729ab0d83f014e49c9bcf193%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Django] #22319: ValueError: Related model cannot be resolved

2014-04-22 Thread Django
#22319: ValueError: Related model cannot be resolved
-+--
 Reporter:  efrinut@…|Owner:  nobody
 Type:  Bug  |   Status:  closed
Component:  Migrations   |  Version:  master
 Severity:  Release blocker  |   Resolution:  fixed
 Keywords:   | Triage Stage:  Unreviewed
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+--

Comment (by loic84):

 @charettes, interestingly, it's not the same error, but rather
 `ValueError: Lookup failed for model referenced by field
 auth.Permission.content_type: contenttypes.ContentType`.

 I find that generating migrations for `d.c.contenttypes` then `d.c.auth`
 fixes the problem up to the point of #22485.

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/075.945c4eaad70d0911efec7639e2009baa%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Django] #22319: ValueError: Related model cannot be resolved

2014-04-22 Thread Django
#22319: ValueError: Related model cannot be resolved
-+--
 Reporter:  efrinut@…|Owner:  nobody
 Type:  Bug  |   Status:  closed
Component:  Migrations   |  Version:  master
 Severity:  Release blocker  |   Resolution:  fixed
 Keywords:   | Triage Stage:  Unreviewed
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+--

Comment (by charettes):

 @RLion the `auth.User` dependency problem is tracked in #22485.

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/075.a9c92a634d482f163045e9d44cdd938d%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Django] #22319: ValueError: Related model cannot be resolved

2014-04-22 Thread Django
#22319: ValueError: Related model cannot be resolved
-+--
 Reporter:  efrinut@…|Owner:  nobody
 Type:  Bug  |   Status:  closed
Component:  Migrations   |  Version:  master
 Severity:  Release blocker  |   Resolution:  fixed
 Keywords:   | Triage Stage:  Unreviewed
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+--
Changes (by RLion):

 * cc: RLion (added)


-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/075.b9f4cfbad55b2ec5ccc2ecb60cc4d428%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Django] #22319: ValueError: Related model cannot be resolved

2014-04-22 Thread Django
#22319: ValueError: Related model cannot be resolved
-+--
 Reporter:  efrinut@…|Owner:  nobody
 Type:  Bug  |   Status:  closed
Component:  Migrations   |  Version:  master
 Severity:  Release blocker  |   Resolution:  fixed
 Keywords:   | Triage Stage:  Unreviewed
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+--

Comment (by RLion):

 It seems like there's another dependancy problem, occuring with auth.User.

 https://github.com/TonyEight/minimal

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/075.4a57b9bd116bd96a26724ef699250bdc%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Django] #22319: ValueError: Related model cannot be resolved

2014-04-09 Thread Django
#22319: ValueError: Related model cannot be resolved
-+--
 Reporter:  efrinut@…|Owner:  nobody
 Type:  Bug  |   Status:  closed
Component:  Migrations   |  Version:  master
 Severity:  Release blocker  |   Resolution:  fixed
 Keywords:   | Triage Stage:  Unreviewed
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+--

Comment (by loic84):

 @maxwell.team did you try to remove the faulty migration after applying
 the patch, then running `makemigrations` and finally running `migrate`
 again?

 Also you may want to try the master version of django on github, since
 this patch has been merged already.

 Feel free to ping me on the #django-dev IRC channel (loic84).

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/075.ed90d2bcbdd075828060e45122dfe37e%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Django] #22319: ValueError: Related model cannot be resolved

2014-04-09 Thread Django
#22319: ValueError: Related model cannot be resolved
-+--
 Reporter:  efrinut@…|Owner:  nobody
 Type:  Bug  |   Status:  closed
Component:  Migrations   |  Version:  master
 Severity:  Release blocker  |   Resolution:  fixed
 Keywords:   | Triage Stage:  Unreviewed
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+--

Comment (by maxwell.team@…):

 I've same problem with my

 {{{
 content_type = models.ForeignKey(ContentType)
 }}}

 changing to

 {{{
 content_type = models.ForeignKey(ContentType, null=True, blank=True)
 }}}

 I've tried to apply patch – but the error remains:

 {{{
 ValueError: Related model 'contenttypes.ContentType' cannot be resolved
 }}}

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/075.ca4317773cc0abaa1833e2f0423b2d0b%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Django] #22319: ValueError: Related model cannot be resolved

2014-04-08 Thread Django
#22319: ValueError: Related model cannot be resolved
-+--
 Reporter:  efrinut@…|Owner:  nobody
 Type:  Bug  |   Status:  closed
Component:  Migrations   |  Version:  master
 Severity:  Release blocker  |   Resolution:  fixed
 Keywords:   | Triage Stage:  Unreviewed
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+--

Comment (by dbinetti@…):

 so sorry for the late response!  i assumed i'd be notified of followups.

 as it turns out I changed my model schema, and have not experienced this
 since.  so perhaps it worked, perhaps some other solution, but in any case
 no problems since.

 thanks!

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/075.8562d51a6694c0cfbc7e8dbc75494052%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Django] #22319: ValueError: Related model cannot be resolved

2014-03-31 Thread Django
#22319: ValueError: Related model cannot be resolved
-+--
 Reporter:  efrinut@…|Owner:  nobody
 Type:  Bug  |   Status:  closed
Component:  Migrations   |  Version:  master
 Severity:  Release blocker  |   Resolution:  fixed
 Keywords:   | Triage Stage:  Unreviewed
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+--

Comment (by loic84):

 @dbinetti, did you delete the existing migrations? This patch fixes the
 generation of migrations, but if your migration is already generated, it's
 not going to help.

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/075.8e21e3c021c5475b4b1f52c6371dd040%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Django] #22319: ValueError: Related model cannot be resolved

2014-03-31 Thread Django
#22319: ValueError: Related model cannot be resolved
-+--
 Reporter:  efrinut@…|Owner:  nobody
 Type:  Bug  |   Status:  closed
Component:  Migrations   |  Version:  master
 Severity:  Release blocker  |   Resolution:  fixed
 Keywords:   | Triage Stage:  Unreviewed
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+--

Comment (by dbinetti@…):

 Complete n00b here, so I'm not sure if I'm following protocol, but this
 fix does not work for me.  How do I go about reporting it?  I'm not even
 sure how to doc the steps to reproduce...

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/075.e7f8703a7c51ce3d7ed44d0f5ca45aaa%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Django] #22319: ValueError: Related model cannot be resolved

2014-03-31 Thread Django
#22319: ValueError: Related model cannot be resolved
-+--
 Reporter:  efrinut@…|Owner:  nobody
 Type:  Bug  |   Status:  closed
Component:  Migrations   |  Version:  master
 Severity:  Release blocker  |   Resolution:  fixed
 Keywords:   | Triage Stage:  Unreviewed
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+--
Changes (by Tim Graham ):

 * status:  new => closed
 * resolution:   => fixed


Comment:

 In [changeset:"0fd51cf0bd31afb085d16476d5a54bedf4a1bc32"]:
 {{{
 #!CommitTicketReference repository=""
 revision="0fd51cf0bd31afb085d16476d5a54bedf4a1bc32"
 Fixed #22319 -- Fixed migration external dependencies when there are
 internal dependencies.
 }}}

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/075.57886aaf63710bdf2dfafc05e0e1ca4e%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Django] #22319: ValueError: Related model cannot be resolved

2014-03-31 Thread Django
#22319: ValueError: Related model cannot be resolved
-+--
 Reporter:  efrinut@…|Owner:  nobody
 Type:  Bug  |   Status:  closed
Component:  Migrations   |  Version:  master
 Severity:  Release blocker  |   Resolution:  fixed
 Keywords:   | Triage Stage:  Unreviewed
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+--

Comment (by Tim Graham ):

 In [changeset:"8e73d3a2c17bd3233d5c6c560dda73f74083f44f"]:
 {{{
 #!CommitTicketReference repository=""
 revision="8e73d3a2c17bd3233d5c6c560dda73f74083f44f"
 [1.7.x] Fixed #22319 -- Fixed migration external dependencies when there
 are internal dependencies.

 Backport of 0fd51cf0bd from master
 }}}

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/075.c38063bfd5cafcfa83e3f406cfa50b85%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Django] #22319: ValueError: Related model cannot be resolved

2014-03-27 Thread Django
#22319: ValueError: Related model cannot be resolved
-+--
 Reporter:  efrinut@…|Owner:  nobody
 Type:  Bug  |   Status:  new
Component:  Migrations   |  Version:  master
 Severity:  Release blocker  |   Resolution:
 Keywords:   | Triage Stage:  Unreviewed
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+--

Comment (by loic84):

 PR https://github.com/django/django/pull/2490.

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/075.2fd1ac28c9315d71683e5fc5fff239a4%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Django] #22319: ValueError: Related model cannot be resolved

2014-03-25 Thread Django
#22319: ValueError: Related model cannot be resolved
-+--
 Reporter:  efrinut@…|Owner:  nobody
 Type:  Bug  |   Status:  new
Component:  Migrations   |  Version:  master
 Severity:  Release blocker  |   Resolution:
 Keywords:   | Triage Stage:  Unreviewed
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+--
Changes (by loic84):

 * cc: loic@… (added)
 * has_patch:  0 => 1


Comment:

 I came up with this patch, does it solve your issues?

 https://github.com/loic/django/compare/ticket22332

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/075.38fea42f219725dca562e8053a698723%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Django] #22319: ValueError: Related model cannot be resolved

2014-03-25 Thread Django
#22319: ValueError: Related model cannot be resolved
-+--
 Reporter:  efrinut@…|Owner:  nobody
 Type:  Bug  |   Status:  new
Component:  Migrations   |  Version:  master
 Severity:  Release blocker  |   Resolution:
 Keywords:   | Triage Stage:  Unreviewed
Has patch:  0|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+--

Comment (by bmispelon):

 I just closed #22332 as a duplicate and it had a minimal project for
 reproducing.

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/075.5f3bd9ee52172a6fd116813ee5b3%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Django] #22319: ValueError: Related model cannot be resolved

2014-03-25 Thread Django
#22319: ValueError: Related model cannot be resolved
-+--
 Reporter:  efrinut@…|Owner:  nobody
 Type:  Bug  |   Status:  new
Component:  Migrations   |  Version:  master
 Severity:  Release blocker  |   Resolution:
 Keywords:   | Triage Stage:  Unreviewed
Has patch:  0|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+--

Comment (by loic84):

 @prairiedogg, any chance you could reproduce with a minimal project that
 has a FK to `contenttypes`? I haven't managed to reproduce yet.

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/075.a6cd0bd7bbb36f2070777cfa0b4e2472%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Django] #22319: ValueError: Related model cannot be resolved

2014-03-25 Thread Django
#22319: ValueError: Related model cannot be resolved
-+--
 Reporter:  efrinut@…|Owner:  nobody
 Type:  Bug  |   Status:  new
Component:  Migrations   |  Version:  master
 Severity:  Release blocker  |   Resolution:
 Keywords:   | Triage Stage:  Unreviewed
Has patch:  0|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+--
Changes (by anonymous):

 * severity:  Normal => Release blocker


-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/075.e66c12d231782974d1631d819b451595%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Django] #22319: ValueError: Related model cannot be resolved

2014-03-24 Thread Django
#22319: ValueError: Related model cannot be resolved
+--
 Reporter:  efrinut@…   |Owner:  nobody
 Type:  Bug |   Status:  new
Component:  Migrations  |  Version:  master
 Severity:  Normal  |   Resolution:
 Keywords:  | Triage Stage:  Unreviewed
Has patch:  0   |  Needs documentation:  0
  Needs tests:  0   |  Patch needs improvement:  0
Easy pickings:  0   |UI/UX:  0
+--

Comment (by prairiedogg):

 This is also happening to me in a simple and reproducible case where I add
 a foreign key on a model to ContentType, `makemigrations` generates the
 migration just fine, but `migrate`raises the same `ValueError: Related
 model 'contenttypes.ContentType' cannot be resolved` error.

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/075.2fd11b0bae419e71bc9b5e5ad75e48d5%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Django] #22319: ValueError: Related model cannot be resolved

2014-03-24 Thread Django
#22319: ValueError: Related model cannot be resolved
+--
 Reporter:  efrinut@…   |Owner:  nobody
 Type:  Bug |   Status:  new
Component:  Migrations  |  Version:  master
 Severity:  Normal  |   Resolution:
 Keywords:  | Triage Stage:  Unreviewed
Has patch:  0   |  Needs documentation:  0
  Needs tests:  0   |  Patch needs improvement:  0
Easy pickings:  0   |UI/UX:  0
+--

Comment (by anonymous):

 Whole error code just in case:

 {{{
   Applying comments.0003_comment_link...Traceback (most recent call last):
   File "local_manage.py", line 22, in 
 execute_from_command_line(sys.argv)
   File "D:\projekty\myinit\env\lib\site-
 packages\django\core\management\__init__
 .py", line 427, in execute_from_command_line
 utility.execute()
   File "D:\projekty\myinit\env\lib\site-
 packages\django\core\management\__init__
 .py", line 419, in execute
 self.fetch_command(subcommand).run_from_argv(self.argv)
   File "D:\projekty\myinit\env\lib\site-
 packages\django\core\management\base.py"
 , line 288, in run_from_argv
 self.execute(*args, **options.__dict__)
   File "D:\projekty\myinit\env\lib\site-
 packages\django\core\management\base.py"
 , line 337, in execute
 output = self.handle(*args, **options)
   File "D:\projekty\myinit\env\lib\site-
 packages\django\core\management\commands
 \migrate.py", line 145, in handle
 executor.migrate(targets, plan, fake=options.get("fake", False))
   File "D:\projekty\myinit\env\lib\site-
 packages\django\db\migrations\executor.p
 y", line 60, in migrate
 self.apply_migration(migration, fake=fake)
   File "D:\projekty\myinit\env\lib\site-
 packages\django\db\migrations\executor.p
 y", line 94, in apply_migration
 migration.apply(project_state, schema_editor)
   File "D:\projekty\myinit\env\lib\site-
 packages\django\db\migrations\migration.
 py", line 97, in apply
 operation.database_forwards(self.app_label, schema_editor,
 project_state, ne
 w_state)
   File "D:\projekty\myinit\env\lib\site-
 packages\django\db\migrations\operations
 \fields.py", line 36, in database_forwards
 field,
   File "D:\projekty\myinit\env\lib\site-
 packages\django\db\backends\schema.py",
 line 378, in add_field
 definition, params = self.column_sql(model, field,
 include_default=True)
   File "D:\projekty\myinit\env\lib\site-
 packages\django\db\backends\schema.py",
 line 108, in column_sql
 db_params = field.db_parameters(connection=self.connection)
   File "D:\projekty\myinit\env\lib\site-
 packages\django\db\models\fields\related
 .py", line 1749, in db_parameters
 return {"type": self.db_type(connection), "check": []}
   File "D:\projekty\myinit\env\lib\site-
 packages\django\db\models\fields\related
 .py", line 1740, in db_type
 rel_field = self.related_field
   File "D:\projekty\myinit\env\lib\site-
 packages\django\db\models\fields\related
 .py", line 1646, in related_field
 return self.foreign_related_fields[0]
   File "D:\projekty\myinit\env\lib\site-
 packages\django\db\models\fields\related
 .py", line 1405, in foreign_related_fields
 return tuple(rhs_field for lhs_field, rhs_field in
 self.related_fields)
   File "D:\projekty\myinit\env\lib\site-
 packages\django\db\models\fields\related
 .py", line 1392, in related_fields
 self._related_fields = self.resolve_related_fields()
   File "D:\projekty\myinit\env\lib\site-
 packages\django\db\models\fields\related
 .py", line 1377, in resolve_related_fields
 raise ValueError('Related model %r cannot be resolved' % self.rel.to)
 ValueError: Related model 'links.Link' cannot be resolved

 }}}

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/075.7a184c7ac7486bd53802e023d785a5a3%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Django] #22319: ValueError: Related model cannot be resolved

2014-03-23 Thread Django
#22319: ValueError: Related model cannot be resolved
+--
 Reporter:  efrinut@…   |Owner:  nobody
 Type:  Bug |   Status:  new
Component:  Migrations  |  Version:  master
 Severity:  Normal  |   Resolution:
 Keywords:  | Triage Stage:  Unreviewed
Has patch:  0   |  Needs documentation:  0
  Needs tests:  0   |  Patch needs improvement:  0
Easy pickings:  0   |UI/UX:  0
+--

Comment (by melinath):

 This seems to be resolved (in the case where I'm getting it now - a rel to
 auth.Group) by adding a dependency to `auth.__first__` - not sure why that
 wasn't automatically added. Also not sure why I was seeing this before,
 since swappable_dependency *was* present and seems to just be a shortcut
 to `app_label.__first__`

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/075.b0c4aca427bcbebb0ec9b7e0494dbf55%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Django] #22319: ValueError: Related model cannot be resolved

2014-03-23 Thread Django
#22319: ValueError: Related model cannot be resolved
+--
 Reporter:  efrinut@…   |Owner:  nobody
 Type:  Bug |   Status:  new
Component:  Migrations  |  Version:  master
 Severity:  Normal  |   Resolution:
 Keywords:  | Triage Stage:  Unreviewed
Has patch:  0   |  Needs documentation:  0
  Needs tests:  0   |  Patch needs improvement:  0
Easy pickings:  0   |UI/UX:  0
+--

Comment (by melinath):

 81f5408 is the first commit where the migrations that are autogenerated
 start exhibiting this behavior - but they have this behavior all the way
 back to 1.7a1, at the very least, once they've been generated. (I get
 different errors for my migrations that are generated *before* 81f5408, so
 I can't tell whether the generation is also wrong before that.)

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/075.54e08319e28c5fb54fa524608813b68f%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Django] #22319: ValueError: Related model cannot be resolved

2014-03-23 Thread Django
#22319: ValueError: Related model cannot be resolved
+--
 Reporter:  efrinut@…   |Owner:  nobody
 Type:  Bug |   Status:  new
Component:  Migrations  |  Version:  master
 Severity:  Normal  |   Resolution:
 Keywords:  | Triage Stage:  Unreviewed
Has patch:  0   |  Needs documentation:  0
  Needs tests:  0   |  Patch needs improvement:  0
Easy pickings:  0   |UI/UX:  0
+--

Comment (by melinath):

 This *particular* bug starts showing up in
 
https://github.com/django/django/commit/81f5408c7a16b8c79053950f05fe7a873506ca55
 (git bisect) but I don't know whether that commit causes it or just
 uncovers it.

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/075.6d4a6818bffd5f325c9278ac78518192%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Django] #22319: ValueError: Related model cannot be resolved

2014-03-23 Thread Django
#22319: ValueError: Related model cannot be resolved
+--
 Reporter:  efrinut@…   |Owner:  nobody
 Type:  Bug |   Status:  new
Component:  Migrations  |  Version:  master
 Severity:  Normal  |   Resolution:
 Keywords:  | Triage Stage:  Unreviewed
Has patch:  0   |  Needs documentation:  0
  Needs tests:  0   |  Patch needs improvement:  0
Easy pickings:  0   |UI/UX:  0
+--

Comment (by melinath):

 I'm seeing this as well. Just tried to re-generate my migrations, and they
 won't run. I got it with auth.User, whether I specify it as 'auth.User' or
 by importing the model. It looks like the migration doesn't run
 do_pending_lookups for models from external apps, for some reason.

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/075.2dca8603d1640c66c215519ff874b7ec%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Django] #22319: ValueError: Related model cannot be resolved

2014-03-23 Thread Django
#22319: ValueError: Related model cannot be resolved
+--
 Reporter:  efrinut@…   |Owner:  nobody
 Type:  Bug |   Status:  new
Component:  Migrations  |  Version:  master
 Severity:  Normal  |   Resolution:
 Keywords:  | Triage Stage:  Unreviewed
Has patch:  0   |  Needs documentation:  0
  Needs tests:  0   |  Patch needs improvement:  0
Easy pickings:  0   |UI/UX:  0
+--
Changes (by anonymous):

 * needs_better_patch:   => 0
 * needs_tests:   => 0
 * needs_docs:   => 0


Comment:

 It happens in django 1.7 beta 1

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/075.1de4e046c85dcae7e1ea5dc9bf2f9a6c%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.


[Django] #22319: ValueError: Related model cannot be resolved

2014-03-23 Thread Django
#22319: ValueError: Related model cannot be resolved
+
 Reporter:  efrinut@…   |  Owner:  nobody
 Type:  Bug | Status:  new
Component:  Migrations  |Version:  master
 Severity:  Normal  |   Keywords:
 Triage Stage:  Unreviewed  |  Has patch:  0
Easy pickings:  0   |  UI/UX:  0
+
 Hey!

 When I try to migrate comments model I get an error:

 {{{
 raise ValueError('Related model %r cannot be resolved' % self.rel.to)
 ValueError: Related model 'links.Link' cannot be resolved
 }}}

 It only happens for this model so when I remove Link fk everything passes
 smoothly


 {{{
 DJANGO_APPS = (
 'django.contrib.auth',
 'django.contrib.contenttypes',
 'django.contrib.sessions',
 'django.contrib.sites',
 'django.contrib.messages',
 'django.contrib.staticfiles',
 'django.contrib.admin',
 'django.contrib.admindocs',
 'django.contrib.webdesign',
 'django.contrib.humanize',
 'django.contrib.sitemaps',
 'django.contrib.flatpages',
 )

 EXTERNAL_APPS = (
 'haystack',
 'storages',
 'pipeline',
 'endless_pagination',
 'easy_thumbnails',
 'mptt',
 'rest_framework',
 'crispy_forms',
 'crispy_forms_foundation',
 'taggit',
 )

 SITE_APPS = (
 'accounts',
 'links',
 'core',
 'images',
 'comments',
 )

 INSTALLED_APPS = DJANGO_APPS + EXTERNAL_APPS + SITE_APPS

 }}}

 {{{
 # -*- coding: utf-8 -*-
 from django.db import models
 from django.core.urlresolvers import reverse
 from django.conf import settings
 from links.models import Link


 class Comment(models.Model):
 link = models.ForeignKey(Link, null=True, blank=True)
 user = models.ForeignKey(settings.AUTH_USER_MODEL, null=True,
 blank=False)
 description = models.TextField(null=True, blank=False)
 parent = models.ForeignKey("self", null=True, blank=True)

 date_added = models.DateTimeField(auto_now_add=True, null=True)
 date_updated = models.DateTimeField(auto_now=True, null=True)

 class Meta:
 verbose_name = u"Comment"
 verbose_name_plural = u"Comments"

 def get_absolute_url(self):
 return reverse("comment:detail", kwargs={'pk': self.pk})


 }}}



 {{{
 # -*- coding: utf-8 -*-
 from urlparse import urlparse
 from django.core.urlresolvers import reverse
 from django.db import models
 from taggit.managers import TaggableManager
 from .managers import ActiveManager
 from django.conf import settings


 class Link(models.Model):
 class Meta:
 verbose_name = u"Link"
 verbose_name_plural = u"Links"

 CONTENT = 1
 IMAGE = 2
 VIDEO = 3

 LINK_TYPES = (
 (CONTENT, u"content"),
 (IMAGE, u"image"),
 (VIDEO, u"video"),
 )

 title = models.CharField(max_length=255, null=True, blank=True)
 description = models.TextField(max_length=1000, null=True,
 blank=False)
 user = models.ForeignKey(settings.AUTH_USER_MODEL, null=True,
 blank=False)
 url = models.URLField(null=True, blank=False)
 domain = models.URLField(null=True, blank=False)
 date_added = models.DateTimeField(auto_now_add=True, null=True)
 date_updated = models.DateTimeField(auto_now=True, null=True)

 link_type = models.PositiveIntegerField(choices=LINK_TYPES, null=True,
 blank=False)
 classified = models.BooleanField(default=False)
 published = models.BooleanField(default=True)

 objects = models.Manager()
 active = ActiveManager()

 # tags = TaggableManager()

 def __unicode__(self):
 return u"{}".format(self.id)

 def get_domain(self):
 return u"{}".format(urlparse(self.url).netloc)

 def get_domain_url(self):
 url = urlparse(self.url)
 return u"{}://{}".format(url.scheme, url.netloc)

 def get_absolute_url(self):
 return reverse("link:detail", kwargs={'pk': self.pk})

 def get_vote_count(self):
 return 0

 def get_comment_count(self):
 return 0

 }}}

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/060.d0956d1503f8cb5878487dce7eb027bc%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.