What is the definition of a local property for a function? I came across this question while thinking about the question whether the integrability is a local property. I first thought that the MSE question What's the definition of a "local property"? addresses this issue, but this question only answers what a local property for a topological space and not for a function is. Thus, my question is:
What is the definition for a property to be a local property of a function?
My attempt: Najib Idrissi gives in his answer to the question What's the definition of a "local property"? the answer

A property $P$ is local when, for all spaces $X$, if $\{U_i\}$ is an open cover of $X$ and all the $U_i$ have $P$, then $X$ has $P$.

From this one may deduce that

A property $P$ is local for a function $f:X\to Y$, iff from the fact, that $\{U_i\}$ is an open cover of $X$ and all $f|_{U_i}$ have the property $P$, follows that also $f$ has the property $P$.

Is this the right definition?

Update: First I had the following wrong argumentation in my question as pointed out by Daniel Fischer in the comments. However, the main question remains...

However, this does not seem to be the right definition. Let $X$ be the long line which we get by pasting $[0,1)$ uncountable many times together. We define $g:X\to\mathbb R$ with $g(x)=\sin(2\pi x)$ on each interval $[0,1)$. As J. Loreaux argued in his answer to the question Does this intuition for "calculus-ish" continuity generalize to topological continuity?, the function $g$ is not continuous.
This contradicts the above attempt for a definition of a function's local property since there is an (uncountable) open cover $\{U_i\}$ of the long line $X$ for which all $g|_{U_i}$ are continuous (for example when all $U_i$ are bounded) and continuity is one of the properties I would see as being a local property.
Also the Wikipedia article "Local property" does only answer what a local property for topological spaces is. It defines the term "being locally equivalent", but this is not what I am looking for.
So: What is the definition of a local property for a function?

 A: To summarize the discussion in the comments: There are currently the following proposed definitions for saying that a property P is a local property of a function $f:X\to Y$:


*

*For any open cover $\{U_i\}$ $X$: All $f|_{U_i}$ have the property $P$, iff $f$ has the property $P$.

*Comment by user254665: $f$ has the property $P$, iff for every $x$ there is an open $U$ with $x\in U$ and $f|_U$ has the property $P$.

*Comment by Daniel Fischer: $P$ is a local property of $f$ in $x\in X$, iff $P$ is a property of the germ $[f]_x$ of $f$ in $x$. This means: If $f$ has the property $P$ in $x$ and $g$ coincide with $f$ in any neighborhood of $x$, then also $g$ has the property $P$ in $x$. 


(1) and (2) are equivalent since (2) is a reformulation of (1).
(1) does not imply (3) and vice versa. Take for example the property "$f$ is continuous". It fulfills (1) but not (3). Take on the over hand the property "$f$ is continuous in $x$". It fulfills (3) but not (1) since $f|U_i$ is only continuous in $x$ for $x\in U_i$.

Note that I have added the implication "$f$ has property $P$ $\Rightarrow$ all $f|_{U_i}$ have property $P$" in (1). 
