Skip to content
This repository was archived by the owner on Oct 7, 2025. It is now read-only.
This repository was archived by the owner on Oct 7, 2025. It is now read-only.

Import image failure using the Cytomine Python Client API #36

@davidhdh

Description

@davidhdh

Guys

We aim to use the Python client API to interact with Cytomine and mainly the immport image function.
Using the provided python import image file, we 've face some error for which we are not able to troubleshoot

The command line executed is the followinng

On the client side we received this import error

[2021-09-27 15:41:06,831][INFO] [GET] [currentuser] CURRENT USER - 337 : dvo-test | 200 OK
[2021-09-27 15:41:06,848][INFO] [GET] [storage collection] 1 objects | 200 OK
[2021-09-27 15:41:07,478][ERROR] Error during image upload.
False

Looking at the backend server log , we do have an null pointer exception raised during the processing of the request
Below the part of the processing log .

May I ask to explain us how we could troubleshoot this kind of error ?
So far we are still not able to spot the root cause of this error.

Many Thanks

2021-09-27 15:40:23,518 [quartzScheduler_Worker-6] INFO client.HttpClient - Connection to http://core.pdee4.local/api/deletecommand.json?domain=uploadedFile&after=1632584423518&max=0&offset=0
2021-09-27 15:40:23,552 [quartzScheduler_Worker-6] INFO client.Cytomine - 200
2021-09-27 15:41:07,471 [http-bio-8081-exec-12] INFO storage.StorageController - Upload is made on Cytomine = null
2021-09-27 15:41:07,471 [http-bio-8081-exec-12] INFO storage.StorageController - We use e3c09071-c05b-466e-9218-91d12c560da6/5546bb94-269d-4765-b86a-37a4c3b58c45 to connect
2021-09-27 15:41:07,471 [http-bio-8081-exec-12] INFO web.CytomineService - tryAPIAuthentification
2021-09-27 15:41:07,471 [http-bio-8081-exec-12] INFO web.CytomineService - cytomineUrl=null
2021-09-27 15:41:07,471 [http-bio-8081-exec-12] INFO web.CytomineService - ISPubKey=e3c09071-c05b-466e-9218-91d12c560da6
2021-09-27 15:41:07,471 [http-bio-8081-exec-12] INFO web.CytomineService - ISPrivKey=5546bb94-269d-4765-b86a-37a4c3b58c45
2021-09-27 15:41:07,471 [http-bio-8081-exec-12] INFO web.CytomineService - authorization=CYTOMINE f24a8c5f-c3ca-413e-8580-6dc5ab309ec1:SBBQvHjQXi0AgA74Z/kxMsXFRjU=
2021-09-27 15:41:07,471 [http-bio-8081-exec-12] INFO web.CytomineService - host=ims:8081
2021-09-27 15:41:07,471 [http-bio-8081-exec-12] INFO web.CytomineService - connection=close
2021-09-27 15:41:07,471 [http-bio-8081-exec-12] INFO web.CytomineService - content-length=605
2021-09-27 15:41:07,471 [http-bio-8081-exec-12] INFO web.CytomineService - x-request-id=78aab48e537400fd7faf3f9ae072d96c
2021-09-27 15:41:07,471 [http-bio-8081-exec-12] INFO web.CytomineService - x-real-ip=10.64.16.99
2021-09-27 15:41:07,471 [http-bio-8081-exec-12] INFO web.CytomineService - x-forwarded-for=10.64.16.99
2021-09-27 15:41:07,471 [http-bio-8081-exec-12] INFO web.CytomineService - x-forwarded-proto=http
2021-09-27 15:41:07,471 [http-bio-8081-exec-12] INFO web.CytomineService - x-forwarded-host=upload.pdee4.local
2021-09-27 15:41:07,471 [http-bio-8081-exec-12] INFO web.CytomineService - x-forwarded-port=80
2021-09-27 15:41:07,471 [http-bio-8081-exec-12] INFO web.CytomineService - x-scheme=http
2021-09-27 15:41:07,471 [http-bio-8081-exec-12] INFO web.CytomineService - user-agent=python-requests/2.26.0
2021-09-27 15:41:07,471 [http-bio-8081-exec-12] INFO web.CytomineService - accept-encoding=gzip, deflate, br
2021-09-27 15:41:07,471 [http-bio-8081-exec-12] INFO web.CytomineService - accept=application/json, /
2021-09-27 15:41:07,471 [http-bio-8081-exec-12] INFO web.CytomineService - content-type=multipart/form-data; boundary= 8a20d6e9b3f34a6bb9581a3aa054cf3a
2021-09-27 15:41:07,471 [http-bio-8081-exec-12] INFO web.CytomineService - date=Mon, 27 Sep 2021 15:41:06 +0000
2021-09-27 15:41:07,471 [http-bio-8081-exec-12] INFO web.CytomineService - x-requested-with=XMLHTTPRequest
2021-09-27 15:41:07,471 [http-bio-8081-exec-12] INFO web.CytomineService - authorization=CYTOMINE f24a8c5f-c3ca-413e-8580-6dc5ab309ec1:SBBQvHjQXi0AgA74Z/kxMsXFRjU=
2021-09-27 15:41:07,471 [http-bio-8081-exec-12] INFO web.CytomineService - finalDate=Mon, 27 Sep 2021 15:41:06 +0000
2021-09-27 15:41:07,471 [http-bio-8081-exec-12] INFO web.CytomineService - forwardURI=/upload
2021-09-27 15:41:07,471 [http-bio-8081-exec-12] INFO web.CytomineService - content_md5=
2021-09-27 15:41:07,471 [http-bio-8081-exec-12] INFO web.CytomineService - content_type=multipart/form-data; boundary=8a20d6e9b3f34a6bb9581a3aa054cf3a
2021-09-27 15:41:07,471 [http-bio-8081-exec-12] INFO web.CytomineService - date=Mon, 27 Sep 2021 15:41:06 +0000
2021-09-27 15:41:07,471 [http-bio-8081-exec-12] INFO web.CytomineService - queryString=?storage=339&core=http%3A%2F%2Fcore.pdee4.local&sync=False
2021-09-27 15:41:07,471 [http-bio-8081-exec-12] INFO web.CytomineService - path=/upload
2021-09-27 15:41:07,471 [http-bio-8081-exec-12] INFO web.CytomineService - method=POST
2021-09-27 15:41:07,472 [http-bio-8081-exec-12] INFO web.CytomineService - accessKey=f24a8c5f-c3ca-413e-8580-6dc5ab309ec1
2021-09-27 15:41:07,472 [http-bio-8081-exec-12] INFO web.CytomineService - Connection Cytomine: null e3c09071-c05b-466e-9218-91d12c560da6 5546bb94-269d-4765-b86a-37a4c3b58c45
2021-09-27 15:41:07,472 [http-bio-8081-exec-12] INFO web.CytomineService - cytomine.getUser(f24a8c5f-c3ca-413e-8580-6dc5ab309ec1)
2021-09-27 15:41:07,472 [http-bio-8081-exec-12] ERROR storage.StorageController - java.lang.NullPointerException
java.lang.NullPointerException
2021-09-27 15:41:23,517 [quartzScheduler_Worker-7] INFO client.Cytomine - fetchCollection=/api/deletecommand.json?domain=uploadedFile&after=1632584483517&max=0&offset=0
2021-09-27 15:41:23,517 [quartzScheduler_Worker-7] INFO client.HttpClient - Connection to http://core.pdee4.local/api/deletecommand.json?domain=uploadedFile&after=1632584483517&max=0&offset=0
2021-09-27 15:41:23,539 [quartzScheduler_Worker-7] INFO client.Cytomine - 200

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions