Using OSCYank as a clipboard provider

OSCYank is great, but only works if I'm manually yanking text. I really wanted it to work with anything that copies to the clipboard, like fugitive's GBrowse! command. Neovim (not vim, AFAIK) allows users to implement a custom clipboard provider, which I managed to integrate with OSCYank like so:
let g:clipboard = {
        \   'name': 'osc52',
        \   'copy': {'+': {lines, regtype -> OSCYankString(join(lines, "\n"))}},
        \   'paste': {'+': {-> [split(getreg(''), '\n'), getregtype('')]}},
        \ }

Now regular yanks (using clipboard=unnamedplus) as well as commands like GBrowse! will put text on the local clipboard.
Would this make sense to include in the README? I only discovered g:clipboard today, so I have no idea if it might cause unexpected problems, but so far I've found it useful and wanted to share :)

I love this! Thank you for the tip.

Thanks!
The following is even better because there are no errors on :registers:
let g:clipboard = {
        \   'name': 'osc52',
        \   'copy': {
        \     '+': {lines, regtype -> OSCYankString(join(lines, "\n"))},
        \     '*': {lines, regtype -> OSCYankString(join(lines, "\n"))},
        \   },
        \   'paste': {
        \     '+': {-> [split(getreg(''), '\n'), getregtype('')]},
        \     '*': {-> [split(getreg(''), '\n'), getregtype('')]},
        \   },
        \ }

lua version
local function copy(lines, _)
  vim.fn.OSCYankString(table.concat(lines, "\n"))
end

local function paste()
  return {
    vim.fn.split(vim.fn.getreg(''), '\n'),
    vim.fn.getregtype('')
  }
end

vim.g.clipboard = {
  name = "osc52",
  copy = {
    ["+"] = copy,
    ["*"] = copy
  },
  paste = {
    ["+"] = paste,
    ["*"] = paste
  }
}

this doesnt seem to work with 'yy' to yank a line, any way to fix that?

@nathanaelcunningham y uses the "unnamed" register unless you explicitly specify a register like + or *.
If you want y to always use a clipboard register (and consequently work with the clipboard provider described above), try set clipboard=unnamed or set clipboard=unnamedplus. See https://neovim.io/doc/user/provider.html.

To ALWAYS use the clipboard for ALL operations (instead of interacting with
the '+' and/or '*' registers explicitly):
set clipboard+=unnamedplus

Thank you for the solutions. I tried one but result still not perfect: paste is not working.
So I added this:
local function copy(lines, _) vim.fn.OSCYankString(table.concat(lines, "\n")) end
local function paste() return { vim.fn.split(vim.fn.getreg(''), '\n'), vim.fn.getregtype('') } end
vim.g.clipboard = {  name = "osc52", copy = { ["+"] = copy, ["*"] = copy }, paste = { ["+"] = paste, ["*"] = paste }}
vim.cmd [[
set clipboard+=unnamedplus
]]

Result:

[Kitty] copying via SSH works
[Kitty] copying via SSH while nvim opened in tmux works
[Alacritty] copying in both cases doesn't work
[Kitty] copying locally without tmux works
[Kitty] copying locally inside tmux doesn't work
[Alacritty] copying locally without tmux works
[Alacritty] copying locally with tmux doesn't work

Pasting doesn't work everywhere (there is a way to paste using Ctrl+Shift+v by using terminal but it's not a good way to do that):
E353: Nothing in register "
E353: Nothing in register +

So did anyone found a way to fix these problems? Don't know what can be done in the situation.

I found two ways to fix almost all problems I mentioned. However it's unrelated to this issue about clipboard provider but I hope you can adapt it for your usecases or even to clipboard provider.
First of all, if you want to use this plugin, there is one solution but it has drawbacks: it copies successfully in 1-5 of 10 tries in tmux. Have no idea why. It tries to copy but no actual clipboard filling happens in some tries. Without tmux it's working fine.
Example of config. I use '+' here with mswin because I like mswin behaviour and it copies to '+' register:
autocmd TextYankPost * if v:event.operator is 'y' && v:event.regname is '+' | execute 'OSCYankReg +' | endif
source $VIMRUNTIME/mswin.vim

But I don't recommend this way because of tmux issues.
I found the Greatest Ever solution from Reddit user leeren: https://www.reddit.com/r/vim/comments/ac9eyh/comment/ed6kl67/?utm_source=share&utm_medium=web2x&context=3
Original code had some syntax errors, so I changed it a little bit to make shorter and adapted to our task, have a look:
function! Osc52Yank(text)
    let buffer='\e]52;c;'.substitute(system('base64 -w0', a:text), "\n$", "", "").'\x07'
    "echo buffer " Uncomment it to see that this function is actually called by autocmd
    silent exe "!echo -ne ".shellescape(buffer)." > ".shellescape("/dev/pts/0")
endfunction
au TextYankPost * if v:event.operator is 'y' && v:event.regname is '+' | call Osc52Yank(join(v:event.regcontents, "\n")) | endif

Again I use '+' register, you can omit it in if statement if you want or if you just don't use mswin.
Normally mswin setups <C-c> keybinding for copying into '+' register for us but it won't happen if we connect via SSH without tmux since in https://github.com/vim/vim/blob/master/runtime/mswin.vim#L26 vim checks clipboard support and don't add keybindings if there is no clipboard (in tmux there is a clipboard available, so that's why it works there).
So we need to setup keybindings ourselves if we want to have clipboard working:
" CTRL-X and SHIFT-Del are Cut
vnoremap <C-X> "+x
vnoremap <S-Del> "+x
" CTRL-C and CTRL-Insert are Copy
vnoremap <C-C> "+y
vnoremap <C-Insert> "+y
" CTRL-V and SHIFT-Insert are Paste
map <C-V>		"+gP
map <S-Insert>		"+gP
cmap <C-V>		<C-R>+
cmap <S-Insert>		<C-R>+

Ok, cool, but in this case we will meet a limit of ~100.000 characters. I don't know on what the limit is: number of characters or bytes, and is this limit of initial text or base64 encoded. In my case the limit was ~98000 characters and ~130000 base64 characters. After I tried to copy larger part of text nvim just crashed:).  Let's change the code a little bit:
if strlen(a:text) > 90000
      echohl ErrorMsg
      echo "Too long string, divide it into chunks. Length: ". strlen(a:text) , ", max: 90000"
      echohl None
      return
 endif

And the final result is:
function! Osc52Yank(text)
    if strlen(a:text) > 90000
      echohl ErrorMsg
      echo "Too long string, divide it into chunks. Length: ". strlen(a:text) , ", max: 90000"
      echohl None
      return
    endif
    let buffer='\e]52;c;'.substitute(system('base64 -w0', a:text), "\n$", "", "").'\x07'
    silent exe "!echo -ne ".shellescape(buffer)." > ".shellescape("/dev/pts/0")
endfunction
au TextYankPost * if v:event.operator is 'y' && v:event.regname is '+' | call Osc52Yank(join(v:event.regcontents, "\n")) | endif

" CTRL-X and SHIFT-Del are Cut
vnoremap <C-X> "+x
vnoremap <S-Del> "+x
" CTRL-C and CTRL-Insert are Copy
vnoremap <C-C> "+y
vnoremap <C-Insert> "+y
" CTRL-V and SHIFT-Insert are Paste
map <C-V>		"+gP
map <S-Insert>		"+gP
cmap <C-V>		<C-R>+
cmap <S-Insert>		<C-R>+

source $VIMRUNTIME/mswin.vim

The final result works with:

Kitty (shell, shell + tmux, ssh, ssh + tmux)
Alacritty (shell, shell + tmux, ssh, ssh + tmux)
in 100% of tries to copy
with the limitation of characters
internal clipboard of nvim works with paste as usual (p or Ctrl+v)
external paste doesn't work, you need to press Ctrl + Shift + V in this case.

I wanted to jump in here as well since I had this issue a while ago, and found a solution which might not be perfect, but works for all cases I typically go through:
I develop on an SSH server, so I was looking for something that when:

Copies/pastes inside vim should replicate outside vim
Copies/pastes outside vim should replicate inside vim

To solve this, I have the following Lua file in my config:
local isInSsh = not (vim.env.SSH_CLIENT == nil) -- I share this config with my local machine, so I need this to ignore this provider if not on ssh

if isInSsh then
  local clipboard = {}

  local function refreshClipboard()
    vim.fn.jobstart(
    -- I have a reverse ssh tunnel to my local machine called "local", which allows me to get stuff from my macbook's pbpaste
      "ssh local pbpaste",
      {
        stdout_buffered = true,
        on_stdout = function(_, data) clipboard = data end
      }
    )
  end

  refreshClipboard() -- Initialize the clipboard when the file is loaded

  local function copy(lines, regtype)
    vim.fn.OSCYankString(table.concat(lines, "\n"))
    clipboard = { lines, regtype }
  end

  -- doesn't necessarily paste the current clipboard content (if, for example, I copy something outside vim)
  -- but it refreshes when called, so if you try again it will paste the current clipboard content
  -- I do this as a compromise to avoid delays when pasting
  local function paste()
    refreshClipboard()
    return clipboard
  end

  vim.api.nvim_create_user_command('RefreshClipboard', refreshClipboard, {})

  vim.g.clipboard = {
    name = "osc52",
    copy = {
      ["+"] = copy,
      ["*"] = copy
    },
    paste = {
      ["+"] = paste,
      ["*"] = paste
    }
  }
end

Then I have on my ssh machine's ~/.ssh/config:
Host local
  HostName localhost
  Port 2222
  User <host user>

and then on my local machine's ~/.ssh/config:
Host dev
  HostName <IP for the SSH machine>
  User <user>
  RemoteForward <IP_ADDRESS>:2222 <IP_ADDRESS>:22 # this allows me to access the local machine from the remote machine
  ServerAliveInterval 240

This allows me to keep the clipboard in sync in almost all cases, the only quirk is that if I have vim already open and copy something outside vim (on a webpage, for example), when you paste it inside vim, it will paste the old contents of the clipboard, and sync it behind the scene, so I have to undo and paste again. I do this as a compromise, to avoid adding any delay when pasting since I'd have to wait for the ssh to connect to my local machine to get the content. In general, this doesn't happen that often with me, so I'm okay with it :)
Hope this helps someone else as well!

Thanks @avently. I have been using your awesome solution for a while in my linux machine and it works very well.
Though I ran into some problems when I started using it in my macOS (intel) machine (local Alacritty + zsh + tmux) yesterday because of two issues:

base64 in macOs doesn't have -w0 option. In fact, it would just work in macOS without -w0 (https://stackoverflow.com/questions/46463027/base64-doesnt-have-w-option-in-mac)
echo -ne is not very well portable because different systems and shells could translate it differently. Apparently, my setup couldn't interpret it correctly as we want. It's recommended to use printf instead. (https://stackoverflow.com/a/43528813, https://www.in-ulm.de/~mascheck/various/echo+printf/)

Here is my current updated script which works in macOS (local Alacritty + zsh + tmux) and Linux (ssh Alacritty + zsh + tmux). I've not tested in other combinations:
function WriteToClipboard(text)
    local is_tmux = os.getenv("TMUX")

    local ssh_connection = os.getenv("SSH_CONNECTION")
    if not is_tmux and not ssh_connection then
        -- Not in a SSH session, nothing to do, copy will work anyway
        return
    end

    -- https://stackoverflow.com/questions/46463027/base64-doesnt-have-w-option-in-mac
    local is_macos = vim.fn.has("macunix")
    local base64_opts = "-w0"
    if is_macos then
        base64_opts = ""
    end

    local filename = "/tmp/vim_clipboard.tmp"
    local file = io.open(filename, "w")
    file:write(text)
    file:close()
    if is_tmux then
        -- Copy to each client because there is no way in tmux to differentiate only current client
        os.execute(
            "for pts in $(tmux list-clients -F '#{client_tty}'); do printf $(cat < "
                .. filename
                .. " | base64 "
                .. base64_opts
                .. " | sed 's/\\(.*\\)/\\\\e]52;c;\\0\\\\x07/') > $pts; done"
        )
    else
        os.execute(
            "echo -ne $(cat < "
                .. filename
                .. " | base64 -w0 | sed 's/\\(.*\\)/\\\\e]52;c;\\0\\\\x07/') > "
                .. ssh_connection
        )
    end
    os.remove(filename)
end
vim.cmd [[
au TextYankPost * if v:event.operator is 'y' && v:event.regname is '+' | call v:lua.WriteToClipboard(join(v:event.regcontents, "\n")) | endif

" CTRL-X and SHIFT-Del are Cut
vnoremap <C-X> "+x
vnoremap <S-Del> "+x
" CTRL-C and CTRL-Insert are Copy
vnoremap <C-C> "+y
vnoremap <C-Insert> "+y
" CTRL-V and SHIFT-Insert are Paste
map <C-V>		"+gP
map <S-Insert>		"+gP
cmap <C-V>		<C-R>+
cmap <S-Insert>		<C-R>+

source $VIMRUNTIME/mswin.vim
]]


Makefile: Create commands that dont rely on docker

@jchauncey I'd like to keep the docker-based operations but suffix the build targets with -docker. this way, we can still use them in CI (not strictly necessary, but we can make that change later, in another issue). here's the list of applicable targets:

build
build-docker
test
test-docker

thoughts?

Yeah as long as we have a way to not run them in docker that's fine
On May 11, 2016 5:48 PM, "Aaron Schlesinger"<EMAIL_ADDRESS>wrote:

@jchauncey https://github.com/jchauncey I'd like to keep the
docker-based operations but suffix the build targets with -docker. this
way, we can still use them in CI (not strictly necessary, but we can make
that change later, in another issue). here's the list of applicable targets:

build
build-docker
test
test-docker

thoughts?
—
You are receiving this because you were mentioned.
Reply to this email directly or view it on GitHub
https://github.com/deis/deisrel/issues/40#issuecomment-218622854

clearing the milestone as this is a nice-to-have but not required for rc1


Update api.md

Fix typo on list_spaces and space_info

The docs for this PR live here. All of your documentation changes will be reflected on that endpoint.


IE11 - Unable to get property '@@__symbol:toStringTag0.1657645160586493312' of undefined or null reference

Error:

URL:
<script src="https://polyfill.io/v3/polyfill.min.js?features=es6,es7,Element,Element.prototype.append,Element.prototype.prepend,Element.prototype.replaceWith,Element.prototype.after,Element.prototype.before,Element.prototype.cloneNode,Element.prototype.classList,Element.prototype.matches,Element.prototype.dataset,Element.prototype.closest,Element.prototype.placeholder,Element.prototype.remove,Element.prototype.toggleAttribute,devicePixelRatio,Object.assign,Uint32Array,Reflect,fetch,Math.sign,Promise,Symbol,Symbol.iterator,Symbol.prototype,Symbol.toPrimitive,Symbol.toStringTag,Uint8Array,WeakMap">

cc @spence-s

Hi @niftylettuce, I don't have much to go on with the information you have provided.
I made an html page which has the script tag in it that you have mentioned and opened that in IE11 and see no error. -- https://output.jsbin.com/lobeyusiqa
Do you know what other code I need to run to see this error occur?

I think this is due to https://github.com/Financial-Times/polyfill-service/issues/747 and that we were using<EMAIL_ADDRESS>

@niftylettuce Could you please provide a small reproducible example of this for me? If not, I don't think I can help with it unfortunately.


Rotting Oranges

Description: You are given a grid where each cell is either empty (0), contains a fresh orange (1), or a rotten orange (2). Every minute, rotten oranges rot adjacent fresh oranges. Return the minimum number of minutes that must pass until no fresh orange remains. If it is impossible, return -1.
Example:
Input: [[2,1,1],[1,1,0],[0,1,1]]
Output: 4

Heyy @Saloni6111, could you assign me this issue? I'd like to work on it.

Heyy @Saloni6111, could you assign me this issue? I'd like to work on it.

Sure @RudraJy , it's already assigned to you. Please go ahead!


Queries with refetchOnWindowFocus=true are refetched on focus even if not stale

My queries have a non-zero staleTime (I'm using 5 minutes, or 5 * 60 * 1000 ms). I just noticed that all my queries get force-refetched by the onWindowFocus event handler in setFocusHandler.js, even though they are still fresh. This does not match the expected behavior as per the documentation:

Stale queries will automatically be refetched in the background when the browser window is refocused by the user. You can disable this using the refetchOnWindowFocus option in queries or the global config.

It would be great if the code could be adapted to match the documentation. :-)

This should have been fixed. Can you verify that you are using the latest version of RQ?

The bug is still there in v1.5.5. Reproduction steps:

Set the staleTime of any query to a non-zero positive number, e.g. 60 * 1000 for 1 minute.
Open the page and wait for the first fetch to succeed.
Click away and focus the page again. No refetch will occur (which is okay, as the query is not stale yet).
Wait for the staleTime set in step 1 to elapse (e.g. 1 minute in my example).
Click away and focus the page again. The query will refetch as intended.
Now repeat step 5 as often as you like. The query will get refetched every time, even though the query has just been refetched and should NOT be considered stale.

Any news on this? Were you able to reproduce the bug with my steps?

@rutzfutz I think it's been resolved in the latest version of react-query. I have just tested with the example provided in Docs.
  const { status, data, error, isFetching } = useQuery("posts", getPosts, { staleTime:10000, });

I can’t reproduce in the latest version.

Hello there,
I would like to point out that there is a regression between from v:^1.5.8 and the version ^2.0.0 about this issue.
I had to rollback to the first one to check.
Your "Basic" example can reproduce this issue with the version 2.0.3.
Just add a staleTime and a log to the useQuery to replicate.
function Posts({ setPostId }) {   const { status, data, error, isFetching } = useQuery(     "posts",     async () => {       console.log("QUERY");       const { data } = await axios.get(         "https://jsonplaceholder.typicode.com/posts"       );       return data;     },     { staleTime: 200000 }   );
Thanks for the hard work btw !

@tannerlinsley  @GuillaumeSpera I can confirm that in 2.0.3 refetchOnWindowFocus happens regardless of whether data is stale or not. Setting staleTime: Infinity does nothing.
I like the feature very much, but it would be great if it regarded the staleTime option.

Fixed in c3e42c44afa4f19613043e64aca7d88b9d68ba08 🎉


Whitelist all branches in the default travis config

This way, folks can easily enable travis to run on their personal feature branches by going to travis-ci.com.

+1
(For folks who are unaware; there was prior discussion about this on the mailing list).

+2, merging


refactored BasePaymentsPage to function based component

Details

Migrate BasePaymentsPage to function based component
Fixed Issues

$ https://github.com/Expensify/App/issues/16287
PROPOSAL: https://github.com/Expensify/App/issues/16287#issuecomment-1624688703
Tests

Click the Settings
Click the Payments
Should be enabled Add Payments Method button and showed the added payment methods

[x] Verify that no errors appear in the JS console

Offline tests

Follow the same steps listed in the section above.
Add Payments Method button should be disabled.
QA Steps

Follow the same steps listed in the section above.

[x] Verify that no errors appear in the JS console

PR Author Checklist

[x] I linked the correct issue in the ### Fixed Issues section above
[x] I wrote clear testing steps that cover the changes made in this PR

[x] I added steps for local testing in the Tests section
[x] I added steps for the expected offline behavior in the Offline steps section
[x] I added steps for Staging and/or Production testing in the QA steps section
[x] I added steps to cover failure scenarios (i.e. verify an input displays the correct error message if the entered data is not correct)
[x] I turned off my network connection and tested it while offline to ensure it matches the expected behavior (i.e. verify the default avatar icon is displayed if app is offline)
[x] I tested this PR with a High Traffic account against the staging or production API to ensure there are no regressions (e.g. long loading states that impact usability).

[x] I included screenshots or videos for tests on all platforms
[x] I ran the tests on all platforms & verified they passed on:

[x] Android / native
[x] Android / Chrome
[x] iOS / native
[x] iOS / Safari
[X] MacOS / Chrome / Safari
[X] MacOS / Desktop

[x] I verified there are no console errors (if there's a console error not related to the PR, report it or open an issue for it to be fixed)
[x] I followed proper code patterns (see Reviewing the code)

[x] I verified that any callback methods that were added or modified are named for what the method does and never what callback they handle (i.e. toggleReport and not onIconClick)
[x] I verified that the left part of a conditional rendering a React component is a boolean and NOT a string, e.g. myBool && <MyComponent />.
[x] I verified that comments were added to code that is not self explanatory
[x] I verified that any new or modified comments were clear, correct English, and explained "why" the code was doing something instead of only explaining "what" the code was doing.
[x] I verified any copy / text shown in the product is localized by adding it to src/languages/* files and using the translation method

[x] If any non-english text was added/modified, I verified the translation was requested/reviewed in #expensify-open-source and it was approved by an internal Expensify engineer. Link to Slack message:

[x] I verified all numbers, amounts, dates and phone numbers shown in the product are using the localization methods
[x] I verified any copy / text that was added to the app is grammatically correct in English. It adheres to proper capitalization guidelines (note: only the first word of header/labels should be capitalized), and is approved by marketing by adding the Waiting for Copy label for a copy review on the original GH to get the correct copy.
[x] I verified proper file naming conventions were followed for any new files or renamed files. All non-platform specific files are named after what they export and are not named "index.js". All platform-specific files are named for the platform the code supports as outlined in the README.
[X] I verified the JSDocs style guidelines (in STYLE.md) were followed

[x] If a new code pattern is added I verified it was agreed to be used by multiple Expensify engineers
[x] I followed the guidelines as stated in the Review Guidelines
[x] I tested other components that can be impacted by my changes (i.e. if the PR modifies a shared library or component like Avatar, I verified the components using Avatar are working as expected)
[x] I verified all code is DRY (the PR doesn't include any logic written more than once, with the exception of tests)
[x] I verified any variables that can be defined as constants (ie. in CONST.js or at the top of the file that uses the constant) are defined as such
[x] I verified that if a function's arguments changed that all usages have also been updated correctly
[x] If a new component is created I verified that:

[x] A similar component doesn't exist in the codebase
[x] All props are defined accurately and each prop has a /** comment above it */
[x] The file is named correctly
[x] The component has a clear name that is non-ambiguous and the purpose of the component can be inferred from the name alone
[x] The only data being stored in the state is data necessary for rendering and nothing else
[x] If we are not using the full Onyx data that we loaded, I've added the proper selector in order to ensure the component only re-renders when the data it is using changes
[x] For Class Components, any internal methods passed to components event handlers are bound to this properly so there are no scoping issues (i.e. for onClick={this.submit} the method this.submit should be bound to this in the constructor)
[x] Any internal methods bound to this are necessary to be bound (i.e. avoid this.submit = this.submit.bind(this); if this.submit is never passed to a component event handler like onClick)
[x] All JSX used for rendering exists in the render method
[x] The component has the minimum amount of code necessary for its purpose, and it is broken down into smaller components in order to separate concerns and functions

[x] If any new file was added I verified that:

[x] The file has a description of what it does and/or why is needed at the top of the file if the code is not self explanatory

[x] If a new CSS style is added I verified that:

[x] A similar style doesn't already exist
[x] The style can't be created with an existing StyleUtils function (i.e. StyleUtils.getBackgroundAndBorderStyle(themeColors.componentBG))

[x] If the PR modifies code that runs when editing or sending messages, I tested and verified there is no unexpected behavior for all supported markdown - URLs, single line code, code blocks, quotes, headings, bold, strikethrough, and italic.
[x] If the PR modifies a generic component, I tested and verified that those changes do not break usages of that component in the rest of the App (i.e. if a shared library or component like Avatar is modified, I verified that Avatar is working as expected in all cases)
[x] If the PR modifies a component related to any of the existing Storybook stories, I tested and verified all stories for that component are still working as expected.
[x] If a new page is added, I verified it's using the ScrollView component to make it scrollable when more elements are added to the page.
[x] If the main branch was merged into this PR after a review, I tested again and verified the outcome was still expected according to the Test steps.
[x] I have checked off every checkbox in the PR author checklist, including those that don't apply to this PR.

Screenshots/Videos

Web

https://github.com/Expensify/App/assets/35476479/7042d520-6191-45ec-a61f-e7500077602e

Mobile Web - Chrome

https://github.com/Expensify/App/assets/35476479/18b32ced-0f47-4db1-86f2-930982117ca1

Mobile Web - Safari

https://github.com/Expensify/App/assets/35476479/c8ac4043-d972-4c82-b9fd-3c408c3cadb8

Desktop

https://github.com/Expensify/App/assets/35476479/85af0066-9e8b-4110-865a-f824b74f8634

iOS

https://github.com/Expensify/App/assets/35476479/1a8e88ac-e415-4e07-9149-b20d87daebcd

Android

https://github.com/Expensify/App/assets/35476479/b4ed49e6-1d62-4db7-836d-9207f23fe22c

Hi, @Santhosh-Sellavel
Can you please check my comment?

Sorry @multijump I missed submitting this yesterday!

Hi @Santhosh-Sellavel
I just updated the useLocalize instead of withLocalizeHoc also use useWindowDimensions instead of withDimensionHOC.
Please check.

Sorry @multijump I missed submitting this yesterday!

Hi, @Santhosh-Sellavel
Can you please consider my explains again?

Can you please resolve conflicts

Can you please resolve conflicts

Resolved conflicts
Please check again.
Thanks.

Lots of console errors please fix
https://github.com/Expensify/App/assets/85645967/cad8edf5-fc7a-4ed0-9fb2-23097af9cdfa

https://github.com/Expensify/App/assets/85645967/275d91ce-1dee-458c-80d7-de688ae245e5

Prototypes should be removed for Localize and window dimension changes

Removed unused propsType

Hi, @Santhosh-Sellavel
Can you please kindly check my comment?
Thanks

@multijump Can you resolve conflicts please

Sorry for the delay @multijump, Let's try to get this merged within a couple of days!

@multijump Can you resolve conflicts please

Hi, @Santhosh-Sellavel
Fixed conflict issues.
Thanks.

Ah Again conflicts

Ah Again conflicts

Fixed conflict again.
Thanks

Reviewer Checklist

[x] I have verified the author checklist is complete (all boxes are checked off).
[x] I verified the correct issue is linked in the ### Fixed Issues section above
[x] I verified testing steps are clear and they cover the changes made in this PR

[x] I verified the steps for local testing are in the Tests section
[x] I verified the steps for Staging and/or Production testing are in the QA steps section
[x] I verified the steps cover any possible failure scenarios (i.e. verify an input displays the correct error message if the entered data is not correct)
[x] I turned off my network connection and tested it while offline to ensure it matches the expected behavior (i.e. verify the default avatar icon is displayed if app is offline)

[x] I checked that screenshots or videos are included for tests on all platforms
[x] I included screenshots or videos for tests on all platforms
[x] I verified tests pass on all platforms & I tested again on:

[x] Android / native
[x] Android / Chrome
[x] iOS / native
[x] iOS / Safari
[x] MacOS / Chrome / Safari
[x] MacOS / Desktop

[x] If there are any errors in the console that are unrelated to this PR, I either fixed them (preferred) or linked to where I reported them in Slack
[x] I verified proper code patterns were followed (see Reviewing the code)

[x] I verified that any callback methods that were added or modified are named for what the method does and never what callback they handle (i.e. toggleReport and not onIconClick).
[x] I verified that the left part of a conditional rendering a React component is a boolean and NOT a string, e.g. myBool && <MyComponent />.
[x] I verified that comments were added to code that is not self explanatory
[x] I verified that any new or modified comments were clear, correct English, and explained "why" the code was doing something instead of only explaining "what" the code was doing.
[x] I verified any copy / text shown in the product is localized by adding it to src/languages/* files and using the translation method
[x] I verified all numbers, amounts, dates and phone numbers shown in the product are using the localization methods
[x] I verified any copy / text that was added to the app is grammatically correct in English. It adheres to proper capitalization guidelines (note: only the first word of header/labels should be capitalized), and is approved by marketing by adding the Waiting for Copy label for a copy review on the original GH to get the correct copy.
[x] I verified proper file naming conventions were followed for any new files or renamed files. All non-platform specific files are named after what they export and are not named "index.js". All platform-specific files are named for the platform the code supports as outlined in the README.
[ ] I verified the JSDocs style guidelines (in STYLE.md) were followed

[ ] If a new code pattern is added I verified it was agreed to be used by multiple Expensify engineers
[ ] I verified that this PR follows the guidelines as stated in the Review Guidelines
[ ] I verified other components that can be impacted by these changes have been tested, and I retested again (i.e. if the PR modifies a shared library or component like Avatar, I verified the components using Avatar have been tested & I retested again)
[x] I verified all code is DRY (the PR doesn't include any logic written more than once, with the exception of tests)
[x] I verified any variables that can be defined as constants (ie. in CONST.js or at the top of the file that uses the constant) are defined as such
[x] If a new component is created I verified that:

[x] A similar component doesn't exist in the codebase
[x] All props are defined accurately and each prop has a /** comment above it */
[x] The file is named correctly
[x] The component has a clear name that is non-ambiguous and the purpose of the component can be inferred from the name alone
[x] The only data being stored in the state is data necessary for rendering and nothing else
[x] For Class Components, any internal methods passed to components event handlers are bound to this properly so there are no scoping issues (i.e. for onClick={this.submit} the method this.submit should be bound to this in the constructor)
[x] Any internal methods bound to this are necessary to be bound (i.e. avoid this.submit = this.submit.bind(this); if this.submit is never passed to a component event handler like onClick)
[x] All JSX used for rendering exists in the render method
[x] The component has the minimum amount of code necessary for its purpose, and it is broken down into smaller components in order to separate concerns and functions

[x] If any new file was added I verified that:

[x] The file has a description of what it does and/or why is needed at the top of the file if the code is not self explanatory

[x] If a new CSS style is added I verified that:

[x] A similar style doesn't already exist
[x] The style can't be created with an existing StyleUtils function (i.e. StyleUtils.getBackgroundAndBorderStyle(themeColors.componentBG)

[x] If the PR modifies code that runs when editing or sending messages, I tested and verified there is no unexpected behavior for all supported markdown - URLs, single line code, code blocks, quotes, headings, bold, strikethrough, and italic.
[x] If the PR modifies a generic component, I tested and verified that those changes do not break usages of that component in the rest of the App (i.e. if a shared library or component like Avatar is modified, I verified that Avatar is working as expected in all cases)
[x] If the PR modifies a component related to any of the existing Storybook stories, I tested and verified all stories for that coxmponent are still working as expected.
[x] If a new page is added, I verified it's using the ScrollView component to make it scrollable when more elements are added to the page.
[x] If the main branch was merged into this PR after a review, I tested again and verified the outcome was still expected according to the Test steps.
[ ] I have checked off every checkbox in the PR reviewer checklist, including those that don't apply to this PR.

Screenshots/Videos

Web & Desktop
https://github.com/Expensify/App/assets/85645967/0f5e665a-f693-4b4e-80a1-263a600bad2c

Mobile Web - Chrome & Mobile Web - Safari
Couldn't able to test

iOS & Android
https://github.com/Expensify/App/assets/85645967/0c2a5265-e057-4abe-8937-4d9fdaf66c50

Hi, @MonilBhavsar
This will work as offline test?
Thanks.
https://github.com/Expensify/App/assets/35476479/8675d30e-60ba-4fe1-89fb-53790517ca5a

Sorry, could you please describe the test. Sorry, what is hovering off over the button triggering?

Actually, the wallet is hidden behind the beta. So they might have missed it.
Offline Steps:

Open Setting Page
Go Offline
Verify wallet balance & Add Payment button is disabled
Go Online
Verify Loading is shown for wallet balance and right balance is updated
Verify Add Payment button is enabled

Does this look good for you @MonilBhavsar ?

cc: @multijump Please update the steps thanks!

Yes, that works for me. Thanks! Can we also please test it

cc: @multijump Please update the steps thanks!

bump @multijump

Yes, that works for me. Thanks! Can we also please test it

I've already tested this, worked well!

cc: @multijump Please update the steps thanks!

Sorry for late @Santhosh-Sellavel
I updated the offline test steps.
And I can test only payment button disabled.
attached screen record for it.
Thanks.
https://github.com/Expensify/App/assets/35476479/8675d30e-60ba-4fe1-89fb-53790517ca5a

:hand: This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release.

Looks like we have a regression. @multijump could you please comment in this slack thread https://expensify.slack.com/archives/C049HHMV9SM/p1690547253119529?thread_ts=1690546771.892759&cid=C049HHMV9SM

🚀 Deployed to staging by https://github.com/MonilBhavsar in version: 1.3.48-0 🚀

platform
result

🤖 android 🤖
success ✅

🖥 desktop 🖥
success ✅

🍎 iOS 🍎
success ✅

🕸 web 🕸
success ✅

🚀 Deployed to production by https://github.com/puneetlath in version: 1.3.48-5 🚀

platform
result

🤖 android 🤖
success ✅

🖥 desktop 🖥
success ✅

🍎 iOS 🍎
success ✅

🕸 web 🕸
success ✅

🚀 Deployed to staging by https://github.com/MonilBhavsar in version: 1.3.49-0 🚀

platform
result

🤖 android 🤖
success ✅

🖥 desktop 🖥
success ✅

🍎 iOS 🍎
success ✅

🕸 web 🕸
success ✅

🚀 Deployed to production by https://github.com/Beamanator in version: 1.3.49-3 🚀

platform
result

🤖 android 🤖
success ✅

🖥 desktop 🖥
success ✅

🍎 iOS 🍎
success ✅

🕸 web 🕸
success ✅


Ion-select i can’t get selected value

Demo.html
<ion-list>
  <ion-item>
    <ion-label class="ion-label”>label</ion-label>
    <ion-select  [ngModel]="selected_value" (ionChange)="showselected(selected_value)" [ngModelOptions]="{standalone: true}">
      <ion-option value="1"> item1</ion-option>
      <ion-option value="2"> item2</ion-option>
    </ion-select>
  </ion-item>
</ion-list>

Demo.ts
showselected(selected_value)
{
console.log("selector: ", selected_value );
}
ionic info
Cordova CLI: 6.3.0
Ionic Framework Version: 2.0.0-beta.11
Ionic CLI Version: 2.0.0-beta.32
Ionic App Lib Version: 2.0.0-beta.18
ios-deploy version: Not installed
ios-sim version: Not installed
OS: Mac OS X Yosemite
Node Version: v6.3.1
Hello , i have problem that i can't get selected value using (change), but when using (ionChange) it returns undefind value

Hello! This should be fixed now. Unfortunately we were not specifying the exact version of @angular/forms in our package.json or our npm install command in the update instructions which causes an newer version of @angular/forms that does not support Angular 2 rc4 to be installed. To fix this you may have to go into your package.json and change the @angular/forms listing to<EMAIL_ADDRESS>and then run npm install. Thanks for using Ionic!


Popover button

Gives an error, no btn.
show = () => {     super._show();     const { options, btn } = this;     if (options.dismissible && btn) setTimeout(() => focus(btn), 17);   };

Please provide a test fiddle or something, I will fix this with the next release. Thanks

@websceneru
I figured out the problem, will be fixed with next commit.

@websceneru please test latest v5.0.5.
Thanks


Don't write a finishing newline in silent mode

Description
When running ffuf in silent mode, a new line is still written on every line at the end of a run of ffuf.
While this looks fine if there are any matches, it will just spam empty new lines whenever:

No matches are found
If you redirect stdout but keep stderr on console

Piping ffuf multiple times with different targets, this approx. looks like this:
https://github.com/ffuf/ffuf/assets/26608194/6194f5ec-8e51-496a-9149-68b04cc87658
Thus, let's remove printing the new line when in silent mode.
Additonally

[ ] If this is the first time you are contributing to ffuf, add your name to CONTRIBUTORS.md.
The file should be alphabetically ordered.
[ ] Add a short description of the fix to CHANGELOG.md

-> I skipped since I thought this change is too insignificant.

Thanks for the PR, merging


Running into issues computing indices with loc

Describe the issue:
Running into errors when trying to compute indices on df's sliced with loc
Minimal Complete Verifiable Example:
pdf = pd.DataFrame({"a":[1,2,3],"b":[4,5,6]})
df = dd.from_pandas(pdf, 2)
df.loc[2].index.compute()

     50 if cindexer is None:
---> 51     return df.loc[iindexer]
     52 else:
     53     return df.loc[iindexer, cindexer]

AttributeError: 'tuple' object has no attribute 'loc'

Anything else we need to know?:
Other combinations of loc that touch the first partition seem to work without issues:
df.loc[1].index.compute() # works
df.loc[1:3].index.compute() # works
df.loc[2:].index.compute() # fails

Environment:

Dask version: 2024.4.0
Dask expr version: 1.0.9
Python version: 3.10
Operating System: ubuntu
Install method (conda, pip, source): pip
Pandas version: 2.2.1

Thx for the report, put up a pr to fix

I pushed out a release with a fix. It's already on pypi and will be on conda forge soon


add attach_fn

Current dependencies on/for this PR:

main

PR #66   👈

This stack of pull requests is managed by Graphite.

Merge activity

Feb 6, 11:44 PM EST: @willseltzer merged this pull request with Graphite.


code release

Thanks for your nick work! When will the code be available?

It is available now. Thank you for checking!


Missing headings level names

The headings level names are missing:
Heading      Default      Treesitter
-----------------------------------------
  # Level 1  markdownH1   markdownTSTitle
 ## Level 2  markdownH2   markdownTSTitle
### Level 3  markdownH3   markdownTSTitle
...
-----------------------------------------

Implementing the levels would significantly improve the readability via color schemes.
This module is amazing, and the H levels would make it even more spectacular.
❤

This is more of a limitation of nvim-treesitter, which does not offer enough captures (and highlight groups) to distinguish them, even if there's a node for it.
(Nvim-treesitter is more centralized than legacy regex syntax highlighting, where every language was allowed to define whatever highlight groups it wanted without concern for others. While this leads to a more consistent highlighting for standard programming languages, it restricts the possibilities for other types of languages.)

Exactly, the level names are actually emitted as nodes. But if you want you add custom highlight captures as described in the nvim-treesitter README. E.g. add
[
  (atx_heading
    (atx_h1_marker))
  (setext_heading
    (setext_h1_underline))
] @text.title1

to markdowns highlights.scm and
lua <<EOF
  require"nvim-treesitter.highlight".set_custom_captures {
    ["text.title1"] = "markdownH1",
  }
EOF

to your config.


doc: guidelines: ask to use full url for bug numbers

The commit guideline currently asks to add references to issue numbers in the commits by specificing the issue number alone. This is meaningless once the repository is forked, reword the guideline to explicitly ask for a full URL.

https://builds.zephyrproject.io/zephyr/pr/72371/docs/contribute/guidelines.html#commit-message-body

+1, but I wonder If it would be acceptable to encourage the use of the shorter zephyrproject-rtos/zephyr#123456 form?

The problem is that people use these reference to avoid having to write the whole context in the commit message, which you'll inevitably need once you find that the fix broke something else, so I'd rather be a proper link.
Honestly I'd rather tell people to write some proper context in the commit message so that these tags are not needed in the first place, and just go for the short one in the PR comment (rather than the commit message), but this is a step forward.

+1, but I wonder If it would be acceptable to encourage the use of the shorter zephyrproject-rtos/zephyr#123456 form?

The problem is that people use these reference to avoid having to write the whole context in the commit message, which you'll inevitably need once you find that the fix broke something else, so I'd rather be a proper link.
Honestly I'd rather tell people to write some proper context in the commit message so that these tags are not needed in the first place, and just go for the short one in the PR comment (rather than the commit message), but this is a step forward.

Not sure how this answer is related to the suggestion, why not zephyrproject-rtos/zephyr#123456 instead of the full URL?

This is meaningless once the repository is forked...

Do not fork.....
almost 100k commit in and mostly using the short format and that is the first time I see this being raised as a "problem". It is so convinient to just add the number and not worry about long URLs (and getting them right unless you copy/paste them) in commit message.

Not sure how this answer is related to the suggestion, why not zephyrproject-rtos/zephyr#123456 instead of the full URL?

Because you can't use that without the full URL? This git log thing.

Do not fork.....

Are we moving off Git as well?
https://github.com/zephyrproject-rtos/zephyr/commit/ba6142050493eb5f6b0f1233cf4a313eb4d162b5 works
https://github.com/nrfconnect/sdk-zephyr/commit/ba6142050493eb5f6b0f1233cf4a313eb4d162b5 does not work
Why not make them work?

almost 100k commit in and mostly using the short format and that is the first time I see this being raised as a "problem". It is so convinient to just add the number and not worry about long URLs (and getting them right unless you copy/paste them) in commit message.

Empty messages are also convenient but we block them...

need to hear about what happens if someone adds short form instead of long URL, are we going to block PRs because of this?

Oh yeah, I do it all the time.

Is this going to be enforced in some way at some point?

Ideally.

Not sure I support this. Zephyr is Zephyr, and there is only one upstream.

Sorry I'm not talking fork in the zephyr-ng sense, rather in the git clone or GitHub "fork" button sense. All these references are lost, see the examples above.

Sorry I'm not talking forks in the zephyr-ng sense, rather in the git clone or GitHub "fork" button sense. All these references are lost, see the examples above. Of the same commit in the same repo in two different orgs, I mean this does not even work coherently within GitHub.

I get that, but I tend to agree with @nashif - 100k commits in, first time I've heard this being mentioned as a problem.

I get that, but I tend to agree with @nashif - 100k commits in, first time I've heard this being mentioned as a problem.

Yeah, sadly the whole GitHub story does not give you much in term of commit hygiene control, you can't even put a comment on message commits, I imagine most people don't bother reviewing them just for that reason, can't blame them.

Sorry I'm not talking forks in the zephyr-ng sense, rather in the git clone or GitHub "fork" button sense. All these references are lost, see the examples above. Of the same commit in the same repo in two different orgs, I mean this does not even work coherently within GitHub. Am I using the wrong term?
DESCRIPTION
       Clones a repository into a newly created directory, creates
       remote-tracking branches for each branch in the cloned repository
       (visible using git branch --remotes), and creates and checks out an
       initial branch that is forked from the cloned repository’s currently
       active branch.

Maybe I'm using the wrong term.

but this is exactly where it is not a problem:
https://github.com/nashif/zephyr/commit/ed9a983837b8503d5134b9e491f6ab08b1451631
This is my fork
That same commit:
commit ed9a983837b8503d5134b9e491f6ab08b1451631
Author: Jukka Rissanen<EMAIL_ADDRESS>Date:   Thu Aug 9 09:34:38 2018 +0300

    net: ipv6: Initial support for privacy extension

    This creates support for IPv6 privacy extensions which is described
    in RFC 8981. This will also add API that can be used to add IPv6
    prefixes to a allow or deny list privacy extension filter.

    The code will create temporary IPv6 addresses from prefixes that
    are advertised by Router Advertisement messages. The temporary
    IPv6 addresses are then expired according to lifetime and removed.

    Fixes #9349

    Signed-off-by: Jukka Rissanen<EMAIL_ADDRESS>
so github links correctly to the issue.
There is no problem with forks.

For some reason, I seem to remember that we were told not to put GitHub issue references into commit messages.
I guess it's the opposite now?
Adding the message in the PR description works as well.

References to bugs fixes was never meant to replace a detailed commit message, it is meant to provide some form of traceability and having it in commit messages is very useful IMO. You read the commit message and have a reference to go look at for more details about the bug and so on.
I am all for documenting the need for detailed commit messages and enforcing this. However, this PR is about references that are autolinked in the main repo and its fork but is just a number when you look at the commit message on the command line or in "disconnected forks" that are not on github. But we are transfering the burdon to 100s of developers and making our commit message cluttered with URLs for the sake of few forks out of github? Does this make sense? I mean, if you work with a Zephyr fork and see a number, how difficult it is to go to the project page and paste the number in the search to get more details about the bug? why does it need to be linked in commit messages?

References to bugs fixes was never meant to replace a detailed commit message, it is meant to provide some form of traceability and having it in commit messages is very useful IMO

Yeah I blocked a "Fix issue #x EOM" commit recently, and that's why I ended here. Having a reference in the commit message can certainly be useful, but I find there's value in doing it with full URL, ideally using "Link" tags, as it's done all the time in kernel.org (you can git log --grep "Link: https://github.com/")

But we are transfering the burdon to 100s of developers and making our commit message cluttered with URLs for the sake of few forks out of github? Does this make sense? I mean, if you work with a Zephyr fork and see a number, how difficult it is to go to the project page and paste the number in the search to get more details about the bug? why does it need to be linked in commit messages?

Is it that much more work to copypaste the whole URL rather than just the number?
Anyway, the PR in this form is really a watered down version of what I originally wanted, and @stephanosio comment (which I very much resonate with) made me realize that I'm not happy with it anyway, so let's not waste any more time on it.
I'm probably better off preparing a canned message for commit with non descriptive changes, which at the end of the day is really what bothers me rather than unclickable midly inconvenient links.

References to bugs fixes was never meant to replace a detailed commit message, it is meant to provide some form of traceability and having it in commit messages is very useful IMO

Yeah I blocked a "Fix issue #x EOM" commit recently, and that's why I ended here. Having a reference in the commit message can certainly be useful, but I find there's value in doing it with full URL, ideally using "Link" tags, as it's done all the time in kernel.org (you can git log --grep "Link: https://github.com/")

But we are transfering the burdon to 100s of developers and making our commit message cluttered with URLs for the sake of few forks out of github? Does this make sense? I mean, if you work with a Zephyr fork and see a number, how difficult it is to go to the project page and paste the number in the search to get more details about the bug? why does it need to be linked in commit messages?

Is it that much more work to copypaste the whole URL rather than just the number?
Anyway, the PR in this form is really a watered down version of what I originally wanted, and @stephanosio comment (which I very much resonate with) made me realize that I'm not happy with it anyway, so let's not waste any more time on it.
I'm probably better off preparing a canned message for commit with non descriptive changes, which at the end of the day is really what bothers me rather than unclickable midly inconvenient links.


Laravel mix not compiling vue components

Laravel Mix Version: 5.4.* (npm list --depth=0)
Node Version 8.11.1 (node -v):
NPM Version 6.0.0 (npm -v):
OS:

Description:
I had an old project that used Laravel 5.3 and I recently upgraded it to Laravel 5.4 I updated my composer.json file to get Laravel 5.4, and I followed the upgrade guided for 5.4 Then, I created a package.json file and npm install. My node modules were installed. Next, I run npm run dev, and the JavaScript compiles, however, the Vue component which I am sure I have mounted never gets compiled.
I have created a fresh install of Laravel and tried compiling the component, and it works. However, I need the component to work in my old project. Were there ny steps I missed when installing mix?
Steps To Reproduce:

Update from Laravel 5.3 to 5.4
Create package.json file
3 run npm install
run npm run dev

Just my two cent here but, could you check if you're using vue-loader 15.x or vue-loader 14.x currently?
It seems vue-loader 15.x is not handled yet by laravel mix, at least you have to manually tweak the config.
Kind regards.

If someone can give me reproducible steps, I’ll take a look. But I can’t reproduce this on my end.

I bumped into the same issue. I fixed it by adding .default when requiring single file components, according to recent changes in Laravel: https://github.com/laravel/laravel/blob/master/resources/js/app.js
Example:
Vue.component('example-component', require('./components/ExampleComponent.vue'));

becomes
Vue.component('example-component', require('./components/ExampleComponent.vue').default);

Found the same issue today and @joaomnb  .default Fixed it thanks

@joaomnb thank you so much this helped me resolved my issue. I want to learn why the .default fixed it. Can you point me in the direction of learning the inner workings?
Thanks in advance

Hi @j3rg, sure. This is due to vue-loader moving from the older CommonJS module syntax, module.exports = {...}, to the newer ES6 module syntax export default {...}.
So, the error was caused because we were now attempting to import an ES6 module using the require() method, which is CommonJS syntax. There are (at least) two ways of fixing the code:
The one I posted above, changing require(...) to require(...).default – which is kind of a "hack", since we are now mixing the two syntaxes.
And a probably better solution, that I hadn't understood yet when I posted, which is adopting the ES6 way of importing modules... So this:
Vue.component('example-component', require('./components/ExampleComponent.vue'));

becomes this:
import ExampleComponent from './components/ExampleComponent.vue';
Vue.component('example-component', ExampleComponent);

I hope that is clear enough! 😄


feat: Sync from noir

Automated pull of development from the noir programming language, a dependency of Aztec.
BEGIN_COMMIT_OVERRIDE
fix: Change panic to error in interpreter (https://github.com/noir-lang/noir/pull/5446)
feat: Add more slice methods to the stdlib (https://github.com/noir-lang/noir/pull/5424)
feat: Unquote multiple items from annotations (https://github.com/noir-lang/noir/pull/5441)
chore: move SSA checks to a new folder (https://github.com/noir-lang/noir/pull/5434)
feat: lsp rename/find-all-references for type aliases (https://github.com/noir-lang/noir/pull/5414)
chore: dummy workflow (https://github.com/noir-lang/noir/pull/5438)
chore: refactor logic around inlining no_predicates functions (https://github.com/noir-lang/noir/pull/5433)
chore: extracts refactoring of reading error payloads from #5403 (https://github.com/noir-lang/noir/pull/5413)
fix: lsp struct rename/reference difference (https://github.com/noir-lang/noir/pull/5411)
chore: merge BarretenbergVerifierBackend and BarretenbergBackend (https://github.com/noir-lang/noir/pull/5399)
feat: Sync from aztec-packages (https://github.com/noir-lang/noir/pull/5432)
END_COMMIT_OVERRIDE

Benchmark results
Metrics with a significant change:

proof_construction_time_sha256_100_ms (16): 5,449 (-17%)
avm_simulation_time_ms (Token:mint_public): 49.4 (-86%)
avm_simulation_time_ms (Token:transfer_public): 52.6 (+31%)

Detailed results
All benchmarks are run on txs on the Benchmarking contract on the repository. Each tx consists of a batch call  to create_note and increment_balance, which guarantees that each tx has a private call, a nested private call, a public call, and a nested public call, as well as an emitted private note, an unencrypted log, and public storage read and write.
This benchmark source data is available in JSON format on S3 here.
Proof generation
Each column represents the number of threads used in proof generation.

Metric
1 threads
4 threads
16 threads
32 threads
64 threads

proof_construction_time_sha256_ms
5,714
1,540
700 (-1%)
782 (+3%)
767

proof_construction_time_sha256_30_ms
11,728
3,139
1,403
1,433
1,458

proof_construction_time_sha256_100_ms
43,857
11,746
:warning: 5,449 (-17%)
5,401
5,354

proof_construction_time_poseidon_hash_ms
78.0
34.0
34.0
59.0 (+2%)
89.0 (+2%)

proof_construction_time_poseidon_hash_30_ms
1,515
416 (-1%)
200
228 (+2%)
267 (-1%)

proof_construction_time_poseidon_hash_100_ms
5,729 (+3%)
1,574 (+4%)
724 (+7%)
774 (+8%)
791 (+6%)

L2 block published to L1
Each column represents the number of txs on an L2 block published to L1.

Metric
4 txs
8 txs
16 txs

l1_rollup_calldata_size_in_bytes
1,412
1,412
1,412

l1_rollup_calldata_gas
9,476
9,474
9,464

l1_rollup_execution_gas
613,504
613,653
613,794

l2_block_processing_time_in_ms
757
1,427 (+1%)
2,706 (-1%)

l2_block_building_time_in_ms
12,918 (-1%)
25,451 (-1%)
49,792 (-1%)

l2_block_rollup_simulation_time_in_ms
12,917 (-1%)
25,451 (-1%)
49,792 (-1%)

l2_block_public_tx_process_time_in_ms
10,865 (-1%)
23,225 (-1%)
47,573 (-1%)

L2 chain processing
Each column represents the number of blocks on the L2 chain where each block has 8 txs.

Metric
3 blocks
5 blocks

node_history_sync_time_in_ms
7,062 (+1%)
9,995

node_database_size_in_bytes
12,439,632
16,203,856

pxe_database_size_in_bytes
16,254
26,813

Circuits stats
Stats on running time and I/O sizes collected for every kernel circuit run across all benchmarks.

Function
time_ms
bytecode_size_in_bytes

GasToken:_increase_public_balance
82.5 (+3%)
13,790

GasToken:set_portal
13.3 (-13%)
3,339

Token:constructor
102
23,692

FPC:constructor
75.0 (+3%)
13,592

GasToken:mint_public
62.8
10,158

Token:mint_public
:warning: 49.4 (-86%)
19,034

Token:assert_minter_and_mint
70.3 (+11%)
12,925

AuthRegistry:set_authorized
33.4 (-3%)
7,812

FPC:prepare_fee
101 (-2%)
15,062

Token:transfer_public
:warning: 52.6 (+31%)
31,218

FPC:pay_refund
131 (+4%)
25,260

Benchmarking:increment_balance
1,310 (-1%)
15,267

Token:_increase_public_balance
14.9 (-1%)
15,006

FPC:pay_refund_with_shielded_rebate
163 (+1%)
26,347

Public DB Access
Time to access various public DBs.

Function
time_ms

get-nullifier-index
0.161 (+4%)

Tree insertion stats
The duration to insert a fixed batch of leaves into each tree type.

Metric
1 leaves
16 leaves
64 leaves
128 leaves
256 leaves
512 leaves
1024 leaves

batch_insert_into_append_only_tree_16_depth_ms
10.5 (+1%)
16.8 (+1%)
N/A
N/A
N/A
N/A
N/A

batch_insert_into_append_only_tree_16_depth_hash_count
16.8
31.7
N/A
N/A
N/A
N/A
N/A

batch_insert_into_append_only_tree_16_depth_hash_ms
0.605 (+1%)
0.517 (+1%)
N/A
N/A
N/A
N/A
N/A

batch_insert_into_append_only_tree_32_depth_ms
N/A
N/A
48.2
75.8
131
247 (+1%)
469

batch_insert_into_append_only_tree_32_depth_hash_count
N/A
N/A
95.9
159
287
543
1,055

batch_insert_into_append_only_tree_32_depth_hash_ms
N/A
N/A
0.492
0.466
0.450
0.447 (+1%)
0.438

batch_insert_into_indexed_tree_20_depth_ms
N/A
N/A
59.4
111
183 (+1%)
355 (+1%)
691

batch_insert_into_indexed_tree_20_depth_hash_count
N/A
N/A
109
207
355
691
1,363

batch_insert_into_indexed_tree_20_depth_hash_ms
N/A
N/A
0.501 (-1%)
0.499
0.484
0.481 (+1%)
0.474

batch_insert_into_indexed_tree_40_depth_ms
N/A
N/A
73.0
N/A
N/A
N/A
N/A

batch_insert_into_indexed_tree_40_depth_hash_count
N/A
N/A
133
N/A
N/A
N/A
N/A

batch_insert_into_indexed_tree_40_depth_hash_ms
N/A
N/A
0.519
N/A
N/A
N/A
N/A

Miscellaneous
Transaction sizes based on how many contract classes are registered in the tx.

Metric
0 registered classes
1 registered classes

tx_size_in_bytes
74,090
667,873

Transaction size based on fee payment method
| Metric |  |
| - |  |


process masked token the same way

Proposed changes:

process golden tokens the same way we process other tokens in mask loss

Status (please check what you already did):

[ ] added some tests for the functionality
[ ] updated the documentation
[ ] updated the changelog (please check changelog for instructions)
[x] reformat files using black (please check Readme for instructions)

You just renamed some variables, this is not reflected in the description. Do I miss something?
Also you might want to branch of from 1.8.x to get it into the next patch release.

yes, but by renaming these variables, I removed intermediate x meaning that the golden token input becomes the one after ffnn layer, which is technically a breaking change (that no-one will notice)


Adds the rate limiting plugin. Closes #210

Adds the rate limiting plugin. Closes #210
Plugin is disabled by default because it works only when mocking and random errors are disabled. We can provide specific presets after we've done #228

@garrytrinder, after we merge this, let's ensure we add it to the docs

I'd love if we make this default for Graph endpoints. ODSP is using those all over the place and I feel this drives a lot of value over there. I'd love a developer to go on and test their code without having to change the config for this scenario.

Given that rate limiting works when chaos is disabled, I suggest that we start thinking about including some scenario-based presets that are ready to use. That way, we could offer preconfigured settings for the different APIs and scenarios that we want to test, without offloading it all to our customers.

Good idea!


Useful changes for more extensibility

renamed ImageViewer.scss to build.scss
moved all SCSS files to scss/
introduced new variables.scss
updated the example.html files
introduced listeners
introduced zoom buttons

Hey @monajjar1. Thanks for the PR. The changes look perfect. I wanted to check if you will be willing to maintain this library. If yes, I will add you as the core contributor with all the rights and add you on the npm to publish.

Hey @monajjar1. Thanks for the PR. The changes look perfect. I wanted to check if you will be willing to maintain this library. If yes, I will add you as the core contributor with all the rights and add you on the npm to publish.

Got no problem with that at all

Great to know that. 🙂

I have sent you an invite. Let's connect over email if you have any questions on this.

I have sent you an invite. Let's connect over email if you have any questions on this.

Sure thing


[MM-19856] Add back button when navigating outside of the mattermost team within the app

Before submitting, please confirm you've

[x] executed npm run lint:js for proper code formatting

Please provide the following information:
Summary
Provide an extra bar with a back option to go back in history. This bar only appears when the app navigates outside of a mattermost team.
Issue link
MM-19856
Test Cases

logout from the community-* server
login using onelogin
expected:

extra bar appears

clicking on back
expected:

takes you to the previous screen (login in this case)  and it disappears

completing the login process
expected:

takes you to the team and the bar disappears

** Additional notes **

Added awesome font to render the back symbol
fixed a but on isTeamURL, we weren't checking the origin on it relying on previous checks to work.

For some reason, I thought I should have a dark/clear version. Sorry about that.
I've matched the one from Password reset, bar is now about 36, added button.
I left the logic for clear/dark version in just in case we want to use that in the future, it just doesn't do anything with css.

I did try the open sans family, but it looked way worse, like bolded even though it was normal, I'll review that again just in case I can make it to work.

@Willyfrog or @deanwhillier will you post screenshots or a link to the build I can download and test, thanks guys!

link to artifacts on the build: https://app.circleci.com/jobs/github/mattermost/desktop/5481/artifacts,
I'll DM  a video, I can't post it here

Force pushed as there was a lot of files from master being re-added


Create a version catcher

Create/augment existing gha to check latest version of dbt-core to update scaffold of project structure and keep adapter plugin start point within step bounds of core.
co-author @kwigley

@McKnight-42 can you change the base branch of this to make it easier to see the diff?

@kwigley great catch.

wanted to move https://github.com/dbt-labs/dbt-database-adapter-scaffold/pull/24#issuecomment-1100389318 over to here as its still a open topic.


Hard to debug slow consumers

Want a better way to debug slow consumers, possible send client identifier in INFO message which can then be used for a closure on logs? Maybe do async notifications.

Imo log is simplest.  One could watch the /varz slow_consumers to bump and check out the the logs when it does.
That being said, another option could be to add to /connz.  Something like a slow_consumers array with a subject and a count, name is there.  Not great to hold the state, but imo would provide better info for triggering alerts in something like Prometheus.
  "connections": [
    {
      "cid": 2,
      "ip": "::1",
      "port": 58239,
      ...
      "subscriptions": 1,
      "name": "nats-sub",
      "lang": "go",
      "version": "1.3.1",
      "subscriptions_list": [
        "global.alert"
      ]
      "slow_consumers": [
        "global.alert" : 2
      ]
    }
  ]

I have been thinking about it, possibly have a /slowz which can be an array of slow consumer events with time, client id etc.

Closing this since more info in #520.


Track VSTGUI 4.12.3

The current development version creates corruption on multiple platforms (#1004, sfztools/sfizz#1005). It's set at 4.10.2 in 1.1.1, but we have interest in tracking the upstream version when it becomes stable.

merged in aaacd14


running main.js and BAD REQUEST encountered

I have installed the caliper package and dependencies are installed.
I did not modify anything either in the config.json file or in the fabric.json file.
Then I simply run
node benchmark/simple/main.js -c config.json
and I met the following error:
# create mychannel......
error: [Orderer.js]: sendBroadcast - on error: "Error: 14 UNAVAILABLE: EOF\n    at createStatusError (/Users/starry/caliper/node_modules/fabric-client/node_modules/grpc/src/client.js:64:15)\n    at Client
DuplexStream._emitStatusIfDone (/Users/starry/caliper/node_modules/fabric-client/node_modules/grpc/src/client.js:270:19)\n    at ClientDuplexStream._receiveStatus (/Users/starry/caliper/node_modules/fabri
c-client/node_modules/grpc/src/client.js:248:8)\n    at /Users/starry/caliper/node_modules/fabric-client/node_modules/grpc/src/client.js:804:12"
not ok 1 Failed to create channels Error: SERVICE_UNAVAILABLE at ClientDuplexStream.<anonymous> (/Users/starry/caliper/node_modules/fabric-client/lib/Orderer.js:138:21) at emitOne (events.js:116:13) at Cl
ientDuplexStream.emit (events.js:211:7) at ClientDuplexStream._emitStatusIfDone (/Users/starry/caliper/node_modules/fabric-client/node_modules/grpc/src/client.js:271:12) at ClientDuplexStream._receiveStat
us (/Users/starry/caliper/node_modules/fabric-client/node_modules/grpc/src/client.js:248:8) at /Users/starry/caliper/node_modules/fabric-client/node_modules/grpc/src/client.js:804:12
  ---
    operator: fail
    at: channels.reduce.then.then.catch (/Users/starry/caliper/src/fabric/create-channel.js:160:19)
    stack: |-
      Error: Failed to create channels Error: SERVICE_UNAVAILABLE
          at ClientDuplexStream.<anonymous> (/Users/starry/caliper/node_modules/fabric-client/lib/Orderer.js:138:21)
          at emitOne (events.js:116:13)
          at ClientDuplexStream.emit (events.js:211:7)
          at ClientDuplexStream._emitStatusIfDone (/Users/starry/caliper/node_modules/fabric-client/node_modules/grpc/src/client.js:271:12)
          at ClientDuplexStream._receiveStatus (/Users/starry/caliper/node_modules/fabric-client/node_modules/grpc/src/client.js:248:8)
          at /Users/starry/caliper/node_modules/fabric-client/node_modules/grpc/src/client.js:804:12
          at Test.assert [as _assert] (/Users/starry/caliper/node_modules/tape/lib/test.js:224:54)
          at Test.bound [as _assert] (/Users/starry/caliper/node_modules/tape/lib/test.js:76:32)
          at Test.fail (/Users/starry/caliper/node_modules/tape/lib/test.js:317:10)
          at Test.bound [as fail] (/Users/starry/caliper/node_modules/tape/lib/test.js:76:32)
          at channels.reduce.then.then.catch (/Users/starry/caliper/src/fabric/create-channel.js:160:19)
          at <anonymous>
          at process._tickCallback (internal/process/next_tick.js:188:7)
  ...
fabric.init() failed, Error: Fabric: Create channel failed
    at channels.reduce.then.then.catch (/Users/starry/caliper/src/fabric/create-channel.js:161:31)
    at <anonymous>
    at process._tickCallback (internal/process/next_tick.js:188:7)
not ok 2 TypeError: Cannot read property 'getUpdates' of undefined
  ---
    operator: error
    expected: |-
      undefined
    actual: |-
      [TypeError: Cannot read property 'getUpdates' of undefined]
    at: process.onetime (/Users/starry/caliper/node_modules/tape-promise/node_modules/onetime/index.js:22:12)
    stack: |-
      TypeError: Cannot read property 'getUpdates' of undefined
          at update (/Users/starry/caliper/src/gui/src/demo.js:145:26)
          at Object.demoStopWatch [as stopWatch] (/Users/starry/caliper/src/gui/src/demo.js:185:5)
          at startPromise.then.then.then.then.then.then.catch (/Users/starry/caliper/src/comm/bench-flow.js:347:18)
          at <anonymous>
          at process._tickCallback (internal/process/next_tick.js:188:7)

I have seen a closed issue mentioned the BAD REQUEST problem, which has feedback that the problem might be caused by the version of fabric.
However, since i did not modify the fabric.json file, and it is configured as network/fabric/simplenetwork/cryto-config
I am wondering whether this configure is ok, if it is not ok why it occurs in the default version of the config files. If it is ok, then what causes the aforementioned error?

i have a same error

I also have the same error. The channel does not start up and I get the BAD_REQUEST.

same error...
create mychannel......
not ok 1 Failed to create channels Error: create status is BAD_REQUEST at channel.organizations.reduce.then.then.then (/opt/caliper/src/fabric/create-channel.js:146:43) at  at process._tickCallback (internal/process/next_tick.js:188:7)
operator: fail
at: channels.reduce.then.then.catch (/opt/caliper/src/fabric/create-channel.js:160:19)
stack: |-
  Error: Failed to create channels Error: create status is BAD_REQUEST
      at channel.organizations.reduce.then.then.then (/opt/caliper/src/fabric/create-channel.js:146:43)
      at <anonymous>
      at process._tickCallback (internal/process/next_tick.js:188:7)
      at Test.assert [as _assert] (/opt/caliper/node_modules/tape/lib/test.js:224:54)
      at Test.bound [as _assert] (/opt/caliper/node_modules/tape/lib/test.js:76:32)
      at Test.fail (/opt/caliper/node_modules/tape/lib/test.js:317:10)
      at Test.bound [as fail] (/opt/caliper/node_modules/tape/lib/test.js:76:32)
      at channels.reduce.then.then.catch (/opt/caliper/src/fabric/create-channel.js:160:19)
      at <anonymous>
      at process._tickCallback (internal/process/next_tick.js:188:7)

...
fabric.init() failed, Error: Fabric: Create channel failed
at channels.reduce.then.then.catch (/opt/caliper/src/fabric/create-channel.js:161:31)
at
at process._tickCallback (internal/process/next_tick.js:188:7)
not ok 2 TypeError: Cannot read property 'getUpdates' of undefined
operator: error
expected: |-
  undefined
actual: |-
  [TypeError: Cannot read property 'getUpdates' of undefined]
at: process.onetime (/opt/caliper/node_modules/tape-promise/node_modules/onetime/index.js:22:12)
stack: |-
  TypeError: Cannot read property 'getUpdates' of undefined
      at update (/opt/caliper/src/gui/src/demo.js:145:26)
      at Object.demoStopWatch [as stopWatch] (/opt/caliper/src/gui/src/demo.js:185:5)
      at startPromise.then.then.then.then.then.then.catch (/opt/caliper/src/comm/bench-flow.js:347:18)
      at <anonymous>
      at process._tickCallback (internal/process/next_tick.js:188:7)

...
1..2
tests 2
pass  0
fail  2

i have a same error too

@starrycheng @lotty02cho @zsh122958 @EG-easy @Miraczpp @Ryan-Ouyang @jamievaravara
Can you please provide the logs of the orderer node after you encountered the error? (as a GitHub gist preferably)
It is possible, that the orderer is not ready yet to serve the request. In this case, remove the start script from the config, start the network manually, wait a few more seconds, then execute the benchmark.

Here is my orderer logs.
$ docker container logs orderer.example.com
2018-12-03 01:54:50.138 UTC [localconfig] completeInitialization -> INFO 001 Kafka.Version unset, setting to <IP_ADDRESS>
2018-12-03 01:54:50.160 UTC [orderer/common/server] prettyPrintStruct -> INFO 002 Orderer config values:
	General.LedgerType = "file"
	General.ListenAddress = "<IP_ADDRESS>"
	General.ListenPort = 7050
	General.TLS.Enabled = true
	General.TLS.PrivateKey = "/var/hyperledger/orderer/tls/server.key"
	General.TLS.Certificate = "/var/hyperledger/orderer/tls/server.crt"
	General.TLS.RootCAs = [/var/hyperledger/orderer/tls/ca.crt]
	General.TLS.ClientAuthRequired = false
	General.TLS.ClientRootCAs = []
	General.Keepalive.ServerMinInterval = 1m0s
	General.Keepalive.ServerInterval = 2h0m0s
	General.Keepalive.ServerTimeout = 20s
	General.GenesisMethod = "file"
	General.GenesisProfile = "SampleInsecureSolo"
	General.SystemChannel = "test-system-channel-name"
	General.GenesisFile = "/var/hyperledger/orderer/orderer.genesis.block"
	General.Profile.Enabled = false
	General.Profile.Address = "<IP_ADDRESS>:6060"
	General.LogLevel = "INFO"
	General.LogFormat = "%{color}%{time:2006-01-02 15:04:05.000 MST} [%{module}] %{shortfunc} -> %{level:.4s} %{id:03x}%{color:reset} %{message}"
	General.LocalMSPDir = "/var/hyperledger/orderer/msp"
	General.LocalMSPID = "OrdererMSP"
	General.BCCSP.ProviderName = "SW"
	General.BCCSP.SwOpts.SecLevel = 256
	General.BCCSP.SwOpts.HashFamily = "SHA2"
	General.BCCSP.SwOpts.Ephemeral = false
	General.BCCSP.SwOpts.FileKeystore.KeyStorePath = "/var/hyperledger/orderer/msp/keystore"
	General.BCCSP.SwOpts.DummyKeystore =
	General.BCCSP.PluginOpts =
	General.Authentication.TimeWindow = 15m0s
	FileLedger.Location = "/var/hyperledger/production/orderer"
	FileLedger.Prefix = "hyperledger-fabric-ordererledger"
	RAMLedger.HistorySize = 1000
	Kafka.Retry.ShortInterval = 5s
	Kafka.Retry.ShortTotal = 10m0s
	Kafka.Retry.LongInterval = 5m0s
	Kafka.Retry.LongTotal = 12h0m0s
	Kafka.Retry.NetworkTimeouts.DialTimeout = 10s
	Kafka.Retry.NetworkTimeouts.ReadTimeout = 10s
	Kafka.Retry.NetworkTimeouts.WriteTimeout = 10s
	Kafka.Retry.Metadata.RetryMax = 3
	Kafka.Retry.Metadata.RetryBackoff = 250ms
	Kafka.Retry.Producer.RetryMax = 3
	Kafka.Retry.Producer.RetryBackoff = 100ms
	Kafka.Retry.Consumer.RetryBackoff = 2s
	Kafka.Verbose = false
	Kafka.Version = <IP_ADDRESS>
	Kafka.TLS.Enabled = false
	Kafka.TLS.PrivateKey = ""
	Kafka.TLS.Certificate = ""
	Kafka.TLS.RootCAs = []
	Kafka.TLS.ClientAuthRequired = false
	Kafka.TLS.ClientRootCAs = []
	Debug.BroadcastTraceDir = ""
	Debug.DeliverTraceDir = ""
2018-12-03 01:54:50.160 UTC [orderer/common/server] initializeServerConfig -> INFO 003 Starting orderer with TLS enabled
2018-12-03 01:54:50.181 UTC [fsblkstorage] newBlockfileMgr -> INFO 004 Getting block information from block storage
2018-12-03 01:54:50.221 UTC [orderer/commmon/multichannel] NewRegistrar -> INFO 005 Starting system channel 'testchainid' with genesis block hash 82312e773f3d76e71927b33d85d25f42596fc5ce113390e1d34666df2151c9f7 and orderer type solo
2018-12-03 01:54:50.222 UTC [orderer/common/server] Start -> INFO 006 Starting orderer:
 Version: 1.2.0
 Commit SHA: cae2ad4
 Go version: go1.10
 OS/Arch: linux/amd64
 Experimental features: false
2018-12-03 01:54:50.222 UTC [orderer/common/server] Start -> INFO 007 Beginning to serve requests
2018-12-03 01:54:52.788 UTC [msp] DeserializeIdentity -> INFO 008 Obtaining identity
2018-12-03 01:54:52.790 UTC [msp] DeserializeIdentity -> INFO 009 Obtaining identity
2018-12-03 01:54:52.795 UTC [msp] DeserializeIdentity -> INFO 00a Obtaining identity
2018-12-03 01:54:52.810 UTC [fsblkstorage] newBlockfileMgr -> INFO 00b Getting block information from block storage
2018-12-03 01:54:52.845 UTC [orderer/commmon/multichannel] newChain -> INFO 00c Created and starting new chain mychannel
2018-12-03 01:54:53.016 UTC [msp] DeserializeIdentity -> INFO 00d Obtaining identity
2018-12-03 01:54:59.254 UTC [msp] DeserializeIdentity -> INFO 00e Obtaining identity
2018-12-03 01:55:06.133 UTC [msp] DeserializeIdentity -> INFO 00f Obtaining identity
2018-12-03 01:55:06.148 UTC [orderer/common/broadcast] Handle -> WARN 010 Error reading from <IP_ADDRESS>:35334: rpc error: code = Canceled desc = context canceled
2018-12-03 01:55:06.151 UTC [common/deliver] Handle -> WARN 011 Error reading from <IP_ADDRESS>:35332: rpc error: code = Canceled desc = context canceled
2018-12-03 01:55:06.167 UTC [msp] DeserializeIdentity -> INFO 012 Obtaining identity
2018-12-03 01:55:09.001 UTC [msp] DeserializeIdentity -> INFO 013 Obtaining identity
2018-12-03 01:55:09.254 UTC [msp] DeserializeIdentity -> INFO 014 Obtaining identity
2018-12-03 01:55:09.263 UTC [msp] DeserializeIdentity -> INFO 015 Obtaining identity
2018-12-03 01:55:09.267 UTC [orderer/common/broadcast] Handle -> WARN 016 Error reading from <IP_ADDRESS>:35376: rpc error: code = Canceled desc = context canceled
2018-12-03 01:55:09.267 UTC [common/deliver] Handle -> WARN 017 Error reading from <IP_ADDRESS>:35374: rpc error: code = Canceled desc = context canceled
2018-12-03 01:55:09.288 UTC [msp] DeserializeIdentity -> INFO 018 Obtaining identity
2018-12-03 01:55:09.288 UTC [msp] DeserializeIdentity -> INFO 019 Obtaining identity
2018-12-03 01:55:14.887 UTC [msp] DeserializeIdentity -> INFO 01a Obtaining identity
2018-12-03 01:55:14.890 UTC [orderer/common/broadcast] Handle -> WARN 01b Error reading from <IP_ADDRESS>:35438: rpc error: code = Canceled desc = context canceled

@lotty02cho What kind of error do you get? (Since you don't create the channel, I guess it's not a "can't create mychannel" error)
Could you also provide the following information:

Version of the Fabric SDK you use (the backend is v1.2 as I see)
Versions of additional packages, like grpc, node
Where is your network (local docker containers, remotely, etc)
Anything you think is relevant

Also note, that Caliper provides some network examples that are much easier to deploy in my opinion :)


ADDED BASIC UI

I created an app.rb file that will serve as my console app entry-point. It has methods that do the following:
Lists all books.
Lists all people.
Creates a person (teacher or student, not a plain Person).
Creates a book.
Creates a rental.
Lists all rentals for a given person id.
In my main.rb I defined the entry point, this will be a method called main that is invoked at the end of your file. This method do the following:
Presents the user with a list of options to perform.
Lets users choose an option.
Have a way to quit the app.

@Simpleshaikh1 can you remove all files out from the classes folder and if possible you can delete the classes folder


proper usage to delete photo

What is the proper usage for deleting photo? I have tried using delete media request but i do not know what to place in for media id or im doing it properly?

Example of a media ID:
https://www.instagram.com/p/BgmG57Ej4GM
press CTRL+U in your browser and open the source code, search for "instagram://media?id="
this ID is the media ID you need to delete a media
or simply use .getMediaId()


Bartending Content & Bug Fixes

Adding Bartending Content and bug fixes
Partially Fixes  #818
I've added several new reagents, drinks, recipes, and items for bartending
Added said items to the right place, such as booze-o-mat in the case of bottles and cartons
Attempted to alphabetize YML files and clean them up
Fixed empty bottles in the spawn menu as well as the booze-o-mat
Fixed the size of some drink container objects to be on par with most ss13 forks
Changed Thirteen Loko and its sprite to a more fitting Fourteen Loko
Screenshots

Changelog
:cl: Daemon

tweak: Changed Thirteen Loko to Fourteen Loko
fix: Fixed some bottles in booze-o-mat and admin spawn panel being empty
add: Added various new reagents for bartending and added them to dispensers and vending machines
add: Added many new craft-able mixed drinks, experiment to find out!

Alright I'm good to go for another check on this

Typos are the bane of my existence

you can run yaml linter locally

I figured I could, but was unable to figure out how

dotnet cli - dotnet run Content.YAMLLinter
rider/vs - right click on the project and click run


Read_gtf but no write_gtf?

Would be a nice feature to also be able to write the dataframe to a gtf again. With the attribute column parsed as it is it's impossible to go the opposite direction

It worth what it worth but this is a small function to write gtf. I wanted to be quick so it's not very polish...
import polars
from pathlib import Path
import typing as t

COMMONS_COL = ['seqname', 'source', 'feature', 'start', 'end', 'score', 'strand', 'frame']

def write_gtf(df: polars.DataFrame, export_path: str | Path, headers:  t.List[str]):
    headers = headers or []
    with open(export_path, 'w') as f:
        for header in headers:
            f.write(f"{header}\n")
        for row in df.iter_rows(named=True):
            f.write(f"{commons_cols(row)}\t{custom_fields(row)}\n")

def commons_cols(row) -> str :
    return "\t".join([str(row[field] or '.') for field in COMMONS_COL])

def custom_fields(row) -> str:
    return "; ".join([f'{field} "{row[field]}"' for field in row.keys() if (field not in COMMONS_COL) and (row[field])])

It worth what it worth but this is a small function to write gtf. I wanted to be quick so it's not very polish...
import polars
from pathlib import Path
import typing as t

COMMONS_COL = ['seqname', 'source', 'feature', 'start', 'end', 'score', 'strand', 'frame']

def write_gtf(df: polars.DataFrame, export_path: str | Path, headers:  t.List[str] = None):
    headers = headers or []
    with open(export_path, 'w') as f:
        for header in headers:
            f.write(f"{header}\n")
        for row in df.iter_rows(named=True):
            f.write(f"{commons_cols(row)}\t{custom_fields(row)}\n")

def commons_cols(row) -> str :
    return "\t".join([str(row[field] or '.') for field in COMMONS_COL])

def custom_fields(row) -> str:
    return "; ".join([f'{field} "{row[field]}"' for field in row.keys() if (field not in COMMONS_COL) and (row[field])])

And the test :
from gtfparse import read_gtf, write_gtf
from data import data_path
from polars import DataFrame

REFSEQ_GTF_PATH = data_path("refseq.ucsc.small.gtf")

def test_write_gtf(tmp_path):
    gtf_dict = read_gtf(REFSEQ_GTF_PATH)
    write_gtf(gtf_dict, tmp_path/"dummy_gtf.gtf")
    assert  isinstance(read_gtf(str(tmp_path/"dummy_gtf.gtf")), DataFrame)

Nice one. Thank you!

You give me the motivation to make a PR :)

Go for it, otherwise happy to do it at the end of the week :)


Add share links to brexit checker results

Trello card: https://trello.com/c/fB9KKRrJ/242-add-share-your-results-component

Adds social share links that pass on your results URL onto various social media platforms.
Desktop

Intermediate

Tiny Mobile

🤔 can't work out what's going on with the e2e tests here, everything runs fine on local... and I've re-run em.

seems to be:
13:46:00  Failed examples:
13:46:00
13:46:00  rspec ./spec/publisher/publishing_content_to_government_frontend_spec.rb:7 # Publishing content from Publisher to Government Frontend Publishing a Help guide
13:46:00
13:46:00  Finished in 30.76 seconds (files took 1.93 seconds to load)
13:46:00  1 example, 0 failures

Unrelated to this change?

oh weird, that change went away...


Lower cabal-version and update README

Maybe we could mention the new env var in the README?

Actually, I changed my mind. These env variables are subject to change, since their usage is not very consequent. I would like to overhaul them a bit after a release.
If we add them to the README, they become obserable behaviour on which one can rely on.


Microfiber options (especially removeUnusedTypes) need to be exposed

I just spent way too long hunting down a parameter that caused many types in my schema to be hidden, and which was not accessible via config.yaml. I had to change these lines in src/themes/default/data/index.js to display all the types:
  let opts
  opts = {
    removeUnusedTypes: false
  }
  const introspectionManipulator = new IntrospectionManipulator(
    introspectionResponse, opts
  )

This option should be in the top-level config.yaml instead of inaccessible.
This was especially frustrating because the documentation instructs the user to set "documented": true to unhide types, but that does not affect the ones dropped by this hidden setting.
The setting also mistakenly considers types unused if they implement an interface which is referenced, but are not referenced directly.
Thanks for sharing the package otherwise. It has been very helpful.

Hi @felixvd and thanks for using SpectaQL. Sorry about your issue.
Hmm, yes, the options you need should actually be available in the "hide" options, like this one.
However, it does look like I'm not passing them to that location like I should be so that they are used in that instance of microfiber.
Can you tell me what was happening?

Yes, that's right. Concretely, my schema is referencing an interface, but the types implementing the interface are dropped:
type Query {
  ListStats(
    statType: String
  ): ListStatReturn
}

type ListStatReturn {
  rets: [StatEntry!]!
}

interface StatEntry {
  metainfo: String
}

type Stat1 implements StatEntry {
  metainfo: String
  value: Int
}

type Stat2 implements StatEntry {
  metainfo: String
  value: Int
}

(Stat1 and Stat2 do not appear in the doc)
This minimal example SDL reproduces the issue as well:
type Query {
  DummyQuery(
        nofield: String
  ): MyTestType1
}

type MyTestType1 {
  MyTestField: String
}

type MyTestType2 {
  MyTestField1: Int
}

MyTestType2 is removed from the doc regardless of the config's content. This is the first problem. I came across another after this.
Setting removeUnusedFields=false seems to cause the underlyingTypeDefinition not to be loaded correctly for types that are not referenced by a query (and are not String or Boolean). You can reproduce it with this SDL and the change described in the original post:
type Query {
  MyQuery(
    ret: String
  ): String
}

type OtherType {
  s: String
  b: Boolean
  f: Float
  i: Int
  o: OtherType2
}

type OtherType2 {
  s: String
}

I can't post my actual SDL file publicly, but I am happy to send it privately. It may clarify what I am trying to do and avoid an x-y problem.

I would have liked to read through microfiber's cleanSchema to see if it can be changed such that types which implement a referenced interface will not be removed. But it does not look like I will have the time. I hope the change is easy and you or someone else (or me if I can find time in the future) can fix it.
For completeness, I wanted to add that I needed to add these kinds of examples (with fragments) to our generated doc, and that it would have been very useful to have them auto-generated as well:
query {
     DummyQuery (
        ret: "stat1"
     ) {
      ... on Stat1 {
        value
      }
      ... on Stat2 {
        othervalue
      }

Hope this use case can serve as a reference. Thanks again for the tool!

Ah yes, you're only referencing the interface type and not the implementations...this is interesting.
Yeah, I think now that what I should do primarily is to update microfiber to consider types that implement an interface that is used as something to keep around. Let me check that out.

This is fixed/provided for in main and v1.5.2.

Excellent, thank you :)


Client / Orders / Invoices Overview broken

After I added some clients and tested the system the overview pages doesn't list the clients / oreders / invoices.. (screenshot attached)
I don't know exactly what's happened and where to start debugging.
Have you seen something like this before?

Could you tell us exact steps we need to take in order to reproduce the problem as I did not manage to do it in my environment?

We have the same issue here, clean install, version 4.20. PHP Version 5.3.29

Issue resolved, after enabling debug mode in boxbilling, I've a got a fatal error - call to undefined function mb_internal_encoding, so I have found that I need to install extension mbstring and everything is back to normal.
@peet86 You can enable that debug mode too, but I guess you have the same issue with missing extension - check it via phpinfo.

Thank you @newbot23 your answer solved my problem as well! I'm closing this issue.


KeyError: 'Commands'

Thanks for creating and publishing the script.
When running the second command to create the LOLBAS md files I get the following error:
└─# python3 generator.py lolbas build -od MyVault/LOLBAS/                                       1 ⨯
2022-12-21 16:08:08,505 - main - INFO - Executing utility module: <lib.utils.lolbas.Build object at 0x7f074c9807c0>
2022-12-21 16:08:08,505 - lolbas.build - INFO - Using cached LOLBAS repository.
Traceback (most recent call last):
  File "/opt/sec-vault-gen/generator.py", line 115, in <module>
    util(**dargs)
  File "/opt/sec-vault-gen/lib/utils/lolbas.py", line 149, in __call__
    return Build.build(*args, **kwargs)
  File "/opt/sec-vault-gen/lib/utils/lolbas.py", line 83, in build
    categories = list(set([c['Category'] for c in fm['Commands']]))
KeyError: 'Commands'

After checking the variable "fm" it seems that the "FM.read" is not parsing the YML file. But the path to the YML file is correct.
            # ====================
            # GET FRONTMATTER DATA
            # ====================

            for infile in d.glob('*.yml'):
                with infile.open() as i:
                    fm = FM.read(i)

                # =============================
                # ORGANIZE COMMANDS BY CATEGORY
                # =============================

                categories = list(set([c['Category'] for c in fm['Commands']]))
                commands_by_category = {}
                for cat in categories:
                    commands_by_category[cat] = [
                        c for c in fm['Commands'] if c['Category'] == cat
                    ]

Before I debug further, maybe you have an idea or have you had the same issue once?
Python Version: 3.10.9
Thanks

Same issue here. Did you find a solution? @m8r1us

Sorry...didn't know this code was still being used. Thought it was long forgotten!
Just merged a potential fix by @pkincaid-sa


Datetime parsing

Pull Request Test Coverage Report for Build 39

63 of 67 (94.03%)  changed or added relevant lines in 3 files are covered.
1 unchanged line in 1 file lost coverage.
Overall coverage decreased (-0.08%) to 98.079%

Changes Missing Coverage
Covered Lines
Changed/Added Lines
%

rest_client_gen/dynamic_typing/string_serializable.py
2
6
33.33%

Files with Coverage Reduction
New Missed Lines
%

rest_client_gen/models/init.py
1
70.89%

Totals

Change from base Build 36:
-0.08%

Covered Lines:
868

Relevant Lines:
885

💛  - Coveralls


Add php-scrypt as a example project

Hey There 👋
We at Appwrite recently created an extension using this library to fix an issue we had with the standard C-based php-scrypt by rewriting it in rust. Thanks to this library being so easy to use, we could get a working version in less than a day!
We would love it if you could add it as an example project in this repository to give more examples of how to use this library.
Thank you for reviewing this pull request,
Bradley Schofield

@ptondereau Thank you for reviewing our example, I was wondering where we should place our stubs within the repo once we have generated them? Is there a standard for this or should we do add it to our build steps?

@ptondereau Thank you for reviewing our example, I was wondering where we should place our stubs within the repo once we have generated them? Is there a standard for this? or should we add it to our build steps?

IMHO, it's up to you: I would go to exposing the stubs with a dedicated Packagist entry. In the ext's repository, add all stubs to a composer.json with a name in a manner that your user just need to composer install vendor/ext-stubs


TS2322: Type  () => void  is not assignable to type  Function in Typescript 5.2.2

🔎 Search Terms
TS2322
Type  () => void  is not assignable to type  Function
🕗 Version & Regression Information

This is a crash
This changed between versions  5.2.2

⏯ Playground Link
No response
💻 Code
// TS2322: Type  () => void  is not assignable to type  Function
let c: Function = () => {};

console.log(c);

🙁 Actual behavior
// TS2322: Type  () => void  is not assignable to type  Function
🙂 Expected behavior
no ts error
Additional information about the issue
No response

works fine:
https://www.typescriptlang.org/play?#code/DYUwLgBAxgXBBiBXAdlMBLA9siBeCAFAJR4B8EA3gL4DcAsAFBTYDOmoAdMJgOYFREaQA
(btw, that's why there's a playground - so you can share examples with people)


rxvt-unicode: patch to support perl 5.38

Description of changes
This fixes character encoding and rendering issues with non-ascii characters after the recent perl update. As the urxvt patch notes state:

perl 5.38 does not handle empty locale names, use "C" instead

Things done

Built on platform(s)

[x] x86_64-linux
[ ] aarch64-linux
[ ] x86_64-darwin
[ ] aarch64-darwin

[ ] For non-Linux: Is sandbox = true set in nix.conf? (See Nix manual)
[ ] Tested, as applicable:

NixOS test(s) (look inside nixos/tests)
and/or package tests
or, for functions and "core" functionality, tests in lib/tests or pkgs/test
made sure NixOS tests are linked to the relevant packages

[ ] Tested compilation of all packages that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD". Note: all changes have to be committed, also see nixpkgs-review usage
[x] Tested basic functionality of all binary files (usually in ./result/bin/)
23.11 Release Notes (or backporting 23.05 Release notes)

[ ] (Package updates) Added a release notes entry if the change is major or breaking
[ ] (Module updates) Added a release notes entry if the change is significant
[ ] (Module addition) Added a release notes entry if adding a new NixOS module

[ ] Fits CONTRIBUTING.md.

I'm not running into any issues anymore after applying the patch but I'm running a bit of a mix of hack/dejavu/noto/symbola/tamzen
It might be worth checking that you're not running into something like this: https://github.com/NixOS/nixpkgs/issues/245393#issuecomment-1650532982


Regex in steps

Sometimes we have had requests for regex in steps
This card is to discuss the use cases, requirements, suggestions and alternatives if any.

Closing this as an old issue. However, any PR's to fix this will be merged.


project create error

error D:\create-react-native-app\my-app2\node_modules\ref: Command failed.
Exit code: 1
Command: C:\Windows\system32\cmd.exe
Arguments: /d /s /c node-gyp rebuild
Directory: D:\create-react-native-app\my-app2\node_modules\ref
Output:
D:\create-react-native-app\my-app2\node_modules\ref>if not defined npm_config_node_gyp (node "C:\Users\AS00475240\AppData\Roaming\npm\node_modules\yarn\bin\node-gyp-bin\....\node_modules\node-gyp\bin\node-gyp.js" rebuild )  else (node  rebuild )
gyp info it worked if it ends with ok
gyp info using<EMAIL_ADDRESS>gyp info using<EMAIL_ADDRESS>| win32 | x64
gyp ERR! configure error
gyp ERR! stack Error: Can't find Python executable "python", you can set the PYTHON env variable.
gyp ERR! stack     at Object.failNoPython (C:\Users\AS00475240\AppData\Roaming\npm\node_modules\yarn\node_modules\node-gyp\lib\configure.js:454:19)
gyp ERR! stack     at Object. (C:\Users\AS00475240\AppData\Roaming\npm\node_modules\yarn\node_modules\node-gyp\lib\configure.js:480:16)
gyp ERR! stack     at C:\Users\AS00475240\AppData\Roaming\npm\node_modules\yarn\node_modules\graceful-fs\polyfills.js:284:29
gyp ERR! stack     at FSReqWrap.oncomplete (fs.js:123:15)
gyp ERR! System Windows_NT 10.0.10586
gyp ERR! command "C:\Program Files\nodejs\node.exe" "C:\Users\AS00475240\AppData\Roaming\npm\node_modules\yarn\node_modules\node-gyp\bin\node-gyp.js" "rebuild"
gyp ERR! cwd D:\create-react-native-app\my-app2\node_modules\ref
gyp ERR! node -v v6.9.4
gyp ERR! node-gyp -v v3.5.0
gyp ERR! not ok
info Visit https://yarnpkg.com/en/docs/cli/add for documentation about this command.
yarnpkg add --dev --exact --ignore-optional react-native-scripts failed

Duplicate of #48 - I should be releasing a fix for this later today.

do notify when fix available
On Thu, Mar 16, 2017 at 9:47 PM, Adam Perry<EMAIL_ADDRESS>wrote:

Duplicate of #48
https://github.com/react-community/create-react-native-app/issues/48 -
I should be releasing a fix for this later today.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
https://github.com/react-community/create-react-native-app/issues/78#issuecomment-287109771,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AMZJiyfdtT6llx0hxz-yUiJWAB5qggCnks5rmWCZgaJpZM4MffvY
.


Feature: implement caching

Is your feature request related to a problem? Please describe.
Using big projects it take much time to refresh project and consumes alot of memory once,
but when you close vscode you will lose all data.
Describe the solution you'd like
There should be way to use workspaceState from vscode.ExtensionContext
Describe alternatives you've considered
Or any other caching mechanism that also have small memory fingerprint (SQLite maybe)
Additional context
assets folder size: 10GB
example: https://github.com/estruyf/vscode-msgraph-autocomplete/blob/main/src/providers/CacheProvider.ts

I'm also feeling same thing.
Now clover is spending so much memory when project loaded and I'm also looking for solve this issue.
Your solution is also good way.


Fixed bug where migration would fail due to a new view referencing a migrated column

Problem:
Database upgrade failed when a new view referenced a newly added table column
Steps to reproduce:

Create a migration which adds a new column to a table
Create a new view model which references the column

Due to the views being created prior to the migration scripts, the migration view creation failed.
Fixes:
Split executeCreations into executeTableCreations and executeViewCreations, and ran executeMigrations in the middle i.e.

excuteTableCreations
executeMigrations
excuteViewCreations

thank you for your contribution. As per Readme, please make against the develop branch. Ill close this for you.


ReplicaCollie should support to migrate replica to another folder

This is the follow-up of #75. ReplicaCollie support to migrate replicas to another broker currently. That is not a fully migration tool. After #75, we should enhance ReplicaCollie to support such migration.

@garyparrot @qoo332001 就看#75完成後，誰有空來幫忙處理這個議題