Skip to content

GitLab

  • Projects
  • Groups
  • Snippets
  • Help
    • Loading...
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in
Trac
Trac
  • Project overview
    • Project overview
    • Details
    • Activity
  • Issues 246
    • Issues 246
    • List
    • Boards
    • Labels
    • Service Desk
    • Milestones
  • Operations
    • Operations
    • Metrics
    • Incidents
  • Analytics
    • Analytics
    • Value Stream
  • Wiki
    • Wiki
  • Members
    • Members
  • Collapse sidebar
  • Activity
  • Create a new issue
  • Issue Boards

GitLab is used only for code review, issue tracking and project management. Canonical locations for source code are still https://gitweb.torproject.org/ https://git.torproject.org/ and git-rw.torproject.org.

  • Legacy
  • TracTrac
  • Issues
  • #33360

Closed (moved)
Open
Opened Feb 18, 2020 by Karsten Loesing@karsten

IntegerDistribution breaks when given negative values

As found in #27981 (moved), our unit tests fail when being run in 1990.

The reason is that we're using a hard-coded time for sending the request (2013-04-24 12:22:22) and the current system time for determining when we handled the request. We compute the difference of the two timestamps as the time needed for handling the request. But IntegerDistribution does not accept negative values.

That's a bug. It should either reject negative values in its addLong method, or it should store them and include them in the result. I'd prefer the second variant, even though we're not using it for negative values under normal circumstances.

Not blocking the upcoming 8.0 protocol update.

To upload designs, you'll need to enable LFS and have admin enable hashed storage. More information
Assignee
Assign to
None
Milestone
None
Assign milestone
Time tracking
None
Due date
None
Reference: legacy/trac#33360