Project

General

Profile

Actions

Bug #9742

closed

Error when trying to debug line with "startDate = Time.parse('2014-Apr-01 12:00:30')"

Added by sreesreekanth1 (Sreekanth Simhadri) over 10 years ago. Updated over 10 years ago.

Status:
Third Party's Issue
Assignee:
Target version:
ruby -v:
ruby 1.9.3p545 (2014-02-24) [i386-mingw32]
[ruby-core:<unknown>]

Description

Tried debug and parse string which has date and time to Time using below code

Time.parse('2014-Apr-01 12:00:30')

Actual Result: Script failed with error attached errorLog.txt file which was copied from console

Expected Result: Should return Time without any error


Files

errorLog.txt (10.4 KB) errorLog.txt Error Log when Debugging sreesreekanth1 (Sreekanth Simhadri), 04/14/2014 08:57 PM

Updated by sreesreekanth1 (Sreekanth Simhadri) over 10 years ago

Sreekanth Simhadri wrote:

Tried debug and parse string which has date and time to Time using below code

Time.parse('2014-Apr-01 12:00:30')

Actual Result: Script failed with error attached errorLog.txt file which was copied from console

Expected Result: Should return Time without any error

Resolved the issue by using DateTime.parse('2014-Apr-01 12:00:30').to_time

Updated by avit (Andrew Vit) over 10 years ago

There is a stdlib time with the parse feature which is not included in core. You can do:

require 'time'
Time.parse('2014-Apr-01 12:00:30')

Updated by hsbt (Hiroshi SHIBATA) over 10 years ago

  • Status changed from Open to Closed

Updated by nobu (Nobuyoshi Nakada) over 10 years ago

Ask debugger gem developers.

Updated by usa (Usaku NAKAMURA) over 10 years ago

  • Status changed from Closed to Third Party's Issue
Actions

Also available in: Atom PDF

Like0
Like0Like0Like0Like0Like0