Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

undefined method `to_local' for #<TZInfo::DataTimezone: America/New_York> #84

Closed
HCLarsen opened this issue Apr 3, 2018 · 6 comments
Closed
Labels

Comments

@HCLarsen
Copy link

@HCLarsen HCLarsen commented Apr 3, 2018

Despite your code showing a to_local method, and your README showing how to use it, it seems impossible to call this method on a TimeZone object.

@philr
Copy link
Member

@philr philr commented Apr 3, 2018

It sounds like you're probably running the latest gem release, but reading the code and README file on the master branch.

The master branch contains changes that have not yet been released. One of these changes was the addition of a to_local method to TZInfo::Timezone.

The code and README for the latest gem release can be found in git tagged as v1.2.5. The documentation for this release is available on RubyDoc.info.

@philr philr added the invalid label Apr 3, 2018
@philr philr closed this Apr 3, 2018
@HCLarsen
Copy link
Author

@HCLarsen HCLarsen commented Apr 4, 2018

Problem with that is that the documentation on RubyDoc.info is incomplete. It contains no listing for the TZInfo::DataTimezone class.

@philr
Copy link
Member

@philr philr commented Apr 4, 2018

The issue with TZInfo::DataTimezone being omitted from the documentation has already been resolved in master. This class will be included in the documentation for the upcoming v2.0.0 release.

The TZInfo::DataTimezone class extends from TZInfo::Timezone via TZInfo::InfoTimezone. In version 1.2.5, it provides implementations for the 'abstract' identifier, period_for_utc, periods_for_local, transitions_up_to and canonical_zone methods. These methods are all defined and documented in the TZInfo::Timezone class.

@HCLarsen
Copy link
Author

@HCLarsen HCLarsen commented Apr 5, 2018

Good to know. Thank you.

@AlexWayfer
Copy link

@AlexWayfer AlexWayfer commented Dec 17, 2018

584 commits to master since this release

Is there a new release planned?

@philr
Copy link
Member

@philr philr commented Dec 17, 2018

Yes, there will be a 2.0.0 release from master sometime soon.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
3 participants