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

All bulk changes result in endless "loading" loops #177

Closed
xbln opened this Issue Jan 15, 2018 · 5 comments

Comments

Projects
None yet
2 participants
@xbln

xbln commented Jan 15, 2018

Description of problem

When applying a test-plan bulk change (e. g. status, default tester, category, ...) the system stays in a "loading" loop.

Component (web, API, etc)

web

Version or commit hash (if applicable)

3.49-ee demo site

How often reproducible

permanent

Steps to Reproduce

  1. Make a test plan with some test cases
  2. Apply a bulk change (e. g. bulk change status)

Actual results

loop (but changes were made in the background), no return

Expected results

changes to any of the test cases

bugz1

@atodorov atodorov added the bug label Jan 16, 2018

@atodorov

This comment has been minimized.

Member

atodorov commented Jan 16, 2018

I get an update failed pop-up, not the loading image. Please don't remove or edit this test plan and its test cases before I can figure out what's wrong with it.

@xbln

This comment has been minimized.

xbln commented Jan 16, 2018

I get the same result (loading...) with any testplan on my own kiwi installation.

@atodorov

This comment has been minimized.

Member

atodorov commented Jan 19, 2018

@xbln can you find a traceback for this problem on your installation?

Check if the DEFAULT_PAGE_SIZE setting is an integer number, not a string.

I am able to reproduce is some odd cases and the problem is that page size coming from the filter options is a string, which breaks Kiwi.

atodorov added a commit that referenced this issue Jan 19, 2018

Convert request body to string. Fixes #177
request.body returns bytes, e.g. b'abcd'. This is replaces into the
template as-is and later the JavaScript code works with it, trying
to serialize the search form and any previous search criteria when
doing bulk update actions like changing a TC status!

Because the form serialization operations are home-drown the
existing b' is left and subsequently it breaks elsewhere.

In this particular case this leads to page a page size parameter
posted with value 20' which breaks integer conversion.

The UI serializing forms and posting www-urlform-encoded to the
server is a total mess. We should instead post pure JSON and
receive pure JSON.
@atodorov

This comment has been minimized.

Member

atodorov commented Jan 19, 2018

Nevermind, I figured it out and it's an ugly one :(. Fix is a 1 line though.

@xbln

This comment has been minimized.

xbln commented Jan 19, 2018

Glad to hear you fixed it! I checked that error on the demo site again and I could produce the error with any set of test cases.

@xbln xbln closed this Jan 19, 2018

atodorov added a commit that referenced this issue Jan 19, 2018

Convert request body to string. Fixes #177
request.body returns bytes, e.g. b'abcd'. This is replaces into the
template as-is and later the JavaScript code works with it, trying
to serialize the search form and any previous search criteria when
doing bulk update actions like changing a TC status!

Because the form serialization operations are home-drown the
existing b' is left and subsequently it breaks elsewhere.

In this particular case this leads to page a page size parameter
posted with value 20' which breaks integer conversion.

The UI serializing forms and posting www-urlform-encoded to the
server is a total mess. We should instead post pure JSON and
receive pure JSON.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment