[GH-ISSUE #177] Right-click on performance report errors does not show dialogue with error descriptions #88

Open
opened 2026-03-03 11:58:48 +03:00 by kerem · 2 comments
Owner

Originally created by @HenkKalkwater on GitHub (Feb 16, 2026).
Original GitHub issue: https://github.com/finmars-platform/finmars-core/issues/177

Originally assigned to: @HenkKalkwater on GitHub.

Image

Right clicking right now shows the default context menu of the browser, but it should show the details of the error message instead.

Originally created by @HenkKalkwater on GitHub (Feb 16, 2026). Original GitHub issue: https://github.com/finmars-platform/finmars-core/issues/177 Originally assigned to: @HenkKalkwater on GitHub. <img width="1184" height="579" alt="Image" src="https://github.com/user-attachments/assets/37731abf-cd49-4966-84d8-a663b3fdd9c5" /> Right clicking right now shows the default context menu of the browser, but it should show the details of the error message instead.
Author
Owner

@HenkKalkwater commented on GitHub (Feb 16, 2026):

So it most likely seems to arise from finmars-core, which returns exceptions in a different format if the environment variable DEBUG=True

<!-- gh-comment-id:3908958366 --> @HenkKalkwater commented on GitHub (Feb 16, 2026): So it most likely seems to arise from `finmars-core`, which returns exceptions in a different format if the environment variable `DEBUG=True`
Author
Owner

@HenkKalkwater commented on GitHub (Feb 16, 2026):

The error format when DEBUG=True:

{
	"error": {
		"datetime": "2026-02-16 15:29:52",
		"details": {
			"error_key": "no_first_transaction_date",
			"error_message": "'NoneType' object has no attribute 'transaction_date'",
			"traceback": "  File \"performance_report.py\", line 121, in build_report\n    self.instance.first_transaction_date = self.get_first_transaction()\n                                           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n  File \"performance_report.py\", line 116, in get_first_transaction\n    raise FinmarsBaseException(error_key=\"no_first_transaction_date\", message=str(e)) from e\npoms.common.exceptions.FinmarsBaseException: 'NoneType' object has no attribute 'transaction_date'"
		},
		"message": "Server got itself in trouble",
		"status_code": 500,
		"url": "http://127.0.0.1/realm00000/space00000/api/v1/reports/performance-report/",
		"username": "admin"
	}
}

The error format when DEBUG=False:

{
	"error": {
		"url": "http://127.0.0.1/realm00000/space00000/api/v1/reports/performance-report/",
		"method": "POST",
		"username": "admin",
		"status_code": 500,
		"message": "Server got itself in trouble",
		"datetime": "2026-02-16 14:42:35",
		"details": {
			"type": "server_error",
			"errors": [
				{
					"code": "error",
					"detail": "'NoneType' object has no attribute 'transaction_date'",
					"error_key": "no_first_transaction_date",
					"attr": null
				}
			],
			"traceback": [
				"  File \"performance_report.py\", line 121, in build_report\n    self.instance.first_transaction_date = self.get_first_transaction()\n                                           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n  File \"performance_report.py\", line 116, in get_first_transaction\n    raise FinmarsBaseException(error_key=\"no_first_transaction_date\", message=str(e)) from e\npoms.common.exceptions.FinmarsBaseException: 'NoneType' object has no attribute 'transaction_date'"
			]
		}
	}
}
<!-- gh-comment-id:3909098829 --> @HenkKalkwater commented on GitHub (Feb 16, 2026): The error format when `DEBUG=True`: ```json { "error": { "datetime": "2026-02-16 15:29:52", "details": { "error_key": "no_first_transaction_date", "error_message": "'NoneType' object has no attribute 'transaction_date'", "traceback": " File \"performance_report.py\", line 121, in build_report\n self.instance.first_transaction_date = self.get_first_transaction()\n ^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n File \"performance_report.py\", line 116, in get_first_transaction\n raise FinmarsBaseException(error_key=\"no_first_transaction_date\", message=str(e)) from e\npoms.common.exceptions.FinmarsBaseException: 'NoneType' object has no attribute 'transaction_date'" }, "message": "Server got itself in trouble", "status_code": 500, "url": "http://127.0.0.1/realm00000/space00000/api/v1/reports/performance-report/", "username": "admin" } } ``` The error format when `DEBUG=False`: ```json { "error": { "url": "http://127.0.0.1/realm00000/space00000/api/v1/reports/performance-report/", "method": "POST", "username": "admin", "status_code": 500, "message": "Server got itself in trouble", "datetime": "2026-02-16 14:42:35", "details": { "type": "server_error", "errors": [ { "code": "error", "detail": "'NoneType' object has no attribute 'transaction_date'", "error_key": "no_first_transaction_date", "attr": null } ], "traceback": [ " File \"performance_report.py\", line 121, in build_report\n self.instance.first_transaction_date = self.get_first_transaction()\n ^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n File \"performance_report.py\", line 116, in get_first_transaction\n raise FinmarsBaseException(error_key=\"no_first_transaction_date\", message=str(e)) from e\npoms.common.exceptions.FinmarsBaseException: 'NoneType' object has no attribute 'transaction_date'" ] } } } ```
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/finmars-core#88
No description provided.