error 'NoneType' object has no attribute '__dict__'
问题 I have encoutered this error and its not letting me save the info in the form. The initial data is showing well in the form but saving is challenging me. Hope someone can help, I'm really stuck class UserPostCreatView(CreateView): form_class = PostModelForm template_name = 'posts/post_form.html' success_url = "/profile/{user_slug}/wall" def get_initial(self): # Get the initial dictionary from the superclass method initial = super(UserPostCreatView, self).get_initial() user_slug = self.kwargs