Delta entries fail to parse

Hi, thanks for this, I really like the API.
I'm using the longpoll_delta + delta combination, and hitting a JSON parsing error.  The Delta response model assumes that the entries is of type [string]; in fact (this might be new, looking at other implementations), it's a 2-element array of [string, metadata].
I have a patch I can try and clean up if you'd like, or you might have your own preferred way of handling it.

I've implemented a fix for this. I'll commit the changes as soon as I can.

Resolved with commit 91049cea1abb319b4077d5f8a476f1ecc6a5768b

Great, thanks!  I just came back to this to open a pull request, great timing (and that looks near-identical to my patch :)).  Thanks again.


always return flags when possible

...even if the cache file can't be written

/cc @phated for a sanity check. this should be totally backwards compatible with liftoff. once this lands and the world doesn't explode, i'll update liftoff to emit a warning about the failure to cache this file rather than bailing entirely.


github api throttles requests

github api throttles requests with or without a username/password...
solution may be to use oauth?  but may have the same issues with that.
could get the readme.md from the raw url, instead of API, would cut down requests about 30x from current load.

Maybe update the repo list only on explicit request/every 24h?

Maybe update the repo list only on explicit request/every 24h?

hm, good idea.... and since I want to serve this ultimately from IPFS / IPNS / dnslink... there is no server to cache the repo list... we could of course cache it in IPFS, especially with the recent (or soon) opening of write API... but I can't see how do do this writing to IPFS.  I could write a cache every 24 hours to IPNS, but that implies server/cron/etc, which I'm trying to avoid...  maybe CRDTs hold a possible answer, but I don't get that enough to go there, though I'm interested in learning...
any thoughts here @jbenet @whyrusleeping @diasdavid?

You could have a deploy script which pulls the repo list down and stores it in a file before you push to github

That sounds good... but don't want to have to push to github to update the repo list...
Sounds like some kind of cron would be needed, on CI or a heroku instance ... maybe (notes to self):

https://github.com/grosser/travis_cron
https://nightli.es/
http://tron-ci.herokuapp.com/
http://traviscron.pythonanywhere.com/

I am planning a fallback cascade:

Try to fetch the fresh repo list from github api anonymously.  Throttling is per IP address, so this should succeed most of the time, especially if we cut down the API calls from 31 to 1, which is easy.
Fall back on a repo list that we fetch and save as json at deploy time.  Ideally trigger a nighly build so this list is fairly fresh.

More info on rate limiting from https://developer.github.com/v3/#rate-limiting:

For requests using Basic Authentication or OAuth, you can make up to 5,000 requests per hour. For unauthenticated requests, the rate limit allows you to make up to 60 requests per hour.

Could you pull the repo list from the project-directory.md file in ipfs/ifps? That way we could include repositories that aren't in the IPFS organisation, too. And why wouldn't we pull directly from the raw URL for each repo?
Switching to OAuth or just using Basic Auth should work - are we doing more than 5k an hour?

Could you pull the repo list from the project-directory.md file in ipfs/ifps? That way we could include repositories that aren't in the IPFS organisation, too.

We could, certainly.  Not sure we want to though.  Are all repos we point to in that list, even outside of ipfs org, repos that we want/expect to follow our guidelines?  ( There are quite a few already, and likely to be more: https://github.com/ipfs/ci-status/issues/1#issue-115979968 )

And why wouldn't we pull directly from the raw URL for each repo?

Raw URLs or API fetches both work fine, and both are throttled if not logged in.

Switching to OAuth or just using Basic Auth should work - are we doing more than 5k an hour?

Nope!  Should be plenty.

Using raw URLs anonymously is working well.  We also have a counter of remaining github calls.  We run out sometimes in dev, but probably not so much IRL.  Closing, please reopen if experiencing pain around this.


Investigate if diskio_mutex is still needed

From the buspirate forums....

Another thing I note is that there is a (&diskio_mutex) in nand_ftl_diskio.c. Is this still needed/warranted since we now have write lock when the terminal is open (and later, exclusive disk and terminal modes)?

It is defo still needed. Even in read only mode we need the disk access to be atomic. And, I can't believe I'm only now realizing, but the USB MSD is also serviced on core 2 with the rest of the USB stack, so I understand now why it's been such a mess. While all the firmware access to the disk is core 1, MSD is serviced on core 2.

For folks following along, while the multi-core aspect adds to internal locking requirements, the same multi-initiator data corruption concerns would apply on a single-core solution.


Change default ignored_reactions to use SBO terms

Currently looks_like is used to identify biomass and exchange reactions (usually not balanced). This is not robust, SBO terms should be used instead. Functions like is_biomass_reaction and is_exchange_reaction implement SBO matching in COBREXA, use that here.

Implemented in #70


When trying to run a Monero pool: Unable to load shared library 'libcryptonote' or one of its dependencies.

Miningcore can see my Monero daemons, but it crashes right afterwards. I see this error in the log:
[2022-08-13 18:24:03.1506] [I] [xmr1] All daemons synched with blockchain                                                                                [2022-08-13 18:24:03.1833] [E] [xmr1] System.DllNotFoundException: Unable to load shared library 'libcryptonote' or one of its dependencies. In order to help diagnose loading problems, consider setting the LD_DEBUG environment variable: liblibcryptonote: cannot open shared object file: No such file or directory   at Miningcore.Native.CryptonoteBindings.decode_address(Byte* input, Int32 inputSize)                                                                        (cut)

How can I install or build just the missing libraries? I can not build the complete latest version on Miningcore because of another issue. It simply does not build  #1327 .
My software:
Ubuntu 20.04.4 LTS
Monero 'Fluorine Fermi' (v<IP_ADDRESS>-release)
Miningcore <IP_ADDRESS>-master
Thank you.

[SOLVED] #1350


Address Issue 3723

Fixes #3723 by just considering physical bonds to calculate the degree.
This sounds reasonable to me, but I'm wondering if using getValenceContrib(atom) != 0.0 would be more appropriate.

It's hard to say exactly what the right thing to do in this case is - for example: should we even include torsions where one of the bonds is a zero-order bond? - but I think sticking to this small change is a good place to start.
I think it would be better to use getValenceContrib() rather than the bond types explicitly: your calculation misses the fact that dative bonds do impact the valence of one of the atoms involved in the bond and getValenceContrib() accounts for that.

It's hard to say exactly what the right thing to do in this case is - for example: should we even include torsions where one of the bonds is a zero-order bond? - but I think sticking to this small change is a good place to start.
I think it would be better to use getValenceContrib() rather than the bond types explicitly: your calculation misses the fact that dative bonds do impact the valence of one of the atoms involved in the bond and getValenceContrib() accounts for that.

[...] dative bonds do impact the valence of one of the atoms involved in the bond [...]

I know. I might be confused about this, but my though was that this contribution to the valence is considered by the atom->getExplicitValence() term, while the electrons are not shared over the dative bond, so it kind of made sense not to consider it for the degree of the atom.
In any case, it's just an intuition, as I'm not familiar to considerations of this kind. I'll update to use getValenceContrib().

[...] dative bonds do impact the valence of one of the atoms involved in the bond [...]

I know. I might be confused about this, but my though was that this contribution to the valence is considered by the atom->getExplicitValence() term, while the electrons are not shared over the dative bond, so it kind of made sense not to consider it for the degree of the atom.
In any case, it's just an intuition, as I'm not familiar to considerations of this kind. I'll update to use getValenceContrib().


Does this bootloader support nRF52832?

No, it does not.
Adding support for it wouldn't be too difficult, you basically just need to add the linker files and update the makefile targets for that specific board, and there wouldn't be an double-tap-reset support.
Pull requests are welcome. I don't have any nRF52832 boards at my disposal to test with.

Thank you for the quick response.
Can you please quickly comment on the main difference between your bootloader vs adafruit nrf52 bootloader (https://github.com/adafruit/Adafruit_nRF52_Bootloader)?

This is documented in the readme but for clarity, it has the same feature/board support as the Adafruit one with the following differences:

Supports Nordic Secure BLE DFU OTA instead of the Legacy one
Uses the standard nrfutil tools instead of the custom Adafruit ones.
Presently doesn't have support for anything other than nRF52840 chipsets
Does not support UF2 yet

In short, I needed the Secure BLE DFU OTA functionality for an app I have and the Adafruit one didn't provide it so I made this.

If I end up using your bootloader and added support for nrf52832, do you know if this bootloader will work with Adafruit_nRF52_Arduino (https://github.com/adafruit/Adafruit_nRF52_Arduino)?

Unfortunately it doesn't due to an upstream issue.  The normal arduino stuff works, the Adafruit Bluefruit libraries however do not. See https://github.com/charlesportwoodii/kaidyth_nrf52_bootloader/issues/3#issuecomment-507072763 and adafruit/Adafruit_nRF52_Arduino#200.
It's a problem with how the Bluefruit libraries interact with the Nordic Secure Bootloader which this is based off of. Adafruit would need to update the Bluefruit libraries to make them compatible.


ENH: optimize.root_scalar, etc.: add function convergence criteria and callback

Hi, I think I found a problem with optimize.newton: sometimes it returns a solution which is not a root, without error.
Consider:
def f(x):
    return x**4 - x**2 + 1

then:
x = newton(f, 0.001)

Returns x = 0.00110008147544, with f(x) = 0.999998789822.
Changing the starting point to 0.1 returns an error (Failed to converge), which is ok (this equation does not have a root). Might be a mistake in the convergence criterion?

The convergence criterion is
abs(p - p1) < tol

For p1 the old guess for the root and p the new guess, which is a strange way to do things.

But from the documentation:
"However, the stopping criterion used here is the step size and there is no guarantee that a zero has been found."
So everything does work as advertised.

Should be fixed nonetheless imho. For newton method, the step length may be reasonable termination condition, but it's actually the secant method in this case.

Yes, indeed, I missed that sentence in the documentation. Seems like a documented bug though :). The function should return an error when abs(f(x))>tol IMO.

Yep, that's what #6380 changes it too.

Hi, I am new to GitHub and filing bug reports/issues for SciPy.
I arrived here because I encountered a problem with the secant method in scipy.optimize.newton, which may be related to the issue reported here. I am working on a solution.
What happened to pull request #6380 which dealt with the issue ? The request was closed, but I did not find the corresponding changes in the main branch of the source code. Was it dropped?
Meanwhile, the issue here is still open. @GGurtner , does the problem still exist or has it been solved?
Thanks.

IMHO, a better convergence criterion for the secant method would be abs(f(x) < ftol, instead of the step size in x becoming smaller than tol. The objective of the secant method is after all to find x such that f(x) is sufficiently close to zero. However, this criterion may be confusing for those who would expect tol to refer to x. (Of course, there is a correspondence between these tolerances, at least for functions that actually do have f(x) = 0 in the vicinity of x0)
In addition to this issue with the convergence criterion for the secant method, there is also an issue with the 'initial guess'. The secant method needs two points to get started, x0 and x1. In the present implementation, x0 is supplied by the user and x1 is generated automatically (by multiplying by 1.0001 and adding or subtracting 0.0001), which causes problems when working with small x. It may be a good idea to create the possibility of supplying x1.
I have a modified version of the scipy.optimize.zeros.newton secant method that indeed fails gracefully with the x = newton(f, 0.001) example above, and that also solves the problem I encountered when working with small values of x (x < 1E-6, typically).

The issue I have with the secant method in scipy.optimize.zeros (newton), is that the following does not converge to the (existing) zero, even though the starting point is really close to the answer. (I discovered the problem using a more complicated function, but the following reproduces the undesired behaviour.)
import numpy as np
from scipy.optimize import newton

def g(x, k, xoff):
    y = 1./(1.+np.exp(-k*(x-xoff))) - 0.5
    return y

x = newton(g, 2e-10, args=(1e10, 1.4142e-10), tol = 1e-13)
print('x=', x, 'g(x)=',g(x, 1e10, 1.4142e-10))

This gives x = 8.24242091953e-06 and g(x) = 0.5, whereas there is an analytical solution for g(x) = 0, i.e. x = 1.4142e-10. As one notices, the starting point specified is already really close to the actual
solution, but newton does not find it.
When instead of k = 1e10, k = 1 is chosen, newton does function normally. The problem stems from the automatically generated starting conditions for the secant solver (choice for x1), which are hard-wired (something like x1 = x0 * 1.0001 + 1E-4, which in the case of small x0 throws x1 far off from the range of interest)
(Admittedly, I work with small values, but that is the entire point of using floating point numbers in scientific calculations. The function g(x) is perfectly smooth, even with k << 1e20, and the secant solver should be able to find the zero)
Below is a modified secant solver (based on the code in scipy.optimize.zeros),which addresses both my issue (works with small x, and flawlessly solves g(x) = 0), and the issue raised by @GGurthner (convergence testing on func(x)).
Finally, I  feel that using x step size as a convergence  criterion in the secant method does make sense since it gives a measure of the uncertainty of the solution. Once the algorithm has converged
to a value for  x, it is then relatively easy to test if func(x) is within a desired tolerance interval from 0. To this end, an optional parameter ftol was added. If it is specified, the solution x will be tested, and an error will be raised if it is not close enough to zero.
Here is the idea:
#!/usr/bin/env python3
# -*- coding: utf-8 -*-

import warnings
import numpy as np

def secant(func, x0, x1=None, args=(), tol=1e-8, ftol=None, maxiter=50):
    """
    Find a zero of the function `func` given nearby starting points `x0`
    and `x1`, using the secant method

    (based on scipy.optimize.zeros.newton)

    Parameters
    ----------
    func : function
        The function whose zero is wanted. It must be a function of a
        single variable of the form f(x,a,b,c...), where a,b,c... are extra
        arguments that can be passed in the `args` parameter.
    x0, x1 : floats
        Initial estimates of the zero that should be somewhere near the
        actual zero. Two separate points are needed to begin the search.
        It is not necessary to bracket an interval where `func` changes sign.
        If `x1` is not specified, an initial guess will be constructed.
    args : tuple, optional
        Extra arguments to be used in the function call.
    tol : float, optional
        The allowable error on the `x` position of the zero of `func(x)`. This
        provides the stopping convergence criterion for the method.
    ftol : float, optional
        If specified, secant will check the result after convergence, and raise
        an error if `func(x)` is not within tolerance `ftol` of zero. If not
        specified, there is no guarantuee that a zero was found even when
        secant successfully terminates.
    maxiter : int, optional
        Maximum number of iterations.

    Returns
    -------
    zero : float
        Estimated `x` location where function `func(x)` is zero.

    See Also
    --------
    newton, brentq, brenth, ridder, bisect
    fsolve : find zeroes in n dimensions.

    Notes
    -----
    The stopping criterion used here is the step size and if `ftol` is not
    specified there is no guarantee that a zero has been found.
    Safer algorithms are brentq, brenth, ridder, and bisect, but they all
    require that the root first be bracketed in an interval where the function
    changes sign. The brentq algorithm is recommended for general use in one
    dimensional problems when such an interval has been found.
    """
    if tol <= 0:
        raise ValueError("tol too small (%g <= 0)" % tol)
    if maxiter < 1:
        raise ValueError("maxiter must be greater than 0")

    p0 = x0
    if x1 == None:
        p1 = x0 * 1.001 # construct initial guess for `x1` from `x0`
    else:
        p1 = x1
    if np.abs(p1 - p0) < tol: # if initial step small compared to `tol`
        p1 = x0 + 10.*tol
        msg = ("`x1` too close to `x0`. Initial step for secant method was "
               "increased to 10 times 'tol'.")
        warnings.warn(msg, RuntimeWarning)
    q0 = func(*((p0,) + args))
    q1 = func(*((p1,) + args))
    for i in range(maxiter):
        if q1 == q0:
            msg = ("Secant method failed to converge: no further progress "
                   "possible after {0} iterations: "
                   "x = {1}, f(x) = {2}").format(i, p1, q1)
            raise RuntimeError(msg)
        p = p1 - q1*(p1 - p0)/(q1 - q0)
        p0 = p1
        q0 = q1
        p1 = p
        q1 = func(*((p1,) + args))
        if np.abs(p1 - p0) < tol:
            if ftol==None:
                return p1
            elif np.abs(q1) < ftol:
                return p1
            else:
                msg = "Result not close enough to zero."
                raise RuntimeError(msg)
    msg = "Secant failed to converge after %d iterations, x = %s"\
         % (maxiter,p)
    raise RuntimeError(msg)

### RUN SOME TESTS
if __name__=='__main__':
    # Test 1 (GGurthner)
    def f(x):
        return x**4 - x**2 + 1

    try:
        x = secant(f, 0.001)
    except:
        print('secant failed...')
    else:
        print('secant did not fail... x=', x, 'f(x)=',f(x))

    try:
        x = secant(f, 0.001, ftol=1e-2)
    except:
        print('secant failed as expected')
    else:
        print('secant did not fail... x=', x, 'f(x)=',f(x))

    # Test 2
    def g(x, k, xoff):
        y = 1./(1.+np.exp(-k*(x-xoff))) - 0.5
        return y

    for k in [1e6, 1e7, 1e10, 1e13, 1e20]:
        # parametrize curve and initial guess
        xoff=np.sqrt(2)/k
        x0guess=xoff*1.01 # start from a point already close
        # calculate f(x)=0 from secant and compare to analytical
        x_s = secant(g, x0guess, args=(k, xoff), tol=1e-3/k)
        print('analytical = ',xoff, '; secant = ', x_s)

I was using the newton root finding method today and was getting results that did not match the solver tolerance set. I expect this is due to this issue. I was able to get around this issue by modifying my code to set both x0 and x1, which, I expect, changes the step size to the difference between the two values.

The fact that this function uses a step size tolerance is not unusual. This is common in optimization and root finding routines, and it is specifically mentioned in secant method references (e.g. Wikipedia). The thing that is needed, I think, is the addition of a function tolerance as mentioned above.
To close this issue, I'd suggest the following:

use the decorator in _lib/utils (I can be more specific when I'm at a computer) to rename tol to xatol and rtol to xrtol in a backward compatible way and include only the new names in the documentation.
add an fatol stopping condition, and maybe an frtol stopping condition.

This is similar to what gh-6380 proposed, but the difference is that these would all be separate parameters. If any of these criteria are is met, iteration terminates. Also, the names of the parameters would follow the convention for absolute/relative solution/function value convergence criteria adopted elsewhere in optimize rather than those proposed in gh-6380.

On a related note, we should add a callback interface similar to that of minimize, which terminates when the callback function raises StopIteration.
Eventually, these convergence criteria would be available for all scalar root finders and exposed in the root_scalar interface.

@andyfaff would you be interested in implementing this or reviewing a PR if I were to prepare it?

I am in favour of cleaning up the naming and making sure all functions use these. It's confusing right now and users need to read the doc to be sure they have the correct param name.

@mdhaber @tupui and others: many thanks for looking into this and solving issue #14486 which also concerns scalar root finding.
These latest suggestions for harmonizing and enhancing scipy.optimize.root_scalar and scipy.optimize.newton make good sense to me.
I am a simple user of scipy with very limited coding and git skills, and do not have time to dig further into this matter at the moment. I'll give the new versions a test drive later on, and try and compare scipy.optimize.root_scalar and scipy.optimize.newton. (So, I am leaving this message also for my future self)
Again, many thanks.

I just tried to use the secant algorithm from scipy.optimize.newton again, with the latest SciPy (1.10.1 via conda-forge) and it still fails for very small values of x in my case.
The following reproduces the problem. The secant algorithm works fine for k = [1e-3, 1, 1e3] (large x) but fails for the other values (small x).
I have a modified version of the secant algorithm that passes successfully this test, but the standard version fails when executing the code below.
import numpy as np
import scipy
import scipy.optimize

print('SciPy version', scipy.__version__)

def g(x, k, xoff):
    y = 1./(1.+np.exp(-k*(x-xoff))) - 0.5
    return y

for k in [1e-3, 1, 1e3, 1e6, 1e9, 1e12, 1e20]:
    xoff=np.sqrt(2)/k
    print('Testing k =', k, 'analytical = ',xoff, '; ', end='\t')
    # initial guess
    x0guess=xoff*1.01 # start from a point already close
    try:
        x_s = scipy.optimize.newton(g, x0guess, args=(k, xoff), tol=1e-3/k)
    except RuntimeError:
        print('*** ALGORITHM FAILED ***')
    else:
        print('secant = ', x_s)


Docs.MS CI Updates for Azure.Template

CI Update for release of Azure.Template

Docs Build status updates of commit 829db25:
:white_check_mark: Validation status: passed

File
Status
Preview URL
Details

bundlepackages/azure-dotnet-preview.csv
:white_check_mark:Succeeded

For more details, please refer to the build report.
Note: Broken links written as relative paths are included in the above build report. For broken links written as absolute paths or external URLs, see the broken link report.
For any questions, please:Try searching in the Docs contributor and Admin GuideSee the frequently asked questionsPost your question in the Docs support channel


Print out usage guidelines when non-numeric line & column are given to type-at-pos

Hello!
I noticed that the error feedback when using type-at-pos incorrectly could be a little more consistent.
In the current build, passing a filename and line but no column results in the following output:
$ ./bin/flow type-at-pos some/file 2
Unhandled exception: Failure("int_of_string")

This is because with two arguments type-at-pos expects to receive line and column, and for the filename to be given via stdin. Most filenames can't be parsed as ints, hence the Failure.
The same error occurs if three args are passed, but the second two are non-numeric, e.g.
$ ./bin/flow type-at-pos some/file 2 a
Unhandled exception: Failure("int_of_string")

This change just makes type-at-pos bail out if the line & column are unparseable with the same behavior used for the zero arguments case.
Please let me know if there's anything I can do to make this better!

This is awesome and looks good to me! Thanks for fixing this up!


Adding domain for CEME, NUST, Pakistan

This domain is used for student email in the Department of Mechatronics Engineering, CEME, NUST, Pakistan
The official website is: https://ceme.nust.edu.pk/

@bestatscience Thank you for your patience while waiting for a review and processing your request. Pull request merged.


Please add "&intl=nosplash" to all BestBuy links for international users

I'm a US resident currently abroad trying to buy a card. When I go to the Best Buy website, it first drops me on a splash screen to choose my country, which breaks this tool and always gives alerts. I've discovered you can bypass this screen by putting "&intl=nosplash" at the end of every Best Buy url and it goes directly to the product page. Could you please add this to future versions as I have to add it manually each time I pull currently.
Thanks!

Submitted PR #153 to add this


Support for histogram data

Read NXdata from file and publish as hs00. This feature is present in https://github.com/ess-dmsc/NeXus-Streamer.

Confirmed not in use in C++ implementation, so closing ticket.


Fix addOption when 'nested' specified

Fixed an issue where addOption would not find the proper place to insert into when optgroups are specified & index is not.
Example here: https://jsfiddle.net/me8v1fyp/
The index calculation doesn't recognize that that.$element.children() is the list of optgroups when they are specified, so it places the new option after the last optgroup - instead of entering the specified group (nested) to insert into.

Cleaned it up -- as it turns out, all that had to be done was initialize $container first, and use it to find the index in place of that.$element.


initial file structure

bringing over the rest of the files from original yardsale - will need to refactor from MVC into graphql and react

good job sorry about the other comments lol


Error: react-native-permissions: NativeModule.RNPermissions is null (Android).

Bug report

Summary

I'm getting this error in Android:
 ERROR    Error: react-native-permissions: NativeModule.RNPermissions is null. To fix this issue try these steps:
• If you are using CocoaPods on iOS, run `pod install` in the `ios` directory and then clean, rebuild and re-run the app. You may also need to re-open Xcode to get the new pods.
• If you are getting this error while unit testing you need to mock the native module. You can use this to get started: https://github.com/zoontek/react-native-permissions/blob/master/mock.js
If none of these fix the issue, please open an issue on the Github repository: https://github.com/zoontek/react-native-permissions

Environment info

react-native info output:
# paste it here

 "@iterable/react-native-sdk": "^1.0.26",
    "@react-native-community/async-storage": "^1.12.1",
    "@react-native-community/masked-view": "^0.1.11",
    "@react-native-firebase/analytics": "^11.1.2",
    "@react-native-firebase/app": "^11.1.2",
    "@react-native-firebase/crashlytics": "^11.1.2",
    "@react-native-firebase/dynamic-links": "^11.1.2",
    "@react-navigation/native": "^5.9.3",
    "@react-navigation/stack": "^5.14.3",
    "react": "16.13.1",
    "react-native": "0.63.4",
    "react-native-dotenv": "^2.5.3",
    "react-native-extended-stylesheet": "^0.12.0",
    "react-native-gesture-handler": "^1.10.3",
    "react-native-permissions": "^3.0.3",
    "react-native-reanimated": "^2.0.0",
    "react-native-safe-area-context": "^3.2.0",
    "react-native-screens": "^2.18.1",
    "react-native-webview": "^11.2.3",
    "react-redux": "^7.2.2",
    "redux": "^4.0.5",
    "redux-persist": "^6.0.0",
    "redux-thunk": "^2.3.0"

Library version: 3.0.3
Steps to reproduce

install library
get error on Android while running the app

Describe what you expected to happen:

I can run Android app

Reproducible sample code

I used  --legacy-peer-deps during install, because react-native-permissions library was complaining that I was using not the latest version of react-native and react.

@Luckygirlllll Do you have a reproduction repository? Create a small example with a fresh app to show that the issue is real.


Revise copy for URL on roster page

Who is this PR for?
educators, from feedback from LL
What problem does this PR fix?
Make more explicit that particular filter combinations can be loaded by URL.
What does this PR do?
Changes the copy.
Screenshot (if adding a client-side feature)
before

after

selfie


Break Serilog.Formatting.Json.JsonFormatter dependency (WIP)

Relates to serilog/serilog#819.
I thought I'd put this up in it's current state for discussion - this PR just moves the base JSON formatter type into the sink assembly as DefaultJsonFormatter.
There are a couple of options for how this might be cleaned up - a zero-breaking-change option, if that's desired, is to merge as-is.
Another alternative is to get rid of some of the unnecessary cruft, e.g. omitEnclosingObject and so-on, and perhaps collapse DefaultJsonFormatter down into ElasticsearchJsonFormatter, simplifying and cleaning things up in the process.
Happy to try either approach, keen to gather some feedback @mivano @Mpdreamz @merbla.

LGTM :+1: its nice to add the non breaking variant in 4.
When we accumulate enough breaking changes moving over to one true new way should be a blocker in 5.

Thanks @Mpdreamz.
:shipit: ?

Guys, closing this to re-target to dev. Cheers!


Status page, resource log hangs when items per page set to 500

When changing the number of items to display to 500, MyC runs very slow, hangs for few seconds. Tested on demo site and on local RPi2. System CPU load jumps to 100%.

@turbatus Yes, loading more number of rows at a time will lead performance issue on server side as well as on client side (on browser).

Well, I kinda thought that way myself. But, since this can cause problems, is really needed to display 500 items at once? i think 250 will do just fine. my opinion...

@turbatus I do not face hangs issue with our demo site as well as with RPi2. I hope you are running browser on low-end system.
For me it takes around ~3 seconds. My RPi2 running with Raspbian and no desktop installed on it. Java (oracle): 1.8.0_65-b17

well, then it was a false alarm. I'll close this issue, then. Thank you.

@turbatus Thank you!


Build starter subsystem

With spark gap design.

The spark gap version is finished, but not perform well. Move on to solid state one #38 .


Migrate existing ARKS to EZID and add metadata

After #708, we can probably just call #update_ezid


botframework-directlinespeech sdk not compatible with spfx 1.11

We have tried out directline speech sample in SharePoint page using Modern script editor webpart. It is working in SharePoint but it will be only specific to that page.
We want to avail bot on each page. For that purpose we are using SPFX Application Customizer Extension. SPFX currently supports only node version 10.
When we tried out with higher version of botframework-webchat in spfx solution, we found out it have compatibility issues with node version 10. As you can find in screenshot:

Botframework-directlinespeech-sdk are not compatible with node version 10, which is only node version supported by SPFX 1.11.

Can you please provide botframework-directlinespeech-sdk which is compatible with node 10. Or let us know any alternative.

@compulim could you please weigh in on this question and triage?

@jayarau Are you trying to run botframework-directlinespeech-sdk in a server, or, in a browser?

Hi @msomanathan , We are not trying to botframework-directlinespeech on server. We just need botframework-directlinespeech package to integrate bot in SharePoint Site. For integrating bot we are using SPFX(SharePoint Framework)  Extension.

I am not an expert of SharePoint. But if you are not running DLSpeech SDK on a server, Node.js version should not matter because you shouldn't be running DLSpeech SDK on Node.js.
As I can see, the latest version of SPFx is 1.11.0 of 2020 July. This installation page said it support Node.js 10 LTS only, which is 10.24.0.
But according to Node.js releases page, Node.js 10 LTS will be discontinued on 2021-04-30, which is a month away. The current active LTS is Node.js 14.
I have looked at our dependency tree. While it's okay to de-bump our Node.js requirement to 10.14.2, the work will be scheduled to our R14 release, which will be released in about 1-3 months of time. And when we release, Node.js 10 support has already ended.
@jayarau can you check with SharePoint team to see if SPFx 1.12.0 with support of Node.js 12 LTS or 14 LTS is around the corner or not?
Technical context
FYI, following is a walk of our deps tree, showing Node.js deps that do not satisfy 10.0.0. It will satisfy almost all of them on Node.js 10.14.2, and just failing watchpack-chokidar2, which requires Node.js <8.10.0.
<EMAIL_ADDRESS>is required by<EMAIL_ADDRESS>and<EMAIL_ADDRESS><EMAIL_ADDRESS>has the engines.node requirement removed.  You can join their meetups and ask them if about their plan to bump to Node.js 12.
https://pnp.github.io/

SPFX 1.12 was released on March 16, 2021. But Version 1.12 release is currently considered as deprecated and has been unpublished due the unexpected regressions.

From the release node of SPFx 1.12.1, I think the SharePoint team recognize the importance of Node.js 12/14 in SPFx 1.12.0. But they accidentally tripped the deadline due to unexpected regressions.
We will de-bump our engine requirement to 10.14.2. But due to our shipping cycle, I can't guarantee if it will be released sooner than SPFx 1.12.1 or later (21Q2). We should have a release around end of May, but it's not a guarantee.
@jayarau Does it work for you?
Also, I would love to learn how to integrate Web Chat (or other React components) with SPFx. Could you send me your favorite tutorials on this topic?
Personally, I would love to see if we can setup a new test that consistently test hosting Web Chat inside (dev bench) of SPFx. And/or, having a new sample teaching end-dev how to host Web Chat in SPFx the right way. Can't guarantee anything here, but I would see it as an opportunity for us to reduce our workload on supporting SPFx.

Hi @compulim ,
Yes, It will work for us.
For integrating webchat with spfx we have referred below link. You can take look into that.
https://www.withum.com/resources/build-a-custom-chat-bot-with-sharepoint-framework/


TaskBarX will not continue working after going to sleep or after computer is restarted.

Every time my computer goes to sleep or I turn it off I have to re open taskbarx and click apply again. Ive played around with the startup delay and it has changed nothing.
To Reproduce
Steps to reproduce the behavior:
Let computer go to sleep or turn computer off or restart computer.
Expected behavior
Taskbarx would begin working again however is does not.
Desktop :

OS: [Windows 10]
Version 21H1
Taskbarx version <IP_ADDRESS>

Additional context
for some reason it has a better chance of working on startup if I manually put my computer to sleep or shut it down than it does if i just let my computer go to sleep.

To be able to focus on major/current bugs I had to close all issues. The issues section has gotten very messy to a point that I couldn't follow it anymore. Most issues are duplicates, very old or are already fixed/solved. Feel free to reopen this issue if you still have this issue on the latest version of TaskbarX to get my attention. All feature requests have been put in a list here: 💡| Feature requests #870
I hope you understand ❤


Consolidate examples

This PR moves querydsl-customer-dao, querydsl-sql-example, and querydsl-jpa-example under querydsl/querydsl/querydsl-examples.

I need to upgrade querydsl-sql-example and querydsl-jpa-example to use querydsl 4.0.1 and add the examples module to the travis profile.

This looks good to me.

So does this mean that the original repositories can be removed?
Should we add a new label for example or something?

I think we should remove the original repositories.
I'm not sure a new label is necessary but I guess it wouldn't hurt to create one.

I agree, we can remove the original repositories.

Then I'll merge this.


Wrong redirection after add time to issue

Gitea version (or commit ref): 1.13.0 and previous
Git version: 2.17.1
Operating system: Linux - AMD binary from gitea site.
Database (use [x]):

[ ] PostgreSQL
[ ] MySQL
[ ] MSSQL
[X] SQLite

Can you reproduce the bug at https://try.gitea.io:

[ ] Yes (provide example URL)
[X] No

Description
When I install gitea, I setup it on my local server (IP: <IP_ADDRESS>) and it's working ok. But, I have configured a VPN when I'm roaming and I reach gitea server through a different IP (<IP_ADDRESS>).
VPN in Normal operation works OK, I can fetch/pull/push project without problem, and I can navigate and create/edit issues with the UI without problem.
The problem appear when I add time to an issue, after press approve button, I'm redirected to the issue page in the local IP not in the IP though VPN, this make to appear a 404 because I can't reach server through local IP.
The time added is registered and we go back and reload page to get the issue with time on screen.
Regards.
Manuel.

On AddTimeManually() action, Gitea will use the host specified in ROOT_URL config var for redirects, so there will only be one valid host.
We could make the redirect host-relative as in other post actions, like DisableTwoFactor().
A quick survey on the codebase shows this issue occurs in:

routers/repo/issue_lock.go
routers/repo/issue_watch.go
routers/repo/issue_stopwatch.go
routers/repo/issue_timetrack.go
routers/repo/issue_dependency.go
routers/repo/issue.go (NewComment())
routers/user/setting/security_openid.go
routers/user/auth_openid.go

On AddTimeManually() action, Gitea will use the host specified in ROOT_URL config var for redirects, so there will only be one valid host.
We could make the redirect host-relative as in other post actions, like DisableTwoFactor().
A quick survey on the codebase shows this issue occurs in:

routers/repo/issue_lock.go
routers/repo/issue_watch.go
routers/repo/issue_stopwatch.go
routers/repo/issue_timetrack.go
routers/repo/issue_dependency.go
routers/repo/issue.go (NewComment())
routers/user/setting/security_openid.go
routers/user/auth_openid.go

If you have two root_urls you're gonna find lots of other things don't work too.
I think therefore this issue is invalid and you should either retitle/rephrase or open another issue to ask for multiple rooturl support.
It would be possible to do something with this by looking at the remote IP of client connection or by listening on different ports - however the actual issue is one of configuration:
How do we come up with a concise reasonably uncomplicated and backwards compatible configuration to make this possible.
If an issue were written with such a proposed configuration, implementation wouldn't actually be too difficult.
Many feature requests on gitea would benefit from this additional level of thought.

If you have two root_urls you're gonna find lots of other things don't work too.
I think therefore this issue is invalid and you should either retitle/rephrase or open another issue to ask for multiple rooturl support.
It would be possible to do something with this by looking at the remote IP of client connection or by listening on different ports - however the actual issue is one of configuration:
How do we come up with a concise reasonably uncomplicated and backwards compatible configuration to make this possible.
If an issue were written with such a proposed configuration, implementation wouldn't actually be too difficult.
Many feature requests on gitea would benefit from this additional level of thought.

I agree that title should be broader.
The configuration-less way to do it, is to switch to relative redirects. That's simple, and I already outlined above where this needs to be changed.
The more involved alternative is to treat this as a dupe of #8697 and #11732 (i.e. make things like repo.HTMLURL() consider the current request host), which I personally won't touch, as this is related to the macaron/chi refactor. (but could also be considered an opportunity to fix it while refactoring)

I agree that title should be broader.
The configuration-less way to do it, is to switch to relative redirects. That's simple, and I already outlined above where this needs to be changed.
The more involved alternative is to treat this as a dupe of #8697 and #11732 (i.e. make things like repo.HTMLURL() consider the current request host), which I personally won't touch, as this is related to the macaron/chi refactor. (but could also be considered an opportunity to fix it while refactoring)

I never though this will be a multi-root config related problem, as web developer I avoid any absolute reference as far as I can.
I agree with @noerw about host-relative redirects as solution, sadly i am not a go programmer so I can't help to fix them.
Please suggest me a new tittle for issue or I'll close it as dupe.

I never though this will be a multi-root config related problem, as web developer I avoid any absolute reference as far as I can.
I agree with @noerw about host-relative redirects as solution, sadly i am not a go programmer so I can't help to fix them.
Please suggest me a new tittle for issue or I'll close it as dupe.

OK we need to be clearer about what we mean when we say relative.
Usually "relative" in this case is actually an absolute path "/root-of-gitea/owner/reponame/..." rather than FQDN links. These absolute paths are still going to fail if you have Gitea mounted on a suburl on one IP/domain and on a different one on a different IP/Domain.
If you mean only ever emit truly relative addresses that's a lot of work and possibly not even possible. It would honestly be easier to allow the different mounting.

OK we need to be clearer about what we mean when we say relative.
Usually "relative" in this case is actually an absolute path "/root-of-gitea/owner/reponame/..." rather than FQDN links. These absolute paths are still going to fail if you have Gitea mounted on a suburl on one IP/domain and on a different one on a different IP/Domain.
If you mean only ever emit truly relative addresses that's a lot of work and possibly not even possible. It would honestly be easier to allow the different mounting.

Related to

https://github.com/go-gitea/gitea/issues/19345

Close this one


Cypress run starts but does not run any tests

When we run our cypress tests they appear to start and find the specs but then no tests are run. The step ends and reports success and the cypress cloud link that is presented in the logs is an old run. Here is the output from the step:
[STARTED] Task without title.
2024-03-17T23:09:14.798Z @cypress/github-action found command "/usr/local/bin/yarn"
2024-03-17T23:09:14.798Z @cypress/github-action with arguments start
2024-03-17T23:09:14.798Z @cypress/github-action running "/usr/local/bin/yarn" start in /home/runner/work/projectname-ui/projectname-ui
2024-03-17T23:09:14.798Z @cypress/github-action waiting for the command to finish? false
/usr/local/bin/yarn start
yarn run v1.22.22
$ next start --hostname local.projectname.com --port 2000
ready - started server on local.projectname.com:2000, url: http://local.projectname.com:2000
info  - Loaded env from /home/runner/work/projectname-ui/projectname-ui/.env
warn  - The `target` config is deprecated and will be removed in a future version.
See more info here https://nextjs.org/docs/messages/deprecated-target-config
[SUCCESS] Task without title.

Opening Cypress...

DevTools listening on ws://<IP_ADDRESS>:34471/devtools/browser/909ce3cb-d39e-4b4e-9f63-fd0a77713073
[3742:0317/230918.590670:ERROR:object_proxy.cc(590)] Failed to call method: org.freedesktop.portal.Settings.Read: object_path= /org/freedesktop/portal/desktop: unknown error type:

====================================================================================================

  (Run Starting)

  ┌────────────────────────────────────────────────────────────────────────────────────────────────┐
  │ Cypress:        13.6.3                                                                         │
  │ Browser:        Electron 114 (headless)                                                        │
  │ Node Version:   v20.8.1 (/home/runner/runners/2.314.1/externals/node20/bin/node)               │
  │ Specs:          24 found (login.spec.ts, status-check.spec.ts, institution/search-org.spec.ts, │
  │                  institution/setup-organization.spec.ts, organization/add-folder.spec.ts, orga │
  │                 nization/assign-transaction.spec.ts, organization/search-subaccount.spec.ts, s │
  │                 ubaccount/close-subacco...)                                                    │
  │ Searched:       cypress/e2e/**/*spec.ts                                                        │
  │ Params:         Tag: false, Group: false, Parallel: true                                       │
  │ Run URL:        https://cloud.cypress.io/projects/<projectid>/runs/334                              │
  │ Experiments:    experimentalOriginDependencies=true                                            │
  └────────────────────────────────────────────────────────────────────────────────────────────────┘

====================================================================================================

  (Run Finished)
2024-03-17T23:09:29.328Z @cypress/github-action Cypress tests: 0 failed
2024-03-17T23:09:29.328Z @cypress/github-action resultsUrl https://cloud.cypress.io/projects/<projectid>/runs/334
2024-03-17T23:09:29.329Z @cypress/github-action all done, exiting

This is the step definition from our workflow
      - name: Cypress run
        uses: cypress-io/github-action@v6
        with:
          start: yarn start
          install: false
          record: true
          parallel: true # Runs test in parallel using settings above
        env:
          CYPRESS_RECORD_KEY: ${{ secrets.CYPRESS_RECORD_KEY2 }}
          DEBUG: '@cypress/github-action'

@cushdan
Could you post your full workflow?
Have you provided a matrix of containers for the parallel run like:
    strategy:
      fail-fast: false
      matrix:
        containers: [1, 2, 3]

Is this a private repository or is it public?

Yes we do have a matrix defined as seen in the full workflow below. This is a private repo. Thanks!
name: Cypress Tests

on:
  pull_request:
    branches: [ main ]
  schedule:
    # Run daily at 6pm EST 23 UTC
    - cron: '0 23 * * *'
  workflow_dispatch:

jobs:
  cypress-run:
    runs-on: ubuntu-22.04
    permissions:
      contents: read
      id-token: write
    strategy:
      fail-fast: false # https://github.com/cypress-io/github-action/issues/48
      matrix:
        containers: [1, 2, 3, 4] # Uses 4 parallel instances

    steps:
      - name: Checkout the Code
        uses: actions/checkout@v4

      - name: Assume AWS Decrypt Role
        uses: aws-actions/configure-aws-credentials@v4

      - name: Decrypt Secrets

      ## workaround to support assuming different roles within the same workflow
      ## https://github.com/aws-actions/configure-aws-credentials/issues/236#issuecomment-881033383
      - name: reset creds
        shell: bash

      - name: Assume AWS E2E Role
        uses: aws-actions/configure-aws-credentials@v4
        with:

      - name: Setup Node v20
        uses: actions/setup-node@v4
        with:
          node-version: 20

      - name: Install OpenSSL
        run: sudo apt-get update && sudo apt-get install -y openssl
      - name: Generate private key & self-signed certificate
        run: openssl req -x509 -newkey rsa:4096 -keyout localhost-key.pem -out localhost.pem -days 365 -subj "/CN=localhost/CN=local.projectname.com" -nodes

      - name: Add local.foobar.com to /etc/hosts
        run: echo "<IP_ADDRESS> local.projectname.com" | sudo tee -a /etc/hosts

      - name: Install NGINX
        run: sudo apt-get update && sudo apt-get install -y nginx
      - name: Start NGINX
        run: sudo /usr/sbin/nginx -c ${GITHUB_WORKSPACE}/nginx/conf/nginx.conf

      - name: Build projectname
        run: |
          yarn --frozen-lockfile
          yarn build

      - name: Cypress run
        uses: cypress-io/github-action@v6
        with:
          start: yarn start
          install: false
          record: true
          parallel: true # Runs test in parallel using settings above
        env:
          CYPRESS_RECORD_KEY: ${{ secrets.CYPRESS_RECORD_KEY2 }}
          DEBUG: '@cypress/github-action'

also, worth noting that it seems to show this behavior only when the action is triggered from the schedule, but that could be a coincidence

@cushdan
I don't see anything obviously wrong with the workflow. I can't comment on the permissions part though as I have never tried to lock this down.
Have you tried without parallel recording? In other words, commenting out the following:
#    strategy:
#      fail-fast: false # https://github.com/cypress-io/github-action/issues/48
#      matrix:
#        containers: [1, 2, 3, 4] # Uses 4 parallel instances

...
#          record: true
#          parallel: true # Runs test in parallel using settings above

In parallel recording Cypress Cloud should be telling each container what test it is supposed to run so that it does load-balancing. It may be failing in this part.

ok, are there any additional logs that could help narrow things down? I've added DEBUG: to the cypress step already.
It seems strange that the url it provides at the end of the run is one from 4 days ago. Could it be getting confused if there are no new commits and it's determining what to do based on the commit sha? I could try creating a custom build id from the gh action run id

@cushdan
The documentation advises

We recommend passing the GITHUB_TOKEN secret (created by the GH Action automatically) as an environment variable. This will allow correctly identifying every build and avoid confusion when re-running a build.

        env:
          # pass GitHub token to allow accurately detecting a build vs a re-run build
          GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

You might want to try that in addition to the other test I suggested.

I made added the GITHUB_TOKEN back to the step and ran into some permissions errors. I think I may have resolved it by expanding the requested permission scopes for the token to essentially give read-all access as well as the id-token:write that we relied on.
permissions:
      actions: read
      checks: read
      contents: read
      deployments: read
      issues: read
      discussions: read
      packages: read
      pages: read
      pull-requests: read
      repository-projects: read
      security-events: read
      statuses: read
      id-token: write

I do see a difference in the build metadata that the cypress step is using when doing the run so I think the lack of permissions was limiting what the action was able to do.
It ran successfully tonight and we'll see how the next few days go!

@cushdan
Can you confirm that your issue is resolved now? If so, please go ahead and close it ⬇

Closed due to inactivity.


Compact: Fix web.prefix-header to use &wc.prefixHeaderName

Signed-off-by: Daksh Sagar<EMAIL_ADDRESS>
Fix web.prefix-header to use &wc.prefixHeaderName instead of &wc.externalPrefix
Fixes #3156

[ ] I added CHANGELOG entry for this change.
[ ] Change is not relevant to the end user.

Changes
cmd/thanos/config.go in registerFlag method, make cmd.Flag("web.prefix-header", "...", "...") use the prefixHeaderName  field instead of externalPrefix

Verification

@yeya24 Can you see please see if this is alright?

For the future, changelog item is too code specific, we need to make sure it's understandable for a user e.g: Compactor: Fixed support for web.external-prefixfor Compactor UI. Also it should be infixed` category.
I fixed it here, so this is just for learning purposes (:


Database projects build using .net core msbuild make dacpac references upper case

Azure Data Studio Version: Insider build

Steps to Reproduce:

build a database project with a reference
deploying using sqlpackage fails with sqlpackage looking for references with UPPERCASE FILENAMES

Renaming dacpac referenced files to be upper case works.
The model file has the references in upper case
<CustomData Category="Reference" Type="SqlSchema">
			<Metadata Name="FileName" Value="C:\TEMP\TEMPLATE.SQL\SRC\TEMPLATEPROJECT.DB\BIN\DEBUG\TEMPLATEPROJECT.DB.DACPAC" />
			<Metadata Name="LogicalName" Value="TemplateProject.Db.dacpac" />
			<Metadata Name="SuppressMissingDependenciesErrors" Value="False" />
		</CustomData>
		<CustomData Category="Reference" Type="SqlSchema">
			<Metadata Name="FileName" Value="C:\TEMP\TEMPLATE.SQL\SRC\LIB\TSQLT\TSQLT.DACPAC" />
			<Metadata Name="LogicalName" Value="tSQLt.dacpac" />
			<Metadata Name="SuppressMissingDependenciesErrors" Value="False" />
		</CustomData>
		<CustomData Category="Reference" Type="SqlSchema">
			<Metadata Name="FileName" Value="C:\TEMP\TEMPLATE.SQL\SRC\LIB\MASTER.DACPAC" />
			<Metadata Name="LogicalName" Value="master.dacpac" />
			<Metadata Name="ExternalParts" Value="[$(master)]" />
			<Metadata Name="SuppressMissingDependenciesErrors" Value="False" />
		</CustomData>

*** No file was supplied for reference TemplateProject.Db.dacpac; deployment might fail. When package was created, the original referenced file was located C:\TEMP\TEMPLATE.SQL\SRC\TEMPLATEPROJECT.DB\BIN\DEBUG\TEMPLATEPROJECT.DB.DACPAC.
*** No file was supplied for reference tSQLt.dacpac; deployment might fail. When package was created, the original referenced file was located C:\TEMP\TEMPLATE.SQL\SRC\LIB\TSQLT\TSQLT.DACPAC.
*** No file was supplied for reference master.dacpac; deployment might fail. When package was created, the original referenced file was located C:\TEMP\TEMPLATE.SQL\SRC\LIB\MASTER.DACPAC.

Workaround is to rename files, this might not work and you have to rename to a different filename and then back to the original name but UPPER CASE
Tag #11105

@simonsabin does publishing through ADS work or does it also have this error?

This is building not publishing. I’m running the same dot net command as run by ads.
Simon Sabin

From: Kim Santiago<EMAIL_ADDRESS>Sent: Wednesday, July 22, 2020 9:44:15 PM
To: microsoft/azuredatastudio<EMAIL_ADDRESS>Cc: Simon Sabin<EMAIL_ADDRESS>Mention<EMAIL_ADDRESS>Subject: Re: [microsoft/azuredatastudio] Database projects build using .net core msbuild make dacpac references upper case (#11455)
@simonsabinhttps://github.com/simonsabin does publishing through ADS work or does it also have this error?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHubhttps://github.com/microsoft/azuredatastudio/issues/11455#issuecomment-662686490, or unsubscribehttps://github.com/notifications/unsubscribe-auth/AAJHM2YF3QRGFE7C3RSSLLLR45FR7ANCNFSM4PD3NLKQ.

I don't have ADS on linux to test.
But ADS won't publish the project.
I was testing with sqlpackage to deploy

Closing this as the upper casing is removed now.


Error with device counts

I think the device counts are calculated incorrectly.
It looks to be counting the device number based upon the get request numbers rather than actual devices.
For example $TOTAL_IOS_NUMBER is just a calculation of of how many requests were made $yesterday that included iOS user agents. A single device might make 20 requests a day.
That doesn't mean 20 devices hit the caching server.
We should look at unique IP addresses and then break down that list and look for iOS (or other) devices based on that. Still an assumption that a device has the same IP address for a 24 hour period. But possibly more accurate.

You're absolutely right and it actually used to be accurate but Apple made logging changes. As always, PR's are gladly accepted. I still have zero time to do any new engineering effort on this.
Ideally it should be moved to Python.

Cool I'm doing a bit of a re-write to suit our setup here, most of it will be portable. I'll create some PR's for bits that will merge in with yours when i'm done
yeah my python skills are not as good as my bash skills yet so that might have to wait a little bit :P

Please try https://github.com/erikng/Cacher/blob/python-refactor/Cacher
I will be closing this ticket, but you are welcome to re-open if this does not solve your issue.


Organize + Project Clean up

Current situation:
REAME.md is messy.
Re-used code in most functions, make reference methods.
Expected situation/ideas:
Reduce file size's
Have the project organized(get rid of useless classes/files)
No more un used imports.

Could probably break this down into multiple different issues...
But I linked a PR which updates the README file :)


Build(deps): Bump keycloak-js from 18.0.0 to 18.0.1 (#3654)

Pull request opened by the merge tool on behalf of #3654

Merged in 10f8ed0f95d4953f9efb5466b7e1e1392fc497bb


Regex Tester: Not matching correctly, Sql Select

Current behavior
Using the Regex Tester to find a simple regex for a SQL select statement.
I settled for ^(SELECT|select)\s.*\s(FROM|from)\s.*\s(WHERE|where)(\s.*\s=\s.*\s)*$ with the follwoing test data:
SELECT * FROM system:objects WHERE tag = 5
select city from system:objects WHERE name = 'name'
select city from system:objects WHERE name = 'name' and tag = 0
select name from table where
select name from table where

The first three lines match. The two last ones dont.
How to reproduce it (as minimally and precisely as possible)
Open the Regex Tester.
Paste above mentioned regex.
Paste above mentioned test data.
First three lines match.
Expected behavior
None of the lines should match. I ran my code with that regex, and everything failed.
I cross-checked the Regex with regex101.com and found out that the regex tested in DevToys should not work.
The correct regex is: ^(SELECT|select)\s.*\s(FROM|from)\s.*\s(WHERE|where)\s(.*=\s.*)+$
Screenshots
No response
Workaround
No response
Affected platforms
Windows
Affected DevToys kind
DevToys (app with GUI)
DevToys Version
Version <IP_ADDRESS> | X64 | RELEASE | 94bb8213 | 94bb8213
Relevant Assets/Logs
No response

Hello,
From my understanding (please correct me if I'm wrong), when checking "Global" in Regex101, we get the same result than in DevToys, and DevToys behaves like if this Global option was checked.
When this Global option is unchecked, Regex101 only matches the first line. Do you know if you had this option checked on regex101.com?

I admit that in DevToys, it is not clear what behavior is expected. I'm planning to add this option in DevToys 2.0 (I'm currently working on it).
Thanks

Yes, I ran it with global and multiline enabled. I also enabled multiline in DevToys.
The issue is with the first Regex, which I thought would work, because of the feedback from DevToys:
^(SELECT|select)\s.*\s(FROM|from)\s.*\s(WHERE|where)(\s.*\s=\s.*\s)*$

The same Regex (*$ at the end) gives truly another result on regex101:

After I corrected the Regex on regex101 (+$ at the end) the output is the same:

That is quite interesting! Thanks for sharing!

So, here is some good news 😁
I'm currently porting the RegEx Tester tool to DevToys 2.0, and I think I'm doing it better.
First, the regex that was producing some odd highlighting compared to Regex101.com now behaves as on Regex101:

Second, I added some colors to make the matches easier to group.

Does that look better?
Please note that this is a work in progress though. It's not done.

Thank you very much for sharing!
Yes, that looks indeed promissing 👍
I am looking forward to the release 2.0


work item: add support for watch reconnection

Currently the API level watch reconnection is not supported yet. this will need to be added on to further ensure GRS functionality and ensure the persistence ( cache and/or disk) of the CRV for re-watch(especially with restart ).

for short term, can live with it. so push to post 1230


test failure: impossible GUM constraints test broken in Canary

@alvestrand: travis builds of canary (which has the experimental web platform flag on) fail in the
Call getUserMedia with impossible constraints

test. I suspect that is because you recently added support for that but this bogus case is not rejected (yet). Can you check if the test makes sense to you and fix it before unflagging the feature?
(another issue caught by tests \o/)

This is interesting .... I found code in Chrome that treated mandatory framerate 0 specially (setting it to 1 instead of failing). I made it accepted without comment and marked it as "needs investigation to see if anyone uses this".
I'll have to look at what the errors are.

I think that code might have something to do with fractional framerates.

Closing. We should consider unit tests instead.


GEP-1619: Enumerate common configuration for session persistence and affinity

What type of PR is this?
/kind gep
What this PR does / why we need it:
This update adds concrete configuration for session persistence and affinity to help lay a framework for future potential API design.
We are building iteratively on GEP-1619 by taking small steps towards a workable solution. This PR does not introduce concrete API design yet, but that is expected to come in the near future.
Review this GEP PR with Markdown Rendered: https://github.com/gcs278/gateway-api/blob/gep-1619-cookie-configuration/geps/gep-1619.md
Which issue(s) this PR fixes:
NONE
Does this PR introduce a user-facing change?:

NONE

/ok-to-test

@robscott asked me to take a look at this PR since I have similar ideas for an API for stateful session affinity that is currently modeled as a vendor extension.

For the "Security and Privacy Implications" section we may also want to mention the impact of IP reuse - say in Kubernetes a new pod gets the IP of a recently shut down pod and hence receives session persistent traffic meant for the old pod.

For the "Session Initiation" section: I think there is a 3rd case of the client initiating a session - by not including a cookie or a header in a request. A cookie or header is always present for an "in-session" request but for a request initiating a new session this will not be present. In fact this case is probably more common than a "gateway" initiating session.
Also I am wondering if we have to mandate that a client has to use a cookie or header returned in a previous response. I think there might be cases where a client may use a locally generated value for a header (or even a cookie but less likely) which is then used by a gateway/proxy to figure out if this is for an existing session or a new session.

For the "Session Initiation" section: I think there is a 3rd case of the client initiating a session - by not including a cookie or a header in a request. A cookie or header is always present for an "in-session" request but for a request initiating a new session this will not be present. In fact this case is probably more common than a "gateway" initiating session.
Also I am wondering if we have to mandate that a client has to use a cookie or header returned in a previous response. I think there might be cases where a client may use a locally generated value for a header (or even a cookie but less likely) which is then used by a gateway/proxy to figure out if this is for an existing session or a new session.

I don't think we should mandate - there are use cases for using a cookie or header obtained in other ways to
bootstrap the session. I also don't see what mandating would do - there is no way to enforce that.
A client may also decide to stop passing the cookie - for example to start a new session.

One lesson from Istio is that mixing layers and too many things in one API is not ideal...
There are plenty of load balancing policies - some ring hash based, etc. We may need a way for users to pick one. But I don't think 'cookie or header based strong affinity' should be mixed with this.
I mentioned in one of the comments that K8S already has an equivalent in Service.sessionAffinity=ClientIP -
"If you want to make sure that connections from a particular client are passed to the same Pod each time, you can select the session affinity based on the client's IP addresses by setting .spec.sessionAffinity to ClientIP for a Service (the default is None).
Session stickiness timeout
You can also set the maximum session sticky time by setting .spec.sessionAffinityConfig.clientIP.timeoutSeconds appropriately for a Service. (the default value is 10800, which works out to be 3 hours)."
Obviously we can't extend Service - and the cookie/header session affinity works in a broader context, but we should
take this into account too. It is not a 'load balancing' option, but session affinity option.

...
I don't think we should mandate - there are use cases for using a cookie or header obtained in other ways to bootstrap the session. I also don't see what mandating would do - there is no way to enforce that.
A client may also decide to stop passing the cookie - for example to start a new session.

Yes, we are saying the same thing (I think) so I am in agreement.

One lesson from Istio is that mixing layers and too many things in one API is not ideal... There are plenty of load balancing policies - some ring hash based, etc. We may need a way for users to pick one. But I don't think 'cookie or header based strong affinity' should be mixed with this.
...
. It is not a 'load balancing' option, but session affinity option.

Actually session affinity/persistence is kind of related to "load balancing" - it is the exact opposite of load balancing. The goal is to keep sending requests (that match certain criteria) to a single backend instead of trying to balance load. So if all of the requests in a certain load balancer/proxy case have to obey the session persistence/affinity semantics then there is no (or very little) load balancing happening.
Given this, I think session persistence/affinity is an attribute of a load balancing policy. What it basically says is that if a request has to be routed based on session affinity/persistence, then route it but if that does not apply (e.g. there is no cookie or header for it) then use the load balancing algorithm dictated by the policy.

One lesson from Istio is that mixing layers and too many things in one API is not ideal...

Given this, I think session persistence/affinity is an attribute of a load balancing policy. What it basically says is that if a request has to be routed based on session affinity/persistence, then route it but if that does not apply (e.g. there is no cookie or header for it) then use the load balancing algorithm dictated by the policy.

@sunjayBhatia @costinm I think this is a really good back and forth. In my other comments, I think we've come to the conclusion it's best to keep separate definitions of persistence and affinity, regardless of our future API design. It will be more important to keep these definitions if we keep the API structures separate, but it doesn't hurt if we decide to bundle them together in a LoadBalancing-oriented API structure (like istio).
This API design debate seems like a really good conversation to bring up in the next PR in which we start designing a spec.

This has been a great discussion, but I agree that it's probably time to round out this initial cut, get the Provisional version merged, and leave implementation for later.

Actually session affinity/persistence is kind of related to "load balancing" - it is the exact opposite of load balancing. The goal is to keep sending requests (that match certain criteria) to a single backend instead of trying to balance load. So if all of the requests in a certain load balancer/proxy case have to obey the session persistence/affinity semantics then there is no (or very little) load balancing happening.

I wouldn't say its the exact opposite of load balancing. Rather its a two tier decision logic where we say 1) if we have a session identity provided in the request then route according to previous state/contract otherwise 2) Load balance as per LB configuration

...
I wouldn't say its the exact opposite of load balancing. Rather its a two tier decision logic where we say 1) if we have a session identity provided in the request then route according to previous state/contract otherwise 2) Load balance as per LB configuration

I was trying to take a high level view in terms of the goal of each feature: a load balancer's goal is to spread (or "balance") the load among a set of backends (equally or based on some other criteria such as capacity) whereas the goal of a persistence/affinity feature is to not spread it but rather keep it stuck to one backend as far as possible.
We can model the behavior as you have described for the purpose of defining the API: if the policy dictates routing based on session identity then do it otherwise load balance based on some LB configuration.

This has been a great discussion, but I agree that it's probably time to round out this initial cut, get the Provisional version merged, and leave implementation for later.

I would like to see a proposal for the API but it still says TBD in the "Session Affinity API" section. Will it be part of this PR?

This API design debate seems like a really good conversation to bring up in the next PR in which we start designing a spec.

So this PR won't include the API definition? Just clarifying.

We should capture any outstanding concerns that aren't easily rectified yet as part of a TODO-type section.

Added an additional open question in https://github.com/kubernetes-sigs/gateway-api/compare/df8eba0fa6ee7747822b0a6381016be541a6e21f..37d18517ea87f4b2271bad98e5f3436bf993b4af regarding discussion on API design.
Otherwise, I think our TODO section captures what we need todo. The biggest one being We need to design and document an API for session persistence and/or session affinity in the Gateway API spec. We'll tackle that in the next PR.

I like how Rob's review is from 14 hours ago, but the individual comments say last week. He wasn't kidding when he said he had a review in progress for a while that he just hadn't submitted yet :joy:

CloudRun is different - and I'm sure google has a few more :-)
On Wed, May 3, 2023 at 10:46 AM Grant Spence @.***>
wrote:

@.**** commented on this pull request.
In geps/gep-1619.md
https://github.com/kubernetes-sigs/gateway-api/pull/1935#discussion_r1184029023
:

+| Hashicorp Consul  	| Implementation (Envoy) 	| N/A 	| Supports Gateway API Only* 	| N/A 	| Hashicorp Consul solely uses Gateway API; therefore, it doesn’t yet have a way to configure session persistence. Hashicorp Consul API Gateway Docs 	|
+| Kuma 	| Implementation (Envoy) 	| None 	| None 	| None 	| Kuma has no documentation on how it supports session persistence or cookies. Kuma Docs 	|
+| Cilium 	| Implementation / Dataplane 	| None 	| None 	| None 	| Cilium has no documented way of doing session persistence. Cilium Docs  	|
+| Kong 	| Implementation / Dataplane 	| Cookie-Based 	| cookie_name=namerolling_timeout=timeoutabsolute_timeout=timeoutidling_timeout=timeoutcookie_path=pathcookie_domain=domaincookie_same_site=[Strict | Lax | None | off]cookie_http_onlycookie_secure=[true | false]stale_ttl=durationcookie_persistent=[true | false]storage=storage_type 	| Route, Service, Global (Route or Backends or Global) 	| N/A 	|
+|  	|  	| Header-Based 	| name 	| Upstreams (Backends) 	|  	|
+| Traefik 	| Implementation / Dataplane 	| Cookie-Based 	| name=namesecurehttpOnlysameSite=[none | lax | strict ] 	| Services (Backends) 	| N/A 	|
+| Google CloudRun	 	| Implementation / Dataplane 	| Cookie-Based 	| Enabled / Disabled 	| Service (Backends) 	| Only allowed to turn off or on, no other configuration items 	|
+| Flomesh Service Mesh 	| Implementation / Dataplane (Pipy) 	| ? 	| ? 	| ? 	| ? 	|
+| HAProxy Ingress 	| Implementation (HAProxy) 	| Cookie-Based 	| affinity (enable/disable)cookie-key=keysession-cookie-domain=domainsession-cookie-dynamic=[true | false]session-cookie-keywords=keywordssession-cookie-name=namesession-cookie-preserve=[true | false]session-cookie-same-site=[true | false]session-cookie-shared=[true | false]session-cookie-strategy=strategysession-cookie-value-strategy=value_strategy	 	| Backend (Backends) 	| N/A 	|
+| Apache APISIX 	| Implementation (Nginx) 	| Cookie-Based 	| hash_on=[vars | header | cookie | consumer]key=cookie_name 	| Upstream (Route or Backends) 	| N/A 	|
+|  	| Implementation (Nginx) 	| Header-Based 	| hash_on=[vars | header | cookie | consumer]key=header_name 	| Upstream (Route or Backends) 	| N/A 	|
+| NGINX Kubernetes Gateway 	| Implementation (Nginx) 	| N/A 	| Supports Gateway API Only 	| N/A 	| *NGINX Kubernetes Gateway solely uses Gateway API; therefore, it doesn’t yet have a way to configure session persistence. Nginx Kubernetes Gateway Docs 	|
+| Java Servlet 	| Web Server 	| Cookie-Based / URL-Encoded 	| invalidate()setAttribute(String name, Object value)setMaxInactiveInterval(int interval) 	| N/A 	| Java Servlets do not natively support proxy functions. 	|
+| Apache httpd 	| Web Server 	| Cookie-Based / URL-Encoded 	| Cookie Attributes 	| N/A 	| N/A 	|

+Session Affinity
Added Google GKE, but left Google Cloud Run, let me know if I am
conflating the two
—
Reply to this email directly, view it on GitHub
https://github.com/kubernetes-sigs/gateway-api/pull/1935#discussion_r1184029023,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AAAUR2T3FWDV5POVEKID6MDXEKKYZANCNFSM6AAAAAAW6XBIAQ
.
You are receiving this because you were mentioned.Message ID:
@.***>

/lgtm
I'll leave the hold though until @gcs278 has a chance to address those nits.

Thanks @gcs278!
/lgtm

/hold cancel

Noone ever mentioned #1619 to create the link, sigh.


Update README.md with corrected order_data Hash

This PR corrects the example provided in README.md, according to the most recent documentation: https://www.tremendous.com/docs
Also provides instructions for people running recent versions of rails, as the most recent code from master branch hasn't been published on rubygems just yet.

Hey @JulienDefrance  - thanks for the PR. I incorporated your tweaks and pushed an update of the readme to master. LMK if you have any other issues!


esrv_youtube crashes WACUP

Pre-Requisites:

Install Preview Version: <IP_ADDRESS>56 (x86) from https://getwacup.com/preview/
Download the WinampEasyService 2023-09-23 Release Binaries
Put the ml_easysrv and in_easyfngetter plugins in the WACUP Plugins folder
Also put isrv_managed in the WACUP Plugins folder
Copy the content of WinampEasyServicePlugins to the Plugins folder

Steps:

Open WACUP & the Media Lib (Alt-L)
In the services tab go to YouTube
Click Invoke Plugin & enter a search term
After some time, or on the next click WACUP will crash

System:

Windows 11 Pro build 22621.2215
dotnet 6.0.22

Hi!
Try setting this...:
WACUP Preferences -> Playlist -> Titles|ATF -> Metadata Reading
...to this...:
Read metadata only when fie(s) are played
... and try again.

Unfortunately, srv_youtube is the most unstable of the plugins.

Does this still happen?

I don't have the same PC anymore, so I tried with a fresh install ( and WACUP Preview v<IP_ADDRESS>40 ) and these plugins don't load at all.

Duplicate of #2


Get version number

Is it possible to add version number to ease traceability/identification?
In js header (traceability):
/*! remark 0.12 | (c) 2011-2015 Ole Petter Bang */

In js code (identification, e.g. display remark version):
  version : "0.12"

This is fixed in #225 and will be included in the upcoming release 0.11.

Version 0.11 which fixed this has now been released.


Fix kuzzle tests with FastAPI

Besides tweaking the parameters validation, it is also necessary to define a custom formatter for datetimes, in order to preserve the same format.

Thanks!


No Intro Videos crashes, no other mods

Bug
Simple: I wanted to not have to watch the videos and press the spacebar numerous times just to start playing so I got this mod:
https://www.nexusmods.com/cyberpunk2077/mods/533?tab=description
I purchased the base game plus the expansion pack packaged as one. Installed that mod and eventually installed CyberEngineTweaks.
I then removed the skip videos mod, had GOG verify the install files, reinstalled CyberEngineTweaks and it no longer crashes. So that is my confirmation. If there is another way to automatically skip videos I'm open to it. I consider this report in the "nice-to-have" category.

Hi there.
That mod does not require Cyber Engine Tweaks. So opening an issue here I don't think will help you.
Please post on nexus forum for this issue.


Fixed getFilteredECListForWords ignoring the first occurence of an entity.

When updating getFilteredECListForWords to IdTables I apparently messed up the building of the filter HashMap used to map entity ids to their row in the filter table. When the filter table is size 1 another optimized method that uses a HashSet is used instead, which is why this didn't affect #240 .
This should fix #239, but I haven't been able to test this on wikidata yet. @niklas88 is there an easy way of testing this?

When updating getFilteredECListForWords to IdTables I apparently messed up the building of the filter HashMap used to map entity ids to their row in the filter table. When the filter table is size 1 another optimized method that uses a HashSet is used instead, which is why this didn't affect #240 .
This should fix #239, but I haven't been able to test this on wikidata yet. @niklas88 is there an easy way of testing this?

You can built a docker image on galera and then follow the /local/data/qlever/wikidata-full/README.md to run the wikidata-full index with wharfer where you of course have to replace niklas88/qlever with your newly built image. If you also rename the --name param you don't even need to stop the current instance.

Sadly I haven't found a way to trigger this on scientists, it would be great to have an End-to-End test for this


Download Bars !!

Why aren't there any download progress bars to check upon the download and installation of the extensions. There are over 10000 of them. Imagine how much we need them. Developers are humans too!!

i think its a duplicate

/duplicate


How to solve the invalid repo problem

Hello,
I have utterances installed in my GitHub account, and it has access to the repository I want it to have access to: rscharfer/myblog.
This is the script I am using in my app.
<script
          src="https://utteranc.es/client.js"
          repo="https://github.com/rscharfer/myblog"
          issue-term="pathname"
          theme="github-light"
          crossOrigin="anonymous"
          async
        ></script>

For some reason, I am getting the error Uncaught Error: Invalid Repo.  Does anyone have an ideas?

You don't include the full repo URL. Just username/reponame would work. There is a form to generate the script for you at the official site, you should start there.

Thank you!!

You don't include the full repo URL. Just username/reponame would work. There is a form to generate the script for you at the official site, you should start there.

True, but it doesn't spell out — as you did — that it should be in that format. Thanks for making it clear; I was having the same problem as @rscharfer and was glad to see the answer here.


Added Visual Studio to readme's support list

Alphabetized the list of supported editors too...
Fixes #1042.

Thanks @JoshuaKGoldberg!


Expose TransactionBuilder.setLockTime()

BITBOX.TransactionBuilder needs to expose setLockTime which is part of bitcoincashjs-lib.
https://github.com/bigearth/bitcoincashjs-lib/blob/0a7fc7cf23551503f57689db4c930b8136db954c/src/transaction_builder.js#L488

Handled here https://github.com/Bitcoin-com/bitbox-sdk/commit/b3f3fe210d4f3d3310db7092e0c466a4d389f62f


PIF CC assist is showing wrong number, duplicating button

Defective ToolKit Feature Name: Pay in full credit card assist
Expected Behavior
Credit account where the balance matches available is not highlighted yellow. Button to rectify available appears once with correct value.
Actual Behavior
One credit account with available matching balance is showing in yellow. Rectify button is showing twice, once with correct value (+0) and once with an incorrect value (+4.68). Screenshot attached--top of two yellow highlighted is behaving correctly, bottom is the weird one.
Steps to Reproduce the Behavior

Have credit accounts.
Observe matching balance and available.
Also observe incorrect colour and rectify value.

Export of Toolkit Settings (Bottom Left of Settings Page)
[{"key":"accountTransactionSearch","value":false},{"key":"accountsClearSelection","value":true},{"key":"accountsDisplayDensity","value":"0"},{"key":"accountsEmphasizedOutflows","value":false},{"key":"accountsRowHeight","value":"0"},{"key":"accountsSelectedTotal","value":false},{"key":"accountsStripedRows","value":false},{"key":"activityTransactionLink","value":true},{"key":"betterScrollbars","value":"0"},{"key":"budgetBalanceToZero","value":true},{"key":"budgetProgressBars","value":"0"},{"key":"budgetQuickSwitch","value":false},{"key":"budgetRowsHeight","value":"0"},{"key":"calendarFirstDay","value":"0"},{"key":"categoryActivityPopupWidth","value":"0"},{"key":"changeEnterBehavior","value":true},{"key":"checkCreditBalances","value":true},{"key":"checkNumbers","value":false},{"key":"closeReconcileWindow","value":false},{"key":"collapseExpandBudgetGroups","value":false},{"key":"collapseSideMenu","value":false},{"key":"colourBlindMode","value":false},{"key":"compactIncomeVsExpense","value":false},{"key":"currentMonthIndicator","value":true},{"key":"daysOfBuffering","value":false},{"key":"daysOfBufferingHistoryLookup","value":"0"},{"key":"editButtonPosition","value":"2"},{"key":"enableRetroCalculator","value":true},{"key":"enlargeCategoriesDropdown","value":true},{"key":"enterInRegisterNow","value":false},{"key":"goalIndicator","value":false},{"key":"goalIndicatorWarningColor","value":true},{"key":"googleFontsSelector","value":"0"},{"key":"hideAOM","value":false},{"key":"hideHelp","value":true},{"key":"highlightNegativesNegative","value":false},{"key":"importNotification","value":"1"},{"key":"incomeFromLastMonth","value":"1"},{"key":"l10n","value":"0"},{"key":"largerClickableIcons","value":true},{"key":"monthlyNotesPopupWidth","value":"0"},{"key":"navDisplayDensity","value":"0"},{"key":"pacing","value":"0"},{"key":"popupCalculator","value":false},{"key":"printingImprovements","value":true},{"key":"privacyMode","value":"2"},{"key":"reconciledTextColor","value":"1"},{"key":"removePositiveHighlight","value":false},{"key":"removeZeroCategories","value":true},{"key":"reports","value":false},{"key":"resizeInspector","value":false},{"key":"rightClickToEdit","value":true},{"key":"runningBalance","value":false},{"key":"seamlessBudgetHeader","value":false},{"key":"showIntercom","value":true},{"key":"spareChange","value":false},{"key":"splitKeyboardShortcut","value":false},{"key":"splitTransactionAutoAdjust","value":true},{"key":"squareNegativeMode","value":true},{"key":"stealingFromNextMonth","value":true},{"key":"swapClearedFlagged","value":true},{"key":"toBeBudgetedWarning","value":false},{"key":"toggleSplits","value":false},{"key":"toggleTransactionFilters","value":"0"},{"key":"warnOnQuickBudget","value":true}]
System Settings
ToolKit Version:
Operating System (Mac/Windows/Etc): Windows 10
Browser (Chrome/Firefox/Safari): Chrome
Browser Version: 56.0.2924.87 (64-bit)
Other Extensions: Avira Browser Safety, Chromium Wheel Smooth Scroller, HTTPS Everywhere, LastPass: Free Password Manager, Magic Actions for YouTube, Right Click Opens Link in New Tab, Save to Pocket, uBlock Origin

Can confirm I'm seeing the double button (not with different numbers though) maybe @blargity  can tackle this one :P

Closing this old issue which is being tracked in #928 which has a PR submitted for it.


Babel error with custom .babelrc since 0.26

I integrate react-native in a existing application.
I created a subfolder js with the javascript and start it with this activity:
mReactInstanceManager = ReactInstanceManager.builder()
            .setApplication(getApplication())
            .setBundleAssetName("index.android.bundle")
            .setJSMainModuleName("js/index.android")
            .addPackage(new MainReactPackage())
            .setUseDeveloperSupport(BuildConfig.DEBUG)
            .setInitialLifecycleState(LifecycleState.RESUMED)
            .build();

In the js folder I have a .babelrc containing:
{
    "presets": ["react-native"]
}

In my root folder (which also contains node_modules) I have another .babelrc which I need for other build-steps:
{
    "presets": ["es2015"]
}

Since 0.26 react-native complains when I have this file with "es2015" in it. When I delete it, it works:
> SyntaxError: <project>/node_modules/react-native/Libraries/vendor/emitter/EventEmitter.js: Unexpected token (56:13)
>   54 |    */
>   55 |   addListener(
> > 56 |     eventType: String, listener, context: ?Object): EmitterSubscription {
>      |              ^
>   57 |     return this._subscriber.addSubscription(
>   58 |       eventType,
>   59 |       new EmitterSubscription(this._subscriber, listener, context));

This is expected, since files under node_modules get transpiled with the config at the project root. I don't think this is a new behaviour with 0.26

It might have to do with babel, but I don't think so. I tried several older babel version before 6.9 and they didn't work either. It seems to me that the react-native-preset changed with 0.26?

It's been always like that with Babel. No idea how it ever worked for you. May be earlier it worked because of some caching issue.
@facebook-github-bot expected

Webpack starts looking for your babelrc from the point of entry. once it finds it will use that one. You might consider mulitple entry points. https://webpack.github.io/docs/configuration.html

I don't have a webpack config in this project.

@fab1an Mostly because no one has set it up yet. It'd be awesome if you could send a PR for it.

I can check it out, but I guess a simple babel src -d lib step won't do, at the size of this project. :D

The packager caches files that haven't been modified, so precompilation doesn't help that much and adds more complexity to source maps and the build. For RN I've found it's much better not to publish compiled files to npm -- the subset of JS defined by babel-preset-react-native is the language of RN, not ES5.

@ide I'd say that not pre-compiling has actually resulted in tons of issues with Babel config and such,

It's quite problematic to use with other code which is pre-compiled with Babel
Sourcemaps are screwed up when you've dependency that has a .babelrc with different config, sometimes it even breaks the code
It's kinda difficult to use different configs for the other code when the project has different types of code mixed, so you're pretty much locked to use RN's preset for everything
Since the packager transpiles node_modules, we've to be careful about which transforms we enable not to affect third party code, for example, enabling strict mode breaks many third party modules

Though it's not really RN not being pre-compiled, but packager transpiling code it's not supposed, the simplest solution is to pre-compile RN code. I personally had lots of issues with it which wouldn't exist if RN was pre-compiled.
I think @cpojer also wanted to do this to improve Jest's performance. @davidaurelio also said that he wanted to do this.

Well, the same language (es2015 + jsx + some extensions) is used by quite a few other projects as well.
The problem with not pre-compiling is that it's really hard to write any code that depend on react-native.
I just published a styling module (https://github.com/fab1an/react-native-tachyons) and couldn't use react-native's StyleSheet because I would have to somehow transpile react-native's code in my plugin. This is a gigantic source for potential errors.

Addendum: Issues like this might also go away with precompilation: https://github.com/facebook/react-native/issues/7679
I can try to help out here, but I need some support:
Everything seems to be imported from "react-native/Libaries/react-native". So possibilities:

a) Move all Javascript out from there into a separate src folder with the same structure and compile it into the place it was before or
b) Compile javascript into a different dist directory and change package.json to reference that.

I think a) would be easier.

Does some of the javascript code in Libraries/ rely on non-js files being in the same directory?

Ok, what I did so far:

copied the whole Libaries folder and cleaned out any non-js files:

 cp -R Libraries/ src/
 find src -type f -not -name "*js" -print0 | xargs -0 rm

created a .babelrc in src and installed the presets and plugins:

{
    "presets": ["es2015", "react"],
    "plugins": [
      "transform-object-rest-spread",
      "transform-class-properties",
      "syntax-trailing-function-commas",
      "babel-plugin-syntax-async-functions"
    ]
}

compiled everything from src back into Libraries
node_modules/.bin/babel src/ -d Libraries

replaced require('React') with require('react') to clear the warnings
One warning still appearing is:

You or one of the Babel plugins you are using are using Flow declarations as bindings.
Support for this will be removed in version 6.8. To find out the caller, grep for this
message and change it to a `console.trace()`.

linked this using npm link into an existing project and tried running the packager:
(./node_modules/react-native/packager/packager.sh start --reset-cache)

This gives me an error about files being duplicated:
[12:47:16 PM] <END>   Building (deprecated) Asset Map (68ms)
Failed to build DependencyGraph: @providesModule naming collision:
Duplicate module name: NavigationTreeNode
Paths: /Users/fabian/dev/forks/react-native/Libraries/CustomComponents/Navigator/Navigation/NavigationTreeNode.js
collides with /Users/fabian/dev/forks/react-native/src/CustomComponents/Navigator/Navigation/NavigationTreeNode.js

For testing purposes I just moved the src folder (the original source) elsewhere and ran the packager again.
Now I don't get warnings by the packager but a 404 on the phone:

(my react-native entry is in js/index.android.js)
I don't know anything about haste or the packager, so any clues on how to proceed?

Ok, the next thing I will try is trying to serve everything from webpack directly and circumvent the packager.
What is the packager used for besides compiling from babel?

@fab1an module bundling, hot reload, serving and bundling assets etc.

Mhm, but all of that are things that webpack can do, can't it?
Anyway, I tried serving things from webpack-dev-server now, which needs https://github.com/yuanyan/haste-resolver-webpack-plugin to be able to resolve react-native's files.
I get a ton of errors, especially from files in Libraries/CustomComponents/NavigationExperimental/ which do require("react-native") themselves.
I think i'll stop my efforts now, because I just don't know enough about haste.
I hope we'll see precompiled react-native sometime anyway ;)

@fab1an feel free to take stab at pre-compiling if you want

See my comments above, I spent about 5 hours here, I precompiled the source, but (I think) haste is getting in the way.
My install fail with messages like "DEV" isn't defined etc. No idea what to do with them.

@fab1an Oh sorry, missed it.

created a .babelrc in src and installed the presets and plugins:

You need to use babel-preset-react-native to compile the files

This gives me an error about files being duplicated:

You need to remove the source files/duplicate compiled files. RN packager uses Haste and there'll be conflicts when 2 files have same @providesModule declaration
After compilation, you might wanna add node_modules to your .babelignore to ensure that babel transforms are not applied to RN files again,

I did all that, but at the moment, I'm stuck with this error: https://github.com/facebook/react-native/issues/7814
(Without any precompilation or something)

Is it __DEV__ or DEV? If it's DEV, it's certainly a typo, and you can try changing it to __DEV__.

DEV

@fab1an Looks like a typo somewhere. try changing it to __DEV__.

@satya164 Look at the line 15 in the bug that is linked:
../node_modules/react-native/Libraries/react-native/react-native.js:15
it says __DEV__ there. It is not a typo, it's some weirdness by node-haste (I guess).

@fab1an Hmm... Got confused by Markdown changing the __.
It's weird. I've been using 0.26 and never had this issue. One quick workaround can be to set it global.__DEV__ = true until we figure out the issue.

Also, are you on master? Is this a clean install? If your example is reproducible, will be great if you can push it to GH and link to it in that issue.

I'm on a custom project using react-native master, like stated earlier in this thread. When I set __DEV__ like you said the next thing I get is
[node-haste] Encountered an error while persisting cache:
> Error: Cannot find module 'ReactNative'
>     at Function.Module._resolveFilename (module.js:440:15)
>     at Function.Module._load (module.js:388:25)
>     at Module.require (module.js:468:17)
>     at require (internal/module.js:20:19)
>     at Object.<anonymous> (/Users/fabian/dev/react-native/Libraries/react-native/react-native.js:177:27)
>     at Module._compile (module.js:541:32)
>     at Object.Module._extensions..js (module.js:550:10)
>     at Module.load (module.js:458:32)
>     at tryModuleLoad (module.js:417:12)
```

Unfortunately I don't have any more time to look into this, I already spent hours here.

I know how to work with "normal" es6, babel and node-requires, but since `react-native` seems to have it's own package manager and module resolving it's just a depressing hunt for invalid path for me, so good look to the next person :).

@fab1an It'll be great if you can push what you already have.

@satya164 This is my branch. Contrary to what I said in this thread I know compiled from Libraries to dist and not the other way round now, to get a nicer diff.
https://github.com/fab1an/react-native/tree/precompile-babel

@fab1an Thanks. Will check it out when I've time.

Great, I'm sure it's worth it.
Building, transpiling and packaging is always a pain, so better stick with how everybody else is using babel, webpack etc… IMHO.

I opened a proper bug for that, closing this.


Add Outputs base class

Adding base class for outputs and the unit testing. Testing is a bit empty, but I guess we will see more once we implement other cases.

(please, disregard the failing pipeline; tests are passing locally)

will review after lunch

Just finished some first version, feel free to do another review.
You can also resolve threads when you feel you satisfied with the resolutions.

Pull Request Test Coverage Report for Build<PHONE_NUMBER>
Details

23 of 23 (100.0%)  changed or added relevant lines in 2 files are covered.
No unchanged relevant lines lost coverage.
Overall coverage increased (+21.9%) to 88.571%

Totals

Change from base Build<PHONE_NUMBER>:
21.9%

Covered Lines:
31

Relevant Lines:
35

💛  - Coveralls


Map Performance

We can further increase the performance:
The map needs two ajax calls to render. One for the "map_custom" feature and one for the QSOs.
By writing the map_custom stuff into the sessiondata and a JS variable we can reduce the time for loading the maps.
To accomplish this I moved the ajax targets (controller functions) into the optionslib to make it available.
On Dashboard, Logbook and LBA we now have one sql query and one ajax call less. You feel that the map is loading a bit faster.
On Exportmap and Visitor View we just have one ajax call less since we don't have sessiondata here. But you also feel an improvement.

This one gains speed for Visitor-Map and LBA because the ajax was eliminated.
On the other hand it adds a (unnecessary) Call to nearly EVERY Page/View and wastes sesion_var-Space for data which is only needed at maps.
Proposal: Eliminate those AJAX-Calls (good idea) by fetching the data at controller-level for those pages where it is needed directly in PHP

You are right.. Could have thought that myself. Changes made. Still fast :)


Prevent a dependency from installing if it has some flag.

Is that possible to add a feature that would allow to ignore some dependencies when running install if their version, or name have a prefix?
It could look like this:
{
  "name": "MapEditor",
  "version": "0.0.1",
  "dependencies": {
    "leaflet": "~0.7.3",
    "-leaflet-dev": "0.8.*"
  }
}

It means that bower should install leaflet 0.7.3 as usually and ignore leaflet-dev 0.8 because there is a minus in its name as a prefix.
It won't break JSON format and easy to use to include/exclude some dependencies temporarily so that not to have to remember all the used libraries which can be eventually needed.

This is probably duplicate of #1394