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

fix quarter precision with one month has 31 days #27

Closed
wants to merge 1 commit into from

Conversation

icoreman
Copy link

Issue link: #26
Fix way: reverse loop i.e from last (len-1) segment to first (0) segment in here)

@icoreman icoreman requested a review from adhocore as a code owner May 21, 2023 01:44
@adhocore
Copy link
Owner

thank you for PR. for some reason this has caused infinite loop in my local 💫 😵 and it seems same happen in actions too https://github.com/adhocore/gronx/actions/runs/5035233909

@icoreman
Copy link
Author

thank you for PR. for some reason this has caused infinite loop in my local 💫 😵 and it seems same happen in actions too https://github.com/adhocore/gronx/actions/runs/5035233909

I don't think we can fix the last day of qurater issue by the simple change...

@@ -46,7 +46,8 @@ func loop(gron Gronx, segments []string, start time.Time, incl bool, reverse boo
for iter > 0 {
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

over:
    for iter > 0 {
        iter--

@icoreman infinite loop can be prevented by moving over label outside loop

@adhocore
Copy link
Owner

closing as the scope quickly escalates if we attempt to merge this

@adhocore adhocore closed this Jul 20, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants