Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 6 additions & 4 deletions .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,12 +11,14 @@ Addresses issue # .


**Checklist:**
The below is a list of things what will be considered when reviewing PRs. It is not prescriptive, and does not
imply that PRs which touch any of these will be rejected but gives a rough indication of where there is a potential
for hangups (i.e. factors which could turn a 5 min review into a half hour or longer and shunt it to the bottom
of the TODO list).

- [ ] Tested with numpy=1.14
- [ ] Tested on python 2.7 and 3.6
- [ ] Tested with wx=3.x and wx=4.x [if UI code]
- [ ] Does the PR avoid variable renaming in existing code, whitespace changes, and other forms of tidying? [There is a place for code tidying, but it makes reviewing
much simpler if this is kept separate from functional changes]
much simpler if this is kept separate from functional changes. The auto-formatting performed by some editors is particulaly egregious and can lead to files with thousands
of non-functional changes with a few functional changes scattered amoungst them]

If an enhancement (or non-trivial bugfix):

Expand Down
9 changes: 9 additions & 0 deletions PYME/LMVis/renderers.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,9 @@
#import pylab
import numpy as np

import logging
logger = logging.getLogger(__name__)

renderMetadataProviders = []

SAMPLE_MD_KEYS = [
Expand Down Expand Up @@ -272,6 +275,12 @@ def Generate(self, settings):
# for recipe usage, if provided with 'all', replace colour list with a list of all available channels
colours = self.colourFilter.getColourChans()

if len(colours) == 0:
# hack to make this do something sane / backwards compatible
# when colour info is missing (see comment on #1305)
logger.warning("Renderer called with colours=['all',] but datasource has no colour information. Most likely the result of a missing ProcessColour module.")
colours=[None,]

oldC = self.colourFilter.currentColour

ims = []
Expand Down