TypeError: instance of IO needed

https://sentry.gitlab.net/gitlab/staginggitlabcom/issues/1099037/

TypeError: instance of IO needed
  active_support/core_ext/marshal.rb:6:in `load'
    super(source, proc)
  active_support/core_ext/marshal.rb:6:in `load'
    super(source, proc)
  active_session.rb:137:in `block in active_session_entries'
    Marshal.load(raw_session) # rubocop:disable Security/MarshalLoad
  active_session.rb:136:in `map'
    entry_keys.map do |raw_session|
  active_session.rb:136:in `active_session_entries'
    entry_keys.map do |raw_session|
...
(136 additional frame(s) were not displayed)

TypeError: instance of IO needed