Admin Inline Models Prevent Data From Saving

I have a three table data structure where I have a Main table, Tag table, and TagtoMain table.TagToMain associates Main records with Tag records. There is an FK to Tag and Main.

When I add a Main record, one or more Tag records needs to be added. To make ths possible, I added an Inline Model to my Admin interface. Which worked and I can see Tags under main when adding data.

The problem is, I am getting this when saving from the Inline form and only then - I am able to save data anywhere else is admin,

ConnectionError(<urllib3.connection.HTTPConnection object at 0x7fa044850fa0>: Failed to establish a new connection: [Errno 113] No route to host) caused by: NewConnectionError(<urllib3.connection.HTTPConnection object at 0x7fa044850fa0>: Failed to establish a new connection: [Errno 113] No route to host)

What is strange is, I can add data for any other model. It only happens when I use the Model with the inline Model. So if I take away the Inline Model it works. Or even with the inline model and getting this error, I can still add data for other models no problem / no error.

Why would an inline model be giving me no route to host? But I can still go to TagtoMain by itself, click Add and add data no problem.

This isn’t a general networking issue because it does work. Django can see DB no problem. Its just happening with the inline model form data being added.

class JokeInline(admin.TabularInline):
    model = JokeTag

@admin.register(Joke)
class JokeAdmin(admin.ModelAdmin):
    inlines = [JokeInline]

Thanks.

There should be more to the traceback than what you’re showing here. Please post the complete traceback.

The rest of the traceback was essentially more of that. I got it solved. It was just a few little things. My TagToMain’s def for self was off, and a package was broken and needs upgraded. Since I am not using it, just commented it out. Thanks.