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

JSON - RPC Client Exception #27

Closed
florin-systouch opened this issue Jan 15, 2024 · 6 comments
Closed

JSON - RPC Client Exception #27

florin-systouch opened this issue Jan 15, 2024 · 6 comments

Comments

@florin-systouch
Copy link

On rencontre une exception au moment du récupérer le contenu byte[] d'un rapport en format , qweb-pdf à partir du serveur ODOO
La connexion initiale de la session se passe bien , le report en question il se trouve dans le cache retourné : reportListCache.

Par contre au moment de l'appel de cette ligne de la lib

Object[] result = session.call_report_jsonrpc(getReportModel(), getReportMethod(), reportParams);

On sort directement dans l'exception
at com.googlecode.jsonrpc4j.DefaultExceptionResolver.createJsonRpcClientException(DefaultExceptionResolver.java:53) ~[jsonrpc4j-1.6.jar!/:?]
at com.googlecode.jsonrpc4j.DefaultExceptionResolver.resolveException(DefaultExceptionResolver.java:32) ~[jsonrpc4j-1.6.jar!/:?]
at com.googlecode.jsonrpc4j.JsonRpcClient.handleErrorResponse(JsonRpcClient.java:272) ~[jsonrpc4j-1.6.jar!/:?]
at com.googlecode.jsonrpc4j.JsonRpcClient.readResponse(JsonRpcClient.java:196) ~[jsonrpc4j-1.6.jar!/:?]
at com.googlecode.jsonrpc4j.JsonRpcClient.readResponse(JsonRpcClient.java:539) ~[jsonrpc4j-1.6.jar!/:?]
at com.googlecode.jsonrpc4j.JsonRpcHttpClient.invoke(JsonRpcHttpClient.java:143) ~[jsonrpc4j-1.6.jar!/:?]
at com.googlecode.jsonrpc4j.JsonRpcHttpClient.invoke(JsonRpcHttpClient.java:113) ~[jsonrpc4j-1.6.jar!/:?]
at com.googlecode.jsonrpc4j.JsonRpcHttpClient.invoke(JsonRpcHttpClient.java:175) ~[jsonrpc4j-1.6.jar!/:?]
at com.odoojava.api.Session.call_report_jsonrpc(Session.java:292) ~[odoo-java-api-3.3.2.jar!/:?]
at com.odoojava.api.ReportAdapter.getPDFReportAsByte(ReportAdapter.java:127) ~[odoo-java-api-3.3.2.jar!/:?]

Le URL généré par la session est le suivant : https://srv02.hopodoo.com:443/jsonrpc

@florin-systouch
Copy link
Author

image

@flotho
Copy link

flotho commented Jan 15, 2024

thanks for the report,
Could you confirm that you are using this lib
image

additionnaly, could you provide more information. Is it a specific report, do you use a specific user with or without API Key ?
Thanks for giving feedback.
Regards

@flotho
Copy link

flotho commented Jan 15, 2024

For example ou unit tests succeed in printing "account.report_invoice" whatever the id .

@florin-systouch
Copy link
Author

florin-systouch commented Jan 16, 2024 via email

@flotho
Copy link

flotho commented Jan 16, 2024

hum....
ok, I remember something
you also have to use a patch on your ODoo server because render method is no more available

@flotho
Copy link

flotho commented Jan 16, 2024

Did you try this : #17 (comment)

@flotho flotho closed this as completed Apr 22, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants