question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Remove client state

See original GitHub issue

Reading ‘Lightweight Django’ chapter 4 ‘Building a REST API’ It suggest removing ‘django.contrib.sessions.middleware.SessionMiddleware’ as ’ the server will not maintain any client state’ Sounds reasonable don’t you think? As ‘django.contrib.sessions.middleware.SessionMiddleware’ is removed, also middleware and apps dependant on this needs to be removed:

django.contrib.auth.middleware.AuthenticationMiddleware,
django.contrib.auth.middleware.SessionAuthenticationMiddleware, and
django.contrib.messages.middleware.MessageMiddleware

And django.contrib.admin, django.contrib.sessions, django.contrib.messages apps

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Comments:7 (1 by maintainers)

github_iconTop GitHub Comments

1reaction
spoetnikcommented, Feb 12, 2017

I can add the admin (and thus session, etc) to local settings? My doubt is that local and production vary to much, so “it works on my computer” doesn’t mean anything… Maybe make a ‘backoffice’ settings or something, and add the admin to that?

0reactions
agconticommented, Jan 14, 2020

@spoetnik thanks for your enthusiasm and contribution!

I’m going to close this issue based on this project’s core values:

The idea behind this project is to have the slimmest possible boilerplate while maximizing developer productivity from the get-go. [This] isn’t something that I think the project should support out of the box because it’s a specific use case. While many will find it useful, many others won’t have a need for it.

If this is something that you’d like to maintain yourself – I encourage you to fork the project!

Removing session storage as you’ve outlined adds additional complexity to settings configuration. While some users, like yourself, will want to remove session storage so that there’s no chance they violate RESTful guidelines. Most users will be content to just not use session storage or would like the option to violate RESTful guidelines with session storage when they think its best for their project.

You seem very passionate about this so please fork the project and customize it your own liking!

Read more comments on GitHub >

github_iconTop Results From Across the Web

Remove client state creation restrictions - Paradox Forum
"Client states can be created from core or non-core provinces that have a direct land ... Remove client state creation restrictions.
Read more >
Dear Paradox, please consider removing this nonsensical ...
Removing the client state restrictions would unbalance the competitiveness of the game by making it way to easy to conquer and hold ...
Read more >
Deleting a state/city return for a client - CS Professional Suite
In the Client Properties dialog, click the state's tab. Click the Delete State button. UltraTax CS prompts you to confirm that you want...
Read more >
Client state - Wikipedia
A client state, in international relations, is a state that is economically, politically, and/or militarily subordinate to another more powerful state ...
Read more >
Adding or removing a state return from a client file in Lacerte
Select Yes to remove the state. Back to Table of Contents PCG_ASSET_spacer_11px.png. Why am I unable to delete a state from Lacerte client?...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found