Skip to content

Make shift seeds timezone-aware. #298

@timparenti

Description

@timparenti

After upgrading to Rails 5+, db/seeds.rb should probably use something like Time.zone.strptime() instead of DateTime.strptime() in order to create timestamps which are properly timezone-aware. This should fix the recurring bug over the last few years which has caused the initially-seeded shifts to end up scheduled 4 hours earlier than desired, since DateTime.strptime() ends up interpreting the local timestamps defined in the CSVs as UTC instead.

Also, grep the repo for all instances of Eastern and New_York to find other similar cases.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions