Spring Pest Control: Bugs Begone!

YoPrint New Features ReleasedAPRIL

Hey guys, we did a little spring cleaning on a bugs infestation we had and apart from working hard on V2, here’s a quick update on what we’ve been up to these past few weeks!

Bug: Sales Order Create / Edit Page Flickering

You may have encountered a case where you are trying to override the price of an item, and for some reason, the popover keeps closing. We found the culprit! Since we made YoPrint real-time, anytime someone updates an order, the page is silently refreshed for everyone currently logged in. Whenever we do one of this silent update, the popover gets dismissed! This is extra annoying to larger teams with frequent order updates. You’ll be happy to know this annoying bug is now squashed! This should also fix the random scrolling that happens.

Meme 4

Bug: The Disappearance of Customer Brand Profiles

For all the drop shippers out there, if you have ever noticed that the Customer Brand Profiles seem to be missing on the Sales Order Detail Page from time to time, you are not alone! We asked Anbin what was happening, and here is what he said.

“Basically, we are fetching the data from the server but incorrectly discarding the data without storing it locally. Typically we will turn on cache-locally flag and then fetch the data which will indicate data needs to be stored. In this case, we are fetching the data first and then turning on the cache-locally flag which defeats the point.”

We don’t quite get it, but he promised it’s fully fixed now.

pu1 1

Bug: Manual Column Save

We’re not gonna sugarcoat this – our manual column save was a buggy release. We are happy that this is now finally stable and working as expected. Here are some of the issues we fixed.

  • Pinning the column to the right incorrectly pinned it to the left after saving. This has now been fixed.
  • Changing filters may sometimes show different column orders depending on prior actions. This has been standardized and fixed.
  • Column saving and loading logic was not working consistently. So we tossed the old and replaced it with a more robust and deterministic algorithm.

We’re so sorry this took us several tries!

Bug: Calendar Loading Fails Intermittently

This was a doozy to figure out. It doesn’t happen often, which doesn’t help, but after several emails and video calls, we figured out how you trigger it.

1. Go to the Job List Page.

2. Click on Calendar View

3. Before the loading is complete, go to any page. We went to the Customer List Page.

4. Return to the Job List Page and click Calendar View.

5. The calendar will now be broken until you refresh the page.

According to Anbin, “Ahh – It looks like when a user navigates to a different page, we cancel the current API call. When we cancelled the call, we were updating the wrong flags, resulting in all subsequent API calls for Job Calendar being discarded.”

Once again, he promises this is completely fixed now. We really need Anbin to stop raising the flags~!

Bug: Sales Order Concurrent Edit Dialog Issue

For Sales Order Create and Edit, we have a detection mechanism that checks to see if someone else is editing the order. If so, you can either take over the editing or let the other user finish first. If you take over, we will cancel the other user’s “session.” Seems simple enough?

With the new UI, the dialog to make this selection was buried underneath the loading dialog. So there is no way to click it!

pu2

This should be an easy fix, right? Just move the dialog above. According to Anbin, “Ahh… the session detection dialog is written in Angular and the rest of the page is written in React. Simply updating the z-index might break something else. Honestly – I didn’t realize this can happen. I am just going to rewrite the Concurrent Edit Detection in React and surface the correct dialog depending on context. Yup – rewriting it is the only way.”

The software truly works in mysterious ways!

Quality of Life: The Tab Order for New Customer Dialog

When creating a new customer, pressing the Tab key to navigate the fields goes like this.

  1. First Name
  2. Email
  3. Fax
  4. Last Name
  5. Phone

The correct order should be

  1. First Name
  2. Last Name
  3. Email
  4. Phone
  5. Fax
pu3 1

This is something no one complained about, but Anbin went ahead and fixed it anyway. Anbin should get a hobby.

Bug: Tiny Mockup Preview Dialog

Meme 3

The picture says it all. Our Mockup Preview dialog was so small that it wasn’t much of a preview. Here is the fixed version.

pu5

Bug: Jason and the Case of Vanishing Inventory

Up until now, we’ve only seen bugs from Anbin and the frontend team. Here is one from Jason and the backend gang.

The inventory list page will show blank occasionally, only to magically appear the next day.

pu6

According to Jason:

  1. If there are frequent inventory updates, which is especially true for larger teams, the update will sometimes fail due to a conflict and throw the inventory out. We’ve added retry logic to fix it.
  2. We also go through our database and reindex our search engine at midnight to ensure the data is current and any inconsistencies are fixed. So, there was no magic involved.
  3. We’ve added a new monitor that periodically checks the search engine and reindexes as necessary. This is fail-safe logic; we don’t expect it to run. Yes – we write code and fully expecting it to never run.
  4. We also noticed that anytime an address changes, the incremental reindex omits a flag that is critical for the search query to work. Therefore, even though the data was in the search engine, the search results were returning empty. This is the real reason why the inventory vanished, and the rest are just fail-safes we’ve implemented, just in case.

It looks like both founders have a way with words. For us non-technical folks, the underlying issue of the vanishing inventory has been addressed, and it should work as expected now. If you find it otherwise please let us know!

Experimental: PDF Upload for Artwork/Mockups

We’re also rolling out experimental support for uploading PDFs for Mockup Uploads. We need the Mockups to be in an image format (PNG, JPG, tiff, gif) so that we can render them on the app and print them on the PDFs. While rendering PDFs on the app is possible, rendering a PDF inside a PDF is a non-starter.

Your only option is to export the PDFs as images and upload them into YoPrint. With the experimental PDF Upload support, when you upload the PDFs, we will convert them to images and upload them for you, essentially skipping a step.

This is only available on the Job List Page, but we will roll it out app-wide when we fully release the V2. Here is a working Preview.

Untitled 4

Editor Notes

“If debugging is the process of removing software bugs, then programming must be the process of adding them”—Edsger W. Dijkstra.

We recommend that the frontend team code less, but Anbin has politely but firmly declined. We tried!

That wraps up this update! We wanted to give you some insight into what goes into identifying, reproducing, and fixing bugs at YoPrint, as well as into the technical details and a little behind-the-scenes process of fixing bugs.

Now, if you’re wondering what’s up with V2, there’s a quick update from our resident streamer, Anbin, who will walk you through it himself. Watch the full video here.

(We suspect that he’s enjoying this too much and might try vlogging professionally soon)