ome / omero-figure

An OMERO.web app for creating Figures from images in OMERO
http://figure.openmicroscopy.org
GNU Affero General Public License v3.0
15 stars 30 forks source link

Django 1.9 #344

Closed will-moore closed 4 years ago

will-moore commented 4 years ago

See parent omero-web PR: https://github.com/ome/omero-web/pull/12

will-moore commented 4 years ago

Currently OMERO.figure on py3-merge https://py3-ci.openmicroscopy.org/web/figure/ is failing because no JS is being generated from source code. Is Grunt missing on that machine? I forget where it's getting installed on merge-ci so I can't check the equivalent spot on py3-ci

will-moore commented 4 years ago

Travis log:

flake8.main.application   MainProcess   1702 INFO     Found a total of 59 violations and reported 1
./omero_figure/views.py:22:1: F401 'unicodedata' imported but unused
will-moore commented 4 years ago

Thanks Josh, Sorry - don't know why I didn't fix that unicodedata after I saw it yesterday.

will-moore commented 4 years ago

Script on idr1-slot2 (py3) with TIFF export of a figure name with unicode characters currently fails with:

  File "./script", line 2148, in save_page
    self.figure_file_name = self.get_figure_file_name()
  File "./script", line 892, in get_figure_file_name
    while(os.path.exists(full_name)):
  File "/home/omero/workspace/OMERO-server/omero-virtualenv/lib64/python3.6/genericpath.py", line 19, in exists
    os.stat(path)
UnicodeEncodeError: 'ascii' codec can't encode character '\xb5' in position 0: ordinal not in range(128)

But there shouldn't be a problem with unicode characters. This works fine on local py37:

>>> fname = "µmµm"
>>> import os
>>> os.path.exists(fname)
False
will-moore commented 4 years ago

However, script is OK for TIFF export if Figure Name doesn't include unicode characters.