why saleor itself is not using ariadne?

Is ariadne still not production ready for scalable apps?

Saleor has a large existing API, migrating it would not be an easy task.

Has anyone already started migrating existing api to ariadne?


Align API with TF

Aligns the backend API and functionality (NaN propagation, dtype strictness, kernel signatures) with TensorFlow Python.

Remove backend.minPool since TF doesn't have it.
Remove normRegion param in localResponseNormalization kernel since TF doesn't support it.
Remove leakyRelu, prelu and preluDer from the backend and implement using higher-level ops, aligning with TF Python.
Make backend.multinomial take logits instead of probabilities and normalized: boolean param for backwards compatibility.
argMin and argMax take single axis: number instead of axes: number[]
Change eluDer(x: T): T signature to eluDer(dy: T, y: T): T to align with TF.
Change NaN behavior of max/avgPool and conv2d to align with TF.
Change avgPool out of bounds (padding) behavior to align with TF
Require indices in oneHot and gather to be of dtype int32

Fixes tensorflow/tfjs#195

This change is

Nice observation! Yes, those will be removed as part of that PR

Reviewed 9 of 18 files at r1, 8 of 14 files at r2.
Review status: 17 of 24 files reviewed at latest revision, all discussions resolved, some commit checks failed.

src/index.ts, line 68 at r2 (raw file):

  gpgpu_util
};
export {WebGLTimingInfo} from './kernels/backend_webgl';

put this under webgl

src/kernels/webgl/pool_gpu.ts, line 108 at r2 (raw file):

        'minMaxValue[0], minMaxValue[1]), minMaxValue[2]), minMaxValue[3])';
    if (poolType === 'avg') {
      returnValue = `avgValue / count`;

why keep an accumulator around when you know this statically?

src/ops/lrn.ts, line 44 at r2 (raw file):

  static localResponseNormalization<T extends Tensor3D|Tensor4D>(
      x: T, radius = 5, bias = 1, alpha = 1, beta = 0.5,
      normRegion: 'acrossChannels'|'withinChannel' = 'acrossChannels'): T {

this will break caffe
can you just throw for the TF backend? I'd like to not break API if possible. Going forward we can reject these changes.

src/ops/multinomial_test.ts, line 31 at r2 (raw file):

    const probs = tf.tensor1d([0.5, 0.5]);
    const seed: number = null;
    const normalized = true;

the API still allows normalized, but we now don't have coverage

src/ops/pool.ts, line 165 at r2 (raw file):

  @doc({heading: 'Operations', subheading: 'Convolution'})
  @operation
  static minPool<T extends Tensor3D|Tensor4D>(

hmm... I depend on this for some channel-normalization stuff in the activation visualization demos. What about just throwing in the backend? Alternatively, we could think about finding a way to expose the WebGL backend directly so we can call a WebGL kernel that does this.

Comments from Reviewable

Thanks for the fast review!

Review status: 17 of 24 files reviewed at latest revision, 5 unresolved discussions, some commit checks failed.

src/index.ts, line 68 at r2 (raw file):
Previously, nsthorat (Nikhil Thorat) wrote…
put this under webgl

Can't do it since it's a type.

src/kernels/webgl/pool_gpu.ts, line 108 at r2 (raw file):
Previously, nsthorat (Nikhil Thorat) wrote…
why keep an accumulator around when you know this statically?

to align with TF avgPool behavior where padded values are ignored (different than treating them as 0)

src/ops/lrn.ts, line 44 at r2 (raw file):
Previously, nsthorat (Nikhil Thorat) wrote…
this will break caffe
can you just throw for the TF backend? I'd like to not break API if possible. Going forward we can reject these changes.

Chatted offline. LRN is rarely used and we are keeping the default behavior.

src/ops/multinomial_test.ts, line 31 at r2 (raw file):
Previously, nsthorat (Nikhil Thorat) wrote…
the API still allows normalized, but we now don't have coverage

Chatted offline. We have webgl and cpu coverage, and there is something we can do later on for other backends.

src/ops/pool.ts, line 165 at r2 (raw file):
Previously, nsthorat (Nikhil Thorat) wrote…
hmm... I depend on this for some channel-normalization stuff in the activation visualization demos. What about just throwing in the backend? Alternatively, we could think about finding a way to expose the WebGL backend directly so we can call a WebGL kernel that does this.

We can use -maxPool(-x) to simulate minPool

Comments from Reviewable


Add a view to easily see precipitation and temperature during the day.

I think it's important to have an overview of the day (or future days) where you can easily see how the temperature or the wind, or expecially the precipitation (probability and amount) evolves during the day, something like this:

Because for now you can only see a simple summary of the days like this:

or you have to manually slowly check every hour by clicking here:

which I think really hurts usability.
Really like the app (and the widget) though, works and looks great, this one thing would make it almost perfect for me (would only be missing some features like air quality and the moon phase).

I feel like a more accurate title would: Charts showing trend of certain data.
Personal thoughts:
Although I think a chart doesn't necessarily goes with the theme of the app, it could be something that the dev could add if they want to.
My take on the implementation:

A card could be added similar to how Breezy Weather does it (shown in video), but instead of the horizontal scrollable bar a vertical drop down menu could be used.
An option to hide the card would also need to be added in the settings
Also, would it be only hourly or daily as well?

https://github.com/darkmoonight/Rain/assets/69535896/6fb7350e-b871-4d8b-96f8-adc0703a9f34

Nobody beats the old Partly Cloudy iOS app that sadly isn't available anymore, but still works for anyone who bought it back in the day.
Within 1 second you immediately have a sense over what happens during the day and precisely when and which conditions combine during specific moments. You just know from a glance because everything is projected on an analog clock face, and you can move the handle to fast-forward the time and glance at future days or the second half of the day if using the 12h regular clock face rather than a zoomed out 24h analog clock.
To this day I'm dying to get that experience on Android since it makes planning your day around weather so easy even on days with rapidly changing conditions.
Here's a lovely little German language demo of the app, Youtube's auto-translated subtitles seem pretty good on this one, but let me know if there are any questions left. :)
https://youtu.be/BNaNZGFvcp4


Update of README.md

Added Windows section to Install, as syft is available as Chocolatey package
https://community.chocolatey.org/packages/syft and https://github.com/marcinbojko/syft

@marcinbojko sorry one more status check can you amend the commit to sign it off?

git commit --amend --no-edit --signoff


Fix adding new location data into POI list

Implements/Fixes #325
This PR is ready for review.
Testing Plan
Manual testing
Summary
In case of appending POI list with new location data there was no update of POI list.
The reason for such behavior - new location data appended into SDL.NavigationModel.LocationDetails array directly instead of using Ember object notification system.
So now, location data appends through Ember object notification system.
CLA

[X] I have signed the CLA

Changes in PR approved. Will make PR to open sdl.


Add a simple fee payer transaction example

Description

Add simple fee payer transaction example
Modify existing simple transfer example

Might be better to encourage to use getAccountCoinsData query to check account balance instead of getAccountResource. Even better to have a query to check account balance that return the amount prop returned from getAccountResource.
Anyway, we should wait for https://github.com/aptos-labs/aptos-ts-sdk/pull/48#pullrequestreview-1677681796 so we don't need to use sleep.
Test Plan
run all tests

need to ctrl + f replace sponser with sponsor:D

Probably want to update the README file in /example as well @0xmaayan


Blueprint "extras" module with pre-built generic components.

It would be great to create a new blueprint-extras or blueprint-components repo/module which provided users with a set of reusable components to get up and running.
For example, blueprint-extras could supply a generic  implementation which handles value changes etc. This component could work in a similar fashion to juce::Slider and still allow users to customise the slider's behaviour with onDraw, onValueChanged props etc.
Part of this "extras" module could also include juce-wrapper components as discussed here: https://forum.juce.com/t/introducing-blueprint-build-native-juce-interfaces-with-react-js/34174/25
@nick-thompson I'd be interested to hear your thoughts about this in regards to how such a project could be kicked off.

Yes! I meant to mention this in our conversation, but looking back over our chats I obviously forgot :)
At the root of the current repository is a blueprint/ directory holding the "blueprint core juce module." Right now, especially as blueprint continues to evolve quickly and as the "extras" module grows, I think it makes sense to just keep it right here– probably just a blueprint_extras/ directory at the root, with its own JUCE Module stuff. As its own module, it will maintain its independence, and if at some point it makes more sense to move it out into its own repo it'll be a trivial task
What do you think? I think your juce::Slider wrapper from our forum discussion is a great first add, and a "slider example" project to show the different approaches would probably be super helpful

Yeah that sounds like a great start to me!

I'll be writing a couple of "generic" component classes over the next few days for my current project so once I'm happy with them I'll be sure to send a PR across with this.

Great, excited to see it! Thanks

Picking this back up after a great convo in #70
Structurally, I imagine this work residing in two places: on the native side, we'll create a new JUCE Module, blueprint_extras right next to the blueprint module at the top level of this repo. This module should have a dependency on the core blueprint module. Next, we'll have the javascript side in a new package next to packages/juce-blueprint maybe just called packages/blueprint-extras (we'll be undergoing a big rename following #34 presumably, so names don't matter so much here right now).
On the native side, we're thinking about some free-standing helper functions for registering native methods bound to a juce::AudioProcessorValueTreeState: https://github.com/nick-thompson/blueprint/issues/70#issuecomment-655545516. We're also thinking about those native components mentioned above which wrap specialized juce components such as juce::Slider and have a nice LookAndFeel layer for delegating to JS paint methods and such.
On the js side, we'll have the corresponding APIs and Components for the native work just mentioned, as well as pure-js components such as ParamSlider (mentioned in #70) that compose a Slider from the blueprint core library and add some specialized hooks to those APIs registered to the AudioProcessorValueTreeState.
I believe that's a comprehensive overview, and obviously a big task which will likely have to be broken down into stages.

@nick-thompson, think this captures the scope of the issue perfectly.
Also worth noting if it's not clear from the link that we may add a couple more exotic components to the extras module like FrequencyResponsePlot or WaveformPlot etc.

@nick-thompson
I've just about got an initial set of base components together and I'm working on fleshing out the ParameterValueStore/AudioProcessorValueTreeState stuff.
It'd be cool to get this "extras" package going soon. Noticed you'd gotten a bit of interest on the forum again etc.
Just to clarify, are we thinking add the new module and packages directly to this repo ? I.e.no need to got submodule them or anything ? If so I could start getting a thing together and drop your a PR with a structure idea and some initial components. Let me know what you think. Cheers

Awesome. Yea people are asking for it :)

Just to clarify, are we thinking add the new module and packages directly to this repo ?

Yea, I think that makes sense for now. No need to complicate the workflow with more submodules or anything before it becomes necessary.

Awesome. I'll aim to get you a PR over for the weekend. Has Button, ToggleButton, Slider and possibly Picker as a start Then wrappers like ParamButton, ParamSlider etc.
Hopefully we can chat over the base component approaches. At the moment I quite like a Canvas approach with drawFunction props and default implementations of those draw functions of no override provided. Has worked really well in my case but we'll see what you think to the overall shape when I get it over.
I like it because it's easy to pull in an SVG document inside the drawFunction thanks to the drawImage API etc.
Cheers

@nick-thompson, I realise I've still not dropped this across. Mainly because I've been refining various things after more experience building out a UI with these core components.
I'm starting to look at moving the basic-components folder from my current React/Blueprint app into Blueprint.
Very quick question, organisation wise, where should Blueprint's core components live? juce-blueprint/esm/components ?
I'll start trying to get this together over the weekend. My current components are .tsx components so I'll split them back to plain JS with type definition files as per our chat on Discord the other day, I don't think enforcing Typescript too heavily is a good idea at all right now.

Great! Yea let's move to #70 but I'll answer here briefly:

Very quick question, organisation wise, where should Blueprint's core components live? juce-blueprint/esm/components ?

Yep sounds good to me.

I'll start trying to get this together over the weekend. My current components are .tsx components so I'll split them back to plain JS with type definition files as per our chat on Discord the other day, I don't think enforcing Typescript too heavily is a good idea at all right now.

Agreed, thanks! I think we'll have to strike the right balance with typescript right now. Things will still be changing fast enough that I don't want to go all in on it yet, plus I think we have some work to do on first-time-user experience still

Also, I've followed this whole approach of using Canvas draw functions for the majority of components. They have a basic draw implementation and that can be overridden by user paint functions (ala juce::LookAndFeel). I've got various little simple canvas draw helpers in a lib. i.e. drawRoundedRect etc. Is this something worth sticking in Blueprint? i.e. some DrawingHelpers.js in the lib directory or similar? There may be libraries you're aware of that we could leverage for this? Alternatively that can just be a thing we leverage internally for these components?

Yea interesting. I think it'd be helpful to see the code; I could imagine some drawing utilities being helpful, but I could also imagine integrating a third party library for drawing utilities if the CanvasContext API has parity enough.
I also had a thought the other day about this– one thing that I'm realizing I hesitate about a little bit, in terms of deriving these core UI components from Canvas, is that it means that a larger application will lean very heavily on the javascript engine within the paint loop. For example, an app with many buttons, toggle buttons, and sliders: what happens in the event of resizing the window? I'd be interested to measure the performance impact. On the flip side, a Button derived only from View using style primitives (background-color, border-radius, etc), never has to visit the JS engine during a paint loop. So a larger app during a big event like a resize will lean less heavily on the js engine. Obviously, as this is mostly an optimization question, there's not much to do here before we measure :)
Let's move this to #70 but yes, very happy to start looking at what you've got!

@nick-thompson , I think this issue can probably die for now. It existed before we decided that the likes of Slider and Button would just live in blueprint core. We can revisit at a later time if needed but makes sense to keep list of issues clean whilst we run to beta.


Implementation of buttonCode

Closes #1255

Download:
Environment: QT=5.12, ARCH=32, CONFIGURATION=release, QTIFW=C:\Qt\Tools\QtInstallerFramework\3.1


Add WritableResourceStream

The old Buffer has been renamed to WritableResourceStream to complement the ReadableResourceStream introduced via #83.
Note that the WritableResourceStream now rejects read-only streams, so this may affect BC. If you want a read-only resource, use ReadableResourceStream instead of Stream.
Refs #37 and builds on top of #83.

Updated to work around HHVM incompatibility (does not report fopen mode for pipe streams) :shipit:


Improve kitodo process ocr script to support workflow, script and lan…

…guage as parameter

Support named parameters
Remove support of workflow file in process directory
Adjust ssh command to forward parameter values to manager script

No this submodule only contains the build mechanim to build and run the Kitodo.Production image. Our ocrd-main branch in my repository should be updated to provide new functionalities but it works also without IMO.


scipy.fft: Can OpenMP be used portably

Related to #10238
Can we build and use OpenMP in a portable way?
This will require compiler dependent build arguments which I can't see explicitly mentioned in the numpy distutils guide.  It also needs to link against the OpenMP runtime which may be an issue.

Can we start without it and add it as an enhancement later?
If it's an integral / non-optional part of the software we'll have to figure this out now. But if not, I'd rather wait. As soon as you talk about multithreading the C code, it can be very useful, but you have to think about things like can you set the number of threads for each call, what's the interface for doing so, etc. Because even on a multicore machine, you might know that you are going to use joblib to do N tasks over N CPUs, each of which uses calls to scipy.fft so really you want each of these to do a single-threaded computation. So things like this can increase the complexity level.
You'll probably notice a theme in these responses: trying to start with something small that works and build up from there, rather than trying to include everything at once. It allows for easier review and also easier division of labor (e.g., someone else could do OpenMP once the basics of scipy.fft are in place if they are motivated to do so).

Okay, I'll remove the worker argument for now and build without OpenMP on all platforms.

I am interested in figuring out the status of OpenMP though. I've looked for an up-to-date description before, but didn't find one. Does anyone know of one? It would need to cover:

portability
compiler support
playing well with other libraries that may use OpenMP (same or other version), multiprocessing, or threading.

compiler support

Here is detailed OpenMP compiler support info

playing well with other libraries that may use OpenMP (same or other version), multiprocessing, or threading.

Calls to omp_set_num_threads take precedence over the OMP_NUM_THREADS environment variable. There is also a num_threads clause that can be used to override either of these. This is explained in detail in here.

For reference, here is a concrete example from the DiPy project which uses OpenMP within Cython code (probably a bit more complex that what would be needed here as we probably don't need to call omp_set_num_threads, etc, explicitly if pypocketfft does that for us):
At build time, setup.py attempts to compile a simple source importing omp.h and if it succeeds, OpenMP support is enabled:
https://github.com/nipy/dipy/blob/4b24d30ba6e4cb959d2cc788362241361c80f024/setup.py#L123-L141
where the add_flag_checking class is defined in setup_helpers.py:
https://github.com/nipy/dipy/blob/4b24d30ba6e4cb959d2cc788362241361c80f024/setup_helpers.py#L81
Calls to omp_set_num_threads, omp_get_num_threads etc can be made at the Cython level via:
https://github.com/nipy/dipy/blob/master/dipy/utils/omp.pyx
which relies on:
https://github.com/nipy/dipy/blob/master/src/safe_openmp.pxd
https://github.com/nipy/dipy/blob/master/src/conditional_omp.h
Finally, an example of dynamically setting and then restoring the number of threads based on user input from within a Cython function:
https://github.com/nipy/dipy/blob/4b24d30ba6e4cb959d2cc788362241361c80f024/dipy/denoise/denspeed.pyx#L96-L111

The openmp discussion is getting a bit fragmented now because it's spread over #10242, #10238, and here. This makes it harder for other devs to follow.
In my experience I just couldn't iron out all the issues with openmp - I would be very, very, cautious about making it an integral part of code from the outset (I was scarred by the entire experience).The following points are from that experience:

The clang default compiler on macOS doesn't support openmp
This would mean that macOS users wouldn't get the performant behaviour. I tried to get around this by installing the llvm-openmp and clang conda packages, then setting the CC and CXX environment variables to choose the new compiler. However, you then run into the issues of distributing wheels - the openmp library needs to be distributed as well.
On macOS the openmp version crashes (if mkl numpy is installed) because there are two openmp libraries that are initialised (the one that mkl uses and the llvm-openmp version from 1). This can be circumvented by setting the KMP_DUPLICATE_LIB_OK='True' environment variable. I'm not sure how to ensure that this wouldn't occur, and it's a generalised problem. There is the potential for several different openmp runtimes to exist, e.g. libiomp, libomp, libgomp. I'm not sure if this issue also applies to other OS's, I develop on macOS.
openmp doesn't play nicely with multiprocessing.Pool
See scikit-learn/scikit-learn#7650 and also https://joblib.readthedocs.io/en/latest/parallel.html#bad-interaction-of-multiprocessing-and-third-party-libraries

At the moment it is not safe to use OpenMP for low overhead thread based parallelism in our Cython code base because of a bad interaction between multiprocessing.Pool (worker processes are necessarily created by fork without exec under Python 2) and the openmp runtime library libgomp used in GCC. This can cause the program to silently freeze.

I also experienced this when running some Linux tests on through a Docker image. To get around this one can use joblib with the Loky backend. joblib is a nice project, but I found (for my particular code) that joblib wasn't as performant as multiprocessing.
One also has to consider the overall picture of how the parallelisation is carried out, it's going to be in such a heterogeneous and nested environment. Here are some cases:

user does computation (FFT?) on their own machine --> wants to use as many processors as possible to parallelise the computation.
user is doing a parallelised task [e.g. minimisation (differential_evolution) using a Pool of workers] --> want to use as many workers as there are cores. However, each distributed computation (using FFT) should only be single threaded.
user is doing a distributed task on a cluster, they want to parallelise over nodes, each node having several cores. Perhaps they want to parallelise over the nodes and cores on each node using MPI, with each discrete (FFT) computation being single threaded.
alternatively, the cluster computation could be MPI parallelised over the nodes, but on each node the (FFT) computation is parallelised over the cores using openmp.

The bottom line is that precise control is needed over how parallelisation is achieved, with no recourse to environment variables (see point 2), global state, etc.
I went down this path because I was using pthreads for macOS/posix, and Windows parallelisation calls (_beginthreadex, _endthreadex, WaitForMultipleObjects, etc). Using openmp would've done a slight amount of cleanup in the code. However, in the end it just wasn't worth it, there were too many difficulties.
Would it be possible to continue discussions on this kind of thing on scipy-dev?

Would it be possible to continue discussions on this kind of thing on scipy-dev?

Yep, sounds good. Perhaps copy-paste what you wrote above to move the discussion there?
For this specific issue, I think this implies we should not include it right now and add it later (if ever).

Proposed parallelization for scipy.fft is now standard multithreading instead of OpenMP (#10614), so this can perhaps be closed.

Agreed, thanks @mreineck

Linking the related mailing list thread which has quite a bit of relevant content, like how scikit-learn does manage to ship wheels with OpenMP: https://mail.python.org/pipermail/scipy-dev/2019-August/023635.html

Linking the related mailing list thread which has quite a bit of relevant content, like how scikit-learn does manage to ship wheels with OpenMP: https://mail.python.org/pipermail/scipy-dev/2019-August/023635.html

Also adding the following 2019 discussion from the ML for reference for anyone interested.
(Not my sleuthing, mentioned by @jb-leger in #13576)

Most important reason: because it plays badly with multiprocessing.

Only libgomp (the default OpenMP runtime implementation that comes with GCC) is not fork-safe. The Microsoft OpenMP runtime (used by default when building with MSVC) and the LLVM OpenMP runtime (used by default when building with clang) are safe.
On Linux, it's possible to build with GCC and then replace libgomp by llvm-openmp. It should also be possible to build with clang directly. More details in the conda-forge documentation: https://conda-forge.org/docs/maintainer/knowledge_base.html#openmp

If the OpenMP standard itself does not mandate this form of fork safety, I'd personally not rely on added guarantees that are are made by specific implementations.
At least for C++ the current approach with a thread pool implemented with standard language features is very convenient to use, and (although I was reluctant to switch away from OpenMP myself at first) I'm now using it in my other C++ projects as well and am really happy with reliability and portability.
However I admit that this is probably not a great help when multithreading is needed in extensions written in C or Fortran...

However I admit that this is probably not a great help when multithreading is needed in extensions written in C or Fortran...

or Cython, or pythran or numba which all have OpenMP integration.

On Linux, it's possible to build with GCC and then replace libgomp by llvm-openmp. It should also be possible to build with clang directly. More details in the conda-forge documentation: https://conda-forge.org/docs/maintainer/knowledge_base.html#openmp

The problem is not that you can't use llvm-openmp; it's that you need to be able to guarantee no user at runtime will end up running libgomp. On PyTorch for example, we've had some bug reports that depend on whether import numpy or import torch happens first because on some environments you end up using a different version of OpenMP.


Implement String.is_whitespace

Allows developers to quickly check if a string is formed of only whitespace.
Whitespace characters included are only the ones marked as "Is_Whitespace" over here: https://en.wikipedia.org/wiki/Whitespace_character

Note that we have an implementation of is_whitespace() for characters in the codebase:
https://github.com/godotengine/godot/blob/61598c5c88d95b96811d386cb20d714c35f4c6d7/core/string/char_utils.h#L119-L121
I wonder what would be the benefit of exposing it to developers. As you can see, the definition of “whitespace” is different for different scenarios, especially when Unicode is involved.

Am I missing it or we don't have a simple String.trim() function that by default uses all the known whitespace chars? I'm asking because, to me, that'd be more natural than adding this. My point is that there's a widespread idiom to check for empty strings, which is if trim(some_string) == "". That's good because you can use the same trim() for cleaning user input of surrounding whitespaces as well as checking for empty mandatory fields.

Am I missing it or we don't have a simple String.trim() function that by default uses all the known whitespace chars?

strip_edges

Why is the one in the codebase not exposed?

What ones are exposed? This is not a method on String, there aren't any in @GlobalScope, and that method mentioned is a code point method, not a string one, it operates on individual characters

Modified to use the internal is_whitespace function.


Create Shadow Clones (new extension)

Describe the extension
Create shadow clone objects that follow the same path as a primary object.  Select the primary object, the shadow clone object, the number of shadow clones, the number of frames between shadow clones, the rate that shadow clones will fade away (if desired), the Z-value of the shadow clones, and the layer the shadow clones will be created on.
This extension can be used to:

Make an object look faster, such as during a speed powerup.
Give a 3D-like feel to a character
Implement unique time-based elements, like teleporting a character back to a previous location
Simulate the movement of a caterpillar or slinky
Recreate games like snake or tron

These object variables can be use to manage the shadow clones:

ShadowCloneOrder = Shadow clone identifier, where 1 is the shadow clone closest to the primary object
FramesBehindPrimary = The number of frames that the shadow clone is behind the primary object
ShadowCloneGroupID = Shared identifier for the shadow clones that were created (Optional)

Checklist

[x] Extension has a proper name and description.
[x] Extension has tags (for example: "platform, brick, breakable").
[x] All behaviors have a description.
[x] All functions (actions, conditions, expressions) have descriptions.
[x] I confirm that this extension can be intergrated to this GitHub repository, distributed and MIT licensed.

Extension file
CreateShadowClonesExtension-0.0.1.json.zip

Looks nice! Easy to use :)
Do you think there would be a way to make it work for multiple objects? I've seen some Trigger Once so I think it would only work for a single object at a time?

Great question.  You are right, this extension currently works only with one primary object.  I think it might be possible to use it on multiple primary objects, but I'll have to do a lot of thinking.  I'll write back with my results.

I also want to add the ability to increase/decrease the shadows.  I am making a game similar to the hungry caterpillar book; each time he eats, he grows one more shadow clone.

Both would be interesting! Flexibility of using it on multiple objects is I think important to avoid confusing/frustrating people that would want more than one object casting these shadow clones :)
Let me know if you can get something working. Instead of Trigger Once, you might have to work with variables set on the object(s), and possibly add some "For Each Object" events so that you're sure you're handling each object separately :)

Another idea to consider:

Give users the option to make ShadowClones use the same animation ID and frame ID that the primary object was using
Pause animation on ShadowClones (I think they should act frozen in time, and stay in the state they were created at)

That's possible indeed! That's assuming you use a sprite as the object to follow. Could be a variant (as another action) maybe, so you could use both?

Thanks to much-appreciated help from @entropy, we have made some updates to this extension:

Moved position history under the primary object
You can now use this extension on multiple primary objects (YES!)
-- If you want to use the same shadow clone object on both primary objects, then you must specify a unique "ShadowCloneGroupID"
Increasing and decreasing shadow clones works... sort of.  If you try to add and remove multiple times, gaps in the shadow clone chain begin to appear.  (This bug needs resolved)

CreateShadowClonesExtension-0.0.1_3.json.zip

Thanks! I've been very busy these days but I'll take a look and add it 👍

You can now use this extension on multiple primary objects (YES!)

Nice :)
It seems the "empty frames" between shadows might be buggy:
I've added it to the platformer example:

and the result seems to be a single shadow clone (the others have been skipped?):

On the description side of the action, this part is useful in the extension description but should not be in the action description:

as it's taking place and the creator already made the choice of using the extension - so they know the utility.
Finally, I would also rename the action slightly to make it clear that this is an action that must be called continuously to work properly. Something like "Animate" might be better suited (while "create" looks like you just need to call this action once, and then you can forget about it).

Remember that you also have a Trigger Once that will probably give very weird result/bugs because you can use this action on more than one object:

I recommend using a variable to simulate a Trigger Once. You could actually maybe store a "CreatedShadowNumber" - which is 0 by default, and then that you increment/decrement (instead of a c variable) :)

If possible, I'd like to work on it more before publishing.  I am using this issue as a way to share my code and get feedback (and code improvements) from others.   I don't see a way for me to tag this with something like "in progress" and eventually "submitted for approval".

I've made a Work In Progress label ;) Tag me when you have a new version :)

FYI - The problem with your test is that you are fading opacity by 20 every frame, and you have 10 frames between coins, so the next shadow will be faded by 200.  :)

Speaking of that, I should change the logic so that it fades opacity "per shadow" and not "per frame"....

Ah I see! Works well when I change that then. But yeah I think per shadow would be awesome then, especially when using a large number of frames between shadows :)

I have changed the opacity fade to per clone instead of per frame.
I’m also going to try turning this into a behavior and see if it works better.

Nice! Let me know when you have a new version.

Version 0.3.3
Changes include:

Fixed bug when adding and removing clones
Cleans up unused history (when the number of clones goes down)
Now mimics the angle, scale, animation, and frame of the primary object
Works with multiple instances of a primary object
Opacity fade is per clone (instead of per frame)
Removed an extra ForEach() loop
Tested with an example game

@4ian I am ready for you to review this for inclusion into GDevelop.  Feel free to send more of those delicious nit-picking recommendations you often provide!  :)
Live Demo
https://games.gdevelop-app.com/game-9281a1a6-15f3-4c7c-8267-07642cce765a/index.html
Example Game
ShadowClonesExample.zip
Video
https://user-images.githubusercontent.com/8879811/108014809-f2f32f80-6fcb-11eb-872d-231334eb015c.mp4
Extension file
ShadowClonesExtension_0.3.3.json.zip

I woke up this morning and realized that I didn't test an animated sprite.  I think I forgot to Pause the animation of the shadow clones.
Don't import this until I review it later tonight.

Sure let me know when it's ready. Looks really good! 👍

Version 0.3.4
Changes include:

Paused the animation of shadow clones
Tested with an example game (now with sprites)

Live Demo
https://games.gdevelop-app.com/game-9281a1a6-15f3-4c7c-8267-07642cce765a/index.html
Extension file
ShadowClonesExtension_0.3.4.json.zip
Video
https://user-images.githubusercontent.com/8879811/108159537-75e7b900-70a4-11eb-9648-8370549aab5b.mp4

Looks very good! 👍👍
Is there a need to store both width/height and scale x/y? Width/height should be linked to the scale anyway?
Nitpicking: instead of inverting these conditions:

You can use the "not equal" operator?
Finally maybe mention in the description that the shadow will be virtually linked to the primary object (so one should not try to use the "Linked objects" feature between the shadows and primary object, otherwise they risk breaking the shadows).

Apart from that we should be good to go :) Because this is mostly nitpickings/not that important, I'll go ahead and add the extension now :)
I would also recommend changing "Create PARAM3 copies of PARAM2 that follow the position..." to "Create and animate PARAM3 copies of PARAM2 that follow the position" to make it a bit clearer that this is not a one off action, it must be called at every frame.

Is there a need to store both width/height and scale x/y? Width/height should be linked to the scale anyway?

I wasn't sure the best thing to do.  If I am setting both scale AND width/height, then the actual size will only be affected by the last action performed, right?  I think I will probably remove width/height and just use the scale.

Nitpicking: instead of inverting these conditions:

You can use the "not equal" operator?

Since these have the same logic, I like to think that the big red invert on the left is easier to see than the difference between "=" and "!=".  I'm certainly willing to change, if you recommend using "!=".

Finally maybe mention in the description that the shadow will be virtually linked to the primary object (so one should not try to use the "Linked objects" feature between the shadows and primary object, otherwise they risk breaking the shadows).

This extension DOES link the shadow objects to the primary object.  I actually think users will need to use the linked conditions/actions if they want to delete shadow clones of a single primary object.   This extension does provide a "DeleteShadowClones" action that will delete all shadow clones with the same ShadowCloneGroupID, but I don't think users will have unique ShadowCloneGroupID for each instance.
Lastly, I think my next version will include boolean variables that let the user decide which properties of the primary object should be used on the shadow clones.  For instance, if you want small objects (dust-trail/foot-prints/pets/minions) to follow your player, this extension will currently force the width/height of the shadow clones to match the player.

Apart from that we should be good to go :) Because this is mostly nitpickings/not that important, I'll go ahead and add the extension now :)
I would also recommend changing "Create PARAM3 copies of PARAM2 that follow the position..." to "Create and animate PARAM3 copies of PARAM2 that follow the position" to make it a bit clearer that this is not a one off action, it must be called at every frame.

I will add this to the Trello board to change on the next version.

Lastly, I think my next version will include boolean variables that let the user decide which properties of the primary object should be used on the shadow clones. For instance, if you want small objects (dust-trail/foot-prints/pets/minions) to follow your player, this extension will currently force the width/height of the shadow clones to match the player.

Yes great idea, not everyone may want to have the shadow clones to use the same width/height :) Giving the choice here is surely a good idea

Version 0.3.5
Changes include:

Added boolean variables to let users choose which primary object properties will be matched on the shadow clones.
Changed DeleteShadowClones function.  It now deletes shadow clone instances that are linked to the primary object instance.
Changed all single-character variable names to descriptive names
Changed wording based on recommendations

Live Demo
https://games.gdevelop-app.com/game-82269a54-55e7-4f19-87c2-26e3e30dd8aa/index.html
Extension file
ShadowClonesExtension_0.3.5.json.zip

Updated! Thanks :)

Version 0.3.6
Changes include:

Reset PrimaryObject variables when DeleteShadowClones function is executed (needed for dash to work)
Added link to Youtube video tutorial on how to use the extension (https://youtu.be/2t4ANYgrrak)
Added link to Entropy's Youtube channel in the credit field

Unrelated changes to platformer example:  (FYI - I'll submit this separately)

Added horizontal dash (press "x") with shadow clones
Added instructions on controls (I'm not sure how translations are done)
Added animation to checkpoint cactus (y-scale tween) and added sound
Added victory trophy

Live Demo
Platformer example with Dash added (press "x" to dash)
https://games.gdevelop-app.com/game-0a3741e9-22dc-44d6-bdef-c0647e85fbd6/index.html
File
ShadowClonesExtension_0.3.6.json.zip

Updated, thanks! 👍

Shadow clone.zip
Added "scale down per clone" action to the fanction.

Zim Quadery thanks for sharing this!  I looked at it briefly, and it looks good.  I think I even learned that I can remove the opacity setting on every frame and just do it once as you did for scale.
I'll test that change and combine it with yours, and submit it as a minor update to this issue.

I have almost completed a major overhaul of ShadowClones that is much simpler and more resilient.  (I'll provide more details in a later post).
I have one remaining problem that I am hoping someone could look at.  (If you were confused how ShadowClones worked in the past, it should now be much easier to understand)
Problem:

ShadowClones are being created even when there is no position data.

I have a condition that is supposed to only create them only if the X OR Y position are not 0.  However, these objects are being created with x=0 AND y=0.   (Note: You can't see them because scale values are also 0, but you can see in the debugger).

Extension file
ShadowClonesExtension_0.5.0.json.zip
Source Files
ShadowClonesExample_SourceFiles_0.5.0.zip
Game Example
https://games.gdevelop-app.com/game-dd9b3439-cf8d-46c3-abdf-211425e808e7/index.html

Version 0.5.1
Updates:

Revamped logic to increase simplicity, resiliency, and efficiency (while functionality for the user remains the same)
Added the ability to shrink the size of clones (this acts similar to opacity fade)
Fixed bug where hundreds of clones could be created on top of each other when changing the number of clones
Changing the distance between clones now moves them instead of deleting and recreating

Future optimization:

Only create shadow clones when there is position history for them.
(I have a condition that is supposed to enforce this, but it is not working.  Shadow clones are created even if there is no position history and moved to x=0,y=0 with scale=0.  If anyone has a solution to this, please let me know! In the meantime, this update is a major improvement to the existing version of ShadowClones).

Example game
https://victrisgames.itch.io/shadowclones-extension-demo
Extension file
ShadowClonesExtension_0.5.1.json.zip

Nice! This seems good to go even without the further optimization?

Shadow clones are created even if there is no position history

Could you explain exactly what this means?
Do you use a structure?

https://victrisgames.itch.io/shadowclones-extension-demo

Very nice! I think these demos are very good candidates for the new repository of examples https://github.com/GDevelopApp/GDevelop-examples :)
So that they will be surface directly in (the next version of) GDevelop. And they will also list the extensions used in them.

Yes, I use structure variables.  On every frame, I create a new child variable under "PrimaryObject.ObjectHistory".  So the 3 most recent frames would be:
PrimaryObject.ObjectHistory.1
PrimaryObject.ObjectHistory.2
PrimaryObject.ObjectHistory.3
I store all the characteristics of the PrimaryObject as child variables under each frame.  For instance, the most recent frame has:
PrimaryObject.ObjectHistory.1.xpos
PrimaryObject.ObjectHistory.1.ypos
PrimaryObject.ObjectHistory.1.angle
PrimaryObject.ObjectHistory.1.animation
PrimaryObject.ObjectHistory.1.frame
PrimaryObject.ObjectHistory.1.xscale
PrimaryObject.ObjectHistory.1.yscale
PrimaryObject.ObjectHistory.1.width
PrimaryObject.ObjectHistory.1.height
Lastly, on every frame I move the data one frame down so that the most recent data always lives at "PrimaryObject.ObjectHistory.1".  (BTW, I also "clean-up" extra frame data so I only keep the exact number I need.)
The missing optimization is that this extension currently creates all requested ShadowClones in the first frame.  Clones are created at the current position of the PrimaryObject, but I immediately move them to the values stored in the ObjectHistory structure.  Since this structure has not been populated with data yet, the clones are moved to x=0,y=0.  If you have enabled matching scale, you will not see them because their scale is also 0.  These objects do exist, and you can see them in the debugger.
I have conditions that should only create the objects when there is position data in ObjectHistory for their frame, but for some reason, they are not working...
UPDATE:  Thanks to the benefit of explaining a problem to someone, I found the error in my code.  My conditions were supposed to check for the frame number, but I was only checking the clone number.  Thanks for pushing me on this, @4ian.  :)
Here are the fixed conditions:

Version 0.5.2

Add optimization so that shadow clones are now only created when there is object history for their frame.

Extension file
ShadowClonesExtension_0.5.2.json.zip

Amazing! Good catch :)
I've updated the extension 👍
Also note that this kind of manipulation can be easier to do in the future thanks to arrays (just for the fact of being able to use numbers in the brackets: ObjectHistory[...]). We may add some array manipulation actions to "pop"/shift an element from the beginning of the array :)


Create JS/Kotlin/etc. bindings for bitcoin_client_rs

It would be very useful to create bindings from the rust library to various targets that developers need - especially JS and JVM-based.

I did some experiments in trying to create JS bindings with wasm-bindgen. Unsuccessful so far, leaving some notes for future reference.
===
I did manage to use the transport object from JS code(from @ledgerhq/hw-transport-node-hid in a Rust class, in turn exported to JS run in node.
===
A limitation of wasm-bindgen is that it cannot export objects with type parameters; therefore, a wrapper of BitcoinClient<Transport> seems necessary, e.g. a struct like:
#[wasm_bindgen]
pub struct BitcoinClientJS {
    client: BitcoinClient<Transport>,
}

I tried to import a transport object from JS and implement the Transport trait
#[wasm_bindgen]
extern "C" {
    pub type TransportJS;

    #[wasm_bindgen(method)]
    pub async fn send(this: &TransportJS, cla: u8, ins: u8, p1: u8, p2: u8, data: &[u8])
        -> JsValue;
}

#[async_trait]
impl Transport for TransportJS {
    type Error = Box<dyn Error>;

    async fn exchange(&self, command: &APDUCommand) -> Result<(StatusWord, Vec<u8>), Self::Error> {
        todo!()
    }
}

That should be possible as per the initial experiment above, but I couldn't make it work; apart from some painful limitations of wasm-bindgen on the allowed returned types for the public members, I hit a roadblock when I started getting errors when trying to implement exchange for  TransportJS, like:
55 |       async fn exchange(&self, command: &APDUCommand) -> Result<(StatusWord, Vec<u8>), Self::Error> {
   |  ___________________________________________________________________________________________________^
56 | |         let result = self
57 | |             .send(command.cla, command.ins, command.p1, command.p2, &vec![])
58 | |             .await;
...  |
63 | |         }
64 | |     }
   | |_____^ future created by async block is not `Send`

I don't know how to fix this; attempts to wrap things in Arc or Mutex failed, I couldn't get it to compile.
===
A second attempt to avoid having to call JS code from Rust world initially seemed promising, but the existing implementation of the Transport class depend on the ledger-transport-hid crate, which in turn depends on hidapi that does not compile to the wasm32-unknown-unknown; not sure if this is solvable at all, so this approach is probably not worth pursuing.
error: failed to run custom build command for `hidapi v1.5.0`

...

Caused by: failed to execute `cargo build`: exited with exit status: 101
  full command: "cargo" "build" "--lib" "--release" "--target" "wasm32-unknown-unknown"

I found this:
https://stackoverflow.com/questions/71217860/how-to-call-an-async-javascript-import-function-from-webassembly-rust-in-a-nod
Maybe it can help you solve your problem. (Sharing here because I cannot post links on the Ledger discord)

Thanks @edouardparis, I didn't manage even in that way, either − but it's a useful reference for this issue.


Fix build issues with the newer v6 aot compiler

Currently, the older v1 alpha compiler is used since building with v6 leads to the linker complaining about the wmainCRTStartup function being missing. As far as I know, this is a windows specific function and so cannot be added. This was with an older version of the compiler however and this might be fixed by now.
Check if this is because of the compiler not being designed for this use or if it is because dotnet.exe is being told to build for win-x64. Both are possible since the other .net efi projects using a stock compiler either use csc directly or the same compiler as this project where this issue does not exist.

I have just figured out how to build with the v6 ilc but only using dotnet publish for its access to ilc and then manually calling link.exe with "link "obj\x64\Release\net5.0\win-x64\native\EfiSharp.obj" /subsystem:EFI_APPLICATION /entry:EfiMain ..\EfiSharp.Native\x64\release\EFiSharp.Native.lib".
This is to get around ilc v6 introducing its own /subsystem and /entry arguments and also adding in runtime.lib and bootstrapper.lib. It appears I was not the only one to discover this change as at roughly the same time I was trying figuring this out, https://github.com/dotnet/runtimelab/pull/633 was posted.
Ideally, I would be able to use the stock runtime.lib or at least the portable version but current attempts result in quite a few unresolved externals.

I have tried to work around this on the NativeAOT-Test.Corelib-RuntimeFix branch but even fixing all errors just allows the wrong entry point to be used.

Attempting to join both the v6 and runtime changes does resolve the errors in the previous image but lead instead of over a hundred missing external symbols in low level functions.

At least some of the ones in MathHelpers.obj appear due to no c runtime which could be solved with a freestanding one like mlibc but most appear specific to the dotnet.

At least some of the ones in MathHelpers.obj appear due to no c runtime which could be solved with a freestanding one like mlibc but most appear specific to the dotnet.

Yep, this is missing C runtime (GSHandlerCheck, fltused, round, etc.), plus missing Win32 APIs (DuplicateHandle, GetCurrentThread, etc.)
Runtime.lib needs to be ported from Windows to UEFI to be usable.
(Cool project, btw! )

Yep, this is missing C runtime (GSHandlerCheck, fltused, round, etc.), plus missing Win32 APIs (DuplicateHandle, GetCurrentThread, etc.)
Runtime.lib needs to be ported from Windows to UEFI to be usable.
(Cool project, btw! )

I did know about the Runtime.lib issues, I already added part of MathHelpers.cpp so I could cast float to ulong but going much further and adding functions like RhpNewArray proved a bit hard.
Weirdly, at one point I did have libcmt.lib errors so it was being used. I did check and I do not have /NODEFAULTLIB anymore so not sure why it disappeared.

The updated compiler almost deals with all the errors in the first red image, all that is left is the unresolved floating point operations in MathHelpers.obj. The linker says it is the Runtime.lib version however so I worry that once I fix these errors I will get the grey error list again.

It turns out I was mistaken and those errors were only shown because I forgot to include my version of MathHelpers.cpp. It would probably a good idea to deal with those functions at some point however as floating point support is still quite limited and even modulus is currently broken.

I guess the v6 compiler uses exe now, even for efi binaries.


fix bug

Fixes #1355 https://github.com/olivere/elastic/issues/1355

fix

That's probably too simple, as I think older versions of ES 5.x use score, while newer versions use _score. We had the same with ES 6.x.

I have also encountered this problem recently, could we merge the PR, thanks. @olivere

Fixed by #1364


bash apollo.sh build failed

[INFO] Building on x86_64...
INFO: Reading 'startup' options from /apollo/tools/bazel.rc: --batch_cpu_scheduling
INFO: Analysed 1470 targets (12 packages loaded).
INFO: Found 1470 targets...
ERROR: /home/autolab/.cache/bazel/_bazel_autolab/540135163923dd7d5820f3ee4b306b32/external/com_google_protobuf/BUILD:113:1: C++ compilation of rule '@com_google_protobuf//:protobuf' failed (Exit 1)
In file included from external/com_google_protobuf/src/google/protobuf/generated_message_table_driven.cc:1:0:
/usr/include/x86_64-linux-gnu/asm/param.h:1: confused by earlier errors, bailing out
INFO: Elapsed time: 514.355s, Critical Path: 510.16s
FAILED: Build did NOT complete successfully
[ERROR] Build failed!
[INFO] Took 808 seconds

We have experienced the same problem, it seems the latest docker image does not come pre-loaded with the bazel/protobuf dependencies under the '/home/tmp/' directory. This leads to bazel runtime not being able to find the packages and therefore failing.

Hi, fenglupeter. protobuf must be built with a particular bazel version, because some features in protobuf are not compatible with some bazel version.
So, please  tell me your docker_dev version, use instruction 'docker images' to show all images; your  bazel version, in docker_dev, use instruction 'bazel --version' to show bazel info; your protobuf version, in docker_dev, protobuf file is in directory /home/tmp.

Closing this issue as it appears to be resolved. Feel free to reopen if the issue persists. Thanks!

Please re-open the issue. I suspect issue #10159 is actually another version of this one.
Bazel version: 0.5.3


Kerberos auth

Hi,
Is kerberos auth supported?
Since we switched to Kerberos i am receiving these errors:
Exception in thread "main" org.apache.spark.SparkException: Job aborted due to stage failure: Task 2 in stage 77.0 failed 4 times, most recent failure: Lost task 2.3 in stage 77.0 (TID 5711, CLUSTER_NAME, executor 40): com.exasol.jdbc.ConnectFailed: Connection refused (Connection refused)
Thanks!

Sorry, I could not reply earlier. I was on a vacation past two weeks.
Unfortunately, the spark exasol connector does not support kerberos
at the moment.
But since your spark cluster is kerberos enabled (and not exasol cluster)
the connection still should work?
Do you have more logs, for example the Ipv4 addresses the Spark tasks
connecting?

Sorry for the late response.
After some further debugging it looks like the problem is not created by Kerberization of the server. The error message (Connection refused) lead me to think that. Let me explain a bit further.
First of all, I updated the lib version to 0.3.0 - we were using 0.2.1 previously.
During the debugging process, I ran the same job on the same data and produced deterministic failure in the code. My code was pushing 3 tables to Exasol using the connector -  and the problem always occurred when writing second of the 3 tables.
This proved that Kerberization had nothing to do with the problem, since first and third table were working fine.
On the other hand, error message was confusing. For the same job, same data and same pipeline i received these 2 messages interchangeably without any observable pattern:

Exception in thread "main" org.apache.spark.SparkException: Job aborted due to stage failure: Task 2 in stage 77.0 failed 4 times, most recent failure: Lost task 2.3 in stage 77.0 (TID 5711, CLUSTER_NAME, executor 40): com.exasol.jdbc.ConnectFailed: Connection refused (Connection refused)

Exasol failed: Job aborted due to stage failure: Task 2 in stage 78.0 failed 4 times, most recent failure: Lost task 2.3 in stage 78.0 (TID 5577, CLUSTER_NAME, executor 20): org.apache.spark.memory.SparkOutOfMemoryError: Unable to acquire 65536 bytes of memory, got 0

It turned out that due to the bug in our scripts the data volume that was being pushed to Exasol was several times larger than usual.
Once we fixed the bug everything started working fine.
So, you can close this issue, but the thing that is interesting is that second message helped debug the problem - it suggests that the data is too big (for the memory), but the first message did not indicate that, although the root cause is the same.
Thanks, and sorry for your trouble!

Hi,
I'm experiencing similar issue and I don't think there is issue with data volume.
Dataframe that I'm trying to insert into Exasol is 9row x 35col size with fields that are mostly null or strings that do not exceed 50 characters. What is pretty odd is that somehow table is actually created along with appropriate columns, but there is no data inserted.
Here is stacktrace:
Job aborted due to stage failure: Task 3 in stage 118.0 failed 4 times, most recent failure: Lost task 3.3 in stage 118.0 (TID 7369, CLUSTER_NAME, executor 3): org.apache.spark.memory.SparkOutOfMemoryError: Unable to acquire 572 bytes of memory, got 0
	at org.apache.spark.memory.MemoryConsumer.throwOom(MemoryConsumer.java:157)
	at org.apache.spark.memory.MemoryConsumer.allocatePage(MemoryConsumer.java:119)
	at org.apache.spark.util.collection.unsafe.sort.UnsafeExternalSorter.acquireNewPageIfNecessary(UnsafeExternalSorter.java:383)
	at org.apache.spark.util.collection.unsafe.sort.UnsafeExternalSorter.insertRecord(UnsafeExternalSorter.java:407)
	at org.apache.spark.sql.execution.UnsafeExternalRowSorter.insertRow(UnsafeExternalRowSorter.java:135)
	at org.apache.spark.sql.catalyst.expressions.GeneratedClass$GeneratedIteratorForCodegenStage3.sort_addToSorter_0$(Unknown Source)
	at org.apache.spark.sql.catalyst.expressions.GeneratedClass$GeneratedIteratorForCodegenStage3.processNext(Unknown Source)
	at org.apache.spark.sql.execution.BufferedRowIterator.hasNext(BufferedRowIterator.java:43)
	at org.apache.spark.sql.execution.WholeStageCodegenExec$$anonfun$13$$anon$1.hasNext(WholeStageCodegenExec.scala:636)
	at org.apache.spark.sql.execution.RowIteratorFromScala.advanceNext(RowIterator.scala:83)
	at org.apache.spark.sql.execution.joins.SortMergeJoinScanner.advancedBufferedToRowWithNullFreeJoinKey(SortMergeJoinExec.scala:811)
	at org.apache.spark.sql.execution.joins.SortMergeJoinScanner.<init>(SortMergeJoinExec.scala:686)
	at org.apache.spark.sql.execution.joins.SortMergeJoinExec$$anonfun$doExecute$1.apply(SortMergeJoinExec.scala:213)
	at org.apache.spark.sql.execution.joins.SortMergeJoinExec$$anonfun$doExecute$1.apply(SortMergeJoinExec.scala:150)
	at org.apache.spark.rdd.ZippedPartitionsRDD2.compute(ZippedPartitionsRDD.scala:89)
	at org.apache.spark.rdd.RDD.computeOrReadCheckpoint(RDD.scala:324)
	at org.apache.spark.rdd.RDD.iterator(RDD.scala:288)
	at org.apache.spark.rdd.MapPartitionsRDD.compute(MapPartitionsRDD.scala:52)
	at org.apache.spark.rdd.RDD.computeOrReadCheckpoint(RDD.scala:324)
	at org.apache.spark.rdd.RDD.iterator(RDD.scala:288)
	at org.apache.spark.rdd.CoalescedRDD$$anonfun$compute$1.apply(CoalescedRDD.scala:100)
	at org.apache.spark.rdd.CoalescedRDD$$anonfun$compute$1.apply(CoalescedRDD.scala:99)
	at scala.collection.Iterator$$anon$12.nextCur(Iterator.scala:435)
	at scala.collection.Iterator$$anon$12.hasNext(Iterator.scala:441)
	at scala.collection.Iterator$$anon$11.hasNext(Iterator.scala:409)
	at scala.collection.Iterator$$anon$11.hasNext(Iterator.scala:409)
	at com.exasol.spark.writer.ExasolWriter.insertPartition(ExasolWriter.scala:82)
	at com.exasol.spark.DefaultSource$$anonfun$saveDFTable$1.apply(DefaultSource.scala:140)
	at com.exasol.spark.DefaultSource$$anonfun$saveDFTable$1.apply(DefaultSource.scala:140)
	at org.apache.spark.rdd.RDD$$anonfun$foreachPartition$1$$anonfun$apply$28.apply(RDD.scala:935)
	at org.apache.spark.rdd.RDD$$anonfun$foreachPartition$1$$anonfun$apply$28.apply(RDD.scala:935)
	at org.apache.spark.SparkContext$$anonfun$runJob$5.apply(SparkContext.scala:2101)
	at org.apache.spark.SparkContext$$anonfun$runJob$5.apply(SparkContext.scala:2101)
	at org.apache.spark.scheduler.ResultTask.runTask(ResultTask.scala:90)
	at org.apache.spark.scheduler.Task.run(Task.scala:121)
	at org.apache.spark.executor.Executor$TaskRunner$$anonfun$10.apply(Executor.scala:408)
	at org.apache.spark.util.Utils$.tryWithSafeFinally(Utils.scala:1405)
	at org.apache.spark.executor.Executor$TaskRunner.run(Executor.scala:414)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
	at java.lang.Thread.run(Thread.java:748)

Hello @nikoki, @kundacina-m,
Thanks for your feedback! We highly appreciate it!
@nikoki,
It is great that you were able to solve the issue! I agree, the error message does not help very much here. From my understanding, one of the Spark tasks fails due to memory issues.
Meanwhile, on the Exasol side the waiting JDBC subconnection timeout reaches and it closes the connection. Please keep in mind this is problem for all parallel connections, not to single one. In this case, you should see the "Connection was lost" exceptions for the first attempt. You could check that this exception is thrown early on the first attempt of tasks.
The above connection refused exception is for the following attempts when task tries to connect to the closed Exasol JDBC subconnection.
@kundacina-m
I guess the error is not related to Exasol, but to Spark task memory. From the exception message I see that it does not reach to save action yet. I also see that you are doing join, please check that the join key is not skewed. Since a join for a key is performed in a one Spark task, check that a single key does not contain majority of the values.
Additionally, you can increase memory of executor and decrease the executor cores per node.
For example, start spark-submit or spark-shell with similar parameters:
 --executor-cores 5 \
 --executor-memory 34G \
 --conf spark.yarn.executor.memoryOverhead=3891M

This will start 5 tasks per executor, each with ~6.8G memory. I have also added memory overhead for executor. You can also set the --num-executors parameter to control how many executors are started. This will allow to balance memory of a cluster node.
I hope this is helpful, please let us know if there are issues or questions.
Best

Hey all,
I am going to close this issue. Please open a new issue if there are still questions.


⚠ LPDM Handbook (hosted on Divio) has degraded performance

In 6f96973, LPDM Handbook (hosted on Divio) (https://repohubdev.tk) experienced degraded performance:

HTTP code: 500
Response time: 6162 ms

Resolved: LPDM Handbook (hosted on Divio) performance has improved in bb58a0c.


Various filters are overloaded by duplicate findings listings

Bug description
Some of the advanced filters for findings will not exclude the duplicate_list and duplicate_finding fields which leads to long page load times and slow UIs with large amounts of data.
Steps to reproduce
Steps to reproduce the behavior:

Go to 'Closed Findings'
Click on the filter button on the top right.
See "Duplicate finding" and "Duplicate list" filters.

Expected behavior
Don't have those filters.
Deployment method (select with an X)

[ ] Kubernetes
[ ] Docker
[ ] setup.bash / legacy-setup.bash

Environment information

Operating System: [e.g. Ubuntu 18.04]
DefectDojo Commit Message: [use git show -s --format="%h: %s [%ci]"]

Sample scan files (optional)
If applicable, add sample scan files to help reproduce your problem.
Screenshots (optional)
If applicable, add screenshots to help explain your problem.
Console logs (optional)
If applicable, add console logs to help explain your problem.
Additional context (optional)
Add any other context about the problem here.

Some sort of common set of filtered fields for Finding could be maintained which avoids the duplication of effort whenever new fields are added that may or may not be useful for searching/filtering.

To add to this: the filters are slow in general because every query is executed twice by django-filter.

Would be interesting to see of this is still an issue after the recent changes regarding the duplicate_list vs duplicate_finding field.


If vites config contains defineConfig with callback, then SSR is broken

Prerequisites

[X] I have written a descriptive issue title
[X] I have searched existing issues to ensure the bug has not already been reported

Fastify version
4.17.0
Plugin version
4.0.0
Node.js version
16.18.1
Operating system
Windows
Operating system version (i.e. 20.04, 11.3, 10)
10 Pro (21H2)
Description
In vite.config.js I need to generate config for different goals. vite can help with this case and front build is Ok, but when I start http-server with the plugin - it fails, cause in next code
https://github.com/fastify/fastify-vite/blob/568e178a10768211944bfc1aaf6e57a6a091693d/packages/fastify-vite/config.js#L173
we try to make Object.assign(<function>, <object>), where <function> is config-function from vite.config.js
Steps to Reproduce

Get any react SSR example (not SPA) like https://github.com/fastify/fastify-vite/tree/dev/examples/react-hydration
Open vite.config.js
Modify export like this

import { defineConfig } from 'vite'
//...
export default defineConfig((config) => {
    return ({ root, plugins })
})

Expected Behavior
No issue

Think is already fixed, need to add a test and push out the new release. Will double check.

This is great news because this bug breaks my build and I had to add a lot of hacks. I'm really looking forward to the release.

In which branch can I see the fixed code


Auto-generation of config if it doesn't exist.

Fixes second part of #144

Temporary fix, unwraps will be removed once proper errors are implemented.

Temporary fix, unwraps will be removed once proper errors are implemented.


Having trouble running on OSX Sierra

Might be similar to closed issue #90
jvsmb:dhtfiles jamie$ MESHBIRD_KEY="075164337e1bb1857e60d50ff8eb05640a070000ffff0000" meshbird --loglevel info join
2017/06/09 18:48:24 INF [main] state restored, &{Secret:0xc4200e2760 ListenPort:5538 PrivateIP:<IP_ADDRESS>}
2017/06/09 18:48:24 INF [local] initializing net-table service
2017/06/09 18:48:24 INF [local] initializing listener service
2017/06/09 18:48:24 INF [listener] listening on 5539 port
2017/06/09 18:48:24 INF [local] running "net-table" service
2017/06/09 18:48:24 INF [local] initializing discovery-dht service
2017/06/09 18:48:24 INF [local] initializing iface service
2017/06/09 18:48:24 INF [local] running "listener" service
2017/06/09 18:48:24 INF [local] running "discovery-dht" service
2017/06/09 18:48:24 FTL [main] error on local node start, initialization of "iface" finished with error: tun interface  up err: up interface  err: exit status 1

my mistake - works with sudo - ok to close


style: align headers icons

Hi, this fix is for the following bug -
https://github.com/hasadna/open-bus-map-search/issues/974
It seems that in the header.css file the '.main-header' template with the field "justify-content" modified the behavior of the headers icons not to be aligned as expected. I change it to "flex-end" that verify that in each language we are using the headers icons bar will be at the end of line which means the other side as expected. Below there is an example of before and after the change.
Before change:

After change:

Thanks!
Have you verified that it looks right on mobile devices?
(visual tests are not executed in the CI pipeline from forked repositories)

Yes. Checked it on mobile as well.
Hebrew view:

English view:

In your PR preview, it seems different -

Hi, updated the MR. Added specific tags for the mobile view. When I checked it as the screenshot you shared I saw the issue.
So I defined the css the order them differently when they are in mobile (also applied for dark mode )

Thanks @ofirc77 !

could you please verify that you have pushed your code, and that it's passing the linter (npm run lint)?
did you try to play with the horizontal size of the browser and see that it looks fine on every screen size?

Yes it passed the lint check and I increased the max-width to 750 to make sure also in horizontal it will look good I played with it a little bit it seems that in some cases it will not function as expected.

you can see it by visiting the commit statuses section of this pull request:

@NoamGaash updated the PR according to the project linter and it seems that all tests are passing now


Error about #r not supported is reported on fs files even when inside #if INTERACTIVE block

VSCode 1.21.1
Ionide-fsharp 3.18.0

This seems to be fixed


Access it via GUI instead of CLI.

[x] I have checked that a similar feature request does not already exist.

Is your feature request related to a problem? Please describe.
No.
Describe the solution you'd like
Have a simple GUI for scrcpy so that we don't need to open the terminal.
Describe alternatives you've considered
I don't know.

How would a GUI improve the process of just clicking scrcpy-noconsole.exe? What features do you have in mind?

There is a similar project with Qt GUI, see this repository https://github.com/barry-ran/QtScrcpy.

How would a GUI improve the process of just clicking scrcpy-noconsole.exe? What features do you have in mind?

On Linux, not crappy Windows.

There is a similar project with Qt GUI, see this repository https://github.com/barry-ran/QtScrcpy.

Thanks!


Allow users to disable schema check and creation on load_file

Support running load_file without checking if the table schema exists or trying to create it.
Introduces the argument schema_exists. This argument is False by default, and the Python SDK will behave as of 1.6 (running schema check & creation queries if needed). When this argument is True, the SDK will not check if the schema exists or try to create it.
Recently a user reported that the cost of checking if the schema exists is very high for Snowflake:
"I have a (load_file) task that took 1:36 minutes to run, and it was 1:30 running the information schema query."
This is likely happening for other databases as well.
Closes: #1921

@tatiana Do you think a global setting as a default can be helpful? like an env variable?

@tatiana Do you think a global setting as a default can be helpful? like an env variable?

@utkarsharma2 that's a great idea, I'll add to this PR.

@utkarsharma2 I added the global config, please, let me know your thoughts!


Refactoring of table feature properties decoding

This patch modifies the encoding and decoding implementation of the
OpenFlow table feature properties in order to comply with 1.3.1
specification. Unit tests updated appropriately, tested in conjuction
with LINC-Switch.
Added String functions to print a readable representation of the
few OpenFlow types.
closes #112

cc @samribeiro


Append new entries to pickle file (KNNClassifier object)

face_recognition version: v1.22
Python version: 3.6
Operating System: Mac

Description
I am trying to add new encodings and names to saved pickle file (KNNClassifier object) - but unable to append.
What I Did
        # Save the trained KNN classifier
        if os.path.getsize(model_save_path) > 0:
            if model_save_path is not None:
                with open(model_save_path, 'rb') as f:
                    unpickler = pickle.Unpickler(f)
                    clf = unpickler.load()

            newEncodings = X, y
            clf.append(newEncodings)

            with open(model_save_path,'wb') as f:
                pickle.dump(clf, f)

        else:
            if model_save_path is not None:
                with open(model_save_path, 'wb') as f:
                     pickle.dump(knn_clf, f)

Getting error : KNeighborsClassifier' object has no attribute 'append'  Is there any way to achieve this? Please advice.
Other questions, if I train all images for every new training requests, does it going to impact the verification process as the pickle file is in use or OS can handle that?
I am working on moving to MySQL, if anyone did this please share your thoughts. Thank you!

* face_recognition version: v1.22

* Python version: 3.6

* Operating System: Mac

Description
I am trying to add new encodings and names to saved pickle file (KNNClassifier object) - but unable to append.
What I Did
        # Save the trained KNN classifier
        if os.path.getsize(model_save_path) > 0:
            if model_save_path is not None:
                with open(model_save_path, 'rb') as f:
                    unpickler = pickle.Unpickler(f)
                    clf = unpickler.load()

            newEncodings = X, y
            clf.append(newEncodings)

            with open(model_save_path,'wb') as f:
                pickle.dump(clf, f)

        else:
            if model_save_path is not None:
                with open(model_save_path, 'wb') as f:
                     pickle.dump(knn_clf, f)

Getting error : KNeighborsClassifier' object has no attribute 'append'  Is there any way to achieve this? Please advice.
Other questions, if I train all images for every new training requests, does it going to impact the verification process as the pickle file is in use or OS can handle that?
I am working on moving to MySQL, if anyone did this please share your thoughts. Thank you!

Hello, first off as the error suggests, a classifier behaves differently than a python list and you cannot append objects and arrays to it.
What it think you meant to do here is to update the classifier using new embeddings.
Sadly within for most of the models, the online training option is not included. So this requires you to train the KNN once again from scratch (clf.fit()) with all the samples from the database which does not seem feasible.
I would recommend you to look up river which supports updating a classifier using only one sample. They also have a KNNClassifier instance, the difference is that you use model = model.learn_one(x, y)  to train on one instance. So the replacement would be easy.

Thank you @KiLJ4EdeN
The online learning library river, provide learn_one(x, y) & predict_one(x) methods in KNNClassifier. I have rewritten my code to include river here:
def train_online(train_dir, model_save_path=None, n_neighbors=None, knn_algo='ball_tree', verbose=False):

        X = []
        y = []

         # Loop through each person in the training set
        for class_dir in os.listdir(train_dir):
            if not os.path.isdir(os.path.join(train_dir, class_dir)):
                continue

            # Loop through each training image for the current person
            for img_path in image_files_in_folder(os.path.join(train_dir, class_dir)):
                image = face_recognition.load_image_file(img_path)
                face_bounding_boxes = face_recognition.face_locations(image)
                # face_bounding_boxes = face_recognition.face_locations(image, number_of_times_to_upsample=2, model="cnn")

                if len(face_bounding_boxes) != 1:
                    # If there are no people (or too many people) in a training image, skip the image.
                    if verbose:
                        print("Image {} not suitable for training: {}".format(img_path, "Didn't find a face" if len(face_bounding_boxes) < 1 else "Found more than one face"))
                else:
                    # Add face encoding for current image to the training set
                    # X.append(face_recognition.face_encodings(image, known_face_locations=face_bounding_boxes, num_jitters=100)[0])
                    X.append(face_recognition.face_encodings(image, known_face_locations=face_bounding_boxes)[0])
                    y.append(class_dir)

        if n_neighbors is None:
            n_neighbors = int(round(math.sqrt(len(X))))
            if verbose:
                print("Chose n_neighbors automatically:", n_neighbors)

        model = (preprocessing.StandardScaler(), neighbors.KNNClassifier(n_neighbors=n_neighbors, algorithm=knn_algo, weights='distance'))

        for encoding, name in zip(X, y):
            model.learn_one(encoding, name)

Please help me in understanding the below items:

How do I save the model, as I did it in pickle format?
How to load and get this model, when I need it for prediction? (predict_one).

This is new to me, kindly advice.

I am closing this issue, as I have implemented using PostgreSQL, and I feel that is much better solution in my case.
If any starter facing same scenario, have a look at here  it might help.
@KiLJ4EdeN thanks for your reply, I got to learn about online training.


utils.pad_and_concat cannot pad torch.LongTensor list

pad_and_concat function cannot pad torch.LongTensor. For example
>>> a = [torch.tensor([[1,2]]), torch.tensor([[3]])]
>>> a[0].dtype
torch.int64
>>> texar.utils.pad_and_concat(a, 0)
Traceback (most recent call last):
  File "<input>", line 1, in <module>
  File "/Users/haoransh/PycharmProjects/texar-pytorch/texar/utils/shapes.py", line 221, in pad_and_concat
    values[i] = torch.cat((v, padding), dim=pad_dim)
RuntimeError: Expected object of scalar type Long but got scalar type Float for sequence element 1 in sequence argument at position #1 'tensors'

Fixed by #52


Support for mobile safari, android browser, chrome for ios/android, others mobile browsers?

Hi Browser Update

Your project is fantastic!

Are you considering adding notifications for old mobile browsers too?

Thanks,
Christiaan Kortekaas

Original issue reported on code.google.com by<EMAIL_ADDRESS>on 10 Dec 2014 at 1:55

We now notify android phones.


Added convenience method DocumentSession for getting last committed e…

…vents.
This potentially fixes #324
Thoughts?

@jarroda I think I'd rather see it sitting on the IChangeSet interface. I only say that because IDocumentSession is already pretty crowded. Plus that way you could access all the events from previous commits if there were any.

Great point.  How about this?

@jarroda That looks like a winner to me. Wanna add a test for it, and then I'll pull it in?

Sounds good.  I'll try to knock that out today.

Nice! I needed this one as well :)

Looks good, I'm pulling this in now.

Pulled in with a rebase.


"Unexpected token" with import statements

Running the following gives an "Unexpected token" error:
esprima.parse('import foo from "bar"');

esprima 2.5.0
node 0.12.7
npm 3.2.0
The online parser demo at http://esprima.org/demo/parse.html also gives this error.
Is import/export syntax not supported yet?

You need to specify that it is a module that is being parsed (vs a script):
esprima.parse('import foo from "bar"', { sourceType: 'module'} );

Thanks, figures I was missing something simple :)

@nebrius Glad to know it's working for you :-)

Use like below.
esprima.parseModule('import foo from "bar"');


fix retry key and nonce for draft-34

Fortunately, we haven't cut any release that officially supports draft-34 yet.

The interop runner is happy with these changes.


Configuration in isolated mode

I'm trying to change my .NET 6 Azure Functions V4 project to isolated mode but seem to be missing some stuff

How to get the ApplicationRootPath or Environment values in either ConfigureHostConfiguration/ConfigureAppConfiguration
How to get the IConfiguration in ConfigureServices

Previously I could use the IFunctionConfigurationBuilder/IFunctionsHostBuiler  GetContext() method but I can't find an equivalent

Hi @phatcher,

ConfigureAppConfiguration has an overload which takes an Action of type: Action<HostBuilderContext, IConfigurationBuilder> configureDelegate)
- I think ApplicationRootPath now is accessible from the HostBuilderContext type and now has the name ContentRootPath,
- You can access the Environment values by using the static class Environment or if you need something which was not declared there you can use string myCustomEnvVariable = Environment.GetEnvironmentVariable("my_custom_env_variable ")

Example for ConfigureAppConfiguration
    .ConfigureAppConfiguration((hostBuilderContext, builder) =>
    {
        IHostEnvironment hostingEnvironment = hostBuilderContext.HostingEnvironment;
        IConfiguration configuration = hostBuilderContext.Configuration;

        string myCustomEnvVariable = Environment.GetEnvironmentVariable("my_custom_env_variable");

        // Example of configuring
        // local.settings.json, environment variables, visual studio user secrets.
        builder.SetBasePath(Directory.GetCurrentDirectory())
                .AddJsonFile("local.settings.json", optional: true, reloadOnChange: true)
                .AddEnvironmentVariables()
                .AddUserSecrets(Assembly.GetExecutingAssembly(), optional: true);
    })

To get IConfiguration in ConfigureServices you need to use
ConfigureServices(Action<HostBuilderContext, IServiceCollection> configureDelegate); overload.

Example:
    .ConfigureServices((hostBuilderContext, services) =>
    {
        IConfiguration configuration = hostBuilderContext.Configuration;
        string sqlConnectionString = configuration.GetValue<string>("SqlConnectionString");

        services.AddScoped<IUserService, UserService>();
    })

@davidpetric Thanks for that, it's unblocked me from proceeding - I think something along these lines needs to go into the migration guide as finding the overloads is a bit non-obvious.
Just need to see if it works now and whether I can easily get over the lack of INameResolver ;-)

Flagging this as an opportunity to improve samples/docs.

The answer in this issue is indeed the correct one, using Directory.GetCurrentDirectroy() to set the configurationbuilder base path.
The documentation here is out of date, not relevant for isolated workers: https://learn.microsoft.com/en-us/azure/azure-functions/functions-dotnet-dependency-injection#customizing-configuration-sources
Best to also add the sample there:
https://learn.microsoft.com/en-us/azure/azure-functions/dotnet-isolated-process-guide
var host = new HostBuilder()
    .ConfigureFunctionsWebApplication()
    .ConfigureAppConfiguration((context, configBuilder) =>
    {
        configBuilder
            .SetBasePath(Directory.GetCurrentDirectory())
            .AddJsonFile($"appsettings.{context.HostingEnvironment.EnvironmentName}.json", optional: true);
    })

And results in:

Unhandled exception. System.IO.FileNotFoundException: The configuration file 'appsettings.Staging.json' was not found and is not optional. The expected physical path was '/azure-functions-host/appsettings.Staging.json'.

Re getting over the lack of INameResolver,  take a look at my post on Stack Overflow about how I resolved my issue.
https://stackoverflow.com/questions/78897966/azure-functions-trigger-variables-isolated-functions/78897967


Scene: Remove unused mesh_materials StringNames

They were added in 8be2fabbe5cd846bac5e5a38e55f3fb70e73f2da (2.1 era) but
were likely a first attempt that didn't get unused in the end.

Cherry-picked for 3.4.


Suggestion : Sticky note inside Godot

Hi,
Just a suggestion that would be helpfull to me and probably others:
When i open Godot, i would like something like a sticky note that a wrote to show somewhere on the screen, and i could know what i was doing last time i opened Godot, what to do next or whatever i wrote inside.
Be able to write comment (on a note, not in GDscript) and attach it the node i want, so i could write inside what to improve on this or that node.
Commenting in GDScript is good but can be pain in the arse to read.
And thank you for this wonderfull tool that is Godot Engine!

Like the grease pencil in Blender, that's a cool idea I like it :)

That's a duplicate of #7361. It's a good candidate for an editor plugin IMO.


Add Data Factory scanner

Description
Adding Azure Data Factory support.
Issue reference
We strive to have all PR being opened based on an issue, where the problem or feature have been discussed prior to implementation.
Please reference the issue this PR will close: #103
Checklist
Please make sure you've completed the relevant tasks for this PR, out of the following list:

[x] Code compiles correctly
[x] Created/updated tests
[x] Unit tests passing

Codecov Report

Merging #133 (af6303d) into main (ba5d995) will decrease coverage by 0.38%.
The diff coverage is 23.80%.

@@            Coverage Diff             @@
##             main     #133      +/-   ##
==========================================
- Coverage   45.90%   45.53%   -0.38%
==========================================
  Files          60       62       +2
  Lines        2884     2954      +70
==========================================
+ Hits         1324     1345      +21
- Misses       1548     1597      +49
  Partials       12       12

Files Changed
Coverage Δ

internal/scanners/adf/adf.go
0.00% <0.00%> (ø)

internal/scanners/afd/rules.go
86.20% <0.00%> (ø)

internal/scanners/afw/rules.go
76.31% <0.00%> (ø)

internal/scanners/agw/rules.go
35.21% <0.00%> (ø)

internal/scanners/aks/rules.go
90.90% <0.00%> (ø)

internal/scanners/apim/rules.go
91.48% <0.00%> (ø)

internal/scanners/appcs/rules.go
91.11% <0.00%> (ø)

internal/scanners/cae/rules.go
88.57% <0.00%> (ø)

internal/scanners/ci/rules.go
88.88% <0.00%> (ø)

internal/scanners/cog/rules.go
89.74% <0.00%> (ø)

... and 22 more


docs: Add enjoyable.recipes to the showcase

 Thank you for your submission, we really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.You have signed the CLA already but the status is still pending? Let us recheck it.

Hello @shubhojyoti,
thank you for adding your website to the showcase of Hugo. I've merged your contribution as  a2ec372a.
Hugo's showcase section should be updated within the next minutes.
Cheers,
Digitalcraftsman


add license badge

@elliottslaughter can you please review

@shahzebsiddiqui Thanks for submitting this and sorry for the slow response.
Do you know anything about the licensing status of the badge itself? Our one thought was that if we move the repo in the future (not that we're planning this, but as a contingency), if we embedded the SVG into the repo it might make it more resilient to such potential change (or availability of the shields.io service).

Yes if you move the repo the badge won't render properly. You have to look at shields.io for list of badges they have url links on all the badges


Function and method names should be more self-declaring

Example:
rumq_client::publish does not publish anything, it creates a Publish object that would later have to be sent to the eventstream. same with rumq_client::subscribe
It would make more sense to have them as Publish::new(...) and Subscribe::new(..), or just rename them into create_publish, and create_subscribe
There are numerous such issues that should be addressed before a 1.0 release, to make it easier for newcomers to navigate the library. Lets collect those issues here and discuss them.

Fixed in some commit that I don't remember :). Please feel free to reopen this if you have more issues


Custom operators don't work as described in documentation

When I define a custom operator as described here https://rhai.rs/book/engine/custom-op.html#example
it works as foo(x,y) and not as x foo y.  Does infix only work for primitive types?
Also what are the rules for the name of symbol operators? When I define an operator as e.g. #< or <# it doesn't work because the parser fails to see both characters.

It seems to work in the doc test for Engine::register_custom_operator...
Custom operators must be identifiers; they cannot be symbols, as symbols are parsed in the tokenizer and if it is not recognized, it throws a parsing error early.

You don't seem to have registered a function called lt...
You need something like: engine.register_fn("lt", |a: DateTime, b: DateTime| a < b)

Sorry, I forgot to paste that code:
    engine.register_fn(
        "lt",
        |x: chrono::DateTime<Utc>, y: chrono::DateTime<Utc>| x.cmp(&y).is_lt(),
    );

It is working but not in infix notation.
I will take a look to the plugin solution but I don't think that's solved my issues. Seems more an issue with the parser.

What is the actual error you got?
BTW, you should probably register the actual type instead: engine.register_type_with_name::<chrono::DateTime<Utc>>("DateTime")

This is working:
        let script_content = indoc::indoc! {r#"
            if lt(cs_start_datetime,new_dt(2021,11,1,0)) {
                "foo"
            } else {
                "bar"
            }
        "#};

This gives error ParseError(MissingToken("{", "to start a statement block"), 1:22):
        let script_content = indoc::indoc! {r#"
            if cs_start_datetime lt new_dt(2021,11,1,0) {
                "foo"
            } else {
                "bar"
            }
        "#};

BTW, you should probably register the actual type instead: engine.register_type_with_name::<chrono::DateTime>("DateTime")

Has no effect

I have a test version short of using chrono and it works just fine:
let mut engine = Engine::new();

// Register a custom operator called `lt` and give it
// a precedence of 160 (i.e. between +|- and *|/).
engine.register_custom_operator("lt", 160).unwrap();

// Register a binary function named `lt`
engine
    .register_fn("new_num", || 5 as INT)
    .register_fn("lt", |x: INT, y: INT| x < y);

let mut scope = Scope::new();
scope.push("x", 3 as INT);

assert_eq!(
    engine.eval_with_scope::<INT>(&mut scope, "if x lt new_num() { 42 } else { 123 }")?,
    42
);

And does it still works if you define parameters for new_num?

Yes it does work with parameters...
Considering that it failed at parsing, meaning that Rhai doesn't think lt is a custom operator.  That's very strange, if you register that operator before running the script.

Yes, it's defined before running the script.

O wait, I made the assumption that registering custom functions is only needed for evaluation of a script but it is also needed for the compilation....
And besides that I implemented datetime support after I did the refactor in which compilation was separated from the evaluation. Otherwise I noticed this issue during the refactor and was put directly on the right track for finding the cause.
Anyway, my mistake, did a wrong assumption. Thanks for your help!

So the confusing part is that everything was still working except for the definition of the custom operator.

Btw, I will change my solution and use your suggested plugin solution.

Glad for you to get it working.  The custom operator is actually only needed during parsing as the compiler desugars it to an actual function call.  It is no longer required in evaluation.


fix(rest-api): Avoid panic in append_info_headers

Description of change
The REST API might cause the node to panic if append_info_headers fails to retrieve the data. This PR updates append_info_headers to return an internal server error when it fails.
Links to any relevant issues
Close #4087
Type of change

Bug fix

Change checklist

[x] I have followed the contribution guidelines for this project
[x] I have performed a self-review of my own code
[x] I have checked that new and existing unit tests pass locally with my changes

It seems that this issue was already fixed in the upstream. They just ignore the header if the corresponding object is not found instead of failing with internal server error.

@Alex6323 do you suggest that we use cherry pick to merge their fix in the PR?

After the sync call discussion @alexsporn suggested to cherry pick the commit @semenov-vladyslav found in this PR, then we merge it.


bootstrap on schemas

PGSync version: 1.1.5
Postgres version: 9.6
Elasticsearch version: 7.7.1
Redis version: latest
Python version: 3.7
Problem Description:
bootstrap makes triggers on different schemas for tables with the same name.
For example:
-public
--table1
-my_schema
--table1
it makes triggers in public and my_shema but remove only from the public.
Error Message (if any):

You are right. There was a bug when tearing down secondary schemas. This has been resolved in version 1.1.6


[Blocked] Updated Swift code style

Description

Updated Swift code style to match general guidelines

Status

[x] Code review

Overall I don't mind on using self or not. I find it useful on projects but we usually have the discussion within a team and the answer has varied (but mostly that it is useful). Since this is a small Swift only library I think its ok to remove it though on application code I still find it useful.
Happy to merge when the light is green

@madhikarma I always prefer to use self for context and readability but nowadays the general rule and apple recommendation is not to use it except when needed so I am guessing most people will be familiar with that rule as well.

Current coverage is 97.25% (diff: 100%)

Merging #20 into master will decrease coverage by 0.02%

@@             master        #20   diff @@
==========================================
  Files             4          4
  Lines           514        510     -4
  Methods           0          0
  Messages          0          0
  Branches          0          0
==========================================
- Hits            500        496     -4
  Misses           14         14
  Partials          0          0

Powered by Codecov. Last update 9198ec7...a18fc47

Will close this for now until a proper discussion is setup around style and to when we add swift lint.


support OData advanced filters

I would like to use filters like http://services.odata.org/Northwind/Northwind.svc/Customers?$filter=substringof('Alfreds', CompanyName) eq true

Great addition, do you know if that is already supported by ExactOnline? I think we'd need to change this file then https://github.com/exactonline/exactonline-api-ruby-client/blob/master/lib/elmas/uri.rb

If we use this, we get a 501 error. Not implemented.
I expected that I could use this, as they state to use OData filters in their docs.
Apparently not.

They might use it with different resources, you could open a support ticket with them to ask.

I've just found that I could do the following:
indexof(Name, '".$code."') ge 0