Documentation for interfacing programmatically

Currently the documentation is missing how you would plug in/out game states from the node-graph. (I've read the unity forums too, yet I have no clue how I would use this for something like game-logic.)
Any help and additions in the docs would be appreciated.
Additionally to this issue, I would highly recommend ReadTheDocs for auto-parsing documentation from documented classes, making it easy to make a comprehensive documentation for this project.

You're right, the documentation is still lacking some more advanced topics than just extending it. I do try to improve it when I have time:)
Auto generated documentation from the code would also be nice, but we just decided to use mkdocs to generate the documentation (will go live soon) so it would be a pain to refactor it again to ReadTheDocs or similar. If anyone has suggestions regarding this, I'd appreciate them:)

mkdocs is the same as readthedocs, readthedocs is just a service provider with webhooks (iirc).
Is there somewhere a basic guide how to get started with accessing nodes / traversing them? If not, could you write something small down?
If any kind of documentation-service is up, I would like to contribute to it. I did simliar with my python bot projects and got some experience with the parsing and auto-doc part.

We started discussing it in #46 and groud actually made it possible with mkdocs in his repository. It is currently documenting stuff that's only in the dev branch so it's not replacing the 'old' one, found here, yet.

And if we can use readthedocs works with mkdocs, that'd be amazing:)

Hey, I'm still working on interfacing with it - and some problems seem to be hard to solve.
To give you some feedback on that - which could be a seperate issue, probably:
I tried to write a random selection node. The best solution I may have found is adding a hidden first output which references the selection. Not really pretty, it would make more sense to let Calculate return what nodes it calculated or having an out / ref parameter.
Looking at certain nodes only works with something like this:
NodeCanvas x = NodeEditorFramework.NodeEditorSaveManager.LoadNodeCanvas("Assets/Plugins/Node_Editor/Resources/Saves/test_case.asset");
NodeEditor.RecalculateAll(x);

otherwise all nodes always return 0 on their inputs/outputs. I am not sure if this is intended.

I don't quite understand what you mean:(
Maybe you can explain it in more detail, and what it has to do with the documentation (or not)?

Ref / Out
In my case, I would use the framework to write a dialogue system, with different branches.
Since dialogues could/should have random dialogues downwards, it would be useful to have a intermediate node to select a random path downwards. From here out on I would need to traverse downwards.
Let's say I have a dialogue root, which references 1 child dialogue which chooses a random dialogue node on runtime. I would now have a hard time getting the right child-dialogue to traverse downwards. It's probably about me not understanding some case, but this is how it looks right now:

The only solution I currently can come up with is using the intermediate random node to store an object attribute "selection", writing it in the calculate, use the parent, check the connection (which then is the random node), execute calculate on the random and move on to the randomNode.outputs[randomNode.selection].
There are probably multiple other cases where having and out parameter would be useful as utility.
Recalculating Nodes
I have this piece of code sitting in the Update of a random monobehaviour of an enabled scene:
	NodeCanvas x = NodeEditorFramework.NodeEditorSaveManager.LoadNodeCanvas("Assets/Plugins/Node_Editor/Resources/Saves/test_case.asset");
	NodeEditor.RecalculateAll (x);
	Debug.Log ("I may have loaded.");
	foreach(Node n in x.nodes) {

		// n.Calculate ();
		string s = "> " + n.name;
		n.ClearCalculation ();
		foreach (NodeInput ni in n.Inputs) {
			if (ni.connection != null) {
				s += " | INPUT: " + ni.connection.GetValue<float> ();
			}
		}

		foreach (NodeOutput no in n.Outputs) {
			s += " | OUTPUT: " + no.GetValue<float> ();
		}

		Debug.Log (s);
	}

If you disable RecalculateAll all inputs/outputs return 0. Is this intended?

Yes, it is intended as the calculated values are not serialized. I think that should be reasonable though, and your problem should be aproached differently...
So, you really need the random child node in the parent node? Or do you 'just' want to take a random path down the tree at the random node 'junction'? In the latter case, I'd implement a feature I remember was requested long ago which I didn't do yet (I forgot) but I could implement it in five minutes. It would enable you to 'block' the outputs of a node, so the only thing the random node would do is block all but the randomly selected output and then the calculation would only continue on the selected node. Would that help you?

That would improve it!
Another alternative would be some attribute on a dialoge node and do checks in its calculation. But I guess blocking would work then.

Ok, I'll come back to you when I'm back home and I implemented it:)

Thank you very much for your kindness. After that I would fork that repo and add custom types, like Bool, Int, GameObject, etc..
Also what do you think of the brighter, slightly different knobs? I could merge-request them too, if you'd like to.

Don't know, I like them, maybe a bit too bright (considering the lines). But the style of the node editor is rather unimportant right now as it is up to the developer to customize it for his asset;)

To come back to the OP, I'd really want to write some more articles if I had more time... So I cannot exactly say when I'll be able to provide them:/

@DarkMio I added output blocking in this commit: a05493e
An example for the random branch node, where a random branch get's chosen which will be caluclated further and the others get blocked:
using UnityEngine;
using System.Linq;
using System.Collections.Generic;
using NodeEditorFramework;
using NodeEditorFramework.Utilities;

namespace NodeEditorFramework.Standard
{
	[Node (false, "Example/Random Branch")]
	public class RandomBranchNode : Node
	{
		public const string ID = "randomBranchNode";
		public override string GetID { get { return ID; } }

		public override Node Create (Vector2 pos)
		{
			RandomBranchNode node = CreateInstance<RandomBranchNode> ();

			node.rect = new Rect (pos.x, pos.y, 100, 200);
			node.name = "RND Branch";

			node.CreateInput ("Src", "Float");

			node.CreateOutput ("Branch 1", "Float");
			node.CreateOutput ("Branch 2", "Float");
			node.CreateOutput ("Branch 3", "Float");
			node.CreateOutput ("Branch 4", "Float");
			node.CreateOutput ("Branch 5", "Float");
			node.CreateOutput ("Branch 6", "Float");
			node.CreateOutput ("Branch 7", "Float");
			node.CreateOutput ("Branch 8", "Float");

			return node;
		}

		protected internal override void NodeGUI ()
		{
			Inputs[0].DisplayLayout ();

			foreach (NodeOutput output in Outputs)
				output.DisplayLayout ();
		}

		public override bool Calculate ()
		{
			List<NodeOutput> connectedOutputs = new List<NodeOutput> ();
			foreach (NodeOutput output in Outputs)
			{ // Get all connected outputs to take into consideration
				output.calculationBlockade = true;
				if (output.connections.Count > 0)
					connectedOutputs.Add (output);
			}

			if (connectedOutputs.Count > 0)
			{ // Select a random branch from the connected ones and unblock it so it gets calculated
				int randomSelected = Random.Range (0, connectedOutputs.Count);
				NodeOutput selectedOutput = connectedOutputs[randomSelected];
				selectedOutput.calculationBlockade = false;
				// Just pass the previous value to the selected branch
				selectedOutput.SetValue (Inputs[0].GetValue ());
			}
			return true;
		}
	}
}

For the sake of completeness, here's the counterpart, where an input gets randomly selected to be the output:
using UnityEngine;
using System.Linq;
using System.Collections.Generic;
using NodeEditorFramework;
using NodeEditorFramework.Utilities;

namespace NodeEditorFramework.Standard
{
	[Node (false, "Example/Random Selector")]
	public class RandomSelectorNode : Node
	{
		public const string ID = "randomSelectorNode";
		public override string GetID { get { return ID; } }

		public override Node Create (Vector2 pos)
		{
			RandomSelectorNode node = CreateInstance<RandomSelectorNode> ();

			node.rect = new Rect (pos.x, pos.y, 100, 200);
			node.name = "RND Selector";

			node.CreateInput ("Input 1", "Float");
			node.CreateInput ("Input 2", "Float");
			node.CreateInput ("Input 3", "Float");
			node.CreateInput ("Input 4", "Float");
			node.CreateInput ("Input 5", "Float");
			node.CreateInput ("Input 6", "Float");
			node.CreateInput ("Input 7", "Float");
			node.CreateInput ("Input 8", "Float");

			node.CreateOutput ("Output", "Float");

			return node;
		}

		protected internal override void NodeGUI ()
		{
			Outputs[0].DisplayLayout ();

			foreach (NodeInput input in Inputs)
				input.DisplayLayout ();
		}

		public override bool Calculate ()
		{
			List<NodeInput> connectedInputs = new List<NodeInput> ();
			foreach (NodeInput input in Inputs)
			{ // Get all connected inputs to take into consideration
				if (input.connection != null)
					connectedInputs.Add (input);
			}

			if (connectedInputs.Count > 0)
			{ // Select a random input from the connected ones and pass it to the output
				int randomSelected = Random.Range (0, connectedInputs.Count);
				NodeInput selectedInput = connectedInputs[randomSelected];
				// Just pass the previous value to the selected branch
				Outputs[0].SetValue (selectedInput.GetValue ());
			}
			return true;
		}
	}
}

I hope that helps you with your problem!

Thanks for all your help. I worked the last days (busy weeks before that, sorry) with that and stumbled upon another odd problem:
I'm trying to plug some references from a scene into the node-graph and don't have a really good solution to that yet. I'm still working on a dialogue-system with your framework and have cases where it would be great to pre/post check some variables in the game manager. Without hard-coding certain variable-checks, it's (either me or really) hard to pre-define actions inside the node graph to get run later on.
I have an Abstract Class like this:
public abstract class AbstractCheckable : MonoBehaviour {
    public abstract bool VariableCheck();
}

And an implementation like this:
public class SomeCheckable : AbstractCheckable {
    public bool isTrue;
    public override bool VariableCheck() {
        return isTrue;
    }
}

And a node like this:
namespace NodeEditorFramework.Standard {
    [System.Serializable]
    [Node(false, "Dialogue/Variable Checker")]
    public class VariableChecker : Node {

    public class VariableChecker : Node {
        public const string ID = "variableChecker";

        public override string GetID {
            get { return ID; }
        }

        public override bool AllowRecursion {
            get { return true; }
        }

        public Node selectedNode;

        [SerializeField]
        private AbstractCheckable _abstractCheckable;

        // Use this for initialization
        public override Node Create(Vector2 pos) {
            VariableChecker node = CreateInstance<VariableChecker>();
            node.rect = new Rect(pos.x, pos.y, 200, 80);

            node.name = "Varibale Check";
            node.CreateInput("Parent", "Void");
            node.CreateOutput("true", "Void");
            node.CreateOutput("false", "Void");
            return node;
        }

        // Update is called once per frame
        protected internal override void NodeGUI() {
            GUILayout.BeginHorizontal ();
            _abstractCheckable = (AbstractCheckable) EditorGUILayout.ObjectField(_abstractCheckable, typeof(AbstractCheckable), true);
            GUILayout.EndHorizontal();
            GUILayout.BeginHorizontal();
	        GUILayout.BeginVertical ();
            Inputs[0].DisplayLayout();
            GUILayout.EndVertical();
            GUILayout.BeginVertical();
            Outputs[0].DisplayLayout();
            GUILayout.EndVertical();
            GUILayout.EndHorizontal();
            GUILayout.BeginHorizontal();
            Outputs[1].DisplayLayout();
            GUILayout.EndHorizontal();
        }

        public override bool Calculate() {
            var check = _abstractCheckable.VariableCheck();
            if (_abstractCheckable != null) {
                Debug.Log("Actually in there.");
                check = _abstractCheckable.VariableCheck();
                selectedNode = check ? Outputs[0].connections[0].body : Outputs[1].connections[0].body;
            }
            return check;
        }
    }
}

I have a demo on a secondary device where this worked fine until I rewrote some irrelevant parts. The inspector reports a TypeMismatch, which is expected with extensions of MonoBehaviour. I'm running out of ideas and probably need to hook up (somewhow?) a singleton + some kind of bridge - or you might have a bright idea on that?

It's simply because MonoBehaviours are stored in the scene whereas the canvas is stored as an asset.  So it's simply not allowed to reference scene objects:(
I developed a scene saving solution to overcome this problem, you might want to check it out: 23c875b

This is in your develop-branch, right?
I have that version right now on my instance, is this the magic "save to scene" button?
How do you use the editor for a field like this: !img

You mean mysterious, and crappy rather than magic? ;) It's a temporary GUI, it's the functionality that counts for now:D
I don't get what it's about, you mean referencing scene objects with the object field or adding knobs with the buttons below?

Also, you should not need the calculate button (if it's not something to your design that I don't know about), just make it like this:
if (GUI.changed)
	NodeEditor.RecalculateFrom (this);

;)

No, I actually mean how referencing works (seems my solution works unreliably right now) and how saving to scene works.
I'm still loading my canvas like that:
var _canvas = NodeEditorFramework.NodeEditorSaveManager.LoadNodeCanvas("Assets/Plugins/Node_Editor/Resources/Saves/Boolean_Dialogue.asset", false);

Since saving to scene should make this obsolete - how do I load that now?
The calculate button is just a glorified debug-button.

Ok, so there is a new API for NodeEditorSaveManager - In order to load from/to the scene, there's now SaveSceneNodeCanvas / LoadSceneNodeCanvas ;) It should be obvious, because parameters are roughly the same. Just note that currently there's no caching for canvases saved in the scene, that means you would loose it by shutting down with unsaved changes:/

Interesting. Yet I am not able to load it from scene. Another thing that is probably manageable sooner or later is, that you cannot see already stored canvas.
I'm still confused by this, but loading seems to be working fine. However, the instance-check is still problematic.

There is a call to GetSceneSaves or something similar, also used by the dropdown to load canvases, which might help you:)
Also, you could modify FetchSceneSaveHolder (again, or similar) to not hide the gameobject holding the saves (the line that modifies hideflags). Make sure to reload the scene an it should show:)

I'm sorry, but there is no drop down. The Node graph I'm using is from the recent commit in the develop branch (https://github.com/Baste-RainGames/Node_Editor/commit/23c875b0ffb805efc6b1133e73d420e91e9f49b5)
Also I'm a bit confused what you mean with your second statement.
Thanks for your patience, tho.

No problem:)
The load from scene button has a bug that the dropdown immediately disappears when youclick to the far right because the dropdown is left-aligned to the button and automatically closes when the mouse is out of reach (which would be immediately the case when it opens out of reach obviously). That causes the dropdown to occasionally not show:/
Also, you'de obviously need a save to see it, too;)
My second statement just describes a method to debug all canvases saved in the scene by showing the location where they are saved (a gameobject, hidden by default). That is if you want to debug it;)

I'm still not sure where the dropdown should be. Haha:
The debugging is just to print some internal states of the hackery I'm doing with it.

Ok maybe I was not too clear lol:D
It's not obvious that it's a dropdown, it's the 'Load from Scene' button which I'm referring too, it will open a dropdown containing every scene save you could load:)
Hope that helps you:) I've to quit unfortunately, where Iive it's like 23:55, so I'll answer tomorrow! :)

It's 23:55 here too, you're probably German too, I guess?
Anyway, clicking the "Load from Scene" button doesn't do anything.

Yep, I'm too in Germany:) I'll take a look at this tomorrow!

da3d8b9 adresses this and alot of other errors from the last update:) I can post a gif about using the scene saving functionality in a few mins!

Here's the scene saving functionality in a gif:

I don't have the option to Save to Scene or Load from Scene - any idea why these options might be missing for me?

@pi3butcher Then you're probably using the master branch.
Unfortunately due to lack of time I couldn't yet merge the develop branch with master (develop is way ahead master though and usually even more stable!):/
Sorry for that inconvenience!

I suppose this has been resolved? If not, please reopen! Also, I am working on the documentation right now:)

@Seneral sure is! Very helpful all allround.


replace all unchanged directory name in tools

아직 바뀌지 않은 com/twitter/penguin/korean 을 org/openkoreantext/processor 로 변경하였습니다
replaced some remaining of old directory

Thanks, @lmh30003! I will invite you as a collaborator as well. 👍


Added search for issues

Just wanted to give you a heads up. This and a your other recent pulls we're wrapped up and published in a new release


CMake error

I try to launch this project but faced with such problem
Links I've tried , I downloaded eigen and add it to the PATH but it doesn't help
https://eigen.tuxfamily.org/dox/GettingStarted.html
CMake Error at CMakeLists.txt:21 (find_package):
By not providing "FindEigen3.cmake" in CMAKE_MODULE_PATH this project has
asked CMake to find a package configuration file provided by "Eigen3", but
CMake did not find one.
Could not find a package configuration file provided by "Eigen3" with any
of the following names:
Eigen3Config.cmake
eigen3-config.cmake

Add the installation prefix of "Eigen3" to CMAKE_PREFIX_PATH or set
"Eigen3_DIR" to a directory containing one of the above files.  If "Eigen3"
provides a separate development package or SDK, be sure it has been
installed.
-- Configuring incomplete, errors occurred!
See also "C:/Users/mykha/Desktop/SDF_cuda/build/CMakeFiles/CMakeOutput.log".
See also "C:/Users/mykha/Desktop/SDF_cuda/build/CMakeFiles/CMakeError.log".

Instructions state:
To compile the code and run an example (in ubuntu)
There is no windows support.


Emulationstation does not run via VNC

Hi all,
I’m running emulationstaton 2.0RC1 (on Retropie 2.6.0), and I’m experiencing problems running a VNC server (and remotely viewing emulationstation). I’ve installed (and started) tightvnc server using the procedure described here (which worked perfectly with my last build of Retropie).
This time around, though, I’m not able to start emulationstation from my VNC client. I’m able to use VNC to open a terminal, but launching emulationstation gives the following error:
“X is running. Please shut down X in order to mitigate problems with loosing (sic) keyboard input. For example, logout from LXDE.”
Unfortunately, I am unable to stop X from the VNC terminal (without also halting VNC).
I’d appreciate any thoughts! Thanks, all, in advance.

Run the binary directly - I think it's /opt/RetroPie/supplementary/EmulationStation/emulationstation. RetroPie adds a script, /usr/bin/emulationstation, that checks some stuff before launching ES, which is what you're seeing. ES will work fine from X, but your emulators may not.

Thanks for getting back to me. I ran the binary and it bypasses the check, but returns this error:
Xlib:  extension "RANDR" missing on display ":1".
Keyboard layout unknown, please send the following to the SDL mailing list (sdl@libsdl.org):
lvl0:   Error creating SDL window!
Could not get EGL display
lvl0:   Renderer failed to initialize!
lvl0:   Window failed to initialize!

Thanks for getting back to me. I ran the binary and it bypasses the check, but returns this error:
Xlib: extension "RANDR" missing on display ":1".
Keyboard layout unknown, please send the following to the SDL mailing list (sdl@libsdl.org):
lvl0: Error creating SDL window!
Could not get EGL display
lvl0: Renderer failed to initialize!
lvl0: Window failed to initialize!


Bug with SODA API

Blocking issue for #124 as I'm trying to bring in the total number of rows of a dataset. If I run this:
https://data.seattle.gov/resource/y6ef-jf2w.json?$select=count(*)
It works fine, but if I run this:
https://opendata.miamidade.gov/resource/tzia-umkx.json?$select=count(*)
I get an internal error. I'm trying to reach out to Socrata devs through @sarasti.

Steve Ellsworth<EMAIL_ADDRESS>Hi Ernie,
Hope all is well and looking forward to catching up with you and the Fellows in Oakland.
Mike forwarded on your note late last night and I’m looking into potential causes right now; Back to you as soon as I have an update.

Hi Ernie,
Thank you for reaching out to Socrata Support.
I believe the reason why you ran into that error is because queries don't work well on filtered views. If you query the underlying dataset it should work fine. https://opendata.miamidade.gov/resource/dj6j-qg5t.json?$select=count(*)
Please let me know if I can answer any questions,
Rebecca


put the AKS content 'At the top level between "Manage FMW Infrastructure domains" and "CI/CD Considerations"'

On branch edburns-msft-dd-1426715-wls-aks-docs Per @mriccell and @rosemarymarano @rosemarymarano, put the AKS content 'At the top level between "Manage FMW Infrastructure domains" and "CI/CD Considerations"'
modified:   documentation/3.3/content/samples/azure-kubernetes-service/_index.md
new file:   documentation/3.3/content/userguide/aks/_index.md
modified:   documentation/3.3/content/userguide/base-images/_index.md
modified:   documentation/3.3/content/userguide/cicd/_index.md
modified:   documentation/3.3/content/userguide/istio/istio.md
modified:   documentation/3.3/content/userguide/kubernetes/k8s-setup.md
modified:   documentation/3.3/content/userguide/managing-domains/_index.md
modified:   documentation/3.3/content/userguide/managing-fmw-domains/_index.md
modified:   documentation/3.3/content/userguide/managing-operators/_index.md
modified:   documentation/3.3/content/userguide/platforms/environments.md
modified:   documentation/staging/content/samples/azure-kubernetes-service/_index.md

Re-order weights to preserve layout.

These two had weight: 3:
./prepare/_index.md
./platforms/environments.md

But "Operator prerequisites" sorted before "Setup checklist".

This commit resolves this conflict by incrementing
environments, and the subsequent chapters as well.
+++ b/documentation/3.3/content/userguide/platforms/environments.md
@@ -2,7 +2,7 @@
 title: "Supported platforms"
 date: 2019-02-23T16:40:54-05:00
 description: "See the operator supported environments."


Allow use of different matplotlib backends

pyaf==1.0
In pyaf.TS.Plots.decomp_plot I run unto the warning:
This call to matplotlib.use() has no effect because the backend has already
been chosen; matplotlib.use() must be called before pylab, matplotlib.pyplot,
or matplotlib.backends is imported for the first time.
As I am using TkAgg backend for pandas prior to calling pyaf.
Would be good to be able manually set this in pyaf

Hi @bb78657
Thanks for the report.
I added these plot functions to be able to make some plots in the jupyter notebooks based on the forecast results. I am not a plotting/visualization  expert though.
I designed PyAF to be a computational module, not a visualization software.
A warning is allowed here, if it does not lead to an error.
If you have more sophisiticated use cases, please feel free to use the forecasts and matplotlib.

No worries, not a serious issue, closing this


0.1.5: Failed to install

Obsidian 0.12.12 offers upgrade, but "Failed to install" (from 0.1.4).
Console:
Failed to load resource: the server responded with a status of 404 ()
app.js:1 XMLHttpRequestonabort: nullonerror: ƒ (e)onload: ƒ ()onloadend: nullonloadstart: nullonprogress: nullonreadystatechange: nullontimeout: nullreadyState: 4response: "Not Found"responseText: "Not Found"responseType: ""responseURL: "https://github.com/kzhovn/statusbar-pomo-obsidian/releases/download/0.1.5/manifest.json"responseXML: nullstatus: 404statusText: ""timeout: 0upload: XMLHttpRequestUpload {onloadstart: null, onprogress: null, onabort: null, onerror: null, onload: null, …}withCredentials: false__proto__: XMLHttpRequest
(anonymous) @ app.js:1

I hadn't created the release yet, it should be up now.

Just installed, it works already.
Maybe try again ?


Calculating item height

Hi, i'm trying to use this on my project but my list is populated with rows with a non fixed height, some items has images, other only text, etc and data is being retrieved from a remote server; because this angular-virtual-scroll fails to render my items and it applies the same height to all new rows. There is any way to solve this and wait until the item is loaded or populated with the remote data to calculate the height?
Right now, my first items are being displayed with no problems but when i scroll down after some point, all items begin to have the same height, and also when going back, scrolling upwards again, the items are being displayed with a fixed heigh also.
Thanks in advance,

Any ideas on this?

+1

I have two "not good enough" idea .

You can have a function like "getHeight()" . Once we get a data from web ,we can calculate the item one by one ,without render .
Why without render ? We have a view pattern so we can calculate by "oh I got a title so height + 10 , oh a text ,+ 20 ,good an item's height is 30 " .
Then you can get item's height by user ,and show 'dynamic' item height list.

You render list items one by one and save the item's height in a list , then you can calculate height with a loop .

How about this two solutions ?


Select in standard form

I was trying to get the Select working inside my form but the field is not going with the post, I don't use javascript to get the values, my other form inputs do send the name-values. I tried it by modifying on materializecss.com and it doesn't work there too. Is this a bug?

https://github.com/Dogfalo/materialize/blob/master/CONTRIBUTING.md#using-the-issue-tracker

This sounds like a general How-To question. Please search stack overflow


Access script objects?

I'm creating bridge between Javascript and my native C++ engine, I have ScriptComponent declared into JS.
How can I access to script instance from C++?
How can I call script methods from C++? IE: initialize, update, draw etc?
Thanks

You should first read http://duktape.org/guide.html#gettingstarted which should answer at least parts of your question.

I hope the link answered your question - if not, it might be best to raise usage issues e.g. in Stack Overflow (using "duktape" tag).


Laravel 5.6 support

Hello, please add support for the laravel 5.6.

I've made a release for this.
Thanks @simonhamp 👍

Thank you. Now we must wait on https://github.com/GrahamCampbell/Laravel-Throttle/issues/75 I suppose.


Unit test director processing of vehicle manifests

Adds unit tests for director.register_vehicle_manifest, which tests a number of other functions in the process (in both JSON and ASN.1/DER modes). One of these tests takes advantage of a bugfix made to Uptane's TUF Fork found during the writing of these tests. Adds test data for these tests to tests/test_data/flawed_manifests.
Consolidates pyasn1 ASN.1/DER conversion errors into new Uptane error classes, uptane.ASN1DERDecodingError and uptane.ASN1DEREncodingError, and uses these in testing, for a cleaner interface.
Does a nominal DER DATA schema check that was missing in convert_signed_der_to_dersigned_json, to raise more consistent error types (tuf.FormatError when the data isn't even bytes, for example, instead of an inscrutible pyasn1 error).
(Opportunistic, marginally related): switches tuf.Error to uptane.Error for a few conversion errors in asn1_codec for more consistent errors.

Coverage increased (+3.9%) to 81.78% when pulling 07dce95ff7e65f30e4a65cd8f84b177b29e2705c on awwad:more_unit_tests_for_director into 5edb7e498bbb9f5ea833009b600040ac1c6a3f9b on uptane:develop.

Coverage increased (+7.9%) to 85.786% when pulling 85ab07af821cd2df5517ad860f271ed24a48a793 on awwad:more_unit_tests_for_director into 5edb7e498bbb9f5ea833009b600040ac1c6a3f9b on uptane:develop.

I'd still like a review, @vladimir-v-diaz, when you have time, but the demo runs on this and all tests pass and it's almost entirely additional test content, so I'm going to merge it.


ci: update workflows for forked repo

We cannot depend on the upstream informalsystems/hermes repo for CI  deployments, because we need the forked Hermes code for compatiblity with Penumbra chains. Added a new workflow that will publish as ghcr.io/penumbra-zone/hermes, and removed the informalsystems one.

Oh, sick, my big goal here is to re-add a container build so we can consume it in CI deployments. I'll edit this to just add the container workflow, and wait for #23 to land to rebase this!

This PR now only affects the container-build logic. Will wait until other PRs land, so this can be rebased, and we keep CI green. I can't test the new container workflow until it lands on main, so there might be a follow-up, but will handle that when the time comes.

Ready for review. I tacked on one more commit to bump the timeout on one of the CI jobs that was failing due to overrunning the 20m limit. If we end up maintaining this fork for a long time, maybe someday it'll be worthwhile to focus on speeding up CI—but at the low rate of change here, not worthwhile right now.


add manual promotions for each channel

Why

Updating every channel is not always necessary and is very disruptive to old Repls

What changed

Add a promotion for each channel, so that you have to manually say you want to update it.
After you've updated as many as you want, you can notify spinnaker to build the disk

Test plan

See that the spinnaker workflow looks correct
Try promoting one channel
Roll it back in GCP

Hold up this is possible? I was under the impression that we have to rebuild everything 😕

I guess, should've done this a while ago.

Sorry I didn't mean actually hold up, 😂 sorry. Ship it

Just surprised 🙀


Regressions in rasterizer metrics...

Looks like 90th_percentile_frame_rasterizer_time_millis, 99th_percentile_frame_rasterizer_time_millis, average_frame_rasterizer_time_millistimeToFirstFrameRasterizedMicros, and worst_frame_rasterizer_time_millis are all affected.
See https://flutter-flutter-perf.skia.org/e/?begin=1624912263&end=1624985465&keys=X17a2a7fc30f983e7bd1b45feee6fc777&num_commits=50&request_type=1&xbaroffset=24782.
Also see https://flutter-flutter-perf.skia.org/e/?begin=1624912263&end=1624985465&keys=X1f7236ae14dd4f908e41e01cf0b90796&num_commits=50&request_type=1&xbaroffset=24782 for other rasterizer regressions.
It looks like it might be the roll at https://github.com/flutter/flutter/pull/85508.

/cc @chinmaygarde

https://github.com/flutter/flutter/issues/84213 is the cause of the regression, https://github.com/flutter/engine/pull/27048 was merged to disable it. Next roll should fix.

All the metrics returned to their previous readouts.


It's not working properly for version 8.0 (Windows)

I've properly followed the steps mentioned here : https://draculatheme.com/mysql-workbench
Dark theme is not being applied to entire workbench, Just the code editor !
Any suggestions ? How can I resolve this ?
Thank You !

Idem for me. Not change the other part of the workbench.

Idem for me. Not change the other part of the workbench.

Have you found the fix yet ?? The light mode is really annoying
On mac it's working properly but on windows it's not :(

no fix found


fix(config): change some parameter units to seconds for Minoston MP20Z

I know the manual says the timer values are in minutes, but I have two of these devices and can confirm the units are seconds.
Pretty new to pull requests, hope this is done properly. Thanks for your work on this.

PR description here

@zwave-js-bot rename commit


Factor complex logic out of main token matching.

This commit factors out two more complex if/else blocks from the matcher
for tokens. This has two effects:

The main matching logic becomes easier to read without nested if/else
blocks for more complex matching.

cargo tarpaulin no longer reports lines are not covered because
there is no executable code on that line. By moving the complex logic
into a function, and putting a call to the function on the same line
as the pattern, tarpaulin now correctly sees that it is covered.

Note that the equivalent refactoring was not done for the nested match
of !=, >= and <= as these are simple matches with no if
conditions, and there is benefit to having the full matching logic for
all such operators/symbols expressed directly in the matcher block.
There is a minor hit to locality of knowledge; that is, finding the
logic for tokenizing certain things requires more searching, but the
function names should be sufficiently descriptive to make this
near-trivial. For example, instead of the inlined logic to distinguish a
period token from a .123 style decimal literal, the function is named
read_period_or_decimal_token. This should still provide sufficient
context for readers of the main match block to find the relevant code
further down.

Thanks for this!


bump jiter to 0.8.1

Change Summary
... I think this might fix the aarch64 build failure on main...
Related issue number
N/A
Checklist

[ ] Unit tests for the changes exist
[ ] Documentation reflects the changes where applicable
[ ] Pydantic tests pass with this pydantic-core (except for expected changes)
[ ] My PR is ready to review, please add a comment including the phrase "please review" to assign reviewers

@messense the windows aarch64 failures here seem unfortunate, I think probably maturin has located the x64 (host) interpreters and passed those to PyO3. Then neither project has noticed that we're building for aarch64 and the libs from the host interpreters can't be used to link.
We do have the generate-import-lib enabled, so I think maybe PyO3 is doing the wrong thing here? Or do you think maturin should be doing something different? I will try to push a git branch of PyO3 later, perhaps.

🐍 Found CPython 3.11 at C:\hostedtoolcache\windows\Python\3.11.9\x64\python.exe, CPython 3.12 at C:\hostedtoolcache\windows\Python\3.12.7\x64\python.exe, CPython 3.13 at C:\hostedtoolcache\windows\Python\3.13.0\x64\python.exe

Yeah this looks wrong, previously it was

🐍 Found CPython 3.11, CPython 3.12, CPython 3.13

Heh, looks like that was probably my maturin patch to "fix" the generate-import-lib stuff for abi3 not being quite right then, sorry 🙈

I think it may be related to https://github.com/PyO3/maturin/pull/2353/files#diff-b465b575a327d11d450c4994e874d0fdd40b90890e43089530c3d148d0017a33R9, is_cross_compiling changed to false because the native MSVC compiler can target aarch64, but we also need to account for python architectures.

Thanks, I guess we can merge that and try a beta release here?

A beta release sounds good.

v1.7.8-beta.1 is out.

I think you need to use maturin-version: 1.7.8-beta.1 in the action input, it does not support translating from 1.7.8b1 to 1.7.8-beta.1 yet (it downloads maturin executable from github release)

Thanks, looks like that beta release works 🎉

The aarch64 failure is a definite issue which looks like it's caused by a new interaction between PyO3 0.23 and maturin. Somewhere in the system it seems to not be recompiling when changing Python version.
See output with PyO3 0.22.6 when finishing 3.8 and then compiling for 3.9:
📦 Built wheel for CPython 3.8 to dist/pydantic_core-2.27.1-cp38-cp38-musllinux_1_1_x86_64.whl
warning: `/root/.cargo/config` is deprecated in favor of `config.toml`
note: if you need to support cargo 1.38 or earlier, you can symlink `config` to `config.toml`
   Compiling pyo3-build-config v0.22.6
   Compiling pyo3-macros-backend v0.22.6
   Compiling pyo3-ffi v0.22.6
   Compiling pyo3 v0.22.6
   Compiling jiter v0.7.1
   Compiling pydantic-core v2.27.1 (/home/runner/work/pydantic-core/pydantic-core)
   Compiling pyo3-macros v0.22.6
    Finished `release` profile [optimized] target(s) in 54.07s
🖨  Copied external shared libraries to package pydantic_core.libs directory:
    /usr/local/musl/x86_64-unknown-linux-musl/lib/libgcc_s.so.1
📦 Built wheel for CPython 3.9 to dist/pydantic_core-2.27.1-cp39-cp39-musllinux_1_1_x86_64.whl

Same output with PyO3 0.23:
📦 Built wheel for CPython 3.8 to dist/pydantic_core-2.27.1-cp38-cp38-musllinux_1_1_x86_64.whl
warning: `/root/.cargo/config` is deprecated in favor of `config.toml`
note: if you need to support cargo 1.38 or earlier, you can symlink `config` to `config.toml`
    Finished `release` profile [optimized] target(s) in 0.06s
🖨  Copied external shared libraries to package pydantic_core.libs directory:
    /usr/local/musl/x86_64-unknown-linux-musl/lib/libgcc_s.so.1
📦 Built wheel for CPython 3.9 to dist/pydantic_core-2.27.1-cp39-cp39-musllinux_1_1_x86_64.whl

... I'll try to debug, this looks pretty serious and probably also explains https://github.com/samuelcolvin/watchfiles/issues/313 - I think we're compiling wheels against the wrong Python API.

Yep, pretty clear what's going on. In https://github.com/PyO3/pyo3/pull/4497 I mistakenly changed PYO3_CONFIG_FILE env var to be read in a way that we don't emit a cargo:rerun-if-changed block for it. And so all builds shipped using 0.23 in combination with the PYO3_CONFIG_FILE mechanism (like maturin uses) are potentially broken.
I think this is a pretty major soundness bug, will have to get a PyO3 fix out asap.

@messense with the unfortunate PyO3 compile bug in https://github.com/PyO3/pyo3/issues/4757 I think there's going to be a lot of projects recompiling in the coming days. Could I possibly ask you to publish maturin 1.7.8 please so that they won't hit the same windows aarch64 compile issue?
I think we're then in a good place with PyO3 / maturin hopefully fully compatible with the new free-threaded builds for various configurations, thank you for all your help 🙏

Happy to do it and save you the time, I'll do that now. Thanks.

All green! 🎉


Create reducer/action to consume imageSetDetails from API

Signed-off-by: Adelia Ferreira<EMAIL_ADDRESS>What's inside ?

New api method
New action method
New reducer to ImageSetDetail

How it's build ?

Modify api and action files to create new methods to ImageSetDetail
Create a new reducer and export it to reducers.js to cover action in ImageSetDetail

Codecov Report

Merging #194 (ea44172) into feature-image-sets (a9ecd9c) will increase coverage by 0.57%.
The diff coverage is 53.84%.

:exclamation: Current head ea44172 differs from pull request most recent head 993bf99. Consider uploading reports for the commit 993bf99 to get more accurate results

@@                  Coverage Diff                   @@
##           feature-image-sets     #194      +/-   ##
======================================================
+ Coverage               22.54%   23.12%   +0.57%
======================================================
  Files                      91       92       +1
  Lines                    1557     1570      +13
  Branches                  399      399
======================================================
+ Hits                      351      363      +12
- Misses                   1119     1121       +2
+ Partials                   87       86       -1

Impacted Files
Coverage Δ

src/api/index.js
50.81% <25.00%> (+3.36%)
:arrow_up:

src/store/actions.js
50.00% <33.33%> (-1.43%)
:arrow_down:

src/store/imageSetDetail.js
80.00% <80.00%> (ø)

src/store/action-types.js
100.00% <100.00%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update a9ecd9c...993bf99. Read the comment docs.


Do not remove ragdoll collision layers after simulation disabled

Those two lines that I removed clear collision layers and masks for each bone, if simulation was disabled.
With that collision detection doesn't work any more.
Here is how it works right now:
https://youtu.be/H0wkiiwg4bI
And here is how it has to work, and is without those lines:
https://youtu.be/m2KjrekxD0Y
(in videos the act of shooting enable a simulation, and a keypress disable it and returns character to default position)
If game developer want to clear collision layers, he/she can do that in the script.

After the deactivation the physical skeleton are supposed to remain inplace.
you can see that this function _stop_physics_simulation not only change the layer and the mask but also change the body mode to static.
The correct approach is to add another state (Kinematic):

Active (The bones are fully simulated by the physics)
Kinematic (The physical bones are moved by the animation)
Deactivated (The physical bones are fully deactivated)

About, "The physical bones are moved by the animation", as I can see, it doesn't work at all. For bones to move with animation with simulation disabled, I added a workaround in game script, in form of 3 lines, that go thru each physic bone and correct it's transform to transform of a corresponding animation bone

Exactly, what I mean is that the physical bone should support this
functionality.
On Sat, Dec 14, 2019, 20:06 Acvarium<EMAIL_ADDRESS>wrote:

About, "The physical bones are moved by the animation", as I can see, it
doesn't work at all. For bones to move with animation with simulation
disabled, I added a workaround in game script, in form of 3 lines, that go
thru each physic bone and correct it's transform to transform of a
corresponding animation bone
—
You are receiving this because your review was requested.
Reply to this email directly, view it on GitHub
https://github.com/godotengine/godot/pull/34313?email_source=notifications&email_token=AB7UYR7V3AY5LFVRE42H3GDQYUVCHA5CNFSM4J2EGK72YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEG4I7PQ#issuecomment-565743550,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AB7UYR7LTTCY5ONOLZAPEC3QYUVCHANCNFSM4J2EGK7Q
.

This feature got already integrated by this one #36008

@AndreaCatania Does that mean that this PR should be closed?
@Acvarium If this still desired, it needs to be rebased on the latest master branch.

Yep, it's already implemented.

Closing then. Thanks for the contribution nevertheless!


add support for ips in ipam config

This PR is adding an additional field in the IPAM config for Weave - ips.
It allows for specifying an IP address through the CNI plugin, similar to weave attach and claim that IP.

I am not sure if it makes sense to configure also checkAlive or to set it to true at all times - currently it is set to false.

Since the IPAM configuration is specific to each plugin, I think this is allowed per the CNI spec. I am not sure if the choice for ips type is right though - this type is used in the Result, but it seemed appropriate for the input values of the IPAM as well.

TODO:

[ ] fix 880_cni_plugin_ip_address_assignment_test.sh.sh tests to test new functionality

Thanks for the test; there appear to be a couple of points still outstanding from my first review - could you respond to those?

@bboreham sorry for the delay :( I am trying to prioritise this alongside other work. I will definitely address the rest of the issues, and ping you, when this is ready for another review!

Hey, no apology required!  I've re-pushed the branch so your new test should run in CI.

Thanks for this; sorry I didn't get back to you. Some small notes below.

No worries!
I think I addressed all comments. Let me know if you think this PR should include anything else.
I'd be very happy if this gets into Weave at some point, so that we can stop using a fork on Testground!

Thanks for this; sorry I didn't get back to you. Some small notes below.

No worries!
I think I addressed all comments. Let me know if you think this PR should include anything else.
I'd be very happy if this gets into Weave at some point, so that we can stop using a fork on Testground!

It looks like your test/831_cni_plugin_ip_address_assignment_test.sh is identical to the existing test 830; it should exercise the new feature.

It looks like your test/831_cni_plugin_ip_address_assignment_test.sh is identical to the existing test 830; it should exercise the new feature.

It looks like your test/831_cni_plugin_ip_address_assignment_test.sh is identical to the existing test 830; it should exercise the new feature.

Any chance we can allow this PR to run these tests on CI? I didn't manage to get the test setup to run locally last time, and it seems like it will be fairly easy to update the code and test on CI.

It looks like your test/831_cni_plugin_ip_address_assignment_test.sh is identical to the existing test 830; it should exercise the new feature.

Any chance we can allow this PR to run these tests on CI? I didn't manage to get the test setup to run locally last time, and it seems like it will be fairly easy to update the code and test on CI.

We have no automated system to allow 3rd-party PRs access to the secrets; what I generally do is manually pull your branch and push it to the weaveworks/weave repo.
Note that your test doesn't need to duplicate all the twists and turns of test 830; it just needs to make one or two calls with the IPs set and check the result.
The tests do assume they can ssh into another host where Docker is running with open TCP socket.
To run completely locally you can edit out that assumption:
diff --git test/830_cni_plugin_test.sh test/830_cni_plugin_test.sh
index e53e988c..a8d93cc0 100755
--- test/830_cni_plugin_test.sh
+++ test/830_cni_plugin_test.sh
@@ -131,9 +131,9 @@ assert_raises "exec_on $HOST1 c1 $PING $C3IP"
 # CH0_HAIRPIN=$($SSH $HOST1 cat /sys/devices/virtual/net/weave/brif/$CH0_PEER/hairpin_mode)
 # assert_raises "[ $CH0_HAIRPIN == 1 ]"
 #
-assert "$SSH $HOST1 cat /sys/devices/virtual/net/weave/brif/vethwepl${CH0:0:7}/hairpin_mode" "1"
-assert "$SSH $HOST1 cat /sys/devices/virtual/net/weave/brif/vethwepl${CH1:0:7}/hairpin_mode" "0"
-assert "$SSH $HOST1 cat /sys/devices/virtual/net/weave/brif/vethwepl${CH2:0:7}/hairpin_mode" "1"
+assert "cat /sys/devices/virtual/net/weave/brif/vethwepl${CH0:0:7}/hairpin_mode" "1"
+assert "cat /sys/devices/virtual/net/weave/brif/vethwepl${CH1:0:7}/hairpin_mode" "0"
+assert "cat /sys/devices/virtual/net/weave/brif/vethwepl${CH2:0:7}/hairpin_mode" "1"

@@ -141,13 +141,13 @@ assert "$SSH $HOST1 cat /sys/devices/virtual/net/weave/brif/vethwepl${CH2:0:7}/h
 stop_weave_on $HOST1

 # Ensure no warning is printed to the standard error:
-ACTUAL_OUTPUT=$(CHECKPOINT_DISABLE="$CHECKPOINT_DISABLE" DOCKER_HOST=tcp://$HOST1:$DOCKER_PORT $WEAVE launch 2>&1)
-EXPECTED_OUTPUT=$($SSH $HOST1 docker inspect --format="{{.Id}}" weave)
+ACTUAL_OUTPUT=$(CHECKPOINT_DISABLE="$CHECKPOINT_DISABLE" $WEAVE launch 2>&1)
+EXPECTED_OUTPUT=$(docker inspect --format="{{.Id}}" weave)

 assert_raises "[ $EXPECTED_OUTPUT == $ACTUAL_OUTPUT ]"

-assert "$SSH $HOST1 \"curl -s -X GET <IP_ADDRESS>:6784/ip/$C1 | grep -o -E '[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}'\"" "$C1IP"
-assert "$SSH $HOST1 \"curl -s -X GET <IP_ADDRESS>:6784/ip/$C3 | grep -o -E '[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}'\"" "$C3IP"
+assert "curl -s -X GET <IP_ADDRESS>:6784/ip/$C1 | grep -o -E '[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}'" "$C1IP"
+assert "curl -s -X GET <IP_ADDRESS>:6784/ip/$C3 | grep -o -E '[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}'" "$C3IP"

 end_suite
diff --git test/config.sh test/config.sh
index 3b599ffa..76483877 100644
--- test/config.sh
+++ test/config.sh
@@ -101,7 +101,7 @@ run_on() {
     host=$1
     shift 1
     [ -z "$DEBUG" ] || greyly echo "Running on $host: $@" >&2
-    remote $host $SSH $host "$@"
+    "$@"
 }

 get_command_output_on() {
@@ -115,7 +115,7 @@ docker_on() {
     host=$1
     shift 1
     [ -z "$DEBUG" ] || greyly echo "Docker on $host:$DOCKER_PORT: $@" >&2
-    docker -H tcp://$host:$DOCKER_PORT "$@"
+    docker "$@"
 }

 docker_api_on() {
@@ -136,7 +136,7 @@ weave_on() {
     host=$1
     shift 1
     [ -z "$DEBUG" ] || greyly echo "Weave on $host:$DOCKER_PORT: $@" >&2
-    CHECKPOINT_DISABLE="$CHECKPOINT_DISABLE" DOCKER_HOST=tcp://$host:$DOCKER_PORT $WEAVE "$@"
+    CHECKPOINT_DISABLE="$CHECKPOINT_DISABLE" $WEAVE "$@"
 }

 stop_weave_on() {
@@ -151,7 +151,7 @@ exec_on() {
     host=$1
     container=$2
     shift 2
-    docker -H tcp://$host:$DOCKER_PORT exec $container "$@"
+    docker exec $container "$@"
 }

 # Look through 'docker run' args and try to make the hostname match the name

Then the run looks a little untidy because the CNI results are going to stdout, but you can see it worked:
$ HOSTS=localhost ./test/830_cni_plugin_test.sh -v
Cleaning up on localhost: removing all containers and resetting weave
Docker on localhost:2375: rm -f -v 8adc08a80d77 097012a50dad 5bb8f188cfbf<PHONE_NUMBER>0a 2505ab650754 00ae9ed80765 fa9597b14449 2dbfc8cf44e3 e8c6965ffe8f
Running on localhost: sudo rm -f /opt/cni/bin/weave-plugin-latest /opt/cni/bin/weave-net /opt/cni/bin/weave-ipam /etc/cni/net.d/10-weave.conflist
Test CNI plugin
Running on localhost: sudo mkdir -p /opt/cni/bin
Weave on localhost:2375: setup-cni
Weave on localhost:2375: launch
7ddcd31e8a63473b58d83c09a8918c5bbc0feee7f64040e9a6700631257dbba2
Docker on localhost:2375: run --net=none --name=c0 -dt alpine /bin/sh
Docker on localhost:2375: run --net=none --privileged --name=c1 -dt alpine /bin/sh
Docker on localhost:2375: run --net=none --name=c2 -dt alpine /bin/sh
Docker on localhost:2375: run --net=none --name=ch0 -dt alpine /bin/sh
Docker on localhost:2375: run --net=none --name=ch1 -dt alpine /bin/sh
Docker on localhost:2375: run --net=none --name=ch2 -dt alpine /bin/sh
net.ipv4.conf.all.arp_accept = 1
Docker on localhost:2375: inspect -f {{.State.Pid}} c0
Docker on localhost:2375: inspect -f {{.Id}} c0
Running on localhost: sudo CNI_COMMAND=ADD CNI_CONTAINERID=84f55149129a23980253b5b7e34ca7070be7611d24e264d6178461848a0d9b17 CNI_IFNAME=eth0 CNI_NETNS=/proc/3320277/ns/net CNI_PATH=/opt/cni/bin /opt/cni/bin/weave-net
{
    "ip4": {
        "ip": "<IP_ADDRESS>/12",
        "gateway": "<IP_ADDRESS>"
    },
    "dns": {}
}Docker on localhost:2375: inspect -f {{.State.Pid}} c1
Docker on localhost:2375: inspect -f {{.Id}} c1
Running on localhost: sudo CNI_COMMAND=ADD CNI_CONTAINERID=d36df517afbe134c6b3b16a54c5bee33482825f939b5168fb560d289a8a60fdd CNI_IFNAME=eth0 CNI_NETNS=/proc/3320334/ns/net CNI_PATH=/opt/cni/bin /opt/cni/bin/weave-net
{
    "ip4": {
        "ip": "<IP_ADDRESS>/12",
        "gateway": "<IP_ADDRESS>"
    },
    "dns": {}
}Docker on localhost:2375: inspect -f {{.State.Pid}} c2
Docker on localhost:2375: inspect -f {{.Id}} c2
Running on localhost: sudo CNI_COMMAND=ADD CNI_CONTAINERID=2421f061c5d7cd8c1165affa9cd6de1a4934cad2e5a30aab47381044a10083bf CNI_IFNAME=eth0 CNI_NETNS=/proc/3320402/ns/net CNI_PATH=/opt/cni/bin /opt/cni/bin/weave-net
{
    "ips": [
        {
            "version": "4",
            "address": "<IP_ADDRESS>/12"
        }
    ],
    "routes": [
        {
            "dst": "<IP_ADDRESS>/12"
        }
    ],
    "dns": {}
}Docker on localhost:2375: inspect -f {{.State.Pid}} ch0
Docker on localhost:2375: inspect -f {{.Id}} ch0
Running on localhost: sudo CNI_COMMAND=ADD CNI_CONTAINERID=2cb4dba09753e6169a7f2abdf96ebefadad83cabb4e462c45fd5b931cbee9a05 CNI_IFNAME=eth0 CNI_NETNS=/proc/3320463/ns/net CNI_PATH=/opt/cni/bin /opt/cni/bin/weave-net
{
    "ip4": {
        "ip": "<IP_ADDRESS>/12",
        "gateway": "<IP_ADDRESS>"
    },
    "dns": {}
}Docker on localhost:2375: inspect -f {{.State.Pid}} ch1
Docker on localhost:2375: inspect -f {{.Id}} ch1
Running on localhost: sudo CNI_COMMAND=ADD CNI_CONTAINERID=86bc28f08ca70653c81bb2b86c598999a0f2fddf062ad76af5696df0ce404974 CNI_IFNAME=eth0 CNI_NETNS=/proc/3320520/ns/net CNI_PATH=/opt/cni/bin /opt/cni/bin/weave-net
{
    "ip4": {
        "ip": "<IP_ADDRESS>/12",
        "gateway": "<IP_ADDRESS>"
    },
    "dns": {}
}Docker on localhost:2375: inspect -f {{.State.Pid}} ch2
Docker on localhost:2375: inspect -f {{.Id}} ch2
Running on localhost: sudo CNI_COMMAND=ADD CNI_CONTAINERID=a0f9b4b1a3580cbb6025cb48d549a067803c1f57f7df7b45a32f9f4d770a1e1c CNI_IFNAME=eth0 CNI_NETNS=/proc/3320577/ns/net CNI_PATH=/opt/cni/bin /opt/cni/bin/weave-net
{
    "ip4": {
        "ip": "<IP_ADDRESS>/12",
        "gateway": "<IP_ADDRESS>"
    },
    "dns": {}
}Weave on localhost:2375: ps c0
Weave on localhost:2375: ps c1
Weave on localhost:2375: ps c2
Weave on localhost:2375: ps weave:expose
.......Docker on localhost:2375: rm -f c2
c2
Docker on localhost:2375: run --net=none --name=c3 -dt alpine /bin/sh
Docker on localhost:2375: inspect -f {{.State.Pid}} c3
Docker on localhost:2375: inspect -f {{.Id}} c3
Running on localhost: sudo CNI_COMMAND=ADD CNI_CONTAINERID=e21ed597f48ba3aa3f323fea344621d594c502c84f341dadecdb8966811d52b6 CNI_IFNAME=eth0 CNI_NETNS=/proc/3321708/ns/net CNI_PATH=/opt/cni/bin /opt/cni/bin/weave-net
{
    "ip4": {
        "ip": "<IP_ADDRESS>/12",
        "gateway": "<IP_ADDRESS>"
    },
    "dns": {}
}Weave on localhost:2375: ps c3
..........
all 17 tests passed in 14.710s.```

Also note the first thing each test suite does is `rm -f` every container on the host.

We have no automated system to allow 3rd-party PRs access to the secrets; what I generally do is manually pull your branch and push it to the weaveworks/weave repo.
Note that your test doesn't need to duplicate all the twists and turns of test 830; it just needs to make one or two calls with the IPs set and check the result.
The tests do assume they can ssh into another host where Docker is running with open TCP socket.
To run completely locally you can edit out that assumption:
diff --git test/830_cni_plugin_test.sh test/830_cni_plugin_test.sh
index e53e988c..a8d93cc0 100755
--- test/830_cni_plugin_test.sh
+++ test/830_cni_plugin_test.sh
@@ -131,9 +131,9 @@ assert_raises "exec_on $HOST1 c1 $PING $C3IP"
 # CH0_HAIRPIN=$($SSH $HOST1 cat /sys/devices/virtual/net/weave/brif/$CH0_PEER/hairpin_mode)
 # assert_raises "[ $CH0_HAIRPIN == 1 ]"
 #
-assert "$SSH $HOST1 cat /sys/devices/virtual/net/weave/brif/vethwepl${CH0:0:7}/hairpin_mode" "1"
-assert "$SSH $HOST1 cat /sys/devices/virtual/net/weave/brif/vethwepl${CH1:0:7}/hairpin_mode" "0"
-assert "$SSH $HOST1 cat /sys/devices/virtual/net/weave/brif/vethwepl${CH2:0:7}/hairpin_mode" "1"
+assert "cat /sys/devices/virtual/net/weave/brif/vethwepl${CH0:0:7}/hairpin_mode" "1"
+assert "cat /sys/devices/virtual/net/weave/brif/vethwepl${CH1:0:7}/hairpin_mode" "0"
+assert "cat /sys/devices/virtual/net/weave/brif/vethwepl${CH2:0:7}/hairpin_mode" "1"

@@ -141,13 +141,13 @@ assert "$SSH $HOST1 cat /sys/devices/virtual/net/weave/brif/vethwepl${CH2:0:7}/h
 stop_weave_on $HOST1

 # Ensure no warning is printed to the standard error:
-ACTUAL_OUTPUT=$(CHECKPOINT_DISABLE="$CHECKPOINT_DISABLE" DOCKER_HOST=tcp://$HOST1:$DOCKER_PORT $WEAVE launch 2>&1)
-EXPECTED_OUTPUT=$($SSH $HOST1 docker inspect --format="{{.Id}}" weave)
+ACTUAL_OUTPUT=$(CHECKPOINT_DISABLE="$CHECKPOINT_DISABLE" $WEAVE launch 2>&1)
+EXPECTED_OUTPUT=$(docker inspect --format="{{.Id}}" weave)

 assert_raises "[ $EXPECTED_OUTPUT == $ACTUAL_OUTPUT ]"

-assert "$SSH $HOST1 \"curl -s -X GET <IP_ADDRESS>:6784/ip/$C1 | grep -o -E '[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}'\"" "$C1IP"
-assert "$SSH $HOST1 \"curl -s -X GET <IP_ADDRESS>:6784/ip/$C3 | grep -o -E '[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}'\"" "$C3IP"
+assert "curl -s -X GET <IP_ADDRESS>:6784/ip/$C1 | grep -o -E '[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}'" "$C1IP"
+assert "curl -s -X GET <IP_ADDRESS>:6784/ip/$C3 | grep -o -E '[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}'" "$C3IP"

 end_suite
diff --git test/config.sh test/config.sh
index 3b599ffa..76483877 100644
--- test/config.sh
+++ test/config.sh
@@ -101,7 +101,7 @@ run_on() {
     host=$1
     shift 1
     [ -z "$DEBUG" ] || greyly echo "Running on $host: $@" >&2
-    remote $host $SSH $host "$@"
+    "$@"
 }

 get_command_output_on() {
@@ -115,7 +115,7 @@ docker_on() {
     host=$1
     shift 1
     [ -z "$DEBUG" ] || greyly echo "Docker on $host:$DOCKER_PORT: $@" >&2
-    docker -H tcp://$host:$DOCKER_PORT "$@"
+    docker "$@"
 }

 docker_api_on() {
@@ -136,7 +136,7 @@ weave_on() {
     host=$1
     shift 1
     [ -z "$DEBUG" ] || greyly echo "Weave on $host:$DOCKER_PORT: $@" >&2
-    CHECKPOINT_DISABLE="$CHECKPOINT_DISABLE" DOCKER_HOST=tcp://$host:$DOCKER_PORT $WEAVE "$@"
+    CHECKPOINT_DISABLE="$CHECKPOINT_DISABLE" $WEAVE "$@"
 }

 stop_weave_on() {
@@ -151,7 +151,7 @@ exec_on() {
     host=$1
     container=$2
     shift 2
-    docker -H tcp://$host:$DOCKER_PORT exec $container "$@"
+    docker exec $container "$@"
 }

 # Look through 'docker run' args and try to make the hostname match the name

Then the run looks a little untidy because the CNI results are going to stdout, but you can see it worked:
$ HOSTS=localhost ./test/830_cni_plugin_test.sh -v
Cleaning up on localhost: removing all containers and resetting weave
Docker on localhost:2375: rm -f -v 8adc08a80d77 097012a50dad 5bb8f188cfbf<PHONE_NUMBER>0a 2505ab650754 00ae9ed80765 fa9597b14449 2dbfc8cf44e3 e8c6965ffe8f
Running on localhost: sudo rm -f /opt/cni/bin/weave-plugin-latest /opt/cni/bin/weave-net /opt/cni/bin/weave-ipam /etc/cni/net.d/10-weave.conflist
Test CNI plugin
Running on localhost: sudo mkdir -p /opt/cni/bin
Weave on localhost:2375: setup-cni
Weave on localhost:2375: launch
7ddcd31e8a63473b58d83c09a8918c5bbc0feee7f64040e9a6700631257dbba2
Docker on localhost:2375: run --net=none --name=c0 -dt alpine /bin/sh
Docker on localhost:2375: run --net=none --privileged --name=c1 -dt alpine /bin/sh
Docker on localhost:2375: run --net=none --name=c2 -dt alpine /bin/sh
Docker on localhost:2375: run --net=none --name=ch0 -dt alpine /bin/sh
Docker on localhost:2375: run --net=none --name=ch1 -dt alpine /bin/sh
Docker on localhost:2375: run --net=none --name=ch2 -dt alpine /bin/sh
net.ipv4.conf.all.arp_accept = 1
Docker on localhost:2375: inspect -f {{.State.Pid}} c0
Docker on localhost:2375: inspect -f {{.Id}} c0
Running on localhost: sudo CNI_COMMAND=ADD CNI_CONTAINERID=84f55149129a23980253b5b7e34ca7070be7611d24e264d6178461848a0d9b17 CNI_IFNAME=eth0 CNI_NETNS=/proc/3320277/ns/net CNI_PATH=/opt/cni/bin /opt/cni/bin/weave-net
{
    "ip4": {
        "ip": "<IP_ADDRESS>/12",
        "gateway": "<IP_ADDRESS>"
    },
    "dns": {}
}Docker on localhost:2375: inspect -f {{.State.Pid}} c1
Docker on localhost:2375: inspect -f {{.Id}} c1
Running on localhost: sudo CNI_COMMAND=ADD CNI_CONTAINERID=d36df517afbe134c6b3b16a54c5bee33482825f939b5168fb560d289a8a60fdd CNI_IFNAME=eth0 CNI_NETNS=/proc/3320334/ns/net CNI_PATH=/opt/cni/bin /opt/cni/bin/weave-net
{
    "ip4": {
        "ip": "<IP_ADDRESS>/12",
        "gateway": "<IP_ADDRESS>"
    },
    "dns": {}
}Docker on localhost:2375: inspect -f {{.State.Pid}} c2
Docker on localhost:2375: inspect -f {{.Id}} c2
Running on localhost: sudo CNI_COMMAND=ADD CNI_CONTAINERID=2421f061c5d7cd8c1165affa9cd6de1a4934cad2e5a30aab47381044a10083bf CNI_IFNAME=eth0 CNI_NETNS=/proc/3320402/ns/net CNI_PATH=/opt/cni/bin /opt/cni/bin/weave-net
{
    "ips": [
        {
            "version": "4",
            "address": "<IP_ADDRESS>/12"
        }
    ],
    "routes": [
        {
            "dst": "<IP_ADDRESS>/12"
        }
    ],
    "dns": {}
}Docker on localhost:2375: inspect -f {{.State.Pid}} ch0
Docker on localhost:2375: inspect -f {{.Id}} ch0
Running on localhost: sudo CNI_COMMAND=ADD CNI_CONTAINERID=2cb4dba09753e6169a7f2abdf96ebefadad83cabb4e462c45fd5b931cbee9a05 CNI_IFNAME=eth0 CNI_NETNS=/proc/3320463/ns/net CNI_PATH=/opt/cni/bin /opt/cni/bin/weave-net
{
    "ip4": {
        "ip": "<IP_ADDRESS>/12",
        "gateway": "<IP_ADDRESS>"
    },
    "dns": {}
}Docker on localhost:2375: inspect -f {{.State.Pid}} ch1
Docker on localhost:2375: inspect -f {{.Id}} ch1
Running on localhost: sudo CNI_COMMAND=ADD CNI_CONTAINERID=86bc28f08ca70653c81bb2b86c598999a0f2fddf062ad76af5696df0ce404974 CNI_IFNAME=eth0 CNI_NETNS=/proc/3320520/ns/net CNI_PATH=/opt/cni/bin /opt/cni/bin/weave-net
{
    "ip4": {
        "ip": "<IP_ADDRESS>/12",
        "gateway": "<IP_ADDRESS>"
    },
    "dns": {}
}Docker on localhost:2375: inspect -f {{.State.Pid}} ch2
Docker on localhost:2375: inspect -f {{.Id}} ch2
Running on localhost: sudo CNI_COMMAND=ADD CNI_CONTAINERID=a0f9b4b1a3580cbb6025cb48d549a067803c1f57f7df7b45a32f9f4d770a1e1c CNI_IFNAME=eth0 CNI_NETNS=/proc/3320577/ns/net CNI_PATH=/opt/cni/bin /opt/cni/bin/weave-net
{
    "ip4": {
        "ip": "<IP_ADDRESS>/12",
        "gateway": "<IP_ADDRESS>"
    },
    "dns": {}
}Weave on localhost:2375: ps c0
Weave on localhost:2375: ps c1
Weave on localhost:2375: ps c2
Weave on localhost:2375: ps weave:expose
.......Docker on localhost:2375: rm -f c2
c2
Docker on localhost:2375: run --net=none --name=c3 -dt alpine /bin/sh
Docker on localhost:2375: inspect -f {{.State.Pid}} c3
Docker on localhost:2375: inspect -f {{.Id}} c3
Running on localhost: sudo CNI_COMMAND=ADD CNI_CONTAINERID=e21ed597f48ba3aa3f323fea344621d594c502c84f341dadecdb8966811d52b6 CNI_IFNAME=eth0 CNI_NETNS=/proc/3321708/ns/net CNI_PATH=/opt/cni/bin /opt/cni/bin/weave-net
{
    "ip4": {
        "ip": "<IP_ADDRESS>/12",
        "gateway": "<IP_ADDRESS>"
    },
    "dns": {}
}Weave on localhost:2375: ps c3
..........
all 17 tests passed in 14.710s.```

Also note the first thing each test suite does is `rm -f` every container on the host.

@bboreham OK, thanks for the pointers, will do that and ping you when ready.

@bboreham OK, thanks for the pointers, will do that and ping you when ready.

@bboreham thanks to the tips on how to run tests locally, I am able to run the test suite now! I started adding a test for this functionality, but when running HOSTS=localhost ./test/880_cni_plugin_ip_address_assignment_test.sh -v, it errors with:
Running on localhost: sudo CNI_COMMAND=ADD CNI_CONTAINERID=d682738721b9f73e39482be6486164bb3a42d4b7d219fe1d5d91bf8d26a8ae18 CNI_IFNAME=eth0 CNI_NETNS=/proc/145243/ns/net CNI_PATH=/opt/cni/bin /opt/cni/bin/weave-net
{
    "code": 100,
    "msg": "unable to allocate IP address for bridge: 400 Bad Request: Unable to claim: address <IP_ADDRESS>/32 is already owned by d682738721b9f73e39482be6486164bb3a42d4b7d219fe1d5d91bf8d26a8ae18\n"
}

Not sure why we are not able to claim that address. I checked the following places:

docker logs weave doesn't explain the error
c0, c1 and c2 have only lo iface.

I also rebased the PR onto latest master as it was quite outdated.

@bboreham thanks to the tips on how to run tests locally, I am able to run the test suite now! I started adding a test for this functionality, but when running HOSTS=localhost ./test/880_cni_plugin_ip_address_assignment_test.sh -v, it errors with:
Running on localhost: sudo CNI_COMMAND=ADD CNI_CONTAINERID=d682738721b9f73e39482be6486164bb3a42d4b7d219fe1d5d91bf8d26a8ae18 CNI_IFNAME=eth0 CNI_NETNS=/proc/145243/ns/net CNI_PATH=/opt/cni/bin /opt/cni/bin/weave-net
{
    "code": 100,
    "msg": "unable to allocate IP address for bridge: 400 Bad Request: Unable to claim: address <IP_ADDRESS>/32 is already owned by d682738721b9f73e39482be6486164bb3a42d4b7d219fe1d5d91bf8d26a8ae18\n"
}

Not sure why we are not able to claim that address. I checked the following places:

docker logs weave doesn't explain the error
c0, c1 and c2 have only lo iface.

I also rebased the PR onto latest master as it was quite outdated.

weave status ipam shows all IPs are available:

It shows that all but 1 are available ("1 active").
weave ps should tell you where that IP is in use, or curl <IP_ADDRESS>:6784/ip

weave status ipam shows all IPs are available:

It shows that all but 1 are available ("1 active").
weave ps should tell you where that IP is in use, or curl <IP_ADDRESS>:6784/ip

I've added a test and it is passing locally. @bboreham could you also trigger the remote CI, just to make sure that I haven't messed up the setup phase while testing locally?
The test creates 3 containers with static IPs, and makes sure that these containers can see each other, and that they can't access the open internet.
For some reason weave:expose is calling claim.Try() (discussed above in a comment), and I imagine there is a proper way to handle that case, so this might need adjustment.

I've added a test and it is passing locally. @bboreham could you also trigger the remote CI, just to make sure that I haven't messed up the setup phase while testing locally?
The test creates 3 containers with static IPs, and makes sure that these containers can see each other, and that they can't access the open internet.
For some reason weave:expose is calling claim.Try() (discussed above in a comment), and I imagine there is a proper way to handle that case, so this might need adjustment.

I think your main problem is you left in all sorts of logic from the other test, including BRIP=$(container_ip $HOST1 weave:expose) which is allocating an address for the bridge.
Strip it down to just what you mean to test.

I think your main problem is you left in all sorts of logic from the other test, including BRIP=$(container_ip $HOST1 weave:expose) which is allocating an address for the bridge.
Strip it down to just what you mean to test.

Sorry, changed my mind, that line wouldn't do a PUT with a specific IP.
I do recommend you strip down the test, but you'd need to find out where that PUT is coming from.

Sorry, changed my mind, that line wouldn't do a PUT with a specific IP.
I do recommend you strip down the test, but you'd need to find out where that PUT is coming from.

Could you check if you have a pre-existing address on the weave bridge?
Like ip addr show dev weave.
You may want to do weave reset --force before running the test, to clear all that down.
(This is probably a bug in test/config.sh)

Could you check if you have a pre-existing address on the weave bridge?
Like ip addr show dev weave.
You may want to do weave reset --force before running the test, to clear all that down.
(This is probably a bug in test/config.sh)

Could you check if you have a pre-existing address on the weave bridge?
Like ip addr show dev weave.
You may want to do weave reset --force before running the test, to clear all that down.
(This is probably a bug in test/config.sh)

I am getting the same behaviour after doing a weave reset --force - weave:expose still tries to claim the IP that is owned by a container.
This happens at:
cni_connect $HOST1 c0 <<EOF
...
EOF

It is reproducible only with one container and no bridge.

Could you check if you have a pre-existing address on the weave bridge?
Like ip addr show dev weave.
You may want to do weave reset --force before running the test, to clear all that down.
(This is probably a bug in test/config.sh)

I am getting the same behaviour after doing a weave reset --force - weave:expose still tries to claim the IP that is owned by a container.
This happens at:
cni_connect $HOST1 c0 <<EOF
...
EOF

It is reproducible only with one container and no bridge.

I suspect the problem is happening here:  https://github.com/weaveworks/weave/blob/34de0b10a69c2fa11f2314bfe0e449f739a96cd8/plugin/net/cni.go#L98
This part of the CNI plugin wants to set up a gateway address on the bridge so that egress traffic can be routed back into the Weave network. So it calls the IP allocator, with the same CNI config, so it will get an address in the correct subnet.  Your new code sees ips field and hands back the IP that you wanted to be allocated for the first container.
I cannot see a simple fix retaining all existing behaviour; that code is deliberately not parsing the config because it wants to be independent of whatever ipam the caller has configured.  Maybe we could add another ipam config to be used for gateway address allocation?
I can get your test to otherwise pass by adding weave_on $HOST1 expose before any CNI calls, so the bridge already has an IP when the plugin looks for it.


feature(api): add external logging

Add support for Log Service Management API (https://fivetran.com/docs/rest-api/log-service-management)
Add Metadata API and Roles API Data Sources

Merge main - it's about fixing conflicts via Github UI


change ordering of suffixes

The ordering of suffixes is inconsistent with the behaviour of other components. This change brings it into compliance.

84e35103b7389bffabfe1757081c7a444872cca6 was merged to develop in #208.


cdc: Exponentialize resolved ts scan backoff

What is changed and how it works?

Issue Number: Close #15112
What's Changed:

Make the scan task retry wait time exponential, so that less logs will be produced.

Related changes
Check List
Tests

Unit test
Integration test

Side effects
N/A
Release note
None

/merge

Actually, it's not about CDC but resolved_ts that is relied by stale read and flashback. 😂

/cherry-pick release-7.1


Update ziti router

@dariuszSki Thanks for this! I only took a quick look at this so far and noticed:

Not certain this is relevant in this case, but when possible do use git mv to rename a file so that the changes will be evident in the diff
In this case destinations like /docs/manage/router-overview need to be preserved because there was already an article published to that path, so you could avoid renaming the Markdown file or you could update your branch from main to see the new HTTP redirects that were added in docusaurus.config.js and add one there for the relocated file
there's an unresolved conflict with 03-components.md

Sure, I did not expect this version to be merged as is. Just wanted feedback using this PR,  so please review it if you can. I am open to m make this better.  I am already in the process of splitting the content into sub MD files. There is too much information crammed into one MD file.

I see what happened here, the components folder structure changed since my last sync and now it is out of sync.  Probably better coordination is required when major changes are done to the structure of the folders and files.

It's referenced from 01-overview.md and 03-components.md now.  I think we should have specific pages for each of those components. I see you're expanding on the components, but i think we'd like to keep the _components.md small for now so that the overview page doesn't get too much busier. If it makes sense, I could see moving the 'overview' type stuff to the overview (the existing content) then expanding on them like you are in the 03-components.md.  That or maybe add the extra details you are in a whole new router-focused md?

see new PR https://github.com/openziti/ziti-doc/pull/229, closing this one


Using highlight.js with React.js

I am trying to configure highlightjs in a reactjs application to detect and highlight json. But it doesn't work, any workaround ? I need it on the browser side btw.

To suggest any "workaround" we need to know what was the problem :-) Can you provide any example that does not work?

@Sannis thanks for the quick response, my bad.
In my index.html
<link rel="stylesheet" href="//cdnjs.cloudflare.com/ajax/libs/highlight.js/8.4/styles/default.min.css">

In my react component
var Pretty = React.createClass({
    render: function() {
        return
{JSON.stringify(this.props.json, null, 2)}
;
    }
});

But it isn't highlighting.

I tried with class and className as well. No luck.

hljs.initHighlightingOnLoad(); higlights code on page once after page is loaded.
If you need highlight dinamically loaded content - this is your responsability. We provide hljs.highlight() method for that, so you can include it to React.js render callback. I also think that React.js should provide some post-render events that you can listen and highlight rendered block there.

hljs.initHighlightingOnLoad(); higlights code on page once after page is loaded.

@Sannis thanks a lot. Its solved now. In fact I called hljs.initHighlightingOnLoad(); when the page has been loaded but I did not wait for that particular component to load.

I also think that React.js should provide some post-render events that you can listen and highlight rendered block there.

React provides this, just for future reference
var Pretty = React.createClass({
    componentDidMount: function(){
        hljs.initHighlightingOnLoad();
        var current = React.findDOMNode(this);
        hljs.highlightBlock(current);
    },
    render: function() {
        return
{JSON.stringify(this.props.json, null, 2)}
;
    }
});

Let me know if there is a better way to do this. Thanks a lot.

Great! Unfortunately, I'm not familiar with react to suggest something better. But it looks like you do double work in componentDidMount.

Ohh okay I just realised that for some reason hljs.initHighlightingOnLoad(); doesn't do anything at all. So finally its
componentDidMount: function(){
    var current = React.findDOMNode(this);
    hljs.highlightBlock(current);
 }

Ohh okay I just realised that for some reason hljs.initHighlightingOnLoad(); doesn't do anything at all.

What it does is binds itself to the onload event of the browser which by that moment has probably already been fired. highlightBlock() is the main method anyway.

For anyone (like me) who finds this issue: https://github.com/akiran/react-highlight
:-)

/**

REACT IMPORT
*/
import React from 'react'

/**

HIGHLIGHT IMPORT
*/
import hljs from 'highlight.js'
import javascript from 'highlight.js/lib/languages/javascript'
import '../../node_modules/highlight.js/styles/darcula.css'

/**

ENABLE FUNCTION
*/
hljs.registerLanguage('javascript', javascript)

/**

COMPONENT
*/
export class Highlighter extends React.PureComponent {

componentDidMount(){
hljs.highlightBlock(this.node)
}
render() {
let { children } = this.props
return (

 this.node = node}
>

{children}

)
}
}
export default Highlighter

import React from 'react'
import hljs from 'highlight.js'
import javascript from 'highlight.js/lib/languages/javascript'
import '../../node_modules/highlight.js/styles/darcula.css'
hljs.registerLanguage('javascript', javascript)

export class Highlighter extends React.PureComponent {

  componentDidMount(){
    hljs.highlightBlock(this.node)
  }

  render() {
    let { children } = this.props
    return (

 this.node = node}
      >

          {children}

    )
  }
}

export default Highlighter

<Highlighter>
     {'function(){let test = [\'test\', \'test 2\']}'}
</Highlighter>

For anyone (like me) who finds this issue: https://github.com/akiran/react-highlight
:-)

this library has a lot of side effects.

@f

For anyone (like me) who finds this issue: https://github.com/akiran/react-highlight
:-)

this library has a lot of side effects.

@Farhad33 Like what? I'm very interested to know being that I just incorporated it into my project.

For anyone (like me) who finds this issue: https://github.com/akiran/react-highlight
:-)

this library has a lot of side effects.

@Farhad33 Like what? I'm very interested to know, being that I just incorporated this package into my project.

For anyone (like me) who finds this issue: https://github.com/akiran/react-highlight
:-)

this library has a lot of side effects.

@Farhad33 Like what? I'm very interested to know, being that I just incorporated this package into my project.

I have already experienced unstable DOMExceptions with this library and seen these errors posted as issues but unanswered...

For everyone who didn't find any working answer above.
React: 16.8.2 working example:
import hljs from "highlight.js";
import "./dracula.css";

class Preview extends Component {
  componentDidMount() {
    this.updateCodeSyntaxHighlighting();
  }

  componentDidUpdate() {
    this.updateCodeSyntaxHighlighting();
  }

  updateCodeSyntaxHighlighting = () => {
    document.querySelectorAll("pre code").forEach(block => {
      hljs.highlightBlock(block);
    });
  };

  render() {
    return (

    );
  }
}

Note that updateCodeSyntaxHighlighting should be in componentDidMount and componentDidUpdate methods in every component which use
... tags.

I have a slightly different solution that registers only the language you actually need by importing them once.
React 16.8.2:
import React, { Component } from 'react';
import PropTypes from 'prop-types';
import hljs from 'highlight.js/lib/highlight';   // import hljs library
import 'highlight.js/styles/hopscotch.css';      // import your preferred style

const registeredLanguages = {};   // keep a record of registered languages

export class CodeHighlight extends Component {
    constructor(props) {
        super(props);
        // do not show anything until language is loaded
        this.state = { loaded: false };
        // create a ref to highlight only the rendered node and not fetch all the DOM
        this.codeNode = React.createRef();
    }

    componentDidMount() {
        const { language } = this.props;
        if (language && !registeredLanguages[language]) {
            try {
                const newLanguage = require(`highlight.js/lib/languages/${language}`);
                hljs.registerLanguage(language, newLanguage);
                registeredLanguages[language] = true;
                this.setState(
                    () => { return { loaded: true }; },
                    () => { this.highlight(); }
                );
            } catch (e) {
                console.error(e);
                throw Error(`Cannot register and higlight language ${language}`);
                // We can alternatively set loaded to true and show an error message in the
                // code block instead of children, or just show the children without highlight.
                // This would be an improvement or an optional behavior given a special prop.
            }
        } else {
            this.setState({ loaded: true });
        }
    }

    componentDidUpdate() {
        this.highlight();
    }

    highlight = () => {
        this.codeNode && this.codeNode.current && hljs.highlightBlock(this.codeNode.current);
    }

    render() {
        const { language, children } = this.props;
        const { loaded } = this.state;
        if (!loaded) return ''; // or show a loader

        return

            {children}

;
    }
}

CodeHighlight.propTypes = {
    children: PropTypes.node.isRequired,
    language: PropTypes.string,
};
// optionally set the language you think will use most as a default value
// if you don't set this, I would encourage to make language prop required,
// or at least improve the "else" statement in "componentDidMount"
CodeHighlight.defaultProps = {
    language: 'javascript',
};

Usage:
// Use the default language, if set
<CodeHighlight>
    {JSON.stringify(myObject, null, 4)}
</CodeHighlight>

// Specify a language
<CodeHighlight language="python">
    {JSON.stringify(myObject, null, 4)}
</CodeHighlight>

Witaj @twistezo and ciao @vittoriozamboni
Do your codes support third-party languages like https://github.com/highlightjs/highlightjs-cypher?

Sure. Just import and register the 3rd party grammar after you import the main library.

WItaj @twistezo, ciao @vittoriozamboni and hello @yyyc514 !
Thank you, I have just updated the repo's README, adding React instruction.

After struggling for some time with these solutions, I stumbled across the highlightAuto method, which is designed for generating the highlights server-side, but it worked very nicely in a functional component.
import React from "react";
import hljs from "highlight.js"; // import hljs library

export function Highlighter(content: string): JSX.Element {
    const highlighted = hljs.highlightAuto(content)

    return (

    );
}

Or highlight if the component was aware of the language, etc... those are the two API calls for doing slightly more "manual" integrations, like building a component for a framework.

Thanks for making me aware of the highlight method, it's much faster. I updated the component.

it's much faster.

It should be, but most shouldn't notice unless you're highlighting a LOT of code.

@ExtraHash Thanks for the brilliant solution! I was looking for a simple hljs component to use with Next.js and your snippet did the trick. 🙏 I removed the className="hljs" attribute on  since the
 tag already has hljs className.
import React from "react";
import hljs from "highlight.js";

interface HighlighterProps {
  content: string;
  language?: string;
}

export default function Highlighter({
  content,
  language,
}: HighlighterProps): JSX.Element {
  const highlighted = language
    ? hljs.highlight(language, content)
    : hljs.highlightAuto(content);

  return (

  );
}


Added reuseable functional test

TL;DR

Added functional test in re useable workflow

Boilerplate Changes are in progress https://github.com/flyteorg/boilerplate/pull/52/files
Flytetool Reuseable workflow changes: https://github.com/flyteorg/flytetools/pull/48
Test: https://github.com/flyteorg/flyteadmin/actions/runs/1837582728
Type

[ ] Bug Fix
[x] Feature
[ ] Plugin

Are all requirements met?

[ ] Code completed
[ ] Smoke tested
[ ] Unit tests added
[ ] Code documentation added
[ ] Any pending items have an associated Issue

Complete description
How did you fix the bug, make the feature etc. Link to any design docs etc
Tracking Issue
Remove the 'fixes' keyword if there will be multiple PRs to fix the linked issue
fixes https://github.com/flyteorg/flyte/issues/
Follow-up issue
NA
OR
https://github.com/flyteorg/flyte/issues/

Can we also have a variation which uses flytectl along with flyte-remote for executing launchplans

@pmahindrakar-oss Current functional test script use flyte remote for execution


bsDateTimePicker is null

I followed the readme:
npm install ember-bootstrap-datetimepicker --save-dev
ember g ember-bootstrap-datetimepicker

And put in a {{bs-datetimepicker date=mydate format='YYYY-MM-DD'}}.
But I get this in the JS console:
Uncaught TypeError: undefined is not a function

Which comes from here, and sure enough if I put in a break point and this.get('bsDateTimePicker'), it's null. Any ideas?

+1
I got the same error here, @dukedave are you using ember-cli?

@rafaeliga yep, 0.1.5.
FWIW I've switched to https://github.com/edgycircle/ember-pikaday, which works fine.

@dukedave thanks for your tip! but I need one with time picker...

I had the same problem, it's caused by the new version of bootstrap-datetimepicker.
I just opened a pull request to fix it

I just released v0.2.8 where I updated to eonasdan-bootstrap-datetimepicker to 4.0.0. This should fix this error.

thanks @claudiocro !!!

I'm gona close this issue. It should be fixed


Splicing Localization Issue

Thanks for your awesome work and open-sourcing. However, I cannot reproduce the localization cIoU or mAP as the paper. Specifically, on Columbia dataset, I can only obtain 0.76 cIoU, where the number in paper is 0.98. Could you please provide some generated "pred['ms']" demo for  checking? E.g., release the "pred['ms']" for the "canong3_canonxt_sub_03.tif" file, where my generated one is:

In addition, I also tried to reproduce the localization over DSO dataset, e.g., the pred['ms'] of the file "splicing-40" is as follow, which is much worse than that on the Fig. 9 first row of the appendix.

Hi, thank you for trying out our model! It seems that the model I uploaded is a bit undertrained ( trained for 48k steps, while as said in the paper the full model is trained for ~73k steps). Sadly, the original full model and data are accidentally auto-cleaned by cluster due to long-time no access.  To make up, I uploaded another full model that is trained for 75k steps in another 1.5M random sample of yfcc100m dataset. Qualitatively its performance is extremely similar to original full model, quantitatively there is a little difference, perhaps due to variance of training data.
Specifically, the performance for this version of full model in Columbia and DSO is as follows:
Columbia: mAP: 0.93  cIoU: 0.88
DSO:           mAP: 0.65  cIoU: 0.80
Since this is now the only available full model that we have and can prove the performance, we will update the performance table in Arxiv. Sorry for the inconvenience that caused to you! If there are further questions, don't hesitate to ask.
Again, thank you for discovering this issue!

Thank you for your reply and answering this issue. Great work again!


Hawaiian Cities

So, I noticed this a while ago, but never mentioned it til now...there are barely any cities on the Hawaiian map. The only 3 are Honolulu, Bradshaw AAF, and Kamuela/Waimea, and the last one only shows up if the location is Lihue. My suggestion is to get rid of Kamuela/Waimea, then add the new cities on the map.

That would make the Hawaiian Regional Map a lot more informational.

I decreased the distance of the allowable cities for HW which in turn will display more in the regional maps.
This issue is fixed in version 1.37


espresso is not responsive

Hi Greg,
First, thanks for sharing this work in progress.  I'm excited to give it a go.
So, I've just tried to follow your installation instructions, but the result when I try and execute "./espresso --help" is "Illegal instruction."  I'm not quite sure what's going on there.  I have tried versions 0.2.3 - 0.2.5.
FWIW, I should add that I am running this on a Pi zero for now, despite your advice.  I don't have a 4 on me.  My hope is that, even if it doesn't run optimally on a zero, it will run.

Closing unless further information needed


Fetch canonical compressed in parallel

Further improvement of #34

Now we'll see if SSL handshake overhead per requests kills this :D
On Tue, May 30, 2023, 13:13 Christian Tschugg @.***>
wrote:

Further improvement of #34
https://github.com/badlogic/heissepreise/issues/34
You can view, comment on, or merge this pull request online at:
https://github.com/badlogic/heissepreise/pull/42
Commit Summary

0f5a08d
https://github.com/badlogic/heissepreise/pull/42/commits/0f5a08d72386132f4721bedcccf8da2625fe0439
Fetch canonical compressed in parallel

File Changes
(4 files https://github.com/badlogic/heissepreise/pull/42/files)

M .gitignore
https://github.com/badlogic/heissepreise/pull/42/files#diff-bc37d034bad564583790a46f19d807abfe519c5671395fd494d8cce506c42947
(2)
M analysis.js
https://github.com/badlogic/heissepreise/pull/42/files#diff-7d499aa37431ffe3fd99b028e445afc7df97767327f00db09cef8620beb313eb
(2)
M index.js
https://github.com/badlogic/heissepreise/pull/42/files#diff-e727e4bdf3657fd1d798edcd6b099d6e092f8573cba266154583a746bba0f346
(5)
M site/utils.js
https://github.com/badlogic/heissepreise/pull/42/files#diff-e3f40e1f9dc0e0204c3ccb3f435cebf34bef60d420c763ae3a7fad275a5eb59c
(21)

Patch Links:

https://github.com/badlogic/heissepreise/pull/42.patch
https://github.com/badlogic/heissepreise/pull/42.diff

—
Reply to this email directly, view it on GitHub
https://github.com/badlogic/heissepreise/pull/42, or unsubscribe
https://github.com/notifications/unsubscribe-auth/AAD5QBE6ELN43TFARZRDB5LXIXI37ANCNFSM6AAAAAAYT3GKHI
.
You are receiving this because you are subscribed to this thread.Message
ID: @.***>

http1 might need a keep-alive header
http2 should handle it AFAIK

My server config is bad and I should feel bad :(

Also, each stores file size varies heavily, which diminishes the returns. Equally sized files would probably help quite a bit.
 I'm tempted to revert it :p

Welp. Unfucking my server config is a lot of work.

I will see a revert I guess 😂

Please don't hate me. That's what you get for working on spaghetti OSS!

Try setting the keep-alive headers in the index.js
  const server = app.listen(port, () => {
    console.log(`Example app listening on port ${port}`)
  });
  server.keepAliveTimeout = 30 * 1000;
  server.headersTimeout = 35 * 1000;

I'm not using the Express server in that deployment. I just serve static
files through Nginx, which itself is behind a reverse proxy. Which makes it
even more hilarious how slow it is. I'll figure it out on my end, let's
keep the change.
On Tue, May 30, 2023, 14:11 Christian Tschugg @.***>
wrote:

Try setting the keep-alive headers in the index.js
const server = app.listen(port, () => {
console.log(Example app listening on port ${port})
});
server.keepAliveTimeout = 30 * 1000;
server.headersTimeout = 35 * 1000;
—
Reply to this email directly, view it on GitHub
https://github.com/badlogic/heissepreise/pull/42#issuecomment-1568325533,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AAD5QBGEQMNQCH5OFVEJ6HLXIXPXLANCNFSM6AAAAAAYT3GKHI
.
You are receiving this because you modified the open/close state.Message
ID: @.***>

in that case you should definitely use http2 and push the assets from the server to increase the speed 😆
server {
  listen 443 ssl http2;

  location /index.html {
    http2_push /styles.css;
    http2_push /utils.js;
    http2_push /latest-caninical.billa.compressed.json;
    http2_push /latest-caninical.dm.compressed.json;
    http2_push /latest-caninical.hofer.compressed.json;
    http2_push /latest-caninical.lidl.compressed.json;
    http2_push /latest-caninical.mpreis.compressed.json;
    http2_push /latest-caninical.spar.compressed.json;
    http2_push /latest-caninical.unimarkt.compressed.json;
    http2_push /alasql.js;
    http2_push /chart.js;
    http2_push /main.js;
  }
}


Add setup.sh script improvements

setup.sh should work if autoconf is installed to autoconf or autoconf-.
allow PREFIX and ROOT to be specified.
make sure we have everything we need before attempting to build.

Cool


Exception behavior, structure changes missing

Hello, can you please add information about structure and behavior changes going from EF6 to EF Core?
Thank you

Document Details
⚠ Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.

ID: 9cbb86f3-378b-e83d-56c3-c0532192bd13
Version Independent ID: c96b2fcb-8af0-f05b-e188-a6c59dd9f428
Content: Porting from EF6 to EF Core - EF
Content Source: entity-framework/efcore-and-ef6/porting/index.md
Product: entity-framework
Technology: entity-framework-core
GitHub Login: @ajcvickers
Microsoft Alias: avickers

Differences in areas like this are common since EF Core is a new codebase and has an entirely different internal implementation and provider model. The type of inner exception and how it is structured is also up to the implementing provider, and so isn’t something we could likely document in a general way for EF Core.
You should think of porting from EF6 to EF Core as porting to a new product, not a new version. As such you should expect to test extensively to ensure things like this are caught. (No pun intended.)


Particles cause rendering corruption on Samsung devices with Chrome)

Project: https://playcanvas.com/editor/scene/1198009
Video (Samsung S7 (Chrome 91.0) on the left, Google Pixel 2 XL (Chrome 91.0) on the right)
https://user-images.githubusercontent.com/16639049/126500059-11bdb0c9-9c05-4896-b6dd-2df108e56bcd.mp4
This only happens (so far) if device pixel ratio is enabled and only with particles. It looks related to the lifetime of the particle which is at 1 sec.
Tried browser stack with Samsung S20+ which shows a similar issue. I believe that it's actually doing the same thing as the S7 above but the video compression from Browser Stack to remote screen is making it 'blocky' and screen tearing. The video framerate/compression is not keeping up with the flickering effect shown above on the S7:
https://user-images.githubusercontent.com/16639049/126500321-544b749b-a26c-4c2e-87a9-06621a7daca9.mp4
Nothing shown on the browser log

Data point, user reported no issues on a Samsung S9


Support parse inner scope function

Currently, parse a closure function in non-global scope will lead to indentation error.
def some_process():
    def myfunc()
        pass
    sync.to_ast(myfunc, myprinter)

This PR try detect closure function by indentation of the first line. Then it wraps the code to make py_ast work normally, and lastly fixes the return structure.

Thanks for the contribution! I encountered this issue before but didn't have expertise working on synr.
CC: @tkonolige @Hzfengsy @spectrometerHBH

Thank you for submitting a PR. However, the correct way to handle this would be to remove leading spaces from the first line of the source program and then remove the same amount of spaces from all subsequent lines. You'd need to add a start_column parameter to the Compiler class and flow this through to span_from_ast.

Hi, I re-push the code which works by removing leading spaces as the advice.  Can you kindly take a review on it?  @tkonolige

Thank you @wrongtest!


Generated files

Currently, when the plugin is activated it generates a _settings.less and flexicons.less.
Need a better way to handle these files. They currently are in the .gitignore as when the plugin receives updates, it should not override the users settings.

I made some progress towards this. The caveat to my change is now I need a way to handle merging existing user settings along with new default settings/icons when the package updates.


[webview_flutter] Fix platform exception on iOS 14+ when evaluating any JavaScript that evaluates to null or undefined.

Currently, a PlatformException is thrown whenever evaluateJavascript is run for any JavaScript that evaluates to null or undefined.
This is due to (I assume to be) a regression in webkit's evaluateJavascript function, which no longer supports null or undefined for the given JavaScript to evaluate to, as of iOS 14. (Still tested working on iOS 11.4 and 12.4)
This PR attempts to fix this problem by instead evaluating JavaScript using callAsyncJavaScript on iOS 14+.
Relevant issue:

flutter/flutter#66318

Pre-launch Checklist

[x] I read the [Contributor Guide] and followed the process outlined there for submitting PRs.
[x] I read the [Tree Hygiene] wiki page, which explains my responsibilities.
[x] I read and followed the [relevant style guides] and ran [the auto-formatter]. (Note that unlike the flutter/flutter repo, the flutter/plugins repo does use dart format.)
[x] I signed the [CLA].
[x] The title of the PR starts with the name of the plugin surrounded by square brackets, e.g. [shared_preferences]
[x] I listed at least one issue that this PR fixes in the description above.
[x] I updated pubspec.yaml with an appropriate new version according to the [pub versioning philosophy].

NOTE: I have marked this as a patch. However, iOS will now always return "null" for both null and undefined to match the Android side's behavior, rather than "(null)" for null and "<null>" for undefined. I am not entirely certain if this should be considered a breaking change.

[x] I updated CHANGELOG.md to add a description of the change.
[x] I updated/added relevant documentation (doc comments with ///).
[x] I added new tests to check the change I am making or feature I am adding, or Hixie said the PR is test exempt.
[x] All existing and new tests are passing.

Superseded by #4401


incorrect controller input logos

I have my controller plugged in and enabled 4 controllers. it shows 2, "player 2 xbox" logos. ik this is a local thing and stuff but it confused meat first.

I refreshed it and now it shows 2 player 4 xbox 😂😂😂🤣🤣🤣

That is Microsoft, not Soda. Also it is unimportant, just a visual hint that does not affect the actual behaviour of gamepads.
Anyway, it is patched in v.1.0.2 already. I'm closing the issue.


JUnit5 assertThrows OptionTest

Hi @nhojpatrick
Please rebase on master and implement your FIXME items.

FYI what really needs help with JUnit 5 is Commons VFS... ;-)

Codecov Report

Merging #140 (f8d89e1) into master (4076cc4) will not change coverage.
The diff coverage is n/a.

@@            Coverage Diff            @@
##             master     #140   +/-   ##
=========================================
  Coverage     93.20%   93.20%
  Complexity      567      567
=========================================
  Files            21       21
  Lines          1206     1206
  Branches        214      214
=========================================
  Hits           1124     1124
  Misses           46       46
  Partials         36       36

:mega: We’re building smart automated test selection to slash your CI/CD build times. Learn more

@garydgregory rebased and updated for Java 8.


Use circe-derivation, fix tests

This PR does five things: updates some miscellaneous versions, switches to circe-derivation for 2.11 and 2.11 (which is actually almost 10% faster than the manual definition for decoding, because it avoids flatMap), fixes some tests that either weren't there or were broken, changes the Jackson benchmarks to follow the same definitions as the others, and adds new circe-jackson benchmarks.

Codecov Report

Merging #19 into master will decrease coverage by 1.69%.
The diff coverage is 43.75%.

@@            Coverage Diff            @@
##           master      #19     +/-   ##
=========================================
- Coverage   86.15%   84.45%   -1.7%
=========================================
  Files          12       14      +2
  Lines         130      148     +18
=========================================
+ Hits          112      125     +13
- Misses         18       23      +5

Impacted Files
Coverage Δ

...n/scala/io/circe/benchmarks/CirceDefinitions.scala
0% <0%> (-100%)
:arrow_down:

...la-2.10/io/circe/benchmarks/CirceDefinitions.scala
0% <0%> (ø)

...scala/io/circe/benchmarks/JacksonDefinitions.scala
100% <100%> (+61.53%)
:arrow_up:

...la-2.12/io/circe/benchmarks/CirceDefinitions.scala
100% <100%> (ø)

.../scala/io/circe/benchmarks/Json4sDefinitions.scala
100% <0%> (+33.33%)
:arrow_up:

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 4e9e97f...48ef6ac. Read the comment docs.