Export to CSV does not notify the user

Hi everyone, A user is reporting issues when creating a CSV list for downloading. Previous to v7.9.3 the user could perform the process with a notification being presented shortly after for download. After upgrading to V7.9.3 it seems we need to:

  1. Perform the task to create the CSV list
  2. Log out of Specify and back in
  3. Click on the notifications tab and download the CSV list

Any suggesting to what could be wrong?

Hi @wphillip,

I am unable to replicate this in v7.9.3.1. Have you been able to recreate the user’s issue?

Instead of logging out and back in, have you tried navigating elsewhere in Specify after starting the export? It’s possible that the CSV export is taking a while. Logging out and back in may have allowed it time to complete.

Hello,

I updated our instance from v7.9.3 to v7.9.3.1 and was able to recreate the issue on my end.

  1. Log in as a user
  2. Click on Query > Run a query > Click on “Create CSV”
  3. Message pops up “Export File Being Created”
  4. I navigated to Attachments; Statistics and also run another query and the notifications tab did not update.
  5. By changing the Collection on the lower left hand side, causes the page to refresh, and the Notifications tab now reflects the Query exports are completed and ready to download.

I did wait a few minutes between running queries, but only when doing the above or signing out and back in, resulted in the Notifications tab being updated

1 Like

Hi @wphillip,

I believe I may have been able to recreate the issue, although inconsistently.
Can you share your Specify 7 System Information with me so I can try using the same browser and system configuration as you?

Thank you!

Specify 7 System Information - 2024-04-24T13_07_55.615Z.txt (697.9 KB)

Hi there,

Same here. Running just-specify7 docker-compose tag v7.9. Tried with Firefox 130, Microsoft Edge and Duckduckgo Browser on Android mobile phone, all three with same behavior:

  1. Create and run a (small) query
  2. Click on ‘Export to CSV’
  3. Dialog ‘Export File Being Created’
  4. Notification is never triggered, unless I either switch Collection or log out and in again.

Side note: notification time seem to be expressed in UTC because I never get a ‘Now’ tag, always ‘2 hours ago’ and I am on CEST time zone (UTC +2)

Hi @pverley,

I have added your report to the GitHub issue tracking this!

This is because the back-end of Specify does not support time zones (#641), but we are aware of the oddness and do have an open ticket for this as well.

2 Likes

Dear Specify users,
I have a question about extracting data in CSV. Is it possible to select all the Query entries with a single click?
Because selecting them one by one works when there are ten or so entries. For more, you can select the first entry then go to the last, press the shift key and click on the last entry (this allows you to select all the entries in one go). But what do you do when the query returns several thousand entries? It’s a bit tedious, even with the second option of selecting all the entries.
Have I missed a function somewhere?
Thanks in advance for your help

Hi @Marion,

If I understand correctly, you are looking to export all of the returned records from a query into a csv file. If you leave all of the boxes unchecked, and press “Export to CSV” it will include all of the results in the csv file.

Hi @markp,
Thank you for your quick reply and you’ve well understood my problem. In reality, clicking on the ‘create csv’ button without selecting any entries is obviously the first thing I did. But unfortunately nothing happens when I click on ‘create csv’ without selecting any entries. Specify 7 remains stuck on the message ‘A notification will appear when the export file is complete and ready for download’ (I waited more than 5 min before deducing that nothing would happen, and I did the test on 73 entries, so it shouldn’t take that long). On the other hand, if I select some entries, the data is downloaded immediately. That’s why I was wondering if there was a function somewhere, but apparently it’s a problem with Specify 7, perhaps a problem of incompatibility with the browser I’m using? In any case, the problem is the same for several MfN users. We can’t extract a large amount of data without having to spend several minutes selecting all the entries.

Hi @Marion,

Specify handles exports from query results in two different ways depending on how you prepare the export.

  1. The front end of the app handles the export when you select items in the query results by hand and then click ‘Export to CSV’.
  2. The back end of the app handles the export when you do not select any items and click ‘Export to CSV’. This is when you see the “‘A notification will appear when the export file is complete and ready for download” message, and it is supposed to notify you once it is complete.

But unfortunately nothing happens when I click on ‘create csv’ without selecting any entries. Specify 7 remains stuck on the message ‘A notification will appear when the export file is complete and ready for download’

This is a known issue that can happen when the back end export fails to complete and notify the user. In most cases, you can refresh the page and you will see the notification.

On the other hand, if I select some entries, the data is downloaded immediately.

That is because it is done in real-time in the browser on the front end.

We can’t extract a large amount of data without having to spend several minutes selecting all the entries.

I am sorry to hear about the slowdown your team is experiencing! If you are not receiving the notification with a link to your export after refreshing the page, you can still bulk select items in the query results. To do this, select an item in the list, hold the Shift key, and then select another item in the list, regardless of its distance from the start or end.

That’s why I was wondering if there was a function somewhere, but apparently it’s a problem with Specify 7, perhaps a problem of incompatibility with the browser I’m using? In any case, the problem is the same for several MfN users.

We recommend that users use the latest version of Google Chrome when working with Specify. Are you using another browser or any pop-up blocker that may be causing this issue? Do you see the notification after refreshing the page or logging out and back in?

In any case, I have added your report to the issue tracking this on GitHub:

Thank you @Grant for all these details.
Unfortunately nothing happens when I refresh the page either. I’ve installed the latest version of Google Chrome and I’ve also blocked my pop-up blocker for Specify 7 but all this doesn’t change anything.
As for selecting several entries at the same time, I’d already worked it out and I’ve already suggested this ‘solution’ to my colleagues. However, it’s absolutely not a viable solution because when we want to extract several thousand entries, it takes far too long. For some projects, we’re going to have to export several thousand specimens very regularly (at least once a month or more). I can’t imagine spending more than an hour selecting the entries when I should be able to do it in 1 second. I look forward to a solution to this problem.

Hi @Marion,

I logged into your account on a copy of the database and experimented for some time, but I couldn’t recreate the issue. Could you provide an instance when this occurred, including the name of the query, the time, and the user who encountered the problem?

When you or another collections staff member is waiting and not receiving any notifications, please share the Specify 7 System Information at that time!

Hi @Grant,
Thank you for your time. I’ve just realised what I was missing (and it will probably be the same problem for my other colleagues). What I didn’t have was the ‘Notification’ step. I thought it would appear at the top right of my screen (like when you extract a selection of objects). But in fact it’s the “Notification” tab on the left of my screen in the Specify 7 menu. The notification doesn’t appear automatically and I have to reload the page as you suggested above. So I hope my post will be useful one day to someone else like me who sometimes lacks observation :wink:

1 Like

I think this thread is a good place to mention that the behavior at present is confusing, even to users familiar with biodiversity databases. It would probably be prudent to have the exact notification/download behavior configurable in a future release.

I would say “how do I download data, nothing happens when I click the “export” button” is in the top five list of complaints/questions I’ve had since making our database public. A banner notification or direct download dialog would be preferable.

Hi @nfshoobs–

I completely agree that this is a clear opportunity for us to enhance the user experience for all– particularly new users.

The notification can be insufficient and is often overlooked. Do you have any ideal implementation in mind? I can formalize this into a complete feature request if you (and/or others) can describe what interface would work best for you!

Do we have any data for the average and tail of how long it takes the system to return the results of a query? I have requested csv’s for hundreds of thousands of records, and it seems to be ready within 10 seconds. Could a normal progress bar be applied in a popup, similar to the workbench, with the download button available in that interface once the processing is complete?

@Grant I’m glad you think so! I personally think the ideal implementation would be an unignorable prompt – similar to the error window or the normal download dialog in a given browser. The dialog window notifying the user that their download is ready. It could be paired with an upper-right-hand corner dialog window that shows the user their request is still being worked on (even if it wasn’t connected to anything in the backend. Simply having a visual reminder / confirmation that the request was received would go a long way).

I think the current functionality is based in the idea that the user should be able to browse / use the DB while the file is being prepared. But often even I forget that I tried to make an export, only to realize later that it’s sitting in the notification queue. This is especially troublesome for frequently used saved queries that staff use as templates for more specific queries. I can’t find the post, but there’s an error that I read about here where the files for a given query get overwritten in the notification log after someone performs the same query again.

@markp It’s interesting, I have noticed a big variation in the latency between request and file being ready that does not seem to be related to the number of records requested. If I had to guess, I’d say that having multiple users logged in and querying can sometimes impact an individual user’s backend .csv generation time and cause it to time out. It seems that the browser is way faster than the backend, maybe because the results are already loaded? But I’d say the export time for .csv on the backend is not usually close to the time it takes for the query itself to run, at least in the case of large queries. It’s noticeably slower.