Image similarity?

Incredible work as always you guys! In looking at the Colab, it seems it's possible to do image-to-text similarity but I'm curious if it's possible to compare image similarity as well.
For instance, if I just replace 'text_features' with 'image_features' would that work / be the best way to do this?
image_features /= image_features.norm(dim=-1, keepdim=True)
image_2_features /= image_2_features.norm(dim=-1, keepdim=True)
similarity = image_2_features.cpu().numpy() @ image_features.cpu().numpy().T

Thanks!
I believe image similarities will work, although we haven't experimented/evaluated tasks using image similarity measures specifically.

Thanks!
I believe image similarities will work, although we haven't experimented/evaluated tasks using image similarity measures specifically.

Thank you! I'll try it out and see

Thank you! I'll try it out and see

I tried it and it seems to work pretty well. (actually better than using a pretrained on classification efficientnet for example)

I tried it and it seems to work pretty well. (actually better than using a pretrained on classification efficientnet for example)

I tried it and it seems to work pretty well. (actually better than using a pretrained on classification efficientnet for example)

Just to be clear: when you see it works well (and even better than another method), you mean that you have this feeling based on visual inspection of a few examples, or is it based on an image dataset which you had built beforehand to assess the methods? I would not have any issue with any of the methods, but it is just out of curiosity.

I tried it and it seems to work pretty well. (actually better than using a pretrained on classification efficientnet for example)

Just to be clear: when you see it works well (and even better than another method), you mean that you have this feeling based on visual inspection of a few examples, or is it based on an image dataset which you had built beforehand to assess the methods? I would not have any issue with any of the methods, but it is just out of curiosity.

Visual inspection for now (putting image embeddings in a faiss index and trying a few queries), but I also intend to do a more extensive evaluation later on.
I know there are also image retrieval research dataset and tasks where evaluating this model would give the most reliable and comparable results.

Visual inspection for now (putting image embeddings in a faiss index and trying a few queries), but I also intend to do a more extensive evaluation later on.
I know there are also image retrieval research dataset and tasks where evaluating this model would give the most reliable and comparable results.

Results are interesting, but one has to be careful because the model likes to pick text from images.

Results are interesting, but one has to be careful because the model likes to pick text from images.

Maybe that is because the words (e.g., "story") appear in the text..

Maybe that is because the words (e.g., "story") appear in the text..

Maybe that is because the words (e.g., "story") appear in the text..

I use the pre-trained model, and I only show the images it. Zero text.

Maybe that is because the words (e.g., "story") appear in the text..

I use the pre-trained model, and I only show the images it. Zero text.

Thanks for the clarification. Then the model might have learned attentions to the embedded text regions during the training. It is very interesting, in both of the cases.

Thanks for the clarification. Then the model might have learned attentions to the embedded text regions during the training. It is very interesting, in both of the cases.

I have added a search engine to look for specific Steam games:
https://woctezuma.github.io/steam-svelte-autocomplete/index.html
I am still having fun with this.

I have added a search engine to look for specific Steam games:
https://woctezuma.github.io/steam-svelte-autocomplete/index.html
I am still having fun with this.

I made an app to explore how image similarity works in CLIP by tying it to the closest images in Unsplash. Like @woctezuma noted, it seems to latch onto images with matching text, but in generally there is a lot more going on:

I made an app to explore how image similarity works in CLIP by tying it to the closest images in Unsplash. Like @woctezuma noted, it seems to latch onto images with matching text, but in generally there is a lot more going on:

Anyone has any experience on using CLIP image encoding in a loss function (instead pixel loss like MSE, perceptional loss like LPIPS or structural similar like SSIM) to guide image generation (for instance, using generating images matching both text and a given image) or, for example, VAE training. My experiments with this have not been successful, it simply does not converge. I wonder if it is the case that CLIP image encoding is strictly semantic and does not contain enough visual features to properly guide training to produce images which resemble, for instance, compositionally to a given image.

@htoyryla there is an active community on twitter trying to do just that! I found an interesting point about the text vectors vs image vectors -- they aren't colocated!
https://twitter.com/metasemantic/status/1356406256802607112

Thanks...  my problem seems BTW more like finding the image from the image encoding.

Anyone has any experience on using CLIP image encoding in a loss function (instead pixel loss like MSE, perceptional loss like LPIPS or structural similar like SSIM) to guide image generation (for instance, using generating images matching both text and a given image)

https://github.com/orpatashnik/StyleCLIP

Oh, sorry, it looks like I formulated my question ambiguously. I am specifically looking for a case which uses CLIP to compare similarity between two images, i.e. loss calculated from two image embeddings instead of using a more conventional image loss (MSE, LPIPS or SSIM), possibly together with CLIP to compare text with image.
The above arrangement uses CLIP in the normal way to compare text and image embeddings.

Relevant to some discussion earlier in the thread (and at least an interesting read): https://distill.pub/2021/multimodal-neurons/

Results are interesting, but one has to be careful because the model likes to pick text from images.
 The query is the top left picture. In the second to last picture, there is the word "stonies". It is only in the last picture that there is a visually similar planet shape in the same position as in the query.

Similarly, here, it is the word "empire" which seems to drive the matching between these images.

Here, the word "forest". Etc.

It is both impressive... and a bit disappointing if I want to use the model for retrieving similar images.

You can actually remove text (via some text detector) from those images before feeding them to clip and see how it goes.

Hello， I just want to know  the L2-norm and cos will be working in the case which between the image and image ？

Slightly relevant: this figure in the DALL-E 2 paper.
![Picture](https://i.imgur.com/SsuBjgu.png

can anyone post a fully working code sample (a google colab notebook would be amazing) that will take image A and image B and calculate their image similarity?
Thank you so much
@woctezuma @iremonur @matrixgame2018 @Sxela @htoyryla @thoppe @scorpionsky @rom1504 @youssefavx @jongwook

First, you extract features as shown in the README:
import torch
import clip
from PIL import Image

device = "cuda" if torch.cuda.is_available() else "cpu"
model, preprocess = clip.load("ViT-B/32", device=device)

image = preprocess(Image.open("CLIP.png")).unsqueeze(0).to(device)

with torch.no_grad():
    image_features = model.encode_image(image)

Then you compute similarity between features, e.g. as in the original post.

First, you extract features as shown in the README:
import torch
import clip
from PIL import Image

device = "cuda" if torch.cuda.is_available() else "cpu"
model, preprocess = clip.load("ViT-B/32", device=device)

image = preprocess(Image.open("CLIP.png")).unsqueeze(0).to(device)

with torch.no_grad():
    image_features = model.encode_image(image)

Then you compute similarity between features, e.g. as in the original post or as in the README:
# Pick the top 5 most similar labels for the image
image_features /= image_features.norm(dim=-1, keepdim=True)
text_features /= text_features.norm(dim=-1, keepdim=True)
similarity = (100.0 * image_features @ text_features.T).softmax(dim=-1)

thanks a lot for answer
i did come up with this way what you think?
also do you think clip is the best available method atm for such task?
lets say i liked a jacket on a person and i want to find similar jackets from my database
import torch
from transformers import CLIPImageProcessor, CLIPModel, CLIPTokenizer
from PIL import Image

# Load the CLIP model
model_ID = "openai/clip-vit-large-patch14"
model = CLIPModel.from_pretrained(model_ID)

preprocess = CLIPImageProcessor.from_pretrained(model_ID)

# Define a function to load an image and preprocess it for CLIP
def load_and_preprocess_image(image_path):
    # Load the image from the specified path
    image = Image.open(image_path)

    # Apply the CLIP preprocessing to the image
    image = preprocess(image, return_tensors="pt")

    # Return the preprocessed image
    return image

# Load the two images and preprocess them for CLIP
image_a = load_and_preprocess_image('/content/a.JPG')["pixel_values"]
image_b = load_and_preprocess_image('/content/e.png')["pixel_values"]

# Calculate the embeddings for the images using the CLIP model
with torch.no_grad():
    embedding_a = model.get_image_features(image_a)
    embedding_b = model.get_image_features(image_b)

# Calculate the cosine similarity between the embeddings
similarity_score = torch.nn.functional.cosine_similarity(embedding_a, embedding_b)

# Print the similarity score
print('Similarity score:', similarity_score.item())

Sorry, I don't have any authority on this subject. I cannot help more or recommend a method over another. 😅
That being said, out of curiosity, I would probably try X-Decoder.

Zou, Xueyan, et al. "Generalized Decoding for Pixel, Image, and Language." arXiv preprint arXiv:2212.11270 (2022).


Replaced 200 HTTP status code with Symfony constant

This is a small PR. There were simply magic numbers in the constructor

Ah cool, thank you :) Merged.


WoS import sometimes shows "J" instead of WoS type

Bug
In the new Biblio, whenever importing records via WoS, it does not always import the WoS type – even when it is available.
Steps to reproduce

Go to publications

Import a set of records via WoS https://ugentbe-my.sharepoint.com/:t:/g/personal/miet_claes_ugent_be/EaUZbpjO1_pJpK1qoVKTUhEB54v8lozXK_x4Kmk3j14gmw?e=VyBxZC

Go to publication details of one example record (in my case:(https://backoffice.bibliotest.ugent.be/publication/01GM2YYBE3KE98DXE28DC1F0QQ), scroll to WoS type

Double check one of the examples and see the language available in WoS (in my case: https://www.webofscience.com/wos/woscc/full-record/WOS:000717291300001)

Context
Test example with 22 examples, none have language imported: https://ugentbe-my.sharepoint.com/:t:/g/personal/miet_claes_ugent_be/EaUZbpjO1_pJpK1qoVKTUhEB54v8lozXK_x4Kmk3j14gmw?e=VyBxZC
Record example in test environment (no edits done): https://backoffice.bibliotest.ugent.be/publication/01GM2YYBE3KE98DXE28DC1F0QQ
Record number in production environment (in review, probably edited): under construction

@mietcls @nics Seems to work as intended?
WOS Type contains the type from the TY, DT and PT fields in the WoS import file.  The PT field contains values like "J", "C", "S" and others.  "J" stands for "Journal Article" per the documentation: https://images.webofknowledge.com/images/help/WOS/hs_wos_fieldtags.html
The old Librecat application has a fix which implements a WoS to Biblio mapping. I could give the decoder logic more scrutiny to see if the mappings happens correctly. Assuming that the imported data is consistent of course.

Thanks for the input, we've come to the conclusion we will not fix this (especially with the "not starting from 0" mindset of the future in mind).


Adding NDEBUG to release

I did not expect this small change to create failures. Interesting.

@jkeiser This was a fun bug to fix. I wasted an embarrassingly long time on it.

Merging.


champions you play instead of champions you own

https://github.com/yawhide/Lol-personal-counters/commit/a3c1f107fb8453272a29e1d7efb7c88f5bcf9823


Update the benchmarks

Hey, I just noticed this package, care to update the benchmarks to run against the latest left-pad?

huh, yeah it looks like they updated the code to use the same pattern as this lib (from repeat-string).  Should I steal their optimizations first without attribution? Or just run benchmarks as is? jk but it unfortunately seems like this is becoming the norm.

actually sorry, I'm assuming you mean this one: https://github.com/stevemao/left-pad/blob/master/index.js. but perhaps you mean a different one?

Yeah, that one.
On Fri, Apr 29, 2016 at 6:43 PM, Jon Schlinkert<EMAIL_ADDRESS>wrote:

actually sorry, I'm assuming you mean this one:
https://github.com/stevemao/left-pad/blob/master/index.js. but perhaps
you mean a different one?
—
You are receiving this because you authored the thread.
Reply to this email directly or view it on GitHub
https://github.com/jonschlinkert/pad-left/issues/7#issuecomment-215767220

Sorry for the delay. benchmarks. The benchmarks show both left-pad libs, the one on npm and the stevemao one.
@benjamingr what is the reasoning behind making the code in stevemao/left-pad more like the code in this one, versus just using this lib?

I didn't know this lib, I just used the code from V8 and caching which was simple - I only googled for other libraries later to look for benchmarks.

k, closing since benchmarks were updated


Compiler errors due to old 0.9.4 version of openssl crate.

Attempting to compile the openssl crate on systems with a newer version of SSL results in the following error:
error: failed to run custom build command for `openssl v0.9.24`
process didn't exit successfully: `/home/mindtree/programming/rust/gutenberg/target/release/build/openssl-73cd6a774e5ab81f/build-script-build` (exit code: 101)
--- stderr
thread 'main' panicked at 'Unable to detect OpenSSL version', /home/mindtree/.cargo/registry/src/github.com-1ecc6299db9ec823/openssl-0.9.24/build.rs:16:14
stack backtrace:
   0: std::sys::unix::backtrace::tracing::imp::unwind_backtrace
             at libstd/sys/unix/backtrace/tracing/gcc_s.rs:49
   1: std::sys_common::backtrace::print
             at libstd/sys_common/backtrace.rs:71
             at libstd/sys_common/backtrace.rs:59
   2: std::panicking::default_hook::{{closure}}
             at libstd/panicking.rs:211
   3: std::panicking::default_hook
             at libstd/panicking.rs:227
   4: std::panicking::rust_panic_with_hook
             at libstd/panicking.rs:476
   5: std::panicking::begin_panic
   6: build_script_build::main
   7: std::rt::lang_start::{{closure}}
   8: std::panicking::try::do_call
             at libstd/rt.rs:59
             at libstd/panicking.rs:310
   9: __rust_maybe_catch_panic
             at libpanic_unwind/lib.rs:102
  10: std::rt::lang_start_internal
             at libstd/panicking.rs:289
             at libstd/panic.rs:392
             at libstd/rt.rs:58
  11: main
  12: __libc_start_main
  13: _start

This can be fixed by updating to openssl v0.10+. Checking cargo tree, it looks like openssl 0.9.4 is picked up via:
link_checker -> reqwest -> hyper-tls -> native-tls -> openssl

It looks like updating the reqwest version depended on by link_checker should solve this.
sfackler/rust-openssl#987 provides a little more info on the error.

Next release is 0.5!


Add fairseq to supported libraries for audio-to-audio

No, this only impacts the "compatible libraries" at top right https://huggingface.co/tasks/audio-to-audio
API is managed by https://github.com/huggingface/huggingface.js/blob/main/packages/tasks/src/library-to-tasks.ts#L22

Merging as the error is unrelated


Remove defunctLabel check due to rewrite of StatefulSets these days, …

…fix some CRD comments, modify created-by label value to match Kubernetes recommendation

What this PR does:
Removes defuctLabel check for managed-by label, changes created-by label value and updates some CRD descriptions.
Which issue(s) this PR fixes:
Fixes #354
Checklist

[ ] Changes manually tested
[x] Automated Tests added/updated
[ ] Documentation added/updated
[x] CHANGELOG.md updated (not required for documentation PRs)
[x] CLA Signed:  DataStax CLA

Actually, the created-by fix is wrong. Created-by should not be pushed to CassandraDatacenter, since cass-operator is not creating that resource, only managing it.

k8ssandra-operator should add the created-by..


How to access web inspector to work on VSCode themes?

VSCode Version: Version 1.8.0-insider
OS Version: 10.12.1

There used to be a way to access the web inspector to inspect VSCode itself.   It seems to be gone now.
As a theme author, how do I inspect the scope of items on the screen in order for me to color the scopes in my tmTheme file? Is there a new method?

You still should be able to go to the Help -> Toggle Developer Tools menu item to inspect the vscode dom. Is that menu item missing for you?


wasm32-unknown-unknown target build error for LLVM 9+

Here's the steps to reproduce this:
$ # ensure PATH has clang 9+
$ clang --version
clang version 9.0.0 (https://github.com/llvm/llvm-project.git 1931d3cb20a00da732c5210b123656632982fde0)
Target: x86_64-unknown-linux-gnu
Thread model: posix
InstalledDir: /usr/lib/llvm-9/bin
$ git clone https://github.com/nervosnetwork/blake2b-rs
$ cd blake2b-rs
$ cargo build --target=wasm32-unknown-unknown
   Compiling cc v1.0.45
   Compiling blake2b-rs v0.1.5 (/home/ubuntu/code/blake2b-rs)
error: failed to run custom build command for `blake2b-rs v0.1.5 (/home/ubuntu/code/blake2b-rs)`

Caused by:
  process didn't exit successfully: `/home/ubuntu/code/blake2b-rs/target/debug/build/blake2b-rs-55b914c5314ec856/build-script-build` (exit code: 1)
--- stdout
TARGET = Some("wasm32-unknown-unknown")
OPT_LEVEL = Some("0")
HOST = Some("x86_64-unknown-linux-gnu")
CC_wasm32-unknown-unknown = None
CC_wasm32_unknown_unknown = None
TARGET_CC = None
CC = None
CFLAGS_wasm32-unknown-unknown = None
CFLAGS_wasm32_unknown_unknown = None
TARGET_CFLAGS = None
CFLAGS = None
CRATE_CC_NO_DEFAULTS = None
DEBUG = Some("true")
running: "clang" "-O0" "-ffunction-sections" "-fdata-sections" "-fPIC" "-g" "-fno-omit-frame-pointer" "--target=wasm32-unknown-unknown" "-Wall" "-Wextra" "-o" "/home/ubuntu/code/blake2b-rs/target/wasm32-unknown-unknown/debug/build/blake2b-rs-cc59db8c9c4ef2be/out/BLAKE2/ref/blake2b-ref.o" "-c" "BLAKE2/ref/blake2b-ref.c"
cargo:warning=BLAKE2/ref/blake2b-ref.c:17:10: fatal error: 'string.h' file not found
cargo:warning=#include <string.h>
cargo:warning=         ^~~~~~~~~~
cargo:warning=1 error generated.
exit code: 1

--- stderr

error occurred: Command "clang" "-O0" "-ffunction-sections" "-fdata-sections" "-fPIC" "-g" "-fno-omit-frame-pointer" "--target=wasm32-unknown-unknown" "-Wall" "-Wextra" "-o" "/home/ubuntu/code/blake2b-rs/target/wasm32-unknown-unknown/debug/build/blake2b-rs-cc59db8c9c4ef2be/out/BLAKE2/ref/blake2b-ref.o" "-c" "BLAKE2/ref/blake2b-ref.c" with args "clang" did not execute successfully (status code exit code: 1)

I'm using blake2b-rs crate just as an example here, I suspect any crate using cc could run into this issue.
The same issue can be reproduced on macOS with latest LLVM.
Thanks in advance!

Thanks for the report! This crate can't arrange for everyone's sysroot to be set up right though nor fix all errors in C compilation. This is one you'll need to work with locally, since there's nothing this crate can do to fix this. Configuring a working toolchain for wasm32-unknown-unknown isn't easy, I'd recommend using wasm32-wasi if you can.


Tab completion for project names

I have no idea how to do this but boy do we need it

Oh boy, I looked into this and it is gnarly. Alternate solution: we could modify commands to take paths instead of slugs? That way the paths autocomplete. Curious what @alykat @qdinhbui2 would think of this idea?


Duplicate headers in response

I've noticed that it is possible for the filter to return responses with multipleAccess-Control-Allow-Origin headers, if the original response already happens to contain some CORS headers. Browsers don't like these kind of responses, with Chrome complaining as following:

The 'Access-Control-Allow-Origin' header contains multiple values '*, *', but only one is allowed. Origin 'http://localhost:8000' is therefore not allowed access. Have the server send the header with a valid value, or, if an opaque response serves your needs, set the request's mode to 'no-cors' to fetch the resource with CORS disabled.

While I understand that there should only be on source of CORS headers for a single response, it is quite easy to bump in to the issue if enriching resources from other CORS-enabled services. Then the CORS headers from both services will be appended to the response.
I guess the simple solution would be to check if the response already contains CORS headers, and then either leave them be, or overwrite them with new values. Adding multiple CORS headers doesn't seem to be good behaviour.

As for the CORS specification, it is stated under 7.2 Resource Sharing Check that the response should be considered invalid if it contains more than one Access-Control-Allow-Origin header.

I also ran into this issue. I fixed it by changing the <url-pattern> to match only those remotes which needed CORS headers.


Fix interfaces.

They are currently broken.
I propose storing method pointers in an array along with a pointer to the value of the interface. Similar to the current implementation of the something type.

They are working now.. at least partially!


Is the library in a usable/robust state?

If I wanted to train a feedforward network agent with ~100 inputs, 8 outputs, and a hidden layer of 512 or so, can I use a DQN from this library to do it and expect it to work out okay?
Does the DQN have any of the bells and whistles such as dueling DQN, prioritized experience replay, etc.?

Hi,
Currently this library implements the "most simple" form of the DQN. It is absolutely possible to use it with your inputs/outputs/layers, but it will be only the Q function with only the classical experience replay. So It will work out okay but without wonderful results, because of the need of better algorithms. Double Learning et Prioritized Experience Replay will be implemented in the future, but it needs some time ;)

Thanks for the answer, keep up the good work!


Enable draw mode programmatically

It feels like I’m missing something obvious, but I can’t figure out how to do stuff like this:
// enable polygon Draw Mode
map.pm.enableDraw("Polygon", {
  snappable: true,
  snapDistance: 20,
});

I believe this would let me initialise the polygon draw mode from a button that I control (separate from the geoman UI), but I can’t figure out how to access map.pm so that I can call the enableDraw method.
I have used the wrapper from your example, and everything works perfectly, but the ref on the FeatureGroup doesn’t appear to give me access to map.pm.enableDraw, at least not in the ways I have tried (things like ref.current.pm.enableDraw and variations). Is there a way to do this?
My goal is to be able to have a couple of buttons on a UI that I have overlaid on the map, with labels such as "Create a polygon" and "Create a circle" to get the user started, which would have the same effect as pressing the corresponding icons in the Geoman toolbar.

I was able to solve this by adding a ref on the MapContainer and then passing it down to the GeomanWrapper component. Apologies for the noise, closing.


bug: Injected formatter... does nothing?

Neovim version (nvim -v)
NVIM v0.10.0-dev Build type: RelWithDebInfo LuaJIT 2.1.0-beta3
Operating system/version
Ubuntu 22.04
Add the debug logs

[X] I have set log_level = vim.log.levels.DEBUG and pasted the log contents below.

Log file
Here I ran "format" thrice
08:11:47[DEBUG] Running formatters on /home/mlar/test2.py: { "injected" }
08:11:47[INFO] Run injected on /home/mlar/test2.py
08:11:47[DEBUG] Running LSP formatter on /home/mlar/test2.py
08:11:51[DEBUG] Running formatters on /home/mlar/test2.py: { "injected" }
08:11:51[INFO] Run injected on /home/mlar/test2.py
08:11:51[DEBUG] Running LSP formatter on /home/mlar/test2.py
08:12:06[DEBUG] Running formatters on /home/mlar/test2.py: { "injected" }
08:12:06[INFO] Run injected on /home/mlar/test2.py
08:12:06[DEBUG] Running LSP formatter on /home/mlar/test2.py
Describe the bug
(slight follow-up to https://github.com/stevearc/conform.nvim/issues/224）
Hi Steve, thanks again for an awesome plug-in!
It seems that injected formatter does... nothing?
The below Treesitter injections works (the highlighting is correctly injected) - and the SQL/JSON formatters work, if I copy the contents to a tmp.sql / tmp.json file
.config/nvim/queries/python/injections.scm:
; Variables ending in "_sql" and "_SQL"
(expression_statement
  (assignment
    left: (identifier) @_left (#match? @_left "(_sql|_SQL)$")
    right: (string
      (string_content) @injection.content
      (#set! injection.language "sql")
    )
  )
)

; Variables ending in "_json" and "_JSON"
(expression_statement
  (assignment
    left: (identifier) @_left (#match? @_left "(_json|_JSON)$")
    right: (string
      (string_content) @injection.content
      (#set! injection.language "json")
    )
  )
)

test2.py:

This is also the case for rust injections (the examples would just be too big)
What is the severity of this bug?
tolerable (can work around it)
Steps To Reproduce

Create the files from the Minimal example file-step
nvim -u repro.lua test2.py
Run :lua require("conform").format()

Expected Behavior
I'd expect the formatters to run, or at least indicate why they didn't
Minimal example file
Python file test2.py:
test_sql = """
    select a,b from myTable where a>b
"""

test_json = """
{ "this": "is a value", "that": "is j'son" }
"""

.repro/config/nvim/queries/python/injections.scm:
; Variables ending in "_sql" and "_SQL"
(expression_statement
  (assignment
    left: (identifier) @_left (#match? @_left "(_sql|_SQL)$")
    right: (string
      (string_content) @injection.content
      (#set! injection.language "sql")
    )
  )
)

; Variables ending in "_json" and "_JSON"
(expression_statement
  (assignment
    left: (identifier) @_left (#match? @_left "(_json|_JSON)$")
    right: (string
      (string_content) @injection.content
      (#set! injection.language "json")
    )
  )
)

Minimal init.lua
-- DO NOT change the paths and don't remove the colorscheme
local root = vim.fn.fnamemodify("./.repro", ":p")

-- set stdpaths to use .repro
for _, name in ipairs({ "config", "data", "state", "cache" }) do
  vim.env[("XDG_%s_HOME"):format(name:upper())] = root .. "/" .. name
end

-- bootstrap lazy
local lazypath = root .. "/plugins/lazy.nvim"
if not vim.loop.fs_stat(lazypath) then
  vim.fn.system({
    "git",
    "clone",
    "--filter=blob:none",
    "--single-branch",
    "https://github.com/folke/lazy.nvim.git",
    lazypath,
  })
end
vim.opt.runtimepath:prepend(lazypath)

-- install plugins
local plugins = {
  "folke/tokyonight.nvim",
  {
    "stevearc/conform.nvim",
    config = function()
      require("conform").setup({
        log_level = vim.log.levels.DEBUG,
        formatters_by_ft = {
          json = { "fixjson" },
          sql = { "sql_formatter" },
          ["*"] = { "injected" }
        }
      })
    end,
  },
  -- add any other plugins here
	{
		"nvim-treesitter/nvim-treesitter",
		config = function(_, _)
			require("nvim-treesitter.configs").setup({
				ensure_installed = { "python", "json", "sql" },
				auto_install = true,
				highlight = { enable = true },
			})
		end,
	},

}
require("lazy").setup(plugins, {
  root = root .. "/plugins",
})

vim.cmd.colorscheme("tokyonight")
-- add anything else here

Additional context
No response

Interestingly enough, I get the same "error" in markdown files:
test.md:
```json
{"key": "value", "key2": "value"}
```

```sql
select a,b from Table where a>b
```

Highlighting is correct:

Running :lua require("conform").format() yields the same log file, and no actual formatting:
08:43:23[DEBUG] Running formatters on /tmp/test.md: { "injected" }
08:43:23[INFO] Run injected on /tmp/test.md

A recent change to the formatter broke it only on nightly. Should be working again.

Steven, you are a hero. Thanks for the very fast turn around!


PowerShell Code Error on Page

Recent edit to the page dropped the trailing single quote at the end of the PowerShell code example under heading 'Change the VM size'.  Add a single quote to the end of line three in the first code snippet.
(added this issue as the former was closed and I don't see a way to reopen)

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

ID: 78e65bf3-59d7-4b6d-f45e-884f4ea16cbd
Version Independent ID: 49fbcedf-e5ab-5a83-edba-3609f955756f
Content: Resize a virtual machine - Azure Virtual Machines
Content Source: articles/virtual-machines/resize-vm.md
Service: virtual-machines
GitHub Login: @ericd-mst-github
Microsoft Alias: cynthn

Hi @srotblat
Thanks for this quick feedback. We are currently making this change and will push it shortly.

@ericd-mst-github Thanks for your quick responses.
@srotblat
Thanks for your feedback! We will investigate and update as appropriate.

The change has now been updated to the article. Please let us know in another thread if other issues are present.
Thank you again for your feedback!

@ericd-mst-github Thanks for your quick responses. Please share the pull request link once the document has been updated with the changes.

@ericd-mst-github Eric D FTE Thanks for your quick responses. Please share the pull request link once the document has been updated with the changes.

No worries. Here's the pull request link: https://github.com/MicrosoftDocs/azure-docs-pr/pull/261236

@ericd-mst-github Thanks for creating pull request.
@srotblat
Thanks for reporting this! We have created a PR for this issue and the changes should go live soon.


[WIP] Fix handling of null value in from_adjacency_matrix

This commit fixes an issue with the handling of null values in the
from_adjacency_matrix for PyDiGraph and PyGraph. Previously, the
function incorrectly treated any value <= 0 as a null value and didn't
add an edge for that. But the behavior should have been != instead of
less than or equal to. Additionally, the null value of 0.0 was hard
coded into the constructor methods which precluded using different
values. This commit fixes both issues by adding a new kwarg, null_value,
that lets users specify the null value they'd like to use. Additionally,
the behavior is changed to just use a not equals comparison to enable
using negative values (assuming null_value is zero).
Fixes #408

This is nice and we should probably add this new kwarg to *_adjacency_matrix (https://github.com/Qiskit/retworkx/blob/main/src/connectivity/mod.rs#L331) and *_distance_matrix (https://github.com/Qiskit/retworkx/blob/main/src/shortest_path/mod.rs#L1032) as well.

Yeah, that's a good idea. I'll push up a follow up PR to do the matrix generation functions too. Want to keep this one more about the reported bug.


[FEATURE] Add support for better pre-commit

Hi folks,
I would like to propose the addition of pre-commit support on NuttX.
Yes, I'm aware there's a pre-commit script on tools. I do not want to replace it.
Today, we need to manually run checkpatch.sh or add the available pre-commit script to our git hook. There's another option that should be more user friendly and most important, adds more linter options.
This is the tool: https://pre-commit.com/
I've used it before with massive repositories, different languages and it has always worked great.
Describe the solution you'd like
Additions to the repository
A single addition would be necessary, which is a file called .pre-commit-config.yamlon the root directory (could go on nuttx-apps repository as well).
Maintenance
Little maintenance required. Simply add or remove the linter scripts from the config file.
Are we losing checkpatch.sh?
No, as a first step, we could add checkpatch.sh to the pre-commit tool so we don't need to move all linters that already working from checkpatch.shto this config file (although it is possible).
Also, we don't interfere with CI.
Is it mandatory for me to use it?
No, use of this tool is not mandatory. You can simply ignore it if you want.
Config file example:
This is the config file I'm running right now. It is located in the root directory under
$ cat .pre-commit-config.yaml
repos:
-   repo: https://github.com/pre-commit/pre-commit-hooks
    rev: v4.6.0
    hooks:
    -   id: end-of-file-fixer
    -   id: trailing-whitespace
    -   id: check-added-large-files
-   repo: local
    hooks:
    -   id: nxstyle
        name: nxstyle
        language: script
        entry: ./tools/checkpatch.sh -f

You can see that I'm running checkpatch as a script language. checkpatch itself runs black and isort for Python files, those can also be added to this config file.
It's also possible to simply add nxstyle instead of the checkpatchscript.
How to enable it
Install the pre-commit tool on your machine:
pip install pre-commit.
You need pip because this package is Python based.
Note about Ubuntu:
If using Ubuntu 24+, maybe you will need to install with apt because Python packages cannot be installed directly with pip anymore. In this case:
sudo apt install pre-commit should suffice.
After installing, enter the NuttX directory and simply run pre-commit install
This should install the hooks that are defined on the config file:
fdcavalcanti@espubuntu:~/nuttxspace/nuttx$ pre-commit install
pre-commit installed at .git/hooks/pre-commit

Usage
Simple commit example: I've added a white space at the end of a line in esp32s2_wlan.c and messed with indentation on a if statement. You can see it fixed the whitespace issue was automatically fixed and now I should simply git add this file again, after correcting the nxstyle complaints.
fdcavalcanti@espubuntu:~/nuttxspace/nuttx$ git commit -m "Testing pre-commit"
fix end of files.........................................................Passed
trim trailing whitespace.................................................Failed
- hook id: trailing-whitespace
- exit code: 1
- files were modified by this hook

Fixing arch/xtensa/src/esp32s2/esp32s2_wlan.c

check for added large files..............................................Passed
nxstyle..................................................................Failed
- hook id: nxstyle
- exit code: 1

/home/fdcavalcanti/nuttxspace/nuttx/arch/xtensa/src/esp32s2/esp32s2_wlan.c:737:11: error: Bad right brace alignment

After correction, the commit is done.
fdcavalcanti@espubuntu:~/nuttxspace/nuttx$ git commit -m "Testing pre-commit"
fix end of files.........................................................Passed
trim trailing whitespace.................................................Passed
check for added large files..............................................Passed
nxstyle..................................................................Passed
[feature/esp32s2_wifi 8394e9f3cf] Testing pre-commit
 1 file changed, 1 insertion(+)

I believe there's room to improve our linting, use other hooks and I this can be also extended to the CI.
What do you guys think?
Describe alternatives you've considered
No response
Verification

[X] I have verified before submitting the report.

nice idea, @fdcavalcanti !

So, I'll send the PR soon with the features I mentioned previously.
I tried to expand the config file to do everything checkpatch does. Worked fine except for nxstyle:

pre-commit passes a relative path from root and since nxstyle is inside tools, it can't work itself out.
nxstyle must be built before running, which goes against the standard tools used with pre-commit.

I wonder if some other generic linting tool could be configured to work just as nxstyle.


setNumberLoop(-1) does't work on iOS when mp3 file is short (1s)

:beetle: Please post your code:
play(name) {
        console.log("play:" + name);
        Sound.setCategory('Playback');
        // Load the sound file 'whoosh.mp3' from the app bundle
        // See notes below about preloading sounds within initialization code below.
        var whoosh = new Sound(name, Sound.MAIN_BUNDLE, (error) => {
            if (error) {
                console.log('failed to load the sound', error);
            } else { // loaded successfully
                whoosh.setNumberOfLoops(-1);
                whoosh.play((success) => {
                    if (success) {
                        console.log('successfully finished playing');
                    } else {
                        console.log('playback failed due to audio decoding errors');
                    }
                });
            }
        });

    }

Until the problem is fixed, is there a way to work around it?
concat the short mp3 file, make the file longer(2s)
:bulb: If the bug is confirmed, would you be willing to create a pull request?

    @synchronized(self) {
        player.delegate = self;
        player.enableRate = YES;
       player.numberOfLoops = -1;//add this, player will loop
        [player prepareToPlay];

Which versions are you using?

React Native Sound:(0.11.0)
React Native:(0.61.0)
iOS:11.3(simulate)

Does the problem occur on...

[ *] Simulator

Test file:
start.mp3.zip

I can confirm this issue: actually the sound loops but some of it is cut off after playing correctly the first time.


Bug: Lost devices in Google Home if matterbridge-home-assistant starts before HA or before HA is fully loaded

First of all, I am not sure if this is a bug or even if it belongs here or to the Matterbridge repository, so sorry if this bug report does not apply.
Description of the problem:
If Matterbridge-Home-Assistant (Docker version) is started before Home Assistant is running (or not fully loaded), it will "unregister" all devices, resulting in no devices being exposed. The problem is, if I am using Matterbridge devices with Google Home automations, these actions lose the link with the device, resulting in a "corrupted" automation. (Sorry for my English.)
Steps to reproduce:

Expose a device (e.g., a switch) using Matterbridge-Home-Assistant.
Link Google Home with Matterbridge-Home-Assistant.
Create a Google Home automation and add a switch turn-on action as the automation action. Until this point, everything works okay.
Stop Home Assistant.
Stop the Matterbridge-Home-Assistant Docker.
Start the Matterbridge-Home-Assistant Docker (before Home Assistant). At this point, Matterbridge-Home-Assistant will expose no devices.
Check the recent Google Home automations. The action parts will be empty.
I know Matterbridge-Home-Assistant is intended to be used with Home Assistant as a device backend, but the problem I describe above may occur anytime if Home Assistant is not up or not ready at the moment Matterbridge-Home-Assistant is started.

That is interesting. I’ll try if it can be reproduced with Alexa as well.
in general all of this makes sense:

matterbridge starts with an empty bridge
Google home detects that the bridge is up again and scans it
Google removes all missing devices
automations loose references
Devices are added again

The difference with Alexa will be that devices are never removed when they disappear on the Bridge. They just get "unavailable".
The solution could be to cache entities in the storage and restore them on boot - before HA is contracted first. Anyway the removal of entities is one thing that wouldn’t  happen then.
I’ll need to figure out how deletions of entities could be detected.

I'm experiencing similar behavior except it is happening on every restart of matterbridge. About 50% of my entities throw "New device added" messages on Google home every time matterbridge restarts, regardless of the started / loaded state of HA. The "new" devices lose their naming and room assignments...if they show up at all. Sometimes they're just gone and I have to restart again to get them back.
The devices that this happens to are consistent (same ones every time) but there's no discernable pattern. All of my entities are from the 'light' domain and most are from the same integration, so its not either of those. The craziest one is that there's one physical device with two independently controllable plugs: one is fine and stable, the other keeps reloading.
Thoughts?

No sooner do I post the above do I discover a distinction:
When I look under my Android phone's Settings > Google > Devices & sharing > Matter devices
Stable devices are listed as: "Matter Devices Light"
Unstable devices are listed as: "Light (Vendor ID: 0000)"

I've added a quick workaround, so that entities are initially loaded before matterbridge starts.
This will not fix the problem, when home assistant is not yet up, or other connectivity issues, but hopefully it will prevent google home from loosing the devices. After rebooting matterbridge.

For the vendorId, i am not sure what happens in Google, Alexa or other controllers, when it changes.

I'm guessing changing VID and/or PID would be breaking for existing setups. Perhaps VID could be exposed as an optional config variable? That would at least enable testing.
Ultimately what would be best is for matterbridge to have a full flight VID from the CSA, though I'm not sure how achievable that is.

I hunted down my issue as being caused by a particular Nest speaker. I blocked it from my network and now everything is stable. That speaker is unique, so I would let the Google/Nest devs worry about that.


UserItem: Remove UserItemRaw hack

Before this, we were co-opting UserItemRaw to represent wildcard mentions @all and @everyone in the people autocomplete, pretending that both of those was somehow a "user item".
Stop doing that, and make a more dedicated UI for these, with some small improvements:
While we're at it, make some improvements:

- Show the Font Awesome bullhorn icon, like the web app.
- Re: the explanatory text, previously "(Notify everyone)":
  - It now says "Notify stream" when composing a stream message, and
    "Notify recipients" when composing a PM, following the web app.
  - It doesn't have parentheses anymore. The web app uses them to
    distinguish the explanatory text from the special string that
    triggers the mention, as in "all (Notify stream)". We already do
    that by putting the explanatory text on a new line, in a smaller
    font.
  - It's now wired up for translation.
- We now show "stream", not just "all" and "everyone", fixing #4325.
- A wildcard mention will now show up if your search term matches
  the translation of it in your chosen language.
- We now use shared code (`typeahead.query_matches_string`)
  for match-modulo-diacritics logic.

Screenshots below.
(edit: description updated to reflect current revision.)
Fixes: #4325

Before/after:

Hm, on have both the icons and the text aligned -- I wonder if we should try aligning the text here as well, even though it'll leave some extra space?

Yeah, I agree. Can we try shrinking the user avatars down to the size of the icons?

Sure, seems like a fine direction to try -- thanks!

Thanks for the reviews! Revision pushed. Here's the "after" photo for this revision, and I expect main still likes the "before" photo in https://github.com/zulip/zulip-mobile/pull/5508#issuecomment-1259300482.

OK, and now I've pushed a fix for the emoji data issue you pointed out. Thanks; this is ready for review. 🙂

I've taken the following screenshots at this point, since I don't expect them to be affected by that fix.

I'm not following the details of the discussion, so sorry if this was already mentioned, but the "all" looks shifted to the left compared to everything else in the "after" screenshot.

I've taken the following screenshots at this point, since I don't expect them to be affected by that fix.

I'm not following the details of the discussion, so sorry if this was already mentioned, but the "all" looks shifted to the left compared to everything else in the "after" screenshot.

Yeah, that part was fixed by #5551. I believe the "after" of this PR, now that #5551 is merged, will look just like it did in the previous revision:
https://github.com/zulip/zulip-mobile/pull/5508#issuecomment-1302629158

(FWIW @chrisbobbe for next time when splitting out part of a PR that's readier for merge, my suggestion would be: move that part to the start of the branch, send it as its own PR, but keep the main PR based on top of that so that the tip of the PR still has all the changes. At least in a case like this one where the split-out changes are needed in order to get the final screenshot to look right, or more generally where the changes in the main PR depend on those in the split-out PR.)

(FWIW @chrisbobbe for next time when splitting out part of a PR that's readier for merge, my suggestion would be: move that part to the start of the branch, send it as its own PR, but keep the main PR based on top of that so that the tip of the PR still has all the changes. At least in a case like this one where the split-out changes are needed in order to get the final screenshot to look right, or more generally where the changes in the main PR depend on those in the split-out PR.)

Sure, in retrospect I think that would've made sense in this case. Although, you did say "break out" the commits as a new PR, in part because they had a "different job from the rest of the branch". 😛

OK, this all looks good! With just one commit-message nit:
shared: Upgrade to 0.0.16

This brings a nice change to the typeahead code: the overabstracted
function query_matches_source_attrs is removed, and
query_matches_string is exported instead:
  https://github.com/zulip/zulip/pull/23375

In zulip/zulip#23412, released in 0.0.16, we corrected the type for
`typeahead.get_emoji_matcher` to reflect that the code assumes a
reaction_type property on emoji objects. So, update our
EmojiForShared type to include that property.

That last paragraph can just be deleted, I think -- it's describing a change that now occurs in the previous commit, and is described there. I guess the latter doesn't mention the specific zulip/zulip PR, so you could move that information there.
I would say I'll just fix that up and merge, but this is a rare occasion when I have urgent work: #5545, where the server side is actively being iterated on right now and we want to get both server and client side merged tonight for tomorrow's Zulip Server 6.0 release. So instead, please merge at will after handling the above comment.

Done, thanks for the review!


Test boot supernova

Still a few things to do:

Clean up command line building in the nonrealtime part of the library
Clean up supriya.scsynth.Options class
Write tests for Options
Check if tests for boot() reboot() and connect() are not broken
Repair broken rendering of documentation (scsynth_path --> executable)

I would also incorporate somehow supriya.scsynth.find() as a public method of Options and hide all the executable path discovery logic from the user and other parts of the library.


module 'tensorflow._api.v1.keras.layers' has no attribute 'Lamdba'

Cannot build my code due to "module 'tensorflow._api.v1.keras.layers' has no attribute 'Lamdba'" heres the code thats related to it:
classifier_layer = layers.Lamdba(classifier_layer, input_shape = IMAGE_SIZE*[3]) classifier_model = tf.keras.Sequential([classifier_layer]) classifier_mode.summary()
Im currently just "Copy pasting" / writing it from the Tensorflow tutorial
(https://www.tensorflow.org/tutorials/images/hub_with_keras) to understand how it works, im very unsure why its not working for me since i used every import they used on the page aswell, looked up if i need to install another package (had to do that some times already) but unfortunally i didnt found anything.

Cannot build my code due to "module 'tensorflow._api.v1.keras.layers' has no attribute 'Lamdba'" heres the code thats related to it:
classifier_layer = layers.Lamdba(classifier_layer, input_shape = IMAGE_SIZE*[3]) classifier_model = tf.keras.Sequential([classifier_layer]) classifier_mode.summary()
Im currently just "Copy pasting" / writing it from the Tensorflow tutorial
(https://www.tensorflow.org/tutorials/images/hub_with_keras) to understand how it works, im very unsure why its not working for me since i used every import they used on the page aswell, looked up if i need to install another package (had to do that some times already) but unfortunally i didnt found anything.

Hi! Can you provide the Version of Tensorflow, OS Version,etc. you are using? It would be nice if you close this issue and open another issue using the issue template, provided.

Hello, sorry for the late reply, im gonna open a new issue.. unfortunally i dont know how to close this one.


Fides pull is not generating system file if not present

Bug Description
When configuring items in the UI and trying to initialize a fresh repo, fides pull is not working as expected.
Steps to Reproduce

Create systems and datasets in UI
Run fides pull
See that systems.yml is not created (note - I happen to have datasets in my repo already, but would see if these get generated too)

Expected behavior
systems.yml gets created (and synchronizes with cloud deployment)
Screenshots

Environment

Version: 2.7.2
OS: OSX Intel
Python Version:
Docker Version:

Additional context
Add any other context about the problem here.

@nicolas-ethyca I think you're missing the -a option

fides pull -a new_objects.yml will also pull missing resources, and put all of them into new_objects.yml in this case


[Docs] Fix rbac links in upgrade guide

Signed-off-by: Maciej Kwiek<EMAIL_ADDRESS>

oh, and it may need to be backported to the doc-1.0 branch as well, since that's what we currently serve

test-me-please

test-me-please

test-docs-please

test-docs-please

test-me-please

Oh, this was the PR! I'm really sorry! I thought i was merges and couldn't find it. I should have looked in the open PRs :/


Confirm if Removal of Guardian Path includes Motion to Appoint Temp Guardian

In the latest feedback we received on 8/19/24, Gordon asked why the Motion to Appoint a Temporary Guardian was necessary if there was already a guardian.
My understanding from our document paths spreadsheet and Dorothy's chart (see image below) was that the Temp Guardian motion did need to be included.

We'll need to circle back with CLA and get confirmation on whether to include the Temp Guardian motion in the Removal of Guardian path.

Confirmed with Dorothy W. that the current setup is correct.


& "$env:RBENV_ROOT\rbenv\bin\rbenv.ps1" init  不能正确执行

哦，我才看到，原链接你这边也下载不了。我这边来排查下。

我这边没啥问题。可能你需要检查下你那边的网络问题，如还是无法工作，请继续反馈。

好吧 我看下，谢谢

用浏览器访问 https://mirror.sjtu.edu.cn/github-release/oneclick/rubyinstaller2/releases/download/RubyInstaller-3.2.0-1/rubyinstaller-devkit-3.2.0-1-x64.exe 这个链接，跳转到其他URL了，是不是这个原因了，我的浏览器能下载

了解了，我再研究下。你先试试不用镜像，看看原来的链接(RubyIntsaller.org那个)你能用 rbenv 下载安装吗？

原来的链接可以，只是需要我访问github，可能有时候会网络连接失败吧

我这边提供两个方案供您解决：

麻烦看下你的 $PSVersionTable 以获得你使用的PowerShell版本。建议您使用 PowerShell core 7.2 以上。因为从开发到现在，308都能正常的处理。通过升级，您的问题应该可以完全得到解决。

不升级PowerShell. 但是在下图这个文件所示位置添加这一行代码，然后重新运行试试看。我所用的PowerShell运行不到这儿来，所以在我的机器上无法判断是否能解决你的问题，抱歉。

[System.Net.HttpStatusCode]::PermanentRedirect  # HTTP 308

Hello @ccmywish and @guojhq,
I'm having the same issue. If there is a solution for this, can you please post it here in English?

Hi @ricardoduarte
First, I want to ask that, do you try to install directly (that is not via mirror)? If so, the issue you meet is same as #8
I don't know if the solution above is useful to @guojhq, but here I can translate the method for you:

I offer two schemes for your reference:

Please look at your $PSVersionTable to get the version of PowerShell you are using. It is recommended that you use PowerShell core 7.2 or higher. Since the development until now, 308 can be processed normally. With the upgrade, your problem should be completely resolved.

Do not upgrade PowerShell. But add this line of code in the file shown below and try running it again. My PowerShell doesn't run here, so I can't tell if I can solve your problem on my machine. Sorry.

[System.Net.HttpStatusCode]::PermanentRedirect  # HTTP 308

@ccmywish Now I noticed what was causing my problem. I copied the Powershell config from the project README and didn't delete the line to use a chinese mirror 🤦♂
Now it is working fine, thanks for your help.

Haha, also good to know it's not a difficult issue for maintenance work 😂

@ccmywish My Powershell version is 5.1

Thanks for your information ❤

I will close this issue. If there are still any questions, please feel free to come back and ask.

@guojhq
I've fixed it now for PowerShell v5.x series. See https://github.com/ccmywish/rbenv-for-windows/issues/18
此问题属于PowerShell v5.x 系列，现已修复，感谢反馈👍 见 https://github.com/ccmywish/rbenv-for-windows/issues/18


Lcom4Test.java:74-77: LCOM4: Graph algorithm to determine...

The puzzle 415-1e78bb53 from #415 has to be resolved:
https://github.com/yegor256/jpeek/blob/aea16e71d663fceee10018c5d97740b15a398c48/src/test/java/org/jpeek/metrics/Lcom4Test.java#L74-L77
The puzzle was created by HDouss on 10-Mar-20.
Estimate: 30 minutes,  role: DEV.
If you have any technical questions, don't ask me, submit new tickets instead. The task will be "done" when the problem is fixed and the text of the puzzle is removed from the source code. Here is more about PDD and about me.

@paulodamaso/z please, pay attention to this issue

The job #431 assigned to @fanifieiev/z, here is why; the budget is 30 minutes, see §4; please, read §8 and §9; if the task is not clear, read this and this; there will be no monetary reward for this job

@0crat wait for #413 and #403


chore(headless): fix prettier config to support windows

KIT-400
https://coveord.atlassian.net/browse/KIT-400

Another option is to just set windows to use LF line endings. You can usually do this in VSCode/whatever IDE you're using and in git itself.


pop up completed, basic layout for css. added images and js code for …

…the pop-up functionality

Few commits behind. Only major changes was the css file and html. Additionally add some functionality within the JS file for the pop-up effect. I will change after merge.


I should be able to see the closing transaction id for channels that are in the process of closing

Detailed Description
When waiting for a channel to close, you want to be able to access at the details of the closing transaction so that you can track it's progress more easily.
Currently we show the funding transaction id, but not the closing transaction id.
Context
Channel UI
Possible Implementation
Show the closing transaction id on the channel detail page for transactions that are in the process of closing.

Closed via https://github.com/LN-Zap/zap-desktop/pull/1695

so what is the solution transaction is in closing but shows no closing transaction just stuck in limbo any way to refresh it ?
channels closing but no on chain payment is made how to resolve this?


[CORE} Fix tslint

Select one ...  (check one with "x")
[X] bug
[ ] feature request
[ ] enhancement

Expected behavior

tslint is not running as expected.
Actual behavior
tslint will run as expected and report errors
Placeholder for the incoming pull request that fixes this.

Along with tslint we also need to fix clang:format. After I run clang:format, the tests take a lot longer to run.


feat: fix vulnerabilities

PR Checklist
Please check if your PR fulfills the following requirements:

[x] The commit message follows our guidelines: https://github.com/datorama/akita/blob/master/CONTRIBUTING.md#commit
[x] Tests for the changes have been added (for bug fixes / features)
[x] Docs have been added / updated (for bug fixes / features)

PR Type
What kind of change does this PR introduce?

[x] Bugfix
[ ] Feature
[ ] Code style update (formatting, local variables)
[ ] Refactoring (no functional changes, no api changes)
[ ] Build related changes
[ ] CI related changes
[ ] Documentation content changes
[ ] Other... Please describe:

What is the current behavior?
Npm report high severity vulnerabilitie
@datorama/akita:7.1.1 > "schematics-utilities": "^2.0.3" ><EMAIL_ADDRESS>(deprecated) > "ini" : 1.3.5
Issue Number: #836
What is the new behavior?
Created an npm called schematics-utilities-fix that stops referencing @schematics/update in schematics-utilities.
Changed schematics-utilities referenced in Akita to schematics-utilities-fix.
Does this PR introduce a breaking change?
[ ] Yes
[x] No

Other information

What is this CLA, it's so hard to contribute.

sign the Salesforce.com Contributor License Agreement

The note by the CLA Bot indicates what needs to be signed: https://cla.salesforce.com/sign-cla?prUrl=https%3A%2F%2Fgithub.com%2Fsalesforce%2Fakita%2Fpull%2F1037

@jimjag
I have reopened PR here, and I also agreed to the CLA, but it says You already signed the CLA on 2022-12-14 and I can't seem to go beyond that.
https://github.com/salesforce/akita/pull/1041


How to add layers to a keras.model Model ?

Hi,
I would like to ad some layers to a Model type but I can't find how to do so.
Another solution would be to convert a Mdel to a Sequential(). Does anyone know how to do one of those things please ?
Thanks !!

I suggest you read the guide to the functional API since it's pretty much all explained there.

I have already read this guide but there is not any answer to my question

Please refer to the functional API guide as previously mentioned. It explains how to use the Model class.


AZ cli python3 virtualenv picks wrong interpreter

Description
I installed az-cli usig the follwing steps
mkdir az-cli-venv
python3 -m venv az-cli-venv
cd /az-cli-venv
source bin/activate
pip install azure-cli

the install is successful.  I'm able to use the if I activate it
but when I try to execute (without activating the venv)
/az-cli/bin/az
it fails with

/usr/bin/python: No module named azure

This is because it picks improper python interpreter

CLI Version: What version of the CLI and modules are installed? (Use az --version)
Answer here:
CLI Version: latest (2.0.9)
OS Version: What OS and version are you using?
Docker image alpine (custom build)
Shell Type: What shell are you using? (e.g. bash, cmd.exe, Bash on Windows)
Answer here: Bash

The az in the environment can only be executed from the environment as it calls the current python interpreter with python -m azure.cli.
Running az-cli-venv/bin/python -m azure.cli works though.
You can also achieve what you were after with something like the following:
echo "az-cli-venv/bin/python -m azure.cli \"\$@\"" > az
chmod +x ./az
./az

@clarkbreyman We do not use entry_points['console_scripts'] because the executable it creates has an import to pkg_resources and importing that package takes several milliseconds.
time python -c 'import pkg_resources'

real	0m0.340s
user	0m0.226s
sys	0m0.088s

@derekbekoe  - looks like https://github.com/pypa/setuptools/issues/510


FromNewComponentOnNewPrefab and FromResolveGetter unexpected behaviour

I'm trying to combo FromNewComponentOnNewPrefab  and FromResolveGetter to do some auto binding but it's not working as I'd expect
            [SerializeField] private GameObject _prefab;
            container.BindInterfacesAndSelfTo<Foo>().FromNewComponentOnNewPrefab(_prefab).AsSingle().NonLazy();

            container.Bind<Transform>()
                .FromResolveGetter<Foo>(p => p.transform)
                .AsSingle();

            container.Bind<Rigidbody>()
                .FromResolveGetter<Foo>(p => p.GetComponentInChildren<Rigidbody>())
                .AsSingle();

            ... etc

Expected result:

Prefab instantiated
Transform and rigidbody bound
1 copy of Foo added to instance

Actual Result:

Prefab instantiated
Transform and rigidbody bound as expected
3 copies of Foo added to instance

Is this a bug or intended behaviour? I'd have thought it should only be a single instance of Foo as it's declared AsSingle()
Alternatively if I do
            var instance = container.InstantiatePrefab(_prefab);
            container.BindInterfacesAndSelfTo<Foo>().FromNewComponentOn(instance).AsSingle();

It works fine

What version of zenject?  Can't reproduce this behaviour on the version I'm using.  Multiple copies of Foo should not be added

5.5.1
It's resolving within a subcontainer if that makes a difference.
I'll see if I can get a working bugged version for you. The above was not my actual code, just stripped back for what I was doing.

Oh ok I reproduced it now with your version.  This is apparently fixed in develop branch

Can't remember which change fixed this.  I'm going to be making an effort to get the new release out over the next couple weeks.  But if you can't wait until then, you can use the develop branch directly

Ok thanks. I'll give it a shot.

Just to confirm. The develop branch fixed the issue.


Selecting Revert Selected Ranges in Github pull request plane seems weird

Extension version:0.42.0
VSCode Version:  1.67.2
OS: m1 mac pro

Seems like clicking 'Revert Selected Ranges' in github pull request plane works unexpectedly.
Steps to Reproduce:

Check out my PR
Go to Github Pull Request plane
Select any file under 'CHANGES IN PULL REQUEST'; a diff view appears.
Drag some changes, right click, select
Unstage Selected Ranges -> no-op. I think it is reasonable since we didn't stage anything. However, when we select
Revert Selected Ranges -> The file is messed up; some changes are duplicated and randomly placed.

At first, I expected Revert Selected Ranges to revert selected changes of the current file to what it looked like before the PR, but it didn't work. Is the behavior intended, or am I missing something?
If that is intended or not designed to use like this, is there a way to easily revert-some-selected-range-from-this-PR while staying on the 'diff' view? As a workaround, I manually git reset each file, revert the ranges that I don't want (in the diff view given by 'Source Control'), and re-stage the file.

The built in git extension contributes the "Revert Selected Ranges" command. A PR diff is not the same as a git diff for this command because the git diff shows a diff between your working state and your branch's head and  the PR diff shows the diff between your working state and the remote branch that the PR is against. "Revert Selected Ranges" probably doesn't do what you want it to do in a PR diff.
We could add a new command in this extension for "Revert Selected Pull Request Ranges", which would update your working state to revert the selected lines to match the "into" branch.


James 2210 Evaluate the performance impact to use commons-io in FileSystemBlobStrategy

As per the description changed the code to use IOUtils::copy.
Did not use IOUtils::closeQuietly as it is deprecated in latest releases, and recommended way is to use the  try-with-resources statement.

Please help closing this PR, as it has been merged with complementary work and as I do not have permissions to do close this myself. Thanks !

Thanks Rene! Closing the PR as it is merged .


Fixing iphone 6p dimensions according to iTunes Connect Developer Guide

Hi,
Haven't had a fresh project to check this on yet, no problem with the two you have added, but how I determine which ones to replace is just looking for all pngs in the project directory, and then adding it to the list with the dimensions of the file - so there would have been a requirement at one point to have those images for some version of Cordova.
When I get a chance I will add the others in "just in case" and leave a comment there to remove them at a future date.
Cheers for spotting it!
Ryan

Oh, apologies that I missed that process. Please disregard this then.
Anyway, just want to say thank you for this amazing project. Gathering up
assets is seriously the most difficult part of a Cordova project in my
opinion.
I look forward to more projects from you. Take it easy.
On Tue, Feb 24, 2015 at 12:32 PM, Ryan Knell<EMAIL_ADDRESS>wrote:

Hi,
Haven't had a fresh project to check this on yet, no problem with the two
you have added, but how I determine which ones to replace is just looking
for all pngs in the project directory, and then adding it to the list with
the dimensions of the file - so there would have been a requirement at one
point to have those images for some version of Cordova.
When I get a chance I will add the others in "just in case" and leave a
comment there to remove them at a future date.
Cheers for spotting it!
Ryan
—
Reply to this email directly or view it on GitHub
https://github.com/rknell/cordova-media-generator/pull/5#issuecomment-75697975
.


Memory Leak in /bpf/deserialization_to_bpf_map/deserialization_to_bpf_map.c

What happened:
Some places called calloc or malloc but not free it.
What you expected to happen:
How to reproduce it (as minimally and precisely as possible):
Anything else we need to know?:
Environment:

Kmesh version:
Others:

cc @nlgwcy


【Vid2Seq】Can Docker environment be provided for Vid2seq GPU training

Encountered issues during installation of the environment and was able to provide Docker images

Hey, the release of a docker image is not planned, and the codebase was designed for TPU training so there may be adaptations to be done to work on GPUs. If that is your goal, you may have a look at the updated PyTorch implementation: https://github.com/antoyang/VidChapters.


Debugger starts always the first debugged test

As nvim-dap repo suggests to use vscode-dap I have switched to vscode-dap. Also I have adjusted jester setup a accordingly. Here is my jester setup.
require'jester'.setup{
  cmd = "NODE_OPTIONS=--experimental-vm-modules node ./node_modules/jest/bin/jest.js -t \"$result\" $file", -- run command
  terminal_cmd = ":ToggleTerm",
  dap = {
    type = 'pwa-node',
    request = 'launch',
    name = 'Jest Debug',
    cwd = "${workspaceFolder}",
    rootPath = "${workspaceFolder}",
    runtimeExecutable = "node",
    runtimeArgs = {
      "./node_modules/jest/bin/jest.js",
      "--runInBand",
      "-t",
      "$result",
      "$file",
    },
    -- args = { "--runTestsByPath", "${relativeFile}" },
    args = { "--no-cache" },
    env = { NODE_OPTIONS = '--experimental-vm-modules' },
    sourceMaps = true,
    skipFiles = { "<node_internals>/**" },
    port=9229,
    console = 'integratedTerminal',
    disableOptimisticBPs = true
  },
}

also I have following mappings
nnoremap <silent> <leader>jr :lua require"jester".run()<CR>
nnoremap <silent> <leader>jd :lua require"jester".debug()<CR>

jester.run() works like expected by jester.debug() executes always the first debugged test. I always need to restart nvim to be able to debug second test.

Hi @MijikHna ,
Could you try to log the output of config in
dap.run(config)

in
lua/jester/init.lua:184

?


Issues with using "in subquery" pattern inside crate's query macro

I'm trying to do a fairly simple lookup using a cross-reference table. This is with sqlite.
let rows = sqlx::query!(
            r#"
                select
                    *
                from
                    role
                where
                    id in
                    (
                        select
                            role_id
                        from
                            UserRole
                        where
                            user_id = ?
                    )
            "#
        )
        .bind( param )
        .fetch_all( pool );

However, not matter what I do I keep getting error: expected 1 parameters, got 0
34 |           let rows = sqlx::query!(
   |  ____________________^
35 | |             r#"
36 | |                 select
37 | |                     *
...  |
50 | |             "#
51 | |         )
   | |_________^

At surface-level it looks like sqlx doesn't bind variables to placeholders inside subqueries.

.bind() is for use with the query functions, the macros instead expect the bind parameters as extra arguments: query!("SELECT ...", param1, param2)

Well, shoot, ID-10-T error, there. My b, thank you.
Guess I should alias the macro to avoid confusion.


run a group of code output an error

python 3.6.5
spyder 3.2.8
mxnet-cu92mkl 20180626
code:
from mxnet import nd
w = nd.arange(4).reshape((1,1,2,2))
b = nd.array([1])
data = nd.arange(9).reshape((1,1,3,3))
out = nd.Convolution(data, w, b, kernel=w.shape[2:], num_filter=w.shape[1])
after the last line of code input then error comes:
启动内核时出现了一个错误
Segmentation fault: 11
Stack trace returned 10 entries:
[bt] (0) /usr/lib/python3.6/site‑packages/mxnet/libmxnet.so(+0x32016a) [0x7fe62664616a]
[bt] (1) /usr/lib/python3.6/site‑packages/mxnet/libmxnet.so(+0x2db3686) [0x7fe6290d9686]
[bt] (2) /usr/lib/libc.so.6(+0x368f0) [0x7fe69a3848f0]
[bt] (3) /usr/lib/python3.6/site‑packages/mxnet/libmxnet.so(+0x29719f4) [0x7fe628c979f4]
[bt] (4) /usr/lib/python3.6/site‑packages/mxnet/libmxnet.so(+0x353c39) [0x7fe626679c39]
[bt] (5) /usr/lib/python3.6/site‑packages/mxnet/libmxnet.so(+0x36a6bb) [0x7fe6266906bb]
[bt] (6) /usr/lib/python3.6/site‑packages/mxnet/libmxnet.so(+0x5bb1da) [0x7fe6268e11da]
[bt] (7) /usr/lib/python3.6/site‑packages/mxnet/libmxnet.so(+0x281c8a9) [0x7fe628b428a9]
[bt] (8) /usr/lib/python3.6/site‑packages/mxnet/libmxnet.so(+0x278b579) [0x7fe628ab1579]
[bt] (9) /usr/lib/python3.6/site‑packages/mxnet/libmxnet.so(+0x2794d74) [0x7fe628abad74]
what's the problem?

what's the problem?

We really don't know but this problem is clearly unrelated to Spyder and related to the mxnet library, so please report it to its authors.


Added Getting Started guide for TFLite

Some initial doc changes for a Getting Started guide. The goal is to prioritize "Getting Started" for users and include
end to end examples, with explanations for what each stage does.

LGTM with one section to clean up a little. I'd appreciate if someone else could also read through the new getting started steps for tflite to make sure they can follow them too :)

I was thinking @julianwa would be a good choice

I think something got lost in all the comments:
INFO     -  The following pages exist in the docs directory, but are not included in the "nav"
            configuration:
              - getting-started\tflite-cmd.md
              - getting-started\tflite-python.md

I had suggested merging those pages into a single getting-started/tflite.md. Is keeping them separate but not listed them in the nav intentional?


fix: use RS256 to sign JWT token

Fix: https://github.com/casdoor/casdoor-nodejs-sdk/issues/7

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

@fabian4 plz fix:

@hsluoyz fix done


“tags“ attribute can't use it？

{{#foreach tags}}
{{name}}{{post_count}}
{{/foreach}}
The above code is not valid

Hi @960339491, sorry to hear you're having trouble. Please head on over to slack - https://ghost.org/slack/ - and post information about what you are trying to do and what doesn't work in the #themes channel. There you can get help & support from the Ghost community, which we're not able to do here in the GitHub bug tracker.


Does flate2-rs support ZIP files?

Just wondering if flate2-rs can be used to deflate ZIP files. I'm hoping to be able to process ZIP files similar to the following:
https://github.com/rubytogether/kirby/blob/main/src/file.rs
use flate2::read::GzDecoder;
use std::error::Error;
use std::ffi::OsStr;
use std::fs::File;
use std::io::BufRead;
use std::io::BufReader;
use std::path::Path;

pub fn reader(filename: &str, opts: &super::Options) -> Box<BufRead> {
  if opts.verbose {
    println!("Opening log file {}", filename);
  }

  let path = Path::new(filename);
  let file = match File::open(&path) {
    Err(why) => panic!("couldn't open {}: {}", path.display(), why.description()),
    Ok(file) => file,
  };

  if path.extension() == Some(OsStr::new("gz")) {
    Box::new(BufReader::with_capacity(128 * 1024, GzDecoder::new(file)))
  } else {
    Box::new(BufReader::with_capacity(128 * 1024, file))
  }
}

Thanks!

This library does not support ZIP files, no, you'll need to use a different crate for that. AFAIK those use deflate compression but they're otherwise also very tar-like and would be a pretty big feature to support here (hence the separate crate)


FIX: add genomad to conda recipe

Closing as obsolete in light of https://github.com/bokulich-lab/q2-viromics/pull/21.


Should we use Trello or Slack for discussion?

We discussed on 7/15/2016 and decided to use issue tracking in Github for now.


.NET November 2023 Update - .NET 7.0.14, .NET 6.0.25

.NET November 2023 Update
Today, we are releasing an update to our October 10 security releases. The .NET 7.0.14 and .NET 6.0.25 releases contain the security fixes from our previous September release that were missing in the October release.
Release Notes

7.0.14
6.0.25

Status

Asset Type
7.0.14
6.0.25
Notes

Installers/Binaries
✅
✅

Container Images(Linux)
✅
✅

Container Images(Windows)
✅
✅

Winget Packages
✅
✅

Snaps
✅
✅

Linux Packages (Microsoft distribution)

The list below refers to the Microsoft-provisioned feeds (packages.microsoft.com) and does not in any way represent direct availability in distros (eg RHEL, Fedora).

     Centos 7
✅
✅

     Centos 8
✅
✅

     Debian 10
✅
✅

     Debian 11
✅
✅

     Debian 12
✅
✅

     Fedora 37
✅
✅

     Fedora 38
✅
✅

     Fedora 39
✅
✅

     OpenSUSE 15
✅
✅

      Ubuntu 20.04
✅
✅

     Ubuntu 22.04
✅
✅

     Ubuntu 23.04
✅
✅

Issues
Please report any issues you find either by responding to this issue, creating a new issue or creating a new issue in one of the following repos:

ASP.NET Core: dotnet/aspnetcore
Entity Framework Core: dotnet/efcore
.NET CLI/SDK dotnet/sdk
.NET runtime dotnet/runtime
Winforms: dotnet/winforms
WPF: dotnet/wpf
NuGet: nuget/home
Containers: dotnet/dotnet-docker
Winget: microsoft/winget-pkgs

Known Issues

closing in favor of https://github.com/dotnet/core/issues/9052


Variable Explorer: add an auto-save option

From<EMAIL_ADDRESS>on 2010-09-16T10:49:44Z
during beta-testing, SPyder crashed at times.
Please add an auto save option in order not to loose work
Original issue: http://code.google.com/p/spyderlib/issues/detail?id=369

From pierre.raybaut on 2010-09-22T13:15:10Z
Summary: Variable Explorer: add an auto-save option
Status: Accepted
Labels: -Type-Defect Type-Enhancement Milestone-Release2.0

From pierre.raybaut on 2010-11-01T04:05:11Z
BTW, as I changed very quickly the title of this Issue, could you please confirm that you were referring to a "Variable explorer auto save" feature and not to a "Source code editor auto save" feature.

From pierre.raybaut on 2010-11-01T04:03:56Z
Labels: -Milestone-Release2.0 Milestone-Release2.1

From pierre.raybaut on 2011-05-16T01:11:40Z
Labels: Cat-VariableExplorer

From pierre.raybaut on 2011-06-25T05:36:25Z
Status: WontFix


Unable to configure failover for SOCKS proxy servers

I downloaded, compiled and installed the current branch of code and my log reports I am running 1.1.6. I modified my ts-warp.ini similar to following example. I used an IP address that is currently not in use for the first entry expecting it to attempt to connect, fail and then try the second entry. However, I seem to just continually retry the first entry. Is this failover logic currently implemented or am I misunderstanding the function?
[XX Proxy1]
section_balance = failover
target_host= <IP_ADDRESS>
socks_server =<IP_ADDRESS>:1080
[XX Proxy2]
section_balance = failover
target_host = <IP_ADDRESS>
socks_server = <IP_ADDRESS>:1080

2023.04.07 14:54:49 CRIT [85475]:	TS-Warp-1.1.6 daemon started
2023.04.07 14:54:49 INFO [85475]:	PID file: [/usr/local/var/run/ts-warp.pid], PID: [85475]
2023.04.07 14:54:49 INFO [85475]:	ts-warp address [<IP_ADDRESS>] succesfully resolved to [<IP_ADDRESS>:10800]
2023.04.07 14:54:49 INFO [85475]:	TCP_NODELAY option enabled
2023.04.07 14:54:49 INFO [85475]:	Listening for incoming connections
2023.04.07 14:54:56 INFO [85475]:	Client: [1], IP: <IP_ADDRESS>:54558] accepted
2023.04.07 14:54:56 INFO [85475]:	The client destination address is: [<IP_ADDRESS>:443]
2023.04.07 14:54:56 INFO [85475]:	Clients list. Added PID: [85481], Section: [XX Proxy1]
2023.04.07 14:54:56 INFO [85475]:	Client: [2], IP: [<IP_ADDRESS>:54559] accepted
2023.04.07 14:54:56 INFO [85481]:	Connecting the SOCKS server: [<IP_ADDRESS>:1080]
2023.04.07 14:54:56 INFO [85475]:	The client destination address is: [<IP_ADDRESS>:443]
2023.04.07 14:54:56 INFO [85475]:	Clients list. Added PID: [85482], Section: [XX Proxy1]
2023.04.07 14:54:56 INFO [85482]:	Connecting the SOCKS server: [<IP_ADDRESS>:1080]
2023.04.07 14:56:11 CRIT [85481]:	Unable to connect with destination address
2023.04.07 14:56:11 WARN [85481]:	Unable to connect with SOCKS server: [<IP_ADDRESS>:1080]
2023.04.07 14:56:11 CRIT [85482]:	Unable to connect with destination address
2023.04.07 14:56:11 WARN [85482]:	Unable to connect with SOCKS server: [<IP_ADDRESS>:1080]

Hello @mattreba, the function is implemented and should work, and you seem correctly understand the logic it works.
The issue, you experience, may be related to the parallel way the connections with the target are established. I suppose, this is a web-browser, which opens two simultaneous connections (Client: [1] and Client: [2]) with the target. Both connections are directed via <IP_ADDRESS>:1080, because [XX Proxy1] is listed first in the config. After the Client: [1] detects the connection is failed: 2023.04.07 14:56:11 CRIT [85481]: Unable to connect with destination address, ts-warp sends [XX Proxy1]to the end of the list, allowing[XX Proxy2]to be connected first next time it's used. Unfortunately,Client: [2]has already been using the all same[XX Proxy1]`.
Good news, all the new connections, should use [XX Proxy2] until you restart ts-warp daemon. In your case, "refresh" button in the web-browser should solve the issue. Let me know if this info helped you.

I did repeatedly refresh but never saw the second proxy used. I will generate verbose logs covering a longer test period with multiple refreshes and attach

Confirming the issue and researching. Thank you for finding it.

I was able to get this to function eventually but it took longer than I expected. I had opened multiple Chrome tabs to the target host and also opened a Safari tab and each timed out. Then about 90 seconds later I saw Chrome had auto-refreshed successfully in the background. Sanitized config and verbose log attached.
Archive.zip

Well, it works exactly as you found out.
Let's see if I can make failover faster, so I'll keep the issue open at least for a while.

@mattreba, ok. I did something to speed it up. Could you check please?
Previously, it worked like this:

On the 1-st unsuccessful connection ts-warp detects failed connection
On the 2-nd unsuccessful connection the daemon moves the "failed" section to the end of the list, yet still tries using it for the current connection.
On the 3-rd attempt, use another section.

Now, the 2) excluded. i.e. detecting and rearranging config sections are done withing the first step.
So now everything should work faster. Changes are committed.

I added complexity on this round of testing with a total of 3 SOCKS servers in failover for the same target host:
Server A: Geo 1 - Primary (Down)
Server B: Geo 1 - Secondary (Down)
Server C: Geo 2 - Primary (Up)
15:47:27 Client [1] accepted, Add PID SOCKS server A
15:47:58 Client [2] accepted, Add PID SOCKS server A
15:48:25 Client [3] accepted, Add PID SOCKS server A
15:48:28 Client [4] accepted, Add PID SOCKS server A
15:48:42 First 'Unable to connect' with SOCKS server A
15:48:49 Client [4] Accepted, Add PID SOCKS server B
15:49:00 Client [5] Accepted, Add PID SOCKS server B
15:49:19 Client [5] Accepted, Add PID SOCKS server B
15:49:30 Client [6] Accepted, Add PID SOCKS server B
15:49:54 Client [5] Accepted, Add PID SOCKS server B
15:50:04 First 'Unable to connect' with SOCKS server B
15:50:54 Client [2] Accepted, Add PID SOCKS server C
15:50:54 Client [3] Accepted, Add PID SOCKS server C
15:50:55 Client [2] Accepted, Add PID SOCKS server C
15:50:55 Client [3] Accepted, Add PID SOCKS server C
15:50:56 Client [4] Accepted, Add PID SOCKS server C
15:50:56 Client [4] Accepted, Add PID SOCKS server C
15:50:56 Client [5] Accepted, Add PID SOCKS server C
15:50:57 Client [6] Accepted, Add PID SOCKS server C
15:50:57 Client [7] Accepted, Add PID SOCKS server C
Once successful it catches on quick but it takes some time before we get to the working solution.


Add simple non-HTML5 fallback, preferable without any JavaScript

Something like a a simple list with links to the videos.
Doesn't have to be pretty but better than nothing when something breaks.

Implemented in ac537c684f85cec2faa76c38b8eb40a1eb1fc988


[Android] Understanding Different Types of Menus in Android with Kotlin

[Android] Understanding Different Types of Menus in Android with Kotlin.
Proposed article introduction
In Android applications, menus are essential building blocks. In this tutorial, you will learn how to design and show menus in your Android apps.
Why do we need menus:

To free up screen space
To perform different operations
Navigating to other part of the application

We'll look at three different types of menus:

Options menu
Contextual menu
Popup menu

Key takeaways

You'll learn about the different types of menus.
How to create  menus
You'll learn how to build advanced menus like checkable menus and intent-based menus.
Design guidelines and best practices for Menus

Conclusion
After completing this tutorial, you'll have the skills and understanding of Android menus necessary to create efficient and user-friendly menus in your Android apps.

Good afternoon and thank you for submitting your article for publishing.
Your article has been entered into our queue and should be reviewed (and published pending any changes) as soon as a peer reviewer is finished with the ones in the queue before it. 🚀
Thank you.

Pinging our resident expert on Kotlin @LinusMuema
For some added insight. 🚀

hello @LinusMuema and @hectorkambow
I understand there is an official documentation on menus and to avoid the duplication of the same,  adding custom approach to the tutorial so as to prevent the conflict would be appropriate. In the tutorial:

i will explain on how to integrate different menus to work together in a fully production application.
when people create menus they are often confused or not sure of what menu to use in different part of the application ,so in the article I'll clarify and eliminate this confusion.
Also it would be appropriate to clarify the guidelines and best practices when it come to designing menus.


[BUG] password produced on screen when adding user

In raising this issue, I confirm the following:

[x] I have read and understood the contributors guide.
[x] The issue I am reporting can be replicated.
[x] The issue I am reporting can be is directly related to the pivpn installer script.
[x] The issue I am reporting isn't a duplicate (see FAQs, closed issues, and open issues).

Describe the bug
When adding a user with pivpn (pivpn -a) and specifying a password, that password is then displayed in plain text on the user screen. I believe this is not appropriate for security.
To Reproduce
Steps to reproduce the behavior:

Add a pivpn user the regular way, and specify a password.  ($ pivpn -a)

Expected behavior
When pivpn produces an output, I would expect the password to not be produced on the user's screen
Desktop (please complete the following information):

VPN Protocol
OS: raspbian
Version 1.9

Thanks, will have a look.

Actually, even the latest version does the same thing.  I think it's easy_rsa that is the problem, or maybe pivpn interacting with easy_rsa in the wrong way or something like that. Why would easy_rsa show you the password on screen? I don't know.

When easyrsa creates a client cert/key with a password that password is read from screen by openssl.  That password is not displayed on-screen.

I think this is an issue with expect feeding easyrsa with passwords.

Ya - definitely happening right here:
(in makeOVPN.sh)
expect "Enter PEM pass phrase" { send -- "${PASSWD}\r" }
expect "Verifying - Enter PEM pass phrase" { send -- "${PASSWD}\r" }

@lucserre Password is not shown for me, however I recall an expect script which did leak the text and solved adding a sleep before sending the text. Does it work for you?
expect "Enter PEM pass phrase" { sleep 0.1; send -- "${PASSWD}\r" }
expect "Verifying - Enter PEM pass phrase" { sleep 0.1; send -- "${PASSWD}\r" }

@orazioedoardo  Success!  That did work.
What it looks like now for me.
Using SSL: openssl OpenSSL 1.1.0l  10 Sep 2019
Generating an EC private key
writing new private key to '/etc/openvpn/easy-rsa/pki/private/test2.key.r2eahiToya'
Enter PEM pass phrase:
Verifying - Enter PEM pass phrase:
-----

Reproduced. Screenshot below. Sorry, its so large. However, when adding:
expect "Enter PEM pass phrase" { sleep 0.1; send -- "${PASSWD}\r" }
expect "Verifying - Enter PEM pass phrase" { sleep 0.1; send -- "${PASSWD}\r" }

It does not display.
VPN Protocol
OS: raspbian
Version 1.9

@jerrythiesen It looks like that sreenshot shows that the passwords are being displayed in plain text on the screen, but you pasted code with the sleep 0.1 command included.  Can you confirm if your screenshot was taken with the original code or the sleep command added version of the code?

@jerrythiesen So, does the sleep hide the password or not?

@orazioedoardo - Passing sleep hides the password. Confirmed last night.


Build Exception for Flutter 3.22.3-stable

../../../../.pub-cache/hosted/pub.dev/flexi_chip-1.0.8/lib/src/event.dart:67:7: Error: The superclass, 'WidgetEventController', has no unnamed constructor that takes no arguments.
class FlexiChipEventController extends WidgetEventController {}
      ^
../../../../.pub-cache/hosted/pub.dev/flexi_chip-1.0.8/lib/src/widget.dart:727:25: Error: Too many positional arguments: 1 allowed, but 2 found.
Try removing the extra positional arguments.
      updateWidgetEvents(oldWidget.eventsController, widget.eventsController);

Flutter doctor:
❯ flutter doctor -v
[✓] Flutter (Channel stable, 3.22.3, on macOS 14.6 23G80 darwin-arm64, locale en-IT)
  • Flutter version 3.22.3 on channel stable at /Users/lukas/.local/share/mise/installs/flutter/3.22.3-stable
  • Upstream repository https://github.com/flutter/flutter.git
  • Framework revision b0850beeb2 (2 weeks ago), 2024-07-16 21:43:41 -0700
  • Engine revision 235db911ba
  • Dart version 3.4.4
  • DevTools version 2.34.3

[✓] Android toolchain - develop for Android devices (Android SDK version 35.0.0)
  • Android SDK at /Users/lukas/Library/Android/sdk
  • Platform android-35, build-tools 35.0.0
  • Java binary at: /Users/lukas/Applications/Android Studio.app/Contents/jbr/Contents/Home/bin/java
  • Java version OpenJDK Runtime Environment (build 17.0.11+0-17.0.11b1207.24-11852314)
  • All Android licenses accepted.

[✓] Xcode - develop for iOS and macOS (Xcode 15.4)
  • Xcode at /Applications/Xcode.app/Contents/Developer
  • Build 15F31d
  • CocoaPods version 1.15.2

[✓] Chrome - develop for the web
  • Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome

[✓] Android Studio (version 2024.1)
  • Android Studio at /Users/lukas/Applications/Android Studio.app/Contents
  • Flutter plugin can be installed from:
    🔨 https://plugins.jetbrains.com/plugin/9212-flutter
  • Dart plugin can be installed from:
    🔨 https://plugins.jetbrains.com/plugin/6351-dart
  • Java version OpenJDK Runtime Environment (build 17.0.11+0-17.0.11b1207.24-11852314)

[✓] IntelliJ IDEA Ultimate Edition (version 2024.1.4)
  • IntelliJ at /Users/lukas/Applications/IntelliJ IDEA Ultimate.app
  • Flutter plugin can be installed from:
    🔨 https://plugins.jetbrains.com/plugin/9212-flutter
  • Dart plugin can be installed from:
    🔨 https://plugins.jetbrains.com/plugin/6351-dart

[✓] VS Code (version 1.88.1)
  • VS Code at /Applications/Visual Studio Code.app/Contents
  • Flutter extension version 3.92.0

[✓] Connected device (4 available)
  • sdk gphone64 arm64 (mobile)     • emulator-5554         • android-arm64  • Android 14 (API 34) (emulator)
  • macOS (desktop)                 • macos                 • darwin-arm64   • macOS 14.6 23G80 darwin-arm64
  • Mac Designed for iPad (desktop) • mac-designed-for-ipad • darwin         • macOS 14.6 23G80 darwin-arm64
  • Chrome (web)                    • chrome                • web-javascript • Google Chrome 127.0.6533.74

[✓] Network resources
  • All expected network resources are available.

I've been experiencing the same issue since this morning

@Giovanni-Fantin In the meantime you can use https://api.flutter.dev/flutter/material/ChoiceChip-class.html

I think the problem is in this package:  widget_event 1.10.1 (was 1.9.0), that had an upgrade this morning

Hi, sorry for the inconvenience. There was an issue with widget_event v1.10.* which should have been a breaking change to v2. I've reverted the code to v1.9.0 and released it as v1.11.0. Please run flutter packages upgrade to resolve the error.
If you're using the chips_choice package, consider switching to choice package for significant improvements.


Missing Zod types lead to an unrecoverable error

See https://github.com/matejchalk/zod2md/blob/5f7216693e9ab097f09e32046060513ded3484cc/src/converter/convert-schemas.ts#L244
The problem with this is that in case there is an unsupported Zod Type, the entire documentation generation fails.
Locally, I use the following instead to mitigate this:
console.warn(
    `WARN: Zod type ${
      'typeName' in schema._def ? schema._def.typeName : '<unknown>'
    } is not supported. Returning NEVER`
  );

  return {
    type: 'never',
  };

What do you think?

Makes sense to me :+1:


feat: update golang-github-jcmturner-aescts.v2 to 2.0.0

AES CBC Ciphertext Stealing mode for Go
Issue: https://github.com/deepin-community/sig-deepin-sysdev-team/issues/552
Log: update repo

/lgtm
/approve


Expose project via hook

In the past the react instance had to be used to access helper functions like zoomIn, fitView and project.
export type OnLoadParams<T = any> = {
  zoomIn: () => void;
  zoomOut: () => void;
  zoomTo: (zoomLevel: number) => void;
  fitView: FitViewFunc;
  project: ProjectFunc;
  getElements: () => Elements<T>;
  setTransform: (transform: FlowTransform) => void;
  toObject: ToObjectFunc<T>;
};

https://github.com/andys8/react-flow/blob/b408e6434dc0ddf92cbca4ed63b94ed3519b807e/src/types/index.ts#L252-L261
Now there is useZoomHelper which looks compelling.
I noticed zoomIn, fitView and similar functions are exposed, but project isn't one of them.
const initialZoomPanHelper: ZoomPanHelperFunctions = {
  zoomIn: () => {},
  zoomOut: () => {},
  zoomTo: (_: number) => {},
  transform: (_: FlowTransform) => {},
  fitView: (_: FitViewParams = { padding: DEFAULT_PADDING, includeHiddenNodes: false }) => {},
  setCenter: (_: number, __: number) => {},
  fitBounds: (_: Rect) => {},
  initialized: false,
};

https://github.com/andys8/react-flow/blob/b408e6434dc0ddf92cbca4ed63b94ed3519b807e/src/hooks/useZoomPanHelper.ts#L11-L20
Feature Request
Could project be added to this or a new hook to be exposed the same way?
The advantage would be, that it's not necessary to access the react flow instance anymore.

That's a good idea! I will add it in v9.0.0. If you have more ideas/ needs for certain hooks let us know.
Btw if you are running a project with react-flow, could you try to install react-flow-renderer@next to test if everything works as expected? Would be helpful for us :)

The hook is now available when you install react-flow-renderer@next

released in v9.0.0


Upgrade third party cookie library used in express to fix vulnerability

Hi,
Kindly upgrade the cookie library used in package.json to latest to fix "Large integers in the Max-Age of a cookie cause a panic" vulnerability.
This is reported in NATIONAL VULNERABILITY DATABASE: https://nvd.nist.gov/vuln/detail/CVE-2017-18589
This vulnerability is caught by anchor engine running in container images

If your security software is alerting on the CVE, you need to report that to your vendor as an error. That CVE is for a Rust library, and this is a JavaScript/Node.js library.


Alternative to monkey patching PaymentMethod.available

I wanted to throw this out as an alternative way to do https://github.com/solidusio/solidus_multi_domain/pull/13.  This is what I was trying to describe in earlier comments.
Upsides:

Doesn't modify code that isn't ours
When called, it's more apparent what's happening and where the code is coming from
More straightforwardly compatible with other extensions.  i.e. multiple extensions could have something like this and we wouldn't have to come up with a method signature that could support anything (e.g. an options={} hash in the method signature)
Any code that called the old form can just as easily call the new form
Should be more re-usable -- in more places than just PaymentMethod.available

Downsides:

Less convenient (more verbose to type)

Thoughts?  Other downsides or upsides that I'm missing?

@gmacdougall gave me an even better alternative I'm going to take a look at in just a bit.

I'm still not too keen that this is overriding available_payment_methods in the order model. Can we pull this all into Solidus?

This was the rough draft of @gmacdougall's idea: https://gist.github.com/gmacdougall/130e601e9ad14ada21ec which I think could be a great solution (if we can find a good out backwards-compatibility strategy) and it removes even the monkey patch of Order.  I think that'd be a nice pattern to have in general, though in this case I wouldn't complain if someone managed to merge multidomain into Solidus before I implemented Gregor's suggestion. :)

so to be clear I wasn't suggesting pulling all of multi-domain into solidus quite yet, just that specific method

@athal7 that sounds like a great idea. I didn't realize that Solidus had gotten a Spree::Store model.
@gmacdougall's idea still seems like a great way to open this method up for extensions in general but in this case it seems like it would be great to just move the functionality into Solidus itself.


RC0 ionic emulate ios -lc not working

with RC0 the command:
ionic emulate ios -lc
doesn't appear to work for me (the app hangs on loading screen)
ionic emulate ios works ok but appears not to with the -lc flags added

https://forum.ionicframework.com/t/rc0-livereload-android-not-working/65045/10

Hello, thanks for opening an issue with us! I am going to close this issue as a duplicate of https://github.com/driftyco/ionic-cli/issues/1436. Thanks!


Not making comments

The bot isnt making comments, it only applies "Taking a deeper dive" and "Safe to merge"
i know for a fact that my code is abysmal.
https://github.com/Vital-Utilities/Vital-Utilities/pull/119

Hey @Snazzie thanks for your feedback!
Is it abysmal because of the type annotation warnings? Or because of what else?
Also, right now we're only detecting console logs and their equivalents in other languages (I saw that in your PR we're incorrectly detecting lines of the yml file as console logs) . This is the PR just in case you want to take a look and give us some feedback https://github.com/watermelontools/watermelon/pull/413 What else would you like us to detect? Leftover comments? PII Data? Something else?
Finally regarding the pre-review label. Do you mean our labeling criteria should be more strict? (More PRs getting "Don't Merge" and "Take a deeper dive" instead of "Safe to Merge"?)

I'm here to +1…
So far watermelon run in several PRs of mine, in Ruby and Swift codebases, and it never commented on actual lines of code, just some summaries that are not very useful so far 😬
Examples:

https://github.com/rogerluan/arkana/pull/53#issuecomment-1863565242
https://github.com/rogerluan/arkana/pull/54#issuecomment-1852847495

Any clue why is that? My theory was because it doesn't yet support Ruby or Swift, but I can't really tell, since it's not clear anywhere what are the languages it officially supports 😅 so that's another feedback to you guys 🙇
After reading the comment above "we're only detecting console logs", does this mean it will only comment whether it has console logs or not? 🤔 couldn't this be done using Danger? There's no AI in that 😅

Hey @rogerluan, thanks for your input!
Just to clarify, our current focus is on pinpointing console logs within codebases. However, we're actively working on expanding our capabilities to include PII data detection.
Is there anything else you'd like us to keep an eye out for? Are you thinking about things like leftover comments, or perhaps detecting comments that don’t really add value (redundant)? Any other suggestions? We're all ears!
As for the summary, it's primarily designed for companies rather than individual projects. It's especially handy when your code context is spread across platforms like Slack, Jira, Notion, etc. Do you have any thoughts on how we could tailor it to be more beneficial for open-source projects?

Do you have any thoughts on how we could tailor it to be more beneficial for open-source projects?

tbh a summary wouldn't be useful as an after-thought (i.e. in the form of a comment posted by a bot in the PR after it is open). Instead, if the bot could write a draft for the PR description while the author is still in the process of opening the PR (e.g. a browser extension?), then this would be super valuable and save developers' time.

Is there anything else you'd like us to keep an eye out for?

My tip is for you to aim solving problems that can only be solved by LLM, if you're really working with an LLM. All examples listed (detecting - and kinda interpreting - console logs, accidental PII, leftover comments) can be more or less be identified/fixed using procedural programming, thus not requiring LLM. Of course, the results with LLM can be slightly better, but it's probably not an edge.
My suggestion here is for you to seek making the bot's review as good as a human's. There are lots of static code review services out there that do somewhat advanced analysis e.g. cyclomatic complexity, common code smells, etc, so if you want to stand out, you'd have to offer what those can't offer without an LLM. Things that require context, interpretation, viewing the bigger picture, etc. I can't pinpoint specific examples, but hopefully these will spark ideas for you (maybe with the help of GPT 😜)