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

Mass creation of categories fails weirdly if a categoruy already exists #543

Closed
nomike opened this issue Mar 5, 2024 · 1 comment
Closed
Labels
bug Something isn't working

Comments

@nomike
Copy link

nomike commented Mar 5, 2024

Describe the bug
If I'm trying to mass create a category where one of the parents already exists, an error occurs in a weird way which doesn´t go away until you refresh the browser.

To Reproduce
Steps to reproduce the behavior:

  1. Go to 'Edit' → 'Categories'
  2. Click on 'New Element'
  3. Go to the 'Mass creation' tab
  4. Enter the following text to create new categories:
Prototyping, Fabrication Products
  Solderless Breadboards
  1. Click on "Create"
  2. Click on 'New Element' again.
  3. Enter the following:
Prototyping, Fabrication Products
  Jumper Wire
  1. Click on "Create"

Actual behavior
Instead of the behavior mentioned above an error is thrown and a HTTP/500 is shown in the background of the page, behind all other controls and forms.

The page looked like this, directly before clicking "Create" in step 8.:

image

And looks like this immediately after clicking:

image

Some text is white on white background which can be revealed by selecting it:

image

This error doesn't go away regardless of where you browse to in Part-DB. Only a browser refresh gets rid of it.

Expected behavior
I would expect Part-DB to create a new category named 'Jumper Wire" which is a descendant of the already existing category named "Prototyping, Fabrication Products". As this category already exists, it should be silently ignored.

If all categories specified already exist, I would also expect this to be silently ignored.

What I as a user want is for the specified categories to exist once I've clicked "Create", whether they already existed before that, I don´t care.

And even if this is not an option, if should at least show a user-friendly error message.

Screenshots
See above.

Server Side

  • Part-DB Version: v.11.1.1
  • PHP Version: 8.2.7
  • Database Server: sqlit 3.40.1

Desktop (please complete the following information):

  • OS: Ubuntu 23.10
  • Browser: Firefox
  • Version: 123.0 (64-bit)
@nomike nomike added the bug Something isn't working label Mar 5, 2024
jbtronics added a commit that referenced this issue Mar 9, 2024
@jbtronics
Copy link
Member

This should be fixed with the latest commit.

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