Comment (by JunKi Yoon):
Replying to [comment:5 Mariusz Felisiak]:
Is this still a bug that needs to be fixed?
--
Ticket URL: <https://code.djangoproject.com/ticket/33871#comment:6>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.
Comment (by Mariusz Felisiak):
Replying to [comment:6 JunKi Yoon]:
> Is this still a bug that needs to be fixed?
Yes, it's waiting for a patch.
--
Ticket URL: <https://code.djangoproject.com/ticket/33871#comment:7>
* owner: nobody => JunKi Yoon
* status: new => assigned
Comment:
Replying to [comment:7 Mariusz Felisiak]:
Ok, I will try. Thank you for reply :)
--
Ticket URL: <https://code.djangoproject.com/ticket/33871#comment:8>
Comment (by JunKi Yoon):
Replying to [ticket:33871 Raphael], [ticket:33871 Mariusz Felisiak]:
Hi, Raphael. I want to patch this issue.
1. So, Could you plz give me the URL for the basic Django tutorial ?
2. And, I downloaded your attachments. I have a question about sequence
you wrote. Did you run it from the admin page ? or Django shell ?
3. Did you mean, right?
{{{
two TextField -> Question.question_text, Choice.choice_text,
one JsonField -> Choice.test
}}}
How can I reproduce ?
--
Ticket URL: <https://code.djangoproject.com/ticket/33871#comment:9>
Comment (by Raphael):
Hello,
1. So, Could you plz give me the URL for the basic Django tutorial ?
--- https://docs.djangoproject.com/en/4.1/intro/tutorial01/
2. And, I downloaded your attachments. I have a question about sequence
you wrote. Did you run it from the admin page ? or Django shell ?
-- Admin page
3. Did you mean, right?
-- I didn't really understand the question, but in the sample I attached
is another field. I don't think this is relevant to the problem. I think
it's easier for you to use the sample I sent.
How can I reproduce ?
Run the code and follow the Sequence. You will see that the data will not
be store correctly.
Thank you.
Replying to [comment:9 JunKi Yoon]:
> Replying to [ticket:33871 Raphael], [comment:7 Mariusz Felisiak]:
>
> Hi, Raphael. I want to patch this issue.
>
> 1. So, Could you plz give me the URL for the basic Django tutorial ?
>
> 2. And, I downloaded your attachments. I have a question about sequence
you wrote. Did you run it from the admin page ? or Django shell ?
>
> 3. Did you mean, right?
> {{{
> two TextField -> Question.question_text, Choice.choice_text,
> one JsonField -> Choice.test
> }}}
>
> How can I reproduce ?
--
Ticket URL: <https://code.djangoproject.com/ticket/33871#comment:10>
Comment (by JunKi Yoon):
Replying to [comment:5 Mariusz Felisiak]:
Hi Mariusz Felisiak :)
After debugging, I confirmed that the **initial-choice_set-0-test** and
**choice_set-0-test** are same.
So, I guess one thing. **initial-choice_set-0-test** is not the value that
the Choice object currently has.
**initial-choice_set-0-test** value after showing error message by
sequence 8 is stored as the input value in sequence 6.
Could you plz give me some advice regarding where to set the initial-XXX-
XXX and code?
Thank you.
cc) [comment:10 Raphael]
> Thanks for the detailed report. `initial` value is set to a new value
when invalidated, that's why changes are not detected:
> {{{
> choice_set-0-test="test 123"
> initial-choice_set-0-test="test 123"
> }}}
--
Ticket URL: <https://code.djangoproject.com/ticket/33871#comment:11>
* has_patch: 0 => 1
Comment:
[https://github.com/django/django/pull/16019 PR]
--
Ticket URL: <https://code.djangoproject.com/ticket/33871#comment:12>
* needs_better_patch: 0 => 1
Comment:
Current patch is mixing solution between forms and admin components.
Slightly clearer tests showing the problem would probably clarify.
--
Ticket URL: <https://code.djangoproject.com/ticket/33871#comment:13>
Comment (by JunKi Yoon):
Replying to [comment:13 Carlton Gibson]:
> Current patch is mixing solution between forms and admin components.
Slightly clearer tests showing the problem would probably clarify.
I Improved patch and tests. :)
--
Ticket URL: <https://code.djangoproject.com/ticket/33871#comment:14>
* status: assigned => closed
* resolution: => duplicate
* stage: Accepted => Unreviewed
Comment:
Duplicate of #34119.
--
Ticket URL: <https://code.djangoproject.com/ticket/33871#comment:15>
Comment (by David Sanders):
Confirmed the patch for #34119 fixes the issue with sample models provided
and steps described above.
--
Ticket URL: <https://code.djangoproject.com/ticket/33871#comment:16>