sessions lock
See original GitHub issueOriginally reported by: deecodameeko (Bitbucket: deecodameeko, GitHub: @deecodameeko)
I found an issue last night with sessions where it tries to release a lock on a session that isn’t locked.
Here’s a dump of the logs:
#!python
File "/root/.virtualenvs/web_api/lib/python2.7/site-packages/cherrypy/_cprequest.py", line 102, in run
hook()
File "/root/.virtualenvs/web_api/lib/python2.7/site-packages/cherrypy/_cprequest.py", line 62, in __call__
return self.callback(**self.kwargs)
File "/root/.virtualenvs/web_api/lib/python2.7/site-packages/cherrypy/lib/sessions.py", line 706, in close
sess.release_lock()
File "/root/.virtualenvs/web_api/lib/python2.7/site-packages/cherrypy/lib/sessions.py", line 479, in release_lock
os.unlink(path + self.LOCK_SUFFIX)
OSError: [Errno 2] No such file or directory: '/san/in/api-sessions/session-b93639d62bec1e4a766e244d1a22d0bf7ebdc32c.lock'
It seems it doesn’t check if the file exists before unlinking it. Perhaps it should? I’m not sure what could cause this issue in the first place.
Issue Analytics
- State:
- Created 11 years ago
- Comments:6 (3 by maintainers)
Top Results From Across the Web
Finding and killing locked sessions in Oracle
Because of Oracles internal locking, there are times when it is useful to be able to locate and kill Oracle sessions that are...
Read more >Locked Sessions
The Locked Sessions utility is located at Utilities>Session Statistics>Locks button and displays both the Blocking and Current Locked sessions.
Read more >Session locks - MoodleDocs
1 Debugging session lock issues · 2 Session unlocking · 3 Read only session in pages · 4 Read only sessions in web...
Read more >Session lock - ArchWiki
There are numerous utilities to lock the screen of a session. ... There are many ways to lock the session under Xorg, so...
Read more >What is the difference between lock and disconnect session?
For Windows 7 users, "Lock" keeps the last user connected. "Disconnect Session" means a different user can log on (shared computer). Locking the ......
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
It seems like
zc.lockfile
still has this problem. While researching another issue I’ve noticed a mention of another lib at https://stackoverflow.com/a/9993103/595220: https://pypi.org/project/portalocker/ (https://github.com/WoLpH/portalocker). I’d like to try using it instead.Agreed. For now, I just wanted to document the possibility.