Bug 1182545
Summary: | Internal error when searching systems added to Beaker after/before/at date | ||
---|---|---|---|
Product: | [Retired] Beaker | Reporter: | Jan Stodola <jstodola> |
Component: | web UI | Assignee: | matt jia <mjia> |
Status: | CLOSED CURRENTRELEASE | QA Contact: | tools-bugs <tools-bugs> |
Severity: | medium | Docs Contact: | |
Priority: | medium | ||
Version: | 19 | CC: | aigao, asaha, dcallagh, dowang, mjia |
Target Milestone: | 19.3 | Keywords: | Patch, Regression |
Target Release: | --- | ||
Hardware: | Unspecified | ||
OS: | Unspecified | ||
Whiteboard: | |||
Fixed In Version: | Doc Type: | Bug Fix | |
Doc Text: | Story Points: | --- | |
Clone Of: | Environment: | ||
Last Closed: | 2015-03-17 06:34:22 UTC | Type: | Bug |
Regression: | --- | Mount Type: | --- |
Documentation: | --- | CRM: | |
Verified Versions: | Category: | --- | |
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
Cloudforms Team: | --- | Target Upstream Version: | |
Embargoed: |
Description
Jan Stodola
2015-01-15 12:23:18 UTC
Traceback: Jan 15 12:34:27 beaker-devel beaker-server[27696]: File "/usr/lib/python2.6/site-packages/bkr/server/controllers.py", line 399, in _system_search Jan 15 12:34:27 beaker-devel beaker-server[27696]: sys_search.append_results(cls_ref,search['value'],col,search['operation']) Jan 15 12:34:27 beaker-devel beaker-server[27696]: File "/usr/lib/python2.6/site-packages/bkr/server/search_utility.py", line 790, in append_results Jan 15 12:34:27 beaker-devel beaker-server[27696]: self.queri = self.queri.filter(filter_final()) Jan 15 12:34:27 beaker-devel beaker-server[27696]: File "/usr/lib/python2.6/site-packages/bkr/server/search_utility.py", line 777, in <lambda> Jan 15 12:34:27 beaker-devel beaker-server[27696]: filter_final = lambda: filter_func(mycolumn.column,value) Jan 15 12:34:27 beaker-devel beaker-server[27696]: File "/usr/lib/python2.6/site-packages/bkr/server/search_utility.py", line 1094, in added_after_filter Jan 15 12:34:27 beaker-devel beaker-server[27696]: date = datetime.datetime.strptime(val, '%Y-%m-%d') Jan 15 12:34:27 beaker-devel beaker-server[27696]: File "/usr/lib64/python2.6/_strptime.py", line 325, in _strptime Jan 15 12:34:27 beaker-devel beaker-server[27696]: (data_string, format)) Jan 15 12:34:27 beaker-devel beaker-server[27696]: ValueError: time data '01/07/2015' does not match format '%Y-%m-%d' When the date is selected from the calendar on the search page, it comes as mm-dd-yy On gerrit: http://gerrit.beaker-project.org/#/c/3954/ Matt Jia Steps to Verify: 1. Go to systems page and click on "Show Search Options" 2. Select Table: System/Added 3. Select Operation: after/before/is 4. Type Value: select any date from data picker 5. Click Search and the results should be shown in the table grid. Cheers, Matt Jia (In reply to wangdong from comment #5) > BTW. > > If I given a invalid data value it will return "500 internal server error" > > is this need fix? > > I think we should add restrict about data Value, it should only input valid > data for "Value" > > Please investigate it. Yeah, this is an existing bug in the system search bar. I have uploaded a patch to fix this. http://gerrit.beaker-project.org/#/c/3974/ Cheers, Matt Jia Setting back to ASSIGNED as per comment 5/6, once that patch is merged this can go back to ON_QA. (In reply to wangdong from comment #5) > If I given a invalid data value it will return "500 internal server error" > > is this need fix? > > I think we should add restrict about data Value, it should only input valid > data for "Value" > > Please investigate it. Verify Steps: 1.Go to systems page and click on "Show Search Options" 2. Select Table: System/Added 3. Select Operation: after/before/is 4. Type an invalid date 5. the input box should become red to indicate the value is invalid 6. Click Search button and you will notice that the input value is restored to default current date which is today. 7. Type an invalid date again, make sure the date picker is closed by using ESC when doing this. 8. click Search button and you should see the error message and the form is not submmited. Cheers, Matt Jia Beaker 19.3 has been released. |