Edgewall Software
Modify

Opened 17 years ago

Last modified 9 years ago

#6515 new defect

Trac detected an internal error: Session ID not set

Reported by: franz.x.maier@… Owned by:
Priority: normal Milestone: next-major-releases
Component: general Version:
Severity: normal Keywords:
Cc: alexandre.rossi@…, Thijs Triemstra Branch:
Release Notes:
API Changes:
Internal Changes:

Description (last modified by Remy Blank)

Oops… Trac detected an internal error:

If you think this really should work and you can reproduce it, you should consider reporting this problem to the Trac team.

Go to http://trac.edgewall.org/ and create a new ticket where you describe the problem, how to reproduce it. Don't forget to include the Python traceback found below.

TracGuide — The Trac User and Administration Guide Python Traceback

Traceback (most recent call last):
  File "/usr/local/lib/python2.5/site-packages/trac/web/main.py", line 406, in dispatch_request
    dispatcher.dispatch(req)
  File "/usr/local/lib/python2.5/site-packages/trac/web/main.py", line 184, in dispatch
    req.session = Session(self.env, req)
  File "/usr/local/lib/python2.5/site-packages/trac/web/session.py", line 48, in __init__
    self.get_session(sid)
  File "/usr/local/lib/python2.5/site-packages/trac/web/session.py", line 90, in get_session
    self.bake_cookie()
  File "/usr/local/lib/python2.5/site-packages/trac/web/session.py", line 56, in bake_cookie
    assert self.sid, 'Session ID not set'
AssertionError: Session ID not set

Attachments (0)

Change History (17)

comment:1 by Alec Thomas, 17 years ago

Description: modified (diff)

comment:2 by ThurnerRupert, 17 years ago

Keywords: needinfo added

could you pls shed some light on:

  • your client pc:
    • what did you try to do
    • what operating system did you use
    • what browser with what cookie settings?
  • the server:
    • which url
    • which trac version

comment:3 by franz.x.maier@…, 17 years ago

I tried to retrieve the following url:

http://www.boxbackup.org/trac/wiki

I use Windows XP with all actual fixes and used Firefox and IE - same results! I even couldn't go to your homepage as indicated in the description (using the link) and report the error - also got this error! Strange thing: it now works in Linux (Suse 10.3) with Firefox - everything ok there! Cookie settings: defaults in all systems and browsers.

comment:4 by sid, 17 years ago

Above URL works fine for me on Mac with Firefox. Sounds like a browser configuration problem to me.

comment:5 by apalero@…, 17 years ago

Component: generaltrac-admin
Owner: changed from Jonas Borgström to anonymous
Priority: normalhighest
Status: newassigned

Templates directory usr/local/share/trac/templates>

Creating and Initializing Project
Failed to create environment. You can only execute one statement at a time.
Traceback (most recent call last):
  File "/usr/local/lib/python2.4/site-packages/trac/scripts/admin.py", line 613, in do_initenv
    options=options)
  File "/usr/local/lib/python2.4/site-packages/trac/env.py", line 145, in __init__
    self.create(options)
  File "/usr/local/lib/python2.4/site-packages/trac/env.py", line 250, in create
    DatabaseManager(self).init_db()
  File "/usr/local/lib/python2.4/site-packages/trac/db/api.py", line 70, in init_db
    connector.init_db(**args)
  File "/usr/local/lib/python2.4/site-packages/trac/db/sqlite_backend.py", line 126, in init_db
    cursor.execute(stmt)
Warning: You can only execute one statement at a time.
Failed to initialize environment. 1
Traceback (most recent call last):
  File "/usr/local/lib/python2.4/site-packages/trac/scripts/admin.py", line 617, in do_initenv
    sys.exit(1)
SystemExit: 1
Last edited 9 years ago by Ryan J Ollos (previous) (diff)

comment:6 by hyuga <hyugaricdeau@…>, 17 years ago

Component: trac-admingeneral
Owner: changed from anonymous to Jonas Borgström
Priority: highestnormal
Status: assignednew

What does this traceback have to do with this ticket? Also, please don't mess with assignments, etc.

comment:7 by apalero@…, 17 years ago

im using Centos 4.1,after execute this command (trac-admin /home/user/trac-env/ initenv) and set the right path for svn and repositories then set the Templates directory /usr/local/share/trac/templates> after i set this error appear in my terminal.. please help me..

    File "/usr/local/lib/python2.4/site-packages/trac/scripts/admin.py", line 613, in do_initenv

        options=options)

    File "/usr/local/lib/python2.4/site-packages/trac/env.py", line 145, in init

        self.create(options)

    File "/usr/local/lib/python2.4/site-packages/trac/env.py", line 250, in create

        DatabaseManager?(self).init_db()

    File "/usr/local/lib/python2.4/site-packages/trac/db/api.py", line 70, in init_db

        connector.init_db(**args)

    File "/usr/local/lib/python2.4/site-packages/trac/db/sqlite_backend.py", line 126, in init_db

        cursor.execute(stmt)
Last edited 9 years ago by Ryan J Ollos (previous) (diff)

comment:8 by alexandre.rossi@…, 16 years ago

This (the "Session ID is not set" error, I do not know about the rest) triggered exactly when work admins installed a crappy anti spyware thingy on the WinXP box. Seems that the thing regularly cleans out cookies in some way. I think this is related to this error.

Please note that I'm anonymous, req.incookie.has_key(COOKIE_KEY) seems True.

The trac cookie is empty (empty string contents) and if I delete it, the error does not trigger anymore for one day.

comment:9 by alexandre.rossi@…, 16 years ago

Cc: alexandre.rossi@… added

comment:10 by anonymous, 16 years ago

Resolution: fixed
Status: newclosed

comment:11 by anonymous, 16 years ago

Resolution: fixed
Status: closedreopened

in reply to:  8 comment:12 by Remy Blank, 16 years ago

Description: modified (diff)
Keywords: needinfo removed
Resolution: wontfix
Status: reopenedclosed

Replying to alexandre.rossi@…:

This (the "Session ID is not set" error, I do not know about the rest) triggered exactly when work admins installed a crappy anti spyware thingy on the WinXP box. Seems that the thing regularly cleans out cookies in some way. I think this is related to this error.

This sounds very likely indeed. Not an InstallationIssue, but same conclusion. Please fix your client environment.

comment:13 by alexandre.rossi@…, 16 years ago

My opinion is that Trac should not fail for anonymous users if :

  • they come back to the website after more than one day
  • something's messing up cookies on the client side.

I think that when users are anonymous and cookie information is not good, it should simply be discarded.

in reply to:  13 comment:14 by Remy Blank, 16 years ago

Resolution: wontfix
Status: closedreopened

Replying to alexandre.rossi@…:

I think that when users are anonymous and cookie information is not good, it should simply be discarded.

Yes, that does make sense. It will "hide" the real problem from the user, though, so their settings will get lost every time, but maybe that's acceptable.

comment:15 by Remy Blank, 16 years ago

Milestone: 0.13
Owner: changed from Jonas Borgström to Remy Blank
Status: reopenednew

comment:16 by Thijs Triemstra, 13 years ago

Cc: Thijs Triemstra added
Summary: Trac detected an internal errorTrac detected an internal error: Session ID not set

comment:17 by Remy Blank, 13 years ago

Owner: Remy Blank removed

Refocusing.

Modify Ticket

Change Properties
Set your email in Preferences
Action
as new The ticket will remain with no owner.
The ticket will be disowned.
as The resolution will be set. Next status will be 'closed'.
The owner will be changed from (none) to anonymous. Next status will be 'assigned'.

Add Comment


E-mail address and name can be saved in the Preferences .
 
Note: See TracTickets for help on using tickets.