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

Time Tracking Module doesn't stop running unless you manually pause it. #726

Closed
andrewlimaza opened this issue Sep 8, 2020 · 23 comments
Closed

Comments

@andrewlimaza
Copy link
Contributor

Hi there,

I've purchased the Time Tracking module, it seems that the timer will run in the background automatically even when a ticket has been replied to and is in 'pending' status. So some tickets show that it's been hours.

How can I get help resolving this? I'd like to only track time while someone on our team is actively working on the ticket or left that tab open and to stop tracking time when the ticket isn't open.

Freescout version: 1.5.12

Screen Shot 2020-09-08 at 04 44 08

@andrewlimaza andrewlimaza changed the title Time Tracking Module doesn't stop when you reply. Time Tracking Module doesn't stop running unless you manually pause it. Sep 8, 2020
@freescout-helpdesk
Copy link
Owner

User need to close the tab with the conversation to stop the timer.

@andrewlimaza
Copy link
Contributor Author

@freescout-helpdesk if I close Freescout entirely, the time tracking should stop right? Also when I'm not actively viewing a ticket?

Both cases it hasn't, for example: I've replied, went to bed, woke up and then the timer has a few hours on it for a ticket (when a customer has replied).

@freescout-helpdesk
Copy link
Owner

Check background jobs in the Manage >> System.

@andrewlimaza
Copy link
Contributor Author

Thanks, there's no background jobs. I've noticed that if the customer replies the timer starts again. Is there a way to make it only a support engineer/specific set of user's can control the timers?

It should only be the people providing the support

@andrewlimaza
Copy link
Contributor Author

It'd be nice that the timer gets paused once you press reply and the ticket status changes to pending, or when you view another ticket.

@andrewlimaza
Copy link
Contributor Author

Hi any update? This actually threw out our time tracking badly. It says our support agent 'worked' 128 hours in the past week. Because when a customer replies to the email it starts tracking again and it shouldn't do this - it should only track when someone from our team is working on the ticket, right?

@andrewlimaza
Copy link
Contributor Author

It says a customer has spent 4 days on a ticket, which is definitely not the case 👎

@freescout-helpdesk
Copy link
Owner

We can't reproduce the issue on our end.

@andrewlimaza
Copy link
Contributor Author

Does this rely on cron jobs or anything else? Where can I start looking into this/debugging?

@freescout-helpdesk
Copy link
Owner

Yes, timer is stopped by background job. Also check Manage > Logs > App Logs

@andrewlimaza
Copy link
Contributor Author

This is what I have under "Queue Jobs log" - sh: ps: command not found

@freescout-helpdesk
Copy link
Owner

This is the reason. You need to install ps command on your server.

apt-get install -y procps

@freescout-helpdesk
Copy link
Owner

Have you managed to solve the issue?

@andrewlimaza
Copy link
Contributor Author

It does seem better but not 100% there yet. I did a fresh install on Digital Ocean (using cloudron.io) and ensured everything is correct - cron jobs, dependencies etc. (Same domain name, just on a dedicated server now - I was previously on Siteground which didn't allow this to be installed).

I noticed that the timer still runs if you view a 'pending' ticket but don't reply and then stop viewing this ticket.

There are no warnings in the log files.
Screen Shot 2020-09-16 at 13 05 52

@andrewlimaza
Copy link
Contributor Author

I am still running a few more tests but it seems some of the cases, it does pause now.

@Filoz
Copy link
Contributor

Filoz commented Sep 16, 2020

Hi, as reported in #592 , I have the same problem.

I have procps already installed

Note: Queued Jobs logs is empty

@andrewlimaza
Copy link
Contributor Author

I just logged in this morning, this ticket has no reply (but was previously opened yesterday). Closed Freescout from my browser, went to unassigned.

As you can see its 20 hours running idle.

Screen Shot 2020-09-17 at 09 52 45

@freescout-helpdesk
Copy link
Owner

Is System > Status ok?

Nothing in laravel.log?

@andrewlimaza
Copy link
Contributor Author

andrewlimaza commented Sep 17, 2020

SQLSTATE[42S02]:Base table or view not found: 1146 Table '879d7eb1b92127b9.timelogs' doesn't exist (SQL: select * fromtimelogswhereconversation_id= 3 andfinished= 0 limit 1) {"userId":2,"email":"removedthis","exception":"[object] (Illuminate\\Database\\QueryException(code: 42S02): SQLSTATE[42S02]: Base table or view not found: 1146 Table '879d7eb1b92127b9.timelogs' doesn't exist (SQL: select * fromtimelogswhereconversation_id= 3 andfinished` = 0 limit 1) at /app/code/vendor/laravel/framework/src/Illuminate/Database/Connection.php:664, Doctrine\DBAL\Driver\PDOException(code: 42S02): SQLSTATE[42S02]: Base table or view not found: 1146 Table '879d7eb1b92127b9.timelogs' doesn't exist at /app/code/vendor/doctrine/dbal/lib/Doctrine/DBAL/Driver/PDOConnection.php:79, PDOException(code: 42S02): SQLSTATE[42S02]: Base table or view not found: 1146 Table '879d7eb1b92127b9.timelogs' doesn't exist at /app/code/vendor/doctrine/dbal/lib/Doctrine/DBAL/Driver/PDOConnection.php:77)

I removed my email for privacy reasons.

@andrewlimaza
Copy link
Contributor Author

This error was from yesterday, it no longer happens. I think this was when I tried to view the reports for timetracking and there was no data at the time.

@freescout-helpdesk
Copy link
Owner

Can you give access to the droplet to check it? support@freescout.net

@freescout-helpdesk
Copy link
Owner

Closing for no activity.

@freescout-helpdesk
Copy link
Owner

The issue has been fixed in the Time Tracking Module v1.0.4

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

No branches or pull requests

3 participants