pierrepo / MalariaSmearSearch

Blood smears database for malaria diagnosis :microscope:
GNU General Public License v3.0
1 stars 0 forks source link

Error while uploading 'An error occurred accessing the database' #152

Closed pierrepo closed 7 years ago

pierrepo commented 7 years ago

Starting from a fresh install, I got the following error when I tried to upload a new image:

An error occurred accessing the database

In the console ouput, I also had the following log:

!!!!!!!!!!!!!! <model.Patient object at 0x7f8089e53ef0> chunk_numerotation could not be initialize. num_col and num_row missing [Errno 2] No such file or directory: './samples/2.png' An error occurred accessing the database.

Backtracking the error message chunk_numerotation could not be initialize. num_col and num_row missing leads to line 253 in model.py.

Are the variable self.num_col and self.num_row properly initialized?

Is this could be related to the fact that new_sample.init_on_load() is called twice in the file views.py (line 108 and 124) ?

pierrepo commented 7 years ago

I tried to fix the error. Have a look at the branch fix-error-saving-image-file.