sim-lib: continue simulation on send payment errors

Instead of stopping the simulation on the first send payment rpc error, we gracefully handle the error and report a default send payment result. Since send payment rpc might fail before dispatching a payment (i.e in CLN case), we allow activity result reporting to skip tracking of payment if there's no payment hash
Sample results with failed keysends. The simulation continues until stopped
source,destination,hash,amount_msat,dispatch_time,htlc_count,payment_outcome
023d45dc57ed99e6d793e2fed8dcf79d2f6ad2f32ec31b48102de445e245e08336,03b73874dde2c0af24619f03b6fc5d36adbf00ad6d25ce6479d4f5b60f648c8cb6,83d340ab8a7f7b383294dd06a8fc02bcbff6c77c73debaa8e590aad550216f98,1000,1695160575397,1,Success
02c0c854f511082f9d174f9b0e51ca14fc299c25de9d65dddadebe9ac1fd529758,03b73874dde2c0af24619f03b6fc5d36adbf00ad6d25ce6479d4f5b60f648c8cb6,Unknown,10000000000,1695160576400,0,Unknown

TODO:

[x] Continue simulation on send payment errors
[x] Formalize terminal error handling
[x] Parse CLN send_payment rpc errors to determine terminal failures
[x] Parse LND send_payment rpc errors to determine terminal failures

fixes #96

I do think that we need to take a slightly more subtle approach to handling errors (right now we'll just create failed events for any send_payment failure). In my mind there are two types of errors:

Terminal errors: the lightning node has shut down -> we can't recover and should also shut down.
Payment errors: the API has returned an error, but it's actually just a pathfinding error (eg: no route) -> we can recover from this, and should record the failure and try again.

@carlaKC I agree with your sentiment above, but have a slightly different proposal regarding interpretation of Terminal errors

RE: Terminal errors: the lightning node has shut down -> we can't recover and should also shut down.

Instead of shutting down the entire simulation, I propose we stop simulating the activity or activity set affected by nodes we have seen terminal errors on. This shuts down parts of the simulation, but continues the still good parts.

Right now, if one of the lightning nodes shuts down we'll just continue to track failed payments when we should really just shut down. To address #96, we need to examine the error from CLN and figure out whether it's terminal or now. So basically all of this code as-is, with a little some more precise error handling in the CLN impl.

So building on this PR, my proposal is we stop simulating activity related to the CLN node if we observe terminal failure on the node.

I do think that we need to take a slightly more subtle approach to handling errors (right now we'll just create failed events for any send_payment failure). In my mind there are two types of errors:

Terminal errors: the lightning node has shut down -> we can't recover and should also shut down.
Payment errors: the API has returned an error, but it's actually just a pathfinding error (eg: no route) -> we can recover from this, and should record the failure and try again.

@carlaKC I agree with your sentiment above, but have a slightly different proposal regarding interpretation of Terminal errors

RE: Terminal errors: the lightning node has shut down -> we can't recover and should also shut down.

Instead of shutting down the entire simulation, I propose we stop simulating the activity or activity set affected by nodes we have seen terminal errors on. This shuts down parts of the simulation, but continues the still good parts.

Right now, if one of the lightning nodes shuts down we'll just continue to track failed payments when we should really just shut down. To address #96, we need to examine the error from CLN and figure out whether it's terminal or now. So basically all of this code as-is, with a little some more precise error handling in the CLN impl.

So building on this PR, my proposal is we stop simulating activity related to the CLN node if we observe terminal failure on the node.

Oh, and we terminate the simulation if there's no more activities to simulate.

https://github.com/bitcoin-dev-project/sim-ln/pull/104/commits/f89506abbfba4875d4aa78da79b4bc0c68ee9536 looking nice 👌 thanks for going through a few iterations to get it there!
I you want to go ahead and fill in the parsing I think we can do this all in one PR?

https://github.com/bitcoin-dev-project/sim-ln/pull/104/commits/f89506abbfba4875d4aa78da79b4bc0c68ee9536 looking nice 👌 thanks for going through a few iterations to get it there!
I you want to go ahead and fill in the parsing I think we can do this all in one PR?

I was planning the parsing as follow-ups when I get a chance to build on this.

I was planning the parsing as follow-ups when I get a chance to build on this.

SGTM, no strong feelings.

Starting w cln because that's the most offending

GLHF :')

ACK fb981a2


Fix duplicate keys preservation of JSON data

Supersedes #1136 (I messed up with remote repositories).
Fixes #1133.

Codecov Report

Merging #1163 (13bdade) into master (4d7d6b6) will decrease coverage by 0.01%.
The diff coverage is 99.12%.

:exclamation: Current head 13bdade differs from pull request most recent head 87e1fe2. Consider uploading reports for the commit 87e1fe2 to get more accurate results

@@            Coverage Diff             @@
##           master    #1163      +/-   ##
==========================================
- Coverage   97.28%   97.26%   -0.02%
==========================================
  Files          67       70       +3
  Lines        4235     4314      +79
==========================================
+ Hits         4120     4196      +76
- Misses        115      118       +3

Impacted Files
Coverage Δ

httpie/output/formatters/colors.py
92.66% <83.33%> (-0.92%)
:arrow_down:

httpie/__init__.py
100.00% <100.00%> (ø)

httpie/cli/requestitems.py
91.17% <100.00%> (ø)

httpie/output/formatters/json.py
100.00% <100.00%> (ø)

httpie/output/lexers/http.py
100.00% <100.00%> (ø)

httpie/output/lexers/json.py
100.00% <100.00%> (ø)

httpie/output/utils.py
100.00% <100.00%> (ø)

httpie/utils.py
100.00% <100.00%> (ø)

tests/fixtures/__init__.py
100.00% <100.00%> (ø)

tests/test_cli.py
100.00% <100.00%> (ø)

... and 6 more

Continue to review full report at Codecov.

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


strange small grey rectangle below top menu

There is a strange small grey rectangle below top menu.

Start fresh ionic 2 tutorial app
Open menu
Tap My First List
You will see it like picture: https://i.imgur.com/gQYTF8A.jpg

Can you run ionic info and post the results?

Sure
Cordova CLI: 6.3.1
Ionic Framework Version: 2.0.0-rc.0
Ionic CLI Version: 2.1.0
Ionic App Lib Version: 2.1.0-beta.1
OS:
Node Version: v6.7.0

Hmmm looks like this issue popped back up again: https://github.com/driftyco/ionic/issues/6416

I've got the same issue in ionic2 RC0. #6416 solution doesn't work.

I also have the same problem in ionic2 RC0.

Yes, that is exactly the same as in #6416

I have this problem, when i create page with ModalController.

I have this issue as well in RC0.

Closing as a duplicate of #6416


ValueError: not enough values to unpack (expected 4, got 3)

Hi, Thank you for providing excellent super resolution technology.
I wanted to test the behavior and I ran the following command and I got an error.

C:\Users\yusuke\EDSR-PyTorch\code>python main.py --data_test Demo --cpu --scale 4 --n_threads 0 --pre_train ../experiment/model/EDSR_baseline_x4.pt --test_only --save_results
Making model...
Loading model from ../experiment/model/EDSR_baseline_x4.pt

Evaluation:
0%|                                                     | 0/1 [00:00<?, ?it/s]
Traceback (most recent call last):
File "main.py", line 18, in
while not t.terminate():
File "C:\Users\yusuke\EDSR-PyTorch\code\trainer.py", line 136, in terminate
self.test()
File "C:\Users\yusuke\EDSR-PyTorch\code\trainer.py", line 88, in test
for idx_img, (lr, hr, filename, _) in enumerate(tqdm_test):
ValueError: not enough values to unpack (expected 4, got 3)

Windows 10 64bit
Anaconda 4.5.0
Python 3.6.4
pytorch 0.3.1.post2
torchvision 0.2.0

Hello.
I tested your script, and found that --n_threads 0 is the problem.
Would you try --n_threads 1? (I checked that it works without any error on Ubuntu 16.04.)
Because I do not use PyTorch@Windows, it may take some times to fix this problem.
Thank you.

I tried --n_threads 1 but the operation stopped.
C:\Users\yusuke\EDSR-PyTorch\code>python main.py --data_test Demo --cpu --scale 4 --n_threads 1 --pre_train ../experiment/model/EDSR_baseline_x4.pt --test_only --save_results
Making model...
Loading model from ../experiment/model/EDSR_baseline_x4.pt
Evaluation:
0%|                                                     | 0/1 [00:00<?, ?it/s]Making model...
Loading model from ../experiment/model/EDSR_baseline_x4.pt
Evaluation:
0%|                                                     | 0/1 [00:00<?, ?it/s]Traceback (most recent call last):
File "", line 1, in
File "C:\Users\yusuke\Anaconda3\lib\multiprocessing\spawn.py", line 105, in spawn_main
exitcode = _main(fd)
File "C:\Users\yusuke\Anaconda3\lib\multiprocessing\spawn.py", line 114, in _main
prepare(preparation_data)
File "C:\Users\yusuke\Anaconda3\lib\multiprocessing\spawn.py", line 225, in prepare
_fixup_main_from_path(data['init_main_from_path'])
File "C:\Users\yusuke\Anaconda3\lib\multiprocessing\spawn.py", line 277, in _fixup_main_from_path
run_name="mp_main")
File "C:\Users\yusuke\Anaconda3\lib\runpy.py", line 263, in run_path
pkg_name=pkg_name, script_name=fname)
File "C:\Users\yusuke\Anaconda3\lib\runpy.py", line 96, in _run_module_code
mod_name, mod_spec, pkg_name, script_name)
File "C:\Users\yusuke\Anaconda3\lib\runpy.py", line 85, in _run_code
exec(code, run_globals)
File "C:\Users\yusuke\EDSR-PyTorch\code\main.py", line 18, in
while not t.terminate():
File "C:\Users\yusuke\EDSR-PyTorch\code\trainer.py", line 136, in terminate
self.test()
File "C:\Users\yusuke\EDSR-PyTorch\code\trainer.py", line 88, in test
for idx_img, (lr, hr, filename, _) in enumerate(tqdm_test):
File "C:\Users\yusuke\Anaconda3\lib\site-packages\tqdm_tqdm.py", line 897, in iter
for obj in iterable:
File "C:\Users\yusuke\EDSR-PyTorch\code\dataloader.py", line 133, in iter
return MSDataLoaderIter(self)
File "C:\Users\yusuke\EDSR-PyTorch\code\dataloader.py", line 106, in init
w.start()
File "C:\Users\yusuke\Anaconda3\lib\multiprocessing\process.py", line 105, in start
self._popen = self._Popen(self)
File "C:\Users\yusuke\Anaconda3\lib\multiprocessing\context.py", line 223, in _Popen
return _default_context.get_context().Process._Popen(process_obj)
File "C:\Users\yusuke\Anaconda3\lib\multiprocessing\context.py", line 322, in _Popen
return Popen(process_obj)
File "C:\Users\yusuke\Anaconda3\lib\multiprocessing\popen_spawn_win32.py", line 33, in init
prep_data = spawn.get_preparation_data(process_obj._name)
File "C:\Users\yusuke\Anaconda3\lib\multiprocessing\spawn.py", line 143, in get_preparation_data
_check_not_importing_main()
File "C:\Users\yusuke\Anaconda3\lib\multiprocessing\spawn.py", line 136, in _check_not_importing_main
is not going to be frozen to produce an executable.''')
RuntimeError:
An attempt has been made to start a new process before the
current process has finished its bootstrapping phase.
    This probably means that you are not using fork to start your
    child processes and you have forgotten to use the proper idiom
    in the main module:

        if __name__ == '__main__':
            freeze_support()
            ...

    The "freeze_support()" line can be omitted if the program
    is not going to be frozen to produce an executable.

@f11894
to solve this you should return used {--n_threads 0 } as you in windows, and in trainer.py line 88 change (lr, hr, filename, _) to (lr, hr, filename), to get rid not enough values to unpack (expected 4, got 3) error, then every thing will work as he should.

@ABDOELSHEMY
That went well. Thank you.


Nullish coalescing operator: fallback value is not type checked when left-hand value is array element

🔎 Search Terms
nullish coalescing operator, ??
🕗 Version & Regression Information

This is the behavior in every version I tried, and I reviewed the FAQ for entries about nullish coalescing operator

⏯ Playground Link
https://www.typescriptlang.org/play?ts=5.3.0-dev.20231023#code/MYewdgzgLgBNBOBLMBzAgveBDAngLjiiVQG0BdGAXhnIG4AoUSWAExAFMIA5EKAUUwh4aCHwAeAB3bAo7FgQTIUVQsXSZcJAAwUA-LpgBGAEwBmBk2gx2g+BADCQ+NKgAbfKqUrFqDNhzaep6+GgE6MAQm5ozgVliuECAC8EIOTi7uCkRe1D7q-oEwAD5FRma0QA
💻 Code
const stringArray: string[] = [];
const doesNotErrorAsExpected: string = stringArray[0] ?? 123;
const errorsCorrectly: string = stringArray[0] ? stringArray[0] : 123;
const alsoErrorsCorrectly: string = stringArray[0] || 123;

🙁 Actual behavior
Like the ternary and logical OR operator, const doesNotErrorAsExpected: string = stringArray[0] ?? 123 should error with message "Type 'number' is not assignable to type 'string'."
🙂 Expected behavior
const doesNotErrorAsExpected: string = stringArray[0] ?? 123 is permitted with no type errors.
Additional information about the issue
No response

You'll need to turn on noUncheckedIndexedAccess, since from the checker's POV with that option off, the LHS is never nullish

Thanks, why is that different than with the ternary?


docs: update weaviate benchmark results

Goals:
Update the version of weaviate to 1.16.1 and benchmark results accordingly.

[x] update benchmark results
[x] fix benchamrk chart hover data

Codecov Report
Base: 82.70% // Head: 66.64% // Decreases project coverage by -16.06% :warning:

Coverage data is based on head (fca0812) compared to base (632c3ae).
Patch has no changes to coverable lines.

Additional details and impacted files
@@             Coverage Diff             @@
##             main     #773       +/-   ##
===========================================
- Coverage   82.70%   66.64%   -16.07%
===========================================
  Files         133      133
  Lines        6703     6703
===========================================
- Hits         5544     4467     -1077
- Misses       1159     2236     +1077

Flag
Coverage Δ

docarray
66.64% <ø> (-16.07%)
:arrow_down:

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files
Coverage Δ

docarray/array/mixins/dataloader/helper.py
0.00% <0.00%> (-100.00%)
:arrow_down:

docarray/document/mixins/rich_embedding.py
0.00% <0.00%> (-100.00%)
:arrow_down:

docarray/math/evaluation.py
0.00% <0.00%> (-94.83%)
:arrow_down:

docarray/array/mixins/reduce.py
26.92% <0.00%> (-73.08%)
:arrow_down:

docarray/array/mixins/io/pushpull.py
23.27% <0.00%> (-69.83%)
:arrow_down:

docarray/array/mixins/io/csv.py
23.68% <0.00%> (-65.79%)
:arrow_down:

docarray/document/mixins/plot.py
9.59% <0.00%> (-61.12%)
:arrow_down:

docarray/array/mixins/io/dataframe.py
41.66% <0.00%> (-58.34%)
:arrow_down:

docarray/array/mixins/sample.py
45.45% <0.00%> (-54.55%)
:arrow_down:

docarray/document/generators.py
33.91% <0.00%> (-53.05%)
:arrow_down:

... and 63 more

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

:umbrella: View full report at Codecov.
:loudspeaker: Do you have feedback about the report comment? Let us know in this issue.

maybe we should investigate this as well


How does ‘tasks = self._env.unwrapped.sample_tasks(num_tasks) ’execute in the penultimate line of sampler.py in the maml-rl folder?

As the title

Sample_tasks function defined inside mujoco maml_rl folder on halfcheetah.py


[agent_session.go:180 sendTaskList()] [E] failed to get task list. Error 1054: Unknown column 'task.namespace' in 'field list'

observed on coll-con-1-prod
2016/05/24 08:56:36 [D] socket 10ebe26e-2138-11e6-b9d4-42010af01109 sending message
2016/05/24 08:56:36 [D] sending TaskUpdate to 10ebe26e-2138-11e6-b9d4-42010af01109
2016/05/24 08:56:37 [D] socket 2c8b35c2-2138-11e6-b9d4-42010af01109 sending message
2016/05/24 08:56:37 [agent_session.go:180 sendTaskList()] [E] failed to get task list. Error 1054: Unknown column 'task.namespace' in 'field list'
2016/05/24 08:56:38 [D] socket 10ebe26e-2138-11e6-b9d4-42010af01109 sending message
2016/05/24 08:56:39 [D] socket 2c8b35c2-2138-11e6-b9d4-42010af01109 sending message

(messages containing 'nack message' filtered out, there were way too many)

bad query is
[xorm] [info]  2016/05/24 12:25:29.380533 [sql] SELECT task_id FROM route_by_id_index where agent_id = ? UNION SELE
CT task_id from route_by_any_index where agent_id = ? [args] [4 4]
[xorm] [info]  2016/05/24 12:25:29.381649 [sql] SELECT `task`.`id`, `task`.`name`, `task`.`org_id`, `task`.`config`
, `task`.`interval`, `task`.`route`, `task`.`enabled`, `task`.`created`, `task`.`updated`, `task`.`namespace`, `tas
k`.`version` FROM `task` LEFT JOIN `task_metric` ON task.id = task_metric.task_id WHERE (`task`.`id` IN (?,?,?,?,?,
?,?)) [args] [11 25 28 31 35 37 46]

tracking down where this is being called from.  A recent change in xorm has resulted in all fields in the destination struct being referenced in the query. Previously xorm just queried for *.  As the destination struct is for results from a JOIN, namespace is expected.
Need to find where the query is being called and explicitly define the columns to retrieve.


ロックPro = Lock Pro
I want to check the door open/close sensor with Apple Home.

Can you try the latest beta:

Click here to find out how to install Beta

Wow. It now appears on the home app. Thank you so much!
Arigatou! from Japan

Wow. It now appears on the home app. Thank you so much!
Arigatou! from Japan

Do the controls work?

Yes! But it takes some time to get the sensor status. This is probably to prevent API usage restrictions.

v3.4.0 has geen released.


Improve accuracy of Geometric Distribution

The probability mass function of the geometric distribution had some accuracy problems.  Example:
ghci> da = (geometric (35 / 65536))
ghci> pa = Statistics.Distribution.probability da 106822
ghci> pa
8.812340833341934e-29

The correct answer in this case is 8.812340833326208e-29.
Problematic expressions are of the form log (1-x) for small x; replace them by log1p (-x).
Also exclude the invalid parameter choice p = 0.

Thank you!
Everything is good except computation of s * (1-s) ** (fromIntegral n - 1). I thrown together quick script to check error of both approaches, images are below. Naive is old one, log1p is proposed. Z axis is relative error divided by floating point ε, so ideally it should be 1 and less.
log1p method clearly outperforms naive for small s but fails for points closer to 1. I didn't figure out why is it so and whether there's nice switchover point
P.S. I hope there's no problem with images

Thanks for these!  They are very helpful. I did indeed miss the regression this causes for larger $s$.  I think I've fixed this issue by switching over to the elementary implementation for larger $s$.  This improved the accuracy for $s \geq 1/2$ to better than $10^{-14}$, according to my tests.  For lower $s$ it is unchanged, and still at $10^{-13}$.  I think the problem with the smaller $s$ value is that the need to use the log domain causes it to be a little worse than ideal.
To make collaboration easier here, I've also created the pull request that contains the code that I'm using to test these distributions, here:  https://github.com/haskell/statistics/pull/199
I've found that code useful to debug and evaluate these particular distributions.

After re-reading through it, I have some doubts about the new implementation of cumulative.  It seems that using the naive $1 - (1 - s)^k$ formula may not be the best choice even for $s \geq 1/2$.  Let me recheck this.

Yeah. For $s \geq 1/2$ $1-s$ is exactly representable so we can use direct computation.

It seems that using the naive $1 - (1 - s)^k$ formula may not be the best choice even for $s \geq 1/2$.  Let me recheck this.
I'm not sure about this. In that case $1-s$ could be computed exactly. $(1 - s)^k$ will be even smaller so any rounding errors will washed out when it's subtracted from 1.

Maybe there's better way but I don't se any obvious problems

I finally got time to get back to this PR. I rechecked implementation and yes it does improve precision. Thanks!


Dragging Input Item to Other Team Results in The Input Text Being Deleted

When I drag an input element that contains text within its own team, the text in both input elements remain the same. However, when I drag the input element over an input element from another team, the input elements from both teams disappear.
I am not sure exactly how to reproduce it, however, here is my code for the teams component.
import React, { useCallback, useState } from "react"
import Player from "../player/Player"
import { useSelector } from "react-redux"

import "./teams.scss"

interface summonerObject {
  id: string
  text: string
}

const Teams: React.FC<{}> = ({}) => {
  const reduxSummonerName = useSelector(
    (state: any) => state.summonerName.value
  )
  const [teams, setTeams] = useState<summonerObject[]>([
    { id: "Summoner 1", text: reduxSummonerName },
    { id: "Summoner 2", text: reduxSummonerName },
    { id: "Summoner 3", text: reduxSummonerName },
    { id: "Summoner 4", text: reduxSummonerName },
    { id: "Summoner 5", text: reduxSummonerName },
    { id: "Summoner 6", text: reduxSummonerName },
    { id: "Summoner 7", text: reduxSummonerName },
    { id: "Summoner 8", text: reduxSummonerName },
    { id: "Summoner 9", text: reduxSummonerName },
    { id: "Summoner 10", text: reduxSummonerName },
  ])

  //callback to be used by Player component to find index of itself within teams state
  const findPlayer = useCallback(
    (id: string) => {
      const player = teams.filter((c) => c.id === id)[0] as {
        id: string
        text: string
      }
      return {
        player,
        index: teams.indexOf(player),
      }
    },
    [teams]
  )

  //callback to be used by Player component to move Player
  const switchPlayer = useCallback(
    (id: string, atIndex: number) => {
      const { index } = findPlayer(id)
      //copy of current array
      const updatedArr = [...teams]

      //switch array items
      const temp = updatedArr[index]
      updatedArr[index] = updatedArr[atIndex]
      updatedArr[atIndex] = temp

      //rerender component with updated array placements
      setTeams(updatedArr)
    },
    [findPlayer, teams, setTeams]
  )

  const renderPlayers = (color: string, arr: summonerObject[]) => {
    const teamArr = color === "blue" ? arr.slice(0, 5) : arr.slice(5, 10)
    return (
      <article className={`col-sm-10 col-md-5 teams__container ${color}-list`}>

          {teamArr.map((summoner) => (
            <Player
              key={summoner.id}
              id={summoner.id}
              switchPlayer={switchPlayer}
              findPlayer={findPlayer}
              text={summoner.text}
            />
          ))}

    )
  }

  return (

        {renderPlayers("blue", teams)}
        {renderPlayers("red", teams)}

  )
}

export default Teams

Here is the Player component logic...
import React from "react"
import { useDrag, useDrop } from "react-dnd"
import { setSummonerName } from "../slices/summonerNameSlice"

const Player: React.FC<{
  text: string
  id: string
  switchPlayer: (id: string, to: number) => void
  findPlayer: (id: string) => { index: number }
}> = ({ text, id, switchPlayer, findPlayer }) => {

  //get original index of Player
  const originalIndex = findPlayer(id).index

  //link drag ref to input component.
  //create isDragging element to style components with when component is being dragged
  //Monitor the element that is dropped
  const [{ isDragging }, dragRef] = useDrag(
    () => ({
      type: "player",
      item: { id, originalIndex },
      collect: (monitor) => ({
        isDragging: !!monitor.isDragging(),
      }),
      end: (item, monitor) => {
        const { id: droppedId, originalIndex } = item
        const didDrop = monitor.didDrop()
        if (!didDrop) {
          switchPlayer(droppedId, originalIndex)
        }
      },
    }),
    [id, originalIndex, switchPlayer]
  )

  const [{ isOver }, drop] = useDrop(
    () => ({
      accept: "player",
      collect: (monitor) => ({
        isOver: !!monitor.isOver(),
      }),
      drop({ id: draggedId }) {
        const { index } = findPlayer(id)
        if (draggedId !== id) {
          switchPlayer(draggedId, index)
        }
      },
    }),
    [findPlayer, switchPlayer]
  )

  return (

      <input
        style={{
          opacity: isDragging ? 0.4 : 1,
          border: isDragging || isOver ? "1px solid white" : "0px",
        }}
        className="col-8"
        onChange={(e) => setSummonerName(e.target.value)}
        value={text}
        placeholder={id}
        ref={dragRef}
      ></input>

  )
}

export default Player

Any help would be greatly appreciated as I have been trying to solve this for close to two days now.

@AaronTran206 How did you fix your issue? I'm running into something similar and would love to hear if you found a solution.

It has to do with the component re-entering because the reference to the
array is changing.
You need to reformat your code so that the data is coming from a another
source and not originating from the component.
Hope that helps!
On Tue, Jul 5, 2022, 7:17 AM Ty Hitzeman @.***> wrote:

@AaronTran206 https://github.com/AaronTran206 How did you fix your
issue? I'm running into something similar and would love to hear if you
found a solution.
—
Reply to this email directly, view it on GitHub
https://github.com/react-dnd/react-dnd/issues/3453#issuecomment-1175048988,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AXSWM7UPATS5VUYCDZFPSCLVSQYUZANCNFSM5W364XHQ
.
You are receiving this because you were mentioned.Message ID:
@.***>

@AaronTran206 My mistake was not adding a value to the useDrag dependency array. Your answer helped me figure that out, so thanks a bunch!


Linking does not work

Hey,
I've tried several methods to link the module (react-native link, rnpm link, react-native install) but I'm still getting the "Cannot read property 'Constants' of undefined".
Is there another way to troubleshoot this or other solutions?

@mxmtsk after you run react-native link react-native-video go to your app target in xcode
Build Phase -> Link Binary With Libraries
Check and make sure there's a house next to libRCTVideo.a

See how all of the packages above have a house except libPods-ramble.a? If your libRCTVideo.a doesn't have a house, then that means it's not linked properly.
Select it and delete. Then drag the file back into this list from Libraries -> RCTVideo.xcodeproj -> Products -> libRCTVideo.a

you have to link the .a manually if your project has more than one target, the react native link can help you link only one target .
select one target in 'General' scroll to 'Linked Frameworks and Libraries' and make sure the libRCTViedo.a is on the list. if not just click the add button to link the .a then check another one.
hope it will work.

@mxmtsk can this be closed?

@jhabdas  yes sorry!

-1 when using react-native link it shows an error like this
-2 and when i want add libRCTvidoe.a, it doesn't apear in linkages so let start hacking :)
i cloned project and use libRCTvideo.a in project , droped to my project and walla.. now librctvideo apears and i added to my project and it worked !


Allow Summary to take a arbitary amount of characters

Add a {{ SummaryAmount 250 }} function for example which will only generate the specified amount of characters in the summary not including words that are on the cut off. Either that or be able to specify it as a site variable or the like.

It would have to be a site-wide config constant. (or, it wouldn't HAVE to be, but what you suggest would be too much work to be worth it).

Also, if you want per-page sumarylength, you can do it all manual style by adding <!--more--> after your summary.

The use-case is that the text needs a fixed maximum size that I don't want to manually input  tags which I currently do.

It's pretty easy to extract the summary length into site config. I know @spf13 isn't a fan of too many knobs, so he'll be the judge.

Note/Update: This issue is marked as stale, and I may have said something earlier about "opening a thread on the discussion forum". Please don't.
If this is a bug and you can still reproduce this error on the latest release or the master branch, please reply with all of the information you have about it in order to keep the issue open.
If this is a feature request, and you feel that it is still relevant and valuable, please tell us why.

In chinese, there is no space between words, so you can't count it in normal way.
If I use any theme which have ".Summary" in list page, the summary will very very long.
Can we have a way to count summary by character?

@hyacinthus try to set hasCJKLanguage = true in your Site config.

@bep thank you , it works.  But the summary is a little short now...

@hyacinthus cannot have it all ... you may try the truncate func with full content.

I switch from wordpress, and already have many posts, without truncate function.
Anyway, I'll use a none summary theme. Looks more cleaner.

@bep thanks for the cc.
Updated here: https://hugodocs.info/content-management/summaries/#hugo-defined-automatic-summary-splitting
BTW, think I should add a third shortcode for a "tip" admonition? Right now I have just "note" and "warning," and "tip" is pretty common. Maybe I can convince Bud to make it pretty for me too.

Close this as a duplicate of #3693


Questions w/ radio buttons do not allow user to Save answer

For the radio button question on NIH template I cannot save my answer. Nothing happens when I click Save (no timestamp save confirmation) and when I navigate away from the page and return my selection is not saved.

The commit pushed only fixes the problem for those users that are owner or have edit privileges into a plan that includes radio button. For read only users in a plan, see #352

You can save answers now, but the recorded values don't appear to be sticking. See issue noted in #355

Fixed as part of the work done in #355

This is working. Closing out


[SPARK-42630][CONNECT][PYTHON] Introduce UnparsedDataType and delay parsing DDL string until SparkConnectClient is available

What changes were proposed in this pull request?
Introduces UnparsedDataType and delays parsing DDL string for Python UDFs until SparkConnectClient is available.
UnparsedDataType carries the DDL string and parse it in the server side.
It should not be enclosed in other data types.
Also changes createDataFrame to use the proto DDLParse.
Why are the changes needed?
Currently parse_data_type depends on PySparkSession that creates a local PySpark, but it won't be available in the client side.
When SparkConnectClient is available, we can use the new proto DDLParse to parse the data types as string.
Does this PR introduce any user-facing change?
The UDF's returnType attribute could be a string in Spark Connect if it is provided as string.
How was this patch tested?
Existing tests.

Merged to master and branch-3.4.


Gracefully handle folders that are not repositories

nabu panics if the user tries to watch a directory that is not a git repository, gracefully handle this case, showing an error rather than panicking.

This is actually already happening. My bad


Add reth-config crate with all config (reth.toml) types

Describe the feature
Config currently resides in
https://github.com/paradigmxyz/reth/blob/5039122c356f20d36e3d5979f0da97a2fc40ac75/crates/staged-sync/src/config.rs#L12-L23
we want a standalone crate that provides all config types.
TODO

[ ] add reth-config crate
[ ] move Config struct to reth-config

ref #2514
Additional context
No response

I will take this.

I can try taking this issue. Just to confirm, only the Config struct should be moved? Or all the structs in the file should be moved?

Or all the structs in the file should be moved?

not exactly set on this yet, wdyt @onbjerg ?
I guess we have two options:

config create defines all config types used by reth crates
config create imports all config types from other reth crates

I feel like 2 is cleaner

I can proceed with 2 for now. Should be straightforward to change to 1 if need be.


[EasyHydrator] DateTimeImmutable resolver (symplify#2254)

Fixing #2254

Thank you :+1:

Tip for Github closing keyword: https://docs.github.com/en/enterprise/2.16/user/github/managing-your-work-on-github/closing-issues-using-keywords


Cli updates

Issue #, if available:
N/A
Description of changes:
Enhance the CLI pkg w/

StringSliceFlag (accepts a list of strings from the command line)
StringOptionsFlag (accepts a string from the command line and performs validation based on options based in when the flag is registered)
Expose raw cobra command for advanced usage
Expose CLI processing logic for pluggable usage
Added test coverage

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

Codecov Report

Merging #5 into master will increase coverage by 1.70%.
The diff coverage is 92.00%.

@@            Coverage Diff             @@
##           master       #5      +/-   ##
==========================================
+ Coverage   87.51%   89.22%   +1.70%
==========================================
  Files           7        7
  Lines         673      724      +51
==========================================
+ Hits          589      646      +57
+ Misses         60       52       -8
- Partials       24       26       +2

Impacted Files
Coverage Δ

pkg/cli/cli.go
85.48% <77.77%> (-1.30%)
:arrow_down:

pkg/cli/flags.go
91.89% <95.00%> (+13.14%)
:arrow_up:

pkg/cli/types.go
100.00% <100.00%> (ø)

Continue to review full report at Codecov.

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

removeIntersectingArgs won't affect other command's parsing logic and cannot be used in a larger cobra app since the parse logic will be the responsibility of the rootCmd of that app. This function is only available for the actual ec2-instance-selector CLI driver.


Missing information about supported filters

Information is missing about what kind of filter is supported on list items and their different column types.
The only way right know is to go by trial error, which is very frustrating and slow.

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

ID: 2524650e-06e7-dc8c-b2ae-0c2fbffdb541
Version Independent ID: 3eb41d73-2b60-1459-e921-20403004655c
Content: Retrieve items from a SharePoint list - Microsoft Graph v1.0
Content Source: api-reference/v1.0/api/listitem-list.md
Product: sharepoint
Technology: microsoft-graph
GitHub Login: @JeremyKelley
Microsoft Alias: MSGraphDocsVteam

As part of a repository clean up effort we are closing older issues. If this issue remains, please: open a new issue, reference this issue, and provide any additional details that may help in resolution. Thank you for your understanding as we work to improve our responsiveness.


Do not document queries as supporting multiple kinds

Fixes #572
Updated the documentation to not make people think we support multiple kinds. The code automatically arrayizes the kind given as required by the backend API.

LGTM if this is all the places where ['Kind'] appears in user-facing land.

I'll double check.

I added a couple changes so that the code more closely matches the documentation. I also removed a test that will continue to pass, but is against what our library should support.

PTAL

If those are all the places we talk about multiple kinds, then LGTM.

Yep!


Posting "text" results in "Missing Posting Authority "

Expected behaviour
That I would be able to post the following text:
Imagining two persons talking about their sandals:

> Person 1: So, what brand are your sandals?
Person 2: Mine? A unique design... its called, <public_key_that_generated_the_AI_drawing> 😂
Person 1: Oh... they are so nice! Can I have one pair for myself?
Person 2: Sure, send me some money to <public_key_that_generated_the_AI_drawing> and I will ship you one!

Did I just create a business? LOL

Actual behavior
An error message saying "Missing Posting Authority "
Steps to reproduce the behavior
Use the text above to post a comment, while using the posting key (via steemconnect).
Does it work if posting other texts?
YES, for example, "abc123" works fine...

Example on SteemHunt for example:

On eSteem also gives an error about the SDK...

Multiple users with problems now...

Now sorted. Thanks @bonustrack


Text not pixelated enough on Safari

Because of Safari's extra-chunky antialiasing, the text shows up less pixelated-looking than it should. This might happen with other browsers on Mac too.

This was fixed in release 2.0b2, but the kerning is a little off now. I'm not sure there's a way to fix that besides an update to the font itself, though.


Deploy first version of CI - amd64, linux

The goal for the first version of CI (amd64; linux) is the following:

[x] src/: safety checks; sct; extraction to EasyCrypt; compilation from Jasmin to assembly ~(-ATT and -intel)~ (will be addressed separately)
[x] test/: checksums and valgrind
[x] bench/: for a reduced number of timings, check if compilation is possible
[x] proof/: extracted files are processed by EasyCrypt

Note: Functional correctness proofs will be handled in a separate issue.

https://github.com/formosa-crypto/formosa-25519/commit/2cd0a8cbc2e58f3aa395b2cea5e9d2adb6775e73


Update About Section

If possible, update your About section with more skills glyphs.

Added skills glyphs to about section and refactored relevant CSS for a good UI.


Can first node in rule chain be a Server service?

Can the server service (e.g. http server、.....) be the first node in the rule chain?

The Server service  in RuleGo is known  as endpoint. It enables configuration in the rule chain DSL, which is configured under the metadata.endpoints section. For further details, refer to the documentation .

example:
{
  "ruleChain": {
    "id": "withHttpEndpoint",
    "name": "Built in HTTP input rule chain"
  },

  "metadata": {
    "endpoints":[
      {
        "id": "e1",
        "type": "http",
        "name": "http server",
        "configuration": {
          "server": ":9090"
        },
        "routers": [
          {
            "id":"r1",
            "params": [
              "POST"
            ],
            "from": {
              "path": "/api/v1/test",
              "configuration": {
              }
            },
            "to": {
              "wait": true,
              "processors": ["responseToBody"]
            }
          }
        ]

      }
    ],
    "nodes": [
      {
        "type": "jsFilter",
        "name": "filter",
        "debugMode": true,
        "configuration": {
          "jsScript": "return msg.temperature>10;"
        }
      }
    ],
    "connections": [

    ]
  }
}


Grouping Cluster

I am using the library for one of my project, but I was wondering if it is possible to cluster my marker by group. For example, I want to cluster only markers that are "Friends" and cluster the others who are only "Coworker" and etc... (Maybe not the best example, but I hope that you understand)
My idea was to use multiple ClusterManager but I didn't tried it and don't really know if it is the best solution or even a good solution.
Thanks for the reply.

@broady How do you set different related GoolgeMap listeners for two different ClusterManagers simultaneously?

@broady I tried it for multiple cluster managers and the listeners are applied only to the latest cluster manager that the listeners are being set to. Could you handle this in the library or atleast suggest a way to handle it ?

Hello,
I have the same problem for using multiple cluster managers. Does any one found a solution for that?
Thank you in advance

Hello,
I'm facing the same problem. I can't figure out how to handle multiple cluster managers. My listeners are applied only to the latest cluster manager. Does anyone have a solution?
Many thanks.

Hi qthurier,
Well, I did not find any other solution but to use 'n' cluster manager with associated 'n' cluster renderer. This solution worked for me. All you have to do is to ensure you set data to respective appropriate cluster manager.
As far as listeners are concerned you can always get respective manager with a bit dirty way, need to use onMarkerClick listener only. Example: At the time of adding Marker to manager ensure you set either title or snippet as "Pizza" and add it to respective manager i.e. PizzaManager. Then upon click of Marker, onMarkerclick will be invoked and there you can check for title/snippet and can retrieve respective manager or renderer.
I know this not at all a good way but thats how it works with this library.
Hope this helps!

Hi ! i'm facing the same issue, i can't figure out how to manage multiple cluster managers to make cluster groups as we can do in "android-maps-extension".
I'm not sure i understand your solution @jaayesh, which manager's listeners are you binding with the map ? Like @qthurier said if you declare 3 Cluster Manager, you need to bind setOnCameraChangeListener and setOnMarkerClickListener to a manager not 3, so how do you perform your trick ? Maybe a little example would help ? :)
Thanks !

Any solutions?

I'm also looking for this

For this you can implement OnCameraMoveListener and on moving of zooming of map you can force to clustermanger to make cluster. Like this,
if (mClusterManager != null)
mClusterManager.cluster();

@jaayesh how to add multi cluster manager in a map? I try with
mMap.setOnCameraChangeListener(new GoogleMap.OnCameraChangeListener() {
@Override
public void onCameraChange(CameraPosition cameraPosition) {
mClusterManager1.onCameraChange(cameraPosition);
mClusterManager2.onCameraChange(cameraPosition);
}
});
but it can't. Can you share your code add multiple cluster manager?

What exactly do you mean by, "how to add multi cluster manager in a map?", if you want to update respective cluster manager with respect to map's camera change event, you need to call manager.cluster()

setOnCameraChangeListener is now deprecated. You can use setOnCameraIdleListener.
Calll cluster method on each clusterManager:
mMap.setOnCameraIdleListener(new GoogleMap.OnCameraIdleListener() {
             @Override
             public void onCameraIdle() {
                 for (ClusterManager<MarkerClusterItem> cm:clusterManagerList)
                 {
                     cm.cluster();
                 }
             }
         });

    googleMap.setOnCameraIdleListener(new GoogleMap.OnCameraIdleListener() {
        @Override
        public void onCameraIdle() {
            clusterManager.cluster();
            clusterManager2.cluster();
        }
    });

When using multiple ClusterManager, the listeners are still overwritten by the latest ClusterManager.
private lateinit var clusterManagerA: ClusterManager<AItem>
private lateinit var clusterManagerB: ClusterManager<BItem>

override fun onMapReady(googleMap: GoogleMap) {
    clusterManagerA = ClusterManager(this, googleMap)
    clusterManagerA.setOnClusterItemInfoWindowClickListener {
        Log.d(TAG, "clusterManagerA onClusterItemInfoWindowClick")
    }
    clusterManagerA.addItem(AItem())

    clusterManagerB = ClusterManager(this, googleMap)
    clusterManagerB.setOnClusterItemInfoWindowClickListener {
        Log.d(TAG, "clusterManagerB onClusterItemInfoWindowClick")
    }
    clusterManagerB.addItem(BItem())
}

Now when I click on the InfoWindow of:

AItem: Nothing happens
BItem: It shows the log message

Is there a solution/workaround for this?

I know this might be late, but it might help someone who encounters this poorly documented issue in the future.
To successfully add multiple clusters to Google Maps that work independently, the most important and often overlooked step is to add:
`MarkerManager markerManager = new MarkerManager(gMap);`

You then use this MarkerManager to create your clusters:
```

ClusterManager clusterManagerA = new ClusterManager<>(this, gMap, markerManager);
ClusterManager clusterManagerB = new ClusterManager<>(this, gMap, markerManager);

Notice that both clusters are created using **the same MarkerManager, and this is essential**. If you create two different MarkerManager instances, only the last ClusterManager you defined (in this case, clusterManagerB) will handle the clicks and other interactions, effectively ignoring the first one.

I'm not 100% sure why this happens, but my educated guess, which I’m about 90% confident in, is that when you create a ClusterManager tied to the map without passing a MarkerManager like this:

   ` ClusterManager<MyClusterItemA> clusterManagerA = new ClusterManager<>(this, gMap);`

it defaults to creating a new MarkerManager, as can be seen in the constructor:

        ```
public ClusterManager(Context context, GoogleMap map) {
        this(context, map, new MarkerManager(map));
    }

This means the previous MarkerManager associated with the map is effectively replaced (as indicated by new MarkerManager(map)), capturing all click events.
However, if you use the constructor where you pass an existing MarkerManager, then it simply adds the clicks from the new cluster to the same MarkerManager. Here’s the constructor code for reference:
    ```

public ClusterManager(Context context, GoogleMap map, MarkerManager markerManager) {
mMap = map;
mMarkerManager = markerManager;
mClusterMarkers = markerManager.newCollection();
mMarkers = markerManager.newCollection();
mRenderer = new DefaultClusterRenderer<>(context, map, this);
mAlgorithm = new ScreenBasedAlgorithmAdapter<>(new PreCachingAlgorithmDecorator<>(
new NonHierarchicalDistanceBasedAlgorithm()));
mClusterTask = new ClusterTask();
  mRenderer.onAdd();
}

So, the key takeaway is to create a shared MarkerManager before creating multiple clusters and pass that same MarkerManager to each ClusterManager.


Raise appropriate exception when upload fails.

Closes #1717.

LGTM

@tseaver This is #1717. Which issue is this supposed to close?

Ahhh I see in the branch name #1712.


Introduce ability to pre-parse Request's query

This would allow user to avoid parsing query himself in order to determine its semantics
@sunli829 This is a bit specialized use case that I found myself in need.
Right now it is difficult to determine type of operation to finalize query context (in our case it is selection of Database: whether to use replica or primary)
So I made this split which would allow to parse, check operation type and then finalize execution.
It does require our database connection to be customizable without mutable reference to Data which is inconvenient but can be worked around with almost zero overhead (which is better than we parse query twice 😄 )

LGTM👏🏻, but there seems to be an issue that changes the execution order of the extension callbacks.
thread 'test_extension_call_order' panicked at 'assertion failed: `(left == right)`
[496](https://github.com/async-graphql/async-graphql/runs/6033591760?check_suite_focus=true#step:6:496)
  left: `["prepare_request_start", "prepare_request_end", "parse_query_start", "parse_query_end", "validation_start", "validation_end", "request_start", "execute_start", "resolve_start", "resolve_end", "resolve_start", "resolve_end", "execute_end", "request_end"]`,
[497](https://github.com/async-graphql/async-graphql/runs/6033591760?check_suite_focus=true#step:6:497)
 right: `["request_start", "prepare_request_start", "prepare_request_end", "parse_query_start", "parse_query_end", "validation_start", "validation_end", "execute_start", "resolve_start", "resolve_end", "resolve_start", "resolve_end", "execute_end", "request_end"]`', tests/extension.rs:270:9

Huh, strange, maybe I changed something after refactoring...
I'll check it out

@sunli829 Ah it makes sense, I wanted to avoid boxing future so I just split it into parts but now the lifecycle of extension changes 😞
I need to think on how to retain order

@sunli829 Hm looking back, it seems my idea is difficult to be implemented with current lifetime of extensions.
Would it be acceptable to change lifetime for two-time way to execute request, while retaining it the same for Schema::execute?

Another way to allow async_graphql::Request to pass in a parsed query, what do you think?

@sunli829 Since query is public method I cannot just replace it with enum that would have parsed variant.
Do you suggest to add parsed_query: Option<ExecutableDocument> 🤔

@sunli829 Since query is public method I cannot just replace it with enum that would have parsed variant.
Do you suggest to add parsed_query: Option<ExecutableDocument> 🤔

Yes, adding the parsed_query:Option<ExecutableDocument> field avoids breaking changes. 😁

@sunli829 I reworked my solution as per your suggestion.
Note that unfortunately it makes Request struct quite big so clippy started to complain about RequestBatch enum, and I had to silence it

@sunli829 I reworked my solution as per your suggestion.
Note that unfortunately it makes Request struct quite big so clippy started to complain about RequestBatch enum, and I had to silence it (cannot really break API for the sake of clippy, so maybe in major version bump)

I don't think it's a big problem, usually there won't be a lot of Request objects, so it's not a waste. 😂

I removed ParseQueryFut. 😁

Oh ok, no problem.
It is just habit of mine to use Future manually


Freezing the screen when capture button is pressed to indicate the pictu

...re has been taken and is being proccessed

Thank you again! Will be releasing as version 2.1.1


[WebSub]  Allow user to specify hub service/resource paths

Description:
$title, currently fixed as "/websub" and "/hub" respectively.

Done with https://github.com/ballerina-platform/ballerina-lang/pull/19599.


(FACT-3004) Disable by default external structured facts

External facts that use dot in their names will no
longer be converted to structured facts.
In order to convert all custom and external facts
to a structured, one needs to use set the
structured-external-facts to true in facter.conf

LGTM. This PR restores the old behavior of accessing fact names with dots:
❯ FACTER_LOCATION=file:///Users/josh/work/facter be puppet apply -e "include fact_test" --modulepath .
Notice: Compiled catalog for localhost in environment production in 0.03 seconds
Notice: [true]
Notice: /Stage[main]/Fact_test/Notify[fact dotcustom.array]/message: defined 'message' as '[true]'
Notice: {value => true}
Notice: /Stage[main]/Fact_test/Notify[fact dotcustom.hash]/message: defined 'message' as '{value => true}'
Notice: true
Notice: /Stage[main]/Fact_test/Notify[fact dotcustom.string]/message: defined 'message' as 'true'
Notice: true
Notice: /Stage[main]/Fact_test/Notify[fact dotcustom.symbol]/message: defined 'message' as 'true'
Notice: 12
Notice: /Stage[main]/Fact_test/Notify[fact dotcustom.aggregate.flat]/message: defined 'message' as '12'
Notice: [1, 2]
Notice: /Stage[main]/Fact_test/Notify[fact dotcustom.aggregate.structured]/message: defined 'message' as '[1, 2]'
Notice: true
Notice: /Stage[main]/Fact_test/Notify[fact dotdata.flat]/message: defined 'message' as 'true'
Notice: true
Notice: /Stage[main]/Fact_test/Notify[fact dotdata.json]/message: defined 'message' as 'true'
Notice: true
Notice: /Stage[main]/Fact_test/Notify[fact dotdata.yaml]/message: defined 'message' as 'true'
Notice: true
Notice: /Stage[main]/Fact_test/Notify[fact dotexe.flat]/message: defined 'message' as 'true'
Notice: true
Notice: /Stage[main]/Fact_test/Notify[fact dotexe.json]/message: defined 'message' as 'true'
Notice: true
Notice: /Stage[main]/Fact_test/Notify[fact dotexe.yaml]/message: defined 'message' as 'true'
Notice: Applied catalog in 0.02 seconds

This PR will break manifests relying on autoconversion and trying to access them as structured facts:
❯ pushd fact_test; git checkout facter4; popd
~/work/puppet/fact_test ~/work/puppet ~/work/modules/fact_test ~/work/modules ~/work/modules/fact_Test ~/work/facter ~/work/dotfiles ~
Switched to branch 'facter4'
Your branch is up to date with 'origin/facter4'.
❯ FACTER_LOCATION=file:///Users/josh/work/facter be puppet apply -e "include fact_test" --modulepath .
Notice: Compiled catalog for localhost in environment production in 0.03 seconds
Notice:
Notice: /Stage[main]/Fact_test/Notify[fact dotcustom.array]/message: defined 'message' as ''
Notice:
Notice: /Stage[main]/Fact_test/Notify[fact dotcustom.hash]/message: defined 'message' as ''
Notice:
Notice: /Stage[main]/Fact_test/Notify[fact dotcustom.string]/message: defined 'message' as ''
Notice:
Notice: /Stage[main]/Fact_test/Notify[fact dotcustom.symbol]/message: defined 'message' as ''
Notice:
Notice: /Stage[main]/Fact_test/Notify[fact dotcustom.aggregate.flat]/message: defined 'message' as ''
Notice:
Notice: /Stage[main]/Fact_test/Notify[fact dotcustom.aggregate.structured]/message: defined 'message' as ''
Notice:
Notice: /Stage[main]/Fact_test/Notify[fact dotdata.flat]/message: defined 'message' as ''
Notice:
Notice: /Stage[main]/Fact_test/Notify[fact dotdata.json]/message: defined 'message' as ''
Notice:
Notice: /Stage[main]/Fact_test/Notify[fact dotdata.yaml]/message: defined 'message' as ''
Notice:
Notice: /Stage[main]/Fact_test/Notify[fact dotexe.flat]/message: defined 'message' as ''
Notice:
Notice: /Stage[main]/Fact_test/Notify[fact dotexe.json]/message: defined 'message' as ''
Notice:
Notice: /Stage[main]/Fact_test/Notify[fact dotexe.yaml]/message: defined 'message' as ''
Notice: Applied catalog in 0.02 seconds

Enabling the global setting restores the Facter 4 behavior (up to 4.0.52):
❯ cat /etc/puppetlabs/facter/facter.conf
global : {
  structured-external-facts : true
}

❯ FACTER_LOCATION=file:///Users/josh/work/facter be puppet apply -e "include fact_test" --modulepath .
Notice: Compiled catalog for localhost in environment production in 0.03 seconds
Notice: [true]
Notice: /Stage[main]/Fact_test/Notify[fact dotcustom.array]/message: defined 'message' as '[true]'
Notice: {value => true}
Notice: /Stage[main]/Fact_test/Notify[fact dotcustom.hash]/message: defined 'message' as '{value => true}'
Notice: true
Notice: /Stage[main]/Fact_test/Notify[fact dotcustom.string]/message: defined 'message' as 'true'
Notice: true
Notice: /Stage[main]/Fact_test/Notify[fact dotcustom.symbol]/message: defined 'message' as 'true'
Notice: 12
Notice: /Stage[main]/Fact_test/Notify[fact dotcustom.aggregate.flat]/message: defined 'message' as '12'
Notice: [1, 2]
Notice: /Stage[main]/Fact_test/Notify[fact dotcustom.aggregate.structured]/message: defined 'message' as '[1, 2]'
Notice: true
Notice: /Stage[main]/Fact_test/Notify[fact dotdata.flat]/message: defined 'message' as 'true'
Notice: true
Notice: /Stage[main]/Fact_test/Notify[fact dotdata.json]/message: defined 'message' as 'true'
Notice: true
Notice: /Stage[main]/Fact_test/Notify[fact dotdata.yaml]/message: defined 'message' as 'true'
Notice: true
Notice: /Stage[main]/Fact_test/Notify[fact dotexe.flat]/message: defined 'message' as 'true'
Notice: true
Notice: /Stage[main]/Fact_test/Notify[fact dotexe.json]/message: defined 'message' as 'true'
Notice: true
Notice: /Stage[main]/Fact_test/Notify[fact dotexe.yaml]/message: defined 'message' as 'true'
Notice: Applied catalog in 0.02 seconds


if token limit reached in OpenAI API, client hangs

Related: https://github.com/vllm-project/vllm/issues/525
Repro:

Start vllm, e.g.

export NCCL_IGNORE_DISABLED_P2P=1
export CUDA_VISIBLE_DEVICESs=0,1,2,3
python -m vllm.entrypoints.openai.api_server --port=5000 --host=<IP_ADDRESS> --model h2oai/h2ogpt-4096-llama2-70b-chat --tokenizer=hf-internal-testing/llama-tokenizer --tensor-parallel-size=4 --seed 1234

Connect via OpenAI API and make prompt too large (> 2560).

This appears to be fixed as of v0.2.0

In particular, it appears to have been fixed in #1029

I'll close assuming fixed


Native environment location locator customization request

Please can this behavior be made optional? We use the native environment to back the config server with an internal website which our internal deployment tools are able to manage and control.
We want the search locations that we specify to be honored in the order that we specify them so that we can implement a hierarchy of general environment properties, project-wide properties then service-specific properties in that order. This kind of works until the auto-labeling logic is hit and we get an unwanted search location tacked on.
If we could just have a property that says 'don't interfere with our search locations' then that would be great. Currently I've had to copy-paste the whole source to the native repository into my own very similar custom version. Unfortunately I can't extend the native repository because most of the member variables are private (why?)

Another thing is that the looping logic in getLocations() tends to produce duplicates in the output ArrayList. Spring seems to be smart enough to know about these further up the chain and not hit my http server with duplicate requests but it's so simple to not create the duplicates in the first place.
All that's required is to change this line from:
List<String> output = new ArrayList<String>();

to:
Collection<String> output = new LinkedHashSet<>();

Duplicates are eliminated at source and append order is preserved.


Make it so InYourFace and Incredibly-inyourface are one

Overview
Making it so you can toggle in the settings.
What happens to the other
Make it a public archive

Thats a great idea however I'm quite busy with uni at the moment and won't be able to do this myself so if anyone wants to make a pull request in the mean time I'd be more than happy to publish that


tablet list item layout

Fix list item layout for tablet (large).
In tiny tablets, overlaps title and description with temperatures

fixed!


Be Cool If . . .

would be super cool if this could output in JSON - just sayin' 🙃😏😉

I think that would be fairly trivial. What data would you want in a JSON file? That is, what would you want it to look like so that you can parse it? The text is not difficult to parse. Can JSON deal with large integers? The code as it stands has no upper limit beyond available memory.


Propagate mousewheel event if ctrl key is pressed.

Typical browser behaviour allow us to zoom the page in/out by mouse wheel with control key pressed. It would be better if this behaviour still the same (Issue #319).
My change have been made and tested with Windows PC in Chrome and IE. I thought about Macs and I tried to test it on OS X Yosemite but it has no zoom feature by mousewheel at all. I googled how it can be enabled and found the following topic http://forums.macrumors.com/threads/zoom-with-control-mouse-wheel.1411306/ But after enabling "Use scroll gesture with..." nothing has changed and I decided to leave it as it is. By the way, jQuery.mousewheel event has no property commandKey and it should be determined by keyCode :)

Hi, any idea why your solution was not merged yet? Is there a better way of achieving the same result? Thanks for reply

Hi! Actually I have no idea sorry :)
BTW, finally I've modified the library about 10 times and now we are using this custom version for more than one year. It's really the best library for scrolling.

would be better, if it's an option rather than the default behaviour


Migrate to v4 version of aws provider

v4 deprecates policy argument in aws_s3_bucket resource[1], therefore users who would like to have this functionality should create aws_s3_bucket_policy.
[1] https://registry.terraform.io/providers/hashicorp/aws/latest/docs/guides/version-4-upgrade#policy-argument

@dolohow thanks for your contribution and your patience. Sorry, that this one took a lot longer to get back to.

Released in v1.6.0


rbenv: bundle: command not found

I am still experiencing this problem and I already tried the rbenv-rbx plugin but that doesn't do squat for me.

The `bundle' command exists in these Ruby versions:
2.0.0-p195
2.0.0-p247

I don't think this is a rubinius issue but rather a rbenv or ruby-build issue. What is your take on it?
On Mac OS X Mavericks with XCode 5 and latest rbenv/ruby-build through homebrew.

This may be a bit naive as I am pretty new to ruby, but for me I just needed to run gem install rails to fix this error message after installing ruby 2.4.0


Missing metrics if there are over 1000 nodes in a cluster

Is there an existing issue for this?

[X] I have searched the existing issues

What happened?
Prometheus-operator only detects up to 1000 endpoints per ServiceMonitor. So if you have over 1000 nodes, you will be missing Cilium metrics for a subset of them.
Cilium Version
all
Kernel Version
n/a
Kubernetes Version
n/a
Sysdump
No response
Relevant log output
No response
Anything else?
Upstream bug: https://github.com/prometheus-operator/prometheus-operator/issues/3862
A workaround is to use PodMonitor instead of ServiceMonitor, example: https://github.com/prometheus-community/helm-charts/pull/2866
Code of Conduct

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

So  a simple fix would be for us to add an option to create PodMonitors instead of ServiceMonitors. That seems fairly simple. @dctrwatson would you be interested in opening a PR for that?


I need help error 2019

hey having this problem for a while and I need help.
Error:
Severity	Code	Description	Project	File	Line	Suppression State Error	LNK2019	unresolved external symbol "class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > __cdecl Guess(void)" (?Guess@@YA?AV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@XZ) referenced in function "void __cdecl PrintBack(void)" (?PrintBack@@YAXXZ)	Section_2	C:\Users\zcrea\Downloads\Video Game Making C++\Section_2\Section_2\main.obj	1
My Code:
`#include
#include "FBullCowGame.h"
#include
bool AskToPlayAgain();
void PrintBack();
void Game();
int main();
void PrintIntro();
void PlayGame();
std::string GetGuess();
std::string Guess();
int main()
{
bool bWantsToPlayAgain = false;
do {
PrintIntro();
	PlayGame();

	bWantsToPlayAgain = AskToPlayAgain();

	std::cout << std::endl;
}
while (bWantsToPlayAgain);
return 0;

}
void PrintIntro() {
//introduction
constexpr int WORD_LENGTH = 9;
std::cout << "Welcome to Bulls and Cows! This is a word game\n";
std::cout << "Can you guess the " << WORD_LENGTH;
std::cout << " letter of the isogram I'm thinking of???\n";
std::cout << std::endl;
return;

}
void PlayGame()
{
FBullCowGame BCGame;
int MaxTries = BCGame.GetMaxRetries();
std::cout << MaxTries << std::endl;
// loop for the number of turn asking for guesses
for (int count = 1; count <= MaxTries; count++)
{
	Game();
	std::cout << std::endl;
}

}
void Game() {
GetGuess();
PrintBack();
return;
}
std::string GetGuess() {
//get a guess from the player
std::cout << "Whats your guess?";
std::cout << std::endl;
std::string Guess = "";
getline(std::cin, Guess);
return Guess;
}
void PrintBack() {
// repeat the guess
std::cout << "Your guess was " << Guess;
std::cout << " ";
std::cout << std::endl;
std::cout << " ";
std::cout << std::endl;
return;

}
bool AskToPlayAgain() {
std::cout << "Do you want to play again?(y/n)\n";
std::string Response = "";
getline(std::cin, Response);
return (Response[0] == 'y') || (Response[0] == 'Y');
do {
main();
} while (Response[0] = 1);
}`

might need to #include iostream

hey i too don't understand linker errors but i have a temporary solution, just change 👍
in main:
#include "FBullCowGame.h" to #include "FBullCowGame.cpp"
don't delete the .h file tho it works ,hope it was helpful


Game crashes upon accessing the Alloy Forge

Game Version: 1.19.2
Mod Version: 0.16.4
Log: https://pastebin.com/F21GPxLc
Mod List: https://ctrlv.link/STOx

Duplicate of #135


Info about append_event

@mpraglowski Please take a look. I've added paragraph about appending events.

@brissenden +1
However it is hard to check what has changed based on commit :( we need some improvement here ;)


Remove mkPackage from template

mkPackage, the little function that never quite was :cry: :trumpet: (<-- this plays Taps, or auld lang syne, depending on your religion)
https://github.com/purescript/package-sets/pull/399

While I have no solution for the emoji rebus, I think we should also output a warning for folks that still have it in their packages.dhall (i.e. either traverse the AST or just grep searching for "mkPackage"), so that they can migrate and we can remove it from package-sets when releasing 1.0


Update CONTRIBUTING.md

Add the procedure when signing was forgotten.
Signed-off-by: Takuya Nakaike<EMAIL_ADDRESS>

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


Toplevel printers are incomplete

In particular, they don't nicely print structure fields, and also anonymous structures:
# #require "ctypes.top";;
# open Ctypes;;
# let struc = Ctypes.structure "";;
# let r = field struc "r" float;;
# let g = field struc "g" float;;
# let b = field struc "b" float;;
# let a = field struc "a" float;;
# seal struc;;
# struc;;
- : '_a Static.structure typ = struct  { float r; float g; float b; float a;  }
# let uni = union "";;
# field uni (array 4 float);;
# let floats = field uni "rgba" (array 4 float);;
# let struc' = field uni "" struc;;
# seal uni;;
# uni;;
- : '_a Static.union typ = union  { float rgba[4]; struct  ;  }
# let struc'' = structure "NVGcolor";;
# field struc'' "" uni;;
# seal struc'';;
# struc'';;
- : '_a Static.structure typ = struct NVGcolor { union  ;  }
# typedef struc'' "NVGcolor";;
- : '_a Static.structure typ = NVGcolor

I agree that this can be considered a bug and should be fixed.  Structs and unions are printed differently in different contexts: the full type is printed in a top-level context, and the abbreviated type (struct tag or union tag) is printed in other contexts.  We should use the top-level printing code in (almost) all contexts where we don't have tags available.
We'll also need to fix the code that retrieves field offsets to handle anonymous struct and union members.  There are a couple of cases that I expect are broken currently:

retrieving the layout of an struct without a tag
struct { int x, y; }

We can (mostly) fix this one with better typedef support.

retrieving the layout of a structure with anonymous fields
struct t { union u { int x; char y; } };

We can fix this one by retrieving the layout of the first member instead of the field.  (We may have to descend through a few types to find the first member, but we should always find one eventually, since C doesn't allow empty structs or unions.)

I think there are a few obscure cases that we won't be able to handle properly such as the following code which introduces a new type but no way of referring to it:
struct { int x, y } *foo(void) { ... }

I'd be surprised to see this sort of thing in real code, though.

The latter is, I think, actually a bug in C. Maybe not a bug, but compilers generally complain loudly about such code, so it is not important.


Reconsider yeoman as the generator

yeoman is actually pretty heavy weight for someone getting started. It has a ton of dependencies, so there's a lot more chances for things to go wrong at install time.
Some recent issues:

https://github.com/github/generator-hubot/issues/53
https://github.com/github/generator-hubot/issues/51
https://github.com/github/generator-hubot/issues/56

Some ideas:

go back to rolling our own
web based generator for creating a hubot?

My two favorites as a web version, or just forking a good example repo.
I personally like the idea of a web based generator, though it seems like it could be a bit of an effort to maintain and setup. However, the idea of selecting an adapter, possibly a deployment destination and a few starter scripts seems like a fairly straight forward process that would be easy to get started with.
This actually seems to be a little bit like http://chato.ps 's setup process, I think.
For many projects, I really like the idea of a starting point repo that can just be forked / cloned. I forget how exactly I setup my hubot a while ago, but I think I basically started off with a clone of a similar group's hubot setup. For Heroku related stuff, the "Deploy to Heroku" button works pretty well. HipChat has an example bot setup like this (https://github.com/hipchat/triatomic).

Found this ticket after looking around to see if there was a known issue with the yeoman generator.
We've had several people drop by in our support channel with the issue described here: https://github.com/RocketChat/hubot-rocketchat/issues/114
We're thinking about changing our instructions and removing the suggestion for using yeoman. Instead putting up a repo with our adapter setup, so they can just clone it.
Granted doing so, we're going to have to include a few more FAQ's to handle Bot renaming, etc.
I'd love to see a web based generator.  If it could be done to just spit out a single JSON file, you could probably put on the hubot site and the generate the JSON file client side.  Prevent the need to stand up infrastructure.

Another idea tossed around has been a create repo, ie as described in https://yarnpkg.com/lang/en/docs/cli/create/

@geekgonecrazy - Did you ever end up creating a repo?
Using yeoman on Amazon linux is just a complete nightmare.
There are a lot of threads complaining about the same issue (running as root, permissions, sudo, etc) -- found 6-7 of them, all like this one: https://github.com/yeoman/yeoman.github.io/issues/282
It's really frustrating when you just want to get started with hubot.

@ventz I believe our bot team has as it yeoman gave us a lot of headache.
https://github.com/RocketChat/hubot-rocketchat-boilerplate

@geekgonecrazy - Thanks!

I think we should not use or recommend yeoman to generate a new "bot" because it's added complication with not enough value, imho.
I currently believe that the problem statement is "I want to run a chat bot and after some research, I've decided on leveraging Hubot. And so I want to create a new git repo of scripts that I can package, deploy and run as an instance of Hubot somewhere."
Given that, I propose the following recipe.
mkdir myhubot
cd myhubot
npm init -y
npm i coffeescript hubot

At this point, they theoretically could start Hubot with:
npx hubot -a slack
or
npx hubot which will run the shell adapter by default.
But there are no scripts yet and they haven't configured a Slack App, nor setup a way for the adapter to get the required credentials from the environment. So there's still some work for them to do before they're really up and running.
I think we should start with updating the docs with the above recipe and start including recipes for more complicated scenarios, in an incremental fashion. An example of that would be:
Development Setup
Execute the following commands to create the initial codebase.
mkdir myhubot
cd myhubot
npm init -y
npm i coffeescript hubot
npx hubot

Executing npx hubot will use the builtin Shell adapter by default, but since there are no scripts yet, Hubot won't know any commands. To add your first command, execute the following:
mkdir scripts
touch scripts/Test.js

Edit the new Test.js file and type the following ....
I can update the Getting Started page to include some recipes for development.

I think there is value in having a quickstart for using Hubot. There are lots of examples out there of tooling to simplify getting started, like Rails' new app generator, create-react-app, and others.
The generator was originally builtin hubot itself, but it has been awhile so I don't recall why we moved to yeoman. IIRC, it was gaining popularity as a generator.
A repository template would be a pretty lo-fi way to have a quick start, and not have any moving parts to worry about?

I currently believe that the problem statement is "I want to run a chat bot and after some research, I've decided on leveraging Hubot. And so I want to create a new git repo of scripts that I can package, deploy and run as an instance of Hubot somewhere."

That is the exact train of thought that led me here :slightly_smiling_face:

Given that, I propose the following recipe.
mkdir myhubot
cd myhubot
npm init -y
npm i coffeescript hubot

Seconded

@technicalpickles I don't have permissions to create repos for this org. Do you want to create the repo template?

I merged the PR to remove yeoman. Let me know if ya'll want to discuss further and we can re-open this issue.


Potential races

Path A:

peer_manager::async_recv's lambda runs from the sockets's executor
Calls peer_manager::disconnect

Modifies _connections while running from the sockets's executor
This can happen from multiple sockets' executors

Calls websocket_connection::close
Modifies closed while running from the sockets's executor

Path B:

main's http_config->disconnect inner lambda runs from chainContext
Calls peer_manager::disconnect

Modifies _connections while running from chainContext

Calls websocket_connection::close
Modifies closed while running from chainContext

There appear to be more paths to websocket_connection::close.

peer_manager::async_recv dispatches back to chainContext before calling disconnect.


feat: split forest cli and daemon

Summary of changes
Changes introduced in this pull request:

[x] split forest crate into cli, daemon and shared
[x] update Makefile accordingly
[x] update readme.md accordingly
[x] update dockerfile setup accordingly
[x] update CI setup accordingly

Reference issue to close (if applicable)

Closes https://github.com/ChainSafe/forest/issues/1901
Other information and links

As far as I understand forest/cli/src/cli/mod.rs is mostly old forest/cli/mod.rs. Could it be rewired to the old file, so that the history is maintained?

Same question forforest/shared/src/cli/client.rs from https://github.com/ChainSafe/forest/pull/1973#issuecomment-1268187808

Hey @tyshko5 that's good points, I have managed to rewired client.rs but not mod.rs cuz we still have 3 new files and because of https://git.wiki.kernel.org/index.php/GitFaq#Why_does_Git_not_.22track.22_renames.3F it does not seem possible to manually wire it, I've added a comment at the header of the new file with the link to the lost commit history

Besides adjusting the infrastructure code to the new API, splendid job @hanabi1224!


Fix issue bandit scheduler

Description
Fixes the BanditScheduler class because it could sometimes have unexpected number of active emitters.
Done

[x] Added a check that enough emitters are active (before PR: only checked if there was 0 active emitters)
[x] Added a check that there are not too many active emitters
[x] Both checks comply with the BanditScheduler's expected behaviour, i.e.:
- activate emitters that were never used, if there are none, those that are expected to perform better
- deactivate least performing emitters first

Questions

[ ] I am quite sure this is not the most efficient way to do this, which would slow down any use of the BanditScheduler. I would appreciate any feedback on how to improve this.
[ ] I added a test, but it seems more complicated than other tests of the file. Should I put it somewhere else?

Status

[x] I have read the guidelines in
CONTRIBUTING.md
[x] I have formatted my code using yapf
[x] I have tested my code by running pytest
[x] I have linted my code with pylint
[x] I have added a one-line description of my change to the changelog in
HISTORY.md
[ ] This PR is ready to go

To be honest this is also a fix I did months ago because I ran into the issue. I was not sure about my fix at the time, so that’s why I am proposing one only now.
It happened when I had both classic MAP-Elites and CMA-ES emitters in the emitters pool, so I think it is because these 2 have different periods of activity.
I should be able to provide an example to reproduce next week.

That's weird because this line in ask seems to check for emitters like GaussianEmitter that do not have a restarts attribute and thus can be considered as "always restarting."
I'll take a look at the example when it's ready. Thanks!

Here is an example where the number of active emitters is not the stable without my fix, and it is stable with my fix.
I am sorry this is long, I tried to make it as simple as possible.
I just found out that there is still a problem even with my fix, because if you comment the GaussienEmitter in emitters in the example I provide, the number of active emitters is not stable in both version of BanditScheduler. I am working on it and will update if I find a solution.
import tqdm

from ribs.archives import GridArchive
from ribs.schedulers import BanditScheduler
from ribs.emitters import EvolutionStrategyEmitter, GaussianEmitter

class DebugBanditScheduler(BanditScheduler):
    def ask(self):
        """Generates a batch of solutions by calling ask() on all active
        emitters.

        The emitters used by ask are determined by the UCB1 algorithm. Briefly,
        emitters that have never been selected before are prioritized, then
        emitters are sorted in descending order based on the accurary of their
        past prediction.

        .. note:: The order of the solutions returned from this method is
            important, so do not rearrange them.

        Returns:
            (batch_size, dim) array: An array of n solutions to evaluate. Each
            row contains a single solution.
        Raises:
            RuntimeError: This method was called immediately after calling an
                ask method.
        """
        if self._last_called == "ask":
            raise RuntimeError("ask cannot be called immediately after " +
                               self._last_called)
        self._last_called = "ask"

        if self._reselect == "terminated":
            # Reselect terminated emitters. Emitters are terminated if their
            # restarts attribute have incremented.
            emitter_restarts = np.array([
                emitter.restarts if hasattr(emitter, "restarts") else -1
                for emitter in self._emitter_pool
            ])
            reselect = emitter_restarts > self._restarts

            # If the emitter does not have "restarts" attribute, assume it
            # restarts every iteration.
            reselect[emitter_restarts < 0] = True

            self._restarts = emitter_restarts
        else:
            # Reselect all emitters.
            reselect = self._active_arr.copy()

        # If not enough emitters are active, activate the first num_active.
        num_needed = self._num_active - self._active_arr.sum()
        i = 0
        while num_needed > 0:
            reselect[i] = False
            if not self._active_arr[i]:
                self._active_arr[i] = True
                num_needed -= 1
            i += 1

        # Deactivate emitters to be reselected.
        self._active_arr[reselect] = False

        # Select emitters based on the UCB1 formula.
        # The ranking of emitters also follows these rules:
        # - Emitters that have never been selected are prioritized.
        # - If reselect is "terminated", then only active emitters that have
        #   terminated/restarted will be reselected. Otherwise, if reselect is
        #   "all", then all emitters are reselected.
        if reselect.any():
            ucb1 = np.full_like(
                self._emitter_pool, np.inf
            )  # np.inf forces to select emitters that were not yet selected
            update_ucb = self._selection != 0
            if update_ucb.any():
                ucb1[update_ucb] = (
                    self._success[update_ucb] / self._selection[update_ucb] +
                    self._zeta * np.sqrt(
                        np.log(self._success.sum()) /
                        self._selection[update_ucb]))
            # Activate top emitters based on UCB1.
            activate = np.argsort(ucb1)[-reselect.sum():]
            self._active_arr[activate] = True

            # Deactivate emitters if there are too many active emitters.
            nb_deactivate = self.emitters.sum() - self._num_active
            deactivate = np.argsort(ucb1)
            for i in deactivate:
                if nb_deactivate == 0:
                    break
                if self._active_arr[i]:
                    self._active_arr[i] = False
                    nb_deactivate -= 1

        self._cur_solutions = []

        for i in np.where(self._active_arr)[0]:
            emitter = self._emitter_pool[i]
            emitter_sols = emitter.ask()
            self._cur_solutions.append(emitter_sols)
            self._num_emitted[i] = len(emitter_sols)

        # In case the emitters didn't return any solutions.
        self._cur_solutions = np.concatenate(
            self._cur_solutions, axis=0) if self._cur_solutions else np.empty(
                (0, self._solution_dim))
        return self._cur_solutions

# set the random seed
np.random.seed(0)

qd_score_me_me = []

nb_variables = 7
nb_emitters = 5
nb_generations = 100
nb_dimensions = 2

archives = [
    GridArchive(
        solution_dim = nb_variables,
        dims = [10] * nb_dimensions,
        ranges = [(-2, 2)] * nb_dimensions
    ) for i in range(2)
]

me_map_elites_archives = archives[0]
me_map_elites_archives_debug = archives[1]

emitters = [
[  # Create a pool of different emitters
    EvolutionStrategyEmitter(
        archive = me_map_elites_archives,
        x0 = [0.5] * nb_variables,  # This is arbitrary
        sigma0 = 0.3,
        ranker = "2imp",
    ) for i in range(nb_emitters * 2)
]
+
[
        GaussianEmitter(
        archive = me_map_elites_archives,
        x0 = [0.5] * nb_variables,
        sigma = 0.3,
    ) for i in range(nb_emitters * 2)
]
for j in range(2)]

emitters_me_map_elites = emitters[0]
emitters_me_map_elites_debug = emitters[1]

emitter_calls = np.array([0] * len(emitters_me_map_elites))

scheduler_me_map_elites = BanditScheduler(
    archive = me_map_elites_archives,
    emitter_pool = emitters_me_map_elites,
    num_active = nb_emitters
)

scheduler_me_map_elites_debug = DebugBanditScheduler(
    archive = me_map_elites_archives_debug,
    emitter_pool = emitters_me_map_elites_debug,
    num_active = nb_emitters
)

print("Starting ME-MAP-Elites")
for itr in tqdm.trange(1, nb_generations + 1):
    if itr % 10 == 0:
        print(f"Iteration {itr}/{nb_generations}")

    # === CLASSIC ME-MAP-Elites ===
    sols = scheduler_me_map_elites.ask()

    emitter_calls += scheduler_me_map_elites._active_arr

    obj_array = np.random.rand(len(sols))
    feat_array = np.random.rand(len(sols), nb_dimensions)

    scheduler_me_map_elites.tell(obj_array, feat_array)
    qd_score_me_me.append(me_map_elites_archives.stats.qd_score)

    if np.sum(scheduler_me_map_elites._active_arr) != nb_emitters:
        print("Classic - Nb. active emitters: "
              f"{np.sum(scheduler_me_map_elites._active_arr)}"
              f" instead of {nb_emitters}"
              f" at iteration {itr}")

    # === DEBUG ME-MAP-Elites ===
    sols_debug = scheduler_me_map_elites_debug.ask()

    obj_array = np.random.rand(len(sols_debug))
    feat_array = np.random.rand(len(sols_debug), nb_dimensions)

    scheduler_me_map_elites_debug.tell(obj_array, feat_array)
    qd_score_me_me.append(me_map_elites_archives_debug.stats.qd_score)
    if np.sum(scheduler_me_map_elites_debug._active_arr) != nb_emitters:
        print("Debug - Nb. active emitters: "
              f"{np.sum(scheduler_me_map_elites._active_arr)}"
              f" instead of {nb_emitters}"
              f" at iteration {itr}")

Now, everything works as intended. Below, I provide the updated example to make sure everything works. This examples shows that the fixes help when:

The emitter pool contains only EvolutionStrategyEmitter emitters, the previous version would not activate enough emitters (you need to comment the GaussianEmitter lines to illustrate this)
The emitter pool contain both EvolutionStrategyEmitter and GaussianEmitter emitters, the previous version would activate too much of them

import numpy as np
import tqdm

from ribs.archives import GridArchive
from ribs.schedulers import BanditScheduler
from ribs.emitters import EvolutionStrategyEmitter, GaussianEmitter

class DebugBanditScheduler(BanditScheduler):
    def ask(self):
        """Generates a batch of solutions by calling ask() on all active
        emitters.

        The emitters used by ask are determined by the UCB1 algorithm. Briefly,
        emitters that have never been selected before are prioritized, then
        emitters are sorted in descending order based on the accurary of their
        past prediction.

        .. note:: The order of the solutions returned from this method is
            important, so do not rearrange them.

        Returns:
            (batch_size, dim) array: An array of n solutions to evaluate. Each
            row contains a single solution.
        Raises:
            RuntimeError: This method was called immediately after calling an
                ask method.
        """
        if self._last_called == "ask":
            raise RuntimeError("ask cannot be called immediately after " +
                               self._last_called)
        self._last_called = "ask"

        if self._reselect == "terminated":
            # Reselect terminated emitters. Emitters are terminated if their
            # restarts attribute have incremented.
            emitter_restarts = np.array([
                emitter.restarts if hasattr(emitter, "restarts") else -1
                for emitter in self._emitter_pool
            ])
            reselect = emitter_restarts > self._restarts

            # If the emitter does not have "restarts" attribute, assume it
            # restarts every iteration.
            reselect[emitter_restarts < 0] = True

            self._restarts = emitter_restarts
        else:
            # Reselect all emitters.
            reselect = self._active_arr.copy()

        # If not enough emitters are active, activate the first num_active.
        # This always happens on the first iteration(s).
        num_needed = self._num_active - self._active_arr.sum()
        i = 0
        while num_needed > 0:
            reselect[i] = False
            if not self._active_arr[i]:
                self._active_arr[i] = True
                num_needed -= 1
            i += 1

        # Deactivate emitters to be reselected.
        self._active_arr[reselect] = False

        # Select emitters based on the UCB1 formula.
        # The ranking of emitters also follows these rules:
        # - Emitters that have never been selected are prioritized.
        # - If reselect is "terminated", then only active emitters that have
        #   terminated/restarted will be reselected. Otherwise, if reselect is
        #   "all", then all emitters are reselected.
        if reselect.any():
            ucb1 = np.full_like(
                self._emitter_pool, np.inf
            )  # np.inf forces to select emitters that were not yet selected
            update_ucb = self._selection != 0
            if update_ucb.any():
                ucb1[update_ucb] = (
                    self._success[update_ucb] / self._selection[update_ucb] +
                    self._zeta * np.sqrt(
                        np.log(self._success.sum()) /
                        self._selection[update_ucb]))
            # Activate top emitters based on UCB1, until there are num_active
            # active emitters. Activate only inactive emitters.
            activate = np.argsort(ucb1)[::-1]
            for i in activate:
                if self._active_arr.sum() == self._num_active:
                    break
                if not self._active_arr[i]:
                    self._active_arr[i] = True

        self._cur_solutions = []

        for i in np.where(self._active_arr)[0]:
            emitter = self._emitter_pool[i]
            emitter_sols = emitter.ask()
            self._cur_solutions.append(emitter_sols)
            self._num_emitted[i] = len(emitter_sols)

        # In case the emitters didn't return any solutions.
        self._cur_solutions = np.concatenate(
            self._cur_solutions, axis=0) if self._cur_solutions else np.empty(
                (0, self._solution_dim))
        return self._cur_solutions

# set the random seed
np.random.seed(42)

nb_variables = 7
nb_emitters = 3
nb_generations = 100
nb_dimensions = 2

archives = [
    GridArchive(
        solution_dim = nb_variables,
        dims = [10] * nb_dimensions,
        ranges = [(-2, 2)] * nb_dimensions
    ) for i in range(2)
]

me_map_elites_archives = archives[0]
me_map_elites_archives_debug = archives[1]

emitters_me_map_elites = [  # Create a pool of different emitters
    EvolutionStrategyEmitter(
        archive = me_map_elites_archives,
        x0 = [0.5] * nb_variables,
        sigma0 = 0.3,
        ranker = "2imp",
    ) for i in range(nb_emitters * 2)
] + [
    EvolutionStrategyEmitter(
        archive = me_map_elites_archives,
        x0 = [0.5] * nb_variables,
        sigma0 = 0.3,
        ranker = "2obj",
    ) for i in range(nb_emitters * 2)
] + [
        GaussianEmitter(
        archive = me_map_elites_archives,
        x0 = [0.5] * nb_variables,
        sigma = 0.3,
    ) for i in range(nb_emitters * 2)
]

emitters_me_map_elites_debug = [  # Create a pool of different emitters
    EvolutionStrategyEmitter(
        archive = me_map_elites_archives_debug,
        x0 = [0.5] * nb_variables,
        sigma0 = 0.3,
        ranker = "2imp",
    ) for i in range(nb_emitters * 2)
] + [
    EvolutionStrategyEmitter(
        archive = me_map_elites_archives_debug,
        x0 = [0.5] * nb_variables,
        sigma0 = 0.3,
        ranker = "2obj",
    ) for i in range(nb_emitters * 2)
] + [
        GaussianEmitter(
        archive = me_map_elites_archives_debug,
        x0 = [0.5] * nb_variables,
        sigma = 0.3,
    ) for i in range(nb_emitters * 2)
]

emitter_calls = np.array([0] * len(emitters_me_map_elites))

scheduler_me_map_elites = BanditScheduler(
    archive = me_map_elites_archives,
    emitter_pool = emitters_me_map_elites,
    num_active = nb_emitters
)

scheduler_me_map_elites_debug = DebugBanditScheduler(
    archive = me_map_elites_archives_debug,
    emitter_pool = emitters_me_map_elites_debug,
    num_active = nb_emitters
)

print("Starting ME-MAP-Elites")
for itr in tqdm.trange(1, nb_generations + 1):
    if itr % 10 == 0:
        print(f"Iteration {itr}/{nb_generations}")

    # === CLASSIC ME-MAP-Elites ===
    sols = scheduler_me_map_elites.ask()

    obj_array = np.random.rand(len(sols))
    feat_array = np.random.rand(len(sols), nb_dimensions)

    scheduler_me_map_elites.tell(obj_array, feat_array)

    if np.sum(scheduler_me_map_elites._active_arr) != nb_emitters:
        print("Classic - Nb. active emitters: "
              f"{np.sum(scheduler_me_map_elites._active_arr)}"
              f" instead of {nb_emitters}"
              f" at iteration {itr}")

    # === DEBUG ME-MAP-Elites ===
    sols_debug = scheduler_me_map_elites_debug.ask()

    obj_array = np.random.rand(len(sols_debug))
    feat_array = np.random.rand(len(sols_debug), nb_dimensions)

    scheduler_me_map_elites_debug.tell(obj_array, feat_array)

    if np.sum(scheduler_me_map_elites_debug._active_arr) != nb_emitters:
        print("Debug - Nb. active emitters: "
              f"{np.sum(scheduler_me_map_elites._active_arr)}"
              f" instead of {nb_emitters}"
              f" at iteration {itr}")


Need help on JOIN query with where on right table

Hi, I'm trying to do somthing really simple.
I've two models:
var users = baseModel.Model.extend({
  tableName: 'users',
  instructor: function () {
    return this.hasMany('Instructors');
  },
  ...
});

var instructors = baseModel.Model.extend({
  tableName: 'instructors',
  ...
  user_id: function(){
    return this.belongsTo('Users');
  },
  ...
});

I'm having difficulty on getting all users without any instructor related.
Can someone help me?
Thank you
Michele Bertuccioli

We're going to need details on your database schema in order to help.

First of all thank you.
The instructors table has a fk on the user_id column.
The relation is a one (or none)-to-one, the instructor must have an user reference, but the user can have no instructor associated.
Is that enough?

I've got what i need by using a custom knex query forcing the query builder to execute the leftjoin between the tables (by explict leftJoin() method invocation).
Now the question is: is this the best way to do such a thing with bookshelf?
Thank you.
Michele Bertuccioli

The project leadership of Bookshelf recently changed. In an effort to advance the project we close all issues older than one year.
If you think this issue needs to be re-evaluated please post a comment on why this is still important and we will re-open it.
We also started an open discussion about the future of Bookshelf.js here https://github.com/bookshelf/bookshelf/issues/1600. Feel free to drop by and give us your opinion.
Let's make Bookshelf great again


"PANCIU",  "Crucea de Jos ", "Crucea de Sus", "Dumbrava", "Neicu ", "Satu Nou" are listed in the drop-down menu

Description:
When user writes "PANCIU", "Crucea de Jos ", "Crucea de Sus", "Dumbrava", "Neicu ", "Satu Nou", the locations appear in the drop-down menu next to the Component localities of the city which is a part according to the law.
Precondition:
The website is up an running.

Step 1
Write in the search bar "PANCIU"

Expected results
The location appears in the drop-down menu as "Oras PANCIU, Vrancea (PANCIU)".

Step 2
Press "x" button.

Expected results
The location was deleted from the search bar.

Step 3
Write in the search bar "Crucea de Jos "

Expected results
The location appears in the drop-down menu as "Sat Crucea de Jos , Vrancea (PANCIUI)".

Step 4
Press "x" button.

Expected results
The location was deleted from the search bar.

Step 5
Write in the search bar "Crucea de Sus "

Expected results
The location appears in the drop-down menu as "Sat Crucea de Sus  Vrancea (PANCIU)".

Step 6
Press "x" button.

Expected results
The location was deleted from the search bar.

Step 7
Write in the search bar "Dumbrava "

Expected results
The location appears in the drop-down menu as "Sat Dumbrava  Vrancea (PANCIU)".

Step 8
Press "x" button.

Expected results
The location was deleted from the search bar.

Step 9
Write in the search bar "Neicu

Expected results
The location appears in the drop-down menu as "Sat Neicu  Vrancea (PANCIU)".

Step 10
Press "x" button.

Expected results
The location was deleted from the search bar.

Step 11
Write in the search bar "Satu Nou"

Expected results
The location appears in the drop-down menu as "Sat Satu Nou Vrancea (PANCIU)"


No such file or directory @ rb_sysopen - app-debug.txt

Hi Justin! I am facing below issue. Please suggest how to proceed
After running "aaet crawler -s 300 -e Nexus6New -c app-debug.txt --debug --trace", appium server is getting killed. For reference, please see below screenshot

Closing the issue as it was my system issue.. sorry for inconvenience


Move messages in StatusReport to AgentToServer message

It is not clear why we have StatusReport, which contains 4 fields, instead of putting the fields directly in AgentToServer.
Can we move the fields to AgentToServer and eliminate StatusReport message?

Here is what the change can look like: https://github.com/open-telemetry/opamp-go/pull/83
@andykellr @pmm-sumo what do you think?

I like this change.


Revert code to its initial state

I need to revert a code to its initial state, it was obfuscated with this library but I lost the original code and I need to get it again.

Not a topic that we will discuss here


Custom domains support

See details here: https://www.notion.so/rilldata/Custom-domains-implementation-ideas-16c803f925334a299da811efd13045aa
Task list:

[x] Add a custom_domain column on the orgs table
[x] Add CLI commands for setting a custom domain under rill sudo
[x] Add a GetOrgForDomain RPC for use by the frontend
[x] Update the authLoginCallback handler to check if the frontend redirect URL contains a custom domain, and if yes, redirect to the authWithToken handler on the custom domain's API endpoint to correctly set the auth cookie (must support a redirect URL in authWithToken as well)
[x] Update the UI to query the admin service on the custom domain if configured
[x] Test in the staging environment
[x] Audit internally generated admin endpoints for places where we need to prefix with /api

Closing as completed by the two PRs linked above


publish<EMAIL_ADDRESS>

Requested by: @mattjohnsonpint
Merge target: (default)
Quick links:

View changes
View check runs

Assign the accepted label to this issue to approve the release.
Leave the #retract comment under this issue to retract the release (original issuer only).
Targets

[ ] nuget
[ ] github
[ ] registry

Targets marked with a checkbox have already been executed.  Administrators can manually tick a checkbox to force craft to skip it.

GitHub Actions has encountered an internal error when running your job.

odd. retrying


Add support for dapr resources

Here's the PR that supports the dapr resources in azd https://github.com/Azure/azure-dev/pull/2992. We should figure out what the right approach is for Kubernetes.
https://docs.dapr.io/operations/hosting/kubernetes/kubernetes-overview/
cc @philliphoff

Right now i'm considering the following:

During generate we would have a Dapr component processor which would output kustomize manifests to a dapr subfolder.
Adding another action which can be chained into the apply command, which would prompt for installation of dapr in the cluster utilising the dapr cli, only if the output of dapr status -k is an exit code other than 0.
Handle dapr components (see technical)

Technical:
if a user has said no to dapr deploy - what do we do here... allow to continue and patch the kustomization to remove the dapr components, or exit?
I think we should probably exit - as the app wouldn't run without the dapr components being deployed anyway.
This way during generation we still get the dapr components created as dapr k8s components (the cli adds the CRDs for the resource types)

Added in 0.1.25-preview


Updated Readme for step by step setup instructions

Probably worth linking to https://stedolan.github.io/jq/download/ so users not using OSX know how to download and install JQ

For the AWS CLI I usually prefer "pip install", but his works. Everybody ok with this steps?