#37081: loaddata fails when a directory in the fixture path contains a dot
-------------------------------------+-------------------------------------
     Reporter:  Alisson Silveira     |                     Type:  Bug
       Status:  new                  |                Component:  Core
                                     |  (Management commands)
      Version:  6.0                  |                 Severity:  Normal
     Keywords:                       |             Triage Stage:
                                     |  Unreviewed
    Has patch:  0                    |      Needs documentation:  0
  Needs tests:  0                    |  Patch needs improvement:  0
Easy pickings:  0                    |                    UI/UX:  0
-------------------------------------+-------------------------------------
 How to reproduce:

 Create a fixture in a directory containing a dot, for example:
 {{{
 fixtures/fix.v1/data.json
 }}}

 Run (without specifying the file extension):
 {{{
 python manage.py loaddata fixtures/fix.v1/data
 }}}

 This raises:
 {{{
 CommandError: Problem installing fixture 'fixtures/fix': v1/data is not a
 known serialization format.
 }}}

 This occurs when a directory in the fixture path contains a dot, as the
 full path is incorrectly split on "." instead of operating on the file
 name.

 Expected behavior: Django should correctly determine the fixture format
 based on the file name and load the fixture successfully, ignoring dots in
 directory names.

 A fix has been identified and will be submitted in a pull request.
-- 
Ticket URL: <https://code.djangoproject.com/ticket/37081>
Django <https://code.djangoproject.com/>
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 [email protected].
To view this discussion visit 
https://groups.google.com/d/msgid/django-updates/0107019de57e1d7a-9ed01bf0-2d95-4c13-96ae-f848ef3a5052-000000%40eu-central-1.amazonses.com.

Reply via email to