[consensus] switch the vote/TC serde from bcs to json

Motivation
This commit switches the serde format for vote/TC in consensusdb from bcs to json to allow
future backward compatible changes to the struct (as required in 2-chain commit).
Have you read the Contributing Guidelines on pull requests?
(Write your answer here.)
Test Plan
(Share your test plan here. If you changed code, please provide us with clear instructions for verifying that your changes work.)
Related PRs
(If this PR adds or changes functionality, please take some time to update or suggest changes to the docs at https://developers.diem.com, and link to your PR here.)
If targeting a release branch, please fill the below out as well

Justification and breaking nature (who does it affect? validators, full nodes, tooling, operators, AOS, etc.)
Comprehensive test results that demonstrate the fix working and not breaking existing workflows.
Why we must have it for V1 launch.
What workarounds and alternative we have if we do not push the PR.

since this approach requires cherry pick, I'm going another route in https://github.com/diem/diem/pull/8915


ADD ROADMAP

Related Issue
Fixes: #1586
Description
The existing documentation may lack clarity in outlining the project's future features. To enhance it, specific details on planned updates, improvements, or new functionalities will be added, along with timelines for implementation. Deleting any vague statements or redundant information will streamline the section. Additionally, structuring the roadmap with bullet points or sections for each feature will improve readability and allow contributors to understand the project's direction easily.
Type of PR

[ ] Bug fix
[ ] Feature enhancement
[x] Documentation update
[ ] Other (specify): _______________

Screenshots/videos (if applicable)

Checklist:

[x] I have made this change from my own.
[ ] I have taken help from some online resources.
[x] My code follows the style guidelines of this project.
[x] I have performed a self-review of my own 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] I have tested the changes thoroughly before submitting this pull request.
[x] I have provided relevant issue numbers and screenshots after making the changes.

@PriyaGhosal  kindly review the PR

@PriyaGhosal kindly review the PR

@PriyaGhosal

@PriyaGhosal kindly review the PR

@PriyaGhosal kindly review the PR

@PriyaGhosal

@PriyaGhosal kindly review the PR

@PriyaGhosal

@PriyaGhosal kindly review the PR

@PriyaGhosal

@alo7lika Sorry but this is not required in readme


C_CPP : Multiple inheritance in C++ Video submission

Description
I will be submitting a video on multiple inheritance in C++.
Domain
C/CPP
Type of Contribution
Video
Code of Conduct

[X] I follow Contributing Guidelines & Code of conduct of this project.

/assign


When attempting to load a 360 video the player is stuck at "loading"

I have followed the example for 360 video but find myself stuck with the following experience:

With the built in HTML5 video player the video plays fine:

Any ideas on why I am getting stuck on the loading screen?  I am not seeing any errors, and I have confirmed videojs-pannellum-plugin.js is loading.

Without more information, I can't be of much help. Can you post your code?

I have since changed the code a little bit but am still running into similar behavior.
The app I am working with is written in BackboneJS.  The video element has an id derived from the video files id this.model.get('id').  I am using your sample video (path stored in url) for sanity.
Below is some straightforward code where I am adding attributes to a empty video element.  I am then passing the element to videojs.
var element, elementSource, url;

url = 'https://pannellum.org/images/video/jfk.webm';

element = document.getElementById(this.model.get('id'));

element.classList.add("video-js");

element.classList.add("vjs-default-skin");

element.classList.add("vjs-big-play-centered");

elementSource = document.createElement('source');

elementSource.src = url;

elementSource.type = 'video/webm';

element.appendChild(elementSource);

videojs("" + (this.model.get('id')), {
  plugins: {
    pannellum: {}
  }
});

With this code I just get stuck at the loading screen:

If I remove the following the video plays in the built in html5 viewer:
videojs("" + (this.model.get('id')), {
  plugins: {
    pannellum: {}
  }
});

When the above code is removed this is what the video element looks like:
<video id="2158958359" width="1920" height="960" class="image imageWider imageTaller thinner active video-js vjs-default-skin vjs-big-play-centered"><source src="https://pannellum.org/images/video/jfk.webm" type="video/webm"></video>

Here is the element when videojs loads it:
<video id="2158958359_html5_api" class="vjs-tech imageWider imageTaller thinner" src="https://pannellum.org/images/video/jfk.webm" style="display: none;"><source src="https://pannellum.org/images/video/jfk.webm" type="video/webm"></video>

src="https://pannellum.org/images/video/jfk.webm" style="display: none;" looks weird to me... not sure if that is the issue though.  Any ideas?

For reference, in your example this is the final video element:
<video id="panorama_html5_api" class="vjs-tech" preload="none" style="width: 100%; height: 400px; display: none;" poster="/images/video/jfk-poster.jpg" data-setup="{}" src="https://pannellum.org/images/video/jfk.webm">
<source src="https://pannellum.org/images/video/jfk.webm" type="video/webm">
<source src="https://pannellum.org/images/video/jfk.mp4" type="video/mp4">

To view this video please enable JavaScript, and consider upgrading to
a web browser that supports HTML5 video

</video>

After I posted the above code I was thinking there are too many variables to debug this properly.  I went ahead and created a simple html file based on your example with videojs and pannellum both local.  You can download this example project here:
https://www.dropbox.com/s/8tzaxllborweuqp/pannellum-example.zip
In this example I am running into the same behavior (stuck at loading).  This time, however, I am seeing an error in the dev console:

You should be able to reproduce this by opening sample.html in the example project.
I am running macOS 10.12 and Chrome Version 53.0.2785.116 (64-bit).

I had another idea of using the html from your example page to see if I could get it to work locally as well.  I ran into the same loading issue, but without the error in the dev console.  Here is a new zip file with that project.  The html file is sample2.html.
https://www.dropbox.com/s/hd5fr1f6lgu6afl/pannellum-example 2.zip?dl=0
Here is a gif of the behavior:

You're using the non-minified development JavaScript. When doing this, libpannellum.js needs to be included as well (they're combined into one file when the production copy is built). This is why you're getting a libpannellum is not defined error.

@mpetroff thanks for the feedback.
I went ahead and simplified my example project even more just trying to get this to work.  Here is what it contains:

minified pannellum.js version 2.2.1 downloaded from https://pannellum.org/download/
minified video.js version 5.4.6 which is identical to the example at https://pannellum.org/documentation/examples/video/
videojs-pannellum-plugin.js latest master located at https://github.com/mpetroff/pannellum/blob/master/utils/video/videojs-pannellum-plugin.js
using your sample videos and poster
all scripts, css, and content are local to the html doc

Here is the HTML:
<!DOCTYPE html>

    <meta charset="utf-8">
    <title>Pannellum Video Demo</title>
    <link rel="stylesheet" href="pannellum.css" />

    <link href="video-js.css" rel="stylesheet" type="text/css">

    <video id="panorama" class="video-js vjs-default-skin vjs-big-play-centered" controls preload="none" style="width:100%;height:400px;" poster="jfk-poster.jpg" data-setup="{}">
    <source src="jfk.webm" type="video/webm"/>
    <source src="jfk.mp4" type="video/mp4"/>

        To view this video please enable JavaScript, and consider upgrading to
        a web browser that supports HTML5 video

</video>

I am still stuck with a loading screen.  You can hear the audio though so the video is "playing".

Here is my example project in an archive:
https://www.dropbox.com/s/8tcx2ae8vzyisag/pannellum-example 3.zip

Alright the plot thickens.  The example project in my last reply appears to be working in Safari.  So here is what I am seeing:
I am running macOS Sierra 10.12.

Safari Version 10.0 (126<IP_ADDRESS>.10) -- works
Firefox Version 49.0 -- works
Chrome Version 53.0.2785.143 (64-bit) -- stuck at loading

The odd thing is that with Chrome the example at https://pannellum.org/documentation/examples/video/ loads without issue.

I think I have hit a chrome bug.  If I serve the example project with python's SimpleHTTPServer Chrome loads the 360 video just fine.

As I mention in the readme, a local web server should always be used. Otherwise, you end up dealing with the peculiarities of the local filesystem security restrictions of different browsers, with different things working in different browsers, as is the case here. What you describe as a Chrome bug is just Chrome's more restrictive security policy.

Understood.  I think I am narrowing down the issue and appreciate your feedback.
So as I described above Pannellum is now working when running from a web server and all assets are local.  If the source is not from the same origin I get the same "Loading" issue.
So continuing with my example, here is the video element in my sample.html doc:
<video id="panorama" class="video-js vjs-default-skin vjs-big-play-centered" controls preload="none" style="width:100%;height:400px;" poster="jfk-poster.jpg" data-setup="{}">
    <source src="jfk.webm" type="video/webm"/>
    <source src="jfk.mp4" type="video/mp4"/>

        To view this video please enable JavaScript, and consider upgrading to
        a web browser that supports HTML5 video

</video>

I am using the python's SimpleHTTPServer (python -m SimpleHTTPServer) for testing in this case.  In the above example the video source is being served via http://localhost:8000/jfk.webm according to the dev console.  This works great, 360 playback looks good.
If I modify the source of the video then I run into issues:
<video id="panorama" class="video-js vjs-default-skin vjs-big-play-centered" controls preload="none" style="width:100%;height:400px;" poster="jfk-poster.jpg" data-setup="{}">
    <source src="https://pannellum.org/images/video/jfk.webm" type="video/webm"/>
    <source src="https://pannellum.org/images/video/jfk.mp4" type="video/mp4"/>

        To view this video please enable JavaScript, and consider upgrading to
        a web browser that supports HTML5 video

</video>

In the above example the source is https://pannellum.org/images/video/jfk.webm, this causes the visual portion of the video player to be stuck at the loading screen, meanwhile the video is "playing" because you can hear the audio.  If I modify video.js to not load the Pannellum plugin, video playback is fine (of course minus the 360 support).
Here is the example project I am working out of with the video sources pointing to https://pannellum.org/images/video/ (when in the pannellum-example directory simply run python -m SimpleHTTPServer then go to http://localhost:8000/sample.html):
https://www.dropbox.com/s/mgmf0y9ij6ge41c/pannellum-example 4.zip

Digging further into this I used pannellum.js and libpannellum.js from https://github.com/mpetroff/pannellum/tree/master/src/js.
With the video element src is local it works fine like above. When I try using the externally hosted video I now see the following error in the dev console:

I am reading that as in order to load WebGL content it must come from the same source, which would explain why the 360 content won't load.  Is this correct?

This is violating the browser's same-origin security policy, since a CORS header isn't being set. The video itself works fine, which is why the audio plays, since the same-origin policy only applies to JavaScript.
You need to add a crossorigin="anonymous" attribute to the <video> element, e.g. <video id="panorama" class="video-js vjs-default-skin vjs-big-play-centered" controls preload="none" style="width:100%;height:400px;" poster="jfk-poster.jpg" data-setup="{}" crossorigin="anonymous">. I just updated the example to reflect this.

Thanks for the crossorigin="anonymous" -- this is working much better now!


PDF is cut when printing/downloading

I posted my question here
https://stackoverflow.com/questions/69122130/html2pdf-pdf-download-is-short-and-not-correct
I dont understand why it is cut and short when printing. Can you please help?

This is probably not happening if you use version 0.9 - try https://www.boreal-appliances.com/wp-content/themes/hello-theme-child/htmltoPDF.js and check
In my case, since they updated a few days ago everything went to 💩 on the instances we used it.
Reverting to 0.9 resolved the issues (which sound pretty similar to yours, PDF empty/cut off, missing parts, etc)

Hi @TukuToi how can I apply the advance usage to this version? https://www.boreal-appliances.com/wp-content/themes/hello-theme-child/htmltoPDF.js

Hi @TukuToi thank you very much for this, but I have a problem with the letter spacing of the content when I generate the file. Did you encounter that kind of issue?
TIA

Thanks for this one @TukuToi.

Hi, I've had a few reports of things looking worse in v0.10. My guess is that it's due to changes in the dependency html2canvas - I'm putting together some tooling to try to see what's going on.
@VinceSanityyy @TukuToi I'll post here again when I have something up, would be helpful if you could test your issues against a few different versions.

@eKoopmans thanks!
You probably want to re-open this issue, since it was closed somehow (mistakenly probably)
I tested the issues I found with several versions and the only I found working was the one I had used originally, which is the one I link in my first comment on this issue (https://github.com/eKoopmans/html2pdf.js/issues/473#issuecomment-916882318)

Hello @TukuToi . The cut issue is solved with your solution. Unfortunately i didint notice it removes the underline of the underlined words. (it is in the stackoverflow question ididint notice it earlier)

Given that is a way minor issue compared to the actual mess created with 0.10, I would suggest you open another issue for that, also because if it happens with 0.9, it means it is around since quite a while.
This way, they can resolve each issue one by one instead of bulk-debugging which never really goes well ;)

Okay. I thought you got some idea about it. Thanks @TukuToi


Use the new TranslationResult properties from ctranslate2

Hello,
I noticed a deprecation warning when running the FewShotTranslation.apply_packaged_translation method:

DeprecationWarning: Reading the TranslationResult object as a list of dictionaries is deprecated and will be removed in a futur version. Please use the object attributes as described in the documentation: https://opennmt.net/CTranslate2/python/ctranslate2.TranslationResult.html

This could lead to an exception:
> translated_tokens += translated_batch[i]["tokens"]
SystemError: <built-in method __getitem__ of PyCapsule object at 0x7d8642cd7d80> returned a result with an exception set

So I simply used the new properties as suggested by ctranslate2.
Let me know if you want me to add a safer access to the properties for retro-compatibility.
Thanks for the great tool!

Hello :wave:
Just wanted to check if you could review my PR ; Unfortunately this error is a bit blocking for me.

Good catch thank you!

I pushed this change in v1.9.5

Wonderful, thanks!

Why was this causing issues for you? This fix is definitely correct but I've never seen the deprecated version cause problems.


PowerToys.exe waking my PC from sleep very often

Microsoft PowerToys version
0.37.2
Running as admin

[X] Yes

Area(s) with issue?
General
Steps to reproduce
my PC seems to be waking from sleep very often, usually within 2 minutes of being set to sleep/standby. Running the 'powercfg lastwake' command seems to indicate that powertoys is the culprit. Excuse me if this is a known issue, i've tried to google it but have not been able to find a relatable issue/solution.

PowerToysReport_2021-05-26-13-43-48.zip
✔ Expected Behavior
PC being in sleep mode
❌ Actual Behavior
PC wakes up, powercfg indicated that PowerToys.exe is the culprit
Other Software
No response

@Runer23
we have never seen this problem before.
Does it happen all the times you put the PC to sleep?

I think it happens around 90% of the time. I will try later today if it doesn't happen when I close powertoys, I honestly have not tried that. the fact that you've never seen this before makes me suspect it might have to do with my windows installation.

@Runer23 the only thing that can be involved is the daily checked, try do disabled it.

@Runer23 the only thing that can be involved is the daily checked, try do disabled it.

@Runer23 the only thing that can keep the computer wake, could be the daily check for an update.

It's been happening regularly, but haven't been able to reproduce it this weekend... I did try to disable check for update in the past, but that didn't work. I'll watch if it starts happening again soon

@Runer23
the check for updates cannot be unchecked, it can only set the auto-download to false.

@enricogior you're right, i didnt notice that.
It did happen again today, but the "Last succesfully checked:" mentioned by powertoys does not add up to the time it actually happened. Maybe it UNsuccesfully checked?

@Runer23 does it happen with the latest version as well?

@yuyoyuppe Sorry for the silence, i've recently rebuild my pc, and with that came a completely clean windows installation. I've not yet installed the latest version, im on v0.41.3, but i've had it happen a few times over the past weeks. I feel like it's way rarer than before, whether that's due to my clean windows installation or the software itself, i dont know. I'll upgrade right now and respond if it happens again! Thank you!

It happened again today. Im not sure about the frequency since I haven't used my pc often last week, but 'powercfg lastwake' reports the following:
Wake History Count - 1 Wake History [0]   Wake Source Count - 1   Wake Source [0]     Type: Wake Timer     Owner: [PROCESS] \Device\HarddiskVolume3\Program Files\PowerToys\modules\FancyZones\PowerToys.FancyZones.exe
I guess that narrows it down to fancyzones, this is my fancyzones config:

@Runer23 can attach updated logs to this thread from the Report Bug tool?

Reopening this old issue as I'm having the same issue since I updated 0.72.0. I forgot which one I had previously, hadn't updated in a while.
My PC keeps getting woken up since the update. From the event viewer:
The system has returned from a low power state.

Sleep Time: 2023-08-27T19:44:15.612313200Z
Wake Time: 2023-08-27T19:46:07.381000800Z

Wake Source: Timer - PowerToys.Peek.UI.exe

I have the Awake feature turned off

Any help would be great as I don't want to keep turning off power toys before hibernating and turning it back on when I boot my PC back up


String returns

Validation methods now accept types that implement IEnumerable as a return type, in this case, the key field in the DomainError will be the name of the first received argument, or its renamed name set using the DlvDomainRename attribute


Emphasise required return

Summary
Emphasise that .rejects and .resolves still require the assertion to be returned, in response to #4997.
Test plan
Validated output was valid at least in GitHub's Markdown renderer.

Codecov Report

Merging #4999 into master will not change coverage.
The diff coverage is n/a.

@@           Coverage Diff           @@
##           master    #4999   +/-   ##
=======================================
  Coverage   60.31%   60.31%
=======================================
  Files         198      198
  Lines        6662     6662
  Branches        4        4
=======================================
  Hits         4018     4018
  Misses       2644     2644

Continue to review full report at Codecov.

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

Works for me.


Avoid unnecessary system calls in redisAsyncCommand()

Currently, this is how async operations work:
1- Append new command to the output buffer.
2-  __redisAsyncCommand() registers write event unconditionally.
3-  redisAsyncWrite() will be called on the next iteration of the event loop.
4- Write event will be cleared.
Steps 2 and 4 are system calls. They introduce unnecessary overhead.
For better performance, we can directly write to the socket(step-3)
without registering a write event. Still, it is better to detect if the write
event is already registered. In this case, we won't try to write to the socket
as it will probably fail (because the socket buffer is full).

This looks correct to me at first glance, although I didn't write the async layer.
How big a performance improvement are you seeing with it, assuming you're using the new logic?

Hi, @michael-grunder
I see %2 - %20 improvement in my use case. (I use hiredis as part of a bigger project, so a loop benchmark with hiredis commands only probably would give us even better results).
I'm pretty sure this is how we are supposed to use event loops. (Write to socket first, if it is partial, register for the write event).
The downside is, now inside redisAsyncCommand(), we can call __redisAsyncDisconnect() which will trigger disconnect/cleanup callbacks. Not sure if this is a problem or surprising to anybody. Other than that, I don't see a problem but maybe I'm missing something, let's bring more people with async API experience, @yossigo wdty?

@tezc I agree that generally, one should create the write event only after failing to write. In this specific case, I think it will take a bit more to handle it well.
Invoking the disconnect callback directly from redisAsyncCommand() is a significant breaking change and makes the API less intuitive. We could return an error and defer the callback to the next event loop iteration, but that will be a lot more complex than this simple change.
The other point is that the async interface does not have explicit pipelining support (like redisAppendCommand()), so pipelining has to rely on this behavior, and we'll need to come up with an alternative.
Another option to consider is to create a new redisUnbufferredAsyncCommand(), to be used when the extra delay is not desired.

I think the improvement is worth making, but we'll need to make sure not to introduce any breaking changes.
I'm planning on putting together v1.1.0 this weekend, and then we can revisit this PR for the next release.

Okay, I'll see what I can do. Sure, we can revisit this later.


Unite and simplify repositories

Make old duo-firmware repo work with new branch
When it works, move firmware to this repo, and make duo-firmware have the subrepo.

This was finished in commit  https://github.com/datomusic/duo-imxrt/commit/2f7793ee0ea26903f10ddf17547200d2774ca65d
I propose we close this issue once we've verified that brains1 and brains2 builds are working 100% and once we've cleaned up stray files and branches

[ ] brains1 build working
[ ] brains2 build working
[ ] clean up stray branches
[ ] clean up stray files

Closing this in favour of https://github.com/datomusic/duo-imxrt/issues/150


Add Android-specific images

Can you please create a set of Android-specific images (much like the JS and Rust ones), since by default Github Actions contain the Android SDK tools?

is there any update on this?

I recommend using full image, maintaining tooling-specific images takes a lot of time and capacity which we don't have.


⚠ Bofrost.at has degraded performance

In 592fdfc, Bofrost.at (https://www.bofrost.at) experienced degraded performance:

HTTP code: 200
Response time: 1166 ms

Resolved: Bofrost.at performance has improved in 58019a3.


Ferdi crashes when suspending the system

Describe the bug
After waking my system from suspend, Ferdi reloads all services.
It always looks the same like when I restart ferdi, because it also connects to the API.
Therefor I suspect that ferdi crashes but then restarts itself.
Expected behavior
Ferdi should stay open, even when suspending my laptop.
Desktop:

OS: Arch Linux
Kernel: 5.5.7-arch1-1
Ferdi Version: 5.4.3
Server Used: https://api.getferdi.com

Additional information
This is the console output I am getting during this:
Attempting to call a function in a renderer window that has been closed or released.
Function provided here: AppStore.js:1:6788
Remote event names: suspend
Attempting to call a function in a renderer window that has been closed or released.
Function provided here: AppStore.js:1:6909
Remote event names: resume
Attempting to call a function in a renderer window that has been closed or released.
Function provided here: AppStore.js:1:5366
Attempting to call a function in a renderer window that has been closed or released.
Function provided here: SettingsStore.js:1:2900
Attempting to call a function in a renderer window that has been closed or released.
Function provided here: AppStore.js:1:5366
Attempting to call a function in a renderer window that has been closed or released.
Function provided here: SettingsStore.js:1:3103
Attempting to call a function in a renderer window that has been closed or released.
Function provided here: AppStore.js:1:5366
Attempting to call a function in a renderer window that has been closed or released.
Function provided here: SettingsStore.js:1:2900
Attempting to call a function in a renderer window that has been closed or released.
Function provided here: AppStore.js:1:5366
Attempting to call a function in a renderer window that has been closed or released.
Function provided here: SettingsStore.js:1:3103

Thank you for reporting this @n0emis!

Bug is probably introduced by
https://github.com/getferdi/ferdi/blob/eff719b87c60097342d393922048662c32255d88/src/stores/AppStore.js#L202-L212

I tried update ferdi to the newest dev-version (5.4.4-beta.2 ), but this unfortunately didn't resolve my problem. But I was able to export the debug-infos:
https://debug.getferdi.com/6f7575ed-97a4-4cd7-a46b-7c74f229814b

Is you problem just that Ferdi restarts when you power your system back on? Because that is expected behaviour due to the code I sent above.

Is you problem just that Ferdi restarts when you power your system back on? Because that is expected behaviour due to the code I sent above.

@vantezzen Ah ok, sorry. I've overlooked your reply... Would it be possible to make this feature optional (deactivatable) with a config-setting?

Shipped in v5.4.4-beta.3.


Add a faucet for testnet3 and testnet4 coins

We should add a faucet on our website to distribute testnet coins mined during our testings.
Here a list of resources that I found:

bitcoin-faucet in node.js: https://github.com/jprichardson/bitcoin-faucet
recaptcha for vue.js: https://dansnow.github.io/vue-recaptcha/guide

npm module: https://www.npmjs.com/package/vue-recaptcha

Not convinced this should be on this website, but let's see what others think. There are way more higher priority tasks for this repo than this one, that's for sure.


Initial support for GraphQL path guards

Overview
Juniper should support authenticated paths in some way. Instead of using external macros, this PR provides trait based guards which are evaluated before the actual field is resolved. If the guard fails, the whole evaluation fails and an FieldError is returned. Besides allowing early aborts, it is also possible to change the context. For example, if the user is in a privileged group, then we can exchange the context. The new context contains additional information and it could be ensured that no re-check of the same permission happens again.
How does the context change work?
Each object defines their context. The guards may require a specific context. If both contexts are compatible, then the guard can be used. The guard also defines how the output context look like, its is still possible to forward the old context. To annotate a field use #[graphql(Guard = "..")]. Notice that guards are only support for object fields, at least for now.
Authentication
With this PR it is possible to define permission systems on top of Juniper. The current testing cases implement a basic role-based authentication system. Take a look at the source to get a feeling how this feature is used.
Related

https://github.com/graphql-rust/juniper/issues/600
https://github.com/graphql-rust/juniper/issues/447

Progress

[x] basic implementation
[x] combinators (and_then)
[ ] sync support?
[ ] tests
[x] documentation for this features
[x] documentation for this authentication

Not fully done yet. Tests are missing, docs are not perfect, and the book examples do not compile. However, the basic constructs should be established. Would love to hear some initial feedback about this feature.
The only question which is is not solved now is: how to handle non-async. For now I ignored sync code since it should be removed anytime soon. As a result, the guards only support async resolvers and only provide async interface.

My main concern here (and a lot of the other outstanding PRs) is this is making Juniper more opinionated and less of a library and more of a framework.

Not sure about this. The whole proc macros are kind of a framework which uses the underlying library? This PR modifies the code generation in a way which allows to "intercept" the evaluation. Maybe you can expand what you expect, or if such a feature should be possible or not.
The general problem I see right now, is that it is not possible to have custom attribute macros. The order of macros is not specified, thus we can not ensure that their macro is called before. Furthermore, the user must define two procs, like we do, for impl blocks and structs. As a result, proc macros can not be used as a plugin architecture for fields. In the end, this means the user has to use the #[graphl_object] macro for all structs, if the fields must be must run custom logic before the actual evaluation.

To quote the Best Practices page on graphql.org for Authorization:

Enforcing this kind of behavior should happen in the business logic layer.

The page goes on to give examples and details and makes it pretty clear that defining permissions systems on top of Juniper is not recommended.
That being the viewpoint of the GraphQL Foundation (and of myself), I don't think this sort of functionality should be considered.

Agreed! If Juniper doesn't have the proper hooks, please open an issue on the missing extension / integration point.

@ccbrown are you able to name another graphql library that doesn't? Apollo Server does, HotChocolate does, graphql-dotnet does, prisma recommends to use apollo servers auth, etc etc.
Just saying, that spec typically doesn't follow reality, with every company (besides facebook apparently) even versioning their apis: https://developer.github.com/v4/breaking_changes/ .
Would it be happier if this was a sister package? I would argue this is a basics that comes with most  other libraries. Just giving my experience from using other libraries, if this just isn't wanted that's completely in your right, but it would definitely lead to a lower adoption.

The most popular / comparable library for Golang, graphql-go/graphql, does not have any support for this. The only other popular one I've actually used at scale is samsarahq/thunder, which also does not have any support for this. Without looking, my gut says it would not be very hard at all to find more and this probably isn't the kind of situation where lack of the feature is going to be a significant burden to adopters.
This might be reasonable as a sister package, but I would guess the ideal solution here is really to just implement custom directives support (https://github.com/graphql-rust/juniper/issues/156). That would make Apollo Server-like authentication via custom directives possible without making Juniper more opinionated.

My main concern here (and a lot of the other outstanding PRs) is this is making Juniper more opinionated

The irony being, that explicitly not supporting auth, Juniper does, indeed, become more opinionated... By definition...


"Random" 502 errors

Checklist

Have you pulled and found the error with jc21/nginx-proxy-manager:latest docker image?

Yes

Are you sure you're not using someone else's docker image?

Yes

Have you searched for similar issues (both open and closed)?

Yes

Describe the bug
I'm using NPM with multiple images (portainer, httpd ...) and I made the NPM docker-compose join each sub-network for my other docker-compose projects.
When i'm accessing directly, let's say my httpd project with exposed port, no problem, even if i'm mashing F5 button.
When i'm doing the same through the NPM proxy, I have "random" 502 errors, I would say nearly 5-10% of the time, with the same url.
Meanwhile no problem doing the same with the direct access.
Nginx Proxy Manager Version
v.2.9.19
To Reproduce

Make a new network (including ipv6)
Make a docker-compose joining this network
Add the same network to NPM docker-compose (in addition to other networks)
Make proxy using the hostname
Mash the F5 button
Sometime (most of the time) it works, sometime it doesn't
No logs appearing on npm docker logs

Operating System
Docker on Ubuntu Server

Here is my docker-compose.yml for NPM
version: '2.4'
services:
  app:
    container_name: nginxproxymanager
    image: 'jc21/nginx-proxy-manager:latest'
    restart: unless-stopped
    environment:
      ENABLE_IPV6: true
    ports:
      - '80:80'
      - '85:81'
      - '443:443'
    volumes:
      - ./data:/data
      - ./letsencrypt:/etc/letsencrypt
    networks:
      - p1
      - p2
      - p3
networks:
  p1:
    external: true
  p2:
    external: true
  p3:
    external: true

More info :
I just looked at my data/logs/proxy-host-7_error.log and got this message :
023/02/12 21:16:09 [error] 782#782: *176817 [myhost] could not be resolved (3: Host not found)
But at the next f5... it finds it

Hello,
I also have the random problem with the 502 errors
681#681: *1248956 upstream prematurely closed connection while reading response header from upstream, client: <IP_ADDRESS>, server: symcon.xxxx.de, request: "POST /hook/ipsviewconnect/api/ HTTP/1.1", upstream: "https://192.168.x.x:3778/hook/ipsviewconnect/api/", host: "symcon.xxxx.de"
I have that since the last update on all proxies. I can just press F5 a few times or wait. That's pretty annoying :-(

Hello, I also have the random problem with the 502 errors. I have that since the last update on all proxies. I can just press F5 a few times or wait. That's pretty annoying :-(
Before the update everything was working fine!!
Errlog:
2023/02/12 21:52:37 [error] 681#681: *1252331 upstream prematurely closed connection while reading response header from upstream, client: <IP_ADDRESS>, server: symcon.domain.de, request: "POST /hook/ipsviewconnect/api/ HTTP/1.1", upstream: "https://<IP_ADDRESS>:3778/hook/ipsviewconnect/api/", host: "symcon.domain.de" 2023/02/12 21:52:37 [error] 682#682: "

I had this problem too (and mixed hostname resolution... when i was trying to access host1 it was showing host2...) but disabling and enabling again the host was a workaround for me

The cause of this problem is that the resolver in /etc/nginx/conf.d/include/resolvers.conf is hard-coded Google IPv6 DNS.
Quick fix:
create file 09_init.sh
#!/usr/bin/with-contenv bash

set -e
pip install certbot-dns-dnspod zope
sed -i 's/exec nginx$/echo '"'"'resolver <IP_ADDRESS> valid=10s;'"'"' > \/etc\/nginx\/conf.d\/include\/resolvers.conf\nexec nginx/' /etc/services.d/nginx/run

map it into docker:
volumes:
  - ./09_init.sh:/etc/cont-init.d/09_init.sh:ro

Having the same issue. NPM worked fine when I was using docker, but ever since I switched to podman for better rootless containers, I keep getting random 502s that go away after a refresh or two. Unlike the others that have this issue, I'm not getting any error logs

Hi!
I have the same problem on fresh install using this compose file:
version: '3.7'

networks:
  nginx-proxy-manager:
    external: true

services:
  npm:
    image: 'jc21/nginx-proxy-manager:latest'
    container_name: nginx-proxy-manager
    restart: unless-stopped
    ports:
      - '80:80'
      - '43013:81'
      - '443:443'
    networks:
      - nginx-proxy-manager
    depends_on:
      - npm-db
    environment:
      DB_MYSQL_HOST: npm-db
      DB_MYSQL_PORT: 3306
      DB_MYSQL_USER: npm
      DB_MYSQL_PASSWORD: npm
      DB_MYSQL_NAME: npm
      # Uncomment this if IPv6 is not enabled on your host
      #DISABLE_IPV6: 'true'
    volumes:
      - ./data:/data
      - ./letsencrypt:/etc/letsencrypt

  npm-db:
    image: 'jc21/mariadb-aria:latest'
    restart: unless-stopped
    environment:
      MYSQL_ROOT_PASSWORD: npm
      MYSQL_DATABASE: npm
      MYSQL_USER: npm
      MYSQL_PASSWORD: npm
    networks:
      - nginx-proxy-manager
    volumes:
      - ./data/mysql:/var/lib/mysql

Any ideas?
mariadb logs:
MySQL init process done. Ready for start up.

exec /usr/bin/mysqld --user=mysql --console --skip-name-resolve --skip-networking=0
2023-03-29 17:25:33 0 [Note] /usr/bin/mysqld (mysqld 10.4.15-MariaDB) starting as process 1 ...
2023-03-29 17:25:33 0 [ERROR] mysqld: File '/var/lib/mysql/aria_log_control' not found (Errcode: 13 "Permission denied")
2023-03-29 17:25:33 0 [ERROR] mysqld: Got error 'Can't open file' when trying to use aria control file '/var/lib/mysql/aria_log_control'
2023-03-29 17:25:33 0 [ERROR] Plugin 'Aria' init function returned error.
2023-03-29 17:25:33 0 [ERROR] Plugin 'Aria' registration as a STORAGE ENGINE failed.
2023-03-29 17:25:33 0 [Note] Plugin 'InnoDB' is disabled.
2023-03-29 17:25:33 0 [Note] Plugin 'FEEDBACK' is disabled.
2023-03-29 17:25:33 0 [ERROR] Could not open mysql.plugin table. Some plugins may be not loaded
2023-03-29 17:25:33 0 [ERROR] Failed to initialize plugins.
2023-03-29 17:25:33 0 [ERROR] Aborting
[i] pre-init.d - processing /scripts/pre-init.d/01_secret-init.sh
[i] mysqld already present, skipping creation
[i] MySQL directory already present, skipping creation
2023-03-29 17:25:34 0 [Note] /usr/bin/mysqld (mysqld 10.4.15-MariaDB) starting as process 1 ...
2023-03-29 17:25:34 0 [Note] Plugin 'InnoDB' is disabled.
2023-03-29 17:25:34 0 [Note] Plugin 'FEEDBACK' is disabled.
2023-03-29 17:25:34 0 [Note] Server socket created on IP: '::'.
2023-03-29 17:25:34 0 [Warning] 'user' entry '@3726bb8bb89f' ignored in --skip-name-resolve mode.
2023-03-29 17:25:34 0 [Warning] 'proxies_priv' entry '@% root@3726bb8bb89f' ignored in --skip-name-resolve mode.
2023-03-29 17:25:34 0 [Note] Reading of all Master_info entries succeeded
2023-03-29 17:25:34 0 [Note] Added new Master_info '' to hash table
2023-03-29 17:25:34 0 [Note] /usr/bin/mysqld: ready for connections.
Version: '10.4.15-MariaDB'  socket: '/run/mysqld/mysqld.sock'  port: 3306  MariaDB Server
2023-03-29 17:25:39 3 [Warning] Aborted connection 3 to db: 'unconnected' user: 'unauthenticated' host: '<IP_ADDRESS>' (This connection closed normally without authentication)
2023-03-29 17:25:40 4 [Warning] Aborted connection 4 to db: 'unconnected' user: 'unauthenticated' host: '<IP_ADDRESS>' (This connection closed normally without authentication)
2023-03-29 17:25:41 5 [Warning] Aborted connection 5 to db: 'unconnected' user: 'unauthenticated' host: '<IP_ADDRESS>' (This connection closed normally without authentication)
2023-03-29 17:25:42 6 [Warning] Aborted connection 6 to db: 'unconnected' user: 'unauthenticated' host: '<IP_ADDRESS>' (This connection closed normally without authentication)
2023-03-29 17:25:43 7 [Warning] Aborted connection 7 to db: 'unconnected' user: 'unauthenticated' host: '<IP_ADDRESS>' (This connection closed normally without authentication)

NPM logs:
❯ Starting nginx ...
❯ Starting backend ...
s6-rc: info: service frontend successfully started
s6-rc: info: service nginx successfully started
s6-rc: info: service backend successfully started
s6-rc: info: service legacy-services: starting
s6-rc: info: service legacy-services successfully started
[3/29/2023] [5:25:33 PM] [Global   ] › ℹ  info      Using MySQL configuration
[3/29/2023] [5:25:33 PM] [Global   ] › ℹ  info      Creating a new JWT key pair...
[3/29/2023] [5:25:38 PM] [Global   ] › ℹ  info      Wrote JWT key pair to config file: /data/keys.json
[3/29/2023] [5:25:39 PM] [Global   ] › ✖  error     Packets out of order. Got: 1 Expected: 0
[3/29/2023] [5:25:40 PM] [Global   ] › ✖  error     Packets out of order. Got: 1 Expected: 0
[3/29/2023] [5:25:41 PM] [Global   ] › ✖  error     Packets out of order. Got: 1 Expected: 0
[3/29/2023] [5:25:42 PM] [Global   ] › ✖  error     Packets out of order. Got: 1 Expected: 0
[3/29/2023] [5:25:43 PM] [Global   ] › ✖  error     Packets out of order. Got: 1 Expected: 0
[3/29/2023] [5:25:44 PM] [Global   ] › ✖  error     Packets out of order. Got: 1 Expected: 0
[3/29/2023] [5:25:45 PM] [Global   ] › ✖  error     Packets out of order. Got: 1 Expected: 0
[3/29/2023] [5:25:46 PM] [Global   ] › ✖  error     Packets out of order. Got: 1 Expected: 0

Same problem, using version 2.9.22.
Disabling and re-enabling did not work.

Just to add to the discussion, I also experienced this on the latest version but managed to work around it by creating a shared bridge network on podman(so I can set ip ranges and stuff), attaching the containers to it and then setting static IPs on the containers. With that I can point nginx-proxy-manager to the static ip of the container instead of the hostname and it seems to work reliably.

Just to add to the discussion, I also experienced this on the latest version but managed to work around it by creating a shared bridge network on podman(so I can set ip ranges and stuff), attaching the containers to it and then setting static IPs on the containers. With that I can point nginx-proxy-manager to the static ip of the container instead of the hostname and it seems to work reliably.
edit: FWIW I'm using podman 4.2.0 on Rocky Linux 9.1 and configuring everything with ansible so I'm not sure how applicable this is to everyone else.

Interesting, I'm also using podman. Are you running rootless? I'm wondering if it's some weirdness related to rootless networking

Just to add to the discussion, I also experienced this on the latest version but managed to work around it by creating a shared bridge network on podman(so I can set ip ranges and stuff), attaching the containers to it and then setting static IPs on the containers. With that I can point nginx-proxy-manager to the static ip of the container instead of the hostname and it seems to work reliably.
edit: FWIW I'm using podman 4.2.0 on Rocky Linux 9.1 and configuring everything with ansible so I'm not sure how applicable this is to everyone else.

Interesting, I'm also using podman. Are you running rootless? I'm wondering if it's some weirdness related to rootless networking

This doesn't seem to be a issue of rootless network. I'm also using Podman but in root permission. NPM works perfectly when using internal IP address instead of hostnames. The problem of occasional 502 errors occur only for containers using hostnames.

I'm also experiencing this issue.
docker.io/jc21/nginx-proxy-manager:2.9.22
podman version 4.4.4
OpenSUSE Leap 15.4
kernel 5.14.21-150400.24.60-default
cni-plugin-dnsname-1.3.1 RPM installed to enable podman DNS functionality
Created a bridge network with default settings and attached containers for nginx-proxy-manager, grafana and prometheus.
I'd say approx 10-20% of requests fail with a 502, and inspecting the nginx-proxy-manager proxy host error logs shows:
2023/04/24 14:10:46 [error] 713#713: *324 grafana.dns.podman could not be resolved (3: Host not found), client: <IP_ADDRESS>, server: monitoring.redacted.com, request: "GET /api/live/ws HTTP/1.1", host: "monitoring.redacted.com"

However from within the nginx-proxy-manager container itself, nslookup can resolve it
$ nslookup grafana.dns.podman
Server:		<IP_ADDRESS>
Address:	<IP_ADDRESS>:53

Name:	grafana.dns.podman
Address: <IP_ADDRESS>

and this call to grafana's health endpoint succeeds 100% of the time:
$ wget -O - grafana.dns.podman:3000/api/health
Connecting to grafana.dns.podman:3000 (<IP_ADDRESS>:3000)
writing to stdout
{
  "commit": "4add91f03d",
  "database": "ok",
  "version": "9.4.7"
-                    100% |***********************************************************************************************************************************************************************************************|    70  0:00:00 ETA
written to stdout

I have a second proxy host configured to a prometheus container, and this also suffers the same problem. I've also tried running all containers as privileged but the same issue occurs. An obvious workaround is to use static container IPs and set these as the forward ip instead of the hostname but it's not ideal.

Same problem here with fresh 2.10.2 docker install.
The problem is solved as soon as I add root domain to one of proxy hosts - as soon as I remove root domain and leave subdomains only I get 502 error

I'm also experiencing the issues described when using Podman (on plain Docker it worked fine).
Changing the reverse proxy to Caddy instead of Nginx Proxy Manager completely solved the issues, so my guess is that it is due to the DNS resolver NPM is using.

Just to add to the discussion, I also experienced this on the latest version but managed to work around it by creating a shared bridge network on podman(so I can set ip ranges and stuff), attaching the containers to it and then setting static IPs on the containers. With that I can point nginx-proxy-manager to the static ip of the container instead of the hostname and it seems to work reliably.
edit: FWIW I'm using podman 4.2.0 on Rocky Linux 9.1 and configuring everything with ansible so I'm not sure how applicable this is to everyone else.

Interesting, I'm also using podman. Are you running rootless? I'm wondering if it's some weirdness related to rootless networking

This doesn't seem to be a issue of rootless network. I'm also using Podman but in root permission. NPM works perfectly when using internal IP address instead of hostnames. The problem of occasional 502 errors occur only for containers using hostnames.

I am also experiencing issues when using hostnames. I just switched over to Podman, but specifying subuid and subgid and running under root. When switching to using IPs, the problem seems to have gone away.

Since I've pulled the last version I begun to get the random 502. I don;t known exactly why, but the issue is with the domain name resolution.

#2197 Pretty sure this issue and the hosts issue are related, I've added an interim solution to the other ticket (podman specific) I've not experienced this under docker myself.

Have Portainer Business Edition 2.19.4 and jc21/nginx-proxy-manager:2.10.4. Same issue

Pretty sure this issue and the hosts issue (#2197 ) are related, I've added an interim solution to the other ticket (podman specific) I've not experienced this under docker myself.

I just tried a version of this solution with Docker: starting with a default Docker configuration (i.e. no /etc/docker/daemon.json file) at some version upgrade in the past few months I started getting a lot of 502 caused by host not found errors.
Thinking that Docker and resolved hosed something I created the daemon.json file with 2 DNS entries... but that still failed to resolve hostnames very often (half the times?).
Taking a hint from #2197 I changed the file to contain only my local router's DNS... and that fixed the problem.

I encounter the random 502 errors also.
No Podman, just plain docker.
However it seems they only show up when setting: network_mode: host in my docker-compose.yml
Using the 'latest' image

Same issue here. Until further news, I will switch to pointing to IPs directly and avoid going through my DNS.
(BTW: Its adguard, not sure if anyone is experiencing the same issues with pihole? I doubt its related to the DNS, seems to be more of NPM's, but just in case)

Long time ago. Update fixed all my problems

Long time ago. Update fixed all my problems

Update to NPM? I'm running latest version (2.12.1) and experiencing this issues when using hostnames instead of IPs

@CarlesLlobet did you try defining a single DNS in your /etc/docker/ daemon.json file as I did above?

@CarlesLlobet did you try defining a single DNS in your /etc/docker/ daemon.json file as I did above?

I don't have docker, but NPM directly over an LxC. More details here.
However I don't think your approach is ideal, since I it relies on a unique DNS as single point of failure, and manually hardcoded. If that DNS fails or falls, your whole NPM doesn't resolve anything.
If I use DNS, I want to be able to use the DNS shared by DHCP, and in case my DNS falls for some reason, have a second fallback DNS in place.
Otherwise I prefer to just manually input the IPs (although its far from ideal since I have to keep it updated with any changes, so I have to update 2 places (DNs + NPM)). At least this way if my DNS falls, NPM and all my services behind it still work.

@CarlesLlobet the main point here is that the problem isn't in NPM but in the system that manages the DNS for the containers, for at least PodMan and Docker and they both use containerd that in turn uses lxc: likely there's a problem there.
Your options are to set up multiple  DNS servers on a shared ip, use a VM, etc... in general: find a way to run it that doesn't involve a broken DNS for NPM.

the problem isn't in NPM but in the system that manages the DNS for the containers
@RobertoMaurizzi I agree the issue might rely on Docker side rather than NPM.

However at the same time, the only official install option that NPM supports/suggests is docker.
So I do think that it is fair that people might want to set up their Hosts with hostnames instead of IPs, without having to apply patches to the docker DNS config.
Furthermore this solution you suggest would affect ALL your docker containers, not only NPM.
I am not sure at what the best solution / course of action would be from NPM's side, either offering an alternate installation method that doesn't have this issue/bug with DNS, or internally doing the request twice if the first DNS resolution fails, but I do think it could be improved.
As per what I've read from others and my own use case, when NPM replied with a 502, refreshing the page would always point correctly to the page. So maybe just "trying twice" in case the first DNS resolution fails, solves the issue.. And shouldn't add too much overhead / lag to the response.
But Im not an expert on NPM implementation. Do you think that'd be feasible? 🤔

@CarlesLlobet the problem is that if you have 3 DNS entries, it becomes 1 good every three (that was my initial problem, with docker picking up my system's DNS entries in /etc/resolv.conf
I'm also not heavily using containers that need to resolve DNS entries so I'm not sure if this problem affects other projects... I didn't see it anywhere else but I can't say I have enough testing to say that.
It would be interesting to take a look at how NPM approaches DNS resolution and to get a better look at any returned error, but I'm not a Node/JS expert 😅

I had exactly the same issue - some of my docker apps got a bad gateway error behind NPM every 3rd or 4th request. I figured out that the affected docker containers were assigned to the default docker bridge network (system).
After creating a separate docker bridge network for those containers, the bad gateway issues were completely gone. So no issue on NPM side in my case


Mesa/Zink crash with supertuxkart

Description
Running into a crash while trying to capture frames off the GL over Vulkan zink driver running supertuxkart.
Steps to reproduce
With a master build of Mesa and the zink driver compiled, run :
MESA_LOADER_DRIVER_OVERRIDE=zink renderdoccmd capture supertuxkart  --track="ravenbridge_mansion" -R
Here is the capture of the crash :
Core was generated by `supertuxkart --track=ravenbridge_mansion -R'.
Program terminated with signal SIGSEGV, Segmentation fault.
#0  0x00007fe3ab65b150 in ResourceRecord::GetResourceID (this=0x0) at ../renderdoc/core/resource_manager.h:399
399	  ResourceId GetResourceID() const { return ResID; }
[Current thread is 1 (Thread 0x7fe3a913fec0 (LWP 617656))]
(gdb) bt
#0  0x00007fe3ab65b150 in ResourceRecord::GetResourceID (this=0x0) at ../renderdoc/core/resource_manager.h:399
#1  0x00007fe3abc6c49e in VkResourceRecord::MarkBufferFrameReferenced (this=0x5608802f9bc0, buf=0x0, offset=0, size=18446744073709551615, refType=eFrameRef_Read) at ../renderdoc/driver/vulkan/vk_resources.cpp:3905
#2  0x00007fe3ac00050e in WrappedVulkan::vkCmdPushDescriptorSetWithTemplateKHR (this=0x56087fcc94a0, commandBuffer=0x56087f3e5150, descriptorUpdateTemplate=0x56087f3ec390, layout=0x56087f3e8fe8, set=1, pData=0x56088021dea0)
    at ../renderdoc/driver/vulkan/wrappers/vk_cmd_funcs.cpp:5337
#3  0x00007fe3abfd4d03 in hooked_vkCmdPushDescriptorSetWithTemplateKHR (commandBuffer=0x56087f3e5150, descriptorUpdateTemplate=0x56087f3ec390, layout=0x56087f3e8fe8, set=1, pData=0x56088021dea0) at ../renderdoc/driver/vulkan/vk_layer.cpp:235
#4  0x00007fe3a2c07b7d in zink_descriptors_update_lazy (ctx=0x56088021dea0, is_compute=false) at ../src/gallium/drivers/zink/zink_descriptors_lazy.c:375
#5  0x00007fe3a2c0af28 in zink_draw_vbo (pctx=0x56088021dea0, dinfo=0x560880304bc8, dindirect=0x0, draws=0x560880304be8, num_draws=1) at ../src/gallium/drivers/zink/zink_draw.c:554
#6  0x00007fe3a2b7ef51 in tc_call_draw_single (pipe=0x56088021dea0, payload=0x560880304bc8) at ../src/gallium/auxiliary/util/u_threaded_context.c:2375
#7  0x00007fe3a2b79700 in tc_batch_execute (job=0x560880304990, thread_index=0) at ../src/gallium/auxiliary/util/u_threaded_context.c:227
#8  0x00007fe3a2b79b67 in _tc_sync (tc=0x5608803043d0, info=0x7fe3a379e4cf "end of frame", func=0x7fe3a379e978 <__func__.10> "tc_flush") at ../src/gallium/auxiliary/util/u_threaded_context.c:344
#9  0x00007fe3a2b7ee81 in tc_flush (_pipe=0x5608803043d0, fence=0x7ffdd9d7f1e0, flags=1) at ../src/gallium/auxiliary/util/u_threaded_context.c:2349
#10 0x00007fe3a2300b7f in st_flush (st=0x56088037e900, fence=0x7ffdd9d7f1e0, flags=1) at ../src/mesa/state_tracker/st_cb_flush.c:60
#11 0x00007fe3a22e5b7c in st_context_flush (stctxi=0x56088037e900, flags=2, fence=0x7ffdd9d7f1e0, before_flush_cb=0x7fe3a2268a35 <notify_before_flush_cb>, args=0x7ffdd9d7f210) at ../src/mesa/state_tracker/st_manager.c:674
#12 0x00007fe3a2268dff in dri_flush (cPriv=0x56088021dd00, dPriv=0x5608800dcee0, flags=5, reason=__DRI2_THROTTLE_SWAPBUFFER) at ../src/gallium/frontends/dri/dri_drawable.c:526
#13 0x00007fe3a80d3b78 in dri2_flush_drawable_for_swapbuffers (disp=0x56087fab6ab0, draw=0x56088021d630) at ../src/egl/drivers/dri2/egl_dri2.c:1980
#14 0x00007fe3a80e20dc in dri2_wl_swap_buffers_with_damage (disp=0x56087fab6ab0, draw=0x56088021d630, rects=0x0, n_rects=0) at ../src/egl/drivers/dri2/platform_wayland.c:1131
#15 0x00007fe3a80e21ff in dri2_wl_swap_buffers (disp=0x56087fab6ab0, draw=0x56088021d630) at ../src/egl/drivers/dri2/platform_wayland.c:1167
#16 0x00007fe3a80d3c1a in dri2_swap_buffers (disp=0x56087fab6ab0, surf=0x56088021d630) at ../src/egl/drivers/dri2/egl_dri2.c:2001
#17 0x00007fe3a80c40ad in eglSwapBuffers (dpy=0x56087fab6ab0, surface=0x56088021d630) at ../src/egl/main/eglapi.c:1346
#18 0x00007fe3aac10d3d in eglSwapBuffers (dpy=0x56087fab6ab0, surface=0x56088021d630) at g_egldispatchstubs.c:281
#19 0x00007fe3aba31934 in eglSwapBuffers_renderdoc_hooked (dpy=0x56087fab6ab0, surface=0x56088021d630) at ../renderdoc/driver/gl/egl_hooks.cpp:531
#20 0x00007fe3aba32323 in eglSwapBuffers (dpy=0x56087fab6ab0, surface=0x56088021d630) at ../renderdoc/driver/gl/egl_hooks.cpp:735
#21 0x000056087da880b5 in ContextManagerEGL::swapBuffers() ()
#22 0x000056087d9f89e3 in irr::video::COpenGLDriver::endScene() ()
#23 0x000056087d4e4e90 in IrrDriver::initDevice() ()
#24 0x000056087d6b0ae5 in initRest() ()
#25 0x000056087d410870 in main ()

Environment

RenderDoc version: v1.x branch (57b6190c856148233f4b6bf2f96fadb1b5696eb2)

Operating System: Linux Ubuntu 20.10

Graphics API: GL over Vulkan (LOL)

Vulkan driver : Mesa/Intel (Anv)

This is zink-wip btw, not master.

Also zink-wip has hardcoded renderdoc capturing for vk mode atm: in zink_batch.c, you can just change the 400 value in submit_queue() and it'll capture that cmdbuf index automatically. There's no other method of capturing a vk trace.

I wasn't correctly handling the interaction of push descriptors and nullDescriptor feature from EXT_robustness2.

Thanks a bunch!


fix: Misc issues

Motivation
Consistency and PEP-8 compliance.
Modification
Found some issues with IDEA.
Checklist
None of these are applicable.

[ ] Tests updated
[ ] Docs updated
[ ] Issue linked in Title

:lgtm: did you want to change the title to something other than "misc fixes" how about something like
"refactor: pep-8 compliance" ?


Enable Multiprocessing

This PR speeds up the tokenizer loop with multiprocessing.

After parallelizing the loop myself, I realized @blingenf had already implemented a nearly identical solution with an identical branch name. I've merged the two solutions together in this PR, but please let me know if you'd like to merge them differently.


'QuotaExceededError'

Happens everytime i want to delete a filter or add one. I've had about 100 or so filters for a while now but only today is it bringing me this error when i wanted to add 3 more.
Error occurred while saving, you may have to remove some filters and try again
Error: QuotaExceededError: storage.sync API call exceeded its quota limitations
Thanks.

Can anyone help...?
I tried removing the add-on hoping the customisations would be removed but they're saved somewhere. no idea where though.

This should generally be resolved with the extension rewrite in 2022.


Auto install npm dependancies when they are added to code with npm-install-webpack-plugin

Have you seen: https://github.com/ericclemmons/npm-install-webpack-plugin ?
It automatically with add deps to package.json and npm i them for you.
Just an idea. Might be out of scope or something the custom webpack config would do.

Cool, it would be nice to see if it "just works" by adding it to the webpack configuration. I don't have time myself at the moment tho.
Ideally having started the serverless webpack watch or serve with that plugin might just do the trick. Leaving this open if someone wants to report in

I tested this out today and it does in fact "just work". Here is my webpack config:
https://gist.github.com/mikestaub/cfcce4bcff0ac14ae3609d2f91305c4e
One caveat is that I needed to add this line to the entry file, otherwise babel-polyfill will throw an error:
if (!global._babelPolyfill) {
  require('babel-polyfill');
}

Thanks @mikestaub ! This issue should provide enough support for now. We might add some doc in the readme if ppl hit +1 here


Minor text updates

Backup using Seed Words modal:

E should be capital in "English"
Remove fullstop after privately

Verified this issue on dev app v2.0.75(478)


Adding IPv6 support instead of IPv4

This diff replaces support for IPv4 addresses with IPv6 addresses. The implementation of the Network class and the SockAddr class has changed in this diff. Instead of using language supported 128 bit integers (https://gcc.gnu.org/onlinedocs/gcc/_005f_005fint128.html), I am using Kudu's implementation. The parsing of CIDR subnets need a little more formal treatment but I will followup.

@anirbanr-fb - Possible. Yes :) It would be some extra work to overload the socket and sockaddr class + add an extra set of net_util functions. I was thinking about unblocking ourselves first. I am trying to take ownership of https://issues.apache.org/jira/browse/KUDU-1457. I have sent out an email and will send out a patch, if they are responsive. If I am able to land a patch upstream quickly, I will rebase our code on top of the patch. I will leave the merging of this specific pull request on your discretion.

You might chat with Arun Sharma (also from fb) about this. He had a similar patch a few years ago that made ipv6 optional


Incremental sigma vector not working correctly for multistate TPSCI calculations

when computing
|sig_i> = H |psi_i>
            = H (|psi_i> - |psi_i-1>) + |sig_i-1>

The vectors need their phases made identical. For one vector that's fine, just flip the sign if the overlap <psi_i|psi_i-1> is negative, but for multiple roots the states can flip, and so the states need to be aligned before determining sign.

fixed in af595f2


Introduce Node Pattern tutorial

I'm really excited about work with node pattern and I bring this extra tutorial about how to interpret and create node patterns and learn a bit about this small compiler.
Suggestions are welcome!

Before submitting the PR make sure the following are checked:

[x] Wrote good commit messages.
(n/a) Commit message starts with [Fix #issue-number] (if the related issue exists).
[x] Used the same coding conventions as the rest of the project.
[x] Feature branch is up-to-date with master (if not - rebase it).
[x] Squashed related commits together.
(n/a) Added tests.
(n/a) Added an entry to the Changelog if the new code introduces user-observable changes. See changelog entry format.
[x] All tests(rake spec) are passing.
(n/a) The new code doesn't generate RuboCop offenses that are checked by rake internal_investigation.
[x] The PR relates to only one subject with a clear title
and description in grammatically correct, complete sentences.
(n/a) Updated cop documentation with rake generate_cops_documentation (required only when you've added a new cop or changed the configuration/documentation of an existing cop).

I'm not sure how to visualize it in my computer. I just followed the markdown but I'm very curious about run and preview the manual in my local machine.

All you need is http://www.mkdocs.org/ locally.

https://rubocop.readthedocs.io/en/latest/contributing/#working-on-the-manual

Thanks for working on this. I don't know how to use this stuff. 😄

Thanks for the detailed review @pirj. I addressed all the comments (I think).

I'm still thinking about migrating the examples to use rake repl and use Ruby to demonstrate all examples. As I did in the Development tutorial. Not sure how valuable it can be. The idea of just open the terminal, start copying and pasting from the examples are generally comfortable and engage more the reader. At least me as a reader.
Do you agree about code examples?

I'm surprised and honored that someone liked my code enough to write this much about it. Thanks for the tutorial, @jonatas!
I don't think it would hurt to add a note (at the end) that the source code is easy to read and hack on, if that is true. Anyways, it's your tutorial, so please don't feel you need to take my suggestions.

Thanks, @alexdowad! I really enjoyed the Node Pattern approach. I started my own toy independent of RuboCop and it's an interesting learning experience for me. Your code was my major reference there 👍
Added the message to encourage more people to hack it ✅

There's certainly more room for improvement, but I'll merge this at this point as I plan to cut a new RuboCop release later today.
Thanks for your contribution, @jonatas!

Great @bbatsov! Glad to contribute :)


bootstrap error

I try to install TPM2.0-TSS on Redhat 7.1 with Linux kernel 3.10.0-<IP_ADDRESS>.x86_64.
First I install the dependencies

autoconf (GNU Autoconf) 2.69
automake (GNU automake) 1.13.4
m4 (GNU M4) 1.4.16
libtool (GNU libtool) 2.4.2
cmocka 1.0.1
glibc-2.17-111.e1.x86_64
glibc-devel-2.17-111.e1.x86_64
gcc (GCC) 4.8.3 20140911
gcc-c++-4.8.3-10.x86_64
pkgconfig-0.27.1-4.x86_64

Second I run bootstrap, but I got this error. And I follow the solution of issue#185, but it didn't work for me.
[root@localhost TPM2.0-TSS-master]# ./bootstrap
Generating file lists: src_vars.mk
Running libtoolize ...
libtoolize: putting auxiliary files in `.'.
libtoolize: linking file `./config.guess'
libtoolize: linking file `./config.sub'
libtoolize: linking file `./install-sh'
libtoolize: linking file `./ltmain.sh'
libtoolize: putting macros in AC_CONFIG_MACRO_DIR, `m4'.
libtoolize: linking file `m4/libtool.m4'
libtoolize: linking file `m4/ltoptions.m4'
libtoolize: linking file `m4/ltsugar.m4'
libtoolize: linking file `m4/ltversion.m4'
libtoolize: linking file `m4/lt~obsolete.m4'
Running aclocal ...
Running autoconf ...
configure.ac:10: error: possibly undefined macro: AC_MSG_ERROR
      If this token and others are legitimate, please use m4_pattern_allow.
      See the Autoconf documentation.

[root@localhost TPM2.0-TSS-master]# ./configure
checking for gcc... gcc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ISO C89... none needed
checking for g++... g++
checking whether we are using the GNU C++ compiler... yes
checking whether g++ accepts -g... yes
checking build system type... x86_64-unknown-linux-gnu
checking host system type... x86_64-unknown-linux-gnu
checking how to print strings... printf
checking for a sed that does not truncate output... /usr/bin/sed
checking for grep that handles long lines and -e... /usr/bin/grep
checking for egrep... /usr/bin/grep -E
checking for fgrep... /usr/bin/grep -F
checking for ld used by gcc... /usr/bin/ld
checking if the linker (/usr/bin/ld) is GNU ld... yes
checking for BSD- or MS-compatible name lister (nm)... /usr/bin/nm -B
checking the name lister (/usr/bin/nm -B) interface... BSD nm
checking whether ln -s works... yes
checking the maximum length of command line arguments... 1572864
checking whether the shell understands some XSI constructs... yes
checking whether the shell understands "+="... yes
checking how to convert x86_64-unknown-linux-gnu file names to x86_64-unknown-linux-gnu format... func_convert_file_noop
checking how to convert x86_64-unknown-linux-gnu file names to toolchain format... func_convert_file_noop
checking for /usr/bin/ld option to reload object files... -r
checking for objdump... objdump
checking how to recognize dependent libraries... pass_all
checking for dlltool... no
checking how to associate runtime and link libraries... printf %s\n
checking for ar... ar
checking for archiver @FILE support... @
checking for strip... strip
checking for ranlib... ranlib
checking for gawk... gawk
checking command to parse /usr/bin/nm -B output from gcc object... ok
checking for sysroot... no
checking for mt... no
checking if : is a manifest tool... no
checking how to run the C preprocessor... gcc -E
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking for dlfcn.h... yes
checking for objdir... .libs
checking if gcc supports -fno-rtti -fno-exceptions... no
checking for gcc option to produce PIC... -fPIC -DPIC
checking if gcc PIC flag -fPIC -DPIC works... yes
checking if gcc static flag -static works... yes
checking if gcc supports -c -o file.o... yes
checking if gcc supports -c -o file.o... (cached) yes
checking whether the gcc linker (/usr/bin/ld -m elf_x86_64) supports shared libraries... yes
checking whether -lc should be explicitly linked in... no
checking dynamic linker characteristics... GNU/Linux ld.so
checking how to hardcode library paths into programs... immediate
checking whether stripping libraries is possible... yes
checking if libtool supports shared libraries... yes
checking whether to build shared libraries... yes
checking whether to build static libraries... yes
checking how to run the C++ preprocessor... g++ -E
checking for ld used by g++... /usr/bin/ld -m elf_x86_64
checking if the linker (/usr/bin/ld -m elf_x86_64) is GNU ld... yes
checking whether the g++ linker (/usr/bin/ld -m elf_x86_64) supports shared libraries... yes
checking for g++ option to produce PIC... -fPIC -DPIC
checking if g++ PIC flag -fPIC -DPIC works... yes
checking if g++ static flag -static works... no
checking if g++ supports -c -o file.o... yes
checking if g++ supports -c -o file.o... (cached) yes
checking whether the g++ linker (/usr/bin/ld -m elf_x86_64) supports shared libraries... yes
checking dynamic linker characteristics... (cached) GNU/Linux ld.so
checking how to hardcode library paths into programs... immediate
./configure: line 14170: syntax error near unexpected token `,'
./configure: line 14170: `AX_PTHREAD(, AC_MSG_ERROR([requires pthread]))'

What can i do to solve this?

#185 was resolved by installing the autoconf-archive package. The list of dependencies you've installed doesn't include this package. Do you have it installed?

Yeah, I have already installed this package from autoconf-archive-2013.06.09.tar.gz with ./configure; make; make install command. Could it be the pthread or the not matched version who trigger this error?
Is there any way to check details of bootstrap step by step? More specifically, how can I locate this error and debug it?

Finally, I found that autoconf-archive package is to blame. Here is what I have done.
cp /usr/local/share/aclocal/* /usr/share/aclocal/

And bootstrp worked. By the way, thank you @flihp .

Glad you got that sorted @edonyM. I didn't realize that RedHat had removed their autoconf-archive package recently and that you were installing from a source release. Someone put together a few spec / cfg files for building an RPM which may help in the future: https://github.com/wendall911/autoconf-archive


Specify byteorder arg and remove simul index creation

Resolves TypeError: from_bytes() missing required argument 'byteorder' (pos 2)
Removes the index creation in favor of the one at bin/mongodb/indexes.js

I prefer to keep the index creation unless it causes problems


Add switcher between release and main

BEGINRELEASENOTES

I've added a button to switch between release and main deployments easily inside the info modal. This would solve #52.

ENDRELEASENOTES

Can we have the button on the "main" window and not in the modal? It is a bit hard to find there.

But I suppose that is fixed by deploying it because currently the page(s) we redirect to are the deployed ones, right?

Yes, because those don't have the changes from this pr.

Just for my understanding. How does the button look like on the release page once it's merged? Will there be one with "Main" (or maybe call it "Develop"?) similar to what is there for "Release" at the moment?

Just for my understanding. How does the button look like on the release page once it's merged? Will there be one with "Main" (or maybe call it "Develop"?) similar to what is there for "Release" at the moment?

Yes, the same button will change depending on the deployment. When going to /release or /main, the whole page is reloaded, so the script runs again and shows either option depending on the route.


Consider being able to initialise an entity with multiple types

Unsure how our method signatures will look after this.

Hi, I'm part of a small group that wants to work on this issue.
Looking through the code, it looks like it is already possible to create an entity with multiple types by marking that entity multiple times.
Is this a question of creating convenience functions or is there something more fundamental that needs to be changed that we're missing?

Hello! So everything you have said is correct - you can mark an entity multiple times to achieve this. I think it may be worth just adding this as a convenience function to Entities as we have a lot of method definitions for newEntity as it is.
Anything I've marked with the Question tag is entirely up for debate. Do we need it should we have it?
Happy to have you working on JALSE :)

Hey Elizord, I am on the same group as Kevin working on this issue. I have added another implementation of the newEntity method that takes in a Collection of types as an input. I was wondering how you would want us to test this. Thanks.

Hello! I've added a comment to your pull request. You can move the unit test to EntitiesTest (not sure if it exists yet off the top of my head). Thanks!


Sort list of equivalence class elements

The order of elements provided by Hash_set.to_list is unspecified, so the order could change via a different implementation, or even in different executions.
Normalize the order by sorting it.

!ci-build-me

!approved-for-mainnet

!ci-build-me

!ci-build-me

!ci-build-me

!ci-build-me

!approved-for-mainnet

!ci-build-me

!ci-build-me

!approved-for-mainnet


feature: livereload support

[x] write livereload server
[x] livereload client use offical javascript version

resources:

ruby: https://github.com/guard/guard-livereload
go: https://github.com/spf13/hugo/blob/master/livereload/livereload.go

done with c80367429d073daae0028b3e9d5025e1494cf261


[Spike] Research structlog and integration with VDK

Overview
Research how structlog can be integrated into VDK. https://github.com/hynek/structlog
We're mainly interested in the following points

how will log = logging.get_logger() work from now on
how would user logging work
how would metadata fields be configured and added

Acceptance Criteria

Research how to integrate structlog into VDK
Create a proposal for integrating structlog into VDK
Sync proposal with rest of the team
A PoC is done and decide if we would like to use it

Output:
https://github.com/vmware/versatile-data-kit/wiki/VDK-Structlog-Integration
https://github.com/vmware/versatile-data-kit/issues/2722
https://github.com/vmware/versatile-data-kit/issues/2723
https://github.com/vmware/versatile-data-kit/issues/2724
https://github.com/vmware/versatile-data-kit/issues/2725
Other relevant tickets also in milestone


[BOT PR] to update dependencies of istio

This PR will be merged automatically once checks are successful.
none

[APPROVALNOTIFIER] This PR is NOT APPROVED
This pull-request has been approved by:
To fully approve this pull request, please assign additional approvers.
We suggest the following additional approver: wattli
Assign the PR to them by writing /assign @wattli in a comment when ready.
The full list of commands accepted by this bot can be found here.
The pull request process is described here

Needs approval from an approver in each of these files:

OWNERS

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@istio-testing: The following test failed, say /retest to rerun them all:

Test name
Commit
Details
Rerun command

prow/istio-pilot-e2e-envoyv2-v1alpha3.sh
f6af3d39989b2ab4d854f8a4e00d07673ff371ac
link
/test istio-pilot-e2e-envoyv2-v1alpha3

Instructions for interacting with me using PR comments are available here.  If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here.

@istio-testing: The following tests failed, say /retest to rerun them all:

Test name
Commit
Details
Rerun command

prow/istio-pilot-e2e-envoyv2-v1alpha3.sh
f6af3d39989b2ab4d854f8a4e00d07673ff371ac
link
/test istio-pilot-e2e-envoyv2-v1alpha3

prow/istio-pilot-e2e.sh
f6af3d39989b2ab4d854f8a4e00d07673ff371ac
link
/test istio-pilot-e2e

Instructions for interacting with me using PR comments are available here.  If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here.

@istio-testing: The following tests failed, say /retest to rerun them all:

Test name
Commit
Details
Rerun command

prow/istio-pilot-e2e-envoyv2-v1alpha3.sh
f6af3d39989b2ab4d854f8a4e00d07673ff371ac
link
/test istio-pilot-e2e-envoyv2-v1alpha3

prow/istio-pilot-e2e.sh
f6af3d39989b2ab4d854f8a4e00d07673ff371ac
link
/test istio-pilot-e2e

prow/e2e-bookInfoTests-v1alpha3.sh
f6af3d39989b2ab4d854f8a4e00d07673ff371ac
link
/test e2e-bookInfo-envoyv2-v1alpha3

Instructions for interacting with me using PR comments are available here.  If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here.

@istio-testing: The following tests failed, say /retest to rerun them all:

Test name
Commit
Details
Rerun command

prow/istio-pilot-e2e-envoyv2-v1alpha3.sh
f6af3d39989b2ab4d854f8a4e00d07673ff371ac
link
/test istio-pilot-e2e-envoyv2-v1alpha3

prow/istio-pilot-e2e.sh
f6af3d39989b2ab4d854f8a4e00d07673ff371ac
link
/test istio-pilot-e2e

prow/e2e-bookInfoTests-v1alpha3.sh
f6af3d39989b2ab4d854f8a4e00d07673ff371ac
link
/test e2e-bookInfo-envoyv2-v1alpha3

prow/e2e-bookInfoTests.sh
f6af3d39989b2ab4d854f8a4e00d07673ff371ac
link
/test e2e-bookInfo

Instructions for interacting with me using PR comments are available here.  If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here.


Create POST end point for devices/deviceView

Description

this commit add new POST end point and unit test for that as well.
FIXES: # https://issues.redhat.com/browse/THEEDGE-3514
Type of change
What is it?

[ ] Bug fix (non-breaking change which fixes an issue)
[x] New feature (non-breaking change which adds functionality)
[ ] Documentation update
[ ] Tests update
[ ] Refactor

Codecov Report
Patch coverage: 37.93% and project coverage change: -0.04% :warning:

Comparison is base (91426cd) 61.29% compared to head (0bf0118) 61.26%.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #2205      +/-   ##
==========================================
- Coverage   61.29%   61.26%   -0.04%
==========================================
  Files          80       80
  Lines       11866    11895      +29
==========================================
+ Hits         7273     7287      +14
- Misses       3964     3975      +11
- Partials      629      633       +4

Files Changed
Coverage Δ

pkg/routes/devices.go
50.73% <37.93%> (-2.11%)
:arrow_down:

... and 1 file with indirect coverage changes

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.


Change "<" on extra version marker to actual icon

Probably want to use the Font Awesome arrow icon instead.

Fixed with last commit,


indexing support

Gonna need a whole bunch of tests for this too. This is a complex feature!

Gonna need a whole bunch of tests for this too. This is a complex feature!

Yes, just added support for multidimensional too
Will push with tests

@geohot please refactor if possible
pr support

gpu single indexing i.e tensor[0]
slicing indexing i.e tensor[2:10] NOTE: not supported steps yet.
gpu multi dimensional indexing i.e tensor[2,4,5]

@geohot please refactor if possible
pr is completed with support:

gpu single indexing i.e tensor[0]
slicing indexing i.e tensor[2:10] NOTE: not supported steps yet.
gpu multi dimensional indexing i.e tensor[2,4,5]

doesnt support slicing in multidimensional index, i.e tensor[1:2, 3:4, 5:7]

@geohot is this right? :)

I have no idea. Are the tests good and complete?

@geohot the algorithm is simple
[1,2,3]
[4,5,6] ->
gpu buffer stores this as
[1,2,3,4,5,6]
so i wrote an algorithm to access the correct element 👍🏽
and tests are good i think
for testing all features

I have no idea. Are the tests good and complete?

you can do a sanity check too..pull up an interpreter and do some indexing.

Added more test cases,
and setup method, think how we can use it better.

Closing because couldnt find cleaner way to implement! may be some else can implement better!


chore(main): release 1.3.0

:robot: I have created a release beep boop
1.3.0 (2023-12-15)
Features

:sparkles: New feature to check for .git directory in project directories (635f28d)

This PR was generated with Release Please. See documentation.

:robot: Release is at https://github.com/AppelBoomHD/alfred-vscode-github/releases/tag/v1.3.0 :sunflower:


FormBuilderChipsInput 4.0.0+ focus problem

After adding first chip, it's impossible to add new ones without losing and regaining focus. Works on version 3.14.1 without any problem. Even example chip input code in the github is not working. My version is 4.0.2.
Thank you.

I am also having this problem!

I have determined that this problem exists on both iOS and Android.
The problem comes from the flutter_chips_input packages, I think.
On Line 247 in lib/src/chips_input.dart (in flutter_chips_input)
widget.onChanged(_chips.toList(growable: false));
is called. If this line is commented out, the 'losing focus' issue disappears - but you lose the ability to use the onChanged callback.
I've not had time to delve deeper into this, I may also be way off the mark!
Will report back if I find anything more.

I think I fixed this with PR #640.  I think the key attribute was forcing a tree rebuild which was messing with the focus.


loss_local_da doesn't change

when I use custom dataset,the value of loss_local_da doesn't change

It change too 0.249 after a long time, I don't know if this value doesn't change,what it stands for

after training the loss_local_da is still around 0.245


fix(window): middle separator colors

middle_separator is not the same for fill number and all, for fill the colors are the same as text or color (or the reverse of middle sep with number fill).
before:

after:

Also changed where @_ctp_w_left is set since it was always overwritten when the fill is number.

config
# Window
set -g @catppuccin_window_status_style "custom"
set -g window-status-separator ""

## Window global/default configuration
set -g @catppuccin_window_default_text "#{pane_title}"
set -g @catppuccin_window_status "icon"
set -g @catppuccin_window_default_fill "number"
set -g @catppuccin_window_number_position "left"

set -g @catppuccin_window_left_separator "█"
set -g @catppuccin_window_middle_separator "█ "
set -g @catppuccin_window_right_separator ""

## Window current configuration
set -g @catppuccin_window_current_text "#{pane_title}"
set -g @catppuccin_window_current_fill "all"
set -g @catppuccin_window_current_middle_separator " 󰿟 "

Fixes #353

Thanks @vdbe for breaking my entire setup with this and also I'd like to thank @kjnsn for merging this nonsense without testing.

Hey @pentago,
I am sorry to hear that this PR has broken your configuration. However, comments in your tone are unacceptable and is in direct violation of our Code of Conduct (Points 2 and 4 to be exact.)
If you find that a PR has broken your configuration or something looks unexpected as a result of an update, please raise a new issue clearly explaining what's wrong and what you think might be the root cause, without targeting the individuals in question. I won't accept these types of comments towards individuals who have kindly offered up their free time to help maintain this repository.
I highly recommend that you pin your configuration to an existing GitHub tag to avoid unwanted and unexpected breakages.
This is an official warning and if I see more comments in your tone (i.e. targeting individuals) then you will be blocked from this organisation.


OpenSSH with keychain support may expose key passphrase

It's a bit convoluted but I noticed this after struggling and finally succeeding to get sshd running on Yosemite.
Steps to reproduce (only tested with private keys that have a passphrase)

Install openssh with --with-keychain-support
Stop apples sshd
Start brew's sshd, however you want
Log into your local machine ssh localhost
In the same terminal, attempt to log into any other host, localhost works here as well ssh localhost
Notice that no matter how hard you try to type in the password prompt your text always appears in the terminal

Is this the issue that MacPorts attempts to fix with the "pam" patch?
https://trac.macports.org/browser/trunk/dports/net/openssh/Portfile?rev=131258

We won't be supporting the keychain patch going forwards.


SKU's supported

Teams and M365 Business Voice with guest access is also supported on Essentials.
Guest is a user type in Microsoft Teams that is included with all Office 365 Business Premium, Office 365 Enterprise, and Office 365 Education subscriptions. No additional Office 365 license is necessary. Read more about guest access licensing below.

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

ID: 6f1d577c-1360-c2c1-a850-9ac6a941ec2f
Version Independent ID: 346e43d4-22e0-2800-b80d-9fbdac324f75
Content: Manage guest access in Microsoft Teams - Microsoft Teams
Content Source: Teams/manage-guests.md
Service: msteams
GitHub Login: @LanaChin
Microsoft Alias: v-lanac

@dgordonb Thank you for submitting feedback and contributing to the docs. We are currently investigating this.

Hi @dgordonb
Thank you for reaching out to us!
Would you be so kind as to elaborate more on this? Are you suggesting us to update the current content? If yes, could you please let us know the content that you want us to update.
Looking forward to your response. Thank you!

Business Voice is also supported on O365 Business Essentials.  Effectively any SKU that includes Teams.
my MS email is<EMAIL_ADDRESS>and I work on Business Voice in the Teams engineering team.

Sure, @dgordonb
Thank you for your feedback! We will verify and update the content.


libgphoto2: configure fails with `cp: cannot stat ‘/.../usr/share/gettext/po/Makefile.in.in’: No such file or directory

libgphoto2 is located in meta-oe, and is required in meta-ros through this dependency libgphoto2 -> opencv -> cv-bridge.
The build configuration is:
Build Configuration:
BB_VERSION        = "1.33.2"
BUILD_SYS         = "x86_64-linux"
NATIVELSBSTRING   = "fedora-23"
TARGET_SYS        = "i586-oe-linux"
MACHINE           = "qemux86"
DISTRO            = "nodistro"
DISTRO_VERSION    = "nodistro.0"
TUNE_FEATURES     = "m32 i586"
TARGET_FPU        = ""
meta              = "HEAD:ac5c08ea00816852a712a8d7025bce7e865460ec"
meta-oe
meta-python
meta-multimedia   = "master:1dff2351aa6cdafa5a501e8956cb853ab17ed9ae"
meta-qt4          = "master:2c7f8df9039be498f8a2232d1428adb7f4e5e800"
meta-intel-realsense = "master:1d50cb5b82926f8e69a78999e9e8d2ffe2169897"
meta-ros          = "master:8a3adc1a6542f2c8a40b36021a78dc1057e3ed08"

The error log is:
| Configuration (libgphoto2_port 0.12.0):
|
|   Build
|     Source directory:              ../../libgphoto2-2.5.8/libgphoto2_port
|     Compiler:                      i586-oe-linux-gcc  -m32 -march=i586 --sysroot=/home/lukas/dev/openembedded.org/openembedded-core/build/tmp-glibc/work/i586-oe-linux/libgphoto2/2.5.8-r0/recipe-sysroot
|     libltdl includes:
|     libltdl library:               -lltdl
|     Use translations:              no
|
|   Serial ports
|     Serial support:                no
|
|   USB ports
|     libusb-1.0:                    yes
|     libusb0 support:               detected, but disabled (libusb1 support is enabled)
|     libusb:                        yes
|
|   Documentation
|     build API docs with gtk-doc:   no (not requested)
|
| You may run "make" and "make install" now.
|
| Configuration (libgphoto2 2.5.8):
|
|   Build
|     Source code location:          ../libgphoto2-2.5.8
|     GP2DDB support:                no  (EXPERIMENTAL)
|     Compiler:                      i586-oe-linux-gcc  -m32 -march=i586 --sysroot=/home/lukas/dev/openembedded.org/openembedded-core/build/tmp-glibc/work/i586-oe-linux/libgphoto2/2.5.8-r0/recipe-sysroot
|     libltdl includes:
|     libltdl library:               -lltdl
|
|   Features
|     Use translations:              no
|     JPEG mangling support:         yes
|     libxml-2.0:                    yes
|     XML support for Olympus E s..: yes
|     gdlib:                         no
|     libGD conversion support:      no
|     Camlibs:                       all
|     build API docs with gtk-doc:   no (not requested)
|     libexif:                       yes
|
|     Subprojects:                   libgphoto2_port
|
| You may run "make" and "make install" now.
| Please check whether the configuration I detected matches what you
| would like to have. E.g. make sure that USB support is there if you
| intend to use USB cameras with libgphoto2 photo camera library.
|
| Please also check that PKG_CONFIG_PATH contains
|     ${libdir}/pkgconfig
| before compiling any libgphoto2 frontend.
|
| cp: cannot stat ‘/home/lukas/dev/openembedded.org/openembedded-core/build/tmp-glibc/work/i586-oe-linux/libgphoto2/2.5.8-r0/recipe-sysroot/usr/share/gettext/po/Makefile.in.in’: No such file or directory
| WARNING: /home/lukas/dev/openembedded.org/openembedded-core/build/tmp-glibc/work/i586-oe-linux/libgphoto2/2.5.8-r0/temp/run.do_configure.9287:1 exit 1 from 'cp /home/lukas/dev/openembedded.org/openembedded-core/build/tmp-glibc/work/i586-oe-linux/libgphoto2/2.5.8-r0/recipe-sysroot/usr/share/gettext/po/Makefile.in.in /home/lukas/dev/openembedded.org/openembedded-core/build/tmp-glibc/work/i586-oe-linux/libgphoto2/2.5.8-r0/libgphoto2-2.5.8/libgphoto2_port/po/'
| ERROR: Function failed: do_configure (log file is located at /home/lukas/dev/openembedded.org/openembedded-core/build/tmp-glibc/work/i586-oe-linux/libgphoto2/2.5.8-r0/temp/log.do_configure.9287)
ERROR: Task (/home/lukas/dev/openembedded.org/meta-openembedded/master/meta-oe/recipes-graphics/gphoto2/libgphoto2_2.5.8.bb:do_configure) failed with exit code '1'
NOTE: Tasks Summary: Attempted 2430 tasks of which 2429 didn't need to be rerun and 1 failed.

Summary: 1 task failed:
  /home/lukas/dev/openembedded.org/meta-openembedded/master/meta-oe/recipes-graphics/gphoto2/libgphoto2_2.5.8.bb:do_configure
Summary: There was 1 ERROR message shown, returning a non-zero exit code.

When building recipes in meta-ros, the libgphoto2 issue can be avoided by changing the PACKAGECONFIG of opencv to not depend on libgphoto2.
There are two simple ways to do that:

Add a opencv_%.bbappend file with:

PACKAGECONFIG_remove ?= "gphoto2"

Add PACKAGECONFIG_remove_pn-opencv = "gphoto2" to your local.conf.

libgphoto2 successfully builds for melodic using [thud-draft]. @bulwahn < Can I close this issue?

"Silence implies consent" (see http://wiki.c2.com/?SilenceImpliesConsent).


How to overlay segmentation png image over dzi images with panning&zooming in sync

Sorry for long description, just wanted to give as much info as possible. However, can be directly go to Problem statement

Background
First of all, I would really like to thank for the authors and contributors of this awesome large image handling library. We are using it in our web based annotation tool to display WSI (whole slide image) pathology images to enable medical researchers to do various tasks like grid based annotation so that annotated images can be fed into our ML pipeline to train models which is aimed to detect cancerous cases.
We have some overlays like svg grids (previously implemented with viewer.addOverlay) but recently refactored with React.Portals:
<Portal container={viewer.canvas}>
  {isVisible &&
    slide.grids.map((grid) => {
      const texts = pairwiseChunk(grid.tags.map((tag) => tag.name));
      return (
        <ExistingGridBox key={grid.id} viewer={viewer} gridRect={grid.rect} onClick={handleClickGrid(grid)}>
          <svg style={{ overflow: 'visible', pointerEvents: 'none' }} viewBox="0 0 100 100">
            {texts.map((wordPairs, index) => (
              <text key={wordPairs.join(', ')} style={{ fontSize: 10 }} y={(index + 1) * 10}>
                {wordPairs.join(', ')}
              </text>
            ))}
          </svg>
        </ExistingGridBox>
      );
    })}
</Portal>

And here is actual GridBox component which is using viewer to calculate coordinates whenever viewport changes:
const GridBox = ({...}: PropsWithChildren<Props>): JSX.Element => {
  const ref = useRef<HTMLDivElement>(null);
  const [windowCoord, setWindowCoord] = useState<GridRect>(() => convertImageToViewerElementCoord(viewer, gridRect));

  useEffect(() => {
    const handleViewportChange = () => {
      setWindowCoord(convertImageToViewerElementCoord(viewer, gridRect));
    };
    viewer.addHandler('viewport-change', handleViewportChange);

    return () => {
      viewer.removeHandler('viewport-change', handleViewportChange);
    };
  }, [viewer, gridRect]);

  return (
    <Box
      ref={ref}
      className={className}
      data-grid-box
      style={{
        top: `${windowCoord.origin.y}px`,
        left: `${windowCoord.origin.x}px`,
        width: `${windowCoord.width}px`,
        height: `${windowCoord.height}px`,
      }}
      onClick={onClick}
      onMouseEnter={onMouseEnter}
      onMouseLeave={onMouseLeave}
    >
      {children}
    </Box>
  );
};

here is the screenshot of our annotation tool with grids

Here is how we are using OSDViewer (OSDViewer from @lunit/osd-react-renderer which is React wrapper for OpenSeaDragon library)
<>
  <OSDViewer options={OSDOptions} ref={viewerRef} className={className}>
    <viewport
      zoom={viewportZoom}
      rotation={0}
      refPoint={refPoint}
      onOpen={handleViewportOpen}
      onZoom={handleViewportZoom}
      onCanvasKey={handleCanvasKey}
      onCanvasClick={handleCanvasClick}
    />
    <tiledImage tileSource={tileSource as OSD.TileSource} />
    <canvasOverlay onRedraw={handleOverlayRedraw} />
    <mouseTracker onMove={handleMouseMove} />
  </OSDViewer>
  {useZoomController && (
    <ZoomController zoom={viewportZoom} minZoomLevel={0.125} maxZoomLevel={160} onZoom={handleControllerZoom} />
  )}
</>

Problem statement
So far so good. Recently, we are requested to accelerate annotation process by introducing Inference Assisted Annotation which is simply to overlay segmentation mask image (grayscale png) over WSI which is generated by already deployed models.
Requirements are straightforward: inference result, the png mask, should be displayed as a translucent colored area overlaid on the WSI. We are already using dzi images for WSI but now our backend is short of resources so they cannot tile segmentation mask image as dzi tiles. They are providing 3 masks which is identical but with different resolutions, namely,
{
  "tissue_masks": {
    "small": "https://...",
    "medium": "https://...",
    "large": "https://...",
  }
}

and initial plan was to apply them at certain fixed zoom levels. But, I don't think this works as expected as it is not part of OSD render flow, and handling this manually outside of OSD does not seem promising. So, I just want to use only highest resolution png  (actually its size is very small compared to WSI, so it can be loaded very fast).
Problems I facing:

overlay png mask image over WSI and it should be in sync with WSI when panning&zooming, etc.. (should be resized automatically by OSD like other overlays)
how to efficiently convert grayscale mask into RGB colored mask (is there any helpers in OSD for this)

When I looked through the Issue list about what I want to achieve, there are only bits and pieces about it, but honestly I could not find detailed info either because of my poor search or it does not exist.
Hence, I would really appreciate if someone can direct me to the right direction if possible with actual code samples.

overlay png mask image over WSI and it should be in sync with WSI when panning&zooming, etc.. (should be resized automatically by OSD like other overlays)

For this part of it, you could use viewer.addTiledImage() to add your PNG at the appropriate position (using x, y, and either width or height). When you navigate (zoom/pan), the underlying DZI and the PNG would stay in sync.

@pearcetm
Thank you for the response. Let me try what you have suggested and get back to you with the result

@iangilman
I was able to render mask image over WSI with two approaches:

using viewer.addOvelay() method

// omitted for brevity
const maskImage = document.createElement('img');
maskImage.crossOrigin = 'Anonymous';
maskImage.src = maskPath;
const overlayLocation = new OpenSeadragon.Rect(0, 0, 1, 1);

maskImage.onload = async () => {
  const updatedImage = await grayscaleToColorfulImage(maskImage);
  viewer.addOverlay({
    element: updatedImage,
    location: overlayLocation,
    placement: OpenSeadragon.Placement.CENTER,
  });
};

using viewer.addTiledImage() method

// omitted for brevity
const maskImage = document.createElement('img');
maskImage.crossOrigin = 'Anonymous';
maskImage.src = maskPath;
const overlayLocation = new OpenSeadragon.Rect(0, 0, 1, 1);

maskImage.onload = async () => {
  const updatedImage = await grayscaleToColorfulImage(maskImage);
  viewer.addTiledImage({
    tileSource: {
      type: 'image',
      url: updatedImage.src,
    },
    x: 0,
    y: 0,
    width: 1,
    opacity: 0.6,
  });
};

Both of them are working as expected. But I noticed performance difference, tileImage has noticeable lag wile zooming compare to overlayed image. It is small but still I can feel it. I assumed the reason of the performance difference between addTiledImage() and addOverlay() in this scenario is likely due to the extra operations related to handling tiled images that addTiledImage() performs, even when working with a non-tiled image (OpenSeadragon still treats it as if it were a tiled image, but with only one tile). Using addOverlay() can provide better performance for non-tiled images, as it avoids this overhead and focuses on positioning and scaling the provided HTML element.
Can you confirm the assumption, if right, or could you give better explanation if my assumption is wrong. Thanks in advance

tileImage has noticeable lag while zooming compare to overlayed image

I'm a little surprised this would cause a noticeable difference, but especially if the PNG is fairly large, there is definitely going to be a cost with compositing it onto the underlying image, especially because it has transparency.
I think your approach with addOverlay() is probably better, since as you point out, it's not really a tiled image anyway.

@humoyun91 I agree with @pearcetm that addOverlay is a fine choice. I do want to mention, however, that if you want to take advantage of all three sizes of image that you have available, you could do so with addTiledImage and this tile source:
https://openseadragon.github.io/examples/tilesource-legacy/