Como colocar links de redes sociais para compartilhar o link da pagina de um post?

Question: Eu estou com uma dúvida. Eu não entendo muito de ASP.Net, porém um amigo meu pediu uma ajuda pra implementar uns botões de rede social no site de TCC dele. O TCC dele é um portal de notícias, como qualquer outro.
Ele gostaria de colocar, em cada página de post algo do tipo:

Juntamente com o botãozinho do WhatsApp.
O intuito é compartilhar cada pagina de post, ou seja, tem postagem x, eles compartilham o link x, e na postagem y, eles compartilham o link y da postagem y.
Obrigado desde já!!
Comment: Em cada post individualmente? ou em lista?
Comment: Em cada post individualmente!
Answer: Cada rede social funciona de uma forma diferente. No caso do Twitter, você pode usar algo como esse código javascript:

Tweet

basta substituir os valores dos parâmetros 'data-url' pelo link da notícia, 'data-via' pelo perfil do twitter referente ao site, data-related pelo perfil a ser indicado (para que outras pessoas o sigam) e 'data-hashtags' pelas hashtags (se houver)


Miranda's Proposition 1.11 pag. 63

Question: Let $X$ and $Y$ be two complex tori given by lattices $L$ and $M$ respectively. Then any holomorphic map $F: X \mapsto Y$ is induced by a linear map $G: \mathbb{C} \mapsto \mathbb{C}$ of the form $G(z)=\gamma z + a$ where $\gamma$ is a constant such that $\gamma L \subset M$. The constant $a$ may be taken to be zero if and only if $F$ sends $0$ to $0$; in this case the map $F$ is a homomorphism of groups. The holomorphic map $F$ is an isomorphism if and only if $\gamma L=M$. In general, the degree of $F$ is the index $|M/\gamma L|$ of $\gamma L$ inside $M$.
In order to proof this last statement, I consider the commutative diagram
$$\require{AMScd}
\begin{CD}
\mathbb{C} @>G>> \mathbb{C} \\
@V{\pi}VV @VV{\pi}V \\
X@>>F> Y \\
\end{CD} \\
$$
and I study $F^{-1}(z+M)$. Now I note that $F^{-1}=\pi \circ G^{-1} \circ \pi^{-1}$. After some calculation I obtain $F^{-1}(z+M)=z+\gamma L$ or $F^{-1}(z+M)=z+L$. But I don't obtain the result of my thesis. What's wrong?
Comment: It seems that for commutative diagram to render you need to add '\require{AMScd}'. See [meta](http://meta.math.stackexchange.com/questions/2324/how-to-draw-a-commutative-diagram).
Answer: The problem is that $F$ isn't invertible, so you have to be careful with all thos $-1$'s you wrote. It is easy to see that $\deg F=|\ker F|$, and
$$\ker F=\{z+L\in \mathbb{C}/L:\gamma z+M=0\}=\{z\in\mathbb{C}:\gamma z\in M\}\mbox{ mod }L=(\frac{1}{\gamma}M)/L\simeq M/\gamma L.$$
Taking the order of this group gives you what you want.

Miranda's Proposition 1.11 pag. 63


for $p>0$, when does this integration:$\int_0^{\infty} x^pe^{-x^8\sin^2x}dx$ converge?

Question: for $p>0$,find the value range of $p$, which makes this integration: $\displaystyle\int_0^{\infty} x^pe^{-x^8\sin^2x}dx$ converge.
I tried to divide $(0,\infty)$ into $(n\pi,(n+1)\pi)$, but i met difficulty estimating $\displaystyle\int_0^{\pi} (x+n \pi)^pe^{-(x+n \pi)^8\sin^2x}dx$
My teacher says it is $O(n^{p-4})$, but i think it is wrong.
Comment: There are already good answers, but just a warning: proving that the second integral is $O(n^{p-4})$ will only prove that the first converges for $p<3$, not that it diverges for $p\le3$. You have also to find a lower bound.
Comment: Why do you think that your teacher is wrong? Note that you really need to estimate $\int_{\color{#C00}{-\pi/2}}^{\pi/2}(x+n\pi)^pe^{-(x+n\pi)^8\sin^2(x)}\,\mathrm{d}x$
Answer: HINT:
Using $2x/\pi\le\sin(x)\le x$ for $x\in [0,\pi/2]$, we can assert that
$$\begin{align}
\int_0^{\pi/2} (x+n\pi)^pe^{-(x+n\pi)^8\sin^2(x)}\,dx&\le (\pi/2+n\pi)^p\int_0^{\pi/2} e^{-(n\pi)^8(2x/\pi)^2}\,dx\\\\
&\le (\pi/2+n\pi)^p\int_0^\infty e^{-4n^8\pi^6x^2}\,dx\\\\
&=\frac{(n+1/2)^p\pi^p}{4\pi^{5/2}n^4}\\\\
&=O\left(n^{p-4}\right)
\end{align}$$
as $n\to \infty$.
Can you finish now?
Answer: Disclaimer: Do not be afraid of the constants. They come out naturally and it is not necessary to have them explicitly.
Since you asked for the values of $p>0$ for which the integral converges, I will show you that the integral converges if-f $0<p<3$. In doing so, I will have to prove the estimate of your teacher at some point. We begin with
$$\int_{0}^{+\infty}x^pe^{-x^8{(\sin x)}^2}dx=\int_0^{\pi}x^pe^{-x^8{(\sin x)}^2}dx + \sum_{n\geq1}\int_{0}^{1}(x+n\pi)^pe^{-(x+n\pi)^8(\sin x)^2}dx+\\\sum_{n\geq1}\int_{1}^{\pi-1}(x+n\pi)^pe^{-(x+n\pi)^8(\sin x)^2}dx.\ \ \ \ \ \ \ \ (*)$$
In the first integral the integrand is continuous on $[0,\pi].$ Consequently, the integrand is bounded there and so, the aforementioned integral is finite. This means that the integral of the right hand side will not affect the answer to our problem. Next, we show that the second series is convergent. On the interval $[1,\pi-1]$ we have that $(\sin x)^2\geq (\sin 1)^2=:c>0.$ Moreover, it is clear that $(x+n\pi)^8>n^8\geq n$ for $n\geq 1$ and $x>0.$ Thus,
$$e^{-(x+n\pi)^8(\sin x)^2}<e^{-nc}\ \ \ \ \ \ \ \ \ \ \ \ (1)$$
in the integrals of the second series. For a positive integer $n$ and an $x\in [1,\pi-1]$ we have that
$$x+n\pi<\pi(n+1)\leq 2\pi n=\frac{4\pi}{c}\cdot\frac{nc}{2}<\frac{4p\pi}{c}e^{\frac{nc}{2p}}.$$
Hence, $(x+n\pi)^p<(4p\pi/c)^pe^{\frac{nc}{2}}$ for positive integers $n$ and $x\in [1,\pi-1].$ We combine this inequality with $(1)$ and conclude that the second series is bounded from above by
$$\left(\frac{4p\pi}{c}\right)^p(\pi-2)\sum_{n\geq 1}\left(e^{-\frac{c}{2}}\right)^n=\left(\frac{4p\pi}{c}\right)^p\frac{(\pi-2)e^{-c/2}}{1-e^{-c/2}}<+\infty.$$
Of course, a series of positive terms, which is bounded, converges. So, the second series of $(*)$ is, indeed, convergent. This means that the answer to our problem depends only on the behavior of the first series of $(*)$. On $[0,1]$ (and more generally on $[0,\pi/2]$ by looking at the graphs) it is true that $\sin x\geq \frac{2}{\pi}x\geq 0$. As a result, for $x\in [0,1]$ and $n\geq 1$ we get
$$(x+n\pi)^pe^{-(x+n\pi)^8(\sin x)^2}\leq (1+n\pi)^pe^{-\frac{4}{{\pi}^2}n^8x^2}<5^pn^pe^{-c'n^8x^2},$$
where $c':=4/{\pi}^2>0.$ Consequently, the first series of $(*)$ is bounded from above by
$$5^p\sum_{n\geq 1}n^p\int_{0}^{1}e^{-c'n^8x^2}dx=\frac{5^p}{\sqrt{c'}}\sum_{n\geq 1}n^{p-4}\int_{0}^{\sqrt{c'}n^4}e^{-u^2}du\leq \frac{5^p\sqrt{\pi}}{2\sqrt{c'}}\sum_{n\geq 1}n^{p-4}.$$
At the last step we bounded all integrals by half of the Gaussian integral. Furthermore, $|\sin x|\leq |x|$ and so,
$$(x+n\pi)^pe^{-(x+n\pi)^8(\sin x)^2}>{\pi}^pn^pe^{-(1+n\pi)^8x^2}>{\pi}^pn^pe^{-c''n^8x^2}$$
for $c'=5^8>0,\ x\in [0,1]$ and $n$ a postive integer. Therefore, we deduce that the first series of $(*)$ is bounded from below by
$${\pi}^p\sum_{n\geq 1}n^p\int_{0}^{1}e^{-c''n^8x^2}dx=\frac{{\pi}^p}{\sqrt{c''}}\sum_{n\geq 1}n^{p-4}\int_{0}^{\sqrt{c''}n^4}e^{-u^2}du\\ \geq \frac{{\pi}^p}{\sqrt{c''}}\left(\int_{0}^{\sqrt{c''}}e^{-u^2}du\right)\sum_{n\geq 1}n^{p-4}.$$
The integral at the end is finite, because it has a finite interval of integration and its integrand is bounded by $1$. Summarizing, the series $\sum_{n\geq 1}n^{p-4}$ differs only by a constant from the first series of the right hand side of the first equality. Since that series determines the convergence of our integral, we deduce that the initial integral converges if-f the series $\sum_{n\geq 1}n^{p-4}$ converges. But, this is known. Thus, the integral of your question converges if-f $0<p<3.$


How to handle COVID-19 data in a panel

Question: I have panel data with COVID-19 variables starting in 2017 to look at how the pandemic affected stock markets. My N = 487 with 494500 daily observations. At the moment I left the time period before 2020 blank in the panel data resulting in my models only taking into account 151000 observations. Am I allowed to fill in the data period from 2017 to 2020 with 0's if I use the daily amount of new vaccinations and deaths to increase the amount of rows incorporated in the model?
Kind regards
Comment: Just to be clear, what is your outcome of interest?
Comment: how the pandemic has affected the liquidity in stock marets @ThomasBilach
Answer: Since you are interested in the stock market a more elegant way to incorporate the pandemic covariates would be to include a set of dummy variables (be aware of the dummy variable trap) and, depending on other independent variables you are considering, interaction terms of the pandemic dummy variables and other covariates. If you are dealing with daily data you may also consider to employ Chow test to determine whether there is a structural change between the two different periods.
I suggest you to have a look at Chapter 13 of Introductory Econometrics: A Modern Approach by Jeffrey Wooldridge.
Comment: Thank you for your suggestion. I'll look into it

How to handle COVID-19 data in a panel


Decorators that are properties of decorated objects?

Question: I want to create a decorator that allows me to refer back to the decorated object and grab another decorator from it, the same way you can use setter/deleter on properties:
@property
def x(self):
    return self._x

@x.setter
def x(self, y):
    self._x = y

Specifically, I'd like it to act basically the same as property, but emulate a sequence instead of a single value. Here's my first shot at it, but it doesn't seem to work:
def listprop(indices):
    def dec(func):
        class c(object):
            def __init__(self, l):
                self.l = l
            def __getitem__(self, i):
                if not i in self.l:
                    raise Exception("Invalid item: " + i)
                return func(i)
            @staticmethod
            def setter(func):
                def set(self, i, val):
                    if not i in self.l:
                        raise Exception("Invalid item: " + i)
                    func(i, val)
                c.__setitem__ = set
        return c(indices)
    return dec

# ...
class P:
    @listprop(range(3))
    def prop(self, i):
        return get_prop(i)

    @prop.setter
    def prop(self, i, val):
        set_prop(i, val)

I'm pretty sure that c.__setitem__ = set is wrong, but I can't figure out how to get a reference to the instance at that point. Ideas?
Alex Martelli's solution works on 2.6, but something about it is failing on 2.4 and 2.5 (I'd prefer to have it work on these older versions as well, though it's not strictly necessary):
2.4:
>>> p = P()
>>> p.prop
>>> p.prop[0]
Traceback (most recent call last):
  File "<stdin>", line 1, in ?
TypeError: unsubscriptable object

2.5:
>>> p = P()
>>> p.prop
>>> p.prop[0]
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
TypeError: 'NoneType' object is unsubscriptable

2.6:
>>> p = P()
>>> p.prop
<__main__.c object at 0x017F5730>
>>> p.prop[0]
0

Comment: Why not simply set the property value to be a list?
Comment: @S.Lott: Because I don't need a list, I need an object that looks like a list, but actually gets its values from somewhere else, by using the list index as an additional argument. In fact, I need several of them that all do very similar, but slightly different things.
Answer: I fixed many little details and the following version seems to work as you require:
def listprop(indices):
    def dec(func):
        class c(object):
            def __init__(self, l, obj=None):
                self.l = l
                self.obj = obj
            def __get__(self, obj, cls=None):
                return c(self.l, obj)
            def __getitem__(self, i):
                if not i in self.l:
                    raise Exception("Invalid item: " + i)
                return func(self.obj, i)
            def setter(self, sfunc):
                def doset(self, i, val):
                    if not i in self.l:
                        raise Exception("Invalid item: " + i)
                    sfunc(self.obj, i, val)
                c.__setitem__ = doset
                return self
        result = c(indices)
        return result
    return dec

# ...
class P:
    @staticmethod
    def get_prop(i): return i*100

    @staticmethod
    def set_prop(i, val): print 'set %s to %s' % (i, val)

    @listprop(range(3))
    def prop(self, i):
        return self.get_prop(i)

    @prop.setter
    def prop(self, i, val):
        self.set_prop(i, val)

As you see, assigning to c.__setitem__ was not the problem -- there were others, such as c lacking a __get__ (so it wasn't a descriptor, see this guiide) and setter returning None (so p.prop ended up as None).


When was "Nashville Tuning" invented?

Question: Answering a question about alternate tuning today got me thinking about Nashville Tuning and that this is basically the exact same concept used by Stanley Clarke (and apparently Ron Carter) to "invent" the Piccolo Bass.
This article attributes the invention to Ray Edenton; its reference to this article seems to imply the same... The wiki for Nashville Tuning and Ray Edenton do not reference this at all (I realize that Wikipedia does not always contain the most accurate or complete information) and the web doesn't turn up a lot of results otherwise.
Did he "invent" this method of adding thinner strings to an instrument in order to allow tuning to higher pitches? Does this method have roots even further back in time and potentially on other instruments?
Answer: I am familiar with 'Nashville Strung' or 'High Strung' guitar situations, but not Nashville tuning.
In Nashville Strung, a standard six-string guitar is strung with the typical three light-guage (un-wound) on the bottom three strings, and the three upper (normally wound, heavier strings) are replaced with the same three light-gauge strings.
This creates a shimmering, sparkly sound that adds an interesting layer over the other typically-strung guitars in the recording.
I first heard about it in the late 1970's.
Comment: Yes, those phrases all refer to Nashville Tuning... There is plenty of info about the concept itself out there on the web. I'm wondering who actually 'invented' it and when. And, if it's something that has roots even further back than last century
Comment: Please could you clarify? "the typical three light-guage (un-wound) on the bottom three strings" -- where light-gauge strings are *typically* put is on the top strings. "the three upper (normally wound, heavier strings)" -- this is backwards; higher strings need to be lighter, and lower strings heavier. "are replaced with the same three light-gauge strings" -- so that's G3 B3 E4 G3 B3 E4 -- is that right?
Comment: @RosieF Actually you're both saying the same thing. You're counting pitch-wise, but standard guitar string counting is that the high E string is string number "one" or the "first" string. That's why Sparquelito called the high E, B, and G strings "bottom three" as in strings 1-2-3.
Comment: @NickGrooves I know that a string instrument's strings are numbered from top to bottom. But numbering is not an issue with Sparquelito's answer because they didn't mention numbers. The issue seems to be that they called the top strings the bottom strings and the lower strings the upper strings. String I is the top string even though it gets the lowest number. (And high/low don't refer to physical position when being played -- the idea that they do has caught some other people out in other questions on music.SE.)
Answer: The guitar was developed in Spain around the same time as the mandola family in northern Italy. Both evolved from the lute which entered Europe via the court of Palermo. There were and have been many variations of number of strings and string gauges in both families ever since. Attributing "invention" to an alternate tuning or alternately-strung instrument is misguided. For example, one would not say the "Trumpet in C" or a "prepared piano" are new inventions.
Case in point, this PBS article on the history of guitar in North America describes the first "guitar" brought to the New World by explorers as having "five sets of double strings." The article goes on:

By 1800 the six string instrument known today had evolved in southern Europe and was brought over ... By the turn of the [20th] century, improved techniques allowed manufacturers like Martin (founded 1833) and Gibson (founded 1894) to offer steel-string guitars. When played with picks, this allowed a much brighter, louder sound ... one inventory in 1900 reported that over 78,000 guitars had been manufactured that year. Throughout the 1920s, American musicians set about inventing new ways to tune and note these instruments ...

There are many off-shoots of the guitar and bass worldwide which have more strings and/or are tuned differently. The guitar itself has not changed in concept or been re-"invented" merely because the string material or tuning is different.

When was "Nashville Tuning" invented?


Update multiple columns in the same statement

Question: Assume that I have the following database schema:
schema
A student can have more than 2 grades in the same subject.
I want to update the columns highest_math_grade, highest_physic_grade, highest_chemistry_grade of table student. This is how I do it:
UPDATE student JOIN (
SELECT student.id, MAX(grade) AS grade
FROM student join grade
ON student.id = grade.student_id
WHERE subject = 'math'
GROUP BY student.id
  ) AS subquery
ON student.id = subquery.id
SET highest_math_grade = subquery.grade;

UPDATE student JOIN (
    SELECT student.id, MAX(grade) AS grade
    FROM student join grade
    ON student.id = grade.student_id
    WHERE subject = 'physic'
    GROUP BY student.id
  ) AS subquery
ON student.id = subquery.id
SET highest_physic_grade = subquery.grade;

UPDATE student JOIN (
    SELECT student.id, MAX(grade) AS grade
    FROM student join grade
    ON student.id = grade.student_id
    WHERE subject = 'chemistry'
    GROUP BY student.id
) AS subquery
ON student.id = subquery.id
SET highest_chemistry_grade = subquery.grade;

It is not nice that I have to use 3 update statements. I tried:
UPDATE student
  JOIN (SELECT *
        FROM grade
        ORDER BY grade) AS grade
    ON student.id = grade.student_id
SET highest_math_grade    = (CASE WHEN grade.subject = 'math'
  THEN grade.grade
                             ELSE highest_math_grade END),
  highest_chemistry_grade = (CASE WHEN grade.subject = 'chemistry'
    THEN grade.grade
                             ELSE highest_chemistry_grade END),
  highest_physic_grade    = (CASE WHEN grade.subject = 'physic'
    THEN grade.grade
                             ELSE highest_physic_grade END);

However, it only updates each student once which is not what I wanted.
Is there a way to achieve the same thing with just one update statement?
Answer: Try this answer, Hope this helps you:
UPDATE S SET S.highest_math_grade=Math_Grade
    ,S.highest_chemistry_grade =chemistry_Grade
    ,S.highest_physic_grade=physic_Grade
FROM STUDENT S,(
    SELECT S.ID
        ,MAX(G1.grade)Math_Grade
        ,MAX(G2.grade)chemistry_Grade
        ,MAX(G3.grade)physic_Grade
    FROM STUDENT S
    LEFT JOIN Grade G1 ON S.id=G1.student_id AND G1.subject = 'math'
    LEFT JOIN Grade G2 ON S.id=G2.student_id AND G2.subject = 'chemistry'
    LEFT JOIN Grade G3 ON S.id=G3.student_id AND G3.subject = 'physic'
    GROUP BY S.ID
)D
WHERE S.ID=D.ID


Show that $\lim_{s\to 1^+}\prod_{r \equiv 3 \mod 4} (1-r^{-s})^{-1} = \infty.$

Question:
I want to show that $$\lim_{s\to 1^+}\prod_{r \equiv 3 \mod 4} (1-r^{-s})^{-1} = \infty.$$

I showed that $$\lim_{s\to 1^+} \ (s-1) \prod _{q \equiv 1 \mod 4} (1-q^{-s})^{-1} = 1.$$ I feel that there is a simple step that I am overlooking to show that the result immediately follows. Any ideas on how to proceed/conclude? I'm hoping to deduce from this that the sum of reciprocals of primes congruent to 3 modulo 4 diverges.
Answer: Let $\chi_4$ be the non-principal Dirichlet's character $\!\!\pmod{4}$. For any $s>1$ we have
$$ L(\chi_4,s)=\sum_{n\geq 1}\frac{\chi_4(n)}{n^s} = \sum_{k\geq 0}\left(\frac{1}{(4k+1)^s}-\frac{1}{(4k+3)^s}\right)\\=\prod_{p\equiv 1\!\!\pmod{4}}\left(1-\frac{1}{p^s}\right)^{-1}\prod_{p\equiv 3\!\!\pmod{4}}\left(1+\frac{1}{p^s}\right)^{-1}=\zeta(s)\prod_{p\equiv 3\!\!\pmod{4}}\left(\frac{1+1/p^s}{1-1/p^s}\right)^{-1} $$
by Euler's product. As $s\to 1^+$, the LHS approaches $\frac{\pi}{4}$ and $\zeta(s)$ approaches $+\infty$ due to its simple pole at $s=1$ with residue $1$. It follows that
$$ \lim_{s\to 1^+}\prod_{p\equiv 3\!\!\pmod{4}}\left(\frac{1-1/p^s}{1+1/p^s}\right)^{-1}=+\infty $$
implying $$ \lim_{s\to 1^+}\prod_{p\equiv 3\!\!\pmod{4}}\left(1-\frac{1}{p^s}\right)^{-1}=+\infty. $$


How to `continue` or `break` in a `when` statement inside a `while` loop using Kotlin

Question: I am converting a large project to Kotlin. There have been numerous challenges.  Me learning the new patterns of Kotlin is one of them.  Hopefully there is a pattern I can use to resolve this one.
Here is the code I am attempting to achieve.  But, continue and break are not valid in a when statement.
while (!mStopped && c.moveToNext()) {

    val itemType = c.getInt()
    when (itemType) {
        1, 2 -> {
            doSomething()
            if (condition)
                continue
            doSomethingElse()
        }
    }
    doTheLastStuff()
}

This is a very cut-down version of the code.  The original java code had 100's of lines inside the switch statements, and lots of continue's and break's.
What I am trying to achieve is to continue execution back at the while statement.  What is the pattern for doing this in Kotlin
Comment: (Note:  This is not a duplicate of the other.  The other is about functional loops, this is about non-functional loops.  I flagged for moderator intervention to "un-mark this as a dupe, because it is not")
Comment: After that, maybe see if you can turn the loop into a tail recursive function, which can be optimized with Kotlin's tailrec "annotation".
Answer: You can use labels to continue/break the loop i.e:
myLoop@ while (!mStopped && c.hasNext()) {

    val itemType = c.next()
    when (itemType) {
        1, 2 -> {
            doSomething()
            if (condition())
                continue@myLoop
            doSomethingElse()
        }
    }
    doTheLastStuff()
}

Here's is a relevant excerpt from documentation:

Any expression in Kotlin may be marked with a label. Labels have the
  form of an identifier followed by the @ sign, for example: abc@,
  fooBar@ are valid labels(...)
  A break qualified with a label jumps to the execution point right
  after the loop marked with that label. A continue proceeds to the next
  iteration of that loop.
Answer: The issue here is that break and continue have a special meaning inside a when statement, namely breaking and continuing the when itself, not the surrounding loop. For now (kotlin 1.0) the syntax is not decided yet, so the feature does not work, despite the keywords being reserved.
To solve this, use labels https://kotlinlang.org/docs/reference/returns.html#break-and-continue-labels:
loop@ while (...) {
    when (itemType) {
        1 -> continue@loop
        else -> break@loop
    }
}


$F(h)=h \circ \phi$, $F:C^B \to C^A$, $\phi : A\to B$, prove F is surjective

Question: Got a question as the following, could solve the first, would appreciate getting some help for the second :
Let there be $F(h)=h \circ \phi$, $F:C^B \to C^A$, $\phi : A\to B$.
Assuming there's in C more then one element, prove:

if F is injective then $\phi$ is surjective.
if F is surjective then $\phi$ is injective.

So for "if F is injective then $\phi$ is surjective", I proved by contrapositivity.
I assumed that F is injective but $\phi$ isn't surjective, then exists $b \in B$ such that there is no $a\in A$ that fulfills $\phi(a)=b$.
Secondly, I define $f_1, f_2 \in C^B$ that are equal except for element 'b' ($\in B$), meaning that: $f_1(b)=c_1$ $f_2(b)=c_2$.
Now, because F is injective $F(f_1)=F(f_2)$, then $f_1 = f_2$ though $f_1(b)\neq f_2(b)$. Then we get contradiction, then $\phi$ must be surjective.
Now, about "If F is surjective then $\phi$ is injective", I'm not quite sure how to do that. I also think it should be done by the contrapositive path.  Should I define some function $g\in C^A$ that there is no $h\in C^B$ that gives $F(h)=g$ because of defining $\phi$ as non injective?
Would appreciate your help.
Comment: Yes, contraposition sounds like the right way to go for the second part too.
Comment: @HenningMakholm So I need to define $g\in C^A$ such that there is no $h\in C^B$ that gives me g. had trouble finding such one, any ideas?
Comment: x @Ami: Correct. Note that you know that $\phi$ is not injective -- so there are $a_1$ and $a_2$ such that $\phi(a_1)=\phi(a_2)$. This means that $h\circ\phi$ will always map $a_1$ and $a_2$ to the same element of $C$ ...
Answer: First, make $f_1$ and $f_2$ completely concrete: indeed we pick distinct $c_1 \neq c_2$ in $C$ (which our assumption tells us we can do). We have one unreachable $b \in B$. Define $f_1(x) = c_1 = f_2(x)$ for all $x \in B\setminus\{b\}$, $f_1(b) = c_1, f_2(b) = c_2$. Now explicitly show that $F(f_1) = F(f_2)$, etc.
Now suppose that $\phi$ is not injective, this gives us positive info: there are $a_1 \neq a_2$ in $A$ such that $\phi(a_1) = b = \phi(a_2)$ for some $b \in B$.
This means that all compositions with $\phi$ (which is what $F$ is) will do the same thing to $a_1$ and $a_2$. So this limits the kind of functions we can get as an image. Find a concrete (!) function that does not do this and then it cannot be an image of $F$ for this $\phi$.
Comment: Yes. Evaluate $F(f)(a_1)=g(a_1)$ etc. $F(f)(a_1) = (f \circ \phi))(a_1) = f(\phi(a_1)) = f(b)$. Same for $F(f)(a_2) = g(a_2) = f(b)$. So indeed $g(a_) = g(a_2)$ contradiction. No such $f$ can exist.
Comment: how can you know whether there're $a_1, a_2$ in A? you know about C, but know nothing about A.
Comment: You assume non-injectivity (by the contraposition). So you have at least two elements.
Comment: Got you. So I can define g as follows:
$g(a_1)=c_1$ $g(a_2)=c_2$, and for every other $a\in A$ g would be $g(a)=c$ for some arbitary $c\in C$. but as we said $\phi (a_1)=b= \phi (a_2)$ -> then it takes us to contradiction?
Comment: Suppose that $F(f) = g$ for some $f \in C^B$. What happens at $a_1$ and $a_2$?
Comment: at $a_1, a_2$ I get $g(a_1)=g(a_2)$?
Comment: Contrary to how $g$ was chosen
Comment: you mean contrary to that we chose g to be as following:
$g(a_1)=c_1, g(a_2)=c_2$, $g(a)=c$ for some arbitrary $c\in C$ and for every other $a\in A$?


using higher frame then dropping to lower time to find better entry and then fire alert

Question: Unable to get the alerts to fire. I was hoping to get some advice on the following script.
Looking for a pull back on a 4 or 1 hour time frame and drop down to a lower time frame and looking for a stochastic roll over then send an alert.
Would like it to be once per session, but this is a bridge to far for me. Just would like to see the script fire alerts than work on once per session.
Any advice appreciated.
'''
strategy(title="SS_Bounty", overlay=true, calc_on_every_tick = true)

//@version=5

strategy(title="Street_Bounce", overlay=true, calc_on_every_tick = true)

//inputs
var TP = "Trading Parameters"
showCrosses = input(defval=true, title="Show EMA Crosses?", group = TP)
//count = input(defval = 1, title =" How many times do you want sript to run", group =TP)
var HT = "Higher time Frame"
//var count1 = 0
emainput = input(title="EMA", defval = 50, group = HT)
ema1 =ta.ema(close, emainput)

var LT = "Lower Time Frame"
string i_Period = input.timeframe(title="Lower Timeframe", defval="30", group = LT)
periodK = input.int(12, title="%K Length", minval=1, group = LT)
smoothK = input.int(3, title="%K Smoothing", minval=1, group = LT)
periodD = input.int(3, title="%D Smoothing", minval=1, group = LT)

///plot EMA////
plot(ema1, title ='EMA', linewidth =2, color=color.blue, display = display.pane)

///higher time frame pull back ////

longCondition = close[1] > ema1 and ta.crossunder(close, ema1) ? true : na
shortCondition = close[1] < ema1 and ta.crossover(close, ema1) ? true : na

plotarrow(showCrosses and longCondition ? 1 : 0, colorup=color.green, maxheight=50, minheight=50, display = display.pane)
plotarrow(showCrosses and shortCondition ? -1 : 0, colordown=color.red, maxheight=50, minheight=50, display = display.pane)

////lower time frame stochastic/////

MLBuy = input(title="Main Line Stoch Buy has to be below ", defval = 20, display = display.none)
MLSell = input(title="Main Line Stoch Buy has to be above ", defval =80, display = display.none)
ctf_k = ta.sma(ta.stoch(close, high, low, periodK), smoothK)
ctf_d = ta.sma(ctf_k, periodD)

[_ltf_k, _ltf_d] = request.security_lower_tf(syminfo.tickerid, i_Period, [ctf_k, ctf_d])

len = array.size(_ltf_k)

float ltf_k = (len > 0) ? array.get(_ltf_k, len - 1) : na
float ltf_d = (len > 0) ? array.get(_ltf_d, len - 1) : na

//PLOT
//plot(ltf_k, title="%K", color=#2962FF)
//plot(ltf_d, title="%D", color=#FF6D00)
//h0 = hline(80, "Upper Band", color=#787B86)
//hline(50, "Middle Band", color=color.new(#787B86, 50))
//h1 = hline(20, "Lower Band", color=#787B86)
//fill(h0, h1, color=color.rgb(33, 150, 243, 90), title="Background")

//Lower time frame Variables//
GetPipSize() =>
    syminfo.mintick * (syminfo.type == "forex" ? 10 : 1)
SL = input.int(title = "Stop Loss in Pips", defval = 25, group = TP, display = display.none)
PIP_SL = SL * GetPipSize()
R_R = input.int(title = "Risk Reward multiplier", defval = 2, group = TP, display = display.none)
Buy_Profit = open + (PIP_SL * R_R)
Sell_Profit = open - (PIP_SL * R_R)
Buy_SL = open - PIP_SL
Sell_SL = open + PIP_SL
var bool LTBuy = false
var bool LTSell = false
var float open1 = 0
var float open2 = 0

//NewDay = timeframe.change("1D")

//buy alerts
if longCondition == true
    LTBuy := (ctf_k < MLBuy and ctf_k[2] < ctf_d[2] and ctf_k[1] > ctf_d[1]) ? true : na
    open1 := open[0]

if LTBuy == true
    alert("Buy " + syminfo.ticker + " at " + str.tostring(open1,"0.000") + "\n TP " + str.tostring(Buy_Profit,"0.000") + "\n SL " + str.tostring(Buy_SL,"0.000"), alert.freq_once_per_bar)
    longCondition := false

//Sell Alerts

if shortCondition == true
    LTSell := (ctf_k > MLSell and ctf_k[2] > ctf_d[2] and ctf_k[1] < ctf_d[1]) ? true : na
    open2 := open[0]

if LTSell == true
    alert("Sell " + syminfo.ticker + " at " + str.tostring(open2,"0.000") + "\n TP " + str.tostring(Sell_Profit,"0.000") + "\n SL " + str.tostring(Sell_SL,"0.000"),alert.freq_once_per_bar)
    shortCondition := false

'''
Answer: You should always be on your entry timeframe. And from there, you should be looking at the higher timeframes. You are doing the opposite.
Use request.security() to look at the higher timeframes and make sure it does not repaint with the following method:
f_secureSecurity(_symbol, _res, _src) => request.security(_symbol, _res, _src[1], lookahead = barmerge.lookahead_on)

Then do your anlaysis on your entry timeframe and place the order.


Is this a good case for bonferroni correction (or a different correction)?

Question: Here's my experiment : I'm comparing the responses of two cultural groups (high/low context, total n = 550) on several dependent variables (instruments).
The idea is to see if these two groups differ in their responses on these variables.
I have a total of 10 different dependent variables, and perform a wilcox pairwise test on each of them.
Here's what I do not understand: Is a bonferroni correction needed in this case? Does the case of 'multiple statistical tests' refer to testing for multiple (>2) groups and one dependent variable (for example, 4 groups need 6 comparisons) or does it also refer to the case of a single pairwise test and multiple dependent variables? How is the 'family' of tests defined?
Comment: Whether there are multiple comparisons of a single dependent variable, or multiple dependent variables, is irrelevant as to *whether* you apply multiple comparisons. On the other hand, *how* you apply MCPs can differ between the cases, specifically as regards to incorporating dependencies. Bonferroni is valid in either case, although somewhat conservative, depending upon the nature of such dependence structures. How to incorporate dependencies into the MCP, in either case, is well documented in the literature.
Answer: So, I think a good way of approaching this problem might be to think about it the context of some more familiar statistical tests. Let's start by thinking our way through a simpler problem where the answer is more easily seen, and then we'll think about generalizing this out to your case.
Let's say that, instead of 10 dependent variables and 2 independent variables, you have just a single dependent variable but 10 independent variables (e.g., 10 different cultures you measured on just a single instrument). In this case, you might consider running a series of pairwise t-tests comparing Group A vs Group B, Group A vs Group C, Group B vs Group C, and so on. The issue with this approach is that you would need to adjust your p-values because you have multiple tests. Each of these tests is independent of the last one (e.g., a difference in Group A vs Group B has no effect on whether there's a difference between Group B and Group E). At the same time, each of these independent tests has a probability of 0.05 (or whatever alpha value you've specified) of incorrectly rejecting the null hypothesis. In order to perform full pairwise comparisons for all 10 groups, we would need to run 45 different t-tests that each independently give a 0.05 probability of incorrectly rejecting the null hypothesis. Since we have multiple tests that each have a 0.05 probability of a Type I error, we end up with a Type I error rate much larger than 0.05 unless we do something to control for the fact that we ran so many tests to get our final conclusions.
There are two dominant approaches to addressing this. One is to adjust your p-values for multiple corrections as you propose. In this simplest form, this is the Bonferonni correction where the desired Type I error rate (i.e., alpha value) is divided by the total number of tests you ran. There are other adjustments that might be preferable when you are concerned about persevering power or when there are correlations/dependence between the tests you run. The other approach is to use statistics that allow for singular tests across the group. Using the example of a single dependent variable measured over 10 different groups, we might prefer an ANOVA to a series of t-tests. The advantage of the ANOVA is that it is a single test that will tell us whether any of the means of the groups differ, so we don't have to adjust this p-value since we just have that one test. We then have special post-hoc analyses that we can follow-up the ANOVA with that also help to control familywise error.
So, in your case, you have multiple dependent variables. Some methods that are often not as commonly taught in intro statistics classes are multivariate statistics, which are the methods needed for analyzing multiple dependent variables at once. There are multivariate statistical extensions of most of the common statistical tests: multivariate linear regression, Hoetelling's T-squared, MANOVA, etc. The fact that you have utilized a non-parametric statistic suggests to me that there is another wrench thrown into your analyses as these non-parametric statistics are also commonly overlooked in general stats education. Without knowing more about what statistical software you're using, I'm hesitant to recommend very much more for you about how to extend the multivariate statistical methods to non-parametric statistics (or potentially bootstrapping them).
So, we now come to your specific problem where you've got multiple dependent variables being tested against your two groups. What is considered as part of your familywise error really boils down to why you are using the statistic in the first place. If you have a specific hypothesis for each and every of your dependent variables, then you can make a case for uncorrected p-values because you are using the result of each individual statistic to make a conclusion. I don't think that the case is very strong, but you can make it. If your hypothesis is very general (e.g., we think there might be some differences in some of these variables), then you absolutely have to do something to control that familywise error. Getting right down to the core of the p-value issue and Type I error-rates, anytime we run a test and make an inference on the p-value, we are accepting some probability of being wrong. When we run many tests in the course of a single study, we might be confident that the probability of any one of those tests being $\alpha$ is 0.05 (or whatever our nominal value is), but in reality, the probability that at least one the results in the study is a Type I error is not going to be $\alpha$. So, the "familywise error" is something of a matter of perspective, and it's part of the reason that emphasizing decision making based on p-values has been increasingly criticized by the statistics community. The most important thing is doing exactly what you've done, which is being critical of your decisions and trying to minimize the risk that you introduce unwanted error into your reporting. Ultimately, you may decide that an elevated Type I error rate is OK for your particular need. This sometimes happens in exploratory research with small sample sizes (e.g., pilot studies) where controlling for Type I error rates would reduce already low power. At the end of the day, whatever you decide to do, it is important that you know the limitations and the trade-off of that decision so that you can appropriately inform your audience of those caveats, though it should also be very obvious to them whatever decision you made as well and hopefully they're informed enough to know something of the consequences.
Comment: Thank you for this comprehensive answer. To address your comments: (a) I use a non-parametric test because all the variables are non-normally distributed. (b) I'm using R for analysis, and wasn't able to find a good non-parametric alternative to MANOVA. But thanks for the hint to look for one - I found the npmv package, will give it a try.
Comment: Glad you found it helpful! One thing you might consider is running a MANOVA but getting bootstrap confidence intervals instead. The issue when there is non-normal data is that you get biased standard errors since the statistic assumes that normal distribution in the population, but bootstrapping approximates the empirical sampling distribution on which inference is based instead. Depending on sample size, that might be a good options. Here's a decent overview of different ways of handling non-normal data: https://www.frontiersin.org/articles/10.3389/fpsyg.2018.02104/full
Comment: So an update - I tried the npmv package, but it only indicates if two groups differ at a basic level (which suits my requirement) but does not provide a per-variable level analysis of significance. I also found the MANOVA.RM package which provides a semi/non-parametric method. Will try that out.
Comment: Did the MANOVA.RM package work out?


How to stop menu links being disabled after saving nodes?

Question: A localised Drupal 7 site I'm working on has a navigation menu along the top. Each node is provided with a menu link with a given weight. Nodes are translated into three (non-English) languages (the admin language is English). The nodes show on the menu correctly depending on the current language.
Whenever I edit a node (eg edit the title, body) and click Save, its links disappears from the menu.
The same thing happens if I edit a node but don't actually change anything, then click Save.
I can re-enable it by:

Edit the node again
Untick the menu link
Save
Edit the node yet again
Tick the menu link (re-filling the title/weight)
Save again

Or:

Go to admin/structure/menu/manage/main-menu
All the other menu links are enabled, but the recently saved is not and has "(disabled)" after its name
Tick the box to re-enable
Save configuration

But how can I stop menu links from being disabled when a node is edited?
Answer: Here's a quick fix:

Download version 1.7 of i18n.
Unzip it and find the folder named i18n_menu
Go to your site's modules directory (could be /sites/all/modules/)
    Find the folder i18n
Replace the subfolder i18n/i18n_menu with the version from version
1.7 you downloaded in step 1

You can also check this bug report: http://drupal.org/node/1905268
Comment: Thanks for the suggestion. Unfortunately if I do this, links don't disappear after edits, but instead I see *all* links from all three languages instead of just those for the current language. Any ideas?
Comment: I checked the bug, and its parent bug has been fixed and released in the latest dev version. Installing that fixed it. Thanks for the pointers!
Answer: It's a bug in the latest version 1.8 of i18n  Martins Bertins' patch fixed this for me.
But its parent bug has been released in the latest dev version, and installing that fixed it as well.


Android Build fails when I change a .png

Question: I have a NativeScript Application with the directory
...\app\App_Resources\Android\
where alle the images are stored (like drawable-hdpi etc.).
Whenever I change a picture (e.g. ...\app\App_Resources\Android\drawable-hdpi\icon.png to another png I receive a mergeerror:
:generateF0F1F2F3DebugResValues UP-TO-DATE
:generateF0F1F2F3DebugResources UP-TO-DATE
:mergeF0F1F2F3DebugResources
Error: java.util.concurrent.ExecutionException: com.android.ide.common.process.ProcessException:
:mergeF0F1F2F3DebugResources FAILED

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':mergeF0F1F2F3DebugResources'.
> Error: java.util.concurrent.ExecutionException: com.android.ide.common.process.ProcessException:

* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.

BUILD FAILED

Did I miss something to do before? I converted the new .png from a .jpg, but that should not have impact (I could swear it worked already). The iOS-Version is running without any problems.
Edit: What I did:
I resized a jpg to the format of the old .png files and converted it into a .png, then inserted them and replaced the old .png-files by the new .png-files having the same size as the old ones have had.
So to be clear:
There was a file ...\app\App_Resources\Android\drawable-hdpi\icon.png with the size 72x72 and I had a file
icon.jpg which I resized to 72x72 and converted it into icon.png.
Then I inserted it for the other picture, so now I have (again)
...\app\App_Resources\Android\drawable-hdpi\icon.png with the size 72x72 just displaying a slightly other picture.
My pictures:
https://i.stack.imgur.com/F2Jaz.jpg
What else do I have in that directory:
In my ...\app\App_Resources\Android I have the AndroidManifest.xml and the app.gradle and some xml-stuff which should not impact any pictures.
Edit 2: If that matters: These images are the launch screen and the icon of the android app. Could it be that the manifest saves some metadata stuff and fails to merge it? Or do I need to adjust the .xml-files from the "values" and "values-21" folders?
Edit 3 ------------------
when I run tns debug android --log trace I get the following output:
15:25:01.117 [DEBUG] [org.gradle.api.Project] AAPT(QueuedJob{
title=Cruncher notify_panel_notification_icon_bg.png,
task={from=C:\Dev\biff\HandyApp\platforms\android\build\intermediates\exploded-aar\com.android.support\appcompat-v7\26.0.0-alpha1\res\drawable-xhdpi-v4\notify_panel_notification_icon_bg.png, to=C:\Dev\biff\HandyApp\platforms\android\build\intermediates\res\merged\F0F1F2F3\debug\drawable-xhdpi-v4\notify_panel_notification_icon_bg.png},
future=com.google.common.util.concurrent.SettableFuture@9c66ab1}) discarded: Crunching C:\Dev\biff\HandyApp\platforms\android\build\intermediates\exploded-aar\com.android.support\appcompat-v7\26.0.0-alpha1\res\drawable-xhdpi-v4\notify_panel_notification_icon_bg.png
15:25:01.118 [QUIET] [system.out] Error: java.util.concurrent.ExecutionException: com.android.ide.common.process.ProcessException:
15:25:01.118 [DEBUG] [org.gradle.api.Project] AAPT out(Facade for 1223856843): Crunching single PNG file: C:\Dev\biff\HandyApp\platforms\android\build\intermediates\exploded-aar\com.android.support\appcompat-v7\26.0.0-alpha1\res\drawable-xhdpi-v4\notify_panel_notification_icon_bg.png
15:25:01.118 [DEBUG] [org.gradle.api.Project] AAPT out(Facade for 1223856843): -> QueuedJob{
title=Cruncher notify_panel_notification_icon_bg.png,
task={from=C:\Dev\biff\HandyApp\platforms\android\build\intermediates\exploded-aar\com.android.support\appcompat-v7\26.0.0-alpha1\res\drawable-xhdpi-v4\notify_panel_notification_icon_bg.png, to=C:\Dev\biff\HandyApp\platforms\android\build\intermediates\res\merged\F0F1F2F3\debug\drawable-xhdpi-v4\notify_panel_notification_icon_bg.png},
future=com.google.common.util.concurrent.SettableFuture@9c66ab1}
15:25:01.118 [DEBUG] [org.gradle.api.Project] AAPT notify(QueuedJob{
title=Cruncher notify_panel_notification_icon_bg.png,
task={from=C:\Dev\biff\HandyApp\platforms\android\build\intermediates\exploded-aar\com.android.support\appcompat-v7\26.0.0-alpha1\res\drawable-xhdpi-v4\notify_panel_notification_icon_bg.png, to=C:\Dev\biff\HandyApp\platforms\android\build\intermediates\res\merged\F0F1F2F3\debug\drawable-xhdpi-v4\notify_panel_notification_icon_bg.png},
future=com.google.common.util.concurrent.SettableFuture@9c66ab1}): Crunching single PNG file: C:\Dev\biff\HandyApp\platforms\android\build\intermediates\exploded-aar\com.android.support\appcompat-v7\26.0.0-alpha1\res\drawable-xhdpi-v4\notify_panel_notification_icon_bg.png
15:25:01.118 [DEBUG] [org.gradle.api.internal.tasks.execution.ResolveTaskArtifactStateTaskExecuter] Removed task artifact state for {} from context.
15:25:01.118 [DEBUG] [org.gradle.api.Project] AAPT(QueuedJob{
title=Cruncher notify_panel_notification_icon_bg.png,
task={from=C:\Dev\biff\HandyApp\platforms\android\build\intermediates\exploded-aar\com.android.support\appcompat-v7\26.0.0-alpha1\res\drawable-xhdpi-v4\notify_panel_notification_icon_bg.png, to=C:\Dev\biff\HandyApp\platforms\android\build\intermediates\res\merged\F0F1F2F3\debug\drawable-xhdpi-v4\notify_panel_notification_icon_bg.png},
future=com.google.common.util.concurrent.SettableFuture@9c66ab1}) discarded: Crunching single PNG file: C:\Dev\biff\HandyApp\platforms\android\build\intermediates\exploded-aar\com.android.support\appcompat-v7\26.0.0-alpha1\res\drawable-xhdpi-v4\notify_panel_notification_icon_bg.png
15:25:01.118 [DEBUG] [org.gradle.api.Project] AAPT out(Facade for 1223856843):  Output file: C:\Dev\biff\HandyApp\platforms\android\build\intermediates\res\merged\F0F1F2F3\debug\drawable-xhdpi-v4\notify_panel_notification_icon_bg.png
15:25:01.118 [DEBUG] [org.gradle.api.Project] AAPT out(Facade for 1223856843): -> QueuedJob{
title=Cruncher notify_panel_notification_icon_bg.png,
task={from=C:\Dev\biff\HandyApp\platforms\android\build\intermediates\exploded-aar\com.android.support\appcompat-v7\26.0.0-alpha1\res\drawable-xhdpi-v4\notify_panel_notification_icon_bg.png, to=C:\Dev\biff\HandyApp\platforms\android\build\intermediates\res\merged\F0F1F2F3\debug\drawable-xhdpi-v4\notify_panel_notification_icon_bg.png},
future=com.google.common.util.concurrent.SettableFuture@9c66ab1}
15:25:01.118 [DEBUG] [org.gradle.api.Project] AAPT notify(QueuedJob{
title=Cruncher notify_panel_notification_icon_bg.png,
task={from=C:\Dev\biff\HandyApp\platforms\android\build\intermediates\exploded-aar\com.android.support\appcompat-v7\26.0.0-alpha1\res\drawable-xhdpi-v4\notify_panel_notification_icon_bg.png, to=C:\Dev\biff\HandyApp\platforms\android\build\intermediates\res\merged\F0F1F2F3\debug\drawable-xhdpi-v4\notify_panel_notification_icon_bg.png},
future=com.google.common.util.concurrent.SettableFuture@9c66ab1}):        Output file: C:\Dev\biff\HandyApp\platforms\android\build\intermediates\res\merged\F0F1F2F3\debug\drawable-xhdpi-v4\notify_panel_notification_icon_bg.png
15:25:01.118 [DEBUG] [org.gradle.api.internal.tasks.execution.ExecuteAtMostOnceTaskExecuter] Finished executing task ':mergeF0F1F2F3DebugResources'
15:25:01.119 [DEBUG] [org.gradle.api.Project] AAPT(QueuedJob{
title=Cruncher notify_panel_notification_icon_bg.png,
task={from=C:\Dev\biff\HandyApp\platforms\android\build\intermediates\exploded-aar\com.android.support\appcompat-v7\26.0.0-alpha1\res\drawable-xhdpi-v4\notify_panel_notification_icon_bg.png, to=C:\Dev\biff\HandyApp\platforms\android\build\intermediates\res\merged\F0F1F2F3\debug\drawable-xhdpi-v4\notify_panel_notification_icon_bg.png},
future=com.google.common.util.concurrent.SettableFuture@9c66ab1}) discarded:     Output file: C:\Dev\biff\HandyApp\platforms\android\build\intermediates\res\merged\F0F1F2F3\debug\drawable-xhdpi-v4\notify_panel_notification_icon_bg.png
15:25:01.119 [DEBUG] [org.gradle.api.Project] AAPT out(Facade for 1223856843): Done
15:25:01.119 [DEBUG] [org.gradle.api.Project] AAPT out(Facade for 1223856843): -> QueuedJob{
title=Cruncher notify_panel_notification_icon_bg.png,
task={from=C:\Dev\biff\HandyApp\platforms\android\build\intermediates\exploded-aar\com.android.support\appcompat-v7\26.0.0-alpha1\res\drawable-xhdpi-v4\notify_panel_notification_icon_bg.png, to=C:\Dev\biff\HandyApp\platforms\android\build\intermediates\res\merged\F0F1F2F3\debug\drawable-xhdpi-v4\notify_panel_notification_icon_bg.png},
future=com.google.common.util.concurrent.SettableFuture@9c66ab1}
15:25:01.119 [DEBUG] [org.gradle.api.Project] AAPT notify(QueuedJob{
title=Cruncher notify_panel_notification_icon_bg.png,
task={from=C:\Dev\biff\HandyApp\platforms\android\build\intermediates\exploded-aar\com.android.support\appcompat-v7\26.0.0-alpha1\res\drawable-xhdpi-v4\notify_panel_notification_icon_bg.png, to=C:\Dev\biff\HandyApp\platforms\android\build\intermediates\res\merged\F0F1F2F3\debug\drawable-xhdpi-v4\notify_panel_notification_icon_bg.png},
future=com.google.common.util.concurrent.SettableFuture@9c66ab1}): Done
15:25:01.119 [LIFECYCLE] [class org.gradle.internal.buildevents.TaskExecutionLogger] :mergeF0F1F2F3DebugResources FAILED
15:25:01.119 [INFO] [org.gradle.execution.taskgraph.AbstractTaskPlanExecutor] :mergeF0F1F2F3DebugResources (Thread[Daemon worker Thread 2,5,main]) completed. Took 7.194 secs.
15:25:01.119 [DEBUG] [org.gradle.internal.operations.DefaultBuildOperationWorkerRegistry] Worker root.45 completed (0 in use)
15:25:01.119 [DEBUG] [org.gradle.execution.taskgraph.AbstractTaskPlanExecutor] Task worker [Thread[Daemon worker Thread 2,5,main]] finished, busy: 26.976 secs, idle: 0.069 secs
15:25:01.123 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]
15:25:01.123 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter] FAILURE: Build failed with an exception.
15:25:01.123 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]
15:25:01.123 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter] * What went wrong:
15:25:01.124 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter] Execution failed for task ':mergeF0F1F2F3DebugResources'.
15:25:01.126 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter] > Error: java.util.concurrent.ExecutionException: com.android.ide.common.process.ProcessException:
15:25:01.126 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]
15:25:01.126 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter] * Exception is:
15:25:01.127 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter] org.gradle.api.tasks.TaskExecutionException: Execution failed for task ':mergeF0F1F2F3DebugResources'.
15:25:01.127 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.executeActions(ExecuteActionsTaskExecuter.java:84)
15:25:01.127 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.execute(ExecuteActionsTaskExecuter.java:55)
15:25:01.127 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.api.internal.tasks.execution.SkipUpToDateTaskExecuter.execute(SkipUpToDateTaskExecuter.java:62)
15:25:01.127 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.api.internal.tasks.execution.ValidatingTaskExecuter.execute(ValidatingTaskExecuter.java:58)
15:25:01.127 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.api.internal.tasks.execution.SkipEmptySourceFilesTaskExecuter.execute(SkipEmptySourceFilesTaskExecuter.java:88)
15:25:01.127 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.api.internal.tasks.execution.ResolveTaskArtifactStateTaskExecuter.execute(ResolveTaskArtifactStateTaskExecuter.java:46)
15:25:01.127 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.api.internal.tasks.execution.SkipTaskWithNoActionsExecuter.execute(SkipTaskWithNoActionsExecuter.java:51)
15:25:01.127 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.api.internal.tasks.execution.SkipOnlyIfTaskExecuter.execute(SkipOnlyIfTaskExecuter.java:54)
15:25:01.127 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.api.internal.tasks.execution.ExecuteAtMostOnceTaskExecuter.execute(ExecuteAtMostOnceTaskExecuter.java:43)
15:25:01.128 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.api.internal.tasks.execution.CatchExceptionTaskExecuter.execute(CatchExceptionTaskExecuter.java:34)
15:25:01.128 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.execution.taskgraph.DefaultTaskGraphExecuter$EventFiringTaskWorker$1.execute(DefaultTaskGraphExecuter.java:236)
15:25:01.128 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.execution.taskgraph.DefaultTaskGraphExecuter$EventFiringTaskWorker$1.execute(DefaultTaskGraphExecuter.java:228)
15:25:01.128 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.internal.Transformers$4.transform(Transformers.java:169)
15:25:01.128 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.internal.progress.DefaultBuildOperationExecutor.run(DefaultBuildOperationExecutor.java:106)
15:25:01.128 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.internal.progress.DefaultBuildOperationExecutor.run(DefaultBuildOperationExecutor.java:61)
15:25:01.128 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.execution.taskgraph.DefaultTaskGraphExecuter$EventFiringTaskWorker.execute(DefaultTaskGraphExecuter.java:228)
15:25:01.128 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.execution.taskgraph.DefaultTaskGraphExecuter$EventFiringTaskWorker.execute(DefaultTaskGraphExecuter.java:215)
15:25:01.128 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.execution.taskgraph.AbstractTaskPlanExecutor$TaskExecutorWorker.processTask(AbstractTaskPlanExecutor.java:77)
15:25:01.128 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.execution.taskgraph.AbstractTaskPlanExecutor$TaskExecutorWorker.run(AbstractTaskPlanExecutor.java:58)
15:25:01.128 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.execution.taskgraph.DefaultTaskPlanExecutor.process(DefaultTaskPlanExecutor.java:32)
15:25:01.128 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.execution.taskgraph.DefaultTaskGraphExecuter.execute(DefaultTaskGraphExecuter.java:113)
15:25:01.130 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.execution.SelectedTaskExecutionAction.execute(SelectedTaskExecutionAction.java:37)
15:25:01.130 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.execution.DefaultBuildExecuter.execute(DefaultBuildExecuter.java:37)
15:25:01.130 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.execution.DefaultBuildExecuter.access$000(DefaultBuildExecuter.java:23)
15:25:01.130 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.execution.DefaultBuildExecuter$1.proceed(DefaultBuildExecuter.java:43)
15:25:01.130 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.execution.DryRunBuildExecutionAction.execute(DryRunBuildExecutionAction.java:32)
15:25:01.130 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.execution.DefaultBuildExecuter.execute(DefaultBuildExecuter.java:37)
15:25:01.130 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.execution.DefaultBuildExecuter.execute(DefaultBuildExecuter.java:30)
15:25:01.131 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.initialization.DefaultGradleLauncher$3.execute(DefaultGradleLauncher.java:196)
15:25:01.131 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.initialization.DefaultGradleLauncher$3.execute(DefaultGradleLauncher.java:193)
15:25:01.131 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.internal.Transformers$4.transform(Transformers.java:169)
15:25:01.131 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.internal.progress.DefaultBuildOperationExecutor.run(DefaultBuildOperationExecutor.java:106)
15:25:01.131 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.internal.progress.DefaultBuildOperationExecutor.run(DefaultBuildOperationExecutor.java:56)
15:25:01.131 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.initialization.DefaultGradleLauncher.doBuildStages(DefaultGradleLauncher.java:193)
15:25:01.131 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.initialization.DefaultGradleLauncher.doBuild(DefaultGradleLauncher.java:119)
15:25:01.131 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.initialization.DefaultGradleLauncher.run(DefaultGradleLauncher.java:102)
15:25:01.131 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.launcher.exec.GradleBuildController.run(GradleBuildController.java:71)
15:25:01.131 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.tooling.internal.provider.ExecuteBuildActionRunner.run(ExecuteBuildActionRunner.java:28)
15:25:01.131 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.launcher.exec.ChainingBuildActionRunner.run(ChainingBuildActionRunner.java:35)
15:25:01.132 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.launcher.exec.InProcessBuildActionExecuter.execute(InProcessBuildActionExecuter.java:41)
15:25:01.132 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.launcher.exec.InProcessBuildActionExecuter.execute(InProcessBuildActionExecuter.java:26)
15:25:01.132 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.tooling.internal.provider.ContinuousBuildActionExecuter.execute(ContinuousBuildActionExecuter.java:75)
15:25:01.132 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.tooling.internal.provider.ContinuousBuildActionExecuter.execute(ContinuousBuildActionExecuter.java:49)
15:25:01.132 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.tooling.internal.provider.ServicesSetupBuildActionExecuter.execute(ServicesSetupBuildActionExecuter.java:44)
15:25:01.132 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.tooling.internal.provider.ServicesSetupBuildActionExecuter.execute(ServicesSetupBuildActionExecuter.java:29)
15:25:01.132 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.launcher.daemon.server.exec.ExecuteBuild.doBuild(ExecuteBuild.java:67)
15:25:01.132 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.launcher.daemon.server.exec.BuildCommandOnly.execute(BuildCommandOnly.java:36)
15:25:01.132 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.launcher.daemon.server.api.DaemonCommandExecution.proceed(DaemonCommandExecution.java:120)
15:25:01.132 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.launcher.daemon.server.exec.WatchForDisconnection.execute(WatchForDisconnection.java:47)
15:25:01.132 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.launcher.daemon.server.api.DaemonCommandExecution.proceed(DaemonCommandExecution.java:120)
15:25:01.132 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.launcher.daemon.server.exec.ResetDeprecationLogger.execute(ResetDeprecationLogger.java:26)
15:25:01.132 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.launcher.daemon.server.api.DaemonCommandExecution.proceed(DaemonCommandExecution.java:120)
15:25:01.132 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.launcher.daemon.server.exec.RequestStopIfSingleUsedDaemon.execute(RequestStopIfSingleUsedDaemon.java:34)
15:25:01.132 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.launcher.daemon.server.api.DaemonCommandExecution.proceed(DaemonCommandExecution.java:120)
15:25:01.133 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.launcher.daemon.server.exec.ForwardClientInput$2.call(ForwardClientInput.java:74)
15:25:01.133 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.launcher.daemon.server.exec.ForwardClientInput$2.call(ForwardClientInput.java:72)
15:25:01.133 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.util.Swapper.swap(Swapper.java:38)
15:25:01.133 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.launcher.daemon.server.exec.ForwardClientInput.execute(ForwardClientInput.java:72)
15:25:01.133 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.launcher.daemon.server.api.DaemonCommandExecution.proceed(DaemonCommandExecution.java:120)
15:25:01.133 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.launcher.daemon.server.exec.LogAndCheckHealth.execute(LogAndCheckHealth.java:55)
15:25:01.133 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.launcher.daemon.server.api.DaemonCommandExecution.proceed(DaemonCommandExecution.java:120)
15:25:01.133 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.launcher.daemon.server.exec.LogToClient.doBuild(LogToClient.java:60)
15:25:01.133 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.launcher.daemon.server.exec.BuildCommandOnly.execute(BuildCommandOnly.java:36)
15:25:01.133 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.launcher.daemon.server.api.DaemonCommandExecution.proceed(DaemonCommandExecution.java:120)
15:25:01.133 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.launcher.daemon.server.exec.EstablishBuildEnvironment.doBuild(EstablishBuildEnvironment.java:72)
15:25:01.133 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.launcher.daemon.server.exec.BuildCommandOnly.execute(BuildCommandOnly.java:36)
15:25:01.133 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.launcher.daemon.server.api.DaemonCommandExecution.proceed(DaemonCommandExecution.java:120)
15:25:01.133 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.launcher.daemon.server.exec.StartBuildOrRespondWithBusy$1.run(StartBuildOrRespondWithBusy.java:50)
15:25:01.134 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.launcher.daemon.server.DaemonStateCoordinator$1.run(DaemonStateCoordinator.java:297)
15:25:01.134 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.internal.concurrent.ExecutorPolicy$CatchAndRecordFailures.onExecute(ExecutorPolicy.java:54)
...
15:25:01.134 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.internal.reflect.JavaMethod.invoke(JavaMethod.java:73)
15:25:01.134 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.api.internal.project.taskfactory.DefaultTaskClassInfoStore$IncrementalTaskAction.doExecute(DefaultTaskClassInfoStore.java:163)
15:25:01.134 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.api.internal.project.taskfactory.DefaultTaskClassInfoStore$StandardTaskAction.execute(DefaultTaskClassInfoStore.java:134)
15:25:01.134 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.api.internal.project.taskfactory.DefaultTaskClassInfoStore$StandardTaskAction.execute(DefaultTaskClassInfoStore.java:123)
15:25:01.134 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.executeAction(ExecuteActionsTaskExecuter.java:95)
15:25:01.134 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.executeActions(ExecuteActionsTaskExecuter.java:76)
15:25:01.134 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   ... 70 more
15:25:01.135 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter] Caused by: Error: java.util.concurrent.ExecutionException: com.android.ide.common.process.ProcessException:
15:25:01.135 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at com.android.ide.common.res2.MergedResourceWriter.end(MergedResourceWriter.java:268)
15:25:01.135 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at com.android.ide.common.res2.DataMerger.mergeData(DataMerger.java:301)
15:25:01.135 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at com.android.ide.common.res2.ResourceMerger.mergeData(ResourceMerger.java:410)
15:25:01.135 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at com.android.build.gradle.tasks.MergeResources.doFullTaskAction(MergeResources.java:154)
15:25:01.135 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   ... 77 more
15:25:01.135 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter] Caused by: java.util.concurrent.ExecutionException: java.util.concurrent.ExecutionException: com.android.ide.common.process.ProcessException:
15:25:01.135 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at com.google.common.util.concurrent.AbstractFuture$Sync.getValue(AbstractFuture.java:299)
15:25:01.135 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at com.google.common.util.concurrent.AbstractFuture$Sync.get(AbstractFuture.java:286)
15:25:01.135 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at com.google.common.util.concurrent.AbstractFuture.get(AbstractFuture.java:116)
15:25:01.135 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at com.android.ide.common.res2.MergedResourceWriter.end(MergedResourceWriter.java:264)
15:25:01.135 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   ... 80 more
15:25:01.135 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter] Caused by: java.util.concurrent.ExecutionException: com.android.ide.common.process.ProcessException:
15:25:01.135 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at com.google.common.util.concurrent.AbstractFuture$Sync.getValue(AbstractFuture.java:299)
15:25:01.136 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at com.google.common.util.concurrent.AbstractFuture$Sync.get(AbstractFuture.java:286)
15:25:01.136 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at com.google.common.util.concurrent.AbstractFuture.get(AbstractFuture.java:116)
15:25:01.136 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at com.android.builder.internal.aapt.v1.AaptV1.lambda$compile$0(AaptV1.java:446)
15:25:01.136 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter] Caused by: com.android.ide.common.process.ProcessException:
15:25:01.136 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at com.android.builder.png.AaptProcess$NotifierProcessOutput.out(AaptProcess.java:284)
15:25:01.136 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at com.android.builder.png.AaptProcess$ProcessOutputFacade.out(AaptProcess.java:215)
15:25:01.136 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]   at com.android.utils.GrabProcessOutput$2.run(GrabProcessOutput.java:143)
15:25:01.136 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter]
15:25:01.136 [LIFECYCLE] [org.gradle.internal.buildevents.BuildResultLogger]
15:25:01.136 [LIFECYCLE] [org.gradle.internal.buildevents.BuildResultLogger] BUILD FAILED
15:25:01.136 [LIFECYCLE] [org.gradle.internal.buildevents.BuildResultLogger]

Comment: You can't have jpg file inside the drawable folder
Comment: I meant png, edited it, ofc you are right :D
Comment: Hit this command in terminal of AS and check ERROR tag in buildLog.txt  `./gradlew ::mergeF0F1F2F3DebugResources --debug > buildLog.txt --stacktrace`
Comment: @nitinkumarp android studio is not used when building NativeScript applications, all I use is the running emulator. Is this still working then?
Comment:  is the name you see on Project tab in AS where your main source code reside.
Comment: Hit the above command from the root directory of your Project folder.  would be the name of the directory where you have Main project src. Suppose your main src have directory name "app" then the command would be: `./gradlew :app:mergeF0F1F2F3DebugResources --debug > buildLog.txt --stacktrace`
Comment: I cannot execute the /gradlew - command since my terminal cannot find that command. Is that a windows thing (that he does not find the command) or did I miss something on the installation? Still I ran it with a --log trace and posted an update, perhaps that is what you looked for?
Answer: If the drawable-hdpi contains png files keep the same format in all files. This error is due to you have the same file with a different extension in the same folder. Check the resource files.
Comment: NativeScript applications are not developed inside Android Studio.
Comment: @KrunalKapadiya So you mean that I have two different pictures with the same name in my directory where the metadata are not the same? But if I check it there is only one picture for every name and I already tried cleaning the cache and readding the platform/rebuilding the project. What else could I try?
Comment: Readd the android platform, see if that helps.
Comment: @pkanev I already tried that, the outcome did not change. I also tried with another android Version
Comment: is it possible, that the Manifest compares the image with some other metadata? Since the pictures are the launchscreen and the app-icon.
Answer: You want to delete all the cache of your previous builds from your project directory. This is common issue when changing image resources.
Although as @Vodet said, drawable folder works with .png and .xml resources, not .jpg. So if you necessarily want to use a .jpg resource, you want to make an assets folder at the same level as res folder in the project directory hierarchy and load .jpg from there. See this question for more detail.
Comment: You are right, i mean't a .png instead of a .jpg, my fault. I edited my question and described what I did.
Comment: I updated the error message, there seems to be a cache in the .gradle folder, but that pictures have nothing to do with my icons (at least that's what I see). I removed the .gradle folder but the outcome did not change. Can I clear the cache on another way?


android insists i don't have a column in my database table

Question: i can't figure out this strange error while i try to insert value into database
ERROR
01-01 15:48:56.065  10056-10056/com.autophone E/SQLiteLog﹕ (1) table mainTable has no column named status_date
01-01 15:48:56.100  10056-10056/com.autophone E/SQLiteDatabase﹕ Error inserting status_date=1 בינו 2000 15:48:56 problem=non model=N9005 phone_number=123 in_date=1 בינו 2000 15:48:56 status=received name=ian
    android.database.sqlite.SQLiteException: table mainTable has no column named status_date (code 1): , while compiling: INSERT INTO mainTable(status_date,problem,model,phone_number,in_date,status,name) VALUES (?,?,?,?,?,?,?)

the main point it says i don't have "status_date" in the main table
but how is it possible?
  public static final String KEY_ROWID = "_id";
    public static final int COL_ROWID = 0;

    private static final String KEY_NAME = "name";//1
    private static final String KEY_MODEL = "model";//2
    private static final String KEY_PHONE_NUMBER = "phone_number";//3
    private static final String KEY_PROBLEM = "problem";//4
    private static final String KEY_STATUS = "status";//5
    private static final String KEY_IN_DATE = "in_date";//6
    private static final String KEY_STATUS_DATE = "status_date";//7

    public static final String DATABASE_NAME = "MyDb";
    public static final String DATABASE_TABLE = "mainTable";
    public static final int DATABASE_VERSION = 1;

    private static final String DATABASE_CREATE_SQL =
            "create table " + DATABASE_TABLE
                    + " (" + KEY_ROWID + " integer primary key autoincrement, "
                    + KEY_NAME + " text not null, "
                    + KEY_MODEL + " text not null, "
                    + KEY_PHONE_NUMBER + " text not null, "
                    + KEY_PROBLEM + "text not null, "
                    + KEY_STATUS + "text not null, "
                    + KEY_IN_DATE + "text not null, "
                    + KEY_STATUS_DATE + "text not null "
                    +");";

here it is...
this is the enter part
 long newID=myDB.insertRow(new LogEntery("ian","N9005","123","non"));

logentery is a class i use that also adds the rest for the data
public LogEntery(String name,String model,String phone_number,String problem)
    {
        super();
        this.name=name;
        this.model=model;
        this.phone_number=phone_number;
        this.problem=problem;
        this.in_date = DateFormat.getDateTimeInstance().format(new Date());
        this.status_date = DateFormat.getDateTimeInstance().format(new Date());
        this.status = "received";
    }

by the way... how do i change getDateTimeInstance to get DD/MM/YYYY only and not the full data/time?
Answer: A common source of error is the database version.
If you ran your app at least once without the KEY_STATUS_DATE field in your table, and then added that field and ran your app, the table won't be updated (onUpgrade() will not be called), because the system thinks that the database hasn't changed.
Try raising the version.
public static final int DATABASE_VERSION = 2;

With this, the system will think "Oh, there's a new version of the database, let's call onUpgrade()". Ideally from this method, you delete your tables an call onCreate(SQLiteDatabase db) manually, or execute some DDL statements to add the missing field.
Answer: You can check your database in your phone to see if it is real that no column named  status_date.
Solution to your "by the way":
SimpleDateFormat dateFormatGmt = new SimpleDateFormat("dd/MM/yyyy");
String dateString = dateFormatGmt.format(new Date());
Answer: My advice would be to start with a basic schema that works, then write your abstraction layer. I'd take a step back and make sure that all of the assumptions are correct.
For example, there are 4 arguments to your constructor, while there are 8 columns in your table and 7 setters being called in the constructor. Looks like you might just be off-by-one, at a glance. If not, its still a little confusing. I'd either require all parameters for the statement in the constructor, or mark the optional fields in some way (i.e. overloaded method calls with a no-args constructor, etc).
Hope my input is helpful.
Brandon


Is it possible to learn/separate this data?

Question: I have a highly imbalanced (~0.4% minority class) binary classification dataset of time series (flux) observations, and am now at a loss on how to classify it, as the data aren't separable. Here's what the data look like, both originally and with SMOTE oversampling.

I have tried SVM, KNN, RF, ANN, and CNN. SVM, KNN, ANN, and CNN produce similar results—classifying both training classes correctly about 60% of the time, but only classifying the test minority class correctly 1-2% of the time. RF overfits with 100% training accuracy/recall/precision, but the same results on the test data. I get these results regardless of the resampling technique I use on the training data.
Is it possible to do better than this, i.e., classify the minority class more than 2% of the time on unseen data? The classes pretty much overlap, so is there a way to separate them? I've seen some threads mentioning probability calibration, which I am familiar with. Is this something worth trying out even though I am only predicting class labels?
Comment: 0. Welcome to CV.SE. 1. You show the PCA projections, maybe there are other projections that suggest a better separability, (e.g.t-SNE or UMAP) but importantly your minority samples appear to significantly overlap so it is very hard to recognise any decision boundary. 2. Doing EDA and using your own subject matter expertise, can you distinguish between the two classes? Maybe there is a feature engineering step you could do that would really help the classification task.
Answer: I suspect that there is little you can do here as there isn't enough data of the minority class to properly characterise the underlying distribution.  One of the problems with SMOTE is that the way the synthetic data are constructed generates spurious structure in the data (for instance the hole centred around  comp-1 = 0 and comp-2 = -2).  For this reason, make sure you perform evaluation using the original data distribution, not the SMOTEd data as the latter will reward learning of this spurious structure.  Another spurious structure that SMOTE creates is that all synthetic patterns will lie within the convex hull of the original data, which creates the straight, very defined boundaries, when in practice, there would be some chance of minority patterns beyond that boundary if sampled from the true data generating process.  SMOTE is a sensible sounding heuristic, but it is far from ideal.
Class imbalance generally isn't a problem unless you have very little data, and SMOTE is unlikely to improve performance in most cases.  Unfortunately where there is very little data, learning algorithms can demonstrate an undue bias against the minority class and in principle SMOTE can help, but if you have that little data there will be no way to determine the optimal amount of resampling to apply to correct that bias.


how to see error logs in django view when not returning a view

Question: I am doing an ajax post to a django view.  Since I am not returning a page but data to my ajax call back, I do not get a stack trace.  How do I print my errors in the view?
The error is happening when I do a save if that helps.
Answer: If you're using jQuery:
<code>$.ajax({
    // ...
    error: function(jqXHR, textStatus, errorThrown) {
        console.log(errorThrown);
    }
});
</code>


Compare treatment effects between groups - 2x2x2 ANOVA does not work?

Question: I'm working on a psychology thesis where I have fours groups (2 dichotomous variables).
I want to prove that the difference between treatment and control is larger in one group compared to the other three groups (the outcome variable in continuous). A 2x2x2 (var1 x var2 x treatment/control) ANOVA will not work (in my understanding) since it will only show that one/more of the eight groups differ compared to the other groups. Or is it actually the case that the interaction term(s) will capture the difference that I want to prove exists? Any help is much appreciated!
Answer: First, you should cross the grouping variables to make one 4-level group variable. Then run a two-way 4x2 ANOVA with treatment. If the interaction is significant, that means the treatment effect depends on group. To figure out whether the specific differences that you are interested in testing exist, you need to use contrasts.
To answer the question of the whether the treatment effect is larger in one group vs. all the other groups combined, you will create contrasts that allow you to perform a 1-df test comparing the difference between treatment and control in the focal group and the average of the differences between treatment and control in the other groups. To answer the question of whether the treatment effect is larger in the focal group than in each of the other groups, you will need to perform three 1-df tests that compare the difference between treatment and control in the focal group to the difference between the treatment and control in each other group.
Depending on the software you're using, it might be more straightforward to use the following procedure to perform these tests. First, cross the treatment and group variables to create an 8-level condition variable. You can then run a oneway ANOVA with this variable. From within the ANOVA, you can specify the specific contrasts easily. If levels of your new variable are
A1|B1|T A1|B2|T A2|B1|T A2|B2|T A1|B1|C A1|B2|C A2|B1|C A2|B2|C

where A and B are the two grouping variables and 1 and 2 are the levels of each, and T is treatment and C is control, you can specify the contrast matrix as follows to answer the question of whether the treatment effect in the focal group (we'll say it's A1|B1) differs from that in the other groups combined:
 [1, -1/3, -1/3, -1/3, -1, 1/3, 1/3, 1/3]

To specify the contrast matrix to test whether the treatment effect in the focal group differs from that in each other group, you would use the following:
 [1, -1, 0, 0, -1, 1, 0, 0]

This contrasts tests whether the treatment effect differs between A1|B1 and A1|B2. You can adjust the contrasts to run the other two tests.
Comment: Perfect, thanks! Is there any litterature that describes this that I can cite? Any suggestions how I do this in either Stata or R? Also, I've seen that log odds-ratios sometimes are used. What is the difference (pros/cons) between this contrast and log-OR (or other common approaches). Just in case my professor asks why I choosed this method and what altertnatives there are. Thanks again for the quick answer!!
Comment: These are fundamental ANOVA techniques, so you could find them in a textbook aimed at first-year graduate students in psychology. I would recommend looking up a textbook that focuses on ANOVA in R or Stata. Log-ORs are for binary *outcomes* and the choice of whether to use them is unrelated to everything I've said here. If you have binary outcomes you should not be using ANOVA.
Answer: I ended up using anovacontrast in Stata (needs to be installed). Here is the code:
capture drop x
egen x = group(x1 x2 x3), label

table x, contents(mean y)

anova y x
anovacontrast x, values(-1 1   3 -3  -1  1  -1  1)
anovacontrast x, values( 0 0   1 -1  -1  1   0  0)
anovacontrast x, values(-1 1   1 -1   0  0   0  0)
anovacontrast x, values( 0 0   1 -1   0  0   1 -1)

This worked for me.


Getting a "FileNotFoundException: /var/lib/h2/data/odp.mv.db (Permission denied)"" when deploying a JHipster project onto Kubernetes

Question: I am trying to deploy my Jhipster (v5.5.0) project onto Kubernetes (v1.16.3), but the pod keeps failing on an attempt to read the database. I assume its because the /var/lib/h2/data directory is not allowing the user read/write access
Here is my YAML that will create the deployment / pod. I have another YAML that creates the PV and PVC.
apiVersion: apps/v1
kind: Deployment
metadata:
  name: portal
spec:
  replicas: 1
  strategy:
    type: RollingUpdate
    rollingUpdate:
      maxUnavailable: 25%
      maxSurge: 25%
  template:
    spec:
      containers:
        - name: portal
          # for argoCD
          image: xxxx.xxxx.com/appliances/kubernetes/portal:temp-test-17
          envFrom:
            - configMapRef:
                name: portal-config
          # NOTE: the ports.protocol used to be set to TCP, in okd yaml. TCP is the default, so we no longer set it.
          ports:
          - name: http
            containerPort: 8080
          - name: https
            containerPort: 8443
          # resources:
          #   requests:
          #     cpu: 1
          #     memory: 1Gi
          #   limits:
          #     memory: 4Gi
          resources:
            limits:
              cpu: "0.5"
              memory: "2048Mi"
            requests:
              cpu: "0.1"
              memory: "64Mi"
          # an image pull policy of IfNotPresent is useful when docker is less available, but requires updating tags during development more often. Originally was "Always"
          imagePullPolicy: IfNotPresent
          volumeMounts:
            # NOTE: if we use SSL, we will need a 'keystores' volume mount
            # - mountPath: /var/run/secrets/java.io/keystores
            #   name: keystore-volume
            # Volume mount for the database files. Stored on a PV so we can upgrade without removing stored DB data.
            - mountPath: /var/lib/h2/data
              name: portal-db-vol01

          # DEBUG USE ONLY - run as root with elevated permissions.
          securityContext:
            # allowPrivilegeEscalation: true
            # capabilities: {}
            # privileged: false
            runAsNonRoot: true
            runAsUser: 950

      imagePullSecrets:
        - name: regcred-nexus

     # Monitor for future clean deployment: make sure it doesnt create 2 pvcs
      volumes:
      - name: xxx-db-vol01
        persistentVolumeClaim:
          claimName: xxxx-db-pvc-volume01
      # terminationGracePeriodSeconds - we allow 30 seconds for DB cleanup
      terminationGracePeriodSeconds: 30

Here's the error:
Caused by: java.lang.IllegalStateException: Could not open file nio:/var/lib/h2/data/odp.mv.db [1.4.200/1]
    at org.h2.mvstore.DataUtils.newIllegalStateException(DataUtils.java:950)
    at org.h2.mvstore.FileStore.open(FileStore.java:179)
    at org.h2.mvstore.MVStore.<init>(MVStore.java:381)
    at org.h2.mvstore.MVStore$Builder.open(MVStore.java:3579)
    at org.h2.mvstore.db.MVTableEngine$Store.open(MVTableEngine.java:170)
    ... 51 common frames omitted
Caused by: java.io.FileNotFoundException: /var/lib/h2/data/odp.mv.db (Permission denied)
    at java.io.RandomAccessFile.open0(Native Method)
    at java.io.RandomAccessFile.open(RandomAccessFile.java:316)
    at java.io.RandomAccessFile.<init>(RandomAccessFile.java:243)
    at java.io.RandomAccessFile.<init>(RandomAccessFile.java:124)
    at org.h2.store.fs.FileNio.<init>(FilePathNio.java:43)
    at org.h2.store.fs.FilePathNio.open(FilePathNio.java:23)
    at org.h2.mvstore.FileStore.open(FileStore.java:153)
    ... 54 common frames omitted

And here's something I threw into the Dockerfile in order to force this to work, but it seems like the .../h2/data directory is not getting the right permissions
USER root

RUN mkdir -p /var/lib/h2/data
RUN chmod -R 777 /var/lib/h2

RUN useradd -d /home/user -m -s /bin/bash user
USER user

Answer: Change your /var/lib/h2/data to something like /usr/share/..., and make sure your image has more permissions on /var/lib (such as 777)

Getting a “FileNotFoundException: /var/lib/h2/data/odp.mv.db (Permission denied)“” when deploying a JHipster project onto Kubernetes


Don't know Server Name

Question: I just installed SQL management studio to my computer. It opened up with window Connect to Server. What I shall write in Server Name part?
I have just started to study SQL. Where i can find Server Name?
Answer: If you only installed Management Studio then there is no server to connect to.  You need to install the server part also.  After doing that, the server name would be the same as the computer name (assuming you chose the default options).
Here's a longer explanation:  The server part and the client part are two separate pieces.  Management Studio is the client part.  It connects to the server part, which can be on the same computer, or a different computer.  Microsoft offers the Management Studio as a separate download, and it sounds like that is what you installed.  You can also download a package that has both the server and the Management Studio in one installation package.  You should download and install that one if you want to install both the server and the client on your computer.
Answer: Open Windows Command Processor and type hostname you will come across Server Name.  Server Name means name of your computer.
Comment: No, server name is the host name of the server hosting the SQL database.  It's only the same as hostname of the machine you're on if you're logged onto the server itself.  Generally, especially in enterprise situations, the server is in a rack in a datacenter and the administrator is in a cube in a different building/city/country/continent logging into a workstation and connecting to the database over the network.  You don't REALLY want an admin surfing the internet on the same machine that runs the database that is usually the core of a business app, do you?

Don't know Server Name


getTimestamp() does timezone converstion twice in MySQL JDBC connector?

Question: I have a column of type DATETIME wiht a value of 2012-05-07 19:59:12 in MySQL database. I'm trying to retrieve this value from DB, assuming that it's stored in UTC timezone:
Calendar cal = Calendar.getInstance(new SimpleTimeZone(0, "UTC"));
Date date = resultSet.getTimestamp(1, cal);
System.out.println(date);

It outputs (CEST is my local timezone, which is 2 hours ahead of UTC):
Mon May 07 23:59:12 CEST 2012

Expected value is:
Mon May 07 21:59:12 CEST 2012

I'm using these three params in JDBC URL (Europe/Berlin is the same as CEST):
..&useGmtMillisForDatetimes=true&useTimezone=true&serverTimezone=Europe/Berlin

Is it my defect or something should be configured additionally in the JDBC driver? I'm using mysql:mysql-connector-java:5.1.20.
Comment: I think that you're making this a bit more complex than it needs to be. JDBC supports retrieving a timestamp with a calendar for when the database does not support timezones. MySQL does, so this is unnecessary. You can (probably) forget about all of the custom settings on the jdbc url too. Just use getDate(), and you will get a java.util.Date, which is timezone independent until you format it with a specific timezone.
Comment: Well, this is how it works: `&useGmtMillisForDatetimes=true&useJDBCCompliantTimezoneShift=true&useLegacyDatetimeCode=false&useTimezone=true&serverTimezone=UTC`, but thanks for your suggestion, I'll give it a try
Answer: With these JDBC URL params it works:
useGmtMillisForDatetimes=true
useJDBCCompliantTimezoneShift=true
useLegacyDatetimeCode=false
useTimezone=true
serverTimezone=UTC

Comment: Great answer, worked perfectly for me.  Note: you have two (invisible) 0x00 characters between 'useLegacy' and 'DatetimeCode' which means this WONT work if someone copy-pastes it into a properties file.  I did this and it was awfully tough to track down.  Just in case anybody else tries this.
Comment: MySQL connector [reference](http://dev.mysql.com/doc/connector-j/en/connector-j-reference-configuration-properties.html) says that properties `useJDBCCompliantTimezoneShift` and `useTimezone` are mutually exclusive. I am successfully using `useTimezone=false`.
Comment: there were still invisible characters... now fixed!!
Comment: And useLegacyDatetimeCode=false disables effect of useTimezone, useJDBCCompliantTimezoneShift and useGmtMillisForDatetimes, so the only option needed is serverTimezone.
Comment: @RandyRizun Ha, ha. There is a `\u200c ZERO WIDTH NON-JOINER`
Answer: This is from documentation on Connector/J 8.0.32 - Preserving Time Instants :

Use preserveInstants=true&connectionTimeZone=SERVER
This setting corresponds to the default behavior of Connector/J 8.0.22 and before and to the behavior of Connector/J 5.1 with useLegacyDatetimeCode=false.

I would suggest to follow that advice, remove useTimezone=true and serverTimezone, and then,

for Connector/J 5.1 add useLegacyDatetimeCode=false,
for 8.0.22 and before no additional change,
for 8.0.23 add preserveInstants=true and connectionTimeZone=SERVER

so for your case with 5.1 (old posting), this would become
useLegacyDatetimeCode=false

or for 8.0.23
preserveInstants=true
connectionTimeZone=SERVER

Also consider keeping your useGmtMillisForDatetimes=true, not sure why it was needed, but otherwise I have removed all other timezone related properties.


HTML5 & placeholder: how to do it progressively?

Question: I'm thinking about using HTML5's placeholder attribute. If the browser doesn't support HTML5, I can use jQuery as a fallback. However, what if JS is turned off? How do I handle this using the progressive enhancement philosophy?
Comment: Since you've said in a comment below that you don't like the semantics of using a `placeholder` to label an `input` (as is currently trendy, à la the Stack Overflow search bar), even dynamically, I guess it's safe to assume that you're looking to use placeholders for something else. What exactly is your intended use for them?
Answer: Why don't you show an actual  element and hide it with js?
// js file
$('label').hide();

That way, without js, they'll see a regular label; with js, the label will be removed and you'll get either your jquery placeholder, or your html5 placeholder.
Comment: @mozillanerd - I beg to differ. The whole point of this answer is that it produces something useful whether JS is available or not.
Comment: This is the only way of doing this that I can think of that's really doing "progressive enhancement." I'd modify this slightly so that your JavaScript code, instead of just hiding the label, dynamically created a `placeholder` from the `label` text, so it won't have to be duplicated in the HTML source.
Comment: Well, you're not removing the label, you're hiding it. So, semantically, you're ok. and screen readers will get the label as well.
Comment: @mozillanerd - could you explain why you don't think this is a good rec?
Comment: It's not bad semantically, it's just that it's a compromise. This is for the "What if we can't use a placeholder?" scenario, so there may be an actual (semantic) label and then we're just adding another with the hint that would go in the placeholder if placeholder was supported.
Comment: Yes, it's semantic. Semantics is about using structural elements within the structure of your document that accurately define the contents of your document. In this answer, you're using a `` to "label" your input element - you can't get much more semantic than that. The reason the spec says not to use the placeholder as an alternative to a label is because there is not "structural" advantage of a placeholder; it's an attribute. The question asked how to use progressive enhancement to take advantage of html5 placeholder when available, then fallback to a js solution, then fallback again.


onMapReady function seems to not be called on android app

Question: The map seems to be created but the marker does not get placed. Most questions relating to this problem seems to be missing getmapasync but th,s one seems to have it
override fun onCreate(savedInstanceState: Bundle?) {
    super.onCreate(savedInstanceState)
    // Retrieve the content view that renders the map.
    setContentView(R.layout.fragment_dashboard)

    val mapFragment = supportFragmentManager.findFragmentById(R.id.map) as? SupportMapFragment
    mapFragment?.getMapAsync(this)
}
override fun onMapReady(googleMap: GoogleMap) {
    mMap = googleMap
    val sydney = LatLng(-33.852, 151.211)
    mMap.addMarker(
        MarkerOptions()
            .position(sydney)
            .title("Marker in Sydney")
    )
    // [START_EXCLUDE silent]
    mMap.moveCamera(CameraUpdateFactory.newLatLng(sydney))
    // [END_EXCLUDE]
}
// [END maps_marker_on_map_ready_add_marker]

Answer: Is your map fragment nested in a fragment?
If you are calling getMapAsync from a fragment that contains the actual map, you need to use childFragmentManager instead of supportFragmentManager to find the map
(childFragmentManager.findFragmentById(R.id.map) as SupportMapFragment).getMapAsync(this)
Comment: Tnx for the comment it is indeed that way but i still cant figure out a way to implement childFragmentManager
Comment: when i replace supportFragmentManager with childFragmentManager it cannot find a reference
Comment: What do you mean exactly by "implement childfragment manager"?


Discontinuous multiple selection for vListBox or HtmlListbox doesn't work on OS X in wxWidgets / wxPython

Question: I'm trying to create a cross-platform wxPython application which uses the HtmlListBox widget to list multiple multi-line items with formatting. It is working well on Ubuntu and Windows.
On OS X shift-click works to select multiple items in a row, but Command click does not work to select multiple discontinuous items; Control-click works fine on both Ubuntu and Windows.
I tried using a 32-bit Carbon build instead of the Cocoa build and that did work as expected (but had other problems). Command-click to select multiple discontinuous items does work in a normal ListBox widget on Cocoa builds, but I note neither VListBox nor HtmlListBox actually inherit ListBox, it seems.
No combination of LB_EXTENDED or LB_MULTIPLE flags seem to rectify this problem. I've confirmed it is the case in the HTML List example that ships in the latest wxWidgets (3.0). I also tried older 2.9 version builds and the problem was there too.
I found some old bug reports for similar problems but they seem resolved some years ago. I had a poke around in the wxWidgets source but didn't have much luck finding anything.
Is this a bug or am I missing something?
Answer: Looking at the sources I see that under Mac we use Apple-click and not Cmd-click for selecting individual items for some reason. I guess this is just a mistake, so I went ahead and fixed it.
Comment: Thanks! I built wxWidgets & wxPython with your fix and now it is working as intended (I'm on OS X Yosemite). :)
Comment: I just installed Phoenix via pip (snapshot build: https://wxpython.org/Phoenix/snapshot-builds/ wxPython_Phoenix) and this bug still seems to exist there.