Warning when trying to create a CustomLayer with webgl PointsLayer

I'm currently following the workshop but I'm now stuck on the WebGL rendering part.
The following code should be similar to what the workshop propose to render meteorites:
import 'ol/ol.css';
import {Map, View, Feature} from 'ol';

import TileLayer from 'ol/layer/Tile';
import VectorLayer from 'ol/layer/Vector';

import VectorSource from 'ol/source/Vector';
import XYZSource from 'ol/source/XYZ';

import Point from 'ol/geom/Point';

import {fromLonLat} from 'ol/proj';

import Renderer from 'ol/renderer/webgl/PointsLayer';
import {clamp} from 'ol/math';

const stamenLayer = new TileLayer({
    source: new XYZSource({
        url: 'http://tile.stamen.com/terrain/{z}/{x}/{y}.jpg'
    })
});

const meteoriteSource = new VectorSource();
const client = new XMLHttpRequest();
client.open('GET', 'data/meteorites.csv');
client.onload = function() {
    const csv = client.responseText;
    const features = [];

    let prevIndex = csv.indexOf('\n')+1;
    let curIndex;
    while ((curIndex = csv.indexOf('\n', prevIndex)) != -1) {
        const line = csv.substr(prevIndex, curIndex - prevIndex).split(',');
        prevIndex = curIndex +1;

        const coords = fromLonLat([parseFloat(line[4]), parseFloat(line[3])]);
        if (isNaN(coords[0]) || isNaN(coords[1])) {
            continue;
        }

        features.push(new Feature({
            mass: parseFloat(line[1]) || 0,
            year: parseInt(line[2]) || 0,
            geometry: new Point(coords)
        }));
    }
    meteoriteSource.addFeatures(features);
}
client.send();

const color = [1, 0, 0, 0.5];

class CustomLayer extends VectorLayer {
    createRenderer() {
        return new Renderer(this, {
            colorCallback: function(feature, vertex, component) {
                return color[component];
            },
            sizeCallback: function(feature) {
                return 18 * clamp(feature.get('mass') / 200000, 0, 1) + 8;
            }
        });
    }
}
const webglLayer = new CustomLayer({
    source: meteoriteSource,
});

const map = new Map({
    target: 'map-container',
    layers: [
        stamenLayer,
        webglLayer,
        // dynamicLayer,
        // aisLayer,
    ],
    view: new View({
        center: fromLonLat([0, 0]),
        zoom: 2
    })
});

Unfortunately, at this point, nothing happens and I am having a series of warning:
33 WebGL: INVALID_OPERATION: useProgram: program not valid
6 WebGL: INVALID_OPERATION: getUniformLocation: program not linked
2 Helper.js:642 WebGL: INVALID_OPERATION: getAttribLocation: program not linked
./node_modules/ol/webgl/Helper.js.WebGLHelper.getAttributeLocation @ Helper.js:642
./node_modules/ol/webgl/Helper.js.WebGLHelper.enableAttributeArray_ @ Helper.js:692
./node_modules/ol/webgl/Helper.js.WebGLHelper.enableAttributes @ Helper.js:712
./node_modules/ol/renderer/webgl/PointsLayer.js.WebGLPointsLayerRenderer.prepareFrame @ PointsLayer.js:374
./node_modules/ol/layer/Layer.js.Layer.render @ Layer.js:209
./node_modules/ol/renderer/Composite.js.CompositeMapRenderer.renderFrame @ Composite.js:111
./node_modules/ol/PluggableMap.js.PluggableMap.renderFrame_ @ PluggableMap.js:1120
(anonymous) @ PluggableMap.js:175
requestAnimationFrame (async)
./node_modules/ol/PluggableMap.js.PluggableMap.render @ PluggableMap.js:1042
./node_modules/ol/PluggableMap.js.PluggableMap.handleSizeChanged_ @ PluggableMap.js:901
./node_modules/ol/events/Target.js.Target.dispatchEvent @ Target.js:115
./node_modules/ol/Object.js.BaseObject.notify @ Object.js:154
./node_modules/ol/Object.js.BaseObject.set @ Object.js:173
./node_modules/ol/PluggableMap.js.PluggableMap.setSize @ PluggableMap.js:1163
./node_modules/ol/PluggableMap.js.PluggableMap.updateSize @ PluggableMap.js:1196
./node_modules/ol/PluggableMap.js.PluggableMap.handleTargetChanged_ @ PluggableMap.js:954
./node_modules/ol/events/Target.js.Target.dispatchEvent @ Target.js:115
./node_modules/ol/Object.js.BaseObject.notify @ Object.js:154
./node_modules/ol/Object.js.BaseObject.set @ Object.js:173
./node_modules/ol/Object.js.BaseObject.setProperties @ Object.js:186
PluggableMap @ PluggableMap.js:319
Map @ Map.js:83
./main.js @ main.js:69
__webpack_require__ @ bootstrap:19
0 @ log.js:47
__webpack_require__ @ bootstrap:19
(anonymous) @ bootstrap:83
(anonymous) @ bootstrap:83
Helper.js:450 WebGL: INVALID_OPERATION: drawElements: no valid shader program in use
./node_modules/ol/webgl/Helper.js.WebGLHelper.drawElements @ Helper.js:450
./node_modules/ol/renderer/webgl/PointsLayer.js.WebGLPointsLayerRenderer.renderFrame @ PointsLayer.js:330
./node_modules/ol/layer/Layer.js.Layer.render @ Layer.js:210
./node_modules/ol/renderer/Composite.js.CompositeMapRenderer.renderFrame @ Composite.js:111
./node_modules/ol/PluggableMap.js.PluggableMap.renderFrame_ @ PluggableMap.js:1120
(anonymous) @ PluggableMap.js:175
requestAnimationFrame (async)
./node_modules/ol/PluggableMap.js.PluggableMap.render @ PluggableMap.js:1042
./node_modules/ol/PluggableMap.js.PluggableMap.handleSizeChanged_ @ PluggableMap.js:901
./node_modules/ol/events/Target.js.Target.dispatchEvent @ Target.js:115
./node_modules/ol/Object.js.BaseObject.notify @ Object.js:154
./node_modules/ol/Object.js.BaseObject.set @ Object.js:173
./node_modules/ol/PluggableMap.js.PluggableMap.setSize @ PluggableMap.js:1163
./node_modules/ol/PluggableMap.js.PluggableMap.updateSize @ PluggableMap.js:1196
./node_modules/ol/PluggableMap.js.PluggableMap.handleTargetChanged_ @ PluggableMap.js:954
./node_modules/ol/events/Target.js.Target.dispatchEvent @ Target.js:115
./node_modules/ol/Object.js.BaseObject.notify @ Object.js:154
./node_modules/ol/Object.js.BaseObject.set @ Object.js:173
./node_modules/ol/Object.js.BaseObject.setProperties @ Object.js:186
PluggableMap @ PluggableMap.js:319
Map @ Map.js:83
./main.js @ main.js:69
__webpack_require__ @ bootstrap:19
0 @ log.js:47
__webpack_require__ @ bootstrap:19
(anonymous) @ bootstrap:83
(anonymous) @ bootstrap:83
12 [.WebGL-0x5628f92342e0]RENDER WARNING: there is no texture bound to the unit 0

Is there something missing in the workshop or is this a bug ?

Hi, thanks for the bug report. It looks like the code in the workshop is not working any more... I'll look into it.

Ok so the hosted workshop is not up to date, which is why you get these errors. You can take a look at the source of the workshop which contains working code (albeit not in a very readable way): https://github.com/openlayers/workshop/blob/master/src/en/examples/webgl/animated.js

hi!
Found the same errors following the same Workshop tutorial https://openlayers.org/workshop/en/webgl/points.html
With the new github solution errors dissapeared but I don't want animated points. Using only this fragment shader should work? Or I also need a simplified vertexShader?  Thank you!
fragmentShader: `
precision mediump float;
varying vec2 v_texCoord;
varying vec4 v_color;
void main(void) {
vec2 texCoord = v_texCoord * 2.0 - vec2(1.0, 1.0);
float sqRadius = texCoord.x * texCoord.x + texCoord.y * texCoord.y;
float value = 2.0 * (1.0 - sqRadius);
float alpha = smoothstep(0.0, 1.0, value);
gl_FragColor = v_color;
gl_FragColor.a *= alpha;

}`

For a simple use case you're better off using the WebGL Points layer class which adds some abstraction over the shader complexity, see example:
https://openlayers.org/en/master/examples/webgl-points-layer.html?q=webgl

@jahow thank you! I was checking it... the thing is I'm using it with ElectronJS and for some reason "ol/layer/WebGLPoints" is not working. I'm loading OpenLayer using the <script> tag...
I also have doubts if using this WebGL Points layer I can add interaction using the getFeaturesAtPixel() function ?? The thing is we are loading a json data with almost 90000 points, they should be clickable... I'm looking for something that allow me load all this points and we can smoothly navigate and interact with the map....

As @jahow mentioned here, the WebGLPoints layer is currently only available if you use openlayers as a node module. The legacy ol.js does not include experimental classes.
Here is an example with interaction:
https://openlayers.org/en/latest/examples/icon-sprite-webgl.html?q=webgl

@flors I've got a similar use case.
For a working non-animated solution of the workshop example:
class CustomLayer extends VectorLayer {
    createRenderer() {
        return new Renderer(this, {
            attributes: [{
                name: 'size',
                callback: function (feature) {
                    return 32 * clamp(feature.get('mass') / 200000, 0, 1) + 16;
                }
            },
                {
                    name: 'year',
                    callback: function (feature) {
                        return feature.get('year');
                    },
                }],
            uniforms: {
            },
            vertexShader: `
        precision mediump float;
        uniform mat4 u_projectionMatrix;
        uniform mat4 u_offsetScaleMatrix;
        uniform mat4 u_offsetRotateMatrix;
        attribute vec2 a_position;
        attribute float a_index;
        attribute float a_size;
        attribute float a_year;
        varying vec2 v_texCoord;
        void main(void) {
          mat4 offsetMatrix = u_offsetScaleMatrix;
          float offsetX = a_index == 0.0 || a_index == 3.0 ? -a_size / 2.0 : a_size / 2.0;
          float offsetY = a_index == 0.0 || a_index == 1.0 ? -a_size / 2.0 : a_size / 2.0;
          vec4 offsets = offsetMatrix * vec4(offsetX, offsetY, 0.0, 0.0);
          gl_Position = u_projectionMatrix * vec4(a_position, 0.0, 1.0) + offsets;
          float u = a_index == 0.0 || a_index == 3.0 ? 0.0 : 1.0;
          float v = a_index == 0.0 || a_index == 1.0 ? 0.0 : 1.0;
          v_texCoord = vec2(u, v);
        }`,
            fragmentShader: `
        precision mediump float;
        varying vec2 v_texCoord;
        void main(void) {
          vec2 texCoord = v_texCoord * 2.0 - vec2(1.0, 1.0);
          float sqRadius = texCoord.x * texCoord.x + texCoord.y * texCoord.y;
          float value = 2.0 * (1.0 - sqRadius);
          float alpha = smoothstep(0.0, 1.0, value);
          gl_FragColor = vec4(1.0, 0.0, 0.0, 0.3);
          gl_FragColor.a *= alpha;
          gl_FragColor.rgb *= gl_FragColor.a;
        }`
        });
    }
}

You need both vertexShader and fragmentShader for it to work, as mentionned in the doc.
Also, note that vertexShader is setting the position with gl_Position while fragmentShader is setting color with gl_FragColor. So here, both are mandatory it seems.
Also, not sure to understand how the piping work behind the scene, but it seems like vertexShader is setting variable that fragmentShader will later use.
I'll be curious to have more clarifications or documentation link to understand a bit better how those two shaders work together and why you set the position and color in two distinct shaders instead of one.
If you want to understand a bit more how this is working, you should check out the link mentionned in the workshop. It looks like a pretty good introduction to shaders.
You can use getFeaturesAtPixel() with WebGLPointsLayer. I did that during my previous tests.
Also, as an alternative to WebGL, you might consider using VectorImage for fast rendering of vectors. Didn't tried that yet...

There are many articles about how shaders work in WebGL, you could for example start here.

I'll be curious to have more clarifications or documentation link to understand a bit better how those two shaders work together and why you set the position and color in two distinct shaders instead of one.

Geometries are first processed by the vertex shader (once for each vertex), and then the fragment shader will run for every pixel drawn on screen for this geometry. So yes, you need to pass vertex attributes such as color from the vertex shader to the fragment shader. gl_Position is the output of the vertex shader, and gl_FragColor the output of the fragment shader.
The webgl renderer in OpenLayers is pretty low level so it will essentially bind uniforms and attributes for you, and let you complete freedom over the vertex and fragment shaders.

@jahow Excellent link, thanks !
I start to understand a bit more what is happening in the vertexShader
So, if I'm not mistaken, those lines will allow to set the position of each vertices in the clip space of webgl (-1 to 1):
          mat4 offsetMatrix = u_offsetScaleMatrix;
          float offsetX = a_index == 0.0 || a_index == 3.0 ? -a_size / 2.0 : a_size / 2.0;
          float offsetY = a_index == 0.0 || a_index == 1.0 ? -a_size / 2.0 : a_size / 2.0;
          vec4 offsets = offsetMatrix * vec4(offsetX, offsetY, 0.0, 0.0);
          gl_Position = u_projectionMatrix * vec4(a_position, 0.0, 1.0) + offsets;

It seems to me that the various matrices are doing the heavy work here. It looks a bit magic to me but am I right to say those are transformation matrix ?
How could I use the last one, uniform mat4 u_offsetRotateMatrix ?
Also, I can't figure out in what use case the vertexShader would differ from what is provided in the earliest workshop example except if you want to do 3D rendering. Any example ?

They are transformation matrix, although not very complex since we're only working in 2 dimensions.

Also, I can't figure out in what use case the vertexShader would differ from what is provided in the earliest workshop example except if you want to do 3D rendering. Any example ?

Well for one thing the vertex shader will become more complex if you want to rotate the symbols, for example. Besides, you always have to pass vertex attributes to the fragment shaders through them which means you can't just have one shader for all uses.
Other than that, there have been an attempt to actually render the features at different depth in order to do basic z-sorting with the GPU, which would probably add more complexity to the shader. That would be an awesome addition to the renderer IMO.
Working with shaders can be both exciting and very frustrating (especially when it comes to debugging), which is why the webgl layer class brings an abstraction layer over it and translates readable style objects into shaders automatically.
Note: if you enjoy shaders I encourage you to take a look at the book of shaders which has some pretty awesome techniques, some of them used in OL ;)

Other than that, there have been an attempt to actually render the features at different depth in order to do basic z-sorting with the GPU, which would probably add more complexity to the shader.

Hum, I might still not fully understand how rendering in WebGL works. But here is how I guess the rendering is done:
For each feature in features: // CPU time
    render feature // GPU time: WebGL action

In that case, basic z-sorting could be as simple as that:
For each feature in (features ordered by z-index):
    render feature

But maybe I'm missing something here ?

Working with shaders can be both exciting and very frustrating (especially when it comes to debugging)

To get back to something more related to the original issue. Any time my shader programs have syntax error, I get the warnings previously mentionned.
It seems that some debug informations provided by WebGL could be added whenever a shader failed to compile. Here for a simple example.
Something similar could be quite useful before the return statements of those lines : https://github.com/openlayers/openlayers/blob/3014b68254be3ac0c4cfce9af41d90e2aa321a1b/src/ol/webgl/Helper.js#L745-L749

But maybe I'm missing something here ?

This solution will be very costly on the CPU (z-index might potentially change every frame).

It seems that some debug informations provided by WebGL could be added whenever a shader failed to compile.

This was attempted but the problem is that sometimes some browser will output warnings even though the shaders are fine. If you're working on your own shaders you should use this:
https://github.com/openlayers/openlayers/blob/3014b68254be3ac0c4cfce9af41d90e2aa321a1b/src/ol/renderer/webgl/Layer.js#L76-L83
And print whatever is in there yourself.


Error on dotnet iqsharp install

I am a newbie, so bear with me. I couldn't get Q# to work using purely VS Code, as I was told by my tutorial. So, I wanted to install the python package and run my Hello World program that way, but it just gave a ModuleNotFoundError for from QuantumHello import SayHello.
Then I tried this python program for debugging:
import qsharp qsharp.reload() print(qsharp.get_available_operations())
I started it using anaconda in the qsharp environment:
(qsharp-env) C:\Users\User>python C:\Users\User\Documents\Q#\QH\start.py {'text/plain': 'Reloading workspace.', 'application/json': '{"LastUpdated":"2021-02-12T22:49:14.0484048+01:00","IsCompleted":false,"Description":"Reloading workspace","Subtask":null}'} []
Then I read somewhere I needed the dotnet iqsharp package too and this seemed reasonable enough, as python did not seem to recognize my qs-file I placed in the same folder. I then ran dotnet tool install -g Microsoft.Quantum.IQSharp and then wanted to proceed by running dotnet iqsharp install, but I got this error:
System.ComponentModel.Win32Exception (5): Zugriff verweigert ("Access denied" in German)    at System.Diagnostics.Process.StartWithCreateProcess(ProcessStartInfo startInfo)    at System.Diagnostics.Process.Start()    at Microsoft.DotNet.Cli.Utils.Command.Execute(Action1 processStarted)    at Microsoft.DotNet.Cli.Utils.Command.Execute()    at Microsoft.DotNet.Cli.Program.ProcessArgs(String[] args, ITelemetry telemetryClient)    at Microsoft.DotNet.Cli.Program.Main(String[] args)
The same error occurs if trying to run dotnet iqsharp --version or any other dotnet iqsharp-command.
I even tried repairing dotnet and rerunning dotnet tool install -g Microsoft.Quantum.IQSharp, but that changed nothing.
When I tried to run a command starting with dotnet-iqsharp it only returned Zugriff verweigert (Access denied).
I dont know what I've been doing wrong and if I've been soing something wrong, but I hope someone here can help me. Thank you in advance!

Hi @LM726, so the second issue (Access denied) is likely because you already have IQSharp installed, and because an IQ# kernel is running after you started the Python script, the file system won't let you overwrite the package. The iqsharp conda package automatically installs this so you don't have to do that manually.
As for your first issue, this could be due to a bug in the Q# code, or perhaps because the Q# operation is not actually defined anywhere. You need to add a .qs file in the same directory as your notebook file where you define the SayHello operation and should look something like this:
namespace QuantumHello
{
    operation SayHello(name: String) : Unit {
        Message($"Hello {name}!");
    }
}

If you do have such a file, would you mind sharing the contents? Another reason why this error shows up is if there is a bug in the Q# code.

@LM726 another thing we noticed is that your path contains a special character: C:\Users\User\Documents\Q#\QH\start.py. I was not able to reproduce this on Mac but I wonder if this is perhaps an issue on Windows; it may be worth trying out renaming your folder to "QSharp" instead of "Q#".

First of all, I have changed Q# to QSharp in the path. Unfortunately, that does not appear to be the problem.
I have two files in my folder, this is what they look like at the moment:
Operation.qs:
namespace QuantumHello {
    open Microsoft.Quantum.Canon;
    open Microsoft.Quantum.Intrinsic;

    @EntryPoint
    operation SayHello() : Unit {
        Message("Hello quantum world!");
    }
}

start.py:
import qsharp
from QuantumHello import SayHello

SayHello.simulate()
#qsharp.reload()
#print(qsharp.get_available_operations())

When I execute the python file from the anaconda console, I get this error I mentioned previously:
(qsharp-env) C:\Users\Lenna>python C:\Users\Lenna\Documents\QSharp\QH\start.py
Traceback (most recent call last):
  File "C:\Users\User\Documents\QSharp\QH\start.py", line 2, in <module>
    from QuantumHello import SayHello
ModuleNotFoundError: No module named 'QuantumHello'

I tried removing @EntryPoint, but the result was the same.

First of all, I have changed Q# to QSharp in the path. Unfortunately, that does not appear to be the problem.
I have two files in my folder, this is what they look like at the moment:
Operation.qs:
namespace QuantumHello {
    open Microsoft.Quantum.Canon;
    open Microsoft.Quantum.Intrinsic;

    @EntryPoint
    operation SayHello() : Unit {
        Message("Hello quantum world!");
    }
}

One thing to note is that EntryPoint needs to have () following it:
namespace QuantumHello {
    open Microsoft.Quantum.Canon;
    open Microsoft.Quantum.Intrinsic;

    @EntryPoint()
    operation SayHello() : Unit {
        Message("Hello quantum world!");
    }
}

When I execute the python file from the anaconda console, I get this error I mentioned previously:
(qsharp-env) C:\Users\Lenna>python C:\Users\Lenna\Documents\QSharp\QH\start.py
Traceback (most recent call last):
  File "C:\Users\User\Documents\QSharp\QH\start.py", line 2, in <module>
    from QuantumHello import SayHello
ModuleNotFoundError: No module named 'QuantumHello'

That's what I would expect if there was an error compiling your Q# workspace; can you share the output from qsharp.reload? That should show what error is causing QuantumHello.SayHello to not be available.

@LM726 thanks for giving that a try. @cgranade  is right; EntryPoint() requires parentheses. However, I tried reproducing your error, and I got a different error; so it looks something might still be wrong with your environment or installation.
One thing you can run to make sure that the IQ# kernel installed correctly is to run:
import qsharp
qsharp.component_versions()

If you have the latest version installed, this should return:
{'iqsharp': LooseVersion ('0.15.2101125897'),
 'Jupyter Core': LooseVersion ('<IP_ADDRESS>'),
 '.NET Runtime': LooseVersion ('.NETCoreApp,Version=v3.1'),
 'qsharp': LooseVersion ('0.15.2101.125897')}

If any of those look off, that might be the issue.
Another thing to be aware of is that IQ# currently requires Python 3.7. To check your Python version, run: python --version in the command line.
To get you unblocked from coding in Q#, I would recommend one of the following:

Uninstall and re-install Q# from scratch. The best way to go would be to use conda. You can do this by following these steps:
a. Uninstall any non-conda IQ# installations from your machine by closing all your Jupyter notebooks and running dotnet tool uninstall Microsoft.Quantum.IQSharp. If this fails, that means no other IQ# version was installed and you can simply continue.
b. Create a new virtual environment using conda create -n qsharp python=3.7 jupyter
c. Install qsharp and IQ#: conda install -c quantum-engineering qsharp
d. Activate the conda environment: conda activate qsharp
e. Browse to the folder with your code and run jupyter notebook.

Use our pre-built Binder environment. Note that you won't be able to save your notebooks or files, but you can get started running Q# code right away! The link for the Binder instance is here: https://mybinder.org/v2/gh/Microsoft/Quantum/⭐binder

I hope this helps, let us know if you were able to make it work.

Thanks for giving the detailed instructions @cgranade @guenp .
I had python version 3.9, so I uninstalled that and installed Python 3.7.9. I then followed your instructions:

To get you unblocked from coding in Q#, I would recommend one of the following:
Uninstall and re-install Q# from scratch. The best way to go would be to use conda. You can do this by following these steps:
a. Uninstall any non-conda IQ# installations from your machine by closing all your Jupyter notebooks and running dotnet tool uninstall Microsoft.Quantum.IQSharp. If this fails, that means no other IQ# version was installed and you can simply continue.
b. Create a new virtual environment using conda create -n qsharp python=3.7 jupyter
c. Install qsharp and IQ#: conda install -c quantum-engineering qsharp
d. Activate the conda environment: conda activate qsharp
e. Browse to the folder with your code and run jupyter notebook.

Unfortunately, now I simply get this massive error message when trying to run import qsharp in a python script from conda:
(qsharp) C:\Users\User>py -3.7 -c "import qsharp"
IQ# is not installed.
Please follow the instructions at https://aka.ms/qdk-install/python.
Traceback (most recent call last):
  File "C:\Users\User\AppData\Local\Programs\Python\Python37\lib\site-packages\qsharp\clients\__init__.py", line 37, in _start_client
    client.start()
  File "C:\Users\User\AppData\Local\Programs\Python\Python37\lib\site-packages\qsharp\clients\iqsharp.py", line 83, in start
    self.kernel_manager.start_kernel(extra_arguments=["--user-agent", f"qsharp.py{user_agent_extra}"])
  File "C:\Users\User\AppData\Local\Programs\Python\Python37\lib\site-packages\jupyter_client\manager.py", line 309, in start_kernel
    kernel_cmd, kw = self.pre_start_kernel(**kw)
  File "C:\Users\User\AppData\Local\Programs\Python\Python37\lib\site-packages\jupyter_client\manager.py", line 264, in pre_start_kernel
    kernel_cmd = self.format_kernel_cmd(extra_arguments=extra_arguments)
  File "C:\Users\User\AppData\Local\Programs\Python\Python37\lib\site-packages\jupyter_client\manager.py", line 183, in format_kernel_cmd
    cmd = self.kernel_spec.argv + extra_arguments
  File "C:\Users\User\AppData\Local\Programs\Python\Python37\lib\site-packages\jupyter_client\manager.py", line 89, in kernel_spec
    self._kernel_spec = self.kernel_spec_manager.get_kernel_spec(self.kernel_name)
  File "C:\Users\User\AppData\Local\Programs\Python\Python37\lib\site-packages\jupyter_client\kernelspec.py", line 235, in get_kernel_spec
    raise NoSuchKernel(kernel_name)
jupyter_client.kernelspec.NoSuchKernel: No such kernel named iqsharp

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "C:\Users\User\AppData\Local\Programs\Python\Python37\lib\site-packages\qsharp\__init__.py", line 123, in <module>
    client = _start_client()
  File "C:\Users\User\AppData\Local\Programs\Python\Python37\lib\site-packages\qsharp\clients\__init__.py", line 42, in _start_client
    raise IQSharpNotInstalledError(message)
qsharp.clients.IQSharpNotInstalledError: IQ# is not installed.
Please follow the instructions at https://aka.ms/qdk-install/python.

I tried changing the name of the kernel to iqsharp instead of qsharp, because it said in the error message No such kernel named iqsharp, but that made no difference.
Unfortunately, I tried changing my python version first, so I can't give you the output of qsharp.reload or qsharp.component_versions(), as I deleted my previous installation.

Use our pre-built Binder environment. Note that you won't be able to save your notebooks or files, but you can get started running Q# code right away! The link for the Binder instance is here: https://mybinder.org/v2/gh/Microsoft/Quantum/⭐binder

Thank you for the tip, I will look at that.

@LM726, thanks for giving this a try. From your traceback, it looks like the command (qsharp) C:\Users\User>py -3.7 -c "import qsharp" is not picking up the correct Python installation. The python installation you're using is here: C:\Users\User\AppData\Local\Programs\Python\Python37\lib\site-packages. The error you're getting means that it is not using the Python binary in your conda environment, so it's not picking up the IQ# kernel installation correctly.
Would you mind trying this instead: python -c "import qsharp"?
To make sure you're using the correct Python binary, you can run where python, this should return something along the lines of C:\Users\User\Anaconda3\envs\qsharp\python.exe. It should not use C:\Users\User\AppData\Local\Programs\Python\Python37.

@guenp Yeah, sorry, I could have seen that. I didnt realize that the Q# environment had its own python binary. I did pip install qsharp in the environment and then executed python -c "import qsharp". However, the same error occurs, just the binaries are different:
(qsharp) C:\Users\User>python -c "import qsharp"
IQ# is not installed.
Please follow the instructions at https://aka.ms/qdk-install/python.
Traceback (most recent call last):
  File "C:\Users\User\anaconda3\envs\qsharp\lib\site-packages\qsharp\clients\__init__.py", line 37, in _start_client
    client.start()
  File "C:\Users\User\anaconda3\envs\qsharp\lib\site-packages\qsharp\clients\iqsharp.py", line 83, in start
    self.kernel_manager.start_kernel(extra_arguments=["--user-agent", f"qsharp.py{user_agent_extra}"])
  File "C:\Users\User\anaconda3\envs\qsharp\lib\site-packages\jupyter_client\manager.py", line 309, in start_kernel
    kernel_cmd, kw = self.pre_start_kernel(**kw)
  File "C:\Users\User\anaconda3\envs\qsharp\lib\site-packages\jupyter_client\manager.py", line 262, in pre_start_kernel
    kernel_cmd = self.format_kernel_cmd(extra_arguments=extra_arguments)
  File "C:\Users\User\anaconda3\envs\qsharp\lib\site-packages\jupyter_client\manager.py", line 181, in format_kernel_cmd
    cmd = self.kernel_spec.argv + extra_arguments
  File "C:\Users\User\anaconda3\envs\qsharp\lib\site-packages\jupyter_client\manager.py", line 87, in kernel_spec
    self._kernel_spec = self.kernel_spec_manager.get_kernel_spec(self.kernel_name)
  File "C:\Users\User\anaconda3\envs\qsharp\lib\site-packages\jupyter_client\kernelspec.py", line 235, in get_kernel_spec
    raise NoSuchKernel(kernel_name)
jupyter_client.kernelspec.NoSuchKernel: No such kernel named iqsharp

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "C:\Users\User\anaconda3\envs\qsharp\lib\site-packages\qsharp\__init__.py", line 123, in <module>
    client = _start_client()
  File "C:\Users\User\anaconda3\envs\qsharp\lib\site-packages\qsharp\clients\__init__.py", line 42, in _start_client
    raise IQSharpNotInstalledError(message)
qsharp.clients.IQSharpNotInstalledError: IQ# is not installed.
Please follow the instructions at https://aka.ms/qdk-install/python.

By the way, where python in conda returns this:
C:\Users\User\anaconda3\envs\qsharp\python.exe
C:\Users\User\AppData\Local\Programs\Python\Python37\python.exe
C:\Users\User\AppData\Local\Microsoft\WindowsApps\python.exe

Thanks for all the help!

@LM726 can you try conda install -c quantum-engineering qsharp instead of pip install qsharp? The former installs the IQ# kernel while the latter does not.

@guenp Thanks for the tip. I did that before, but now I did it again while the environment was already active, and I it seems to have worked.

c. Install qsharp and IQ#: conda install -c quantum-engineering qsharp
d. Activate the conda environment: conda activate qsharp

However, I am now facing the same problem (ModuleNotFoundError: No module named 'QuantumHello') as before, so I now tried the previous suggestions:
qsharp.reload():
{'text/plain': 'Reloading workspace.', 'application/json': '{"LastUpdated":"2021-02-15T08:55:37.884469+01:00","IsCompleted":false,"Description":"Reloading workspace","Subtask":null}'}
qsharp.get_available_operations():
[]
qsharp.component_versions():
{'iqsharp': LooseVersion ('0.13.20111004'), 'Jupyter Core': LooseVersion ('<IP_ADDRESS>'), '.NET Runtime': LooseVersion ('.NETCoreApp,Version=v3.1'), 'qsharp': LooseVersion ('0.13.2011.1004')}

@LM726 It looks like qsharp is could be hitting a compilation error before it finds the QuantumHello operation. Could you run qsharp.reload() again and capture the full output from it? That should show any compilation issues it's hitting.

You can get more information from logs by setting the environment variable IQSHARP_LOG_LEVEL to Debug (for example using conda conda env config vars set IQSHARP_LOG_LEVEL=Debug). Closing this for now, feel free to reach out if you have more questions

@LM726 I'm very sorry for the delay in response time. Could re-run qsharp.reload() with the log level set to debug and share the output? That ought to show any compilation issues it might be hitting. Let me know if you have any further questions!

Very sorry for the even longer response time. I didnt log on github for a while.
I have changed computers since and I dont need qsharp at the moment, so I wont try to reinstall it.
Nevertheless, thanks for all your help!


Add stylelint-config-prettier

Additions

Add stylelint-config-prettier to handle stylelint/prettier collisions.

Changes

Run Prettier against CSS/Less.
Move stylelint.config.cjs to .stylelintrc.cjs to match eslint config naming.
Spell out eslint-config-prettier in eslint config to make it clearer where that dependency is used.
Remove prettier/stylelint colliding function-parentheses-space-inside, max-empty-lines, indentation, media-feature-parentheses-space-inside, and selector-pseudo-class-parentheses-space-inside rules.

How to test this PR

PR checks should pass.
2 yarn lint should show no less file changes.
If curious, adding

"scripts": {
    "stylelint-check": "stylelint-config-prettier-check"
  }

To package.json and running yarn stylelint-check should show no collisions between prettier and stylelint.

Majority config changes --> https://github.com/cfpb/consumerfinance.gov/pull/7438/commits/7703e48758c4a6be8c2ed3227997cc570888ff1a
Linting changes (+ run Prettier on CSS/Less config change) -->
https://github.com/cfpb/consumerfinance.gov/pull/7438/commits/d6ce58957097ed10150bf53d6e8b0153e9b5b5a9


Reduce configuration files

Related to issue #19. Our plan includes:

Prepare base.yml, dataset/{dataset}.yml, feature/{feature}.yml, model/{model}.yml
Integrate them into one YAML files when running the code

I found that several (current) config files are wrong. Our new config files enable us to reproduce the experiments more easily...

[WIP]: training all of the models


Importing MarkerClusterGroup results in error

Receiving following error:
TypeError: (0, _reactLeaflet.withLeaflet) is not a function. (In '(0, _reactLeaflet.withLeaflet)(MarkerClusterGroup)', '(0, _reactLeaflet.withLeaflet)' is undefined)
in node_modules/react-leaflet-markercluster/dist/react-leaflet-markercluster.min.js:126
I'm using:
{
    "leaflet": "^1.5.1",
    "leaflet.markercluster": "^1.4.1",
    "prop-types": "^15.7.2",
    "react-leaflet": "^2.4.0",
    "react-leaflet-markercluster": "^2.0.0-rc3"
}

the v2.0.0 has been released...
Is this error present in the "stable" version?


Updated KeyVault's client-runtime version that fixes issue #6553.

@JimSuplizio Thanks a lot! Will make the appropriate changes.


Helm Client: Add support for the list releases subcommand

:tada: This issue has been resolved in version 0.12.0 :tada:
The release is available on:

GitHub release
npm package (@latest dist-tag)

Your semantic-release bot :package::rocket:


Android release apk build failed with exception: execution failed for task ":processDebugManifest"

Execution failed for task ':processDebugManifest'.

Manifest merger failed : Attribute activity#com.facebook.FacebookActivity@theme value=(@android:st
yle/Theme.Translucent.NoTitleBar) from AndroidManifest.xml:26:184-243
is also present at [com.facebook.android:facebook-android-sdk:4.16.1] AndroidManifest.xml:32
:13-63 value=(@style/com_facebook_activity_theme).
Suggestion: add 'tools:replace="android:theme"' to  element at AndroidManifest.xml
:26:9-246 to override.

I have tried to add tools:replace="android:theme" in AndroidManifest.xml but still facing this error.

This issue was moved to driftyco/ionic-cli#1509

Hello, thanks for using Ionic! Because this is an issue related to the Ionic CLI and not the Ionic framework I have moved this issue to the CLI repo.


[PMoF-93] delete the residual file of fsdax

Add a file delete operation in fsdax mode.
When fsdax mode is used,
an additional file deletion operation is needed to free up the occupied space.

Hi, @Eugene-Mark This part of the code logic is fine. The reason file deletion may fail is not caused by this code.


date = '0000-00-00' is shown as NULL in dbeaver

System information:

Operating system (distribution) and version: manjaro
DBeaver version: 6.3.3 ce
Additional extensions: none

Connection specification:

Database name and version
Driver name: mysql 5
Do you use tunnels or proxies (SSH, SOCKS, etc)? ssh tunnel

Describe the problem you're observing:
dbeaver shows '0000-00-00' date values as null. phpymadmin for example shows the values correctly.
This causes a lot of confusion when running

select * where date is not null

queries
Include any warning/errors/backtraces from the logs

hi @aardbol ,
unfortunately, I cannot reproduce an issue. Works ok for me against 6.3.5

could you check it against the recent version?

I will get back to you as soon as I can. Unfortunately, the 6.3.5 version isn't in the repos of Manjaro yet. Not is 6.3.4.

if issue is still actual for you against recent vesion - feel free to reopen the ticket


User Interface approach

Hi,
I would like to build a simple diagramming application where the bulk of the 2D drawing are done in canvas.
For the UI (I am looking to use buttons, dropdown menus, slider bars, check boxes and text/numeric fields), what libraries would work well with canvas ?
Cheers

Hi,
thanks for your interest in this project.
It would certainly be possible to implement a simple UI widget library on top of this module, but something like that doesn't exist yet. I only very recently released this project to the public. I don't think a lot of people use it right now, and I am not aware of any libraries built on top of it.

I could also imagine a project similar to this that uses WebSockets to communicate with HTML DOM elements in a browser, for example form input elements, but that would be a different project.


groupby problem when dataframe has only one column

>>> import pandas as pd
>>> import numpy as np
>>> df = pd.DataFrame(index=range(10),data=np.random.randint(0,3,10),columns=['y'])

Gives,
>>> df.y
0    2
1    0
2    2
3    1
4    0
5    0
6    0
7    1
8    2
9    1
Name: y, dtype: int32

>>> df.groupby('y').count()
Empty DataFrame
Columns: []
Index: [0, 1, 2]

But I'm trying to get the count of every item in 'y'. Something like,
>>> from collections import Counter
>>> Counter(df.y)
Counter({0: 4, 1: 3, 2: 3})

Am I doing something wrong here?
Thanks!

The index is 'eaten' by the groupby so you need to pick a column to count.
In [6]: df.groupby('y')['y'].count()
Out[6]:
y
0    1
1    5
2    4
Name: y, dtype: int64
``
you can also do this, treat as a series and groupby itself

In [11]: df['y'].groupby(df['y']).count()
Out[11]:
y
1    4
2    6
Name: y, dtype: int64

Or even better, you can just use value_counts():
In [22]: df['y'].value_counts(sort=False)
Out[22]:
0    3
1    5
2    2
Name: y, dtype: int64


Committed Files to SCM

Aug 16th Redirects jS
Flat format for Netlify

Harness Developer Pull Request
Thanks for helping us make the Developer Hub better. The PR will be looked at
by the maintainers.
What Type of PR is This?

[ ] Issue
[ ] Feature
[x] Maintenance/Chore

If tied to an Issue, list the Issue(s) here:

Issue(s)

House Keeping
Some items to keep track of. Screen shots of changes are optional but would help the maintainers review quicker.

[ ] Tested Locally
[ ] Optional Screen Shoot.

Added these files to SCM @wei-harness @rohanmaharjan100

Please check the Execution Link of the Pipeline for the Website Draft URL. This is located in the Preview Step and also is available in #hdh_alerts. E.g Website Draft URL: https://unique-id--harness-developer.netlify.app


I can't see my folder structure and files while opening a folder

Type: Bug
Dear sir,
I am not able to see my folder and file structure after opening it, like no folder and file is showing is explorer.
VS Code version: Code 1.91.1 (f1e16e1e6214d7c44d078b1f0607b2388f29d729, 2024-07-09T22:06:49.809Z)
OS version: Windows_NT x64 10.0.22631
Modes:

System Info

Item
Value

CPUs
Intel(R) Core(TM) i3-1005G1 CPU @ 1.20GHz (4 x 1190)

GPU Status
2d_canvas: enabledcanvas_oop_rasterization: enabled_ondirect_rendering_display_compositor: disabled_off_okgpu_compositing: enabledmultiple_raster_threads: enabled_onopengl: enabled_onrasterization: enabledraw_draw: disabled_off_okskia_graphite: disabled_offvideo_decode: enabledvideo_encode: enabledvulkan: disabled_offwebgl: enabledwebgl2: enabledwebgpu: enabled

Load (avg)
undefined

Memory (System)
11.75GB (5.34GB free)

Process Argv
D:\telegram course\Harkirat 2.0\week 1\offline-classes\level-1\01-String.js --crash-reporter-id 4c31c16a-3674-4000-a64b-bab0b7b3ea16

Screen Reader
no

VM
0%

Extensions (16)

Extension
Author (truncated)
Version

vscode-tailwindcss
bra
0.12.5

competitive-programming-helper
Div
2024.6.1719243911

es7-react-js-snippets
dsz
4.4.3

prettier-vscode
esb
10.4.0

code-runner
for
0.12.2

copilot
Git
1.213.0

copilot-chat
Git
0.17.1

next-js-ts-snippets
loc
2.0.3

python
ms-
2024.10.0

remote-wsl
ms-
0.88.2

cpptools
ms-
1.20.5

cpptools-extension-pack
ms-
1.3.0

material-icon-theme
PKi
5.4.2

LiveServer
rit
5.7.9

pdf
tom
1.2.2

JavaScriptSnippets
xab
1.8.0

(1 theme extensions excluded)

A/B Experiments
vsliv368:30146709
vspor879:30202332
vspor708:30202333
vspor363:30204092
vscoreces:30445986
vscod805:30301674
binariesv615:30325510
vsaa593:30376534
py29gd2263:31024239
c4g48928:30535728
azure-dev_surveyone:30548225
962ge761:30959799
pythongtdpath:30769146
welcomedialogc:30910334
pythonnoceb:30805159
asynctok:30898717
pythonregdiag2:30936856
pythonmypyd1:30879173
h48ei257:31000450
pythontbext0:30879054
accentitlementsc:30995553
dsvsc016:30899300
dsvsc017:30899301
dsvsc018:30899302
cppperfnew:31000557
dsvsc020:30976470
pythonait:31006305
chatpanelc:31048052
dsvsc021:30996838
bdiig495:31013172
pythoncenvpt:31062603
a69g1124:31058053
dvdeprecation:31068756
dwnewjupyter:31046869
impr_priority:31094925
refactorc:31093864

Please use the Start Extension Bisect command to investigate whether the problem is being caused by one of your extensions.

dear sir,
Thanks for responding me, I have tried the Extension Bisect but
unforunately my problem is not resolved yet.
The issue is when i try to open folder that contain some code file (any
folder) but I am not able to see that files or any folder in working
directory,
[image: image.png]
This folder contains some files but after opening this I am not able to see
any files in the working directory folder.
[image: image.png]
Waiting for your reply.
Thanks & Regards
Nitesh Meena.
On Sun, Jul 14, 2024 at 8:40 PM John Murray @.***>
wrote:

Please use the Start Extension Bisect command to investigate whether the
problem is being caused by one of your extensions.
—
Reply to this email directly, view it on GitHub
https://github.com/microsoft/vscode/issues/221664#issuecomment-2227381688,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AUIRBURHGK2UW7TZ7RDRNCTZMKIFJAVCNFSM6AAAAABK3GM6ZOVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDEMRXGM4DCNRYHA
.
You are receiving this because you authored the thread.Message ID:
@.***>

--
Nitesh

Images sent by email get dropped by GitHub. Please view the issue at the GH website and drag-drop them into a new comment.

/gifPlease

Thanks for reporting this issue! Unfortunately, it's hard for us to understand what issue you're seeing. Please help us out by providing a screen recording showing exactly what isn't working as expected. While we can work with most standard formats, .gif files are preferred as they are displayed inline on GitHub. You may find https://gifcap.dev helpful as a browser-based gif recording tool.
If the issue depends on keyboard input, you can help us by enabling screencast mode for the recording (Developer: Toggle Screencast Mode in the command palette). Lastly, please attach this file via the GitHub web interface as emailed responses will strip files out from the issue.
Happy coding!

F1 -> Reset View Locations

Dear sir,
I am not able to see my folder structure or file when I open a folder in Vs-code, I have recorded a video of same as instructed by you.
Please have a look into it.

after opening folder consisting files it is showing nothing.

@Niteshmeena9672 Did you try F1 -> Reset View Locations as suggested?

Thanks a lot.
Now it work well.


SELECT INTO bug has returned

This issue was previously addressed a couple of times.  In short, tables created using the SELECT INTO syntax are being limited by the result set size specified in the SQL editor.

Vertica – driver is the 8.1.1-7 jar.
From: Serge Rider<EMAIL_ADDRESS>Sent: Wednesday, September 5, 2018 5:22 PM
To: dbeaver/dbeaver<EMAIL_ADDRESS>Cc: Scot Ausborn<EMAIL_ADDRESS>Author<EMAIL_ADDRESS>Subject: Re: [dbeaver/dbeaver] SELECT INTO bug has returned (#4158)
What database and what driver do you use?
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHubhttps://github.com/dbeaver/dbeaver/issues/4158#issuecomment-418885329, or mute the threadhttps://github.com/notifications/unsubscribe-auth/ApBYQgReR3WD6DSvkBFNBVL6G0--vh2lks5uYEAWgaJpZM4Wbig3.

I think we lost this config when we migrated to the new Vertica extension/driver.
Thanks for the bug report


VSCode variable shadowing causes crash

Code Snippet
package main

main :: proc() {
	x : [3]int;
	for i := 0; i < len(x); i += 1 {
		x := x[i] // Crash
	}
}

Output
Connection to server got closed.
Reproduce
Seems to crash as soon as I type the i index.
Versions
OLS: commit 51595ac19fe8f7c13788199c8af8033eddbf2448 (newest as of writing this)
Odin: 0.13.1-92431c83
VSCode:
Version: 1.53.1 (system setup)
Commit: 5d424b828ada08e1eb9f95d6cb41120234ef57c7
Date: 2021-02-08T23:29:42.785Z
Electron: 11.2.1
Chrome: 87.0.4280.141
Node.js: 12.18.3
V8: <IP_ADDRESS>-electron.0
OS: Windows_NT x64 10.0.19041

This is now fixed.


Add send to pocket

It would be nice to be able to send articles to Pocket.  The api is very simple to add a url for an account.
http://getpocket.com/developer/docs/v3/add

Andreas' work has since been merged and is distributed with Newsbeuter; see contrib/getpocket.com directory.


Nat port with Qbitorrent

Details
Qbitorrent  + port redirect VPN
I'm trying to seeding a torrent from a private tracker for test my bandwidth and check if seeding work as expected.
So i start to download with my phone with mobile data for get out of my network. The upload and speed is slow.

And I didn't see my my phone as peer i see the GW is it normal ?
My cni is cilium 1.13.3 with native routing.

Also here

But this is not my smartphone, upload is really slow

Hi @samos667,
I experienced the same problem as you and did some investigation.
As I understood, seeing the Gateway's IP address instead of the incoming peer's public IP is the expected behavior when using Masquerading as outbound NAT, which is how the gateway is configured.
However, I also had the feeling that the performance/connectibility was limited, so I looked for ways around this.
One solution is to use SNAT instead of Masquerading. SNAT requires you to configure a static outbound gateway IP, which is probably the reason why Masquerading is currently used.
I guess this can be set to the "internal" VPN IP (e.g. the Address value of a Wireguard config), which should be static depending on the VPN provider.
I added an option to configure an SNAT_IP and thus use SNAT instead of Masquerading in this PR: #41
With this configuration, I have the impression that the performance is better, although I cannot explain why that is the case.


Add option to download additional sounds languages

Closes #117

@TECH7Fox this is a completely different take than #155.
While we could probably reduce the add-on size by not even bundling the core English sounds as suggested by @nanosonde, this is a different thing and could be implemented later.

Since the add-on now has access to /media, users can customize their Asterisk configuration files to point to whatever music they have stored in /media, like as mentioned by @nanosonde.

How will it handle moh?

It won't, moh will still be included by default in the image. At least ATM.


Keep links within the zebra book whenever possible

Motivation

There's a number of links in the README and the zebra book that refer back to files on github.com instead of the book itself. These should ideally remain in the zebra book.
Solution

Replace links out to github.com with their zebra.zfnd.org equivalents
Review

Reviewer Checklist

[ ] Will the PR name make sense to users?

[ ] Does it need extra CHANGELOG info? (new features, breaking changes, large changes)

[ ] Are the PR labels correct?
[ ] Does the code do what the ticket and PR says?

[ ] Does it change concurrent code, unsafe code, or consensus rules?

[ ] How do you know it works? Does it have tests?

Follow Up Work

This seems like a low risk doc-only change that might be nice to have for new users after the stable release.

@mergifyio refresh


Make Windows builds have the ".exe" extension

As mentioned in this comment, the Windows builds do not have the ".exe" extension.
While this was an easy thing to guess for myself and @IslandFun73, it would not necessarily be easy for others.

Thanks for the catch.


I am looking for a way to set the custom route in blazor, please help

For example like a blog post, the URL will be goes something like this
example.com/1-testing.html
1 IS ID and 'testing' is a slug. I check the issues in this repos but didn't find the code that can help me to do this.
Is current version let me do this.  if yes, how I can try it.
thanks

Sure.. see here: http://learn-blazor.com/pages/router/


Recover from corrupted Metadada caused by #13380

Summary of the changes / Why this improves CrateDB
Checklist

[ ] Added an entry in CHANGES.txt for user facing changes
[ ] Updated documentation & sql_features table for user facing changes
[ ] Touched code is covered by tests
[ ] CLA is signed
[ ] This does not contain breaking changes, or if it does:

It is released within a major release
It is recorded in CHANGES.txt
It was marked as deprecated in an earlier release if possible
You've thought about the consequences and other components are adapted
(E.g. AdminUI)

Currently, it is still a draft but it should have most of what is needed. The tests may seem verbose as it tries to show how my fixes affect the tables.

Hello @seut , Could you have a quick look at high level?

This list is WIP, will expand on it.
alter cluster swap table "m1"."t1" to "m1.s1"; // where both t1 and s1 are partitioned
// s1 is fully but t1 is partially recovered.

alter cluster swap table "m3.t3" to "m3.s3"; // where both t3 and s3 are partitioned
// both tables are partially recovered.

alter cluster swap table "m6.t6" to "m6"."s6"; // where t6 is partitioned and s6 is not partitioned
// t6 is fully but s6 is partially recovered.

alter cluster swap table "m7.t7" to "m7.s7"; // where t7 is partitioned and s7 is not partitioned
// t7 is fully but s7 is partially recovered.

Other variations are either duplicates of this list or fully recovered.

Hello @seut, could you have another rough look? I have tried to address things we discussed on Thursday.
I recently came across new scenarios have not considered yet, which I am working on right now. Thank you.

retest this please
unrelated : testTransientErrorsDuringRecoveryAreRetried
java.lang.AssertionError: timed out waiting for green state
	at __randomizedtesting.SeedInfo.seed([B4E7891983BBDC7F:DD0D654645BD34EB]:0)
	at org.junit.Assert.fail(Assert.java:89)
	at org.elasticsearch.test.IntegTestCase.ensureColor(IntegTestCase.java:735)
	at org.elasticsearch.test.IntegTestCase.ensureGreen(IntegTestCase.java:689)
	at org.elasticsearch.test.IntegTestCase.ensureGreen(IntegTestCase.java:678)
	at org.elasticsearch.indices.recovery.IndexRecoveryIT.testTransientErrorsDuringRecoveryAreRetried(IndexRecoveryIT.java:815)
	at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:104)
	at java.base/java.lang.reflect.Method.invoke(Method.java:578)
	at com.carrotsearch.randomizedtesting.RandomizedRunner.invoke(RandomizedRunner.java:1758)
	at com.carrotsearch.randomizedtesting.RandomizedRunner$8.evaluate(RandomizedRunner.java:946)
	at com.carrotsearch.randomizedtesting.RandomizedRunner$9.evaluate(RandomizedRunner.java:982)
	at com.carrotsearch.randomizedtesting.RandomizedRunner$10.evaluate(RandomizedRunner.java:996)
	at org.junit.internal.runners.statements.FailOnTimeout$CallableStatement.call(FailOnTimeout.java:299)
	at org.junit.internal.runners.statements.FailOnTimeout$CallableStatement.call(FailOnTimeout.java:293)
	at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:317)
	at java.base/java.lang.Thread.run(Thread.java:1589)


Fix settlement handling and add Message.SendSettled

Message.SendSettled allows sending messages settled when LinkSenderSettle is ModeMixed.

Fix for issues brought up in https://github.com/Azure/azure-event-hubs-go/pull/133

@devigned Would you like to test/review this?

@gavinfish this is a good one to practice how to test an early version. Would you like to or would you like me to test it?

@devigned I will try it out later. Any instructions to test an early version?

Just update the go.mod reference to the branch and run the tests. It should be pretty simple.
Check out the send settlement issue / pr test command and output. That describes how to test and what to look for at the protocol level.

@vcabbage do you plan on supporting mixed mode senders?
I think if you were to make settled settable on a message and in mixed mode look to settled when deciding to wait for disposition, it would work. What do you think or did I miss something in the PR?

@vcabbage did you change your mind about Message.SendSettled?

@devigned Can you clarify? Message.SendSettled should be implemented by this PR.

Sorry... I think I need more coffee. I was looking for a func, not a field.
Don't mind me. Please proceed :).


Parse %% repetition

A* %% B => (A+ %% B)?
A+ %% B =>  A+ % B B?

This means that %% is a separated list with optional trailing separator, but no lone separator.

Closing in favor of https://github.com/rust-lang-nursery/gll/pull/2 for now.

Still relevant concerns from the nursery PR:
https://github.com/rust-lang-nursery/gll/pull/2#discussion_r264798783 (change Rule<Pat> representation of *Trailing variants)
https://github.com/rust-lang-nursery/gll/pull/2#discussion_r263947322 (duplication refactor potential)

We still panic during proc-macro compilation of the testcases, still no real idea why and I lack the knowledge/tools required to trace it any better than dbg! debugging

@CAD97 you can take one of the testcases and add a tests/foo.rs file with:
extern crate gll;

#[test]
fn foo() {
    r#"
// ... testcase ...
    "#
        .to_string()
        .parse::<gll::scannerless::Grammar>()
        .unwrap()
        .generate_rust();
}

That should let you debug a panic deep in there.

That was a silly thing to track down: the issue is that it only repros when building as a procedural macro since on encountering %% the current proc_macro emits [Punct { spacing: Alone, char: '%' }, Punct { spacing: Alone, char: '%' }] whereas proc-macro2's polyfill for runtime does the proper behavior we wanted here and emits [Punct { spacing: Joint, char: '%' }, Punct { spacing: Alone, char: '%' }].
So we just accept Trailing:{"%" "%"} for now and hope for a Trailing:"%%" bugfix in the future. (Theoretically we can use the latter as long as we're running on top of anything other than the real proc_macro.)

Rebased to include the quasiquoting refactor. Looking at the dedupe refactor now.

Simplifying refactor completed. @Centril, @eddyb, does this resolve https://github.com/rust-lang-nursery/gll/pull/2#discussion_r263947322, https://github.com/rust-lang-nursery/gll/pull/2#discussion_r264798783

Wait, my description (does not allow a lone trailing separator) does not match my explanation (A+ %% B =>  A+ % B B?). Note to self: add a test for this 😅
I think the "pattern" is accurate to the implementation. I also think we decided that it shouldn't support a lone separator. I'll need to fix that.

I've managed to confuse myself further. I believe the failing test is correctly failing (ToShort(1:1-1:1) when matching b against "a"* %% "b"), but I don't think the code supports that? As the applicable translation is
            (Rule::RepeatMany(elem, sep), rules) => {
                // HACK(eddyb) remove extra variables post-NLL
                let rule = Rc::new(Rule::RepeatMore(elem.clone(), sep.clone()));
                let cont = opt(rule.generate_parse(rules)).apply(cont);
                cont
            }

which turns A * %% B into {A + %% B}?. And that turns into {{A + % B} {B}?}? which oh wait right that requires an A to be the first thing and so it works as desired.
 I want to make sure it continues to behave the same way. How should we go about testing that this does not parse?

Addressed requested changes.

the current proc_macro emits [Punct { spacing: Alone, char: '%' }, Punct { spacing: Alone, char: '%' }] whereas proc-macro2's polyfill for runtime does the proper behavior we wanted here

It's more complicated than that. And it's our fault. Or, well, not complicated:
https://github.com/rust-lang/gll/blob/64872b1be019576dbb19b98acb5596299959217e/macros/src/lib.rs#L10-L12

Unaddressed requested changes due to an upstream change to the API. I'm not sure where best to handle the negative testcase now (other than it definitely should be there!).

Now updated onto master with the Rc and Errors update. r? @eddyb

Pushing in somewhat-broken form to make sure GitHub tracks the rebase/force-push because I'm going to squish everything after because history doesn't make sense anymore.

This should be complete now. With the other changes upstream in the meantime (mainly the extraction of grammer), the improvements are fairly obvious alongside https://github.com/lykenware/grammer/pull/1.


Fixed issue #271

Fix for issue #271 so that identityAddress can be accessed in the userData object as part of Hacktoberfest

 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.

Its not letting me sign the CLA?

@larrysalibra should be good to merge now

Looks like you are good on the CLA! The bot just needed a good kick.

This was resolved by @bitsphr in https://github.com/blockstack/blockstack.js/pull/391#issuecomment-378228337
Thanks @TheSamSmith for getting the ball rolling on this!


[BUG] Wrong work on Velocity

Type /rj bugreport and paste here the result.
This team does not exist on Velocity
Explain your issue.
So. I put the plugin on velocity and it should show a message on login every time the player goes through the proxy (velocity), but for me it turns out that it shows a message every time they go to a new server (without going through the proxy). In fact, this is the same if I put the plugin on each server, instead of one velocity
Are there any errors in the console? Use: link.rocketplugins.space/paste

You can set that string to empty to not send it


OpenID-provider without userinfo_endpoint

Hello!
We are working with a new provider which do not provide the userinfo_endpoint, so it is set to nil via discovery as far as I can understand.
It does fail in openid_connect (1.4.2) lib/openid_connect/access_token.rb with OpenIDConnect::HttpError Unknown HttpError.
As far as I have been able to understand it is only RECOMMENDED in the discovery definition https://openid.net/specs/openid-connect-discovery-1_0.html#ProviderMetadata.
We are using openid_connect through https://github.com/omniauth/omniauth_openid_connect but I have not been able to find a way to disable the use of the userinfo_endpoint from there.
Versions:

openid_connect 1.4.2
omniauth_openid_connect 0.6.0

I don't think it's related to this gem.
In this gem, userinfo_endpoint is optional.


sea-orm-cli generates invalid code when table name is a Rust keyword

Description
I have a database with a table named type. When I run sea-orm-cli it generates syntactically invalid code.

mod type; should be mod r#type;
use crate::type::Entity should be use crate::r#type::Entity

Steps to Reproduce

create a database with a table named type (probably any rust keyword gives the same resull)
cargo new bug ; cd bug
sea-orm-cli generate entity -u mysql://user:pw@localhost/db -o entity/src

Expected Behavior
Generated code should be valid.
Actual Behavior
Generated code does not compile.
error: expected identifier, found keyword `type`
  --> /.../entity/src/mod.rs:36:9
   |
36 | pub mod type ;
   |         ^^^^ expected identifier, found keyword
   |
help: escape `type` to use it as an identifier
   |
36 | pub mod r#type ;
   |         ++

error: expected identifier, found keyword `type`
  --> /.../entity/src/prelude.rs:34:18
   |
34 | pub use super :: type :: Entity as Type ;
   |                  ^^^^ expected identifier, found keyword
   |
help: escape `type` to use it as an identifier
   |
34 | pub use super :: r#type :: Entity as Type ;
   |                  ++

Reproduces How Often
Always
Versions
├── sea-orm v0.9.2
│   ├── sea-orm-macros v0.9.2 (proc-macro)
│   ├── sea-query v0.26.3
│   │   ├── sea-query-derive v0.2.0 (proc-macro)
│   │   ├── sea-query-driver v0.2.2 (proc-macro)
│   ├── sea-strum v0.23.0
│   │   └── sea-strum_macros v0.23.0 (proc-macro)
│   ├── sea-orm v0.9.2 (*)

Additional Information
It seems like code generated by DeriveRelation macro also has this issue.

Hey @andy128k, thanks for the report! Please check https://github.com/SeaQL/sea-orm/pull/1052#pullrequestreview-1113134896


Auto-add contributor info to metadata

Currently in the metadata and the docs we only attribute the "main" authors of the datasets, not people who have made smaller contributions. We should add some git-driven mechanism to add this info automatically.
The info could probably be extracted from git by asking about committer's names. Not sure if we should do it ourselves -- is there a GitHub API for retrieving contributors? This would speed this up massively.
Apply this to:

Profiles (on a per-file basis)
Tasks (per-file)
Categories (???)
Datasets (per-repo basis)
Schema (per-file basis)
Main metadata (not sure how, but it should be generous)

I'm wondering just how realistic this is, as there so many corner cases where people would want to manage this manually...
Maybe a better approach would be keep it manual, but also make it a bit less of a hassle to manage. Maybe make a contributor library in the schema repo, like the one we have for SHACL rules. Then at least adding the contributors would be easier for familiar faces.
There should definitely be some documentation instructing maintainers on how to do this... Adding the contributor to the metadata should be a standard part of any PR.


Using shadow! creates an undesired runtime dependency on libgit2

It appears that when one includes shadow-rs in the [dependencies] section, it causes the generated executable to link against libgit2 (as well as const_format, is_debug, time and tzdb), even though it's not needed. This is undesirable because of executable size bloat, as well as portability (when libgit2 is dynamically linked, as is the default).
Consider splitting project into two crates, one for the build.rs facilities, and the other for the shadow! macro. Workaround is to not use the macro and rather insert the boilerplate manually:
pub mod build {
    include!(concat!(env!("OUT_DIR"), "/shadow.rs"));
}

Actually, the workaround above doesn't work
236 | pub const VERSION:&str = shadow_rs::formatcp!(r#"
    |                          ^^^^^^^^^ use of undeclared crate or module `shadow_rs`

Can the above description provide the complete configuration?

Actually, the workaround above doesn't work实际上，上面的解决方法并不起作用
236 | pub const VERSION:&str = shadow_rs::formatcp!(r#"
    |                          ^^^^^^^^^ use of undeclared crate or module `shadow_rs`

What is the reason for this error? I was not able to reproduce this issue.
@metasim

You get that error if you remove shadow-rs from your [dependencies] section (so as to eliminate the dependency on libgit2. I thought technically you could get away with that because I assumed the generated shadow.rsjust contained string constants, but missed the use ofshadow_rs::formatcp`.

Firstly, the git2 feature is optional. If you want to disable libgit2, you can use the following configuration:
...
[dependencies]
shadow-rs = { version = "{latest}", default-feature = false, features = ["tzdb"] }

[build-dependencies]
shadow-rs = { version = "{latest}", default-feature = false, features = ["tzdb"] }

Secondly, even if the project is split into two crates, the crates depended on via build-dependencies and dependencies will still be managed by the same Cargo.lock file. In reality, this does not reduce the number of crate dependencies.

@metasim Based on the two points I answered above, can it solve your problem?

@baoyachi

@metasim Based on the two points I answered above, can it solve your problem?

No. I'm not worried about crate dependencies. It's runtime dependencies on a shared library that the runtime functionality of my application doesn't need. As currently architected, shadow-rs is forcing applications to link in libgit2 even when it's not needed at runtime. For example (on macOS):
$ cd shadow-rs
$ cargo build --examples
...
$ otool -L target/debug/examples/builtin_fn
target/debug/examples/builtin_fn:
	/System/Library/Frameworks/CoreFoundation.framework/Versions/A/CoreFoundation (compatibility version 150.0.0, current version 2503.1.0)
	/opt/homebrew/opt/libgit2/lib/libgit2.1.8.dylib (compatibility version 1.8.0, current version 1.8.1)
	/usr/lib/libz.1.dylib (compatibility version 1.0.0, current version 1.2.12)
	/usr/lib/libiconv.2.dylib (compatibility version 7.0.0, current version 7.0.0)
	/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 1345.120.2)

I should be able to avail myself of the git functionality at compile time, but not depend on libgit2 at runtime.
I've actually switched to a different solution, so you can close this if you're not interested in pursuing it further.

@metasim
Thank you for your patient explanation. Feel free to reply if you have any questions.
I'm temporarily closing it now.


Yes I'd like Open Sans :)

Body text: Open Sans Light 300, #33333
Bold text and Links: Open Sans Semibold 600
Plenty of line spacing.

@jenmstrick I'm not sure Open Sans Light is readable for all users.  Folks without young eyes might have trouble.  Check out the intranet demo.
Bold links: b1300c84d4c2148f8b64e53f54749b89902bc790
Body text: 66a4911d4e69098a7b69446468d299b10ed9a01a
Line spacing is determined by vertical rhythm dictated by typebase.

@jenmstrick bumping this issue.  Do you think open sans light is the best choice over open sans regular?

Let's make it regular and see. Definitely needs more line spacing for body text, similar to a 1.5 line space in Word.
Decrease font size for all headers. H1 is 4.242rem, so let's try 3. Maybe fonts is something we can sit down and finesse looking at the same screen.

Swapped Open Sans light for regular in #27

Closing.  If we need to revisit typography we can, but this issue is covering too many things at once, many of which have been addressed.


index() method for Entry and VacantEntry plus test coverage for Entry API

I implemented the index() method for VacantEntry that just returns self.map.len() and for Entry.
I also added a test for some of the functions provided by the Entry API

Looks great, thanks a lot!


DO_NOT_MERGE add invalidx to authorizationdao builder

Why not to merge?

Why not to merge?

haven't tested it very well yet, and need to fix failing tests on nanopay side

As discussed in person, we're going to do the following instead:

Make InvalidX extend ProxyX
In Boot.java when initializing the services, set the context of ContextAware DAOs to InvalidX which delegates to the system context
Modify InvalidX to log a warning rather than throw an error


Include primitive types in forc-doc generated docs

forc-doc generates a static documentation website from sway code (specifically, from the sway compiler output).
Sway primitives are, however, written in Rust. We need a way for forc-doc to generate docs for the primitive types and include them as a submodule in the sway-lib-std docs. Some possible solutions:
rust-doc
Maybe we can use rust doc just for the std library for those files and splice them into the forc doc result somehow. rust-doc wouldn’t show usages or trait implementations though, since those are written in sway.
Generate primitive definitions in sway
Maybe there’s a way to generate sway code from the primitive type definitions in rust. If we could generate valid sway code and include it in the lib-std package, forc-doc would generate docs for it.
Custom plugin for generating primitive docs
We could write a custom plugin like forc-doc-primitives that generates docs for the primitives.
Open to other ideas/suggestions!

This will be mostly solved by generating docs for the primitive type impls: https://github.com/FuelLabs/sway/issues/5957
Closing this as a duplicate.


Add Discord Landing Page

I've made a Discord Landing Page clone using CSS and some Bootstrap.

@irshadmd can you please review and merge it as hacktoberfest-accepted

cool, Please create a demo folder inside your project and add a working demo of your project named demo.gif

done. I've added the demo.gif inside demo folder.


Compatibility issue: croptopia and Astromine

Compatibility issue:
Croptopia-1.0.5-1.16.X-FABRIC.jar and astromine-1.11.4+fabric-1.16.3.jar
Creative menu not displaying vanilla blocks and items
This issue does not exist when only astromine is installed, and regardless of other mods installed

That's because You are using outdated Astromine...

That's because you are using an outdated Astromine. Wait what? Where did 1.12.0 version go?

If you want a temporary fix just download newer versions of cardinal components - base, block, chunk, entity, item, level, util, world.

Or this - https://easyupload.io/jq47ej

Yes, I fixed it by downloading Roughly Enough Items. I figured the developers would find this information helpful anyways.

This should be closed.

This should be closed.


Improve Authorizer implementation

The Authorizer now extends and interface, an abstract class, and a variety of new methods to check permissions against roles and resources.
Previously, the Authorizer provided a limited interface for interacting with the ACL and evaluating permissions against roles (one issue being the lack of support for multiple roles).
Old API

rolesAllowed() — Deprecated in favour of anyRolesGrantedAll()
userAllowed() — Deprecated in favour of anyRolesGrantedAll() (via isUserGranted())
resource renamed to defaultResource

Internally, the old permission checking methods now use the new methods (which fixes support for multiple roles) but preserves the default behavior of allowing access to everything.
New API

isRoleGrantedAll() — Check if access is granted to the role, and the resource, for all permissions.

allRolesGrantedAll() — Check if access is granted to all roles, and the resource, for all permissions.
anyRolesGrantedAll() — Check if access is granted to any one of the roles, and the resource, for all permissions.
isUserGranted() — Check if access is granted to the user's role(s), and the resource, for permissions.

isRoleGrantedAny() — Check if access is granted to the role, and the resource, for any one of the permissions.

allRolesGrantedAny() — Check if access is granted to all roles, and the resource, for any one of the permissions.
anyRolesGrantedAny() — Check if access is granted to any one of the roles, and the resource, for any one of the permissions.

isAllowed() — Check if the role has access to the resource and privilege.
hasRole() — Check if the role is registered.
inheritsRole() — Check if the role inherits from another role.
hasResource() — Check if the resource is registered.
inheritsResource() — Check if the resource inherits from another resource.

Example
Example #1
Using the new API with the default "charcoal" resource.
if (!$authorizer->isUserGranted($user, Authorizer::DEFAULT_RESOURCE, 'edit')) {
    return $response->withStatus(403);
}

Example #2
public function isAuthorizedToManageOthers()
{
    $obj        = $this->obj();
    $objType    = $obj->objType();
    $authorizer = $this->authorizer();

    if ($authorizer->hasResource($objType)) {
        $user = $this->authenticator()->getUser();
        if ($user) {
            return $authorizer->isUserGranted($user, $objType, 'object/manage/others');
        }
    }

    return false;
}

protected function prepareAuthorship(ModelInterface $obj)
{
    $old    = $this->prevObj;
    $userId = $this->authenticator()->getUserId();

    if ($old->hasAuthor($userId) && !$obj->hasAuthor($userId)) {
        // Redirect if current user is no longer an author
        if (!$this->isAuthorizedToManageOthers()) {
            $url = $this->getObjectBrowseUrl();
            $url = $obj->renderTemplate($url);
            $this->setSuccessUrl($url);
        }
    }
}

This feature request was originally developed for USports which required support for tiered roles as well as multiple roles as well as privileges such as constraining editing of articles and allowing certain users to be able to edit articles of other users.


Request: Other LLMs

I can take a crack at a PR here even though I'm not nec a pythonista - it owuld be nice to sub in other LLM providers or locallly running LLMs

Also being able to use Claude would be nice, Claude Sonnet is 20 times cheaper


Feat rollup counts

edit: I'll run black formatting on this code before merging, but didn't want to screw up the diff before then!

Adds aggregate_counts argument to validate_gcs_bucket. When this is set it rolls up counts of errors per file, rather than upload raw results files.
implements a function called validate_gcs_bucket_many, which uses a path to a CSV to validate many feeds.

Uploads a file with 1 row per feed, which indicates whether validation was successful
e.g. validation can fail if gtfs schedule does not have agency.txt
This allows the pipeline to easily wire up this library to validate all (or a specified set) of feeds daily.

fixes an issue where the validator could not parse the datetime info we put at the end of filenames. Note that the fix was simply to put "Z" at the end.

As a side note, I noticed that the bulk of validation results files are long string descriptions of the rules (repeated per file x 4,000 timepoints per feed per day..). I cobbled together a quick ERD to describe how this info could be pulled out into dimensions, and everything can be wired together here: https://github.com/cal-itp/data-infra/issues/787#issuecomment-987305649
I'll plan to walk through the ERD and some of the data design decisions tomorrow in our meeting with @mjumbewu and @holly-g , but wanted to get this PR up.
Next step would be to implement https://github.com/cal-itp/data-infra/issues/788 in data-infra to produce the parameters csv, and integrate into the validation task!

@evansiroky thanks for your review! I can go through and make the changes--the two I wanted to be sure to double check are here (but am def on board w/ making the changes):

error_id: https://github.com/cal-itp/gtfs-rt-validator-api/pull/4#discussion_r770232829
import gcsfs: https://github.com/cal-itp/gtfs-rt-validator-api/pull/4#discussion_r769284895


wrong gcm computation when iv length is big enough in main branch

Summary
In the GCM cipher mode, it may be wrong in the computation of Y0 when the bit length of iv is not smaller than 232.
System information
Mbed TLS version (number or commit id):
Operating system and version:
Configuration (if not default, please attach mbedtls_config.h):
Compiler and options (if you used a pre-built binary, please indicate how you obtained it):
Additional environment information:
Expected behavior
Xi = (Xm+n) ^ (len(A) || len(C)) . H
Since the bit length of C(here is iv) can be upper to 264. So, it may be something like
PUT_UINT32_BE( iv_len * 8, work_buf, 8 )
Actual behavior
PUT_UINT32_BE( iv_len * 8, work_buf, 12 )
Steps to reproduce
Additional information

Hi!
If you would like to submit a PR for this fix, then we would be more than happy to review it.

Please see https://github.com/ARMmbed/mbedtls/pull/4950 and have a review.
Thanks.


[FIX] manifest_hash in _loadManifest should be manifestHash

This fixes 'manifest_hash is not defined' error when running contracts.

LGTM :+1:


Here:
$ go run ./cmd/tfimport --input_dir ~/development/hcls/terraform-importer-testing/tfengine-foundation/org/project.mpetkov-hcls-testing-monitor/network --dry_run
2020/05/11 11:49:33 Dry run mode, logging commands but not executing any imports.
2020/05/11 11:49:33 Running: [terraform init]
...
<init snipped>
...
2020/05/11 11:49:33 Running: [terraform plan -out /tmp/014533828]
...
<plan snipped>
...
2020/05/11 11:49:35 Running: [terraform show -json /tmp/014533828]
2020/05/11 11:49:36 Found importable resource: "module.network.module.subnets.google_compute_subnetwork.subnetwork[\"us-central1/forseti-subnet\"]"
2020/05/11 11:49:36 /usr/local/bin/terraform import module.network.module.subnets.google_compute_subnetwork.subnetwork["us-central1/forseti-subnet"] projects/mpetkov-hcls-testing-monitor/regions/us-central1/subnetworks/forseti-subnet
2020/05/11 11:49:36 Found importable resource: "module.network.module.vpc.google_compute_network.network"
2020/05/11 11:49:36 /usr/local/bin/terraform import module.network.module.vpc.google_compute_network.network projects/mpetkov-hcls-testing-monitor/global/networks/forseti-vpc
2020/05/11 11:49:36 Found importable resource: "module.router.google_compute_router.router"
2020/05/11 11:49:36 /usr/local/bin/terraform import module.router.google_compute_router.router projects/mpetkov-hcls-testing-monitor/regions/us-central1/routers/forseti-router
2020/05/11 11:49:36 Found importable resource: "module.router.google_compute_router_nat.nats[\"forseti-nat\"]"
2020/05/11 11:49:36 /usr/local/bin/terraform import module.router.google_compute_router_nat.nats["forseti-nat"] projects/mpetkov-hcls-testing-monitor/regions/us-central1/routers/forseti-router/forseti-nat
2020/05/11 11:49:36 No resources imported.

Why do we need to print found importable resource, can't we just print the command always? Just in normal secnario it's getting executed and dry_run it isn't.
Given other log messages will clutter it, I wonder if we should have different 'modes' e.g. 'exec' which will execute the commands, 'script' (with corresponding 'script_output_path') which will write a bash script with the import commands, etc.

Why do we need to print found importable resource?
I guess it's not necessary. I had it there because it could say Found importable resource...Resource does not exist or Import not supported by provider. So "importable" doesn't necessarily mean it'll be imported.

Can't we just print the command always? Just in normal scenario it's getting executed and dry_run it isn't.
That is actually how it is right now. The default runner always logs Running <command> before executing it.

Given other log messages will clutter it, I wonder if we should have different 'modes' e.g. 'exec' which will execute the commands, 'script' (with corresponding 'script_output_path') which will write a bash script with the import commands, etc.
To me that feels like just a bit too much for this kind of functionality. I'll try to rearrange the code to output things more meaningfully in dry-run mode..

New output at the latest commit:
2020/05/11 13:40:10 Import commands:
cd /usr/local/google/home/mpetkov/development/hcls/terraform-importer-testing/tfengine-foundation/org/project.mpetkov-hcls-testing-monitor/network
/usr/local/bin/terraform import module.network.module.subnets.google_compute_subnetwork.subnetwork["us-central1/forseti-subnet"] "projects/mpetkov-hcls-testing-monitor/regions/us-central1/subnetworks/forseti-subnet"
/usr/local/bin/terraform import module.network.module.vpc.google_compute_network.network "projects/mpetkov-hcls-testing-monitor/global/networks/forseti-vpc"
/usr/local/bin/terraform import module.router.google_compute_router.router "projects/mpetkov-hcls-testing-monitor/regions/us-central1/routers/forseti-router"
/usr/local/bin/terraform import module.router.google_compute_router_nat.nats["forseti-nat"] "projects/mpetkov-hcls-testing-monitor/regions/us-central1/routers/forseti-router/forseti-nat"


Cql4bonnie qdm5 3 937 facility

JIRA Test: https://jira.mitre.org/browse/BONNIE-968
Related PRs:

https://github.com/projectcypress/health-data-standards/pull/527
https://github.com/projecttacoma/cql_qdm_patientapi/pull/64
https://github.com/projecttacoma/bonnie/pull/814

It looks like one of the tests now fails. Please review and modify the test if necessary.

  All tests pass running locally with updated Gemfile:
75 runs, 905 assertions, 0 failures, 0 errors, 0 skips


Would like to insert PBI Title into title of task

I'd like to specify a token within the task template title where this would insert the title of the associated PBI.
For example, my template title may be "Code Changes for {Title}" and then when this tool adds to the PBI titled "Implement Fix to Login Page" the final task title is "Code Changes for Implement Fix to Login Page"

I might be able to do something about this in my own branch. What's a PBI? And could you ellaborate?

Product Backlog Item - We use the Scrum template in VSTS and I would like to generate tasks under the PBI (Story) that would simply concat the PBI title onto the end of the template title. "Template Title" + "PBI Title"

maybe "{ParentTitle}" is a better token

I would also like to see this functionality

Hi @robk410 , I know that @omireault has done some work regarding that functionality. I'm going to review it.

I haven't done anything with that specifically. I was working on it today, but didn't like my approach.

Wiki - Copy fields value from parent

Thank you!!


Feature: Device Sources can modify Device Name

Let the user select in the web interface if a device source can affect the master Device name. Some tally source types like TSL or OBS have names. If you change the name in the originating source, if the option is selected, it will change the name for the associated Device.
Radio option in the event of multiple device source entries (arbitration).

Added in #173

merged in #173


Expose a method to update connection uri in case of passing token parameter

URI is init each time Websocket instance is create, and reuse it for every reconnect attempt. That is sometime a problem.
If I pass a jwt token to the uri then if the token is expired I always have to call the method close and create new WebSocket instance, update the uri with new token.
It is convenient if the uri value can be expose and modify outside.

Hi @Danny-Hoang 👋
Thanks for opening an issue! This seems to be a duplicate of #31 so closing in favor of the other issue 👍


[SPARK-25328][PYTHON] Add an example for having two columns as the grouping key in group aggregate pandas UDF

What changes were proposed in this pull request?
This PR proposes to add another example for multiple grouping key in group aggregate pandas UDF since this feature could make users still confused.
How was this patch tested?
Manually tested and documentation built.

Test PASSed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/testing-k8s-prb-make-spark-distribution-unified/2833/
Test PASSed.

Merged build finished. Test PASSed.

Test build #95666 has started for PR 22329 at commit 36a7ccc.

Test build #95666 has finished for PR 22329 at commit 36a7ccc.

This patch passes all tests.
This patch merges cleanly.
This patch adds no public classes.

Merged build finished. Test PASSed.

Test PASSed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/95666/
Test PASSed.

Test build #95690 has started for PR 22329 at commit 2ad350c.

Merged build finished. Test PASSed.

Test PASSed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/testing-k8s-prb-make-spark-distribution-unified/2851/
Test PASSed.

Test build #95690 has finished for PR 22329 at commit 2ad350c.

This patch passes all tests.
This patch merges cleanly.
This patch adds no public classes.

Merged build finished. Test PASSed.

Test PASSed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/95690/
Test PASSed.

cc @gatorsmile and @BryanCutler

Test build #95734 has started for PR 22329 at commit 1f342aa.

Merged build finished. Test PASSed.

Test PASSed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/testing-k8s-prb-make-spark-distribution-unified/2885/
Test PASSed.

LGTM

merged to master, thanks @HyukjinKwon .  I just saw branch-2.4 was cut already, I'll see if I can figure out how to merge there too.

merged to branch-2.4


just dependencies update

Description
minor dependency updates.
General Checklist

[ ] Tests added for this feature/bug
if it was a bug, test must cover it.
[ ] Conform by the style guides, by using formatter
[ ] Documentation updated
[ ] (optional) Please add a label to your PR

Pull Request Test Coverage Report for Build<PHONE_NUMBER>

0 of 0   changed or added relevant lines in 0 files are covered.
No unchanged relevant lines lost coverage.
Overall coverage remained the same at 80.313%

Totals

Change from base Build<PHONE_NUMBER>:
0%

Covered Lines:
3650

Relevant Lines:
4434

💛  - Coveralls


[stable/elasticsearch-exporter] Added PrometheusRule CRD

Signed-off-by: Pavel Zilke<EMAIL_ADDRESS>What this PR does / why we need it:
Added template for PrometheusRule to stable/elasticsearch-exporter chart
Checklist
[Place an '[x]' (no spaces) in all applicable fields. Please remove unrelated fields.]

[x] DCO signed
[x] Chart Version bumped
[x] Variables are documented in the README.md

Thanks!
The problem with this approach is that this rule would "leak" to any other deployed elasticsearch, this not being acceptable. If there is a way to restrict the rules to apply to only this Release (through restricting with labels?), then it would be perfect and we could start having a "best practices" rules.

/assign
(if there is a positive outcome)

@desaintmartin I restrict rules by jobname, defined in servicemonitor

Sorry for the late reply, I've added a few comments.


Fixes #445, fixes #509.

Change load.deepcleanResult to key off any module name, ending in .6457 or .2310 in automatic mode. Should fix Tutorial #8 - mismatch.

We're deprecating deepClean result and moving Tutorial 8 functions into a separate more detailed tutorial in a future release.


Add search by secondary input in WmStats

Currently the search box in WmStats only allows search by (primary) input dataset, along with output dataset/prep ID/request name/data range. Could it be possible to add an option to search by secondary input, or allow the input dataset query to search for both primary and secondary input?

@thongonary, Thong, secondary means PileUp dataset, right?

Yes, either MCPileup and DataPileup


Handle demo config "opened" state in React (fixes #432)

This updates the "Configuration" bar to store its opened state in React, to ensure it opens correctly (fixes #432).
As a bonus, the entire bar is now clickable, rather than just the text.

Thank you, it works now!


gspell: 1.8.1 -> 1.8.2

Semi-automatic update generated by https://github.com/ryantm/nixpkgs-update tools. This update was made based on information from https://repology.org/metapackage/gspell/versions.
meta.description for gspell is: '"A spell-checking library for GTK applications"'.
meta.homepage for gspell is: '"https://wiki.gnome.org/Projects/gspell"

Checks done (click to expand)

built on NixOS

The tests defined in passthru.tests, if any, passed

0 of 0 passed binary check by having a zero exit code.

0 of 0 passed binary check by having the new version present in output.

found 1.8.2 with grep in /nix/store/yhh1j0z3f6gqh2pxz4zbvcg8xqp0wv4k-gspell-1.8.2

directory tree listing: https://gist.github.com/851d567eab2b1b9eb874978faadb53b6

du listing: https://gist.github.com/26f5a09ea4022896a5f42d283e9a364d

Rebuild report (if merged into master) (click to expand)

62 total rebuild path(s)
20 package rebuild(s)
20 x86_64-linux rebuild(s)
20 i686-linux rebuild(s)
2 x86_64-darwin rebuild(s)
20 aarch64-linux rebuild(s)
First fifty rebuilds by attrpath
corebird
denemo
evince
fractal
gajim
glom
gnome-builder
gnome-latex
gnome-recipes
gnome3.evince
gnome3.gedit
gnome3.gnome-books
gnome3.gnome-documents
gnome3.gnome-software
gnome3.gspell
gnome3.polari
gnome3.sushi
gspell
gtranslator
osmo

Instructions to test this update (click to expand)

Either download from Cachix:
nix-store -r /nix/store/yhh1j0z3f6gqh2pxz4zbvcg8xqp0wv4k-gspell-1.8.2 \
  --option binary-caches 'https://cache.nixos.org/ https://r-ryantm.cachix.org/' \
  --option trusted-public-keys '
  r-ryantm.cachix.org-1:gkUbLkouDAyvBdpBX0JOdIiD2/DP1ldF3Z3Y6Gqcc4c=
  cache.nixos.org-1:6NCHdD59X431o0gWypbMrAURkbJ16ZPMQFGspcDShjY=
  '

(r-ryantm's Cachix cache is only trusted for this store-path realization.)
Or, build yourself:
nix-build -A gspell https://github.com/r-ryantm/nixpkgs/archive/7908e8125369a7b3144be3950c9bd281b2d4fb75.tar.gz

After you've downloaded or built it, look at the files and if there are any, run the binaries:
ls -la /nix/store/yhh1j0z3f6gqh2pxz4zbvcg8xqp0wv4k-gspell-1.8.2
ls -la /nix/store/yhh1j0z3f6gqh2pxz4zbvcg8xqp0wv4k-gspell-1.8.2/bin

cc @lethalman @jtojnar @hedning @worldofpeace for testing.

Already in gnome-3.34 branch


Test the Cairo 0.10 to Cairo 1.0 migration - for ERC-3525

Description
Test the Cairo 0.10 to Cairo 1.0 migration - for all Carbon Protocol
Acceptance Criteria

[ ] TO BE DEFINE

Not relevant


about hotkeys and modifiers...

hello, guys.
Thanks a lot for this best tools pack. These programs helped me a lot to understand complex things (bitmask) for creating best layout ever ;) (Windows Driver Kit or this package). But this topic is vast and my knowledge is not deep yet...
So, I have a couple of questions.
Firstly, I created a layer with modificator 'Kana':
// in scancode replace RCTRL to KANA (VK_OEM_8)
// After fix a bitmask

static VK_TO_BIT vk_to_bits[] = {
    {VK_SHIFT,   KBDSHIFT},
    {VK_CONTROL, KBDCTRL},
    {VK_MENU,    KBDALT},
    {VK_OEM_8,   KBDKANA},
    {0,          0}
};

static MODIFIERS char_modifiers = {
    .pVkToBit    = vk_to_bits,
    .wMaxModBits = 8,
    .ModNumber   = {
        0,            // 000 = <none>
        1,            // 001 = Shift
        // disable another modification
        SHFT_INVALID, // 010 = Control
        SHFT_INVALID, // 011 = Shift Control
        SHFT_INVALID, // 100 = Alt
        SHFT_INVALID, // 101 = Shift Alt
        SHFT_INVALID, // 110 = Control Alt (AltGr)
        SHFT_INVALID, // 111 = Shift Control Alt (Shift AltGr)
        2, // this is my best modificator for new layer.
    }
};

// and add new layer
static VK_TO_WCHARS3 vk_to_wchar3[] = {
    //                     Base   Shift  Kana
    //                     ----   ----- ------
    ....
    {'A',          CAPLOK, {L'a', L'A', L'0'}},
    {'D',          CAPLOK, {L'd', L'D', L'2'}},
    {'F',          CAPLOK, {L'f', L'F', L'3'}},
    {'J',          CAPLOK, {L'j', L'J', L'('}},
    {'K',          CAPLOK, {L'k', L'K', L')'}},
    {'M',          CAPLOK, {L'm', L'M', L'['}},
    {'S',          CAPLOK, {L's', L'S', L'1'}},
    {VK_OEM_COMMA, 0x00,   {L',', L'<', L']'}},
    ....
    {0,            0,      0,     0,    0}
};

All works fine, but... what to do with hotkeys that require characters through a modifier?
I want use hotkey, for example, "ctrl+1", need press kana+ctrl+S in this case, and nothing happend. Why?
The second question follows from the first, for correct work hotkeys this record is not valid?
{'A',          CAPLOK, {L'b', L'B', L'№'}},

Need change scancode on position 'A' to scancode 'b'?
If you have time to answer, I would be grateful.
P.S. Sorry for my terrible English.

Hotkeys are working based on VK keys, not chars. VK keys are coming from WM_KEYDOWN/WM_KEYUP events in Win32. Characters are coming from WM_CHAR events in Win32.
So in your case you'll have VK_OEM_8 + VK_SHIFT + VK_S in WM_KEYDOWN messages when pressing Kana+Ctrl+S. And 1 in WM_CHAR message.


Pydantic "Not Recognizing" Field in BaseModel with Default Value of Type

Checks

[X ] I added a descriptive title to this issue
[X ] I have searched (google, github) for similar issues and couldn't find anything
[X ] I have read and followed the docs and still think this is a bug

Bug
Output of python -c "import pydantic.utils; print(pydantic.utils.version_info())":
pydantic version: 1.7.3
pydantic compiled: True
python version: 3.8.2 (default, Mar 13 2020, 10:14:16)  [GCC 9.3.0]
platform: Linux-4.19.128-microsoft-standard-x86_64-with-glibc2.29
optional deps. installed: ['typing-extensions']

import pydantic
from typing import Type, Sequence, Union

class T:
    pass

class Model(pydantic.BaseModel):
    t: Union[Type[T], Sequence[Type[T]]] = T

    @pydantic.validator("t", always=True)
    def make_tuple(cls, v):
        if isinstance(v, Sequence):
            return tuple(v)
        return v,

# ConfigError: Validators defined with incorrect fields: make_tuple (use check_fields=False if you're inheriting from the model and intended this)

Note: If the field is marked optional and the default value is set to None, the code works without issue.
import pydantic
from typing import Type, Sequence, Union, Optional

class T:
    pass

class Model(pydantic.BaseModel):
    t: Optional[Union[Type[T], Sequence[Type[T]]]] = None

    @pydantic.validator("t", always=True)
    def make_tuple(cls, v):
        if not v:
            return T,
        elif isinstance(v, Sequence):
            return tuple(v)
        return v,

Model()
# Model(t=(<class '__main__.T'>,))

Perhaps I am missing something obvious in my sleep-deprived stupor?

Hello @ntenenz
I'm looking at this but it looks like a bug as the default value with this type is not taken into account in the metaclass causing Model.__fields__ to not have the t key, which causes this error.
In the meantime you can use Field to force it: t: Union[Type[T], Sequence[Type[T]]] = Field(T)
Hope it helps!

Thanks for the prompt response and fix @PrettyWood. Happy holidays! ❄❄❄


Benzene locks/highlights

Benzene breaks the locking/highlighting for some reason. Probably has to do with reference coordinates not being passed through children

Abandoned the internal coordinate system completely. Was getting WAY too complicated with rotation propagating through hierarchies of child elements. DOM already keeps track of everything so just leveraging that now.


The README file in this repo has some bad links

The README file in this repo has some bad links
Status code [404:NotFound] - Link: https://bitbucket.org/multicoreware/x265/wiki/Home
Status code [404:NotFound] - Link: https://x265.readthedocs.io/en/default/
Status code [404:NotFound] - Link: https://github.com/masterjk/ios-avplayer-http-capture
Status code [404:NotFound] - Link: https://github.com/djstava/manifesto
Status code [404:NotFound] - Link: https://www.dolby.com/us/en/technologies/dolby-professional-loudness-solutions.pdf
Status code [404:NotFound] - Link: https://www.dolby.com/us/en/technologies/dolby-vision/dolby-vision-streams-within-the-http-live-streaming-format-v2.0.pdf
Status code [404:NotFound] - Link: https://www.smpte.org/sites/default/files/users/user27446/HDR SMPTE Presentation March 21%2C 2017 V2.compressed.pdf
This was found by an new experimental hobby project that I have just created: https://github.com/MrCull/GitHub-Repo-ReadMe-Dead-Link-Finder
If this has been in any way helpful then please consider giving the above Repo a Star.

I’m aware and currently cleaning today! Tech debt always collects!

https://github.com/krzemienski/awesome-video/commit/32e55053cfc28e7f9e1a010c4959e092332339f4 done!


Convert-TweetDate

I'm sure you'll eventually have the commands write clean, structured objects to the pipeline. I'm using some adhoc tooling for the time being.  Here's a function you can use that should convert the created_at datetime string, into a [datetime] object.
# Convert a value like "Tue Nov 24 15:15:19 +0000 2020" to Tuesday, November 24, 2020 10:15:19 AM which is local time
Function Convert-TweetDate {
    [cmdletbinding()]
    [outputtype([System.DateTime])]
    Param(
        [Parameter(Mandatory,Position=0,ValueFromPipelineByPropertyName)]
        [alias("Created_At")]
        [string]$Timestamp
    )
    Begin {}
    Process {
        Write-Verbose "Converting $timestamp"
        $dt = $timestamp.split()
        $dtstr  = "{0} {1} {2} {3} {4}" -f $dt[2],$dt[1],$dt[5],$dt[3],$dt[4]
        [datetime]::Parse($dtstr).toLocalTime()
    }
    end {}
}

I can then use it in a script like this:
#requires -version 7.1
#requires -module BluebirdPS

#get my recent Twitter mentions

. C:\scripts\Convert-TweetDate.ps1

Search-Tweet to:JeffHicks | Select-Object @{Name="Date";Expression={Convert-TweetDate $_.created_at}},
@{Name="Tweet";Expression={$_.text -replace "@JeffHicks",""}},@{name="from";Expression={$_.user.name}}

I'm assuming command output will eventually write properly formatted and typed data to the pipeline.

I've included a ConvertFrom-TwitterV1Date command:
function ConvertFrom-TwitterV1Date {
    [CmdletBinding()]
    param(
        [Parameter(Mandatory,ValueFromPipeline)]
        [ValidateNotNullOrEmpty()]
        [string]$Date
    )

    try {
        [datetime]::ParseExact( $Date, "ddd MMM dd HH:mm:ss zzz yyyy", [CultureInfo]::InvariantCulture )
    }
    catch {
        $PSCmdlet.ThrowTerminatingError($_)
    }
}


oneshot detector segmentation fault or kernel dies

Model creation fails if tested on more than a few images. Tried macOS (16 GB RAM), CentOS 9 (28 GB RAM), Ubuntu 18 and 19 (28 GB RAM), but I always get Segmentation fault or kernel killed; tried a combination of python 2.7 and 3.6, same result. I run it against 10-30 images. Sometimes memory usage is high, sometimes not. Tried it with different image sets. Example image set: https://drive.google.com/open?id=1Jq8XD1N48YeBF6OxCYPoi4H3_g2e6v0f
Turicreate is 5.6 (current master).
Code is:
python
import turicreate as tc
starter_images = tc.load_images('./')
starter_images['label'] = starter_images['path'].element_slice(2,-4)
model = tc.one_shot_object_detector.create(starter_images,'label')

This seems to be a dupe of #2038. At the very least, we should see if the fix for that issue resolves this one.

When & where is a fix available for this #2038 release so I can test it? Thanks

@phelmsgit - #2038 is still open. So there isn't a fix yet. This issue was closed as a duplicate. Please subscribe to #2038 for updates.