ROS Gazebo black screen

Following this tutorial I managed to run ros on wsl with ubuntu 16.04 and Microsoft Windows [Version 10.0.17134.112]. However when launching gazebo with VcXsrv it gives a black screen where you should see the 3d model of the robot, but the rest of the UI is there and there is no error in the console.
I know WSL is supposed to be for command line tools, but there have been a few issues related to using gui apps through x server that have been resolved here.
I created this issue after reading #1450 where it was suggested to create a new issue for this.

@IceSentry
vcxsrv.exe :0 -ac -terminate -lesspointer -multiwindow -clipboard ...
vcxsrv.exe :0  - display :0

@therealkenc it was asked on gazebo answer http://answers.gazebosim.org/question/16888/gazebo-on-wsl-bash-for-windows/ which is actually how I came to the original issue on github.
 Although on my version of vcxsrv I don't see a native opengl checkbox. I use vcxsrv <IP_ADDRESS> from sourceforge
@Voskrese I have no idea what you want me to do

glxgears gives me about 650 fps on vcxsrv 1.20 in native OpenGL mode on a comparatively slow Intel HD 4000 laptop GPU, about 1500 fps on an Intel HD 620 (two slow generations later)
You can enable OpenGL mode on the vcxsrv side by running XLaunch; this will take you through a wizard which on its last page refers to the LIBGL_ALWAYS_INDIRECT environment variable (export LIBGL_ALWAYS_INDIRECT=1)
Generally speaking, it would be nice to understand whether ROS gazebo actually does run with a native Linux and vcxsrv as the remote X server.

With export LIBGL_ALWAYS_INDIRECT=1 gazebo simply doesn't launch.
Also I made a mistake in my other comment, I was using an old version of xming. I tried it again with vcxsrv with native opengl and I had the same result.

@IceSentry  You wrote that you see a black screen, instead of anything, I assumed that you installed Xming, just do not set it on the desired display, by default-1, and you need 0, if of course you passed the same settings in UNIX environment
In general, you will be disassembled

this will take you through a wizard which on its last page refers to the LIBGL_ALWAYS_INDIRECT environment variable (export LIBGL_ALWAYS_INDIRECT=1)

Do not do that.

Generally speaking, it would be nice to understand whether ROS gazebo actually does run with a native Linux and vcxsrv as the remote X server.

This is generally the prerequisite for posting here. Even then, monsters like ROS make for terrible use-cases for tracking down WSL bugs or feature gaps; since those bugs won't have to do with drawing pixels. An exception is being made since it was suggested to open an issue.

Although on my version of vcxsrv I don't see a native opengl checkbox. I use vcxsrv <IP_ADDRESS> from sourceforge

Start VcXsrv with XLaunch. You will see the checkbox on the third page of the wizard.
In any case, against my better judgement I installed ROS (a short part of my life I'll never get back). Worked here out of the box with Ubuntu 16.04 and VcXsrv 1.20. Which is pretty much what I feared.
n.b. I don't want to imply unchecking native gl is your magic bullet. I only know it lit up without incident for me. I am not sure the thing is actually usable, mind. I suspect Gazebo falls much into the same category as Blender on that front.

I'm sorry if I wasted your time, I'm very new to all of this and since it was suggested in the other thread and I had a similar issue I made this thread.
I know WSL isn't supposed to be used for GUI apps, but I've seen a few issues here talking about running gui apps through an xserver so I assumed it was in a kind of grey area.
I will try to do a fresh wsl and gazebo install and see if it works. I'll also look into running gazebo on a
a linux vm with an X server. To be clear I did find the native opengl option and I disabled it as suggested and it still didn't work for me.
But if I understand correctly you don't believe this is an issue with WSL and it is most likely with gazebo and/or the x server?

I'm sorry if I wasted your time

Don't be. This isn't on you. It wasn't a waste. Yes it's a grey area.

But if I understand correctly you don't believe this is an issue with WSL and it is most likely with gazebo and/or the x server?

Dunno, precisely, or I'd tell ya. I was kind of hoping glxgears wouldn't work for you, in which case we could attack that head on. Or, that gazebo wouldn't work for me, in which case I could deep dive for the curiosity value. We've got neither of those situations, unfortunately.
We do know "WSL" (namely the kernel emulation layer that makes this whole thing go) is fine. Because it works, demonstrably. WSL doesn't even know you are talking to VcXsrv. All WSL knows is you are writing some bytes down a socket on localhost port 6000.
It might be firewall related. I got quite a few popups to open ports. Try disabling your Windows firewall entirely and see if that helps. But we're grasping here.
You might try XMing just to switch things up. That at least purturbs a variable (the X Server).
You can also try running it remotely from inside a VM as an experiment, if you are feeling motivated or are looking for a time sink. But trying a given scenario (like Gazebo) in a VM is more valuable in the case where you know it doesn't work in WSL, and thus can start tracking down a diverge from the Real Thing. Here we know it does, so there is no diverge to discover. The possible outcomes of the experiment for you aren't pretty. Either it doesn't work in the VM, which leaves you exactly where you are right now (wondering why). Or it does work, which puts you in the unenviable position of trying to find out precisely what bits of your Real Linux userspace (Ubuntu + everything) differ from your WSL userspace (Ubuntu + everything). Which is "not easy", to put it mildly.
One "last" shot: what does glxinfo | grep OpenGL return for you. Should look like:
ken@DESKTOP-4UTIQSF:~/Devel/ros$ glxinfo | grep OpenGL
OpenGL vendor string: VMware, Inc.
OpenGL renderer string: llvmpipe (LLVM 6.0, 256 bits)
OpenGL core profile version string: 3.3 (Core Profile) Mesa 18.0.5
OpenGL core profile shading language version string: 3.30
OpenGL core profile context flags: (none)
OpenGL core profile profile mask: core profile
OpenGL core profile extensions:
OpenGL version string: 3.0 Mesa 18.0.5
OpenGL shading language version string: 1.30
OpenGL context flags: (none)
OpenGL extensions:
OpenGL ES profile version string: OpenGL ES 3.0 Mesa 18.0.5
OpenGL ES profile shading language version string: OpenGL ES GLSL ES 3.00
OpenGL ES profile extensions:

If it's the same just say 'same' no need to paste the output. I'm just trying to guess variables.

On the subject of using export LIBGL_ALWAYS_INDIRECT=1, and also regarding "native windows opengl" in vcxsrv, I finally understand some of the implications there.
Fundamentally, using native OpenGL forces all OpenGL commands to be rendered on the remote server (i.e. the "box" which eventually shows the bits and bytes). One of the side-effects of that is that the OpenGL command stream forces use of the GLX protocol - and that only supports OpenGL 1.4 (see http://x.cygwin.com/docs/ug/using-glx.html)
So, some experiments after sudo apt install gazebo9:

launch vcxsrv with "Native opengl" checked
-- export LIBGL_ALWAYS_INDIRECT=1 && gazebo -> exactly nothing happens, silent crash (gazebo diagnostics probably broken)
-- export LIBGL_ALWAYS_INDIRECT=0 && gazebo ->

libGL error: No matching fbConfigs or visuals found
libGL error: failed to load driver: swrast
libGL error: No matching fbConfigs or visuals found
libGL error: failed to load driver: swrast

launch vcxsrv without "Native opengl" checked
-- export LIBGL_ALWAYS_INDIRECT=1 && gazebo -> exactly nothing happens, silent crash (gazebo diagnostics probably broken)
-- export LIBGL_ALWAYS_INDIRECT=0 && gazebo -> life is good

At no time am I able to see a black screen; something must be seriously broken elsewhere for that to happen (in case "black screen" is exactly what is visible)

But if I understand correctly you don't believe this is an issue with WSL and it is most likely with gazebo and/or the x server?

The probability of this being a WSL problem is very, very low, given the above.

This is what I mean by black screen I should have made this at the beginning. The issue is that the 3d viewer is black not the entire window.
I'll do a clean install of wsl, gazebo and vcxsrv tomorrow and try to investigate more.

I have the same black screen problem, with a "preparing world" window on the front.

That warning is a window manager thing (xfce4) and won't be related. [Also, running a window manager serves no purpose, but I digress.]
I think this one has about run its course. There are reports of the same behaviour on Real Linux. Try disabling the Windows firewall (there was no response to that suggestion), but that is mostly pissing on a spark plug. If glxgears was also drawing blackness we could explore general remote opengl problems, but that isn't the case here. The way forward here would be for someone motivated to deep dive Gazebo and find out exactly what it is up to. But there's no WSL actionable, and no one here purports to be a Gazebo expert (I had never heard of the thing before this issue was submitted). Bonne chance.

@therealkenc thanks for spending time on this. I encountered the same issue that  @IceSentry is seeing, and there's an easy solution:
export GAZEBO_IP=<IP_ADDRESS>

I tried running this out of the box, and also saw a black render window, so I started with your suggestion:

Try disabling the Windows firewall (there was no response to that suggestion),

With the firewall completely disabled, I still saw a black render window when following the normal gazebo bringup. This did appear to be related to the network configuration, though, as the gazebo server emits warnings about outgoing message queues filling up (nobody is receiving them). I also had the same issue when running as admin.
Below is the repro that shows and then fixes the bug:

From vanilla Windows 10 Pro x64 with Intel graphics:

Install WSL ref

win$ Enable-WindowsOptionalFeature -Online -FeatureName Microsoft-Windows-Subsystem-Linux

Install Ubuntu16.04 from the MS Store link
Install VcXsrv <IP_ADDRESS>.0 link
Launch VcXsrv through XLaunch with the following commands:

Launch Ubuntu16.04 in WSL (and initialize with new user creds)
Install xubuntu-desktop to suppress window manager warnings

linux$ sudo apt install xubuntu-desktop

Install mesa-utils to verify 3d acceleration

linux$ sudo apt install mesa-utils`

Set DISPLAY

linux$ export DISPLAY=:0

Run glxgears to verify 3d acceleration:

linux$ glxgears

Install gazebo 9 with bootstrap script:

linux$ curl -sSL http://get.gazebosim.org | sh

Run gazebo:

linux$ gazebo --verbose

Result:

Gazebo multi-robot simulator, version 9.3.1
Copyright (C) 2012 Open Source Robotics Foundation.
Released under the Apache 2 License.
http://gazebosim.org

[Msg] Waiting for master.
[Msg] Connected to gazebo master @ http://<IP_ADDRESS>:11345
[Msg] Publicized address: <IP_ADDRESS>
Gazebo multi-robot simulator, version 9.3.1
Copyright (C) 2012 Open Source Robotics Foundation.
Released under the Apache 2 License.
http://gazebosim.org

[Msg] Waiting for master.
[Msg] Connected to gazebo master @ http://<IP_ADDRESS>:11345
[Msg] Publicized address: <IP_ADDRESS>

What stands out here is the [Msg]  Publicized address: <IP_ADDRESS> since that is not the ip address for any valid interface according to ifconfig.
So, killing gazebo and exporting GAZEBO_IP ref fixes this:
linux$ export GAZEBO_IP=<IP_ADDRESS>
linux$ gazebo --verbose

Gazebo multi-robot simulator, version 9.3.1
Copyright (C) 2012 Open Source Robotics Foundation.
Released under the Apache 2 License.
http://gazebosim.org

[Msg] Waiting for master.
Gazebo multi-robot simulator, version 9.3.1
Copyright (C) 2012 Open Source Robotics Foundation.
Released under the Apache 2 License.
http://gazebosim.org

[Msg] Connected to gazebo master @ http://<IP_ADDRESS>:11345
[Msg] Publicized address: <IP_ADDRESS>
[Msg] Waiting for master.
[Msg] Connected to gazebo master @ http://<IP_ADDRESS>:11345
[Msg] Publicized address: <IP_ADDRESS>

I still see a lot of message errors, but this is unlikely a WSL-specific issue beyond networking config:
Exception sending a message
...

@therealkenc, as you said, it runs, but usability is still yet to be seen.
Shoutout @nkoenig @scpeters @tfoote

OMG! I have had just tried this, and it really worked! In fact I launched it succeessfully before, with waiting for it about 20min, which made me thoroughly and finally give up. However, using your solution to launch seems much more normal and save me another 19min.
THANKS! A LOT!
发件人: Jonathan Bohren
发送时间: 2018年8月21日 23:33
收件人: Microsoft/WSL
抄送: yxy1996; Comment
主题: Re: [Microsoft/WSL] ROS Gazebo black screen (#3368)
@therealkenc thanks for spending time on this. I encountered the same issue that @IceSentry is seeing, and there's an easy solution:
export GAZEBO_IP=<IP_ADDRESS>
I tried running this out of the box, and also saw a black render window, so I started with your suggestion:
Try disabling the Windows firewall (there was no response to that suggestion),
With the firewall completely disabled, I still saw a black render window when following the normal gazebo bringup. This did appear to be related to the network configuration, though, as the gazebo server emits warnings about outgoing message queues filling up (nobody is receiving them). I also had the same issue when running as admin.
Below is the repro that shows and then fixes the bug:
From vanilla Windows 10 Pro x64 with Intel graphics:

Install WSL ref
win$ Enable-WindowsOptionalFeature -Online -FeatureName Microsoft-Windows-Subsystem-Linux

Install Ubuntu16.04 from the MS Store link

Install VcXsrv <IP_ADDRESS>.0 link

Launch VcXsrv through XLaunch with the following commands:

Launch Ubuntu16.04 in WSL (and initialize with new user creds)

Install xubuntu-desktop to suppress window manager warnings
linux$ sudo apt install xubuntu-desktop

Install mesa-utils to verify 3d acceleration
linux$ sudo apt install mesa-utils`

Set DISPLAY
linux$ export DISPLAY=:0

Run glxgears to verify 3d acceleration:
linux$ glxgears

Install gazebo 9 with bootstrap script:
linux$ curl -sSL http://get.gazebosim.org | sh

Run gazebo:
linux$ gazebo --verbose
Result:

Gazebo multi-robot simulator, version 9.3.1
Copyright (C) 2012 Open Source Robotics Foundation.
Released under the Apache 2 License.
http://gazebosim.org
[Msg] Waiting for master.
[Msg] Connected to gazebo master @ http://<IP_ADDRESS>:11345
[Msg] Publicized address: <IP_ADDRESS>
Gazebo multi-robot simulator, version 9.3.1
Copyright (C) 2012 Open Source Robotics Foundation.
Released under the Apache 2 License.
http://gazebosim.org
[Msg] Waiting for master.
[Msg] Connected to gazebo master @ http://<IP_ADDRESS>:11345
[Msg] Publicized address: <IP_ADDRESS>
What stands out here is the [Msg] Publicized address: <IP_ADDRESS> since that is not the ip address for any valid interface according to ifconfig.
So, killing gazebo and exporting GAZEBO_IP ref fixes this:
linux$ export GAZEBO_IP=<IP_ADDRESS>
linux$ gazebo --verbose
Gazebo multi-robot simulator, version 9.3.1
Copyright (C) 2012 Open Source Robotics Foundation.
Released under the Apache 2 License.
http://gazebosim.org
[Msg] Waiting for master.
Gazebo multi-robot simulator, version 9.3.1
Copyright (C) 2012 Open Source Robotics Foundation.
Released under the Apache 2 License.
http://gazebosim.org
[Msg] Connected to gazebo master @ http://<IP_ADDRESS>:11345
[Msg] Publicized address: <IP_ADDRESS>
[Msg] Waiting for master.
[Msg] Connected to gazebo master @ http://<IP_ADDRESS>:11345
[Msg] Publicized address: <IP_ADDRESS>
I still see a lot of message errors, but this is unlikely a WSL-specific issue beyond networking config:
Exception sending a message
...
@therealkenc, as you said, it runs, but usability is still yet to be seen.
Shoutout @nkoenig @scpeters @tfoote
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub, or mute the thread.

Glad you got it working. 👍

Set DISPLAY
linux$ export DISPLAY=:0

Minor observation, setting aside $GAZEBO_IP for a moment. Your $DISPLAY variable wants to be <IP_ADDRESS>:0 or localhost:0 as well (per earlier). It might not (and probably doesn't) have any effect on Gazebo, but ":0" means X11 over AF_UNIX on /tmp/.X11-unix/X0, not AF_INET over localhost:6000. But this can (and does) cause problems in some scenarios.
Mentioning it mostly because I didn't personally set $GAZEBO_IP despite it working anyway. That difference remains somewhat unexplained. I did however blindly install all of ROS (because the OP said do that), which pulls in the kitchen sink. So who knows what variables got set. Either way, nice follow up.

Your $DISPLAY variable wants to be <IP_ADDRESS>:0 or localhost:0 as well (per earlier). It might not (and probably doesn't) have any effect on Gazebo, but ":0" means X11 over AF_UNIX on /tmp/.X11-unix/X0, not AF_INET over localhost:6000. But this can (and does) cause problems in some scenarios.

Ah, that's good clarification.

Mentioning it mostly because I didn't personally set $GAZEBO_IP despite it working anyway. That difference remains somewhat unexplained.

Gazebo looks like it's using getifaddrs (location) (manpage) to determine the IP of a given host. WSL networking is also something I lack knowledge about, too, but since that's in the linux kernel, this might actually be a WSL bug. I see that there are some previous issues with getifaddrs: https://github.com/Microsoft/WSL/issues/308

I did however blindly install all of ROS (because the OP said do that), which pulls in the kitchen sink. So who knows what variables got set.

Yeah, I already had a ROS installation in my WSL (but not the machine I used for vanilla repro/debug), and it still failed in the same way.  I don't think any package in gazebo_ros_pkgs exports GAZEBO_IP, anyway.

It looks like instead of coming back as AF_INET like it does on linux, on WSL, sa_family for every interface is AF_PACKET (manpage).
@therealkenc

It's still not clear why getifaddrs is returning this additional 169.254.x.x IP address on WSL and not native Linux, though.

That's excellent information to add, thanks. Since it did "work" for me out of the box (possibly due to differences in my network rig) and, more practically, because I've long since wiped ROS/Gazebo, I ~will need a high bar of boredom to~ probably won't deep dive Gazebo as the repro of choice for a getifaddrs diverge. But absolutely, consider your observation well noted (for when not if something else comes up that smells like a getifaddrs diverge). If you can do a small tight CLI test case you'd definitely get a shiny gold star, but the challenge is going to be doing one concise enough to actually reproduce for the folks in Redmond (read: "returns this additional 169.254.x.x IP").

If you can do a small tight CLI test case you'd definitely get a shiny gold star, but the challenge is going to be doing one concise enough to actually reproduce for the folks in Redmond (read: "returns this additional 169.254.x.x IP").

Here you go (no shiny stars needed):
https://github.com/jbohren-hbr/ifaddrs_test
This works on my native xubuntu 16.04 machine, fails on WSL with extra phantom interfaces that don't show up in ifconfig  and are all on the 169.254.x.x subnet, which is not the right subnet for any of the interfaces I actually have:
wsl$ ./test.bash
not matching.
1,2d0
< eth0
< eth1
7,8d4
< eth6
< eth7
11,12d6
< wifi1
< wifi2

native$ ./test.bash
matching.

Okay. Unfortunately (?) your test doesn't repro for me here. I get "matching." on WSL 18219. Which is, of course, why Gazebo worked out of the box for me (I would have been on some earlier Insiders in July).
I can't think of a dupe off the cuff that would explain a fix since 17134 (usually I can if one exists, but that doesn't mean it doesn't exist). I don't have a 17134 handy to try. First step would be to try Insiders (fast ring not skip-ahead will do) and see if it reproduces there.
Note also your ./text.bash script is sensitive to the ifconfig output syntax, which appears to have changed between Ubuntu 16.04 and 18.04 (ifconfig | grep -B1 "inet addr" won't get a hit on Real Linux Ubuntu 18.04). Not a problem, but something to be aware of since we've got Windows version number and Ubuntu version number variables at play here.

OK. I don't think this is an issue with WSL. The issue seems to be that getifaddrs returns interfaces that are both up and down. Gazebo should be checking if IFF_UP in the flags, surprise.
See here: https://github.com/jbohren-hbr/ifaddrs_test/blob/master/print_ifaddrs.cpp#L92
Test now passing, this can be put to rest. Need to create a PR on gazebo though...

For completeness, Gazebo PR with fix is here: https://bitbucket.org/osrf/gazebo/pull-requests/3009/adding-check-to-make-sure-automatic/diff

🌟

I have encountered same issue on Ubuntu Bionic, ROS Melodic and Gazebo 9 (running on virtual machine). I have 'solved' it by killing previously previously launched instance of gzserver.

I still see a lot of message errors, but this is unlikely a WSL-specific issue beyond networking config:
Exception sending a message
...

The same here. I've installed ROS-Melodic (full desktop) with Gazebo 9 on 3 different machines: 2 of them are with Ubuntu 18.04 and third one with WSL Ubuntu 18.04 (Windows 10). After a fresh install I get Exception sending a message, which is being printed infinitely after starting gazebo (gzserver, roslaunch).  But it seems that everything.
I've also noticed that it happens only when I open VPN connection

It seems that a similar issue related to 169.245.*.* "phantoom" network interfaces is affecting also the Windows build of Gazebo, see https://github.com/ms-iot/ROSOnWindows/issues/47#issuecomment-450665704 . This may indicate that the problem/feature of phantom interfaces may not be related to WSL at all, but it could be related just to the Windows network stack.

If I understand correctly (see https://github.com/ms-iot/ROSOnWindows/issues/47#issuecomment-450668204) the 169.245.*.* interfaces are related to ädapter that are disconnected, and so the issues is in Gazebo that should ignore them.

so the issues is in Gazebo

You are now caught up to above.

You are now caught up to above.

Thanks! Sorry for missing that comment.

For me, setting DISPLAY to 0, 0.0, localhost:0 or <IP_ADDRESS> on a ubuntu windows linux sub system (WLS2) did all not work, I had to use the public IP and the following command helped me:
export DISPLAY=$(cat /etc/resolv.conf | grep nameserver | awk '{print $2}'):0

I use ROS Gazebo in WSL docker. For me, the network settings are correct, but I still see the blank screen. The reason is, Gazebo is downloading data silently in background, and I just need to wait for it to finish.
I use this tutorial  to setup ROS Gazebo in WSL docker.
I run roscore in terminal. Then run rosrun gazebo_ros gazebo in second terminal. I have a blank screen as @IceSentry, and a log in terminal: waitForService: Service [/gazebo/set_physics_properties] has not been advertised, waiting...
Gazebo is downloading data silently in background, see discussion in the forum.
Close the window, and wait for the log to print in terminal:
[ INFO] [1613558941.011174200]: waitForService: Service [/gazebo/set_physics_properties] is now available.
[ INFO] [1613558941.208707300]: Physics dynamic reconfigure ready.

Rerun rosrun gazebo_ros gazebo, then it works.

@therealkenc thanks for spending time on this. I encountered the same issue that @IceSentry is seeing, and there's an easy solution:
export GAZEBO_IP=<IP_ADDRESS>

I tried running this out of the box, and also saw a black render window, so I started with your suggestion:

Try disabling the Windows firewall (there was no response to that suggestion),

With the firewall completely disabled, I still saw a black render window when following the normal gazebo bringup. This did appear to be related to the network configuration, though, as the gazebo server emits warnings about outgoing message queues filling up (nobody is receiving them). I also had the same issue when running as admin.
Below is the repro that shows and then fixes the bug:
From vanilla Windows 10 Pro x64 with Intel graphics:

Install WSL ref

win$ Enable-WindowsOptionalFeature -Online -FeatureName Microsoft-Windows-Subsystem-Linux

Install Ubuntu16.04 from the MS Store link
Install VcXsrv <IP_ADDRESS>.0 link
Launch VcXsrv through XLaunch with the following commands:

Launch Ubuntu16.04 in WSL (and initialize with new user creds)
Install xubuntu-desktop to suppress window manager warnings

linux$ sudo apt install xubuntu-desktop

Install mesa-utils to verify 3d acceleration

linux$ sudo apt install mesa-utils`

Set DISPLAY

linux$ export DISPLAY=:0

Run glxgears to verify 3d acceleration:

linux$ glxgears

Install gazebo 9 with bootstrap script:

linux$ curl -sSL http://get.gazebosim.org | sh

Run gazebo:

linux$ gazebo --verbose

Result:

Gazebo multi-robot simulator, version 9.3.1
Copyright (C) 2012 Open Source Robotics Foundation.
Released under the Apache 2 License.
http://gazebosim.org

[Msg] Waiting for master.
[Msg] Connected to gazebo master @ http://<IP_ADDRESS>:11345
[Msg] Publicized address: <IP_ADDRESS>
Gazebo multi-robot simulator, version 9.3.1
Copyright (C) 2012 Open Source Robotics Foundation.
Released under the Apache 2 License.
http://gazebosim.org

[Msg] Waiting for master.
[Msg] Connected to gazebo master @ http://<IP_ADDRESS>:11345
[Msg] Publicized address: <IP_ADDRESS>

What stands out here is the [Msg] Publicized address: <IP_ADDRESS> since that is not the ip address for any valid interface according to ifconfig.
So, killing gazebo and exporting GAZEBO_IP ref fixes this:
linux$ export GAZEBO_IP=<IP_ADDRESS>
linux$ gazebo --verbose

Gazebo multi-robot simulator, version 9.3.1
Copyright (C) 2012 Open Source Robotics Foundation.
Released under the Apache 2 License.
http://gazebosim.org

[Msg] Waiting for master.
Gazebo multi-robot simulator, version 9.3.1
Copyright (C) 2012 Open Source Robotics Foundation.
Released under the Apache 2 License.
http://gazebosim.org

[Msg] Connected to gazebo master @ http://<IP_ADDRESS>:11345
[Msg] Publicized address: <IP_ADDRESS>
[Msg] Waiting for master.
[Msg] Connected to gazebo master @ http://<IP_ADDRESS>:11345
[Msg] Publicized address: <IP_ADDRESS>

I still see a lot of message errors, but this is unlikely a WSL-specific issue beyond networking config:
Exception sending a message
...

@therealkenc, as you said, it runs, but usability is still yet to be seen.
 This fixed the issue for me, thank you!

For me the 'black screen in gazebo' fix was to install latest Intel driver
Although one issue left to solve is, after Windows restart gazebo scene resets to black screen

It took me a long time to finally solve the problem by deleting the .wslconfig content. The problem should be related to the ip network problem.


Make run result from Runner unit test usable (+ docu)

When you want to use DDQ for automated quality checks, you can also ensure the results in unit tests. We should give an example on how to write an assertion using ScalaTest for example.

Proposal (WIP)
Unit Tests
You can also use DDQ to write automated unit tests for your data. After running a check or a series of checks, you can inspect the results programmatically.
val result = Runner.run(Seq(check1), Seq.empty)

I think that it would be nice to have allConstraintsSatisfied as a CheckResult method.

I thought of the same thing actually, @Gerrrr. Can you create a ticket? I also thought about conversions from constraint results to boolean but I am not sure if we will always have only two (success and failure) possible outcomes. It might be that we have some numeric outcome (like a match rate) or something like this, that is more fuzzy. I don't know. But you are right, this convenience method is nice to have.


Fix typo in mellanox plugin name in logs

mellalnox > mellanox
@adrianchiris

Pull Request Test Coverage Report for Build<PHONE_NUMBER>

-2 of 2 (0.0%)  changed or added relevant lines in 1 file are covered.
5 unchanged lines in 2 files lost coverage.
Overall coverage decreased (-0.05%) to 25.867%

Changes Missing Coverage
Covered Lines
Changed/Added Lines
%

pkg/plugins/mellanox/mellanox_plugin.go
0
2
0.0%

Files with Coverage Reduction
New Missed Lines
%

controllers/sriovibnetwork_controller.go
2
68.94%

api/v1/helper.go
3
42.68%

Totals

Change from base Build<PHONE_NUMBER>:
-0.05%

Covered Lines:
2908

Relevant Lines:
11242

💛  - Coveralls


flow 35 should detect superfluous props

Via https://flowtype.org/blog/2016/10/04/Property-Variance.html
Need to investigate it. But as I understand, it should detect superfluous reducers cases and superfluous component props.

Blocked. Waiting for RN 39 which uses flow 35.

Idk how.


documentation: passing dynamic role variables to tests when runnning molecule verify

I know this could be batted away as something that is related to testinfra only, however, I am finding that I would like to ask here - would you accept a documentation PR that outlines a strategy for including role variables that you passed to your converge playbook, into your unit tests?
Here's what I am currently doing:
# molecule/default/playbook.yml
---
- name: Converge
  hosts: all
  vars_files:
    - testvars.yml
  roles:
    - role: my-role
      foobar: "{{ test_foobar }}"

Then in a molecule/default/testvars.yml, I have:
---
test_foobar: barfoo

Then, in my molecule/default/tests/conftest.py, I do the following:
import os

import pytest
from testinfra.utils.ansible_runner import AnsibleRunner

DEFAULT_HOST = 'all'

inventory = os.environ['MOLECULE_INVENTORY_FILE']
runner = AnsibleRunner(inventory)
runner.get_hosts(DEFAULT_HOST)

@pytest.fixture
def testvars(host):
    variables = runner.run(
        DEFAULT_HOST,
        'include_vars',
        'testvars.yml'
    )
    return variables['ansible_facts']

And in my tests, I can then:
def test_something(host, testvars):
    print(testvars['test_foobar'])

As far as I can see, this is the cleanest way (I've digged around in a lot of tickets) of matching up the dynamic variables that you pass to your role and your testinfra pytest tests.
If it isn't, please someone tell me :)
In any case, the main question remains - is there a place we can start to document this on the RTD setup?

Woops, meant to open this on https://github.com/metacloud/molecule, closing! :)

Following https://github.com/metacloud/molecule/issues/1396#issuecomment-406719205, I'm not getting anywhere on the molecule repository. Could you provide any guidance here or could we suggest some sort of an API for this? I'd be happy to implement something.

Testinfra should load host and group variables automatically. What you mean by "I pass a variable to my role ?", is this a role "default" variable ?
I think you can load such variables by calling the proper api from ansible (see https://github.com/philpep/testinfra/blob/master/testinfra/utils/ansible_runner.py)

I had a similar problem, because I wanted to access the role defaults and vars. I have the following in my conftest.py. I did it this way to keep the variable precedence of ansible intact. I used the cache because I had the problem that the host fixture was teared down and setup for every test which made this really slow.
import pytest

cache = {}

@pytest.fixture(scope='module')
def ansible_vars(request, host):
    role_name =  request.cls.__name__.replace("Test", "").lower()
    if (id(host), role_name) in cache.keys():
        return cache[(id(host), role_name)]

    ansible_vars = host.ansible("include_vars", "file=roles/%s/defaults/main.yml name=role_defaults" %
                                (role_name))["ansible_facts"]["role_defaults"]
    ansible_vars.update(host.ansible.get_variables())
    ansible_vars.update(host.ansible(
        "include_vars", "file=roles/%s/vars/main.yml name=role_vars" % (role_name))["ansible_facts"]["role_vars"])
    del ansible_vars['role_defaults']

    cache[(id(host), role_name)] = ansible_vars

    return ansible_vars

Thanks for weighing in @barnabasJ!  I am sure (from counting tickets on molecule and testinfra repositories) that this is a use case that many people need solved. I must say, your solution does look quite nice!
Perhaps this could be solved as a family of test fixtures that come packaged up.
Any thoughts @philpep?

@barnabasJ : how do you use testinfra? It seems you don't use molecule. In my case, putting a conftest.py file in my test dir doesn't affect my tests. Moreover, I don't understand how you use your functions ansible_vars, more specifically I don't understand what is the request parameter. Could you be more explicit please?

In my current environment it's hard to use docker or vms on my local machine, therefore I don't use molecule. But I write the tests to check if the servers are in the desired state after running ansible-playbooks. I just do it without molecule as a dev tool.
Testinfra is developed as a pytest plugin which allows us to use all the pytest features while writing our tests. When you write the tests you just specify host as an argument and it gets injected during runtime. This is because host is a pytest.fixture.
The conftest.py file is used to create fixtures that can be shared between different test files. While creating fixtures it's possible to inject other fixtures, which you can then use to get the functionality you want. request is another fixture built into pytest that allows to inspect the context from which the fixture is called.

OK thanks for the explaination.
I was able to adapt your code to an usage with molecule. I just added the following code to my tests (it works like yours):
import pytest

@pytest.fixture
def get_vars(host):
    defaults_files = "file=../../defaults/main.yml name=role_defaults"
    vars_files = "file=../../vars/main.yml name=role_vars"

    ansible_vars = host.ansible(
        "include_vars",
        defaults_files)["ansible_facts"]["role_defaults"]

    ansible_vars.update(host.ansible(
        "include_vars",
        vars_files)["ansible_facts"]["role_vars"])

    return ansible_vars

Of course it could be very useful if this was integrated natively in Testinfra, but it could be not so easy because of the many use cases that users could encounter.

There probably isn't one solution for everything. But if we had a documented example, I think most would be able to adapt it to their use-case.

Question: are there any downsides to this approach of using include_vars? If you see links above, the molecule core devs seem to think it can lead to false positives. I haven't seen any limitations in my work so far.
Otherwise, can we come to some agreement on adding variable fixtures to the https://github.com/philpep/testinfra/blob/master/testinfra/plugin.py? It appears since these paths are totally configurable, we'll need defaults (like ../../defaults/main.yml) and then allow to override (using some tricks from https://docs.pytest.org/en/latest/example/parametrize.html).

I'm still not sure I fully grasp the notion of why you need to pass variables around like that and why you need them available for your integration tests?  I've read this issue multiple times and I cannot come up with a good reason to do this without it being overly complex and confusing for the person maintaining such a library.  I think I would need to see an example repository with these additions included to see why it might be worth while effort to make a recommendation.
I know the Ansible community does not believe unit testing but I feel that this scenario, testing variable combinations in custom roles to be more a unit test not an integration test.  Testinfra is a integration test library and I could see adding such a new fixture would cause the test library to behave "weirdly" or "falsey" at times if the user has mis-configured their environment or has files laying around.
If I understand your problem scenario then one of the ways I've solved something like this is to just create a new molecule scenario and add those custom variables in the converge.yml playbook.  Yes, this will increase the time it takes to test your roles, but it's a small price for not testing or having have to many test fixtures floating around and causing you more grief down the road.  Here's the example repo
Anyway, I really like this discussion and curious to learn more about how other folks are doing things.

I'm still not sure I fully grasp the notion of why you need to pass variables around like that

I have laid out a clear example in https://github.com/philpep/testinfra/issues/345#issuecomment-406808758:

A simple use case to focus the discussion:

I pass in a variable to my role called http_port which I open on the firewall with ufw
I test that the vaule of http_port passed into the role was opened by ufw
How do I access this http_port value in my test infra tests?

I could see adding such a new fixture would cause the test library to behave "weirdly" or "falsey" at times if the user has mis-configured their environment or has files laying around.

You're right, we need to avoid this. The default should always work.

If I understand your problem scenario then one of the ways I've solved something like this is to just create a new molecule scenario and add those custom variables in the converge.yml playbook. Yes, this will increase the time it takes to test your roles, but it's a small price for not testing or having have to many test fixtures floating around and causing you more grief down the road. Here's the example repo

Looking at https://github.com/codylane/ansible-role-pyenv/blob/master/molecule/debian/playbook.yml, you have specified - 2.6.9, - 2.7.15 - 3.6.6 as your pyenv versions you want to install. In your https://github.com/codylane/ansible-role-pyenv/blob/517cd3ab912a2c2cf0c62da485e7976cf55555b2/molecule/debian/tests/test_default.py#L114, you hard code which versions you expect to be installed. In fact, (for whatever reason), you're not testing that the version 3.6.6 directory is present.
This example is proving (IMHO) why we need to be able to access role variables in the tests.
If you could access the pyenv versions values you passed to the role in the test, then you could simply iterate over them and make sure the directories are present. This would mean that your tests stay synced with your variables roles.

In my case we would also like to be able to run the test periodically on the servers after provisioning them. But not all the servers are exactly the same. This means hard coding the tests is not always possible. If I use the default_vars during development of the ansible roles. I can just specify the vars in the group_vars/host_vars later the way I would do it if I ran a playbook with multiple roles on multiple servers and the defaults are overwritten and the tests are specific to the servers they're run on.

Ahh, I see both your points now.  Thank you for taking the time to help clarify.
lwm - I will fix that missing test, thank you for pointing it out.  It was there, then I did a refactor due to travis "timeout" problems and I must have forgot to add it back in.
I've really enjoyed this discussion.  I'd like to see if I can take a stab at what I think is being proposed here.
Requirement
When using testinfra to test our ansible roles, we would like to have a way to pass in a group of variables that work for the following cases:

These variables are passed to our role when we run pytest which configures our play.
These variables are available to our system under test in our test_*.py where they can also be used to avoid hard coding them in our tests?

I could also see a need where the scope needs to also be a requirement to avoid the "setup" and "teardown" routines.  Following the testinfra paradigm there are "module" and "function" scope test fixtures so we would probably want a way to do both for maximum flexibility.
Question

I've not tried this but can we not use group_vars or host_vars via the ansible_runner?

Potential Solution Discussion
I wonder if we could explore the following scenarios?
1.) See if we can get ansible_runner to use a dynamic inventory where the dynamic inventory is a JSON blob of configuration.  (I'll provide an example of this when I have more time)
2.) I also wonder if it is possible to use group_vars or host_vars which should be available to both ansible and testinfra?
3.) I wonder if we create a pytest fixture to push custom facts to the SUT (system under test) which would be available to both ansible and testinfra?  I can also provide an example of this if anyone is interested.

Just a quick comment to group_vars/host_vars. Yes the ansible_runner picks up on them but when creating roles I don't use those, I see them as a higher level tool used with playbooks.
I feel that roles should be runable/testable with just the defaults in most cases and I use group/host_var to customize the playbook runs for the different target servers.
What do you think?

barnabasJ - I hear you and that makes a lot of sense from a testing perspective.  My first thought then is to use a dynamic inventory script (i'm still working on an example) that is configured via a JSOB blob where each group would be a different test scenario of configuration data which is then passed to ansible.
However, the challenge is trying to get at those variables through the 'ansible' library API and it's been a few years since I got intimate with it.  It will take a few days as I have free time to sort it out but I've got a few more ideas to try.
lwm - Yup, in my initial testing get_variables is close but it's missing info that I know we can get at, I just need to massage it a bit to get what we want cause hostvars will give us pretty much everything you both are after if we can get at them through the ansible API.

From initial testing, I think I understand why we cannot see the role variables it's because the ansible_runner does not see a playbook, instead it wraps what a playbook might look like via dictionary object
So, with that said, we will need to introduce some new features for the ansible_runner to read to the following:

It should support reading a playbook YAML file from the a directory inside the project root.
There may be multiple playbook files that need to be read for scenario testing where each environment is different and or otherwise isolated.
The variables contained within that playbook should be returned via the get_variables() routine of the ansible_runner so that the system under test (SUT) will be able to interrogate and or simplify our tests from having hard coded tests.

The result that should be returned is a new dictionary that represents hostvars + facts + inventory vars, defaults, or any other variable passed to a playbook run and it should go out of scope depending on the function scope being tested i.e. (module, session, function).
However, before we introduce this new feature, I'd like to get consensus from the project owner @philpep if this solution would be acceptable to implement?
@lwm and @barnabasJ - Please also chime in if I've missed anything.

Great.

There may be multiple playbook files that need to be read for scenario testing where each environment is different and or otherwise isolated.

Should we use some naming convention to allow picking up and reading of vars files in the scenario folder?

However, before we introduce this new feature, I'd like to get consensus from the project owner

Good idea.

The runner is attached to the host which is module scoped. Which should be good for most situations, I'm not sure about how this would effect roles developed with molecule, but the variables for a host should probably not change during a test run.
I'm also not sure if we even need such a complicated setup. Are you guys trying to read variables from the playbook itself too?
Right now it's possible to specify the host from within a module using the
testinfra_host  variable like:
testinfra_hosts = ["ansible://all?ansible_inventory=hosts.ini"]

Maybe it'would be enough to add another option here.  But like you said it's probably best to wait and see what @philpep thinks.

I did play around with it a little bit. Here is a minimal example. All the needed stuff is already in the ansible_runner except the playbook.
import ansible.cli.playbook
import ansible.playbook

import pprint

pp = pprint.PrettyPrinter()

cli = ansible.cli.playbook.PlaybookCLI(None)
cli.options = cli.base_parser(
    connect_opts=True,
    meta_opts=True,
    runas_opts=True,
    subset_opts=True,
    check_opts=True,
    inventory_opts=True,
    runtask_opts=True,
    vault_opts=True,
    fork_opts=True,
    module_opts=True,
).parse_args([])[0]
cli.normalize_become_options()
cli.options.connection = "smart"
cli.options.inventory = 'hosts.ini'
loader, inventory, variable_manager = (
    cli._play_prereqs(cli.options))
playbook = ansible.playbook.Playbook.load('playbook.yml', variable_manager, loader)
pp.pprint(variable_manager.get_vars(playbook.get_plays()[0]))

I just copied most of this from the AnsibleRunnerV2(AnsibleRunnerBase):.__init__(self, host_list): method. I just added the last 2 lines.
This is just thrown together and thought of as a proof of concept.

B U M P :shark: :shark: :shark:

Hi, I'm digging in this issue but I'm a bit confused because I'm not familiar with molecule.
Can someone summarize (shortly) what the current state of this issue ?
IIUC, you run ansible through molecule which run a playbook with "vars_files", "roles" and role variables, and you expect to have a way in testinfra tests to get theses variables (= merge of host_vars, group_vars, vars_file, role default vars and role overriden vars) ?
testinfra doesn't have access to the playbook the machine was provisioned with, it only read inventory, ansible.cfg and host/groups vars.
I think it should be possible to add a playbook parameter to host.ansible.get_variables() which could read the playbook and merge the variables just like ansible do by calling the ansible playbook python API. Do you think it will solve your problem ?

Hi, I'm digging in this issue but I'm a bit confused because I'm not familiar with molecule and ansible.
Can someone summarize (shortly) what the current state of this issue ?

Thanks for taking some time on this! We kind of got lost at sea :confounded:

IIUC, you run ansible through molecule which run a playbook with "vars_files", "roles" and role variables, and you expect to have a way in testinfra tests to get theses variables (= merge of host_vars, group_vars, vars_file, role default vars and role overriden vars) ?

Yes, you got it!

I think it should be possible to add a playbook parameter to host.ansible.get_variables() which could read the playbook and merge the variables just like ansible do by calling the ansible playbook python API. Do you think it will solve your problem ?

I think, basically, we decided that it would be the nicest if we could extend the get_variables() interface, so this sounds like it would work! If I pass a bunch of vars into my playbook and I can pass my playbook into the function and get those vars, we're good.

First of all, I'd like to thank you too for spending your time on this.
I don't use molecule because I can't use docker on my work machine at the moment. During tests, I also like to use ansible variables though. But to test the roles in isolation, it's only possible for me to use the variables inside the role (defaults and vars). Therefore, I don't have a playbook for every role.
I took a glance at the ansible code and saw that the smallest unit for getting the variables is a play. A playbook could potentially hold multiple Plays which might make it difficult to load the correct variables from every playbook. We would probably need to specify at least the playbook and optionally which play we want to load.
For my specific use case, it would also be nice if I could just inline the necessary play data as a string or a dictionary and don't have to create a playbook for every role. Specifically, because I also run the tests of multiple roles combined to test a specific target host which had multiple plays run against it and the legacy roles I work with use the same variable name from time to time. Which would be problematic because some roles would overwrite values for other roles.

Yes, I think role vars are scoped to the role.
So what do you think of this ? :
get_variables(playbook=<file or dict or yaml string>) --> would return merge of host_vars/group_vars and vars_file defined in playbook
get_variables(playbook=..., role=<string of a role name>) --> would return merge of host_vars/group_vars, vars_file AND role default vars + overriden role vars

It might be hard to write this, depending on the complexity of the ansible API, and by experience, it is so I think it's ok to not handle this for old ansible versions (and raise a NotImplementedError).

Right, apologies @barnabasJ, I see we have differing needs.

It might be hard to write this, depending on the complexity of the ansible API, and by experience, it is so I think it's ok to not handle this for old ansible versions (and raise a NotImplementedError).

<3
I've still not had time to do anything to make this happen but I promise I will QA test it :)

@lwm no worries,
I like your idea @philpep, and I think the proposed solution should fit most needs very well. I also agree that it's not necessary to implement this for older ansbile versions.
Let me know if I can do anything to help.

Also looking forward this capability :)

Let's say I have a role with 10 default variables and I want a test to reference one of these variables. What would the syntax look like?
Also, what would we need to do to override that default (such as using vars at the playbook level)?
Ansible has a lot of ways to merge in variables in specific orders from a number of places. I'd really like to be able to just somehow reference the variable in a test case and have the ordering taken care of for me based on what Ansible does (ie. if I supply a playbook to the runner it will use the play's version instead of the role default).
Lastly, none of this is available to do right now right?

Not sure if a lot have changed in the code base since the discussion here have taken place but the variable_manager in the AnsibleRunner should take care of caching the variable. The only thing I would change in testinfra would be to add the possibility to resolve templated variable.
This is the fixture I put in my molecule test file. Hope it can be useful to someone.
from ansible.template import Templar
from ansible.parsing.dataloader import DataLoader

@pytest.fixture(scope='module')
def ansible_vars(host):
    """
    Return a dict of the variable defined in the role tested or the inventory.
    Ansible variable precedence is respected.
    """
    defaults_files = "file=../../defaults/main.yml"
    vars_files = "file=../../vars/main.yml"

    host.ansible("setup")
    host.ansible("include_vars", defaults_files)
    host.ansible("include_vars", vars_files)
    all_vars = host.ansible.get_variables()
    all_vars["ansible_play_host_all"] = testinfra_hosts
    templar = Templar(loader=DataLoader(), variables=all_vars)
    return templar.template(all_vars, fail_on_undefined=False)

Oh nice @sebastienGuavus! @philpep, do you have any indication on what kind of change you'd accept for this issue? I'd gladly put some time in on a pull request. Still would really like to see a more convenience API available for this in testinfra :+1:

I've created a pull request to pass kwargs to ansible in order to write a python module which resolves and exposes role and testinfra variables as a tester fixture. I've outlined my idea with code examples in the pull request.

The testaid pytest plugin should solve this program. Originally, it was calling the ansible cli interface using the testinfra host fixture. But after the latest rewrite it is using the ansible python api directly and even exposes it in two fixtures. As testaid is independent from the host fixture it can now use the session scope which allows pytest to cache the testvars.

One year later, unfortunately, as of almost mid-2020, the testaid had still many limits and cannot be used reliably. Moreover it seems out of maintenance and the author seems to indicate that it was merged/moved to another repo.
I think the solution should be found in the testinfra repo directly.
What are the current blocking points to advance this issue in testinfra ?
How can we help ?

Indeed testaid has been moved to takelage-var and is under active development.
With yesterday's relase 0.4.0, takelvars has become a special case of multitestvars which now gathers the variables for multiple hosts.
The transition from testaid to takeltest (which is now part of a larger framework but can be used independently) led to yet another major refactoring. Hopefully, a lot of issues have been resolved but feel free to post any ongoing issues again in the new repository.


how to install the skin changer?

Hi, I don' t know how to install this skin changer. There is no R3nzSkin_Injector.exe in the zip. How to do it?

It was deleted by your antivirus or windows defender.

I cannot find the exe on the website.

https://github.com/R3nzTheCodeGOD/R3nzSkin/releases

Thank you! I did it!

How do we solve the last one? R3nzskin status reality Not injected

How do we solve the last one? R3nzskin status reality Not injected

From what server ?

我们如何解决最后一个问题？R3nzskin 状态现实 未注入

从什么服务器？

R3nzskin_injector.exe opens and the fourth menu says Not injected

我们如何解决最后一个问题？R3nzskin 状态现实 未注入

从什么服务器？

R3nzskin_injector.exe opens and the fourth menu says Not injected

You try to inject on PBE or Live server ?

我们如何解决最后一个问题？R3nzskin 状态现实 未注入

从什么服务器？

R3nzskin_injector.exe打开，第四个菜单显示未注入

您尝试在 PBE 或 Live 服务器上注入？
Unfortunately, I will not, whether it is because I am Tencent agent lol?


onAction doesn't get called when Popable disappears.

I am trying to change the state variable on the tap of the tooltip component.
Have a look at the code snippet below.
<>             <Popable                 onAction={visible => {                     setIsSelected(visible);                 }}                 content={                     <View style={styles.tooltipView}>                         <Text style={styles.font}>Anything :)</Text>                     </View>                 }>                 <View                     style={styles.infoIcon}>                     {isSelected ? (                         <Image source={require('assets/images/tool_tip_info_black.png')} />                     ) : (                         <Image source={require('assets/images/tool_tip_info.png')} />                     )}                 </Pressable>             </Popable>         </>
I believe visible should provide me the state of the popable. But that doesn't seem to be happening. Kindly help me out.

Hi Atit,
Thanks for sharing this issue.
My guess is that it's not calling props.onAction here:
const handleHidePopover = useCallback(() => {
  setPopoverVisible(false);
  // missing props.onAction(false);
}, []);

I'll make an update and let you know when it's up!

Hi again,
The fix has been added to v0.4.1.
Just upgrade to that version and it should all work fine :)
Good day

Hi @eveningkid thanks for responding so quick.
It still hasn't solved for me though. I have tried and upgraded the version.
To simplify the working, I have tried to show an example here.
As you can see in the example, there are two issues :

In the console, it always logs "Visible true" and it never gets false value.
The state variable isTrue is not having the correct value all the time.

Hi Atit,
I looked into it again and it seemed that yesterday's release didn't work properly.
Without making any changes, it worked by publishing it again!
Just tried your example using 0.4.2 and it's now working.
Let me know if this works for you too, ok?
Good day

Awesome!!
It's working fine now. Thanks!


How to use CustomRoute

I used the same class of the transitionBuilder in the auto route it used to work until i migrated to the null saftey packege

AutoRoute isn't compatible with stacked anymore. Stacked has its own router functionality that you can see in this video

Yes i know , i migrated to the stacked route and using the stacked generator but couldn't find any documentation on the customRoute

It's the same as the AutoRoute one. I moved the code over from AutoRoute into stacked. I'll add some documentation when I get some time.

stacked/src/code_generation/router/transitions_builders.dart
i can't use this class not the same as auto route
is there a different way?

I faced the same problem,
CustomRoute(
page: TestView,
transitionsBuilder: TransitionsBuilders.fadeIn,
),
CustomRoute(
page: UpdateNoteView,
transitionsBuilder: TransitionsBuilders.zoomIn,
),
CustomRoute(
page: TestGallery,
transitionsBuilder: TransitionsBuilders.slideRightWithFade,
),
i can't use anymore
@FilledStacks

Discovered that NavigationService has replaceWithTransition and navigateWithTransition methods but both require the actual Views instead of Routes. Moreover, I tested the built-in transition animations that came with the methods and some of them were buggy (fade transition, which I need for my project, seems to just be the regular Material transition). Just wanted to raise this even though it is a minor/cosmetic issue.

Maybe it's not exported. Let me check if it's still there in the package. I never built any of this in directly.

I just added the transition builders to the exports in stacked.dart. You should be able to import now @okursoftware

Using custom route gives this error:
[SEVERE] stacked_generator:stackedRouterGenerator on lib/app/router.dart:

type 'Null' is not a subtype of type 'String'

Here is the configuration:
@StackedApp(
  routes: [
    CustomRoute(
      page: SplashView,
      initial: true,
      transitionsBuilder: TransitionsBuilders.slideRightWithFade,
      durationInMilliseconds: 300,
    ),
  ]
)
class App {}

What's interesting is that the issue only happens with CustomRoute.

Using custom route gives this error:
[SEVERE] stacked_generator:stackedRouterGenerator on lib/app/router.dart:

type 'Null' is not a subtype of type 'String'

Here is the configuration:
@StackedApp(
  routes: [
    CustomRoute(
      page: SplashView,
      initial: true,
      transitionsBuilder: TransitionsBuilders.slideRightWithFade,
      durationInMilliseconds: 300,
    ),
  ]
)
class App {}

What's interesting is that the issue only happens with CustomRoute.

So it's not just me 😂😂😂
If you don't add the transitionBuilders it works but then what is the use without it

   CustomRoute(page: LoginView,transitionsBuilder: TransitionsBuilders.zoomIn),
The import problem is solved, but,
I encountered such an error when I ran build_runner
[SEVERE] stacked_generator:stackedRouterGenerator on lib/app/app.dart:

NoSuchMethodError: The method 'startsWith' was called on null.
Receiver: null
Tried calling: startsWith("dart")

@FilledStacks How do we add custom TransitionBuilders?

@calebdeji we don't have custom transition builders. We will be working on that for Stacked v3

@FilledStacks, please make sure I can add my ModalsPageRoute.

@ziqq you can make sure and then tell me if you can't.

The doc for this functionality has been created.


Many dependencies from NuGet install

My target framework is 4.6.1 and I plan to run my project on windows and linux (with mono).
When I try to install the nuget package it also tries to install a lot of dependencies that are already available in the mscorlib. I think this is because it also tries to add .NET core/standard libraries, which I don't need or want because the build output becomes gigantic. I even switched my target to 4.5.2 temporarily but didnt seem to help and .NET standard libraries were still being added.
Is it possible to install this package without so many references being added?

That's how netstandard works. We decided to use that technology.


@Crazykev In fact, we can't distinguish a container being killed before and a container that never exist.
(1)、Now runv is stateless actually, the container is running or none.After kill, it just exited.
(2)、There in no api of deleting in containerd.So we can just do like this to work around.
Any good suggestions?

AFAK, for a long term, we need to follow https://github.com/opencontainers/runtime-spec/pull/513 when it land. And in runv, maybe it's more easy to figure out what is the proper way to define delete after we seprerate create and start.
And if this is only a workaround for ocid integration for now, that we need a delete. At least we need to gurantee delete after kill will not fail, that is why I would ask that.

deleting container is  needed, please consider to implement it in containerd.

@YaoZengzeng  @Crazykev runv cli is being improved continuously and had just been refactored at #537 .
Moreover, runv delete was also implemented in #537. Feel free to test ti and give any possible feedback.
Thank you for your contribution.


Wallet should automatically reclaim funds that get blocked

If I spend an output in a transaction that for some reason gets invalidated (the contract in it expires, or another output is double spent), the wallet should automatically detect that a potential transaction has become unspendable, and should reclaim the money.

This isn't fully implemented according to my original vision, but most funds are returned after 80 blocks if they don't make it into the blockchain. Furthermore, the wallet will keep up to date with the things that are and aren't valid in the blockchain and the unconfirmed set. This can be considered finished for the time being.
It's not clear that there's a use case for more difficult invalidations.


:sparkles: add new characters from 2022-08 update

Description
Adds three new characters according to the updated DIN-Version.
Reference
Issues #4

@FabianWilms could you also change the meta fields 🙏

@FabianWilms could you also change the meta fields 🙏

done with c4670da5188065d2af95020a1efbcae2ebfa5b2f


[Bug]: Can't load mod IStumbledTooHardGuys for Stumble guys and version 5.5, 5.6, 5.7 crash

All of the following criteria must be met

[X] All Requirements must be installed.
[x] Full Latest.log file included. If no file exists then leave this unchecked and state so.

All of the following are optional to answer

[x] Tried reinstalling the Game.
[X] Tried reinstalling MelonLoader.
[X] Tried restarting PC.
[X] Was able to see the Start Screen.

Describe the issue.
Can't load mod IStumbledTooHardGuys
[19:01:58.257] ------------------------------
[19:01:58.258] MelonLoader v0.5.3 Open-Beta
[19:01:58.258] OS: Windows 10
[19:01:58.258] Hash Code:<PHONE_NUMBER>009810155102525010010054995798514956995499975410154491005452100
[19:01:58.259] ------------------------------
[19:01:58.259] Name: Stumble Guys
[19:01:58.259] Developer: Kitka Games
[19:01:58.260] Unity Version: 2020.3.38
[19:01:58.260] Game Type: Il2Cpp
[19:01:58.260] Game Arch: x64
[19:01:58.261] ------------------------------
[19:01:58.261] Core::BasePath = E:\Steamtiny10\steamapps\common\Stumble Guys
[19:01:58.300] Game::BasePath = E:\Steamtiny10\steamapps\common\Stumble Guys
[19:01:58.302] Game::DataPath = E:\Steamtiny10\steamapps\common\Stumble Guys\Stumble Guys_Data
[19:01:58.303] Game::ApplicationPath = E:\Steamtiny10\steamapps\common\Stumble Guys\Stumble Guys.exe
[19:01:58.928] Preferences Loaded!
[19:01:58.985] [Il2CppUnityTls] Patching mono_unity_get_unitytls_interface...
[19:01:58.990] [Il2CppUnityTls] Patching il2cpp_unity_install_unitytls_interface...
[19:02:07.427] [Il2CppUnityTls] [ERROR] InstallUnityTlsInterface was not found!
[19:02:07.431] [Il2CppUnityTls] [ERROR] Web Connection based C# Methods may not work as intended.
[19:02:07.434] Loading Plugins...
[19:02:07.444] ------------------------------
[19:02:07.448] No Plugins Loaded!
[19:02:07.450] ------------------------------
[19:02:08.645] Loading Il2CppAssemblyGenerator...
[19:02:08.777] Contacting RemoteAPI...
[19:02:09.449] RemoteAPI.DumperVersion = null
[19:02:09.452] RemoteAPI.UnhollowerVersion = null
[19:02:09.454] RemoteAPI.ObfuscationRegex = null
[19:02:09.456] RemoteAPI.MappingURL = null
[19:02:09.458] RemoteAPI.MappingFileSHA512 = null
[19:02:09.461] Using Dumper Version: 2022.0.0
[19:02:09.470] Using Il2CppAssemblyUnhollower Version = <IP_ADDRESS>
[19:02:09.472] Using Unity Dependencies Version = 2020.3.38
[19:02:09.475] Using Deobfuscation Regex = null
[19:02:09.478] Cpp2IL is up to date.
[19:02:09.481] Il2CppAssemblyUnhollower is up to date.
[19:02:09.487] UnityDependencies is up to date.
[19:02:09.490] Checking GameAssembly...
[19:02:09.934] Assembly is up to date. No Generation Needed.
[19:02:09.953] Game Version: 0.42
**[19:02:09.957] Loading Mods...
[19:02:09.968] [ERROR] Failed to Load Assembly for E:\Steamtiny10\steamapps\common\Stumble Guys\Mods\IStumbledTooHardGuys.dll: System.BadImageFormatException: Invalid assembly
at (wrapper managed-to-native) System.AppDomain.LoadAssemblyRaw(System.AppDomain,byte[],byte[],System.Security.Policy.Evidence,bool)
at System.AppDomain.Load (System.Byte[] rawAssembly, System.Byte[] rawSymbolStore, System.Security.Policy.Evidence securityEvidence, System.Boolean refonly) [0x0000e] in :0
at System.AppDomain.Load (System.Byte[] rawAssembly, System.Byte[] rawSymbolStore, System.Security.Policy.Evidence securityEvidence) [0x00000] in :0
at (wrapper remoting-invoke-with-check) System.AppDomain.Load(byte[],byte[],System.Security.Policy.Evidence)
at System.AppDomain.Load (System.Byte[] rawAssembly, System.Byte[] rawSymbolStore) [0x00000] in :0
at (wrapper remoting-invoke-with-check) System.AppDomain.Load(byte[],byte[])
at System.Reflection.Assembly.Load (System.Byte[] rawAssembly, System.Byte[] rawSymbolStore) [0x00005] in :0
at MelonLoader.Melons.FileHandler.LoadFromByteArray (System.Byte[] filedata, System.Byte[] symbolsdata, System.String filepath) [0x00006] in <239dd078bb4e49c8a1ff8200d76f2e32>:0
[19:02:09.986] [ERROR] Failed to Load Assembly for E:\Steamtiny10\steamapps\common\Stumble Guys\Mods\MoonSharp.Interpreter.dll: No Compatibility Layer Found!**
[19:02:09.993] ------------------------------
[19:02:09.995] No Mods Loaded!
Latest.log
[19:02:09.998] ------------------------------
[19:04:18.799] Preferences Saved!
Did you attach your log file?

[X] Yes, I attached my log file to the text box above.
[ ] No, I could not find a log file at {Game_Directory}\MelonLoader\Latest.log

That assembly is apparently obfuscated, which means that mod is probably malicious and MelonLoader doesn't allow loading that kind of mod, stop cheating and ruining people's fun please.


Fix/todo list overflow issue

Description
It resolved an issue where the todo list overflowed as it grew in size.
Fixes #59
Type of change

[x] Bug fix (non-breaking change)

How Has This Been Tested?

[x ] Test A :  Verified that the todo list correctly handles overflow by adding a large number of items and ensuring no visual or functional issues occur.
[ ] Test B

Checklist:

[x ] My code follows the style guidelines of this project
[x ] I have performed a self-review of my code
[x ] I have commented my code, particularly in hard-to-understand areas
[x ] I have made corresponding changes to the documentation
[x ] My changes generate no new warnings
[x ] Any dependent changes have been merged and published in downstream modules

@Sahil-kushwaha Please run npm run format


docs: update default config object in config-file-options.md

I just installed changesets in a new project and the default config added looks a bit different from what's given in the docs.
Updated the default config object in docs assuming it is outdated.

@bluwy All checks have passed. Can you please merge this? I don't have access to merge the pull request. Thanks!

I'm not the core maintainer around here, so I'd prefer waiting for someone else to review this too before merging. My approval is mostly a pass that it looks good to me.


Multi output tensor

Added multi output network support
example: example_run_age_gender_recognition_retail.py
Restructured resources/nn, added command line option -cnn,--cnn_model
Example:
python3 test.py -cnn person-detection-retail-0013
python3 test.py -cnn mobilenet-ssd
Added support to disable depth calculation on bounding box from network:
-dd,--disable_depth
Added command line option to specify stream list:
-s, --streams
Example:
python3 test.py --streams metaout previewout left right depth_sipp
python3 test.py -s metaout previewout

Was just testing out some of these CLI options, and they work really well! These flags make it SO much nicer to work with. The examples @szabi-luxonis posted above all work, but I didn't thoroughly test the CNNs or multi-network stuff, as I'm not that familiar with it.
One thing I noticed was that even after setting python3 test.py -b 7.5 r 3.5 -e to store the OBC board config to eeprom, the print statements on the next run (python3 test.py) suggested the board settings didn't take:

depthai: Calibration file is not specified, will use default setting;
config_h2d json:
{"_board":{"_homography_right_to_left":[0.988068163394928,0.0029474012553691864,5.067617416381836,-0.008765067905187607,0.9921473264694214,-8.795275688171387,-8.449587767245248e-06,-3.603489403758431e-06,1.0]},"_load_inBlob":true,"_pipeline":{"_streams":[{"name":"metaout"},{"name":"previewout"},{"name":"meta_d2h"}]},"ai":{"calc_dist_to_bb":true},"board":{"clear-eeprom":false,"left_fov_deg":71.86000061035156,"left_to_rgb_distance_m":0.019999999552965164,"left_to_right_distance_m":0.09000000357627869,"override-eeprom":false,"store-to-eeprom":false,"swap-left-and-right-cameras":true},"depth":{"padding_factor":0.30000001192092896}}

Not sure if this is a printing issue or an actual read/write to EEPROM issue. The homography seems to be getting loaded from EEPROM, though, as I don't have a depthai.calib file in my /resources/ directory right now.

Added:
python3 test.py -cnn facial-landmarks-35-adas-0002
python3 test.py -cnn landmarks-regression-retail-0009
python3 test.py -cnn age-gender-recognition-retail-0013
python3 test.py -cnn emotions-recognition-retail-0003

Sweet thanks!

All seems to work well for me.  Tested on microAI (BW1093).
So I do have a question though:
Is there a confidence output from these models?  As it tries to annotate landmarks even when there is no face...  Or is it the case that these models assume there was a successful face-detection (with a confidence thresholding on that detection) prior to this model being run, so there's no reason to have a secondary confidence?

And all models work fine for me.  This version is so much nicer for running various models etc.!
Can't wait to get the multi-stage pipeline builder going so that the face detector is used before these models in a configurable fashion.
LGTM, I think good to merge.
Thoughts @alex-luxonis ?

@Luxonis-Brandon for landmarks recognition there is no confidence, so it assumes that the input is already a face
for age-gender and emotion recognition i added a confidence threshold check, 0.8 (age-gender) and 0.7 (emotion recognition)

Thanks and makes sense.

And I’ll test the updates soon and circle back.  Overall this is looking great to me and would love to get merged to master soon as it makes ll the networks so Blum has easier to use.  And then I’ll update the tutorial on how to use DepthAI shortly after that.
Thought @alex-luxonis?


:green_heart: try to fix wheel test issue on windows.

Description
Please include a summary of the change and which issue is fixed. Please also include relevant motivation and context.
List any dependencies that are required for this change.
Fixes # (issue)
Checklist:

[ ] The pull request only contains commits that are related to it.
[ ] I have added appropriate tests and documentation.
[ ] I have added a changelog entry.
[ ] I have created/adjusted the Python bindings for any new or updated functionality.
[ ] I have made sure that all CI jobs on GitHub pass.
[ ] The pull request introduces no new warnings and follows the project's style guidelines.

@marcelwa After spending several hours, I can now say that the problem is caused by multithreading in QuickSim. I have tried to solve the problem by using std::future without success.
The problem is solved as soon as multithreading is not used. I think this is quite an important issue and topic since multithreading is important for our tools (QuickSim, OpDomain, etc.).

I agree. What exactly is it about the multi-threading that causes this problem do you think?

Have you tried activating the respective sanitizers?


Dice Roll Simulator

Description
Please include a summary of the change and which issue is fixed. List any dependencies that are required for this change.
Fixes #(issue_no)
Replace issue_no with the issue number which is fixed in this PR
Have you read the Contributing Guidelines on Pull Requests?

[ ] Yes
[ ] No

Type of change
Please delete options that are not relevant.

[ ] Bug fix (non-breaking change which fixes an issue)
[ ] New feature (non-breaking change which adds functionality)
[ ] Breaking change (fix or feature that would cause existing functionality to not work as expected)
[ ] This change requires a documentation update
[ ] Documentation Update

Checklist:

[ ] My code follows the style guidelines(Clean Code) of this project
[ ] I have performed a self-review of my own code
[ ] I have commented my code, particularly in hard-to-understand areas
[ ] I have created a helpful and easy to understand README.md
[ ] My documentation follows Template for README.md
[ ] My changes generate no new warnings
[ ] I have added tests/screenshots(if any) that prove my fix is effective or that my feature works.

@avinashkranjan this pull is for issue no #237

@avinashkranjan this pull is for issue no #237

sir plss review it

sir plss review it

@avinashkranjan sir plss review it

@avinashkranjan sir plss review it

@avinashkranjan sir plsssss review it

@avinashkranjan sir plsssss review it


WIP: Fix max_pool_with_argmax behavior on GPU

The PR is still not done yet.

Nagging Assignee @facaiy: It has been 15 days with no activity and this issue has an assignee. Please update the label and/or status accordingly.


update to support duckdb 0.7.0

blocked on this until evidence supports version 43 (0.7.0), but everything else looks good!

ah actually not blocking, can use Buenavista courtesy of @jwills. ok putting this together now.

ah crap running into an error with BV, I think bc the folder structure for the dbt project varies when using meltano compared to a "standard" dbt project.
Traceback (most recent call last):   File "/usr/local/lib/python3.9/runpy.py", line 197, in _run_module_as_main     return _run_code(code, main_globals, None,   File "/usr/local/lib/python3.9/runpy.py", line 87, in _run_code     exec(code, run_globals)   File "/home/vscode/.local/lib/python3.9/site-packages/duckdbt/server.py", line 79, in <module>     raw_profile = raw_profiles[profile_name] KeyError: 'meltano'
so then of course i duplicated the dbt profile into the /transform directory to see if i get a different error:
Traceback (most recent call last):   File "/usr/local/lib/python3.9/runpy.py", line 197, in _run_module_as_main     return _run_code(code, main_globals, None,   File "/usr/local/lib/python3.9/runpy.py", line 87, in _run_code     exec(code, run_globals)   File "/home/vscode/.local/lib/python3.9/site-packages/duckdbt/server.py", line 94, in <module>     base_profile_dict = Profile.from_raw_profiles(   File "/home/vscode/.local/lib/python3.9/site-packages/dbt/config/profile.py", line 392, in from_raw_profiles     return cls.from_raw_profile_info(   File "/home/vscode/.local/lib/python3.9/site-packages/dbt/config/profile.py", line 336, in from_raw_profile_info     target_name, profile_data = cls.render_profile(   File "/home/vscode/.local/lib/python3.9/site-packages/dbt/config/profile.py", line 299, in render_profile     profile_data = renderer.render_data(raw_profile_data)   File "/home/vscode/.local/lib/python3.9/site-packages/dbt/config/renderer.py", line 49, in render_data     return deep_map_render(self.render_entry, data)   File "/home/vscode/.local/lib/python3.9/site-packages/dbt/utils.py", line 228, in deep_map_render     return _deep_map_render(func, value, ())   File "/home/vscode/.local/lib/python3.9/site-packages/dbt/utils.py", line 194, in _deep_map_render     ret = {k: _deep_map_render(func, v, (keypath + (str(k),))) for k, v in value.items()}   File "/home/vscode/.local/lib/python3.9/site-packages/dbt/utils.py", line 194, in <dictcomp>     ret = {k: _deep_map_render(func, v, (keypath + (str(k),))) for k, v in value.items()}   File "/home/vscode/.local/lib/python3.9/site-packages/dbt/utils.py", line 196, in _deep_map_render     ret = func(value, keypath)   File "/home/vscode/.local/lib/python3.9/site-packages/dbt/config/renderer.py", line 33, in render_entry     return self.render_value(value, keypath)   File "/home/vscode/.local/lib/python3.9/site-packages/dbt/config/renderer.py", line 184, in render_value     rendered = super().render_value(value, keypath)   File "/home/vscode/.local/lib/python3.9/site-packages/dbt/config/renderer.py", line 42, in render_value     return get_rendered(value, self.context, native=True)   File "/home/vscode/.local/lib/python3.9/site-packages/dbt/clients/jinja.py", line 587, in get_rendered     return render_template(template, ctx, node)   File "/home/vscode/.local/lib/python3.9/site-packages/dbt/clients/jinja.py", line 542, in render_template     return template.render(ctx)   File "/home/vscode/.local/lib/python3.9/site-packages/dbt/clients/jinja.py", line 183, in render     return self.environment.handle_exception()   File "/home/vscode/.local/lib/python3.9/site-packages/jinja2/environment.py", line 936, in handle_exception     raise rewrite_traceback_stack(source=source)   File "/home/vscode/.local/lib/python3.9/site-packages/dbt/clients/jinja.py", line 140, in quoted_native_concat     head = list(islice(nodes, 2))   File "<template>", line 1, in top-level template code   File "/home/vscode/.local/lib/python3.9/site-packages/jinja2/sandbox.py", line 393, in call     return __context.call(__obj, *args, **kwargs)   File "/home/vscode/.local/lib/python3.9/site-packages/dbt/context/secret.py", line 54, in env_var     raise_parsing_error(msg)   File "/home/vscode/.local/lib/python3.9/site-packages/dbt/exceptions.py", line 449, in raise_parsing_error     raise ParsingException(msg, node) dbt.exceptions.ParsingException: Parsing Error   Env var required but not provided: 'MELTANO_PROJECT_ROOT'
Basically need to "meltano-ize" Buenavista or wait for the node stuff to update to 0.7.0

btw open to thoughts here...

Works great in my fork 💅

Evidence 13.0.0 just released to npm - it includes duckdb dependency update to use 0.7.1 https://github.com/evidence-dev/evidence/pull/654

There were some non-DuckDB-related depenency issues with the 13.X releases. Looks like they just got them ironed out and released 14.0.0. Just tested the Evidence template project with a migrated .duckdb (PR pending https://github.com/evidence-dev/template/pull/36 ) and it works with a 0.7.X file now. You'll want to set your Evidence dependency to "^14.0.0" and change the dev script in analyze/package.json to "evidence dev --open" (the -o flag doesn't work in the new version of vite)

npm run dev isn't working in my codespace (networking issue, looking to be associated with 14.0.0) so I'm pushing to live to check if it works haha. This might break.

closing as completed! its updated!


(#304) Extend AST to support macro definitions and macro calls

Close #304

@rexim looks goode to me! :+1: Thank you for your contribution!


Azure SQL Edge will be retired on September 30th, 2025

According to this announcement, Azure SQL Edge will be retired and have already some compatibility issues.
https://azure.microsoft.com/nb-no/updates?id=azure-sql-edge-retirement
https://github.com/Azure/azure-service-bus-emulator-installer/blob/14d2fd1fc00ef5838de6c85297e8a72d9ac74501/Docker-Compose-Template/docker-compose-default.yml#L21-L22
mcr.microsoft.com/azure-sql-edge:latest should be used

I was going to raise a similar ticket, it's not the end of the world but could we specify a SQL Server instance to use? I always have one running so running a separate instance just for Service Bus takes up more resources.

@deadwards90 this should not be an issue. You can use any a non-prod SQL container instance and spin it up standalone.
Just checked in a sample compose  demonstrating same.

@krishankumar95 That's great, thank you 👍🏻

That’s good information. I already host a Linux SQL Server container instance for development.

Next to that, Azure SQL Edge does not support multi-arch, which is troublesome for us, since we use Apple Silicone based devices as default. Any plans to cope with that?

@nijkampr ; SQL Edge does provide multiple arch support. It has both arm64 and amd64 images available and you can spin the Emulator on any of arm64 arch Mac machines.

The only caveat is open issue at Docker ; which may cause SQL container to crash during launch sometimes which can resolved by recycling the containers.  You can go through the thread for more details.


"This site has been reported as unsafe" and "Deceptive site ahead"

I went to this site this morning using the latest FireFox and got a big red screen with the warning, "Deceptive site ahead".  Viewing the details leads to this link:  https://transparencyreport.google.com/safe-browsing/search?url=https:%2F%2Fopendrr.github.io%2F  Google is reporting that the site is unsafe because it contains pages that, "try to trick visitors into sharing personal info or downloading software".
Oddly, Chrome works.
Tried again with Edge and got, "This site has been reported as unsafe" with the details, "Microsoft recommends you don't continue to this site. It has been reported to Microsoft for containing phishing threats which may try to steal personal or financial information".

Anthony please update this issue. I understand that we've made some headway on resolving these types of errors.

@jvanulde Thank you for notifying me of this issue!  I totally missed this one.
@RobJohnston, thank you so much for reporting!
An equivalent issue was opened by me at https://github.com/OpenDRR/opendrr-platform/issues/119 back on March 13, and thankfully, it got resolved on the same day (within 12 hours of initial discovery) thanks to Google's responsiveness.
The "story" continues on April 14 when it was discovered that CIRA Canadian Shield DNS (which I happened to be using) was blocking our opendrr.github.io site, and VirusTotal detects up to 10 security vendors misclassifying out site as suspicious, phishing or malicious.  Please see the "story" development at https://github.com/OpenDRR/opendrr-platform/issues/122


Cuda is not available after using accelerate launch to run script

System Info
- `Accelerate` version: 0.28.0
- Platform: Linux-5.4.0-173-generic-x86_64-with-glibc2.31
- Python version: 3.10.14
- Numpy version: 1.26.4
- PyTorch version (GPU?): 2.2.1+cu121 (True)
- PyTorch XPU available: False
- PyTorch NPU available: False
- System RAM: 2015.53 GB
- GPU type: NVIDIA A800-SXM4-80GB
- `Accelerate` default config:
        - compute_environment: LOCAL_MACHINE
        - distributed_type: MULTI_GPU
        - mixed_precision: bf16
        - use_cpu: False
        - debug: True
        - num_processes: 8
        - machine_rank: 0
        - num_machines: 1
        - gpu_ids: [0,1,2,3,4,5,6,7]
        - rdzv_backend: static
        - same_network: True
        - main_training_function: main
        - downcast_bf16: no
        - tpu_use_cluster: False
        - tpu_use_sudo: F

Information

[ ] The official example scripts
[X] My own modified scripts

Tasks

[ ] One of the scripts in the examples/ folder of Accelerate or an officially supported no_trainer script in the examples folder of the transformers repo (such as run_no_trainer_glue.py)
[X] My own task or dataset (give details below)

Reproduction
import torch
from accelerate import Accelerator

def main():
    accelerator = Accelerator()
    accelerator.print(torch.cuda.is_available())

if __name__ == "__main__":
    main()

Expected behavior
torch.cuda.is_available() should return True

Hi @MagicianWu, I'm unable to reproduce this behavior. Did you try reinstalling torch with cuda ? Does this happens only after you initialize Accelerator() ?


Multiple api instances for one service

I have 2 same api instances in server A and B. How can Kong forward request to the right server base on request header or something else?
For example, when user call abc.xyz/api, Kong will forward request to server A if the request's host header is A and forward to B if the host header is B?

Hey @lamtrinh since kong 1.3  you can use any header to proxy your requests based on the header. Please refer the link for more information on how to configure your routes.
https://docs.konghq.com/1.3.x/proxy/#request-header
Hope this helps!

@lamtrinh routing based on host header was already supported. From day 1, basically. See the proxy reference https://docs.konghq.com/1.3.x/proxy/#routes-and-matching-capabilities


[vite-node] [ERR_INVALID_URL_SCHEME] /node_modules/swiper/core/core.js

Check that this is really a bug

[X] I confirm

Reproduction link
/
Bug description

Expected Behavior
Importing modules
Actual Behavior
I try to use the latest swiper (V8.4.2) with nuxt 3 (V3.0.0-rc.11). When I try to import a module (e.g. Navigation), the error will pop up.
<template>
  <swiper
    :modules="[Navigation, A11y]"
    slides-per-view="1"
    :space-between="20"
    :breakpoints="{
      640: {
        slidesPerView: 2,
      },
      1280: {
        slidesPerView: 3,
      },
    }"
  >
    <swiper-slide v-for="index in 8" :key="index"> Slide {{ index }} </swiper-slide>
  </swiper>
</template>

<script setup>
// import Swiper core and required modules
import { Navigation, A11y } from "swiper";

// Import Swiper Vue.js components
import { Swiper, SwiperSlide } from "swiper/vue";

// Import Swiper styles
import "swiper/css";
import "swiper/css/navigation";
</script>

{
  "private": true,
  "scripts": {
    "dev": "npx nuxi dev -o --https --ssl-cert localhost.pem --ssl-key localhost-key.pem",
    "build": "nuxt build",
    "generate": "nuxt generate",
    "preview": "nuxt preview",
    "postinstall": "nuxt prepare"
  },
  "devDependencies": {
    "@nuxt/image-edge": "^1.0.0-27719579.87dcdf2",
    "@nuxtjs/tailwindcss": "^5.3.3",
    "@tailwindcss/forms": "^0.5.3",
    "nuxt": "3.0.0-rc.11",
    "sass": "^1.55.0",
    "sass-loader": "^13.0.2"
  },
  "dependencies": {
    "@storyblok/nuxt": "^4.3.0",
    "swiper": "^8.3.1"
  }
}

Swiper version
8.4.2
Platform/Target and Browser Versions
Windows, Chrome 105.0.5195.127
Validations

[X] Follow our Code of Conduct
[X] Read the docs.
[X] Check that there isn't already an issue that request the same feature to avoid creating a duplicate.
[X] Make sure this is a Swiper issue and not a framework-specific issue

Would you like to open a PR for this bug?

[ ] I'm willing to open a PR

You should open this issue on Nuxt i think

you can refer to this issue with nuxt, hope to help
https://github.com/nuxt/framework/issues/5348


add protobuf plugin to intellij setup

Add missing plugin required in README.md

It's not required, I have another issue I thought it was this.


Live refresh not working in secure environments

The preview shows the content at the time the preview window was loaded but fails to update as content is type or even when it is saved.

If you try this out in github codespaces, you will see an error like the following as it tries to upgrade from ws to wss.
Content-Security-Policy: Upgrading insecure request ‘ws://super-acorn-qvp5jgj4rgf97g9-3001.app.github.dev/9125841575581c6d4f0f633b6d1a798ecd199758’ to use ‘wss’
Content-Security-Policy: The page’s settings blocked the loading of a resource (connect-src) at https://github.dev/pf-signin?id=silent-mountain-ck5plmc&cluster=use2&name=super-acorn-qvp5jgj4rgf97g9&port=3001&pb=https%3A%2F%2Fsuper-acorn-qvp5jgj4rgf97g9-3001.app.github.dev%2Fauth%2Fpostback%2Ftunnel%3Frd%3D%252F9125841575581c6d4f0f633b6d1a798ecd199758%26tunnel%3D1 because it violates the following directive: “connect-src ws://super-acorn-qvp5jgj4rgf97g9-3001.app.github.dev/9125841575581c6d4f0f633b6d1a798ecd199758” [fake.html](https://1mn89f2cnojn8som5njndrklrcou4a5mfqmddboac866oqpas2vd.assets.github.dev/stable/dc96b837cf6bb4af9cd736aa3af08cf8279f7685/out/vs/workbench/contrib/webview/browser/pre/fake.html?id=fd0aeb67-29b6-4752-94cd-33c54ebf842a)
Firefox can’t establish a connection to the server at wss://super-acorn-qvp5jgj4rgf97g9-3001.app.github.dev/9125841575581c6d4f0f633b6d1a798ecd199758. [main.js:18:16](https://vscode-remote+codespaces-002bsuper-002dacorn-002dqvp5jgj4rgf97g9.vscode-resource.vscode-cdn.net/home/codespace/.vscode-remote/extensions/ms-vscode.live-server-0.4.13/media/main.js)
WebSocket error: [main.js:39:12](https://vscode-remote+codespaces-002bsuper-002dacorn-002dqvp5jgj4rgf97g9.vscode-resource.vscode-cdn.net/home/codespace/.vscode-remote/extensions/ms-vscode.live-server-0.4.13/media/main.js)
error { target: WebSocket, isTrusted: true, srcElement: WebSocket, currentTarget: WebSocket, eventPhase: 2, bubbles: false, cancelable: false, returnValue: true, defaultPrevented: false, composed: false, … }

In other contexts, you will see a "Mixed Content" error.

It turns out that the failure of live refresh in codespaces in addressed in the FAQ under "I'm trying to use Live Preview in Codespaces and the embedded preview isn't working."
Meanwhile, the CSP errors listed above are actually related to a different websocket connection that has an obscure role in handling navigation history.
Closing.


Very high WER % in extensive benchmark on Fleurs

On which dataset did you exactly evaluate the model? I benchmarked this model on the original Fleurs dataset, along with all other implementations of whisper. It performed way worse with a WER% of 1.5, compared to ~0.46 in original whisper. Did I make an implementation error?
Here is how I initialize the model with temp=0, beams=1, do_sample=True:
model = "distil-whisper/distil-large-v2"
        obj = pipeline(model=model,
                       torch_dtype=parameters["torch_dtype"],
                       device=device,  # or mps for Mac devices
                       chunk_length_s=15,
                       batch_size=parameters["batch_size"],
                       return_timestamps=False,
                       model_kwargs={"use_flash_attention_2": parameters["flash"]},
                       generate_kwargs={"task": "transcribe",
                                        "num_beams": parameters["beam_size"],
                                        "temperature": parameters["temperature"],
                                        "do_sample": parameters["do_sample"]
                                        }
                       )
        if not parameters["flash"]:
            logging.debug("Using Better Transformers without Flash Attention")
            obj.model = obj.model.to_bettertransformer()
        else:
            logging.debug("Using Flash Attention 2")

This how I call the transcribe:
tmp = model(audiopath,
                    generate_kwargs={"language": lang}
                    )
res = [i["text"] for i in tmp]

I am sorry, I just overread that distil-whisper is english only (even though it performs very well on a few other languages as well).

Hey @asusdisciple, no worries! If you're interested in a training Whisper on a different language, you can leverage the training code under distil-whisper/training. I recommend first setting up a baseline using these instructions: https://huggingface.co/sanchit-gandhi/distil-whisper-large-v3-de-kd#training-procedure


[Feat]: Development of TechDisplay Page and Home Page Setup

What feature?
Hello, this is Isha Prajapati. I’d like to take on the task of developing the homepage and setting up the TechDisplay page, as mentioned in issue no. #475. I’d appreciate it if you could assign this to me.
Thank you!
Add screenshots
Add screenshots
Code of Conduct

[X] I agree to follow this project's Code of Conduct

@ishap11 Kindly assign me this task under Hacktoberfest2024, Thanku.

Hello @Musaveershaik, could you please check issue #475 ? Choose any one of the features you'd like to add to DevDisplay, then create a new issue referencing the main issue number (#475).


Can there be an option to auto-rebaseline after failure?

Hi! At first glance it looks useful to get rid of extra actions the user needs to do to re-baseline dependencies:

update deps and get the build error
./gradlew dependencyGuardBaseline
commit updated baselines to git
build again

But, on the other hand, if "auto-rebaseline" will be in gradle's plugin configuration and everything will be done automatically, it will be implicit and less transparent. It will be easy to forget to commit updated baselines to git after auto-rebaseline. In such case it will be unclear, why build is successful on local machine, but fails on CI.
There could be a build flag to explicitly specify that baselines must be updated in case of error. Also there could be corresponding message in build log after auto-rebaseline.
./gradlew :app:assembleDebug --dependency-guard-auto-rebaseline
Another question — should all the baselines in the project be updated in such case or only baselines in the module being build?
Actually, the most explicit way is to get build error and re-baseline manually. It won't take a lot of time, especially with configuration cache enabled, because re-baselining itself takes less than 1 second even on the large-scale project. And the command to re-baseline is listed in the build error.


Documentation

There is a lot documentation on how to build the sanity cms (https://www.sanity.io/docs) but I coudn't find sufficient documentation on how to use the fetched data on the client side, which describes how to use sanity-io/block-content-to-react library with serializers e.g. types, marks, list, listItem to render custom react components.
Is there a hidden documentation I missed?

+1 on this with attention to React Native as well

I find the documentation on the github README confusing as well.

When will the documentation be updated to align with the samples provided in the Sanity starter projects? -- have been trying to make this work under the NextJS e-Commerce starter (sanity.js file) where PortableText along with empty serliazers object -- have put basic h1/h2 tag processing int here and it doesn't work....it doesn't even work when mushed together inside [slug].js in the root directory of the frontend.
This link is also useless https://www.sanity.io/guides/portable-text-internal-and-external-links#render-the-links-with-react-b14f77c2e796

When will the documentation be updated to align with the samples provided in the Sanity starter projects? -- have been trying to make this work under the NextJS e-Commerce starter (sanity.js file) where PortableText along with empty serliazers object -- have put basic h1/h2 tag processing int here and it doesn't work....it doesn't even work when mushed together inside [slug].js in the root directory of the frontend.
This link is also useless https://www.sanity.io/guides/portable-text-internal-and-external-links#render-the-links-with-react-b14f77c2e796

Figured it out
here's my seralizer object in case anyone's looking for some tips to get started
`// Set up Portable Text serialization
export const PortableText = createPortableTextComponent({
...config,
// Serializers passed to @sanity/block-content-to-react
// (https://github.com/sanity-io/block-content-to-react)
// implement inline icon serializer from https://medium.com/@kimbjrkman/how-to-use-inline-images-in-rich-text-with-sanity-io-c42594baa509
serializers: {
types: {
// render video block
videoEmbed: (props) => {
// const { url } = props.node.url;
    if (!props.node.url) {
      console.log("video props ->", props);
      return null;
    }

    return (
      <>

                <ReactPlayer url={props.node.url} controls />

      </>
    );
  },

  // render text blocks
  block: (props) => {
    const style = props.node.style || "normal";
    if (style == "h1") {
      return (

          {props.children}

      );
    }
    if (style == "h2") {
      return (

          {props.children}

      );
    }
    if (style == "h3") {
      return (

          {props.children}

      );
    }

    if (/^h\d/.test(style)) {
      const level = style.replace(/[^\d]/g, "");
      return React.createElement(`h${level}`, {}, props.children);
    }

    return style === "blockquote" ? (

– {props.children}

    ) : (

{props.children}

    );
  },
  // render code block
  code: (props) => (

      {props.node.code}

  ),

  // render image
  mainImage: (props) => (

{props.node.caption}

  ),
},
list: (props) =>
  // console.log("list", props) ||
  props.type === "bullet" ? (

{props.children}

  ) : (

{props.children}

  ),
listItem: (props) =>
  console.log("list", props) ||
  (props.type === "bullet" ? (

{props.children}

  ) : (

{props.children}

  )),
marks: {
  strong: (props) =>
    console.log("strong", props) || {props.children},
  em: (props) => console.log("em", props) || {props.children},
  code: (props) =>
    console.log("code", props) || {props.children},
  externalLink: (props) => {
    return (
      <Link href={props.mark.url}>

          {props.children}

      </Link>
    );
  },
},

},
});`

Closing this, as the new @portabletext/react library is the successor to this module.
Please see https://github.com/portabletext/react-portabletext


My implementation is showing no divider. How can I use f.e "<" as a divider?

Hello there,
This is what my front looks like:
https://i.gyazo.com/0585fdb66bbd34e79ab15ad1b5cc2a0c.png
Here's the implementation:
https://i.gyazo.com/f9ac2441d1c80220f8724b8a27550355.png
Is there a way to use "<" as a divider?
I can push it through in the routes file, but that doesn't really seem clean:
https://i.gyazo.com/54cd557edbb082536f4e46474ce3bff6.png

Hey @aFluxx, It seems to be the best option to do this with CSS. For instance:
.breadcrumb-item+.breadcrumb-item::before {
    display: inline-block;
    padding-right: .5rem;
    color: #6c757d;
    content: "<";
}

If this does not suit you for some reason, you can use your Blade template.

Hey Tabuna,
Thanks! That'll do just fine!