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

Earned Leave is not getting calculated for the future months #1102

Closed
1 task done
JitendraSAW opened this issue Nov 24, 2023 · 13 comments
Closed
1 task done

Earned Leave is not getting calculated for the future months #1102

JitendraSAW opened this issue Nov 24, 2023 · 13 comments
Labels
bug Something isn't working

Comments

@JitendraSAW
Copy link

Information about bug

Frappe HR Team

This is to update you on the month of Oct 2023, We have done the Leave Policy Assignment of our Paid leaves where we have "Earned Leave" configuration and have done the settings accordingly, but the same has been added to the Earned Leaves up to 31st October, but the same is not getting added in the Month of November.

image image

We have done the Leave policy Assignment based on the Leave Period and the system also generated the Leave Allocation

image image image

But if you check the system has allocated 10.5 Leave- up to Oct- Up to 7 Months (18/12=1.5 * 7 Months= 10.5 but it is not added for the November Months

Also Is there any option where we can check any background jobs as whether this system generated entry is got created or we can execute manually or any failure notifications.

image

Module

HR, Payroll

Version

image

Installation method

docker

Relevant log output / Stack trace / Full Error Message.

No response

Code of Conduct

  • I agree to follow this project's Code of Conduct
@JitendraSAW JitendraSAW added the bug Something isn't working label Nov 24, 2023
@ruchamahabal
Copy link
Member

what is the annual allocation set in your leave policy for this leave type?

@JitendraSAW
Copy link
Author

Here you can check the screenshot below. Annual Allocation are 18 Days.

image

@ruchamahabal
Copy link
Member

That is not from where earned leaves find the number. Annual allocation is fetched from the Leave Policy

image

When this leave policy is assigned, based on this number the earned leaves are allocated every month

Maximum Leave Allocation Allowed field is used to validate allocation limit and throw an error, not in earned leave auto allocation

@JitendraSAW
Copy link
Author

Yes this is defined already in the system and based on this it has allocated the same-10.5 (18/12) up to Oct 2023 and Nov it is not got added.

image image image

@ruchamahabal
Copy link
Member

ruchamahabal commented Nov 27, 2023

Please raise an issue on support.frappe.io with site details. Will need access to data & background jobs to investigate

@JitendraSAW
Copy link
Author

The site is not Hoisted in a Frappe Cloud.It is a self hoisting site

@ruchamahabal
Copy link
Member

Cannot replicate locally. Check if your scheduler is running and also check Scheduled Job Log list if this scheduled job is failing anywhere.
utils.allocate_earned_leaves

image

@JitendraSAW
Copy link
Author

No Such Schedule Job has run internally as I have verified from the Schedule Job Log List, as I have tried to filter but it is not getting filtered. It means no background job has run.
image

@JitendraSAW
Copy link
Author

Even our Scheduler Job is running and Active
image

@ruchamahabal
Copy link
Member

Check if HR jobs are there in Scheduled Job Type list
image

And if this job is there make sure its not stopped
image

@JitendraSAW
Copy link
Author

There is no scheduled job of HRMS runner on the background

image

@ruchamahabal
Copy link
Member

ruchamahabal commented Nov 27, 2023

Looks like framework did not sync HR jobs for some reason. Run bench migrate for this site from your bench. Jobs should get created after that and it will run every month from now.

We have some UX enhancements for earned leaves in roadmap:

#1104

this will also allow you to manually allocate earned leaves in such cases

@ruchamahabal ruchamahabal closed this as not planned Won't fix, can't repro, duplicate, stale Nov 29, 2023
@JitendraSAW
Copy link
Author

Even after running this Bench Migrate for this site from your bench, Jobs are not getting created and no background earned leave is getting generated every month from now. So what would be the solution for this? Also, can we run the Schedule Type Job of this earned leave by ourselves? Any provision to create this Schedule Job by ourselves

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants