Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to logon - goes back to logon screen #8481

Closed
3 of 6 tasks
StormTrooper opened this issue Nov 13, 2024 · 5 comments
Closed
3 of 6 tasks

Unable to logon - goes back to logon screen #8481

StormTrooper opened this issue Nov 13, 2024 · 5 comments
Labels
bug Identifies a bug which needs to be addressed question This is a question

Comments

@StormTrooper
Copy link

StormTrooper commented Nov 13, 2024

Please verify that this bug has NOT been raised before.

  • I checked and didn't find a similar issue

Describe the bug*

When I try and logon I get taken back to the logon screen without any errors. (This is on the old GUI interface)
I know the password is correct as if I enter the wrong password I get the correct response about password being incorrect.

This is happening across multiple machines/multiple browsers. (Latest Chrome and FF on Ubuntu 24.04)

I am however logged into a session from one machine and everything is working (Don't want to logout as I might not be able to get back in)

If I view the user under Admin I can see the last logon time is being updated so it's logging on but then kicking me out.

The issue looks similar to:
#7127

I did try update the settings.py file but this didn't make any difference. I have also updated from 0.16.2 to 0.16.8 a few days ago so not sure if it's related.

Tried clearing cache on browsers, rebooting inventree server. Not sure where to go from here or what logs to check.

Steps to Reproduce

Try and logon to Inventree only to be taken back to the logon screen.

Expected behaviour

Should be able to logon

Deployment Method

  • Docker
  • Package
  • Bare metal
  • Other - added info in Steps to Reproduce

Version Information

Version Information:

InvenTree-Version: 0.16.8
Django Version: 4.2.15

Database: mysql
Debug-Mode: False
Deployed using Docker: False
Platform: Linux-5.4.0-200-generic-x86_64-with-glibc2.31
Installer: None

Active plugins: [{'name': 'InvenTreeBarcode', 'slug': 'inventreebarcode', 'version': '2.1.0'}, {'name': 'InvenTreeCoreNotificationsPlugin', 'slug': 'inventreecorenotificationsplugin', 'version': '1.0.0'}, {'name': 'InvenTreeCurrencyExchange', 'slug': 'inventreecurrencyexchange', 'version': '1.0.0'}, {'name': 'InvenTreeLabel', 'slug': 'inventreelabel', 'version': '1.1.0'}, {'name': 'InvenTreeLabelMachine', 'slug': 'inventreelabelmachine', 'version': '1.0.0'}, {'name': 'InvenTreeLabelSheet', 'slug': 'inventreelabelsheet', 'version': '1.0.0'}, {'name': 'DigiKeyPlugin', 'slug': 'digikeyplugin', 'version': '1.0.0'}, {'name': 'LCSCPlugin', 'slug': 'lcscplugin', 'version': '1.0.0'}, {'name': 'MouserPlugin', 'slug': 'mouserplugin', 'version': '1.0.0'}, {'name': 'TMEPlugin', 'slug': 'tmeplugin', 'version': '1.0.0'}, {'name': 'KiCadLibraryPlugin', 'slug': 'kicad-library-plugin', 'version': '1.4.3'}]

Please verify if you can reproduce this bug on the demo site.

  • I can reproduce this bug on the demo site.

Relevant log output

@StormTrooper StormTrooper added bug Identifies a bug which needs to be addressed question This is a question triage:not-checked Item was not checked by the core team labels Nov 13, 2024
@StormTrooper StormTrooper changed the title Unable to logon - goes bac to logon screen Unable to logon - goes back to logon screen Nov 13, 2024
@StormTrooper
Copy link
Author

Looking through various PRs I came across this:

#8390

For existing installs, the user should adjust the value of "cookie.samesite" (in "config.yaml" settings file) from "none" to "false"

The setting on my install was none. I've changed to false and this has fixed the issue.

Guess this issue only raised it's head as I'm always logged onto the session that was always working and one of the users had not logged in since the upgrade a few days ago.

@matmair matmair removed the triage:not-checked Item was not checked by the core team label Nov 20, 2024
@Mattie112
Copy link

I'll reply here as this seems to be the first issue mentioning this. We also had our InvenTree being broken (we auto-update everything) and this indeed fixes it.

My question however: why was this released as a MINOR version? It breaks all existing setups with the "default" configuration. That is a bit strange to me.

@matmair
Copy link
Member

matmair commented Nov 22, 2024

I do not recommend autoupdating at this point. We are pre 1.0 so as per SemVer there can be and are breaking changes with releases.
Not all default instances are broken, only a certain range. That is why there is no auto-mitigation. There are valid use cases for both settings. Pull requests to improve SRE aspects are always appreciated.

@matmair
Copy link
Member

matmair commented Nov 22, 2024

#7847 Would be a simple first issue

@SchrodingersGat
Copy link
Member

@Mattie112 the breaking change here was to address a bug in our setup which broke other installs.

Apologies for the inconvenience in any case.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Identifies a bug which needs to be addressed question This is a question
Projects
None yet
Development

No branches or pull requests

4 participants