[mini.files] opening file from mini.files throw treesitter errors

Contributing guidelines

[X] I have read CONTRIBUTING.md
[X] I have read CODE_OF_CONDUCT.md
[x] I have updated 'mini.nvim' to latest version

Module(s)
mini.files
Description
Hi.
Recently I have encountered some treesitter issues, like this, which maybe is not related to the issue that I am posting here, another one that clearly relate to mini.files and lazy's lazy loading is this one:
Error detected while processing CursorMoved Autocommands for "*":
Unable to load context query for python:
/usr/local/share/nvim/runtime/lua/vim/treesitter/query.lua:273: query: invalid structure at position 513 for language python

reproduce environment
run nvim --version:
NVIM v0.10.0-dev-695+g58f948614
Build type: Release
LuaJIT 2.1.0-beta3
Run "nvim -V1 -v" for more info

run :echo nvim_get_runtime_file('*/python.so', v:true) in neovim:
['/private/tmp/.repo/plugins/nvim-treesitter/parser/python.so', '/usr/local/lib/nvim/parser/python.so']

run checkhealth treesitter give OK results.
Details

 Nvim runtime ABI version: 14
- OK Parser: python     ABI: 14, path: /private/tmp/.repro/plugins/nvim-treesitter/parser/python.so
- OK Parser: bash       ABI: 14, path: /usr/local/lib/nvim/parser/bash.so
- OK Parser: c          ABI: 13, path: /usr/local/lib/nvim/parser/c.so
- OK Parser: lua        ABI: 14, path: /usr/local/lib/nvim/parser/lua.so
- OK Parser: markdown   ABI: 14, path: /usr/local/lib/nvim/parser/markdown.so
- OK Parser: markdown_inline ABI: 14, path: /usr/local/lib/nvim/parser/markdown_inline.so
- OK Parser: python     ABI: 14, path: /usr/local/lib/nvim/parser/python.so
- OK Parser: query      ABI: 14, path: /usr/local/lib/nvim/parser/query.so
- OK Parser: vim        ABI: 14, path: /usr/local/lib/nvim/parser/vim.so
- OK Parser: vimdoc     ABI: 14, path: /usr/local/lib/nvim/parser/vimdoc.so

Neovim version
v0.10.0 nightly
Steps to reproduce
minimal init.lua file managed by lazy, put it at /tmp/init.lua:
vim.g.mapleader = ' '

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 = {
  { 'nvim-lua/plenary.nvim' },
  { 'stevearc/dressing.nvim', opts = {} },
  {
    "echasnovski/mini.files",
    lazy = true,
    keys = {
      {
        "-",
        function()
          local path = nil
          path = vim.api.nvim_buf_get_name(0)
          require("mini.files").open(path, true)
        end,
        desc = "Open mini.files (directory of current file)",
      },

    },
    enabled = true,
    opts = {
      windows = {
        preview = true,
        width_nofocus = 30,
        width_preview = 60,
      },
      options = {
        -- Whether to use for editing directories
        -- Disabled by default in LazyVim because neo-tree is used for that
        use_as_default_explorer = true,
      },
      mappings = {
        go_in_plus = '<CR>',
      }
    },
  },
  {
    --- some issues
    --- https://github.com/nvim-treesitter/nvim-treesitter/issues/3970#issuecomment-1353836834
    --- https://github.com/nvim-treesitter/nvim-treesitter/issues/2014#issuecomment-970342040
    --- `:echo nvim_get_runtime_file('*/python.so', v:true)`
    'nvim-treesitter/nvim-treesitter',
    build = function()
      if #vim.api.nvim_list_uis() == 0 then
        -- update sync if running headless
        vim.cmd.TSUpdateSync()
      else
        -- otherwise update async
        vim.cmd.TSUpdate()
      end
    end,
    lazy = true,
    event = { 'BufReadPost', 'BufNewFile' },
    -- event = 'VeryLazy',
    keys = {
      -- { "<Enter>",    desc = "Init Increment selection" },
      -- { "<Enter>",    desc = "node node incremental selection",      mode = "x" },
      { "<BS>",       desc = "Decrement selection",                  mode = "x" },
      { '<leader>cr', desc = 'Smart rename/nvim-treesitter-refactor' },
    },
    dependencies = {
    },
    init = function()
      vim.opt.smartindent = false
    end,
    config = function()
      require('nvim-treesitter.install').prefer_git = true
      require('nvim-treesitter.configs').setup({
        -- parser_install_dir = parser_install_dir,
        ensure_installed = { 'python' }, -- one of "all", or a list of languages
        sync_install = true,             -- install languages synchronously (only applied to `ensure_installed`)
        auto_install = true,
        ignore_install = {},             -- list of parsers to ignore installing
      })
    end,
  },
  {
    "nvim-treesitter/nvim-treesitter-context",
    event = "BufReadPre",
    lazy = true,
    enabled = true,
    opts = {
      max_lines = 3,
      mode = "cursor",
      min_window_height = 5,
    },
    keys = {
      {
        '[c', '<cmd>lua require("treesitter-context").go_to_context()<cr>', desc = 'Treesitter Context: Go to context'
      }
    },
    config = function(_, opts)
      require('treesitter-context').setup(opts)
      vim.cmd([[hi TreesitterContextBottom gui=underline guisp=Grey]])
    end
  },
  -- add any other pugins here
}

require('lazy').setup({
  spec = plugins,
  root = root .. '/plugins',
  defaults = {
    lazy = false,
  },
  state = root .. '/lazy/state.json',
  performance = {
    cache = {
      enabled = false,
    }
  }
})

-- add anything else here
vim.opt.termguicolors = true
vim.cmd([[colorscheme default]])

a demo python file name it as demo.py or something else and put it together with init.lua file at /tmp/demo.py:
#!/usr/bin/env python3

import os
import os.path
import sys
import subprocess
import signal

# author: https://github.com/olimorris/dotfiles/blob/main/commands/color_mode.py

kitty_path = os.path.expandvars("$HOME/.config/kitty")
# starship_path = "~/.config/starship"
tmux_path = "~"
nvim_path = "~/.config/nvim"

# If we toggle dark mode via Alfred, we end up in a infinite loop. The dark-mode
# binary changes the MacOS mode which in turn causes color-mode-notify to run
# this script. This script then calls dark-mode (via the app_macos method)
# which kick starts this loop all over again. We use this boolean var
# to detect when we've run the command via the cmdline or alfred.
ran_from_cmd_line = False

# The order in which apps are changed
apps = [
  "neovim",
  "kitty",
  # "tmux",
  #"starship",
  # tmux must come after neovim.
  #"fish",
]

def app_macos(mode):
    """
    Change the macOS environment
    """
    path_to_file = "~/.color_mode"

    # Open the color_mode file
    with open(os.path.expanduser(path_to_file), "r") as config_file:
      contents = config_file.read()

    # Change the mode to ensure on a fresh startup, the color is remembered
    if mode == "dark":
        contents = contents.replace("light", "dark")
        if ran_from_cmd_line:
            subprocess.run(["dark-mode", "on"])

    if mode == "light":
        contents = contents.replace("dark", "light")
        if ran_from_cmd_line:
            subprocess.run(["dark-mode", "off"])

    with open(os.path.expanduser(path_to_file), "w") as config_file:
        config_file.write(contents)

def app_kitty(mode):
    """
    Change the Kitty terminal
    """
    kitty_file = kitty_path + "/theme_env.conf"
    kitty_theme_json = kitty_path + "/theme.json"

    dark_theme = ""
    light_theme = ""

    import json
    try:
        with open(kitty_theme_json, 'r') as j:
            theme_dict = json.loads(j.read())
            dark_theme = theme_dict["dark"]
            light_theme = theme_dict["light"]
    except Exception as e:
        print(e)
        return

    # Begin changing the modes
    if mode == "dark":
        contents = "include ./colors/{}".format(dark_theme)

    if mode == "light":
        contents = "include ./colors/{}".format(light_theme)

    with open(os.path.expanduser(kitty_file), "w") as config_file:
        config_file.write(contents)

    # Reload the Kitty config
    # Note: For Kitty 0.23.1, this breaks it
    try:
        pids = subprocess.run(["pgrep", "kitty"], stdout=subprocess.PIPE)
        pids = pids.stdout.splitlines()
        for pid in pids:
            try:
                subprocess.run(["kill", "-SIGUSR1", pid])
            except:
                continue
    except IndexError:
        pass

def app_starship(mode):
    """
    Change the prompt in the terminal
    """
    if mode == "dark":
        return subprocess.run(
            [
                "cp",
                os.path.expanduser(starship_path + "/starship_dark.toml"),
                os.path.expanduser(starship_path + "/starship.toml"),
            ]
        )

    if mode == "light":
        return subprocess.run(
            [
                "cp",
                os.path.expanduser(starship_path + "/starship_light.toml"),
                os.path.expanduser(starship_path + "/starship.toml"),
            ]
        )

def app_tmux(mode):
    subprocess.run(
        [
            "/usr/local/bin/tmux",
            "source-file",
            os.path.expanduser(tmux_path + "/.tmux.conf"),
        ]
    )
    # return os.system("exec zsh")

def app_neovim(mode):
    """
    Change the Neovim color scheme
    """
    print("start process nvim")
    from pynvim import attach

    nvim_config = nvim_path + "/lua/settings_env.lua"
    if not os.path.isfile(os.path.expanduser(nvim_config)):
      with open(os.path.expanduser(nvim_config), 'w') as fp:
        pass

    nvim_contents = 'vim.opt.background = "{mode}"'.format(mode=mode)
    nvim_contents = nvim_contents.strip()

    with open(os.path.expanduser(nvim_config), "w") as config_file:
        config_file.write(nvim_contents)

    # Now begin changing our open Neovim instances

    # Get the neovim servers using neovim-remote
    print("start nvr call")
    servers = subprocess.run(["nvr", "--serverlist"], stdout=subprocess.PIPE)
    servers = servers.stdout.splitlines()

    # Loop through them and change the theme by calling our custom Lua code
    print("start loop nvim servers")
    for server in servers:
        try:
            print("attaching to nvim")
            nvim = attach("socket", path=server)
            print("calling command")
            nvim.command("call v:lua.Ty.ToggleTheme('" + mode + "')")
            print("finish call")
        except Exception as e:
            print(e)
            continue
    return

def app_fish(mode):
    return subprocess.run(["/opt/homebrew/bin/fish"])

def run_apps(mode=None):
    """
    Based on the apps in our list, sequentially run and trigger them
    """
    if mode == None:
        mode = get_mode()

        # sucks https://github.com/neovim/pynvim/issues/231
    def handler(signum, frame):
        raise Exception("end of time")
    signal.signal(signal.SIGALRM, handler)

    # must exit after 3s
    signal.alarm(5)
    for app in apps:
        try:
            getattr(sys.modules[__name__], "app_%s" % app)(mode)
        except Exception as e:
            continue
    return

def get_mode():
    """
    Determine what mode macOS is currently in
    """
    mode = os.environ.get("DARKMODE", 1)
    if mode == 1 or mode == "1":
        return "dark"
    else:
        return "light"

if __name__ == "__main__":
    # If we've passed a specific mode then activate it
    try:
        print("start py1")
        if sys.argv[1]:
            ran_from_cmd_line = True
        run_apps(sys.argv[1])
    except IndexError:
        print("start py2")
        try:
            run_apps()
        except Exception as e:
            print(e)

Steps to repro with lazy

run nvim -u init.lua, wait for lazy to be installed and plugin is all set (including treesitter downloading the python parser etc). then quit.
run nvim -u init.lua.
press - to open the mini.files.
move cursor to demo.py and press enter key to open it.
move your cursor.
The error message shown.

Steps without lazy
If I change the config for treesitter.nvim with  event = { 'VeryLazy' }, the behavior of mini.files is normal.
I am not sure this issue should be resolved by mini.files or lazy plugin. I have checked the LazyVim config for mini.files and treesitter, all is almost same.

Modify the init.lua, change treesitter config with event = { 'VeryLazy' }.
reopen nvim with nvim -u init.lua.
press - to open mini.files.
move cursor to demo.py and press enter key to open it.
everything is working.

Note: If direct open the file with nvim -u init.lua demo.py, it also works (no interact with mini.files).
The working context plugin demo:

Expected behavior
opening file from mini.files should not affect other plugins.
Actual behavior
affect nvim-treesitter-context, make it not working in some case.

Thanks for the issue!

run nvim -u init.lua, wait for lazy to be installed and plugin is all set (including treesitter downloading the python parser etc). then quit.

run nvim -u init.lua.

press - to open the mini.files.

move cursor to demo.py and press enter key to open it.

move your cursor.

The error message shown.

Based on the facts, that 1) the error is shown after 'mini.files' has already opened the file; 2) there is a workaround; 3) I can not reproduce this; I'd suggest this is an issue with 'nvim-treesitter-context', as everything 'mini.files' does is calls :edit <filepath> to open previously not opened file.
Please, feel free to post any follow up if you can create a more minimal reproducible example.

Also reproducible on my personal macbook.
NVIM v0.10.0-dev-698+g02d859a07
Build type: Release
LuaJIT 2.1.0-beta3
Run "nvim -V1 -v" for more info

@echasnovski oil.nvim doesn't have such issue.
init.lua with oil.nvim:
vim.g.mapleader = ' '

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 = {
  { 'nvim-lua/plenary.nvim' },
  { 'stevearc/dressing.nvim', opts = {} },
  {
    'stevearc/oil.nvim',
    opts = {
      default_file_explorer = true,
      keymaps = {
        ["g?"] = "actions.show_help",
        ["<CR>"] = "actions.select",
        ["<C-v>"] = "actions.select_vsplit",
        ["<C-x>"] = "actions.select_split",
        ["<C-t>"] = "actions.select_tab",
        ["<C-p>"] = "actions.preview",
        ["<C-c>"] = "actions.close",
        ["<C-r>"] = "actions.refresh",
        ["y"] = "actions.copy_entry_path",
        ["-"] = "actions.parent",
        ["`"] = "actions.cd",
        ["~"] = "actions.tcd",
        ["g."] = "actions.toggle_hidden",
      },
      use_default_keymaps = false,
      float = {
        padding = 3,
        border = 'single',
        win_options = {
          winblend = 0,
        }
      }
    },
    keys = {
      {
        '-',
        function()
          require('oil').open()
        end,
        desc = 'Open oil file browser(buf)',
      },
    },
  },
  {
    --- some issues
    --- https://github.com/nvim-treesitter/nvim-treesitter/issues/3970#issuecomment-1353836834
    --- https://github.com/nvim-treesitter/nvim-treesitter/issues/2014#issuecomment-970342040
    --- `:echo nvim_get_runtime_file('*/python.so', v:true)`
    'nvim-treesitter/nvim-treesitter',
    build = function()
      if #vim.api.nvim_list_uis() == 0 then
        -- update sync if running headless
        vim.cmd.TSUpdateSync()
      else
        -- otherwise update async
        vim.cmd.TSUpdate()
      end
    end,
    lazy = true,
    event = { 'BufReadPost', 'BufNewFile' },
    -- event = 'VeryLazy',
    keys = {
      -- { "<Enter>",    desc = "Init Increment selection" },
      -- { "<Enter>",    desc = "node node incremental selection",      mode = "x" },
      { "<BS>", desc = "Decrement selection", mode = "x" },
      { '<leader>cr', desc = 'Smart rename/nvim-treesitter-refactor' },
    },
    dependencies = {
    },
    init = function()
      vim.opt.smartindent = false
    end,
    config = function()
      require('nvim-treesitter.install').prefer_git = true
      require('nvim-treesitter.configs').setup({
        -- parser_install_dir = parser_install_dir,
        ensure_installed = { 'python' }, -- one of "all", or a list of languages
        sync_install = true, -- install languages synchronously (only applied to `ensure_installed`)
        auto_install = true,
        ignore_install = {}, -- list of parsers to ignore installing
      })
    end,
  },
  {
    "nvim-treesitter/nvim-treesitter-context",
    event = "BufReadPre",
    lazy = true,
    enabled = true,
    opts = {
      max_lines = 3,
      mode = "cursor",
      min_window_height = 5,
    },
    keys = {
      {
        '[c', '<cmd>lua require("treesitter-context").go_to_context()<cr>', desc = 'Treesitter Context: Go to context'
      }
    },
    config = function(_, opts)
      require('treesitter-context').setup(opts)
      vim.cmd([[hi TreesitterContextBottom gui=underline guisp=Grey]])
    end
  },
  -- add any other pugins here
}

require('lazy').setup({
  spec = plugins,
  root = root .. '/plugins',
  defaults = {
    lazy = false,
  },
  state = root .. '/lazy/state.json',
  performance = {
    cache = {
      enabled = false,
    }
  }
})

-- add anything else here
vim.opt.termguicolors = true
vim.cmd([[colorscheme default]])

I still can not reproduce with the instructions from OP:

run nvim -u init.lua, wait for lazy to be installed and plugin is all set (including treesitter downloading the python parser etc). then quit.

run nvim -u init.lua.

press - to open the mini.files.

move cursor to demo.py and press enter key to open it.

move your cursor.

The error message shown.

I use latest available nightly (NVIM v0.10.0-dev-741+g996dd36c7).
What I would suggest in this situation:

Make sure that all parsers are up to date (run :TSUpdate all).
Use the approach that works for you, i.e. "If I change the config for treesitter.nvim with  event = { 'VeryLazy' }, the behavior of mini.files is normal."

Just add some more information about this issue, clearly this sort of thing should not be managed by mini.files plugin, otherwise plugin author would concern too much. I don't want to use 'VeryLazy' because that kind of making the plugin lazy loading useless.
don't know where to report this kind issue, want to report it at folke's lazy repo, but he is on vacation until end of August.

I added some logs to runtime/vim/treesitter/query.lua (M.get_files) here are the inspection results.
debug code at query.lua:
function M.get_files(lang, query_name, is_included)
  local query_path = string.format('queries/%s/%s.scm', lang, query_name)
  vim.print("check folder")
  vim.print(vim.api.nvim_list_runtime_paths())
  local raw_lang_files = api.nvim_get_runtime_file(query_path, true)
  if query_name == 'injections' then
    error("who called me")
    vim.print('M.get_files')
    vim.print(raw_lang_files)
  end
  local lang_files = dedupe_files(raw_lang_files)
  --- ... rest code.

Normal case (no issues)

run vim -u init.lua demo.py, no output, the ts is loaded.
move cursor, autocmd triggered and ts-context plugin is trying to get some ts query.

output is:
check folder
{ "/private/tmp/.repro//config/nvim", "/private/tmp/.repro/plugins/lazy.nvim", "/private/tmp/.repro/plugins/nvim-treesitter-context", "/private/tmp/.repro/plugins/nvim-treesitter", "/private
/tmp/.repro/plugins/dressing.nvim", "/private/tmp/.repro/plugins/plenary.nvim", "/usr/local/share/nvim/runtime", "/usr/local/share/nvim/runtime/pack/dist/opt/matchit", "/usr/local/lib/nvim",
 "/private/tmp/.repro/state/nvim/lazy/readme" }
M.get_files
{ "/private/tmp/.repro/plugins/nvim-treesitter/queries/python/injections.scm" }
lang: python query_name: injections
{ "/private/tmp/.repro/plugins/nvim-treesitter/queries/python/injections.scm" }
check folder
{ "/private/tmp/.repro//config/nvim", "/private/tmp/.repro/plugins/lazy.nvim", "/private/tmp/.repro/plugins/nvim-treesitter-context", "/private/tmp/.repro/plugins/nvim-treesitter", "/private
/tmp/.repro/plugins/dressing.nvim", "/private/tmp/.repro/plugins/plenary.nvim", "/usr/local/share/nvim/runtime", "/usr/local/share/nvim/runtime/pack/dist/opt/matchit", "/usr/local/lib/nvim",
 "/private/tmp/.repro/state/nvim/lazy/readme" }
lang: python query_name: highlights
{ "/private/tmp/.repro/plugins/nvim-treesitter/queries/python/highlights.scm" }

We can see in the preceding output, all plugin is available in the runtimepath, and importantly, the python/injections.scm is found.
Bad case

run vim -u init.lua.
press - to open mini.files and open the demo.py.

After file is opened, immediately output is following:
check folder
{ "/private/tmp/.repro//config/nvim", "/private/tmp/.repro/plugins/lazy.nvim", "/private/tmp/.repro/plugins/mini.files", "/private/tmp/.repro/plugins/dressing.nvim", "/private/tmp/.repro/plu
gins/plenary.nvim", "/usr/local/share/nvim/runtime", "/usr/local/share/nvim/runtime/pack/dist/opt/matchit", "/usr/local/lib/nvim", "/private/tmp/.repro/state/nvim/lazy/readme" }
M.get_files
{}
lang: python query_name: injections
{}
check folder
{ "/private/tmp/.repro//config/nvim", "/private/tmp/.repro/plugins/lazy.nvim", "/private/tmp/.repro/plugins/mini.files", "/private/tmp/.repro/plugins/dressing.nvim", "/private/tmp/.repro/plu
gins/plenary.nvim", "/usr/local/share/nvim/runtime", "/usr/local/share/nvim/runtime/pack/dist/opt/matchit", "/usr/local/lib/nvim", "/private/tmp/.repro/state/nvim/lazy/readme" }
lang: python query_name: highlights
{ "/usr/local/share/nvim/runtime/queries/python/highlights.scm" }
check folder

We can see, the nvim-treesitter is not in the runtimepath. this is not relate to nvim-treesitter-context plugin because it is not loaded or used.

move the cursor, the nvim-treesitter-context try to get the context query, output is following:

check folder
{ "/private/tmp/.repro//config/nvim", "/private/tmp/.repro/plugins/lazy.nvim", "/private/tmp/.repro/plugins/nvim-treesitter-context", "/private/tmp/.repro/plugins/nvim-treesitter", "/private
/tmp/.repro/plugins/mini.files", "/private/tmp/.repro/plugins/dressing.nvim", "/private/tmp/.repro/plugins/plenary.nvim", "/usr/local/share/nvim/runtime", "/usr/local/share/nvim/runtime/pack
/dist/opt/matchit", "/usr/local/lib/nvim", "/private/tmp/.repro/state/nvim/lazy/readme" }
lang: python query_name: context
{ "/private/tmp/.repro/plugins/nvim-treesitter-context/queries/python/context.scm" }
Error detected while processing CursorMoved Autocommands for "*":
Unable to load context query for python:
/usr/local/share/nvim/runtime/lua/vim/treesitter/query.lua:282: query: invalid structure at position 513 for language python

In this case, I guess it is because the injections.scm is not loaded by treesitter, I don't know why because I am not familiar with treesitter and what the injections does.

Just add a traceback debug(print(debug.traceback())), the reason mini.files triggered this issue is because:
:mess
check folder
{ "/private/tmp/.repro//config/nvim", "/private/tmp/.repro/plugins/lazy.nvim", "/private/tmp/.repro/plugins/mini.files", "/private/tmp/.repro/plugins/plenary.nvim", "/private/tmp/.repro/plug
ins/dressing.nvim", "/usr/local/share/nvim/runtime", "/usr/local/share/nvim/runtime/pack/dist/opt/matchit", "/usr/local/lib/nvim", "/private/tmp/.repro/state/nvim/lazy/readme" }
stack traceback:
^I/usr/local/share/nvim/runtime/lua/vim/treesitter/query.lua:78: in function 'get_files'
^I/usr/local/share/nvim/runtime/lua/vim/treesitter/query.lua:233: in function 'get'
^I...l/share/nvim/runtime/lua/vim/treesitter/languagetree.lua:121: in function 'new'
^I/usr/local/share/nvim/runtime/lua/vim/treesitter.lua:64: in function '_create_parser'
^I/usr/local/share/nvim/runtime/lua/vim/treesitter.lua:130: in function 'get_parser'
^I/usr/local/share/nvim/runtime/lua/vim/treesitter.lua:457: in function </usr/local/share/nvim/runtime/lua/vim/treesitter.lua:455>
^I[C]: in function 'pcall'
^I/private/tmp/.repro/plugins/mini.files/lua/mini/files.lua:1948: in function 'update_fun'
^I/private/tmp/.repro/plugins/mini.files/lua/mini/files.lua:1872: in function 'buffer_update'
^I/private/tmp/.repro/plugins/mini.files/lua/mini/files.lua:1666: in function 'view_ensure_proper'
^I/private/tmp/.repro/plugins/mini.files/lua/mini/files.lua:1445: in function 'explorer_refresh_depth_window'
^I/private/tmp/.repro/plugins/mini.files/lua/mini/files.lua:1253: in function 'explorer_refresh'
^I/private/tmp/.repro/plugins/mini.files/lua/mini/files.lua:1741: in function ''
^Ivim/_editor.lua: in function <vim/_editor.lua:0>
M.get_files
{}
lang: python query_name: injections
{}
check folder
{ "/private/tmp/.repro//config/nvim", "/private/tmp/.repro/plugins/lazy.nvim", "/private/tmp/.repro/plugins/mini.files", "/private/tmp/.repro/plugins/plenary.nvim", "/private/tmp/.repro/plug
ins/dressing.nvim", "/usr/local/share/nvim/runtime", "/usr/local/share/nvim/runtime/pack/dist/opt/matchit", "/usr/local/lib/nvim", "/private/tmp/.repro/state/nvim/lazy/readme" }
lang: python query_name: highlights
{ "/usr/local/share/nvim/runtime/queries/python/highlights.scm" }
check folder
{ "/private/tmp/.repro//config/nvim", "/private/tmp/.repro/plugins/lazy.nvim", "/private/tmp/.repro/plugins/nvim-treesitter-context", "/private/tmp/.repro/plugins/nvim-treesitter", "/private
/tmp/.repro/plugins/mini.files", "/private/tmp/.repro/plugins/plenary.nvim", "/private/tmp/.repro/plugins/dressing.nvim", "/usr/local/share/nvim/runtime", "/usr/local/share/nvim/runtime/pack
/dist/opt/matchit", "/usr/local/lib/nvim", "/private/tmp/.repro/state/nvim/lazy/readme" }
lang: python query_name: context
{ "/private/tmp/.repro/plugins/nvim-treesitter-context/queries/python/context.scm" }
Error detected while processing CursorMoved Autocommands for "*":
Unable to load context query for python:
/usr/local/share/nvim/runtime/lua/vim/treesitter/query.lua:284: query: invalid structure at position 513 for language python

Found out my /usr/local/share/nvim is linked to brew's /usr/local/Cellar/neovim/HEAD-f660b79/share/nvim, but my nvim bin is build from source, and run nvim -v output v0.10.0-dev-695+g58f948614, will cleanup the mess and try again.

The root cause is found, clean up the different neovim build files solved this treesitter issues.


How do you actually get the contents of a file?

Hi, I'm trying to integrate this into my Meteor/React app, but I'm not quite sure on how to actually get the contents of a file. I used the same example as presented in the Readme, except I defined an absolute storagePath.
import { Meteor }          from 'meteor/meteor';
import { FilesCollection } from 'meteor/ostrio:files';

const Images = new FilesCollection({
  debug: true,
  collectionName: 'Images',
  storagePath: "/home/XXX/XXX/testDir"
});

// To have sample image in DB we will upload it on server startup:
if (Meteor.isServer) {
  Images.denyClient();
  Images.collection.attachSchema(Images.schema);

  Meteor.startup(function () {
    if (!Images.find().count()) {
      Images.load('https://raw.githubusercontent.com/VeliovGroup/Meteor-Files/master/logo.png', {
        fileName: 'logo.png',
        meta: {}
      });
    }
  });

  Meteor.publish('files.images.all', function () {
    return Images.find().cursor;
  });
} else {
  Meteor.subscribe('files.images.all');
}

export default Images;

On my client in React, I import Images but how am I supposed to get the actual file contents? I want to display the image but I can't use the path stored in the Images collection because Meteor parses the path through the public/ folder.

Similarly, if this is a text file or any other file, how do I get the contents of the file? Say if I want to get the contents of a text file and display it in a React component, how should this be done?

I couldn't find any instance in the documentation which illustrates how this should be done specifically.
I'm trying to be able to console.log the data first before actually using it in my component. I tried to use link() but I don't think this is the correct way of doing it as it throws some errors:
const Component = () => {
    useEffect(() => {
        console.log(Images.link())
    }, [])
    return

}

Appreciate any help, thanks.

@ajaypillay you're looking for .link() method. Let me know if it helped you

I tried the following:
const Component = () => {
    useEffect(() => {
        const fileRef = Images.collection.findOne({})
        console.log(Images.link(fileRef))
    }, [])
    return

}

But I get this Uncaught errorClass:
errorType: "Match.Error"
message: "Match error: Expected object, got undefined"
path: ""
sanitizedError: errorClass
details: undefined
error: 400
errorType: "Meteor.Error"
isClientSafe: true
message: "Match failed [400]"
reason: "Match failed"
stack: "Error: Match failed [400]\n    at errorClass.<anonymous> (http://XXX.XXX.XX.XX:3000/packages/check.js?hash=75ac

Nevermind, I got it working. I was doing this in React when in actuality it needs to be done on the server side. I'm running a Meteor/Apollo/React stack and I made a simple Graphql resolver to fetch the links, and it all works now because it's being done on the server-side.
Thank you!

@ajaypillay I'm glad this issue was solved quickly. Are you using Meteor methods in your solution?
There's also a way to publish/subscribe it as any other Meteor collection and those functions would work on a Client. But to be honest methods work better than pub/sub, and I prefer methods to pub/sub on "normal" meteor Collections
Please support this project with:

Become a sponsor on GitHub and GitHub would double your every contribution during next 6 months only!;
Support via PayPal;
Star this package on GitHub;
Like at Facebook;
Follow on Twitter;
Check and star our other open source projects on GitHub.

@dr-dimitru
I'm not using any Meteor methods actually, as Apollo/Graphql gives an interface to handle all operations with the database. I defined a Graphql query schema in Files.graphql:
extend type Query {
    getFiles: String
}

And I have a separate file for the actual FileCollection, in files.jsx:
import { FilesCollection } from 'meteor/ostrio:files'
const Files = new FilesCollection({
    debug: true,
    collectionName: 'Files',
    storagePath: "/XXX/XXX/XXX/directory"
})
export default Files

And in resolvers.jsx I have:
import Files from "./files";
export default {
    Query: {
        getFiles(obj, args, context) {
            return Files.collection.findOne({}).link(fileRef, 'original, 'http://XXX.XXX.XX.XX:3000/')
        }
    }
}

And then in my React component I just query the database for the needed data.
import React from "react"
import { gql, useQuery } from '@apollo/client'

const Component = () => {
    const {data, loading, error} = useQuery(gql`
        query getFiles {
            getFiles: getFiles
        }
    `)
    if (loading) return

    if (error) console.log(error)
    console.log(data) // Data will contain the URL string returned by the query
    return (

    )
}

And then I can use data in my component. I've found working with Apollo/Graphql very convenient, and I've abstracted away all the database logic to Apollo. The only thing I'm really using Meteor for right now explicitly is for the accounts package, and other nice things like hot-reloading.

@ajaypillay good Graphql use case, thank you for sharing in details


Sidebar layout issue.

Bug report
Title
Sidebar layout issue.
Issue Description
Sidebar layout issue.
Preconditions
1. framework Version.-1.1.0

Expected result
Layout should be proper
Actual result

fixed


detect resolution change

hi dylan,
as written or irc earlier, it would be nice to have a mechanism to detect any resolution change to keep sowm safe and working as expected while manipulating windows (fs, move center...)
thanks in advance o/

I've added this mechanism. It uses X.h's ConfigureNotify event to watch for resolution change of root window that I mapped to the display. I've tested it - looks like it works.

Why not use the primitive multimonitor patch? You can check res changes via xrandr.


[ISSUE #5147] Fix ClassNotFoundException

Make sure set the target branch to develop
What is the purpose of the change
Close #5147
Brief changelog
XX
Verifying this change
XXXX
Follow this checklist to help us incorporate your contribution quickly and easily. Notice, it would be helpful if you could finish the following 5 checklist(the last one is not necessary)before request the community to review your PR.

[x] Make sure there is a Github issue filed for the change (usually before you start working on it). Trivial changes like typos do not require a Github issue. Your pull request should address just this issue, without pulling in other changes - one PR resolves one issue.
[x] Format the pull request title like [ISSUE #123] Fix UnknownException when host config not exist. Each commit in the pull request should have a meaningful subject line and body.
[x] Write a pull request description that is detailed enough to understand what the pull request does, how, and why.
[x] Write necessary unit-test(over 80% coverage) to verify your logic correction, more mock a little better when cross module dependency exist. If the new feature or significant change is committed, please remember to add integration-test in test module.
[x] Run mvn -B clean apache-rat:check findbugs:findbugs checkstyle:checkstyle to make sure basic checks pass. Run mvn clean install -DskipITs to make sure unit-test pass. Run mvn clean test-compile failsafe:integration-test  to make sure integration-test pass.
[ ] If this contribution is large, please file an Apache Individual Contributor License Agreement.

The opentracing should not be explicitly introduced in maven, otherwise, it may cause version conflict. Instead, you should introduce it in your own project.

The opentracing should not be explicitly introduced in maven, otherwise, it may cause version conflict. Instead, you should introduce it in your own project.

agree with

Actually OpenTracing is archived, you can see more details from here, we may remove the dependency of OpenTracing in the near future.

Hello @caigy ,  @drpmma , @ShadowySpirits , @aaron-ai
thx for your reply, get it
I will manually add opentracing-api to the classpath


[SPARK-16328][ML][MLLIB][PYSPARK] Add 'asML' and 'fromML' conversion methods to PySpark linalg

The move to ml.linalg created asML/fromML utility methods in Scala/Java for converting between representations. These are missing in Python, this PR adds them.
How was this patch tested?
New doctests.

Test build #61544 has started for PR 13997 at commit 35974c9.

cc @jkbradley @mengxr @yanboliang

Test build #61544 has finished for PR 13997 at commit 35974c9.

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

Merged build finished. Test PASSed.

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

LGTM pending nitpicks.

Test build #61556 has started for PR 13997 at commit a180421.

Test build #61556 has finished for PR 13997 at commit a180421.

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

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

Merged build finished. Test PASSed.

Looks good, except for a few minor comments

@jkbradley fair point for the tests - I actually just moved them to tests.py since it's just a copy-paste

Test build #61572 has started for PR 13997 at commit 05ff527.

Test build #61572 has finished for PR 13997 at commit 05ff527.

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

Merged build finished. Test PASSed.

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

Thanks for the updates!  For tests, I'm all for including some doc tests in Python if they provide good examples for the docs.  But developers, myself included, have tended to include too much in doc tests in the past.
LGTM
Merging with master and branch-2.0


add Rev level to Job Ticket Print

Request was submitted to add rev level to the job ticket print utility.

this was released with 6.2.4 patch


DSD-897: Updating Required text in the Label and Fieldset components

Fixes JIRA ticket DSD-897
This PR does the following:

Removes the default "Optional" text that gets displayed by the Label and Fieldset components. This text was displayed all the way on the right side. Now, only the text "(Required)" is displayed inlined with the label or legend text.
The "(Required)" text can be hidden with the showRequiredLabel prop which is now standardized across all components. This use to be optReqFlag and showOptReqLabel in various components.

How has this been tested?
Unit tests and Storybook.
Accessibility concerns or updates

This is a visual update and the required and aria-required attributes in form components have not changed.

Checklist:

[ ] I have updated the Storybook documentation accordingly.
[ ] I have added relevant accessibility documentation for this pull request.
[ ] All new and existing tests passed.

Front End Review:

[ ] View the example in Storybook

Tugboat has finished building the preview for this pull request!
Link:

https://pr942-vg6ckdg5bzmxqexrcc9uo3f8lklhxulb.tugboat.qa

Dashboard:

https://dashboard.tugboat.qa/624f3c287a1d628954508bee

Tugboat has finished building the preview for this pull request!
Link:

https://pr942-vg6ckdg5bzmxqexrcc9uo3f8lklhxulb.tugboat.qa

Dashboard:

https://dashboard.tugboat.qa/624f3c287a1d628954508bee


[FEATURE REQUEST]: Implement Real-Time Search Functionality for FAQs

Is your feature request related to a problem? Please describe.
Currently, there is no search functionality in the FAQ section, making it difficult for users to find specific information quickly. This can lead to frustration and a poor user experience when trying to locate relevant FAQs.
Describe the solution you'd like.
Implement a real-time search feature that allows users to enter keywords in a search bar. The FAQ section should dynamically display the matching FAQs as the user types, providing a more efficient way for users to find answers. This feature should also highlight relevant keywords within the FAQs.
Add any other context or screenshots about the feature request here.
Implementing this feature will significantly enhance user experience by making it easier for users to find specific information quickly without scrolling through multiple FAQs.

@TejasNasre  Please assign this issue to me under gssoc-ext level3 and hactoberfest-accepted, as I am interested in working on it.

not needed add new issue


Add shadcn-registry-template

name: feat: Add shadcn-registry-template
about: Add shadcn-registry-template for building custom component registries
labels: feature

Describe the awesome thing you want to add
What is it?
shadcn 2 and later allow installing components from a custom registry like npx shadcn-ui@latest add https://raw.githubusercontent.com/vantezzen/auto-form/main/registry/auto-form.json. This template allows you to easily create your own registry for your components.
What category does it belong to? (Libs and Components, Apps, Ports, Design System, Boilerplates/Templates)
Libs
Anything else? (optional) (e.g. screenshots, additional information, etc.)
I build this for auto-form but extracted this since its useful for all custom components.
Checklist

[x] I checked that it is in alphabetical order.
[x] I have checked that the awesome thing is not already listed.
[x] I have provided a clear and concise description of the awesome thing.
[x] I have provided a link to the awesome thing.
[x] I have assigned the correct category to the awesome thing.

Please note: If you are adding a new category, you will need to create a new section in the README.md file. Please make sure to update the table of contents as well.
Important: The idea of this repository is to bring together free projects for open-source contributions. If the proposed addition is an entirely paid project, the PR will be closed.

Fixed in https://github.com/birobirobiro/awesome-shadcn-ui/pull/100


Backpack cleanup

Moves the backpack flashing to the "Firmware" menu, as previously suggested.
Also adds colors to "Success", "FAILED" and "Timeout" status values.
Button text returns back to default value when cursor is moved.

Sorry, only got back to my workstation today, had a bit of backlog there. Could we get a rebase on this one?

Sorry, only got back to my workstation today, had a bit of backlog there. Could we get a rebase on this one?

Rebased and tested.


hope to add the fixed column render on the right. Currently, the column can only be fixed on the left

希望在右侧蓝色区域固定列，目前我下载了您的源代码，正在改动相关的事情

hope to add the fixed column render on the right. Currently, the column can only be fixed on the left

This probably wont happen for quite a while.
Obvious api proposal
interface DataEditorProps {
    ...otherCrap,
    freezeColumns: number | [left: number, right: number];
}

Thank you for your reply。Maybe I can improve it。

Thank you for your reply。Maybe I can improve it。

Have you implemented the right fixed function？

I have not seen any such PR come through. It would also be relatively difficult to properly implement while retaining performance. More freeze regions means more rendering passes.

There are a few other konvajs versions I've seen out there, great framework for moving fast. A+ if you can meet your business needs there 👍


Hapi update

I would like to know if there is an update planned in order support Hapi v20.1 ? I would really like to use it my project but there seems to be a compatibility issue.
Thank you for your work !

I'd love to see more typesafe features in Hapi but it mostly relies on Joi. Unfortunately, recently Joi typings had a massive rewrite which makes any kind of modifications much harder.
This is probably something that should be brought up in the official Joi repository.


🎛 Rename AutoFieldController to SubmitController

The current AutoFieldController naming is a but cluncky and in hindsight does not actually reflect what it does.
It would be great to clean this up in the scope of Stimulus Outreachy and rename to w-submit and SubmitController.
Be sure to double check any events that get dispatched (not sure if any).

Discussed on 02/02. The controller doesn’t share enough with ActionController to be combined, but a name change would help to better convey what it does.
w-submit

over to you @Lovelyfin00


Add integration test to Prometheus endpoint

issue #19 created a Prometheus endpoint that exports an up metric, set to one. That issue manually verified the endpoint works.
In this issue, we add an integration test that verifies the Prometheus endpoint.
References:

golang docs on writing tests
A blog post on creating prometheus integration tests. See section named "Using prometheus/client_golang/prometheus/testutil"

Hello! I'd like to take this on if it hasn't been claimed yet

@atimeofday have your started on this? If not I'm working on creating issues with less steep learning curves..

I haven't yet but mostly due to a busy few days of errands and putting together a talk for a Cloud meetup today - taking another crack at this is on my to do list.
The main learning curve issue is that this happens to be a whole new tech stack for me, so some 'plug and play' steps have a bunch of extra context to untangle. Entirely doable and good to learn, but takes a bit more spare time.

All good @atimeofday ! I'm happy to wait for @yonch 's new batch of issues 🙂

@tverghis hope to have it tomorrow noonish. I'm working on specifying Cycles per Instruction collection.
Reason it's taking a bit is I found several packages that might be relevant and want to get the best leverage from existing code..

@yonch Thanks again for the assistance yesterday! I think I have this one done, generalized, commented, and working with the bonus feature of automatically starting up the service to be tested.
I intend to add some notes and resources to the dev log I included in PR #22 to ensure that someone else could follow most of what I did from scratch, then open a new PR with the integration test.
I'll take a shot at #21 when I have time if nobody gets to it first - GitHub Actions is another thing I've been meaning to learn.

Great, awesome work on this! I enjoyed working with you to solve that error! I'll keep an eye out for a PR.


Bump eslint plugin version.

Bumping version of eslint-plugin-lwc-graph-analyzer. This version includes all rules packages in the plugin as default recommended rules and should pick up more lint errors.

@AdamLiechty This PR will fix problem that was observed here.


Joe's Notes

Hi @JoanneBogart , @stuartmcalpine  - thanks so much for making this available.  I thought I'd collect my notes here.

Laptop Installation - I had to use conda to install psycopg2 as installing from source failed with Error: pg_config executable not found. pg_config is required to build psycopg2 from source.
Not clear what "DREGS_CONFIG" should be.
Should probably mention in the docs that this only runs at NERSC for now - I just get a timeout.

On NERSC doing
module load python
conda create -p ./env psycopg2 ipython
conda activate ./env

So far I get:
$ cat ~/.config_reg_reader
sqlalchemy.url: postgresql://reg_writer@data-registry-dev-loadbalancer.jrb-test.development.svc.spin.nersc.org:5432/desc_data_registry

$cat ~/.pgpass
scidb1.nersc.gov:*:des_im3shape:des_admin:XXXXXX
data-registry-dev-loadbalancer.jrbtest.development.svc.spin.nersc.org:5432:desc_data_registry:reg_writer:XXXXXX

(first entry is for another DB I used)
Then running:
import os
from dataregistry.db_basic import SCHEMA_VERSION, create_db_engine, ownertypeenum
from dataregistry.registrar import Registrar

DREGS_CONFIG=os.path.expanduser("~/.config_reg_reader")

# Establish connection to database
engine, dialect = create_db_engine(config_file=DREGS_CONFIG)

registrar = Registrar(
   engine, dialect, ownertypeenum.user, owner="user", schema_version=SCHEMA_VERSION
)

gives:
OperationalError: (psycopg2.OperationalError) connection to server at "data-registry-dev-loadbalancer.jrb-test.development.svc.spin.nersc.org" (<IP_ADDRESS>), port 5432 failed: fe_sendauth: no password supplied

Thank you for taking the time to go through this!
I've updated the docs, for the installation and the example usage. Please have another look when you can, it should clarify these points.
:)

Brilliant, these instructions worked for me now, and I was able to add a file to the system - thanks!
I'll have a play next and look at more detailed usage questions, and open a new issue for that.


MSBuild: Document updating to v15

Visual Studio 2017/MSBuild 15 introduced some changes in how to consume and load the MSBuild API. This new documentation describes the best practice for using MSBuild from a program that isn't Visual Studio.
I've sent this to a couple of customers who thought it was helpful but it's still a bit draft-y.
cc @andygerlicher @Mikejo5000

:white_check_mark: Validation status: passed

File
Status
Preview URL
Details

docs/msbuild/TOC.md
:white_check_mark:Succeeded

docs/msbuild/msbuild-api.md
:white_check_mark:Succeeded

docs/msbuild/updating-an-existing-application.md
:white_check_mark:Succeeded

For more details, please refer to the build report.
Note: If you changed an existing file name or deleted a file, broken links in other files to the deleted or renamed file are listed only in the full build report.

@rainersigwald There's a TODO in the section "Using extension assemblies" that will need content before merging.

@rainersigwald @AndyGerlicher Does this PR need a review by Andy? We need to get rid of the TODO before it can be merged.

:white_check_mark: Validation status: passed

File
Status
Preview URL
Details

docs/msbuild/TOC.md
:white_check_mark:Succeeded

docs/msbuild/msbuild-api.md
:white_check_mark:Succeeded

docs/msbuild/updating-an-existing-application.md
:white_check_mark:Succeeded

For more details, please refer to the build report.
Note: If you changed an existing file name or deleted a file, broken links in other files to the deleted or renamed file are listed only in the full build report.

@Mikejo5000 Sorry, got caught up in other things. I completed the TODO with a brief explanation of that reference mechanism. Andy's on vacation next week so I think we can go live with just you and me for this. Happy to get any feedback you have.

:white_check_mark: Validation status: passed

File
Status
Preview URL
Details

docs/msbuild/TOC.md
:white_check_mark:Succeeded

docs/msbuild/msbuild-api.md
:white_check_mark:Succeeded

docs/msbuild/updating-an-existing-application.md
:white_check_mark:Succeeded

For more details, please refer to the build report.
Note: If you changed an existing file name or deleted a file, broken links in other files to the deleted or renamed file are listed only in the full build report.


PMK Ubuntu pre-reqs should include curl & uuid-runtime

A bare minimum Ubuntu install doesn't appear to have these by default.
We should also update the PMK support docs.

Pull request open to update the support site. Closing this issue.


Android setup launch_image cannot set duration time.

Android setup launch_image cannot set duration time.
Please see the screenshot:

Hi @gionchat
To set custom duration, you can Flutter Splash Screen instead of `launch_background
Please check it out Flutter Splash Screen

This platform is not meant for assistance on personal code. Please see https://flutter.dev/community for resources and asking questions like this, you may also get some help if you post it on Stack Overflow. Closing, as this isn't an issue with Flutter itself,
if you disagree please write in the comments and I will reopen it Thank you


Add support for MPExtended service

Add support for MPExtended service
http://wiki.team-mediaportal.com/1_MEDIAPORTAL_1/17_Extensions/Remote_Access/MPExtended
http://wiki.team-mediaportal.com/1_MEDIAPORTAL_1/17_Extensions/Remote_Access/MPExtended/Developers

This is no longer possible as the developer has restricted access.


Two qestions about the Rust library - metadata and cover art

I am working on a native Rust Spotify binary for GNU/Linux to get more familiar with this language.
I tried to get more metadata of Tracks / Albums than is given in librespot_metadata::Track. librespot_protocol::metadata::Track implements much more functions like get_disc_number(), so there must somehow be a way to get this data via librespot. Since I am new to Rust I was not able to fetch this data yet. Can anyone please give me a hint on how to obtain more metadata about a given librespot_metadata::Track / librespot_metadata::Album (I assume the workflow is similar for tracks / albums / artists)?
My second issue involves fetching a cover art of an album. librespot_metadata::cover has a function get() which returns ChannelData which implements Stream / StreamExt. StreamExt has a function next() which should yield a Result containing either Bytes or a ChannelError (in this implementation) after having being awaited. For some reason I always get a ChannelError, the warning log prints this: ERROR librespot_core::channel] channel error: 2 0. Looking into the source code did not help much, because I am, as I said, pretty new to Rust. My code looks like this:
pub async fn get_album_cover(
  album: &Album,
  session: &Session,
) -> Vec<u8> {
  let mut covers = Vec::new();
  'outer: for file_id in album.covers.iter() {
    info!("{:?}", file_id.0);
    let mut channel = cover::get(session, *file_id);
    let mut cover: Vec<u8> = Vec::new();

    while let Some(result) = channel.next().await {
      match result {
        Ok(data) => {
          info!("Got cover data: {:?}", data);
          data.into_iter().for_each(|byte| {
            cover.push(byte);
          });
        }
        Err(e) => {
          warn!("Error downloading cover: {:?}", e);
          continue 'outer;
        }
      }
    }
    covers.push(cover);
  }

  // -- determine best, return that --
  // [...]

}

Somehow channel.next().await always returns Some(Err(ChannelError)) (eg. the program always goes into the Err(e) part of the match statement). Why is that and how can I fix that?
Thanks in advance for every bit of help. If that is not the right place to ask about the library, where can I ask about it?

You could try on the chat over at Gitter. This isn't really a librespot bug, so I'm closing this issue.
If you use the search, you will find a couple of old issues with channel errors. Usually they have been server errors if my memory serves correctly, or at least protocol errors. Best of luck with your endeavour and while learning Rust, do drop by and contribute to librespot if you can! It's how I learned Rust and look at me now 😆 still learning!

Thanks for the fast answer!
I'll go and ask over at gitter.


[ERROR] Expecting value: line 1 column 1 (char 0)

Hello team, could anyone help me with this error? Or can you tell me why this happens?

To help troubleshoot, please post the output of the following commands:
# see if the server is responding as expected
curl $(jq -r '.couchdb' ~/.bbrf/config.json)/ -u bbrf:$(jq -r .password ~/.bbrf/config.json) | jq

# set debug to True
cat ~/.bbrf/config.json | jq '.debug = true' > ~/.bbrf/config.json

# and rerun the bbrf command that's causing trouble
bbrf new test01


bbu.jed should be named glu.jed

As title states :)

Excellent!  Perhaps a little too hasty copying in the file there, overly optimistic about BBU replicas.  But we're getting really close.


How to add extra to a dependency of a tool?

I installed a tool use requests.
I want to use requests[socks] instead of the default requests package. I have tried the following commands:
uv tool install open-webui --with requests[socks]
uv tool install open-webui --with requests --optional socks
uv tool upgrade open-webui --reinstall-package requests[socks]
....

Finally, could you please confirm whether it's necessary for uv tool to support adding extras to dependencies?

uv tool install open-webui --with 'requests[socks]' should work — did it not?

Sort of related: I installed xonsh using uv, then some plugins (xontribs) using xonsh's own manager, which amounts to installing new packages in the environment. Upon xonsh tool upgrade xonsh, it removed these extra packages. Is there a way to specify a list of packages that should be kept in the environment?


LibWeb: Change where content selection via mouse is allowed

Previously, only DOM nodes with is_editable() allowed selection via the mouse. This had the unwanted consequence, that read-only input/textarea elements did not allow selection.
Now, EventHandler::handle_mousedown() asks the node's non-shadow parent element over the new virtual method is_child_node_selectable(), if selection of the node is allowed.
This method is overridden for HTMLButtonElement and HTMLInputElement, to disallow selection of buttons and placeholders.
Fixes #579
Honestly, this was a difficult one for me and I'm not sure if there might be a better implementation.

Bumping this, there are currently merge conflicts

Superseded by https://github.com/LadybirdBrowser/ladybird/pull/1125


On Fedora, the printer app can't start if /etc/nsswitch is a symbolic link.

When using authselect on Fedora, the file /etc/nsswitch is a symbolic link to /etc/authselect/nsswitch.conf.  When starting the printer app you get this status
× snap.ghostscript-printer-app.ghostscript-printer-app-server.service - Service for snap application ghostscript-printer-app.ghostscript-printer-app-server
     Loaded: loaded (/etc/systemd/system/snap.ghostscript-printer-app.ghostscript-printer-app-server.service; disabled; vendor preset: disabled)
    Drop-In: /etc/systemd/system/snap.ghostscript-printer-app.ghostscript-printer-app-server.service.d
             └─override.conf
     Active: failed (Result: exit-code) since Wed 2021-11-17 07:28:07 CET; 21s ago
    Process: 1368 ExecStart=/usr/bin/snap run ghostscript-printer-app.ghostscript-printer-app-server (code=exited, status=1/FAILURE)
   Main PID: 1368 (code=exited, status=1/FAILURE)
        CPU: 117ms

Nov 17 07:28:07 mybox systemd[1]: snap.ghostscript-printer-app.ghostscript-printer-app-server.service: Scheduled restart job, restart counter is at 5.
Nov 17 07:28:07 mybox systemd[1]: Stopped Service for snap application ghostscript-printer-app.ghostscript-printer-app-server.
Nov 17 07:28:07 mybox systemd[1]: snap.ghostscript-printer-app.ghostscript-printer-app-server.service: Start request repeated too quickly.
Nov 17 07:28:07 mybox systemd[1]: snap.ghostscript-printer-app.ghostscript-printer-app-server.service: Failed with result 'exit-code'.
Nov 17 07:28:07 mybox systemd[1]: Failed to start Service for snap application ghostscript-printer-app.ghostscript-printer-app-server.

After removing the symbolic link and copying the file /etc/authselect/nsswitch.conf to /etc/nsswitch.conf, the printer app can start normally.
--
Villy

I see now that core20/1169/etc/nsswitch.conf now has the mdns4_minimal entry so the nsswitch.conf in the printer apps may no longer be necessary.

@zdohnal @ppywlkiqletw OK, thank you very much for all this info. So I will remove the nsswitch.conf awkwardness from all the Printer Applications at OpenPrinting as it is not needed any more.

If core20/1169/etc/nsswitch.conf is bind-mounted on /etc/nsswitch.conf, there might still be a problem?  A test with the new printer app will show if that is the case.

I am rebuilding now without the layout entry in snapcraft.yaml check whether it works for me (regression test on system without nsswitch.conf symlink) and then upload all OpenPrinting Snaps to the Snap Store, with the awkwardness removed. If this then still not works for you, the problem is not only in the OpenPrinting Snaps but in every Snap using core20 and needing working nsswitch.conf, meaning that it has to be reported to the manitainers of core20 and/or snapd.

I have removed the nsswitch.conf workaround in the Ghostscript Printer Application now (commit 67a1962c) and the Snap Store is rebuilding it. As soon as you get the update, test and tell us whether it solves your problem.

The good news is that the printer application now starts properly.
However, for my usb printer it is unreliable.  Sometimes it works and sometimes not.   I don't know if the errors reported from /usr/libexec/snapd/snap-device-helper could have anything to do with it.  Nor do I have any idea what that program is supposed to do.
-
Nov 18 13:07:08 mybox systemd-udevd[380]: usb2: Process '/usr/libexec/snapd/snap-device-helper add snap_ghostscript-printer-app_ghostscript-printer-app /devices/pci0000:00/0000:00:1d.0/usb2 189:128' failed with exit code 1.
Nov 18 13:07:08 mybox systemd-udevd[374]: usb5: Process '/usr/libexec/snapd/snap-device-helper add snap_ghostscript-printer-app_ghostscript-printer-app /devices/pci0000:00/0000:00:1d.3/usb5 189:512' failed with exit code 1.
Nov 18 13:07:08 mybox systemd-udevd[381]: usb4: Process '/usr/libexec/snapd/snap-device-helper add snap_ghostscript-printer-app_ghostscript-printer-app /devices/pci0000:00/0000:00:1d.2/usb4 189:384' failed with exit code 1.
Nov 18 13:07:08 mybox systemd-udevd[380]: usb2: Process '/usr/libexec/snapd/snap-device-helper add snap_ghostscript-printer-app_ghostscript-printer-app-server /devices/pci0000:00/0000:00:1d.0/usb2 189:128' failed with exit code 1.
Nov 18 13:07:08 mybox systemd-udevd[390]: usb1: Process '/usr/libexec/snapd/snap-device-helper add snap_ghostscript-printer-app_ghostscript-printer-app /devices/pci0000:00/0000:00:1d.7/usb1 189:0' failed with exit code 1.
Nov 18 13:07:08 mybox systemd-udevd[378]: usb3: Process '/usr/libexec/snapd/snap-device-helper add snap_ghostscript-printer-app_ghostscript-printer-app /devices/pci0000:00/0000:00:1d.1/usb3 189:256' failed with exit code 1.

I have tested the new version of the Printer Application Snap now with all 4 options to connect the device (USB, network via SNMP discovery, network via DNS-SD discovery, manually entered the ZeroConf hostname of the printer). All works. This is a regression test as it worked on my system already before, but now we have at least the improvement that the Snap installs and runs its daemon on systems where nsswitch,conf is a symlink.
Have you also tried to set up a network-connected printer using the Ghostscript Printer Application? Have you also tried to connect your Brother printer via network and whether it works this way with the Ghostscript Printer Application?
I simply want to know whether it is at least OK for network printers now. Independent of this it naturally also should work with USB printers.
Please check the following:

Run lsusb repeatedly, does the output always show your printer?
Run sudo /usr/lib/cups/backend/usb repeatedly, does it always show an entry for your printer (with the device ID)? Or run /snap/ghostscript-printer-app/current/usr/lib/ghostscript-printer-app/backend/usb instead, it is also the CUPS backend for USB.
Where did the error messages appear which you are showing in your last message here? In /var/log/syslog? Are there also any messages containing audit or DENIED which are related to USB and your printer?
Is there an ipp-usb process running on your system? If yes, your printer is most probably driverless (IPP printer emulated on localhost:60000) and should appear in CUPS without being set up with a Printer Application. The ipp-usb process is occupying the USB connection of the printer to do its work, you cannot do classic access with a Printer Application in parallel.
Could you run sudo lsusb -vvv > lsusb.txt and post the output here? This can give us more helpful information (like for example whether the printer has a 7/1/4 USB interface which would mean IPP-over-USB).
Please also check whether moving the printer or its cable influences whether your printer is accessible or not (cable/connector defect?).

Also what is the output of
snap connections | grep ghostscript-printer-app

Do you have any other Snaps which are supposed to communicate with USB devices? Do they work correctly for you?

I have tested the new version of the Printer Application Snap now with all 4 options to connect the device (USB, network via SNMP discovery, network via DNS-SD discovery, manually entered the ZeroConf hostname of the printer). All works. This is a regression test as it worked on my system already before, but now we have at least the improvement that the Snap installs and runs its daemon on systems where nsswitch,conf is a symlink.
Have you also tried to set up a network-connected printer using the Ghostscript Printer Application? Have you also tried to connect your Brother printer via network and whether it works this way with the Ghostscript Printer Application?

The printer is USB only.
https://support.brother.com/g/b/spec.aspx?c=us_ot&lang=en&prod=hl2130_all

I simply want to know whether it is at least OK for network printers now. Independent of this it naturally also should work with USB printers.
Please check the following:
1. Run `lsusb` repeatedly, does the output always show your printer?

2. Run `sudo /usr/lib/cups/backend/usb` repeatedly, does it always show an entry for your printer (with the device ID)? Or run `/snap/ghostscript-printer-app/current/usr/lib/ghostscript-printer-app/backend/usb` instead, it is also the CUPS backend for USB.

It never had any problems with current cups, thus sudo /usr/lib/cups/backend/usb as well a lpinfo -v
ghostscript-printer-app devices mostly works.
The record layout it a bit different on Fedora compared to Ubunto.
[root@mybox current]# /var/lib/snapd/snap/ghostscript-printer-app/current/usr/lib/ghostscript-printer-app/backend/usb
DEBUG: Loading USB quirks from "/usr/share/cups/usb".
DEBUG: Loaded 98 quirks.
DEBUG: list_devices
DEBUG: libusb_get_device_list=7
DEBUG2: iSerialNumber="C4N971702"
DEBUG2: Printer found with device ID: MFG:Brother;CMD:PJL,HBP;MDL:HL-2130 series;CLS:PRINTER;CID:Brother Laser Type1; Device URI: usb://Brother/HL-2130%20series?serial=C4N971702
direct usb://Brother/HL-2130%20series?serial=C4N971702 "Brother HL-2130 series" "Brother HL-2130 series" "MFG:Brother;CMD:PJL,HBP;MDL:HL-2130 series;CLS:PRINTER;CID:Brother Laser Type1;" ""
[root@mybox current]#

3. Where did the error messages appear which you are showing in your last message here? In `/var/log/syslog`? Are there also any messages containing `audit` or `DENIED` which are related to USB and your printer?

It is all journal on Fedora.
There used to be SELinux errors, but I run that in permissive mode so that doesn't affect any programs.  The required permissions has now been installed, so no more SELinux errors.
I don't see any other errors.

4. Is there an `ipp-usb` process running on your system? If yes, your printer is most probably driverless (IPP printer emulated on `localhost:60000`) and should appear in CUPS without being set up with a Printer Application. The `ipp-usb` process is occupying the USB connection of the printer to do its work, you cannot do classic access with a Printer Application in parallel.

I am pretty sure that ipp-usb has not been running.

5. Could you run `sudo lsusb -vvv > lsusb.txt` and post the output here? This can give us more helpful information (like for example whether the printer has a 7/1/4 USB interface which would mean IPP-over-USB).

Bus 001 Device 005: ID 04f9:003f Brother Industries, Ltd HL-2130 series
Device Descriptor:
  bLength                18
  bDescriptorType         1
  bcdUSB               2.00
  bDeviceClass            0
  bDeviceSubClass         0
  bDeviceProtocol         0
  bMaxPacketSize0        64
  idVendor           0x04f9 Brother Industries, Ltd
  idProduct          0x003f
  bcdDevice            1.00
  iManufacturer           1 Brother
  iProduct                2 HL-2130 series
  iSerial                 3 C4N971702
  bNumConfigurations      1
  Configuration Descriptor:
    bLength                 9
    bDescriptorType         2
    wTotalLength       0x0020
    bNumInterfaces          1
    bConfigurationValue     1
    iConfiguration          0
    bmAttributes         0xc0
      Self Powered
    MaxPower                2mA
    Interface Descriptor:
      bLength                 9
      bDescriptorType         4
      bInterfaceNumber        0
      bAlternateSetting       0
      bNumEndpoints           2
      bInterfaceClass         7 Printer
      bInterfaceSubClass      1 Printer
      bInterfaceProtocol      2 Bidirectional
      iInterface              0
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x01  EP 1 OUT
        bmAttributes            2
          Transfer Type            Bulk
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0200  1x 512 bytes
        bInterval               1
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x82  EP 2 IN
        bmAttributes            2
          Transfer Type            Bulk
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0200  1x 512 bytes
        bInterval               1
Device Qualifier (for other device speed):
  bLength                10
  bDescriptorType         6
  bcdUSB               2.00
  bDeviceClass            0
  bDeviceSubClass         0
  bDeviceProtocol         0
  bMaxPacketSize0        64
  bNumConfigurations      1
Device Status:     0x0001
  Self Powered

6. Please also check whether moving the printer or its cable influences whether your printer is accessible or not (cable/connector defect?).

It works perfectly with current cups and has done for many years.
However, it seems to depend on whether the printer has gone to sleep.  It seem that if  turn to printer off and then on so it starts making noise .  I then restart the Ghostscript printer app, and I can print.  Once the printer goes to sleep it doesn't work any more.  The old cups still works and can wake up the printer and print stuff.
A new issue.  The ghostscript printer app no longer wants to terminate when told to do so by systemd.  That used to work a few days ago.  Eventually, systemd send to big SIGKILL to force it to stop.

See also this discussion about the nsswitch.conf workaround.

For me
sudo snap stop ghostscript-printer-app

usually works but can sometimes have a delay of around 1 minute, probably if there is ome jobe hanging because the printer is disconnected or turned off.
To investigate why the printer falling into sleep mode makes it unaccessible for the Printer Application, I need more information (my HP does not have such a problem).
The Ghostscript Printer Application as it comes fromthe Snap Store uses the same backends as CUPS uses (but its own copies, so that the Printer Application does not need CUPS on the system), so usually a printer with works with CUPS should work with any of OpenPrinting's Printer Application (naturally the one containing the correct driver).
What can happen when a printer goes to sleep and wakes up again is that the USB device number changes (second nymber in lsusb output lines), but this should not affect the USB CUPS backend as the backend always walks through all USB devices (does the equivalent of lsusb -vvv and grabs the device IDs from the printers) and selects the device of which the model name and the serial number are in the device URI. The device URI you see in the state file of the Printer Application, /var/snap/ghostscript-printer-app/common/ghostscript-printer-app.state. Could you attach your state file (do not forget to attach a copy renamed with .txt file name extension added).

Also what is the output of
snap connections | grep ghostscript-printer-app

[root@mybox selinux]# snap connections | grep ghostscript-printer-app
avahi-control  ghostscript-printer-app:avahi-control  :avahi-control  -
home           ghostscript-printer-app:home           :home           -
network        ghostscript-printer-app:network        :network        -
network-bind   ghostscript-printer-app:network-bind   :network-bind   -
raw-usb        ghostscript-printer-app:raw-usb        :raw-usb        -
[root@mybox selinux]# snap list --all
Name                     Version   Rev    Tracking       Publisher      Notes
core20                   20211115  1242   latest/stable  canonical✓     base
ghostscript-printer-app  1.0       189    latest/edge    openprinting✓  -
snapd                    2.52.1    13640  latest/stable  canonical✓     snapd
[root@mybox selinux]#

Do you have any other Snaps which are supposed to communicate with USB devices? Do they work correctly for you?

For me
sudo snap stop ghostscript-printer-app

usually works but can sometimes have a delay of around 1 minute, probably if there is ome jobe hanging because the printer is disconnected or turned off.

You might need to have someone else test this on a Fedora system.

To investigate why the printer falling into sleep mode makes it unaccessible for the Printer Application, I need more information (my HP does not have such a problem).

Actually the printer sleep mod is not an issue as I stated before.
Important is, I now believe, that the printer has to be turned on before starting the printer app.

I found in the service file:
TimeoutStopSec=30

This means the systemd will use the big SIGKILL after 30 seconds, way before the 60 second delay when it things there are jobs active.

Closing:  The original issue is fixed,  Thanks.

To find out about your USB problem I need some more information. Could you

Do tests with once starting the Printer Application and then turning on the printer and second first turning on the printer and after that starting the Printer Application? Do several tests. Does it work for one case and not for the other? If so, for which does it work, for which not? Make sure to remove all old jobs which did not print from the queue.
The "operation not permitted" errors happen exactly when? When starting the Printer Application? When printing a job? ...

For the usb printer to work in all cases it just needs this little fix as described in the pull request.
https://github.com/systemd/systemd/pull/21576
The problem in snap-device-helper has been fixed, and it just needs an additional permission from systemd to actually work.


Custom scrollbars. Supported in webkit browsers only at the moment.

Custom scrollbars. Supported in webkit browsers only at the moment.
http://css-tricks.com/custom-scrollbars-in-webkit/

This issue was imported from Google Moderator
Moderator votes: +10
Issue added by ____ on 2012-08-15
To vote this issue up or down, simply include +1 or -1 in your comment.

+1

-1

Duplicate of #1449.


[GAPRINDASHVILI] [Changelog] Update for Gaprindashvili-6

[skip ci]

@miq-bot add_label documentation

@miq-bot assign simaishi

@simaishi please merge this too if ready. Thanks!

@JPrause Please set reviewer for this PR.

@simaishi I've already reviewed it,..can you go ahead and merge. @Fryguy will be addressing the review/merge process in an email.

@JPrause I skimmed through the PR (but didn't review the content), so merging.
But can you please make sure we come to conclusion on the process quickly? I think we have/had issues/questions enough already... I know you reviewed it (otherwise you won't open a PR!!!), but the PR owner can't be the reviewer.


asserts replaced by exception for text classification task with test.

I have replaced only a single assert in text_classification.py along with a unit test to verify an exception is raised based on https://github.com/huggingface/datasets/issues/3171 .
I would like to first understand the code contribution workflow. So keeping the change to a single file rather than making too many changes. Once this gets approved, I will look into the rest.
Thanks.

Haha it looks like you got the chance of being reviewed twice at the same time and got the same suggestion twice x)
Anyway it's all good now so we can merge !

Thanks for the feedback.


Labels on date axis don't work on all geoms

As in your examples the geom_point()

has a broken datetime axis but the geom_line() ist correct

Just had the same thing while translating an R project. There isn't an error code I could provide.

This same datetime x-axis issue happens when I include the stat_smooth parameter as well.  If I omit it, it shows the pretty 10 year increments.


DbContext Not Being Disposed Ef Core 1.1

Steps to reproduce
using (var ctx = new ReportingDbContext())
{
     var result = await ctx.Companies.ToListAsync();
     return View(result);
}

The issue
The connection to the database is not being disposed after the result is being returned to the view. After the view has finished rendering, the view result is complete and nothing makes requests to the controller.
Further technical details
EF Core version: 1.1.0
Operating system: Windows 10
Visual Studio version: 2015 Version 14.0.25422.01 Update 3
Other details about my project setup:
I am using the following database
Microsoft SQL Server 2016 (RTM) - 13.0.1601.5 (X64)   Apr 29 2016 23:23:58   Copyright (c) Microsoft Corporation  Express Edition (64-bit) on Windows 10 Home 6.3  (Build 14393: )
This was addressed in #6581 and patch was approved. I do not believe it was merged into the correct and put into the patch train.

@euclid47 I am not sure if what you are seeing is related to the issue described in #6581, because that involved queries with Include(). Anyway, the fix for that issue is part of a patch release that we haven't shipped yet. By the way, as far as I understand #6581 manifests only when MARS is disabled, so you could try enabling MARS in the connection string as a workaround.
If it isn't related to #6581, we would probably need additional information to repro. A repro project would be good.

@divega
Here is another example from my project where the connection is not getting disposed.
 public async Task<IActionResult> Index()
        {

            var result = new List<CompanyListingVm>();
            var companies = stormpath.getUserCompanies(account, false);

            if (companies.Any())
            {
                using (var ctx = new ReportingPlusDbContext())
                {
                    foreach (var c in companies)
                    {
	                    var tmp = await ctx.Companies.Include(x => x.CompanyAddress).FirstOrDefaultAsync(x => x.Id == c.Id);
	                    var empCount = await ctx.Employees.Where(x => x.Active && x.CompanyId == c.Id).CountAsync();

						result.Add(new CompanyListingVm
                        {
                            Company = (CompanyVm)tmp,
                            EmployeeCount = empCount
                        });
                    }
                }
            }

            return result.Any() ? View(result) : View();
        }

If I do not enable MARS I only have one connection that does not get disposed. If I enable MARS three connections do not get disposed. Enabling MARS is not a workaround and it actually increases the number of connections not disposed.

@smitpatel does this ring any bells?

This is not related to #6581 since there is no collection include.
@euclid47 - Can you provide a stand-alone repro code?
The query in first post is very simple query. If it is showing that behavior then probably there are other factors causing it. (Notice SqlServer 2016)

@smitpatel I will have to create a new project and push it up to github. The current project is company proprietary. The code will be as close as possible. It will take me a few days to get it pushed.

@divega @smitpatel
I have created a project that demonstrates the issue.
https://github.com/euclid47/ExampleNotDisposing

@euclid47 What mechanism are you using to determine that connections are not getting disposed?

@ajcvickers I am using the Activity Monitor in sql server management studio 2016

@euclid47 This is not an accurate way of determining that connections have been closed or disposed because because the SQL Client ADO.NET provider is using connection pooling. This means that a connection can be closed and disposed in .NET without the underlying pipeline to the database being closed.

@ajcvickers I was able to add Pooling=False in my connection string and prove your position that Activity Monitor is not an accurate method due to connection pooling. Thank you for very much for the your time and help. I will close this issue due to it being a matter of user education.


Fixed #25346 -- Delete broken symlinks from STATIC_ROOT

Fixed the bug that manage.py collectstatic --clear does not delete broken symlinks.
https://code.djangoproject.com/ticket/25346
FileSystemStorage.delete checks if file exists before removing file the file.
However, os.path.exists used in FileSystemStorage.delete returns False for broken symlinks.
os.path.lexists returns True for broken symlinks, so we should use this.
Perhaps I should have changed FileSystemStorage.delete to use os.path.lexists. I avoided to change FileSystemStorage.delete, because changing FileSystemStorage has a wide influence.

buildbot, add to whitelist.

@timgraham Thank you for your kind review. I have just updated codes. Please review again.

merged in 0922bbf18d3ae8f37e1823df2dbc270d33334548, thanks!


Fixit4chef12

https://github.com/daptiv/seven_zip

tas50:  This is a 1 line change for our internal use to clean up the output since we're stuck (for the moment) with the 2.7 branch of the nginx cookbook.  In the future hopefully they'll release an update or we can rewrite to avoid that dependency.

@matt-altiscale The nginx cookbook probably won't get released anytime soon. It's basically dead at this point. I maintain a fork chef_nginx for Chef that we've been working on for a while. I'd highly recommend checking it out. https://github.com/chef-cookbooks/chef_nginx


added project and team details-Ashwin, Peter and Naveen

Hi,
I've included our project details in the github repository.
Please let me know if I need to make any changes.
Ashwin

Very cool.


Modal Windows

Is there any way to create little modal windows? I'm thinking something like theres a setting that someone can edit and the edit happens in a popup modal window in the center of the screen. Currently it looks like attempting to overlay a center-justified view, even a relatively small one, results in the whole screen getting re-rendered and losing the presenting view entirely. I suspect this is because the entire view needs to be buffered to be able to know the dimensions for where the center is. Is there some clever method to get something like this working? Or is this possible as a feature request?

Hi @mjKosmic ,

Is there any way to create little modal windows? I'm thinking something like theres a setting that someone can edit and the edit happens in a popup modal window in the center of the screen.

That's on my wishlist but it's not supported right now. You could draw a pop-up over other content using a ZStack, but it won't prevent the content below from being selected.

Currently it looks like attempting to overlay a center-justified view, even a relatively small one, results in the whole screen getting re-rendered and losing the presenting view entirely.

I'm not sure I understand, how are you trying to overlay that center view?

I mean just using something as simple as the following:
`struct ModalView: View {
var dismiss: () -> Void
var body: some View {
    VStack(alignment: .center) {
        HStack(alignment: .center) {
            VStack {
                Text("Modal")
                Button("Dismiss") {
                    dismiss()
                }
            }
        }
    }
}

}`
results in the entier screen getting redrawn. Interestingly, it looks like if i embed that modal code in a ZStack, it doesn't center the text and button, but rather renders it in the top left corner
here is the relevant ZStack embedding code:
ZStack {                     VStack {                         HStack {                             Spacer()                             Text("Background")                         }                         Spacer()                     }                     .border()                         ModalView() {                             //dismiss logic                         }                 }

By default, ZStack in SwiftTUI indeed uses a top leading alignment. You can use ZStack(alignment: .center) instead.
In your original code without the ZStack, I suppose you are trying to show the ModalView in the root view, could you help me and send the code of that root view as well so I can try to reproduce? By "redraws the entire screen", you mean that you cannot see the background view, right?

It looks like the reason i got what appeared to be a full screen modal was because i was switching on an enum and not actually appropriately presenting the modal view. This along with a frame(maxWidth: .infinity, maxHeight: .infinity, alignment: .center) placed the modal view in the center of the screen. I think that part is working as expected.
However, a modal view modifier would still be really cool :)


Update sbt-scalajs, scalajs-compiler, ... to 1.7.0

Updates

org.scala-js:sbt-scalajs
org.scala-js:scalajs-compiler
org.scala-js:scalajs-library
org.scala-js:scalajs-library_2.13
org.scala-js:scalajs-test-bridge
org.scala-js:scalajs-test-bridge_2.13

from 1.6.0 to 1.7.0.
GitHub Release Notes - Version Diff
I'll automatically update this PR to resolve conflicts as long as you don't change it yourself.
If you'd like to skip this version, you can just close this PR. If you have any feedback, just mention me in the comments below.
Configure Scala Steward for your repository with a .scala-steward.conf file.
Have a fantastic day writing Scala!

Ignore future updates
Add this to your .scala-steward.conf file to ignore future updates of this dependency:
updates.ignore = [ { groupId = "org.scala-js" } ]

labels: library-update, semver-minor

Codecov Report

Merging #1803 (144c095) into master (503b4ae) will increase coverage by 0.01%.
The diff coverage is n/a.

@@            Coverage Diff             @@
##           master    #1803      +/-   ##
==========================================
+ Coverage   86.19%   86.21%   +0.01%
==========================================
  Files          73       69       -4
  Lines        2499     2473      -26
  Branches      136      142       +6
==========================================
- Hits         2154     2132      -22
+ Misses        345      341       -4

Impacted Files
Coverage Δ

...re/shared/src/main/scala/io/circe/MapDecoder.scala
88.00% <0.00%> (-8.00%)
:arrow_down:

...core/shared/src/main/scala/io/circe/CursorOp.scala
54.16% <0.00%> (-1.39%)
:arrow_down:

...es/core/shared/src/main/scala/io/circe/Error.scala
62.06% <0.00%> (-0.44%)
:arrow_down:

...nter/src/main/scala/io/circe/pointer/Pointer.scala
89.34% <0.00%> (-0.13%)
:arrow_down:

...rc/main/scala/io/circe/numbers/BiggerDecimal.scala
87.71% <0.00%> (ø)

...d/src/main/scala-2.12/io/circe/CompatBuilder.scala

...in/scala/io/circe/pointer/PointerSyntaxError.scala

...rc/main/scala-2.12/io/circe/FactoryInstances.scala

.../main/scala-2.12/io/circe/CollectionDecoders.scala

.../core/shared/src/main/scala/io/circe/Decoder.scala
83.72% <0.00%> (+0.21%)
:arrow_up:

Continue to review full report at Codecov.

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


Event destination state should be state dependent

As I understand it, events in TransitionKit can only have a single destination state. This is a result of the set of valid event transitions being state-independent, rather than a function of the current state.
As an example, here's the state machine from the README:

All of the events have a single destination state, regardless of the current state. So, the following state machine is currently impossible to model:

Well, not impossible. You can create two "View Message" events, two "Mark as Unread" events, and two "Delete Message" events... And then fire the correct one in a if/else if block by checking the current state. But that quickly becomes unwieldy in a larger state machine.

Is my understanding correct that this is a limitation of the current API?

Is this something that you would be willing to accept a pull request for, or is this part of the design that you wouldn't be open to changing?

If you are open to a pull request, how open are you to API changes? The API will have to change, but hopefully not too much. Something along the lines of:

TKState *S1 = [TKState stateWithName:@"S1"];
TKState *S2 = [TKState stateWithName:@"S2"];
TKState *S3 = [TKState stateWithName:@"S3"];

// Simple transition
TKEvent *simple = [TKEvent eventWithName:@"Simple Event" transitioningFromStates:@[S1, S2] toState:S3];

// Add more transitions to existing event
[simple addTransitionFromStates:@[S3] toState:S1];

// Or add them all at once
TKEvent *complex = [TKEvent eventWithName:@"Complex Event" transitions:@{ @[S1, S2]: S3, @[S3]: S1 }];

+1
I like this pod, but our team also pointed out the shortcoming @kurige mentioned. I also agree with him that it can be added in a clean way.
@kurige, please do let me know if you already have a fork with the implementation. I might be interested.

+1 too.
I'm modelling device registration and unregistration, and i'd like to be able to send a single NetworkUp signal to the SM. If the SM is in the WaitingForNetworkWhileRegistering state it would proceed to Registering, and if it is in the WaitingForNetworkWhileUnregistering state it would proceed to Unregistering. At the moment I have to implement by sending two signals - NetworkUpWhileRegistering and NetworkUpWhileUnregistering which doesn't feel right - the external source of network availability shouldn't have to know about the internal state of the SM - it just wants to tell it that the network is up or down.

+1

PR is worth a thousand +1’s

@blakewatters: I agree with "PR is worth a thousand +1s" :)
We have been able to navigate around any need for this feature, for now. But I suspect we will need this for a cleaner implementation. I'm willing to implement a solution when that time comes.

+1


Create a skeleton config.yaml

The over all CI-CD architecture was finalized and created Circle CI skeleton file which defines build test and deploy steps successfully.


Flutter :  Navigation - Video

Description
Add video on Navigation in Flutter, covering:

the Navigation model
its approach
Navigator API

Cover examples too with complete explanation!
Domain
Android Dev (Flutter)
Type of Contribution
Video
Code of Conduct

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

@RuchikaSuryawanshi7 write */assign without asterisks

/assign

/assign


Added UIC related data model section

Some first addition

The analysis is ongoing to have the SFERA system interface with the RINF KG but the internal messaging will remain off-KG.


split blocks (and maps) by index as well as by label

Fixes #187. One pain point for me in using mts is when I know that I want to pick a slice of a block, I know what indices I need, and instead I've to figure out how to do the same thing by sample labels. This PR (that looks like could be pretty simple) implement direct selection by indices.
Contributor (creator of pull-request) checklist

[ ] Tests updated (for new features and bugfixes)?
[ ] Documentation updated (for new features)?
[ ] Issue referenced (for PRs that solve an issue)?

Reviewer checklist

[ ] CHANGELOG updated with public API or any other important changes?

📚 Download documentation preview for this pull-request

Related to https://github.com/metatensor/metatensor/issues/187

Still TBD:

[ ] Add tests using list/arrays as selection
[ ] fix an issue where the gradient samples are wrong after slicing
[ ] Add the same ability to split

does this needs more reviewing or can it be merged?

I've updated the changelog & documentation, should be good to merge once CI is happy


[Edit profile] User can not enter special characters ()!,-’ in the City field on User profile

Environment: Windows 10 Pro v.21H2, Google Chrome 109.0.5414.74 (64-bit).
Reproducible: always.
Build found: 14/01/23
Preconditions

The registered user is logged in.
'My habits' page is opened.

Steps to reproduce

Click the 'Edit' icon on the Profile block.
Enter special characters in the City field
() ! , - ’

Actual result
An error message in red is displayed when user enters special characters: ()!,-’ in the City field.

Expected result
An error message in red isn’t displayed when user enters special characters: ()!,-’ in the City field.
Postconditions
User story and test case links
E.g.: "User story #1010
Test case
Labels to be added
"Bug", Priority ("Medium "), Severity ("Minor"), Type ("Functional").

City can't be started with special characters
Add missing special characters '!''


Bugfix / Update PyPi Version

Bump version to 0.2.2 in setup.py - fixes PR #161
Correct CHANGELOG.md date and version for v0.2.1 release
Add v0.2.2 to CHANGELOG.md - will need to be tagged and released if PR is approved

@dasJ

@bryantbiggs Thanks for your work, with some changes I've reflected the changes REF.
Sorry for the delay


fixes After click on the image app is crashed (#4072)

Description (required)
Fixes #4072
What changes did you make and why?
add an function setSupportActionBar(toolbar) in searchActivity.java becouse getSupportActionBar() function in MedaiDeatailsPageFragment.java give null object reference this cause to crash
Tests performed (required)
android Device :Redmi y3
API:29
Screenshots (for UI changes only)

anyone view my pullRequest

@ashishkumar0207 Hi

please review my pull request so i make another PR of another issue

Thanks @Prince-kushwaha !


Not able to run create, list and other Knowledge base samples

Description
I am not able to create or list a knowledge base programmatically from my NodeJS environment.
Here is my StackOverflow Question: https://stackoverflow.com/questions/60532102/dialogflow-nodejs-knowledge-iam-permission
Environment details

OS: Mac Mojave 10.14.6
Node.js version: 12.13.0
npm version: 6.13.7
@google-cloud/dialogflow version: 1.2.0

Steps to reproduce

copy the sample code for create knowledge base or list knowledge base
run by passing projectID and name

Problem was my key was for client and not for admin. Issue resolved

@JustinBeckwith the issue is resolved


OvO support on AUROC

🚀 Feature
Hi in the sklearn API there is a multi_class parameters which can be set to ‘ovr or ‘ovo'. But it seems that this is not yet implemented in the torchmetrics.
Motivation
In sklearn we can compute ovo AUC, but currently this is not supported
tm = AUROC(num_classes=7, average='macro')
x = torch.randn(100, 7).softmax(1)
y = torch.randint(7, (100, ))
print(tm(x, y), roc_auc_score(y, x, average="macro", multi_class="ovo"))

Additional context
Using torchmetrics 0.6.0

Issue will be closed by classification refactor: see this issue https://github.com/Lightning-AI/metrics/issues/1001 and this PR https://github.com/Lightning-AI/metrics/pull/1195 for all changes
Small recap: This issue ask for support that one-vs-one approach for calculating auroc in multiclass settings. During the refactor it was determined that we do not want to pursue this approach and still only support one-vs-the-rest for calculating roc, auroc etc.
Issue will be closed when https://github.com/Lightning-AI/metrics/pull/1195 is merged.

It was determined that we do not want to pursue this approach and still only support one-vs-the-rest for calculating roc, auroc etc.

Would it be possible to add this clarification to the docs?
Currently it is not clear (to me) what is the multiclass approach that is place (one-vs-one/one-vs-rest).
Thanks!


Add devcontainer

This change adds a devcontainer.json file (ignored by Prettier) with set up for VSCode and GitHub Codespaces compatible container. It includes all the required components for building the repo with python build.py as well as the set of workspace recommended extensions.

OK.... I guess. Do you or others use DevContainers then? If we're going to actively use this in the team then it seems fine to check in. But I don't want it to bit-rot if it's not something we actively need/use.

I use devcontainers as my primary way of testing Linux from Windows and for running in codespaces from my iPad, and I know other repos have benefitted from having this configured. It’s also handy that all our dependencies can be configured from official Microsoft devcontainer images (and one simple post-create command), so there is no need for complex configuration or even a Dockerfile.


Library information:

Version: latest
Compose module: From Example 3 "Horizontal Calendar"

Question:
Is it possible to lazy load monthly events (for each day of the currently visible month) for the closest months ? Like in a ViewPager.
I see 2 loading patterns with your lib :

load all events (like in your example 3) and pick the events you need depending on the currentVisibleMonth : previous/next transitions are OK but .... the events loading is not restricted to the current month (performance issue on large event database)
load the monthly events when the currentVisibleMonth changes : but the previous/next transitions shows a FLASH of content because data of the next month has not been lazy loaded before the page shows up.

So Is there a way to lazy load efficiently month by month data ?
Thanks

load the monthly events when the currentVisibleMonth changes : but the previous/next transitions shows a FLASH of content because data of the next month has not been lazy loaded before the page shows up.

This is the way to go, but unless your connection is super fast, you won't always finish loading the adjacent month data before the user swipes to it. I'd suggest loading 2 or 3 months ahead to give the requests some time.


CutMix Implementation with Keras

Hello Keras Team! I want to contribute to the coding example at keras.io by implementing CutMix implementation for image classification with Keras. Can anyone assign me or may I directly work on it and send a PR.
Paper: https://arxiv.org/pdf/1905.04899.pdf
Thank You!

You can start working on it and send over a PR.

Ok @sayakpaul 👍


[cherry-pick] add auto mode for test.data.load (#994)

cherry-pick https://github.com/pingcap/tispark/pull/994

/run-all-tests

/run-all-tests

Codecov Report

:exclamation: No coverage uploaded for pull request base (release-2.1@e494f95). Click here to learn what that means.
The diff coverage is n/a.

@@              Coverage Diff               @@
##             release-2.1    #1205   +/-   ##
==============================================
  Coverage               ?   53.25%
  Complexity             ?     1119
==============================================
  Files                  ?      153
  Lines                  ?     7023
  Branches               ?      820
==============================================
  Hits                   ?     3740
  Misses                 ?     2913
  Partials               ?      370

Continue to review full report at Codecov.

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


[1.18.1] Requester recipes missing

In JEI, I'm only able to see a recipe for the ultra and creative requesters, but the elite requester (which shows up in the recipe for the ultra) doesn't have a recipe, and I don't even see the first one, that I'm assuming would be the basic requester. Very strange.


After upgrade to v0.12.4 pokt validator doesn't serve relays

Got a session of ETH with zero rewards and poktscan respond with error " invalid JSON from provider", responded with 5xx
https://node-000.pokt.yanis.gr/v1 was giving 502 gateway error
on nginx error log files i saw errors about invalid upstream pokt-000:{{RPC_PORT}}
and on nginx pokt-000 conf file i see

More ppl have same errors

Also
pokt-000.domain.com/v1 shows invalid https certificate
Although I think the certificates are for node-000.domain.com (page node-000.domain.com/v1 has green lock in url)

Resolved in v0.12.5