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

Fatal Error | Student Report Generation Tool. #44

Closed
abhijitkumbharInd opened this issue Feb 27, 2020 · 1 comment
Closed

Fatal Error | Student Report Generation Tool. #44

abhijitkumbharInd opened this issue Feb 27, 2020 · 1 comment
Labels
bug Something isn't working

Comments

@abhijitkumbharInd
Copy link
Contributor

## Description of the issue

While printing the report card of the Student Report Generation Tool it is giving a Fatal error.

## Steps to reproduce the issue

  1. Open Student Report Generation Tool
  2. Select Student
  3. Select assessment group as 'All Assessment Groups'
  4. Select Academic year and program.
  5. Click on the Print Report Card button.

### Observed result

It is showing a Fatal Error.

Traceback (most recent call last):
  File "/home/indictrans/workspace/v12/frappe-bench/apps/frappe/frappe/app.py", line 60, in application
    response = frappe.api.handle()
  File "/home/indictrans/workspace/v12/frappe-bench/apps/frappe/frappe/api.py", line 55, in handle
    return frappe.handler.handle()
  File "/home/indictrans/workspace/v12/frappe-bench/apps/frappe/frappe/handler.py", line 24, in handle
    data = execute_cmd(cmd)
  File "/home/indictrans/workspace/v12/frappe-bench/apps/frappe/frappe/handler.py", line 63, in execute_cmd
    return frappe.call(method, **frappe.form_dict)
  File "/home/indictrans/workspace/v12/frappe-bench/apps/frappe/frappe/__init__.py", line 1068, in call
    return fn(*args, **newargs)
  File "/home/indictrans/workspace/v12/frappe-bench/apps/erpnext/erpnext/education/doctype/student_report_generation_tool/student_report_generation_tool.py", line 31, in preview_report_card
    values = get_formatted_result(doc, get_course=True, get_all_assessment_groups=doc.include_all_assessment)
  File "/home/indictrans/workspace/v12/frappe-bench/apps/erpnext/erpnext/education/report/course_wise_assessment_report/course_wise_assessment_report.py", line 101, in get_formatted_result
    tuple(args_list), as_dict=1)
  File "/home/indictrans/workspace/v12/frappe-bench/apps/frappe/frappe/database/database.py", line 156, in sql
    self._cursor.execute(query, values)
  File "/home/indictrans/workspace/v12/frappe-bench/env/lib/python3.5/site-packages/pymysql/cursors.py", line 170, in execute
    result = self._query(query)
  File "/home/indictrans/workspace/v12/frappe-bench/env/lib/python3.5/site-packages/pymysql/cursors.py", line 328, in _query
    conn.query(q)
  File "/home/indictrans/workspace/v12/frappe-bench/env/lib/python3.5/site-packages/pymysql/connections.py", line 517, in query
    self._affected_rows = self._read_query_result(unbuffered=unbuffered)
  File "/home/indictrans/workspace/v12/frappe-bench/env/lib/python3.5/site-packages/pymysql/connections.py", line 732, in _read_query_result
    result.read()
  File "/home/indictrans/workspace/v12/frappe-bench/env/lib/python3.5/site-packages/pymysql/connections.py", line 1075, in read
    first_packet = self.connection._read_packet()
  File "/home/indictrans/workspace/v12/frappe-bench/env/lib/python3.5/site-packages/pymysql/connections.py", line 684, in _read_packet
    packet.check_error()
  File "/home/indictrans/workspace/v12/frappe-bench/env/lib/python3.5/site-packages/pymysql/protocol.py", line 220, in check_error
    err.raise_mysql_exception(self._data)
  File "/home/indictrans/workspace/v12/frappe-bench/env/lib/python3.5/site-packages/pymysql/err.py", line 109, in raise_mysql_exception
    raise errorclass(errno, errval)
pymysql.err.ProgrammingError: (1064, "You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near ')  and ar.student in ('EDU-STU-2020-00001')\n\t\tORDER BY\n\t\t\tard.assessment_criteri' at line 8")

**### Expected result
Screen recording
**

By clicking Print Report Card it should generate a report card.

@abhijitkumbharInd abhijitkumbharInd added the bug Something isn't working label Feb 27, 2020
@fderyckel
Copy link
Contributor

As error mentioned, you should not select "all assessment groups" You should select a particular one (aka a child of that parent)

@deepeshgarg007 deepeshgarg007 transferred this issue from frappe/erpnext Oct 24, 2022
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

3 participants