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

JavaScript TypeError from a null value, causes tables not to display. #256

Closed
AmuletIndustries opened this issue Mar 23, 2023 · 2 comments
Closed
Labels
bug Something isn't working

Comments

@AmuletIndustries
Copy link

Describe the bug
On some browsers on some machines, when loading any page with a table populated by data from the database, a null value is returned during the table load and a JavaScript Uncaught TypeError occurs. This error occurs in Chrome, Edge, and Firefox on some Win10 machines, but works correctly in Chrome on other Win10 machines. The error occurs in Chrome on Android and iOS, as well as Safari on iOS. On at least one machine the page loads correctly in Chrome but experiences this error in Firefox. Even on browsers where this error occurs, pages which modify the database without displaying it in a table (like part creation, category creation, etc.) work normally and the database is modified as expected. The error occurs regardless of which user is signed in, and the anon user has permissions allowing it to see things that this error breaks.

Importantly: While it seems to be arbitrary if a given browser/machine has this error, the error is persistent on that browser and no amount of restarting or refreshing or changing settings causes that to change.

To Reproduce
Steps to reproduce the behavior:

  • Difficult to reproduce, inconsistent in what machines will/won't work.
  • On machines where this error occurs:
  1. Open browser.
  2. Navigate to Part-DB IP.
  3. Attempt to load any page with a table, such as the See All Parts page, or the contents of any category.
  4. If the error is occurring, the table will be completely empty. Inspecting the browser console for errors will show an Uncaught TypeError: e is null

Expected behavior
The table on a given page should load normally.

Screenshots
All of these screenshots were taken on the same Win10 machine minutes from each other accessing the same page on the same server.

partdb_working_table_chrome_win10
The above image is a screenshot of Chrome showing the Show All Parts table correctly populated.

partdb_broken_table_firefox_win10
The above image is a screenshot of the same page on the same server and the same client Win10 machine but in Firefox. Note the empty table.

partdb_broken_inspect_firefox_win10
The above image is the console output from the inspection, showing the error as well as the offending line in the JS file.

Server Side

  • Part-DB Version: 1.1.0
  • PHP Version: 8.1.16
  • Database Server sqlite 3.34.1

Desktop (please complete the following information):

  • OS: Windows 10 Enterprise 22H2
  • Browser Works in Chrome, Fails in Firefox
  • Chrome: Version 111.0.5563.65 (Official Build) (64-bit)
  • Firefox: Version 102.9.0esr (64-bit)

Smartphone (please complete the following information):

  • Device: Pixel 6 Pro
  • OS: Android 13, Security Update March 5, 2023
  • Browser Chrome (error occurs on this Chrome install)
  • Version 111.0.5563.115
@AmuletIndustries AmuletIndustries added the bug Something isn't working label Mar 23, 2023
@jbtronics
Copy link
Member

This is issue #241. This was already fixed on Version 1.1.1

If this still occurs after you have upgraded to the latest version, feel free to open the issue again.

@AmuletIndustries
Copy link
Author

Ah I thought I had checked through the issues list but I clearly wasn't thorough enough. Updating to the latest version fixes it. Thank you very much.

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