text:
Enquiry on the use of memory

Hi there i'm trying to find ways to maintain conversation history and also managing context.
I see there is some method to handle chatmemory but i'm not sure what is the context and purpose. Could you help elaborate?
More specifically i'm trying to find out how conversations / prompts can be linked

@enigmablue
Thank you for your enquiry.
Conversation history is a list of Message according to the API reference.
Message has the "role" label.

"system" is an order to LLM.
"user" is an user input message.
"assistant" is a LLM output message.

Therefore, "system" is prompt and others are conversation history between human and AI.
You can specify message list by IChatMemory to set constructor of ChatCompletionAPIConnection.
ChatCompletionAPIConnection automatically records requests and responses to memory.
Sample implementations of IChatMemory are followings:

SimpleChatMemory

Simple list of messages.

FiniteQueueChatMemory

Finite count queue of messages.

FiniteTokenLengthQueueChatMemory

Finite total token length list of messages.

LongTermChatMemory

Summarize old messages by ChatGPT.

Also you can customize memory logic by implementing IChatMemory.
I hope this will help.

Thank you but may i ask a stupid question, what is the intention and benefit of setting up memory?

I intend to be able to extend memory implementation because needed memory specification depends on use cases.
As an example, ChatGPT API has the limit of token length at one request.

gpt3.5-turbo: 4096 tokens

https://platform.openai.com/docs/models/gpt-3-5

gpt4: 8192 or 32768 tokens

https://platform.openai.com/docs/models/gpt-4

Token length for these models are calculated by tiktoken.
Then sometimes it is better to take care of token length in memory e.g. FiniteQueueChatMemory and FiniteTokenLengthQueueChatMemory.
See also LangChain.Memory.
In other cases, if you want to utilize the context of the conversation to request a task to ChatGPT but do not need to record a response, customizing the memory has benefit.

thank you for your tips!

May i ask a bit more about this, do you know a way to maximize the token handling so that costs are managed?
For example in a regular ChatGPT conversation, it knows the history of the conversations and it appears to include it in the prompt without us having to manage it. I believe they are handling this as a part of the reinforcement learning mechanism in the web app.
Do you have any idea how that is done or it can be implemented here or in Unity?
Maybe i dont fully understand your statement: "if you want to utilize the context of the conversation to request a task to ChatGPT but do not need to record a response, customizing the memory has benefit."
Thank you so much

authors: enigmablue mochi-neko

repo: mochi-neko/ChatGPT-API-unity


text:
Mocks are not generated with Kotlin 1.9.0 and when allWarningsAsErrors is set to true

Hello 👋
During updating my project version to 1.9.0 I removed the below block from root Gradle file.
    tasks.withType<KotlinCompile> {
        kotlinOptions {
            allWarningsAsErrors = true
        }
    }

Now I solved my all problems one by one but when I put the piece of code above into code base my all mocks start being not generated anymore. (It was not an issue with Kotlin 1.8.22).
Here is the PR that enables back the allWarningsAsErrors: https://github.com/Oztechan/CCC/pull/2514
And here you can see the logs: https://github.com/Oztechan/CCC/actions/runs/5647407144/job/15297461095?pr=2514
The logs are pointing now only 1 test file with 3 tests inside but when i remove this file and run locally build in project next modules are also failing with same issue.
Here is the more detailed local log:

A mock for the type Settings was not generated.

    Make sure the property holding the mock is annotated with @Mock:

        @Mock
        private val myMock = mock(classOf<Settings>())

io.mockative.NoSuchMockError: A mock for the type Settings was not generated.

    Make sure the property holding the mock is annotated with @Mock:

        @Mock
        private val myMock = mock(classOf<Settings>())

	at app//io.mockative.MocksKt.mock(Mocks.kt:17)
	at app//com.oztechan.ccc.client.core.persistence.PersistenceTest.<init>(PersistenceTest.kt:22)
	at java.base@17.0.7/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
	at java.base@17.0.7/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance(Unknown Source)
	at java.base@17.0.7/jdk.internal.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown Source)
	at java.base@17.0.7/java.lang.reflect.Constructor.newInstanceWithCaller(Unknown Source)
	at java.base@17.0.7/java.lang.reflect.Constructor.newInstance(Unknown Source)
	at app//org.junit.runners.BlockJUnit4ClassRunner.createTest(BlockJUnit4ClassRunner.java:250)
	at app//org.junit.runners.BlockJUnit4ClassRunner.createTest(BlockJUnit4ClassRunner.java:260)
	at app//org.junit.runners.BlockJUnit4ClassRunner$2.runReflectiveCall(BlockJUnit4ClassRunner.java:309)
	at app//org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12)
	at app//org.junit.runners.BlockJUnit4ClassRunner.methodBlock(BlockJUnit4ClassRunner.java:306)
	at app//org.junit.runners.BlockJUnit4ClassRunner$1.evaluate(BlockJUnit4ClassRunner.java:100)
	at app//org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:366)
	at app//org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:103)
	at app//org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:63)
	at app//org.junit.runners.ParentRunner$4.run(ParentRunner.java:331)
	at app//org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:79)
	at app//org.junit.runners.ParentRunner.runChildren(ParentRunner.java:329)
	at app//org.junit.runners.ParentRunner.access$100(ParentRunner.java:66)
	at app//org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:293)
	at app//org.junit.runners.ParentRunner$3.evaluate(ParentRunner.java:306)
	at app//org.junit.runners.ParentRunner.run(ParentRunner.java:413)
	at org.gradle.api.internal.tasks.testing.junit.JUnitTestClassExecutor.runTestClass(JUnitTestClassExecutor.java:108)
	at org.gradle.api.internal.tasks.testing.junit.JUnitTestClassExecutor.execute(JUnitTestClassExecutor.java:58)
	at org.gradle.api.internal.tasks.testing.junit.JUnitTestClassExecutor.execute(JUnitTestClassExecutor.java:40)
	at org.gradle.api.internal.tasks.testing.junit.AbstractJUnitTestClassProcessor.processTestClass(AbstractJUnitTestClassProcessor.java:60)
	at org.gradle.api.internal.tasks.testing.SuiteTestClassProcessor.processTestClass(SuiteTestClassProcessor.java:52)
	at java.base@17.0.7/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at java.base@17.0.7/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
	at java.base@17.0.7/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
	at java.base@17.0.7/java.lang.reflect.Method.invoke(Unknown Source)
	at org.gradle.internal.dispatch.ReflectionDispatch.dispatch(ReflectionDispatch.java:36)
	at org.gradle.internal.dispatch.ReflectionDispatch.dispatch(ReflectionDispatch.java:24)
	at org.gradle.internal.dispatch.ContextClassLoaderDispatch.dispatch(ContextClassLoaderDispatch.java:33)
	at org.gradle.internal.dispatch.ProxyDispatchAdapter$DispatchingInvocationHandler.invoke(ProxyDispatchAdapter.java:94)
	at jdk.proxy1/jdk.proxy1.$Proxy2.processTestClass(Unknown Source)
	at org.gradle.api.internal.tasks.testing.worker.TestWorker$2.run(TestWorker.java:176)
	at org.gradle.api.internal.tasks.testing.worker.TestWorker.executeAndMaintainThreadName(TestWorker.java:129)
	at org.gradle.api.internal.tasks.testing.worker.TestWorker.execute(TestWorker.java:100)
	at org.gradle.api.internal.tasks.testing.worker.TestWorker.execute(TestWorker.java:60)
	at org.gradle.process.internal.worker.child.ActionExecutionWorker.execute(ActionExecutionWorker.java:56)
	at org.gradle.process.internal.worker.child.SystemApplicationClassLoaderWorker.call(SystemApplicationClassLoaderWorker.java:113)
	at org.gradle.process.internal.worker.child.SystemApplicationClassLoaderWorker.call(SystemApplicationClassLoaderWorker.java:65)
	at app//worker.org.gradle.process.internal.worker.GradleWorkerMain.run(GradleWorkerMain.java:69)
	at app//worker.org.gradle.process.internal.worker.GradleWorkerMain.main(GradleWorkerMain.java:74)

That's interesting! I'll have a look at upgrading the targeted Kotlin version to 1.9.0 this weekend and I'll look into the issue you're reporting as well 🙂

Hey @Nillerr it looks like the issue was on ksp side.
With the latest version of ksp some issues are fixed, and it turns out that I can not reproduce this issue with the latest ksp.
So closing this issue since it is not related with mockative 🙂

source: gharchive/issue

authors: Nillerr mustafaozhan

repo: mockative/mockative

license: MIT

license_type: permissive

license_source: github-api


text:
Excessive warning statements printed out while running the regression

A large blob of warning statements is being printed out while running the regression. Looks like it is happening in all testing scripts.

In my opinion, the long-term solution for this would be to figure out the type mismatch issue in #277. It points to an issue in the way we codegen slices. Other warnings (e.g., for concurrent features) are informative and it should be okay to have them printed during the regressions.

Closing because the long-term solution was merged earlier this year in #1205. Thanks, @celinval ! 😄

repo: model-checking/kani


text:
Transfer a large amount of data from Dymola to MATLAB via UDP

I am considering using the Modelic_DeviceDrivers library to transfer data via UDP, but it turns out I have to connect every variable via a component, and I have a few thousands of variables, it would take too much effort to connect them.
How could I transfer a large amount of data from Dymola to MATLAB efficiently via UDP?

Maybe you could mechanize it by using the underlying Modelica functions directly, instead of using the drag'n drop blocks.
Though I'm not sure whether it is a good idea using this UDP interface if you have so many variables. It could work, could be even rather efficient, but it simply stuffs everything sequentially in one UDP message. It's rather easy to introduce offset bugs if message construction and deconstruction don't fit exactly and it is potentially hard to debug if you have so many variables.

Except for UDP, is there any other method that allows massive data exchange via the internet efficiently?

UDP may drop packets, it is particularly for time-sensitve applications, e.g., (soft) real-time applications. Otherwise TCP provides a more reliable data stream. MDD is intended for rather simply use cases. There are various libraries available for a more high-level data exchange, e.g., https://zeromq.org/ , but I'm not aware of any ports to Modelica language bindings. I've so far only used the OS functions directly.

authors: Satinelamp bernhard-thiele


text:
incomplete path in Fluid.Examples.HeatExchanger.BaseClass.WallConstProps

Reported by thorade on 20 Apr 2010 11:56 UTC
When duplicating Modelica.Fluid.Examples.HeatExchanger the HeatExchangerSimulation can no longer be simulated, because Types.Dynamics cannot be found. Using Modelica.Fluid.Types.Dynamics instead solves the problem

Migrated-From: https://trac.modelica.org/Modelica/ticket/358

Modified by dietmarw on 20 Apr 2010 14:07 UTC

Modified by dietmarw on 22 Mar 2011 10:13 UTC

Modified by rfranke on 27 Dec 2012 12:03 UTC

Changelog removed by rfranke on 27 Dec 2012 12:03 UTC

Comment by rfranke on 27 Dec 2012 12:05 UTC
the proposed change has been implemented in c43eeb40e330b6d9bbff374ea0c272420de2cdd4

repo: modelica/Modelica


text:
zju_11

提供 1 个兼容 MajicmixRealistic_v6 的风格模型:将军风
使用网络上的胡歌照片训练，得到的效果:

please sync the latest master & change the id to the preset woman id. refer to #220

source: gharchive/pull-request

repo: modelscope/facechain


text:
run_auto_label with error

Describe the bug

https://modelscope.cn/models/damo/speech_ptts_autolabel_16k/summary

from modelscope.tools import run_auto_label
input_wav = "./test_wavs/"
output_data = "./output_training_data/"
ret, report = run_auto_label(input_wav=input_wav, work_dir=output_data, resource_revision="v1.0.5")

IndexError                                Traceback (most recent call last)
Cell In[4], line 4
      1 input_wav = "[./test_wavs/](https://vscode-remote+ssh-002dremote-002b192-002e168-002e50-002e106.vscode-resource.vscode-cdn.net/home/mai/Bark-Voice-Cloning/test_wavs/)"
      2 output_data = "[./output_training_data/](https://vscode-remote+ssh-002dremote-002b192-002e168-002e50-002e106.vscode-resource.vscode-cdn.net/home/mai/Bark-Voice-Cloning/output_training_data/)"
----> 4 ret, report = run_auto_label(input_wav=input_wav, work_dir=output_data, resource_revision="v1.0.5")

File [~/miniconda3/envs/bark_env_3.9/lib/python3.9/site-packages/modelscope/tools/speech_tts_autolabel.py:78](https://vscode-remote+ssh-002dremote-002b192-002e168-002e50-002e106.vscode-resource.vscode-cdn.net/home/mai/Bark-Voice-Cloning/~/miniconda3/envs/bark_env_3.9/lib/python3.9/site-packages/modelscope/tools/speech_tts_autolabel.py:78), in run_auto_label(input_wav, work_dir, para_ids, resource_model_id, resource_revision, gender, stage, process_num, develop_mode, has_para, enable_enh)
     64 model_resource = _download_and_unzip_resource(resource_model_id,
     65                                               resource_revision)
     66 auto_labeling = AutoLabeling(
     67     os.path.abspath(input_wav),
     68     model_resource,
   (...)
     76     process_num,
     77     enable_enh=enable_enh)
---> 78 ret_code, report = auto_labeling.run()
     79 return ret_code, report

File [~/.local/lib/python3.9/site-packages/tts_autolabel/auto_label.py:765](https://vscode-remote+ssh-002dremote-002b192-002e168-002e50-002e106.vscode-resource.vscode-cdn.net/home/mai/Bark-Voice-Cloning/~/.local/lib/python3.9/site-packages/tts_autolabel/auto_label.py:765), in AutoLabeling.run(self)
    762 self.wav_preprocess()
    764 ## cut wav by vad
--> 765 self.wav_cut_by_vad()
    767 # get prosody
    768 audio_path = glob.glob(os.path.join(self.cut_wav_dir, '*.wav'))

File [~/.local/lib/python3.9/site-packages/tts_autolabel/auto_label.py:371](https://vscode-remote+ssh-002dremote-002b192-002e168-002e50-002e106.vscode-resource.vscode-cdn.net/home/mai/Bark-Voice-Cloning/~/.local/lib/python3.9/site-packages/tts_autolabel/auto_label.py:371), in AutoLabeling.wav_cut_by_vad(self)
    369     shutil.rmtree(self.cut_wav_dir)
    370 os.makedirs(self.cut_wav_dir, exist_ok=True)
--> 371 vad_cut(self.resample_wav_dir, self.cut_wav_dir, self.resource_dir)

File [~/.local/lib/python3.9/site-packages/tts_autolabel/audiocut/vad.py:73](https://vscode-remote+ssh-002dremote-002b192-002e168-002e50-002e106.vscode-resource.vscode-cdn.net/home/mai/Bark-Voice-Cloning/~/.local/lib/python3.9/site-packages/tts_autolabel/audiocut/vad.py:73), in vad_cut(input_wav_dir, output_wav_dir, resource_dir, cut_threshold, start_sil_threshold, end_sil_threshold, max_dur_threshold, min_dur_threshold)
     69 min_samples_threshold = int(min_dur_threshold * sample_rate)
     71 wavid = os.path.basename(audio_in).split('.')[0]
---> 73 segments_result = vad_pipeline(audio_in=waveform)
     74 segments_text = segments_result[0]
     76 if len(segments_text) == 0:

File [~/.local/lib/python3.9/site-packages/tts_autolabel/audio2phone/funasr_onnx/vad_bin.py:94](https://vscode-remote+ssh-002dremote-002b192-002e168-002e50-002e106.vscode-resource.vscode-cdn.net/home/mai/Bark-Voice-Cloning/~/.local/lib/python3.9/site-packages/tts_autolabel/audio2phone/funasr_onnx/vad_bin.py:94), in Fsmn_vad.__call__(self, audio_in, **kwargs)
     92 end_idx = min(waveform_nums, beg_idx + self.batch_size)
     93 waveform = waveform_list[beg_idx:end_idx]
---> 94 feats, feats_len = self.extract_feat(waveform)
     95 waveform = np.array(waveform)
     96 param_dict = kwargs.get('param_dict', dict())

File [~/.local/lib/python3.9/site-packages/tts_autolabel/audio2phone/funasr_onnx/vad_bin.py:154](https://vscode-remote+ssh-002dremote-002b192-002e168-002e50-002e106.vscode-resource.vscode-cdn.net/home/mai/Bark-Voice-Cloning/~/.local/lib/python3.9/site-packages/tts_autolabel/audio2phone/funasr_onnx/vad_bin.py:154), in Fsmn_vad.extract_feat(self, waveform_list)
    152 for waveform in waveform_list:
    153 	speech, _ = self.frontend.fbank(waveform)
--> 154 	feat, feat_len = self.frontend.lfr_cmvn(speech)
    155 	feats.append(feat)
    156 	feats_len.append(feat_len)

File [~/.local/lib/python3.9/site-packages/tts_autolabel/audio2phone/funasr_onnx/utils/frontend.py:89](https://vscode-remote+ssh-002dremote-002b192-002e168-002e50-002e106.vscode-resource.vscode-cdn.net/home/mai/Bark-Voice-Cloning/~/.local/lib/python3.9/site-packages/tts_autolabel/audio2phone/funasr_onnx/utils/frontend.py:89), in WavFrontend.lfr_cmvn(self, feat)
     87 def lfr_cmvn(self, feat: np.ndarray) -> Tuple[np.ndarray, np.ndarray]:
     88     if self.lfr_m != 1 or self.lfr_n != 1:
---> 89         feat = self.apply_lfr(feat, self.lfr_m, self.lfr_n)
     91     if self.cmvn_file:
     92         feat = self.apply_cmvn(feat)

File [~/.local/lib/python3.9/site-packages/tts_autolabel/audio2phone/funasr_onnx/utils/frontend.py:103](https://vscode-remote+ssh-002dremote-002b192-002e168-002e50-002e106.vscode-resource.vscode-cdn.net/home/mai/Bark-Voice-Cloning/~/.local/lib/python3.9/site-packages/tts_autolabel/audio2phone/funasr_onnx/utils/frontend.py:103), in WavFrontend.apply_lfr(inputs, lfr_m, lfr_n)
    101 T = inputs.shape[0]
    102 T_lfr = int(np.ceil(T [/](https://vscode-remote+ssh-002dremote-002b192-002e168-002e50-002e106.vscode-resource.vscode-cdn.net/) lfr_n))
--> 103 left_padding = np.tile(inputs[0], ((lfr_m - 1) [/](https://vscode-remote+ssh-002dremote-002b192-002e168-002e50-002e106.vscode-resource.vscode-cdn.net/)[/](https://vscode-remote+ssh-002dremote-002b192-002e168-002e50-002e106.vscode-resource.vscode-cdn.net/) 2, 1))
    104 inputs = np.vstack((left_padding, inputs))
    105 T = T + (lfr_m - 1) [/](https://vscode-remote+ssh-002dremote-002b192-002e168-002e50-002e106.vscode-resource.vscode-cdn.net/)[/](https://vscode-remote+ssh-002dremote-002b192-002e168-002e50-002e106.vscode-resource.vscode-cdn.net/) 2

IndexError: index 0 is out of bounds for axis 0 with size 0

To Reproduce

What command or script did you run?

A placeholder for the command.

Did you make any modifications on the code or config? Did you understand what you have modified?
What dataset did you use?

Please provide the problematic input WAV files so that we can try to reproduce the issue.

https://drive.google.com/file/d/1IZwmZ0s5n5BP_cny0oqaZgR8XA1ST0dR/view?usp=sharing
@GinChow

We didn't reproduce your case. Can you try it again with the latest release version?

authors: GinChow waltcow

repo: modelscope/modelscope


text:
swift库可以增加对mPLUG-Owl2模型的支持吗？

mPLUG-Owl2 是阿里达摩院近期开源的一个优秀MLLM模型：https://github.com/X-PLUG/mPLUG-Owl/tree/main/mPLUG-Owl2 ，并且模型在modelscope和Huggingface都已发布，作者团队能否将该模型在swift库上进行支持呢？非常感谢，期待回复~

感谢你优秀的模型！！！

@Jintao-Huang 这是最近看到的优秀工作，希望你们能够在swift库早日支持！

repo: modelscope/swift


text:
🛑 Wiki is down

In c442fb6, Wiki (https://omegawiki.modem7.com) was down:

HTTP code: 500
Response time: 904 ms

Resolved: Wiki is back up in 9d8634e.


text:
🛑 BorgBase is down

In 0dbf5c4, BorgBase (https://www.borgbase.com/) was down:

HTTP code: 0
Response time: 0 ms

Resolved: BorgBase is back up in 38ea58b.


text:
Return copy of slice

The caller shouldn't be able to modify underlying array of the internal insertedEvents slice:
https://github.com/modernice/goes/blob/875903b43ae7ae6237efd5d1b1ac556c67ad91c9/backend/mongo/transaction.go#L56

hi @bounoable can I work on this? thanks

hey @rafiramadhana, that would be nice 👍🏼

oh, seems like someone already did 😄

authors: bounoable rafiramadhana

repo: modernice/goes


text:
After pd.set_option('display.max_rows', None), df.describe().T only displays 60 rows

System information

OS: macOS 12.4
Modin version: 0.15.2
Python version: 3.9.12 (Anaconda)
Code we can use to reproduce:
In Jupyter nbotebook:

import os
os.environ["MODIN_ENGINE"] = "ray"
import modin.pandas as pd
import numpy as np
import ray
ray.init()
pd.set_option('display.max_rows', None)
df = pd.DataFrame(np.zeros((2,100)))
df.describe().T

Describe the problem

After running
pd.set_option('display.max_rows', None), df.describe().T only displays 60 rows

to display all rows of output, df.describe().T shows the first 30 rows and last 30 rows only, with no indication that you're not seeing all of the output.
Source code / logs

@rhstanton thank you for reporting this issue! I can reproduce it at Modin version 910bf2dd893f52072c2c25413bf0866825f8309d:
import modin.pandas as pd
pd.set_option('display.max_rows', None)
print(pd.DataFrame(list(range(20))))

the above script gives me just 12 rows in my terminal in ipython, while pandas gives me all 20 rows.
To whomever works on the fix:
I tried passing num_rows = len(self.index) to modin.pandas.BasePandasDataset._build_repr_df in case display.max_rows is None (and likewise for columns), but that's not passing the modified unit test test__options_display with max_rows = max_cols = None. However, setting max_rows to math.inf with special treatment so we don't try to divide infinity worked. The latter solution doesn't seem as clear, though.

This seems like low hanging fruit that we should fix in an effort to improve user experience.

authors: mvashishtha pyrito rhstanton

repo: modin-project/modin


text:
Feature Request: .map using dicts

System information

OS Platform and Distribution (e.g., Linux Ubuntu 16.04): Linux Mint 19.1 (Ubuntu 18.04)
Modin installed from (source or binary): binary
Modin version: 0.6.0
Python version: 3.7.3
Exact command to reproduce:

import modin.pandas as pd

data = {
    "column": [0,1]
}

df = pd.DataFrame(data)

mapper = {
    0: "A",
    1: "B"
}

df.loc[:, "column"] = df.loc[:, "column"].map(mapper)

Describe the problem
Maybe it isn't a problem, but just a feature that has yet to be implemented?
Source code / logs
Traceback (most recent call last):
  File "/home/jason/.virtualenvs/bert_poc/lib/python3.7/site-packages/IPython/core/interactiveshell.py", line 3326, in run_code
    exec(code_obj, self.user_global_ns, self.user_ns)
  File "<ipython-input-8-df805f17ff4c>", line 12, in <module>
    df.loc[:, "column"] = df.loc[:, "column"].map(mapper)
  File "/home/jason/.virtualenvs/bert_poc/lib/python3.7/site-packages/modin/pandas/indexing.py", line 256, in __setitem__
    super(_LocIndexer, self).__setitem__(row_lookup, col_lookup, item)
  File "/home/jason/.virtualenvs/bert_poc/lib/python3.7/site-packages/modin/pandas/indexing.py", line 145, in __setitem__
    item = self._broadcast_item(row_lookup, col_lookup, item, to_shape)
  File "/home/jason/.virtualenvs/bert_poc/lib/python3.7/site-packages/modin/pandas/indexing.py", line 172, in _broadcast_item
    item = np.array(item)
  File "/home/jason/.virtualenvs/bert_poc/lib/python3.7/site-packages/modin/pandas/series.py", line 123, in __array__
    return super(Series, self).__array__(dtype).flatten()
  File "/home/jason/.virtualenvs/bert_poc/lib/python3.7/site-packages/modin/pandas/base.py", line 3145, in __array__
    arr = self.to_numpy(dtype)
  File "/home/jason/.virtualenvs/bert_poc/lib/python3.7/site-packages/modin/pandas/series.py", line 1024, in to_numpy
    return super(Series, self).to_numpy(dtype, copy).flatten()
  File "/home/jason/.virtualenvs/bert_poc/lib/python3.7/site-packages/modin/pandas/base.py", line 2946, in to_numpy
    arr = self._query_compiler.to_numpy()
  File "/home/jason/.virtualenvs/bert_poc/lib/python3.7/site-packages/modin/backends/pandas/query_compiler.py", line 143, in to_numpy
    arr = self._modin_frame.to_numpy()
  File "/home/jason/.virtualenvs/bert_poc/lib/python3.7/site-packages/modin/engines/base/frame/data.py", line 1137, in to_numpy
    return self._frame_mgr_cls.to_numpy(self._partitions)
  File "/home/jason/.virtualenvs/bert_poc/lib/python3.7/site-packages/modin/engines/ray/generic/frame/partition_manager.py", line 20, in to_numpy
    for row in partitions
  File "/home/jason/.virtualenvs/bert_poc/lib/python3.7/site-packages/ray/worker.py", line 2247, in get
    raise value
ray.exceptions.RayTaskError: ray_worker (pid=26958, host=LH002609)
ray.exceptions.RayTaskError: ray_worker (pid=26965, host=LH002609)
  File "/home/jason/.virtualenvs/bert_poc/lib/python3.7/site-packages/modin/engines/ray/pandas_on_ray/frame/partition.py", line 197, in deploy_ray_func
    result = func(partition, **kwargs)
  File "/home/jason/.virtualenvs/bert_poc/lib/python3.7/site-packages/modin/data_management/functions/mapfunction.py", line 10, in <lambda>
    lambda x: function(x, *args, **kwargs), *call_args, **call_kwds
  File "/home/jason/.virtualenvs/bert_poc/lib/python3.7/site-packages/pandas/core/frame.py", line 6979, in applymap
    return self.apply(infer)
  File "/home/jason/.virtualenvs/bert_poc/lib/python3.7/site-packages/pandas/core/frame.py", line 6913, in apply
    return op.get_result()
  File "/home/jason/.virtualenvs/bert_poc/lib/python3.7/site-packages/pandas/core/apply.py", line 186, in get_result
    return self.apply_standard()
  File "/home/jason/.virtualenvs/bert_poc/lib/python3.7/site-packages/pandas/core/apply.py", line 292, in apply_standard
    self.apply_series_generator()
  File "/home/jason/.virtualenvs/bert_poc/lib/python3.7/site-packages/pandas/core/apply.py", line 321, in apply_series_generator
    results[i] = self.f(v)
  File "/home/jason/.virtualenvs/bert_poc/lib/python3.7/site-packages/pandas/core/frame.py", line 6977, in infer
    return lib.map_infer(x.astype(object).values, func)
  File "pandas/_libs/lib.pyx", line 2228, in pandas._libs.lib.map_infer
TypeError: ("'dict' object is not callable", 'occurred at index column')

Hi @jmwoloso, thanks for reporting!
This functionality isn't implemented yet, but it shouldn't be throwing this kind of error. I don't think the overhead for implementing it is very high compared to fixing the error message, so we'll probably just implement for the next release. Thanks!

Thank you @devin-petersohn! This is a pretty sweet project!

As a temporary workaround for everyone else (this pattern can probably be applied in general while new features are implemented):
import modin.pandas as mpd
import pandas as pd

data = {
    "column": [0,1]
}

# read in with pandas
df = pd.DataFrame(data)

mapper = {
    0: "A",
    1: "B"
}

# map using pandas
df.loc[:, "column"] = df.loc[:, "column"].map(mapper)

# convert to modin df
df = mpd.DataFrame(df)

# back in action!

Thanks @jmwoloso, there is a more concise way of doing this actually, though it's mostly used internally (editing from your old code):
import modin.pandas as pd

data = {
    "column": [0,1]
}

df = pd.DataFrame(data)

mapper = {
    0: "A",
    1: "B"
}

df.loc[:, "column"] = df.loc[:, "column"]._default_to_pandas(lambda s: s.map(mapper))

This will do everything from converting to a pandas DataFrame, doing the operation, then converting back. Let me know if it is working for you! (It's a little cleaner and less chance of bugs I think)

@devin-petersohn sorry for the really late reply. I haven't had a chance to try it yet, but I trust it works. Thanks for your help!

authors: devin-petersohn jmwoloso


text:
Question for shared function instance between host app and remote app.

Describe the bug
Why is the mitt() instance not singleton ??
Here is the shared function instance code.   This code is shared by host app.

Here is the host federation config.

Here is the usage from host app.   Using the instance directly.

Here is the usage from remote app. Using the instance by shared module.

Reproduction
reproduction
Used Package Manager
pnpm
System Info
System:
    OS: Windows 11 10.0.22631
    CPU: (16) x64 12th Gen Intel(R) Core(TM) i5-1240P
    Memory: 886.59 MB / 15.68 GB
  Binaries:
    Node: 18.20.4 - C:\Program Files\nodejs\node.EXE
    npm: 10.7.0 - C:\Program Files\nodejs\npm.CMD
    pnpm: 9.14.2 - C:\Program Files\nodejs\pnpm.CMD
  Browsers:
    Edge: Chromium (130.0.2849.56)
    Internet Explorer: 11.0.22621.3527

Validations

[x] Read the docs.
[X] Read the common issues list.
[X] Check that there isn't already an issue that reports the same bug to avoid creating a duplicate.
[X] Make sure this is a Module federation issue and not a framework-specific issue.
[X] The provided reproduction is a minimal reproducible example of the bug.

exposed modules are not guarenteed to be singleton, the host and remote have seperate runtime containers and module graphs. only mitt would be singleton, the exposed item would not be in this case, youd need a runtime chunk single but that may cause other issues unless you have an additional ContainerPlugin with runtime: false set on it so that you have one for when the hosts own remote is loaded into the page, and another for if the host is not the same app as a remote being loaded. the exposed thing is not singleton, but its import of mitt is.
if you shared the thing you expose, it would probbably work

Now i'm extract the common stuff to a new runtime.

it looks like working fine.
BUT other issues come out.
When I modify the code on the common side,  I expect the host project will be HMR the changes.
but I met this error.

Thanks for your info.
I'm extracting the common function, instance into a new container. and expose those common parts from this container.
Now, it seems to work well.

unfortunately, I have to maintain another container.  anyway, it works.

repo: module-federation/core


text:
fix(runtime): The shared modules being loaded are getting overwritten

Description
This is a very elusive bug, and it occurs with a certain probability each time the page is refreshed. Several conditions must be met:

The shared module version is the same.
The remote name is greater than the host name.
It happens randomly

Related Issue

Types of changes

[ ] Docs change / refactoring / dependency upgrade
[x] Bug fix (non-breaking change which fixes an issue)
[ ] New feature (non-breaking change which adds functionality)

Checklist

[ ] I have added tests to cover my changes.
[ ] All new and existing tests passed.
[ ] I have updated the documentation.

So because nobody loaded yet, and someone still loding the share - the system thinks it needs to inject another script to load? and sometimes the second time it picks a different share origin than the one already in-flight?

My loading order is this
host init(shared: {vue})
  host start loadShare("vue") // auto load remote, vue start loading
    remote init(shared: {vue})
       remote start loadShare("vue") // At this point, Vue will be overwritten.
           host end loadShare("vue") // return host vue
               remote end loadShare("vue") // return remote vue

The issue is likely caused by the order of execution. I’ll try to fix the order first.

@ScriptedAlchemy I have already fixed the issue I encountered. Could you help review if there are any other problems?
here

and sometimes the second time it picks a different share origin than the one already in-flight?

yes, When not using build plugins and directly using the runtime, I think this issue might still occur.

Are you lazy initializing the remotes or do the all init upfront. Loading all remotes first. Then the app starts running?
Like in webpack and rspack. Before app starts running, remotes and shares are resolved. Then app starts consuming vue etc.
Are you using loaded first or version first share strategy

authors: ScriptedAlchemy zhangHongEn


text:
Spawn sync

Fixes https://github.com/webmixedreality/exokit/issues/369.

Mostly adds the Await method for blocking the current thread on an asynchronous callback.

repo: modulesio/child-process-thread


text:
1 call of showToast() does not fire a Toast Notification, 2 calls of showToast() fires 2 Toast Notifications...

I am working with this library for the first time (am also new to c++) and am running into an issue where the recommended code for usage will not send a toast notification, but including a second line of
WinToast::instance()->showToast(templ, handler)
causes 2 toast notifications to fire. Trying to understand what the root cause of this is so that I can resolve the issue I am experiencing here...
Code I have been using and experiencing the issue with is below and my compiler is set for c++20:
int main() {
    if (!WinToast::isCompatible())
    {
        std::wcout << L"Error, your system in not supported!" << std::endl;
    }

    WinToast::instance()->setAppName(L"WinToastExample");
    const auto aumi = WinToast::configureAUMI(L"mohabouje", L"wintoast", L"wintoastexample", L"20161006");
    WinToast::instance()->setAppUserModelId(aumi);

    if (!WinToast::instance()->initialize())
    {
        std::wcout << L"Error, could not initialize the lib!" << std::endl;
    }

    CustomHandler* handler = new CustomHandler;
    WinToastTemplate templ = WinToastTemplate(WinToastTemplate::Text02);
    templ.setTextField(L"title", WinToastTemplate::FirstLine);
    templ.setTextField(L"subtitle", WinToastTemplate::SecondLine);

    WinToast::instance()->showToast(templ, handler) // when this line is commented out, 0 toast notifications fire when compiled exe is run, when this line is included, 2 toast notifications fire when compiled exe is run

    if (!WinToast::instance()->showToast(templ, handler))
    {
        std::wcout << L"Error: Could not launch your toast notification!" << std::endl;
    }
}

definition of customHandler for reference (copy/paste from WinToast/example/qt-gui-example/WinToastExample/mainwindow.cpp):
class CustomHandler : public IWinToastHandler {
public:
    void toastActivated() const {
        std::wcout << L"The user clicked in this toast" << std::endl;
    }

    void toastActivated(int actionIndex) const {
        std::wcout << L"The user clicked on button #" << actionIndex << L" in this toast" << std::endl;
    }

    void toastFailed() const {
        std::wcout << L"Error showing current toast" << std::endl;
    }
    void toastDismissed(WinToastDismissalReason state) const {
        switch (state) {
        case UserCanceled:
            std::wcout << L"The user dismissed this toast" << std::endl;
            break;
        case ApplicationHidden:
            std::wcout << L"The application hid the toast using ToastNotifier.hide()" << std::endl;
            break;
        case TimedOut:
            std::wcout << L"The toast has timed out" << std::endl;
            break;
        default:
            std::wcout << L"Toast not activated" << std::endl;
            break;
        }
    }
};

Any help that anyone can offer is greatly appreciated.

Try calling CoInitialize(NULL); at the start of the main() and CoUnintialize(); at the end of the main().

authors: rnewendyke shaovoon

repo: mohabouje/WinToast

license: mit

license_source: bigquery


text:
[Feature request] Adding the ability to reuse the AUMID of the current process.

In case of using the WinToast lib in extensions, it wold be great to use AUMID from existing parent app shortcut.
bool WinToast::GetAUMIdForCurrentProcess(_Out_ std::wstring& aumid)
{
	if (!isCompatible()) {
		DEBUG_MSG(L"Warning: Your system is not compatible with this library ");
		return(false);
	}

	// Thanks to:
	// https://stackoverflow.com/questions/59926644/listing-of-installed-apps-on-windows-10
	//

	HRESULT hr = E_FAIL;
	std::wstring exePath(MAX_PATH, 0);
	DWORD written = GetModuleFileNameExW(GetCurrentProcess(), nullptr, &exePath[0], MAX_PATH);
	exePath.resize(written);

	CoInitialize(NULL);
	ComPtr<IShellItem> folder;
	if (SUCCEEDED(hr = SHCreateItemFromParsingName(L"shell:appsFolder", nullptr, IID_PPV_ARGS(&folder))))
	{
		ComPtr<IEnumShellItems> enumItems;
		if (SUCCEEDED(hr = folder->BindToHandler(nullptr, BHID_EnumItems, IID_PPV_ARGS(&enumItems))))
		{
			IShellItem* items;
			while (enumItems->Next(1, &items, nullptr) == S_OK)
			{
				// Get executable path.
				ComPtr<IShellItem> item = items;
				ComPtr<IPropertyStore> store;
				if (SUCCEEDED(item->BindToHandler(NULL, BHID_PropertyStore, IID_PPV_ARGS(&store))))
				{
					wchar_t pvString[MAX_PATH] = { 0 };

					PROPVARIANT propVarPath;
					PropVariantInit(&propVarPath);
					if (SUCCEEDED(store->GetValue(PKEY_Link_TargetParsingPath, &propVarPath)))
					{
						hr = DllImporter::PropVariantToString(propVarPath, pvString, MAX_PATH);
						PropVariantClear(&propVarPath);

						// Compare path.
						if (exePath == pvString)
						{
							PROPVARIANT appIdPropVar;
							PropVariantInit(&appIdPropVar);

							if (SUCCEEDED(hr = store->GetValue(PKEY_AppUserModel_ID, &appIdPropVar)))
							{
								hr = DllImporter::PropVariantToString(appIdPropVar, pvString, MAX_PATH);
								PropVariantClear(&appIdPropVar);

								if (SUCCEEDED(hr))
								{
									aumid = pvString;
									break;
								}
							}
						}
					}
				}
			}
		}
	}

	CoUninitialize();

	return(SUCCEEDED(hr));
}

Thanks for the contribution; I have scheduled this change for version v1.4.0.
Closing this issue and moving it to https://github.com/mohabouje/WinToast/issues/86

authors: mohabouje prachtan


text:
Make public copyRecursive(original, cpy reflect.Value)

For unit testing/mock purpose I need to copy struct to an existing pointer instance.
For example I have:
func Get(key int, val interace{}) error {
  //...
  return nil
}

In the mock I would like to do:
func Get(key int, val interace{}) error {
  deepcopy.CopyRecursive(someVal, val)
  return nil
}

Any reasons to exclude copyRecursive() from exporting?

Sorry for the delayed response.
I hadn't really thought about making it exported.
If you wish to make a pull request exporting it, I'll be happy to accept it.

@mohae, thanks!

authors: astec mohae

repo: mohae/deepcopy


text:
drag and drop

Hi
I am trying to execute some action when a task state changes from Done to any other state. It works fine when the task is open, but not if you drag and drop. Any idea on how to get that working?
regards
Gitte

This is a work item form extension, so it works only from inside a work item form.

authors: gibf mohitbagra

repo: mohitbagra/vsts-extensions


text:
Flow styles are unsupported

For example, errors or invalid YAML result from loading and modifying the mapping or sequence in the following YAML document:
widgets: [flow, style]
gears: {flow: style}

Yes this is a bug. PR to fix it is welcome.


text:
Website is not accessable

http://meshjs.herokuapp.com/
http://meshjs.com/
Is the server down?

Whoops - definitely shouldn't happen. Thanks for the heads up!
Still lots of polishing to do on the home page. There should be docs & examples here in a few weeks.

Cool, let me know if you need any help.

authors: crcn kievechua


text:
Klarna payment additional fee not updated total price order overview

Klarna payment additional fee not updated total price order overview.
It gives no problems when processing the order, invoice or mail, it's just a little bug in the order overview.

Environment

PrestaShop version: 1.7.7.5
Mollie module version: 4.3.0
PHP version: 7.2.24

Hi @petrovv77 ,
Thanks for your message!
We will check with this issue internally on 1.7.7.5 version, as for now we could not replicate this issue on other versions of PS, could be that Prestashop version specific, I will provide feedback as soon as I will have it from the developers.
Thank you.
--
Best regards,
Invertus Support team

@petrovv77 ,
We've setup the same environment as you've provided, made some test orders with Klarna and with the additional fee added, but could not reproduce the issue on our end:

Maybe you could provide us with you BO+FTP credentials for further investigation? If yes, please send them to - support@invertus.eu and be sure to net reply to this message, yet create a separate email so it would not get shared within GitHub.
--
Best regards,
Invertus Support team

@Saimis777
remote research with us is a bit complicated because we don't use regular ftp.
I use percentage and fixed costs.

maybe it was a decimal thing...
I'll wait for the next Klarna payment, and see if the same occurs there.
Earlier version 4.2.4 went well.

Thanks for the clarification @petrovv77 ,
We will try to replicate it one more time by your example, and will let you know with the outcome!
--
Best regards,
Invertus Support team

Hi @petrovv77 ,
Unfortunately we could not reproduce the issue after trying again, maybe there were more Klarna payments within your shop that we could investigate?
Looking forward to your reply!
--
Best regards,
Invertus Support team

@Saimis777
no payment received through Klarna after reporting. So you can close this issue for now

repo: mollie/PrestaShop


text:
Orders with Vat = 0 still not possible

Hello everyone,
unfortunately, I have to reopen an issue concerning Vat. A customer cannot order if he is in a customer group with net prices.
Steps:

Assign a customer to the net-prices group
Order with this customer

Problem
The fix from #4 does not work, because the TexStatus is not tax-free but net

Problem
Even if the fix of #4 would work, another problem would occur:

with following OrderData:

Can you tell me a little more in-depth what your exact setup is? I'm not fully able te reproduce it, yet. Maybe you could guide me.

Actually we don't have a really special setup.
The ordering country is Germany (regular 19% VAT).
This country is also not marked as tax free in the settings.
However, all our customers are in the net customer group (adjustable in the admin). This means that every user also gets net prices displayed in the shop.
Do you have further questions? Ask me specific questions.

Did you make any progress here? You need more info?
Can you already give us a timeline here, when the problem will probably be solved?

I use getAmountTotal() on an order entity. I see now that I have to check seperately if the order is a net order and if so, switch to using the function getAmountNet(). This is fixed and will be in the next release.

Thanks for the answer. Is it possible to release it now? We need it fast.

I'll discuss what's possible.

A release is planned for tomorrow 😊

@henrikvolmer The new version is released. Please let us know if this works out for you.

Sadly not. Now you pay the net price, but you have to pay the brut price.

I have reversed the fix as this was een unintended effect. What I see now is that the calculation of Mollie (which happens in the API call) is different from the data Shopware provides. I can replace Shopware's data by the calculation that Mollie uses, but than (most of the times) the total price doesn't add up. Unfortunately, we have to rethink this.

Is there any news on this already?

Hi Henrik,
Shopware doesn't save both the gross and net prices on orderline items. Even though they store both these prices on a product. I think that makes it more difficult than it should be.
That being said, there's a built in calculator to calculate the required taxes. But it doesn't always give a result that matches with Mollie's calculation. The Orders API calculates the order to check if everything is acceptable. And I know there's a margin of half a cent at Mollie, but the difference actually is a full cent most of the time in these scenario's. I've asked Mollie if they can raise the margin.
Another thing that is weird to me is that even though the setting for net prices is just to display net prices to these customers, Shopware actually calculates the prices in a whole different way as well. The price including vat on an order of a customer in a group with net prices, is different from the price including vat on the exact same basket of a customer in a group with gross prices.
So we're working on it and are talking things over with Mollie and Shopware.

Hi @reindernl,
Thanks for the info. Is there already a timeline for this?
Thanks

@henrikvolmer We've released version 1.0.14 of the MolliePayments plugin for Shopware 6 with a bugfix for net orders. Let me know how this works out for you!

@reindernl: At first sight it seems to work now. We will now test it in detail and then I will give you a final status.

@henrikvolmer Looking forward to that. We've tested quite thoroughly. Testing with a quantity of 11 often gave the above mentioned failure in the previous version of the plugin.

@henrikvolmer Were you able to test in more detail? Any findings?

We have not been able to detect any more errors. Thanks for the help

authors: KienerNL henrikvolmer reindernl


text:
Remove money helper from code to stop collision

In one of my projects I installed a package that depended on the akaunting/money package. These both use a money helper. The akaunting/money package overrides the money helper in the laravel-cashier-mollie package in my case.
This pull requests removes the money helper from the client code and directly uses the Money and Currency class. The tests still use the helper, but for users of the package that shouldn't matter.

Hi @siegerhansma !
Thanks for this PR. Can you point me to the signature of the helper in the colliding package?

@sandervanhooft Sure thing, it's over here: https://github.com/akaunting/laravel-money/blob/master/src/helpers.php#L7

Thanks! It appears to me the helper itself isn't removed in this PR?

Correct, it's still used in the tests. Should I replace them in the tests and remove the helper?

That would definitely help keeping things consistent :)

No problem, I'll update the PR later this week.

Related: #128 #89

@sandervanhooft Removed the helper and updated all the tests to use the class instead of the helper. Not sure about the conflict though.

Looks good to me! Thanks @siegerhansma !

This was a breaking change in a minor release.
Broke our code because of the missing money function

Hi @RemiHin ,
Thanks for reporting and sorry to hear that. I was under the impression it was only used by Cashier internally. But I now see it's also used by the charge builder. Let me revert this and put the money helper back.
@siegerhansma this will have to wait until next major release.

hi @sandervanhooft
We we're able to work around by using the Money and Currency Classes suggested by @siegerhansma, but we might nog be the only people using the helper :) thanks for the quick response

Here you go: https://github.com/mollie/laravel-cashier-mollie/releases/tag/v2.5.4

authors: RemiHin sandervanhooft siegerhansma

repo: mollie/laravel-cashier-mollie


text:
Moving away from the Buffer constructor

new Buffer(...) is unsafe and deprecated. Would it be possible to move these instances of its use to Buffer.from(...)?

NOTE WELL This package is officially deprecated. As of node 9.0.0, there is an 'http2' package built-in. You should use that one instead.

authors: GrosSacASac gabrielschulhof


text:
test: reliable waiting for postgres to start up

Apparently postgres will create sockets before it's actually ready for
clients to talk to it! Weird, but we have a better way of doing this
thanks to the NOTIFY_SOCKET protocol we just learned about.
Co-authored-by: Shahar "Dawn" Or mightyiampresence@gmail.com

Commenting so that some other PRs are the least recently updated. They are used as test fixtures.

authors: jfly mightyiam

repo: molybdenumsoftware/pr-tracker


text:
Moment no longer exporting global when require.js is present

As of version 2.10.0, the moment global is no longer available if a module system is detected.  This was previously working in 2.9.0.  This is causing a headache for us as we have newer code written with Polymer that is HTML Importing moment, and we're integrating it with older code written with require.js.  Moment detects require.js and doesn't add the global, which causes our elements to fail at runtime.  Our tests and demo pages still work because they do not have require.js present, and the Polymer elements themselves don't need require.js to function.
Fiddle is below, but please note that it appears to be freezing for a short period before dumping out to the console.  You'll ultimately get "moment is not defined" error and a "Mismatched anonymous define() module" error from require.js.
Fiddle: https://jsfiddle.net/f5xu1cho/1/

Marking as bug, but I think it may have been intentional.  Need to explorer further.

This was definitely on purpose. Here's where we deprecated require-but-also-globals https://github.com/moment/moment/pull/1220/files. This is one of those damned-if-we-do-damned-if-we-don't things. Some things break in requirejs environments if we do export it (which is why we provided a noGlobal in that patch), and mixed environments break if we don't.

Since this was intentional, I'm marking it as "troubleshooting" instead of "bug".  Perhaps someone can offer a workaround.

The require team kindly explained what to do in this situation with requirejs/requirejs#1554 so I'm closing this.

authors: icambron jimsimon-cengage maggiepint mj1856

repo: moment/moment


text:
[bugfix] In ES6 modules locale/* cannot be import  '../moment' in bro…

ES6 modules cannot import js files without a suffix in the browser

I'm not sure about this. Can't you just import the locale and the core separately (and not depend on the locale to fetch the core). I haven't seen people import with .js just because of this.

authors: ichernev tansan-dev


text:
chore(main): release 1.28.7

:robot: I have created a release beep boop
1.28.7 (2024-10-24)
Miscellaneous

update contributing documentation (#546) (babefcc)

This PR was generated with Release Please. See documentation.

:robot: Release is at https://github.com/momentohq/client-sdk-go/releases/tag/v1.28.7 :sunflower:

repo: momentohq/client-sdk-go


text:
chore(main): release 0.1.2

:robot: I have created a release beep boop
0.1.2 (2023-08-28)
Bug Fixes

use correct token for publishing to pypi (#11) (13a17e6)

This PR was generated with Release Please. See documentation.

:robot: Release is at https://github.com/momentohq/momento-python-redis-client/releases/tag/v0.1.2 :sunflower:

repo: momentohq/momento-python-redis-client


text:
🛑 haccp is down

In 3303b21, haccp (https://www.haccp.or.kr) was down:

HTTP code: 400
Response time: 1177 ms

Resolved: haccp is back up in 0d0f6dc after 8 minutes.


text:
🛑 haccp is down

In 1f2ed01, haccp (https://www.haccp.or.kr) was down:

HTTP code: 400
Response time: 931 ms

Resolved: haccp is back up in 4ebe719 after 9 minutes.


text:
Camurati-Engelmann disease types 1 and 2

From @cmungall on September 29, 2017 16:40
we make the call:

OMIM_131300 Camurati-Engelmann Disease SubClassOf Orphanet_1328 Camurati-Engelmann disease Pr= 0.08695652173913043

note the low probability. kboom is rightly flagging an issue here. Orphanet calls these as equivalent and doesn't acknowledge OMIM_606631 Camurati-Engelmann Disease, Type 2
However, if type 2 exists the correct thing to do is to group t1 and t2 under a superclass
https://en.wikipedia.org/wiki/Camurati–Engelmann_disease#Classification
"Type 2 Camurati-Engelmann Disease is still speculative, with no distinct evidence to credit its existence. There are many similarities between Type 2 CED and hyperostosis generalisata with striations of the bones (HGS), with some speculating they are two phenotypic variations of the same disease"
https://omim.org/clinicalSynopsis/606631
no phenotypes in hpoa
Copied from original issue: monarch-initiative/monarch-disease-ontology-RETIRED#399

From @pnrobinson on September 29, 2017 16:52
Cases like this are a hard call. Even though the case report got an OMIM number, it is still a relatively questionable one-off report and without more reports it is hard to say of there truly are two types of CES. Previously, OMIM was much more lenient with n+1 reports (this publication is from 2002!), and this certainly would not have warranted a separate OMIM id today. This is one of the things that really needs to be cleaned up in OMIM -- it at least needs a flag that it is n=1. We should try to do better in MONDO!

need to add n=1 subset tag to OMIM_606631 Camurati-Engelmann Disease, Type 2

added subset tag in PR https://github.com/monarch-initiative/mondo/pull/220

repo: monarch-initiative/mondo


text:
add OMIMPS to 'congenital vertebral-cardiac-renal anomalies syndrome'

closes #1804

trying to fix this conflict created a mess, so I'm closing this.
Looks like we already have the OMIMPS xref for this term too.


text:
Copy/Preview errors and does nothing

Kind of issue

[ ] Feature
[x] Bug
[ ] Design
[ ] Other, namely:

Description

Browser: Chromium 126.0.6478.114
Steps to reproduce (for me, at least):

Navigate to the preview viewer.
Press "Save Preview" or "Copy Preview".

Logs:
First Load
Error with Permissions-Policy header: Origin trial controlled feature not enabled: 'run-ad-auction'.
Error with Permissions-Policy header: Origin trial controlled feature not enabled: 'join-ad-interest-group'.

Save Preview
simple-icons-website-3f82880105436c5f.js:545 panicked at components/src/preview_generator/buttons.rs:210:48:
called `Result::unwrap()` on an `Err` value: JsValue(SecurityError: Failed to execute 'toDataURL' on 'HTMLCanvasElement': Tainted canvases may not be exported.
Error: Failed to execute 'toDataURL' on 'HTMLCanvasElement': Tainted canvases may not be exported.
    at https://wasm.simpleicons.org/simple-icons-website-3f82880105436c5f.js:1155:33
    at handleError (https://wasm.simpleicons.org/simple-icons-website-3f82880105436c5f.js:316:18)
    at imports.wbg.__wbg_toDataURL_07e0b35272e75f05 (https://wasm.simpleicons.org/simple-icons-website-3f82880105436c5f.js:1154:68)
    at https://wasm.simpleicons.org/simple-icons-website-3f82880105436c5f_bg.wasm:wasm-function[1249]:0x14e575
    at https://wasm.simpleicons.org/simple-icons-website-3f82880105436c5f_bg.wasm:wasm-function[3424]:0x1d580f
    at https://wasm.simpleicons.org/simple-icons-website-3f82880105436c5f_bg.wasm:wasm-function[2572]:0x1b3519
    at https://wasm.simpleicons.org/simple-icons-website-3f82880105436c5f_bg.wasm:wasm-function[3436]:0x1d637e
    at https://wasm.simpleicons.org/simple-icons-website-3f82880105436c5f_bg.wasm:wasm-function[2908]:0x1cd62f
    at __wbg_adapter_63 (https://wasm.simpleicons.org/simple-icons-website-3f82880105436c5f.js:279:10)
    at HTMLButtonElement.real (https://wasm.simpleicons.org/simple-icons-website-3f82880105436c5f.js:215:20))

Stack:

Error
    at imports.wbg.__wbg_new_abda76e883ba8a5f (https://wasm.simpleicons.org/simple-icons-website-3f82880105436c5f.js:532:21)
    at https://wasm.simpleicons.org/simple-icons-website-3f82880105436c5f_bg.wasm:wasm-function[3378]:0x1d4822
    at https://wasm.simpleicons.org/simple-icons-website-3f82880105436c5f_bg.wasm:wasm-function[1640]:0x18d046
    at https://wasm.simpleicons.org/simple-icons-website-3f82880105436c5f_bg.wasm:wasm-function[2632]:0x1b522c
    at https://wasm.simpleicons.org/simple-icons-website-3f82880105436c5f_bg.wasm:wasm-function[2114]:0x1a4e2a
    at https://wasm.simpleicons.org/simple-icons-website-3f82880105436c5f_bg.wasm:wasm-function[1249]:0x14e656
    at https://wasm.simpleicons.org/simple-icons-website-3f82880105436c5f_bg.wasm:wasm-function[3424]:0x1d580f
    at https://wasm.simpleicons.org/simple-icons-website-3f82880105436c5f_bg.wasm:wasm-function[2572]:0x1b3519
    at https://wasm.simpleicons.org/simple-icons-website-3f82880105436c5f_bg.wasm:wasm-function[3436]:0x1d637e
    at https://wasm.simpleicons.org/simple-icons-website-3f82880105436c5f_bg.wasm:wasm-function[2908]:0x1cd62f

imports.wbg.__wbg_error_f851667af71bcfc6 @ simple-icons-website-3f82880105436c5f.js:545
$func3378 @ simple-icons-website-3f82880105436c5f_bg.wasm:0x1d4928
$func1640 @ simple-icons-website-3f82880105436c5f_bg.wasm:0x18d046
$func2632 @ simple-icons-website-3f82880105436c5f_bg.wasm:0x1b522c
$func2114 @ simple-icons-website-3f82880105436c5f_bg.wasm:0x1a4e2a
$func1249 @ simple-icons-website-3f82880105436c5f_bg.wasm:0x14e656
$func3424 @ simple-icons-website-3f82880105436c5f_bg.wasm:0x1d580f
$func2572 @ simple-icons-website-3f82880105436c5f_bg.wasm:0x1b3519
$func3436 @ simple-icons-website-3f82880105436c5f_bg.wasm:0x1d637e
$_dyn_core__ops__function__FnMut__A____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__h1cce5f7ed142ca20 @ simple-icons-website-3f82880105436c5f_bg.wasm:0x1cd62f
__wbg_adapter_63 @ simple-icons-website-3f82880105436c5f.js:279
real @ simple-icons-website-3f82880105436c5f.js:215
simple-icons-website-3f82880105436c5f_bg.wasm:0x18d06c Uncaught RuntimeError: unreachable
    at simple-icons-website-3f82880105436c5f_bg.wasm:0x18d06c
    at simple-icons-website-3f82880105436c5f_bg.wasm:0x1b522c
    at simple-icons-website-3f82880105436c5f_bg.wasm:0x1a4e2a
    at simple-icons-website-3f82880105436c5f_bg.wasm:0x14e656
    at simple-icons-website-3f82880105436c5f_bg.wasm:0x1d580f
    at simple-icons-website-3f82880105436c5f_bg.wasm:0x1b3519
    at simple-icons-website-3f82880105436c5f_bg.wasm:0x1d637e
    at simple-icons-website-3f82880105436c5f_bg.wasm:0x1cd62f
    at __wbg_adapter_63 (simple-icons-website-3f82880105436c5f.js:279:10)
    at HTMLButtonElement.real (simple-icons-website-3f82880105436c5f.js:215:20)
$func1640 @ simple-icons-website-3f82880105436c5f_bg.wasm:0x18d06c
$func2632 @ simple-icons-website-3f82880105436c5f_bg.wasm:0x1b522c
$func2114 @ simple-icons-website-3f82880105436c5f_bg.wasm:0x1a4e2a
$func1249 @ simple-icons-website-3f82880105436c5f_bg.wasm:0x14e656
$func3424 @ simple-icons-website-3f82880105436c5f_bg.wasm:0x1d580f
$func2572 @ simple-icons-website-3f82880105436c5f_bg.wasm:0x1b3519
$func3436 @ simple-icons-website-3f82880105436c5f_bg.wasm:0x1d637e
$_dyn_core__ops__function__FnMut__A____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__h1cce5f7ed142ca20 @ simple-icons-website-3f82880105436c5f_bg.wasm:0x1cd62f
__wbg_adapter_63 @ simple-icons-website-3f82880105436c5f.js:279
real @ simple-icons-website-3f82880105436c5f.js:215

Copy Preview
panicked at components/src/copy.rs:61:57:
called `Result::unwrap()` on an `Err` value: JsValue(SecurityError: Failed to execute 'toBlob' on 'HTMLCanvasElement': Tainted canvases may not be exported.
Error: Failed to execute 'toBlob' on 'HTMLCanvasElement': Tainted canvases may not be exported.
    at https://wasm.simpleicons.org/simple-icons-website-3f82880105436c5f.js:1152:21
    at handleError (https://wasm.simpleicons.org/simple-icons-website-3f82880105436c5f.js:316:18)
    at imports.wbg.__wbg_toBlob_8adeddb6976528a5 (https://wasm.simpleicons.org/simple-icons-website-3f82880105436c5f.js:1151:65)
    at https://wasm.simpleicons.org/simple-icons-website-3f82880105436c5f_bg.wasm:wasm-function[1848]:0x19c2fa
    at https://wasm.simpleicons.org/simple-icons-website-3f82880105436c5f_bg.wasm:wasm-function[1019]:0x1311db
    at https://wasm.simpleicons.org/simple-icons-website-3f82880105436c5f_bg.wasm:wasm-function[3436]:0x1d637e
    at https://wasm.simpleicons.org/simple-icons-website-3f82880105436c5f_bg.wasm:wasm-function[2922]:0x1cd76e
    at __wbg_adapter_95 (https://wasm.simpleicons.org/simple-icons-website-3f82880105436c5f.js:303:10)
    at real (https://wasm.simpleicons.org/simple-icons-website-3f82880105436c5f.js:215:20))

Stack:

Error
    at imports.wbg.__wbg_new_abda76e883ba8a5f (https://wasm.simpleicons.org/simple-icons-website-3f82880105436c5f.js:532:21)
    at https://wasm.simpleicons.org/simple-icons-website-3f82880105436c5f_bg.wasm:wasm-function[3378]:0x1d4822
    at https://wasm.simpleicons.org/simple-icons-website-3f82880105436c5f_bg.wasm:wasm-function[1640]:0x18d046
    at https://wasm.simpleicons.org/simple-icons-website-3f82880105436c5f_bg.wasm:wasm-function[2632]:0x1b522c
    at https://wasm.simpleicons.org/simple-icons-website-3f82880105436c5f_bg.wasm:wasm-function[2114]:0x1a4e2a
    at https://wasm.simpleicons.org/simple-icons-website-3f82880105436c5f_bg.wasm:wasm-function[1848]:0x19c390
    at https://wasm.simpleicons.org/simple-icons-website-3f82880105436c5f_bg.wasm:wasm-function[1019]:0x1311db
    at https://wasm.simpleicons.org/simple-icons-website-3f82880105436c5f_bg.wasm:wasm-function[3436]:0x1d637e
    at https://wasm.simpleicons.org/simple-icons-website-3f82880105436c5f_bg.wasm:wasm-function[2922]:0x1cd76e
    at __wbg_adapter_95 (https://wasm.simpleicons.org/simple-icons-website-3f82880105436c5f.js:303:10)

imports.wbg.__wbg_error_f851667af71bcfc6 @ simple-icons-website-3f82880105436c5f.js:545
$func3378 @ simple-icons-website-3f82880105436c5f_bg.wasm:0x1d4928
$func1640 @ simple-icons-website-3f82880105436c5f_bg.wasm:0x18d046
$func2632 @ simple-icons-website-3f82880105436c5f_bg.wasm:0x1b522c
$func2114 @ simple-icons-website-3f82880105436c5f_bg.wasm:0x1a4e2a
$func1848 @ simple-icons-website-3f82880105436c5f_bg.wasm:0x19c390
$func1019 @ simple-icons-website-3f82880105436c5f_bg.wasm:0x1311db
$func3436 @ simple-icons-website-3f82880105436c5f_bg.wasm:0x1d637e
$_dyn_core__ops__function__FnMut__A____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__ha78d7a0d4fb3ac95 @ simple-icons-website-3f82880105436c5f_bg.wasm:0x1cd76e
__wbg_adapter_95 @ simple-icons-website-3f82880105436c5f.js:303
real @ simple-icons-website-3f82880105436c5f.js:215
simple-icons-website-3f82880105436c5f_bg.wasm:0x18d06c Uncaught RuntimeError: unreachable
    at simple-icons-website-3f82880105436c5f_bg.wasm:0x18d06c
    at simple-icons-website-3f82880105436c5f_bg.wasm:0x1b522c
    at simple-icons-website-3f82880105436c5f_bg.wasm:0x1a4e2a
    at simple-icons-website-3f82880105436c5f_bg.wasm:0x19c390
    at simple-icons-website-3f82880105436c5f_bg.wasm:0x1311db
    at simple-icons-website-3f82880105436c5f_bg.wasm:0x1d637e
    at simple-icons-website-3f82880105436c5f_bg.wasm:0x1cd76e
    at __wbg_adapter_95 (simple-icons-website-3f82880105436c5f.js:303:10)
    at real (simple-icons-website-3f82880105436c5f.js:215:20)

Every other button on the page works just fine with no console output.

Now that I look closer at the error, I've had this issue with other websites that make use of canvas (Figma, namely). I wonder what it is...

Are you using uBlock Origin?

I figured this out recently, it was one of the policies I set on Chromium way back, totally my fault. Don't even remember what policy it was. I'll check this specific site when I get back to my problem machine to make sure this isn't still an issue, but I suspect not. Thanks for the check-in, or else I would have forgotten to get back to y'all!

authors: kanielrkirby mondeja

repo: mondeja/simple-icons-website-rs


text:
merchants: remove newton.co

closes #1671

lgtm

authors: cirocosta erciccione

repo: monero-project/monero-site


text:
Create internal MongoClient for auto-encryption

JAVA-3932
During the testing of the reactive streams implementation, I discovered a bug in ListCollectionsOperation in which two connections were checked out concurrently (and only one used).  I've fixed that here as well.

Merged on command line:

https://github.com/mongodb/mongo-java-driver/commit/c329baa3645384e90fe9a55433803995ad39be43
https://github.com/mongodb/mongo-java-driver/commit/9b1670af30f197db20b4f70ce94ad35d4743b0df

Merged on command line:

https://github.com/mongodb/mongo-java-driver/commit/c329baa3645384e90fe9a55433803995ad39be43
https://github.com/mongodb/mongo-java-driver/commit/9b1670af30f197db20b4f70ce94ad35d4743b0df

repo: mongodb/mongo-java-driver


text:
NODE-1778: fix batch-size calculations

https://jira.mongodb.org/browse/NODE-1778
BSON parser treats array indexes as strings, see BSON parser: https://github.com/mongodb/js-bson/blob/v1.1.0/lib/bson/parser/serializer.js#L699, a batch is an array whose indexes bytes needs to be accumulated.

I think this is really a bug, and it has affected us to continue using mongodb. We hope that the node driver team can pay attention to this issue, thank you very much.
https://jira.mongodb.org/browse/NODE-1778

repo: mongodb/node-mongodb-native


text:
STITCH-2212 Swift SDK: Create a skeleton for sync operations and the data synchronizer

Add the skeletons for CoreSync and DataSynchronizer. We (essentially) get the entirety CoreSync here for free, since on Swift, it is a simple delegate for the DataSynchronizer.
This includes the NetworkMonitor and AuthMonitor protocols.
I've also added an internal FatalErrorListener for the arbitrary lower-level errors that can occur due to MongoSwift or otherwise. It is meant to listen for "impossible states", and will pass along whatever information it can to the user.
Though the PR seems large, much of it is tests/comments, and many of the DataSynchronizer methods are stubs. This should allow us to not step on each other for future tickets.

As discussed, a follow-up tech debt JIRA ticket should be created to rationalize the error handling into a consistent framework -- ideal dichotomy of "recoverable errors" (passed to a handler) vs "non-recoverable errors" (propagated)

authors: dkaminsky jsflax

repo: mongodb/stitch-ios-sdk


text:
duplicate objectids under puma server with multiple threads

This is really an issue in the BSON gem, but it looks like issue reporting is disabled on that repo.
With the puma ruby server, it utilizes multiple threads under a single process. By default, each puma process can spawn up to 16 threads. If you make enough simultaneous create requests, you can get two objects with the same id which results in the data for the second one overwriting that of the first (two requests get picked up by the same process, ie puma worker, which have identical process ids, but different Thread.current object ids).
It looks like the generate method special-cases the jRuby scenario to include the Thread.current's object_id in the process_id. I'm not exactly sure what the best way to detect the puma case would be, but I didn't see this issue mentioned anywhere so at the very least, hopefully this saves someone a headache. Always including the thread's object id would work, but I imagine there is a reason the current code doesn't do that.
For now, I've updated my puma config to limit each puma process to a single thread, which feels like I'm not getting much out of puma anymore, but at least it averts the issue at hand.

Are you sure it's possible to generate duplicate BSON::ObjectIds?
I've just checked the code, and looks like it uses a counter, protected by a Mutex, when generating the ID:
https://github.com/mongodb/bson-ruby/blob/84d8acd32ce9067ad646755e52f472a6ad685918/lib/bson/object_id.rb#L348
Do you have any other evidence for this claim?

Hmm, I actually didn't see that method when I was looking at the source. Its definitely hard to reproduce, but I was seeing odd behavior in my app and was pretty sure it was being caused by multiple new documents being assigned the same database id. I'll have to do a little more investigating and see if I can put together a simple app for reproduction.

If you are running inside docker containers, the code can be a little risky, since your process will always have PID=1. In that case, the Socket.gethostname would be the only source of entropy (aside from the timestamp, which we all know it's not enough).

I just ran some more tests locally and I can't reproduce it anymore, so I'll close the issue.

authors: apolzon fabiob

repo: mongoid/moped


text:
生成的证书问题

您好，请问你的ca.crt和ca_pub.der、ca_private.pem分别是怎么生成的
我自己采用了生成的证书老有问题
生成步骤：
1、openssl genrsa -out cakey.pem 2048
2、openssl req -new -key cakey.pem -out ca.csr
3、openssl x509 -req -days 365 -sha256 -extensions v3_ca -signkey cakey.pem -in ca.csr -out ca.cer
4、openssl pkcs8 -topk8 -nocrypt -inform PEM -outform DER -in cakey.pem -out ca_private.pem
5、openssl rsa -in cakey.pem -pubout -outform DER -out ca_pub.der

@cainwise 可以参考下我写的一篇博客OpenSSL创建带SAN扩展的证书并进行CA自签

@monkeyWie 很感谢您的回复 但是执行下面语句：
openssl rsa -in ca_private.pem -pubout -outform DER -out ca_pub.der
错误异常：
unable to load Private Key
10457:error:0906D06C:PEM routines:PEM_read_bio:no start line:/BuildRoot/Library/Caches/com.apple.xbs/Sources/OpenSSL098/OpenSSL098-64.50.6/src/crypto/pem/pem_lib.c:648:Expecting: ANY PRIVATE KEY

@cainwise
不好意思，生成公钥这步弄错了，是直接用ca.key来生成DER编码的公钥，2L答案已更新。

@monkeyWie
按照2L的格式来生成密钥
抛出的堆栈信息如下：
警告: An exceptionCaught() event was fired, and it reached at the tail of the pipeline. It usually means the last handler in the pipeline did not handle the exception.
java.io.IOException: 你的主机中的软件中止了一个已建立的连接。
at sun.nio.ch.SocketDispatcher.read0(Native Method)
at sun.nio.ch.SocketDispatcher.read(SocketDispatcher.java:43)
at sun.nio.ch.IOUtil.readIntoNativeBuffer(IOUtil.java:223)
at sun.nio.ch.IOUtil.read(IOUtil.java:192)
at sun.nio.ch.SocketChannelImpl.read(SocketChannelImpl.java:380)
at io.netty.buffer.PooledUnsafeDirectByteBuf.setBytes(PooledUnsafeDirectByteBuf.java:288)
at io.netty.buffer.AbstractByteBuf.writeBytes(AbstractByteBuf.java:1106)
at io.netty.channel.socket.nio.NioSocketChannel.doReadBytes(NioSocketChannel.java:373)
at io.netty.channel.nio.AbstractNioByteChannel$NioByteUnsafe.read(AbstractNioByteChannel.java:123)
at io.netty.channel.nio.NioEventLoop.processSelectedKey(NioEventLoop.java:645)
at io.netty.channel.nio.NioEventLoop.processSelectedKeysOptimized(NioEventLoop.java:580)
at io.netty.channel.nio.NioEventLoop.processSelectedKeys(NioEventLoop.java:497)
at io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:459)
at io.netty.util.concurrent.SingleThreadEventExecutor$5.run(SingleThreadEventExecutor.java:858)
at io.netty.util.concurrent.DefaultThreadFactory$DefaultRunnableDecorator.run(DefaultThreadFactory.java:138)
at java.lang.Thread.run(Thread.java:748)

@monkeyWie
采用你git上面的证书ok
但是手动生成的都会出现5L的问题

生成java支持的公钥和私钥

openssl genrsa -out ca.key 2048
openssl rsa -in ca.key -pubout -outform DER -out ca_pub.der
openssl pkcs8 -topk8 -nocrypt -inform PEM -outform DER -in ca.key -out ca_private.pem

再通过CA私钥生成CA证书

openssl req -sha256 -new -x509 -days 365 -key ca.key -out ca.crt \
    -subj "/C=CN/ST=GD/L=SZ/O=lee/OU=study/CN=proxyeeRoot"

@cainwise
会不会是openssl版本的问题，我这是Linux下，版本OpenSSL 1.0.1e-fips，测试没问题。

@monkeyWie
我用linux版本 openssl 1.0.2g也是一样的错误

@monkeyWie
您是否按照下面的方式生成然后替换到git上面的证书和公钥私钥
1.生成java支持的公钥和私钥
openssl genrsa -out ca.key 2048
openssl rsa -in ca.key -pubout -outform DER -out ca_pub.der
openssl pkcs8 -topk8 -nocrypt -inform PEM -outform DER -in ca.key -out ca_private.pem

1.再通过CA私钥生成CA证书
openssl req -sha256 -new -x509 -days 365 -key ca.key -out ca.crt \
    -subj "/C=CN/ST=GD/L=SZ/O=lee/OU=study/CN=proxyeeRoot"

@monkeyWie
是
openssl req -sha256 -new -x509 -days 365 -key ca.key -out ca.crt \
    -subj "/C=CN/ST=GD/L=SZ/O=lee/OU=study/CN=proxyeeRoot"

CN=proxyeeRoot   中的proxyeeRoot写错了需要大写ProxyeeRoot

@cainwise
额，那问题是已经解决了吗？，不过现在代码已经可以读取CA证书里的-sub内容来动态生成ssl证书了。

@monkeyWie
问题解决了
从CA证书里读取-sub内容来动态生成ssl证书  怎么实现的

@monkeyWie
问题解决了

authors: cainwise monkeyWie

repo: monkeyWie/proxyee


text:
Writing errors to StdErr in ConsoleDiagnostics

Looking at my output, I realized that errors are piped to the stdout instead of stderr.
https://github.com/mono/CppSharp/blob/8479ed3735b0e88b9dd816993bf8a0f0028e711f/src/Core/Diagnostics.cs#L123
I think it should look something like
public void Emit(DiagnosticInfo info)
{
    if (info.Kind < Level)
        return;

    var currentIndent = Indents.Sum();
    var message = new string(' ', currentIndent) + info.Message;

    if(info.Kind == DiagnosticKind.Error)
    {
        Console.Error.WriteLine(message);
    }
    else
    {
        Console.WriteLine(message);
    }
    Debug.WriteLine(message);
}

@tritao this is not devoid of sense, what do you think?

Seems fine to me. @iBicha feel free to send a PR with this change.

I think that should be fine.

authors: ddobrev iBicha tritao

repo: mono/CppSharp


text:
shepherd: don't try to recover nodes which have OSInstallationReport set

The shepherd currently attempts to reboot nodes which have been installed successfully, i.e. have OSInstallationReport set.

Fixed in https://review.monogon.dev/c/monogon/+/1672

repo: monogon-dev/monogon


text:
Fixes Pbs issues #175 and #177

#175 eliminates duplicated trailing ts segments from video.pbs.org
#177 Adds high definition video download from pbs.org

Thanks for the update.

authors: njtaylor pcwalden

repo: monsieurvideo/get-flash-videos


text:
fix Timoney asset

add anchor_asset_type="other" and display_decimals=7

Это необязательные поля. Даже лишние.

authors: AduchiMergen cblp

repo: montelibero-org/assets


text:
lb: HA setup for traefik

What were you trying to do?
I was trying to load api.moov.io (or infra.moov.io) resources while the node that traefik was running on had gone away.  This meant that connections were dropped until a new node took over and had the Traefik pod scheduled.
There's a problem currently with the PersistentVolume accessMode in that only one Pod can hold a write lock for the volume. What if we just deploy a traefik-alpha and traefik-beta ? That way there are 2 lb's up and running.

Oh, this will require a second type: LoadBalancer service, which might cost more? Need to double check on that.

repo: moov-io/infra


text:
Efficiency patch

Only login to email once and pull all the emails needed in one swoop - Fixes #14
Changed GIF rotation time to 5 seconds - Fixes #33
Subtract delivered packages from 'in transit' packages, should no longer result in negative counts - Fixes #5 and Fixes #36
No more slow start warnings since we check the email in one call now - Fixes #10
Added aspect ratio calculations to keep image looking correctly - Fixes #32
Added additional subject searches for FedEx emails - Fixes #34
Bump version to 0.1.0 since we're no longer using Imagemagick and fixed the speed issues, seemed like a good milestone.

I've been running this for the past 3-4 days, other than the aspect ratio bit which I haven't been able to confirm yet, all else works great.

FYI, I just add today = '18-Feb-2020'after line 901 in the sensor.py to pull a previous emails to test.
I had issues again with starting due to Mail Attachment.txt being added in the image array. I added the file name to line 828 in the sensor.py to the items to remove from the image array before processing.
remove_terms = ['mailerProvidedImage', 'ra_0' , 'Mail Attachment.txt']
The image rotation continues to be an issue. I think the is a limitation with file camera. My observation is that there are only 10 seconds to get through all the mail images before it reloads the file. I don't think I ever encountered that before since I embedded the imagine the custom card instead of using the camera component.
So, my 4 mail images at 5 seconds each only gets through 2 images.
If I set the duration to 10, I only ever see 1 image. Not sure what the fix is here for a good viewing speed and being able to show the user all mail images.
For image resizing, doesn't seem to be there. I thought that maybe rescale is what should be used by I couldn't get the results. I think you would have to evaluate images widths and height because either could be out of the 317 x 700 perimeter. I'll keep looking into this.

The image rotation continues to be an issue. I think the is a limitation with file camera. My observation is that there are only 10 seconds to get through all the mail images before it reloads the file. I don't think I ever encountered that before since I embedded the imagine the custom card instead of using the camera component.

Setting the lovelace card to "live" resolved this for me.

For image resizing, doesn't seem to be there yet. I thought that maybe rescale is what should be used but I couldn't get the right results either. I think you would have to evaluate images widths and height because either could be out of the 317 x 700 parameter. I'll keep looking into this.

The resize function isn't working for you then? Or should I have it resize the width too?
# Resize images
# This should keep the aspect ratio of the images
#################################################

def resize_images(images):
    sized_images = []
    for image in images:
        if image.shape[1] < 700:
            wpercent = 700/image.shape[1]
            height = int(float(image.shape[0])*float(wpercent))
            sized_images.append(img_as_ubyte(resize(image, (height, 700))))
        else:
            sized_images.append(img_as_ubyte(resize(image, (317, 700))))

    return sized_images

Setting the lovelace card to "live" resolved this for me.

I see, you put in a picture entity card and that has the live setting. If this is the case we should probably make a note of the issue with a regular entity and change the 3 recommended configuration in the documentation to use the this card with the live settings on.

Today I am getting the message that the image-no-mailpieces700.jpg doesn't exist inside the www path. I thought I read that the component now populates that folder?
The image sizing is currently evaluating if the image width is less than 700. The intended function should be if the image width is greater than 700 do something. Even after scaling down the width, it is possible for the image height to still be too large for the intended canvas size. Also there is a type for the height, to match the no image for mail file the size 315px instead of 317.
The logic
From original image array, If image height is greater than 315
get new width, make image 315 x new width
add to first_pass_images array
else
add unmodified image to first_pass_images array
From first_pass_images array, If image width is greater than 700
get new height, make image new height x 700
add to sized_images array
else
add unmodified image to sized_images array
This is getting there. When stitching together in the gif, my first image was resized to w:660h:315 and that becomes the size of the gif.
Two options I can think of now:

Find how skimage can add blank pixels to make all the images exactly 315 x 700 after they are sized to fit within that size.
Add a template image that is 315 x 700 to always be the first image of the array so the gif always takes on the right size. It could say 'mail today' or something so it's not just a blank slide.

`# Resize images
This should keep the aspect ratio of the images
#################################################
def resize_images(images):
first_pass_images = []
sized_images = []
for image in images:
#1 height
if image.shape[0] > 315:
shape = "w:" + str(image.shape[1]) + "h:" + str(image.shape[0])
wpercent = 315/image.shape[0]
width = int(float(image.shape[1])*float(wpercent))
size = "w:" + str(width) + "h:315"
first_pass_images.append(img_as_ubyte(resize(image, (315, width))))
_LOGGER.debug("Image size: %s", str(shape))
_LOGGER.debug("Image too tall, new width: %s", str(width))
_LOGGER.debug("resize percent: %s", str(wpercent))
_LOGGER.debug("new size: %s", str(size))
else:
first_pass_images.append(image)
_LOGGER.debug("Image fine")
for image in first_pass_images:
    #1 check hegh
    if image.shape[1] > 700:
        shape = "w:" + str(image.shape[1]) + "h:" + str(image.shape[0])
        wpercent = 700/image.shape[1]
        height = int(float(image.shape[0])*float(wpercent))
        size = "w:700" + "h:" + str(height)
        sized_images.append(img_as_ubyte(resize(image, (height, 300))))
        _LOGGER.debug("Image size: %s", str(shape))
        _LOGGER.debug("Image too wide, new height: %s", str(height))
        _LOGGER.debug("resize percent: %s", str(wpercent))
        _LOGGER.debug("new size: %s", str(size))
    else:
        sized_images.append(image)
        _LOGGER.debug("Image fine")

return sized_images`

In my goosing I did find this, using a different library.
https://jdhao.github.io/2017/11/06/resize-image-to-square-with-padding/

I'm going to merge this, add in the additional remove term, and add in the information for the camera card needing to be 'live' to the readme.
I think that would be good for a new release and the continue to work on the image sizing.


text:
Travis can't set profiling results for pull requests

As seen in #23, all travis builds for pull requests currently fail.
Reason: A pull request could change anything, including brofiler.py. And anyone can create a pull request. Because of that, travis doesn't set secret variables when building pull requests from forks, to avoid straight up leaking the secret.
Yo @moritzuehling, please choose a solution:

somehow convince me to fix it
Use a Workaround: Just ignore it because it doesn't affect internal pull requests and copy pull requests to internal branches to test them
assign it to me and I'll close it as wontfix
assign it to yourself and fix brofiler.py, so it detects pull request builds (travis will set special envvars for that) and doesn't try to set a commit status for those (just print the link to console instead)

Meh, we don't really need this, right...?

authors: main-- moritzuehling

repo: moritzuehling/demoinfo-public


text:
Accessibility - Is there any way to to navigate using keys (keyboard)

I want a user to be able to show more content on the autosuggest dropdown just like Amazon's search bar, and I am able to show more content on the search bar, but unable to give more ability in terms of accessibility like on amazon's search bar.
Amazon sample:

Application search bar:

Is there a way to achieve this effect? Any workarounds you can think off?

This works on the CDN example in https://react-autosuggest.js.org/, but the library does not. This is a requirement of the web now. Please get this fixed.
In the meantime, do you have any work arounds or pointers on how to implement this?

The examples appear to be using an older version of react-autosuggest. The latest 9.x version (9.4.3) seems to work.

authors: KyleWiteck convpal willbutler

repo: moroshko/react-autosuggest


text:
Video Screen Recording Limited (to 2 minutes)?

Is that correct?
That appears to be the same limit in Android Studio so it looks like you haven't been able to get around that limitation.

It looks like this app is using adb command to record screen. And adb's maximum recrod limit is 180 second(3 minutes).

authors: joshuapinter smashingpks

repo: mortenjust/androidtool-mac


text:
Add MLFlowLogger

What does this PR do?
Adds basic MLFlowLogger that support the following things:

setting experiment name
setting run name
setting tracking_uri
logging metrics
logging params (hyperparameters)

tested manually and added unit tests
What issue(s) does this change relate to?
fixes CO-1245
Before submitting

[x] Have you read the contributor guidelines?
[ ] Is this change a documentation change or typo fix? If so, skip the rest of this checklist.
[x] Was this change discussed/approved in a GitHub issue first? It is much more likely to be merged if so.
[x] Did you update any related docs and document your change?
[x] Did you update any related tests and add any new tests related to your change? (see testing)
[x] Did you run the tests locally to make sure they pass?
[x] Did you run pre-commit on your change? (see the pre-commit section of prerequisites)

Nice! LGTM. Would wait to also get review from @dakinggg though -- 2 reviews for this before we ship to customers would be ideal. Edit: Looks like he's codeowner anyways so its forced
I assume you've tested end-to-end?

yup. they don't have a native dashboard. it's similar to tensorboard.

repo: mosaicml/composer


text:
Replace DataSpec with ComposerDataLoader

Part one of a two-part series in which I hope to make the API for dataloaders more like models. In this part, I move DataSpec from composer.core to composer.datasets, make it extend rather than encapsulate a torch.DataLoader, and rename it to ComposerDataLoader.
In my opinion, DataSpec/ComposerDataLoader is a necessary evil that we should continue to try to find ways to remove fields from. Moving it out of core reflects its status as niche. Having it extend torch.DataLoader lets us pretend it doesn't exist in much of our type signatures and docs (though maybe some would argue that's a bad thing).
However, the real underlying motivation for this is that in a follow-up PR I want to create subclasses of ComposerDataLoader for each of the datasets we support in composer.datasets. Currently, there's an awful lot of logic for setting up dataset transformations and synthetic data that is only available in initialize_object for YAHP users. This is also making code-driven initialization of our minimal Composer examples a lot more verbose than feels necessary. See here - the dataset initialization is half the length of the example, even with a custom model.

I agree that DataSpec is a necessary evil, and would like to minimize its fields. I am of similar opinion regarding Evaluator in the longer-term. However, I am not convinced by the ComposerDataLoader approach, for a few reasons beyond what @ravi-mosaicml had mentioned above:

ComposedDataLoader is more complex and unintuitive regarding our intentions. We'd like to attach metadata, but users would interpret that we are/may modify the __iter__ and other core dataloading logic, making integration with their own datasets difficult. DataSpec clearly delinates a boundary between the pytorch object and the metadata.
Discoverability is harder in the trainer API signature in this case.
I suspect with all the various datatypes out there, split_batch_fn will be commonly required, and eventually i'd like for users to pass in a dict with this config without needing to import.

I do agree with moving DataSpec from core to Datasets.
An alternate approach to address the apt observation on initialize_object is to offer create_imagenet_dataset methods, rather than creating dataset-specific objects? Would that work @jbloxham ?
Side note: multiple places in our API we need to attach metadata to a pytorch-native objects (e.g. dataloader, schedulers (step or interval), eval_dataloader (metrics), model (many)). While the complexity of the metadata dictates our implementation, perhaps we can standardize on a consistent set of rules here? For example:

When we do not anticipate needing to override the pytorch object methods, we use dict or a ___Spec (or __Config might be less surprising to data scientists). We strive to minimize the number of fields here.
Otherwise, we extend the class. For example, ComposerModel is required because the torch.nn.Module.forward() needs to be overridden.

There could be exceptions of course for complexity or consistency with previous practice in the community.

This is going on a tangent now, but I actually think it would be simplifier if we switched the model class to be a ModelSpec, similar to dataloader spec. There is no need to subclass it, other than that's what PTL does. We always have to "unwrap" the model to retrieve the original loss function, metrics, etc... after it has been wrapped by DeepSpeed or DDP. It would definitely simplify things if we had a ModelSpec, where only the model attribute was wrapped. So, from a style guide perspective, I would prefer the config/spec/dict approach.

An alternate approach to address the apt observation on initialize_object is to offer create_imagenet_dataset methods, rather than creating dataset-specific objects? Would that work @jbloxham ?

Can you elaborate? Sorry, a bit confused on what this would look like and what this would accomplish?

This is going on a tangent now, but I actually think it would be simplifier if we switched the model class to be a ModelSpec, similar to dataloader spec. There is no need to subclass it, other than that's what PTL does. We always have to "unwrap" the model to retrieve the original loss function, metrics, etc... after it has been wrapped by DeepSpeed or DDP. It would definitely simplify things if we had a ModelSpec, where only the model attribute was wrapped. So, from a style guide perspective, I would prefer the config/spec/dict approach.

I like the idea of this, but I'm not sure what it would look like in practice. The validate, loss, and metrics functions are all critical for the Composer Trainer, and generally lack reasonable defaults. I guess if ModelSpec were a dict, that would be one less object for users to import, but come on, that alone doesn't meaningfully reduce the complexity of creating a custom model that can be used with the Composer Trainer.

Going to close this PR for now. Will create another one to move DataSpec from core to datasets.

authors: hanlint jbloxham ravi-mosaicml


text:
Landing page

We should update the landing page to reflect what we've done so far:
Conference paper
Iacovella, C. R.; Sallai, J.; Klein, C.; Ma, T. Idea Paper : Development of a Software Framework for Formalizing Forcefield Atom-Typing for Molecular Simulation. In 4th Workshop on Sustainable Software for Science: Practice and Experiences (WSSSPE4); 2016.
http://ceur-ws.org/Vol-1686/WSSSPE4_paper_35.pdf
SSI-SSE poster:
Iacovella, Christopher; Sallai, Janos (2017): SI2-SSE: Development of a Software Framework for Formalizing ForceField Atom-Typing for Molecular Simulation. figshare.
https://doi.org/10.6084/m9.figshare.4573048.v1
Forcefields:
PFAs:
https://github.com/chrisiacovella/oplsaa_perfluoroalkanes
Alkylsilane:
https://github.com/summeraz/OPLSaa_alkylsilanes
PFPEs paper:
http://pubs.acs.org/doi/abs/10.1021/acs.jpcb.7b00891
and associated PFPE forcefield:
http://dx.doi.org/10.5281/zenodo.583310

Could you just copy paste that into a PR against the README?

repo: mosdef-hub/foyer


text:
configmanager add new function for update host

Issues associated with this PR
Your PR should present related issues you want to solve.
Solutions
You should show your solutions about the issues in your PR, including the overall solutions, details and the changes. At this time, Chinese is allowed to describe these.
UT result
Unit Test is needed if the code is changed, your unit test should cover boundary cases, corner cases, and some exceptional cases. And you need to show the UT result.
Benchmark
If your code involves the processing of every request, you should give the Benchmark Result.
Code Style

Make sure Goimports has run
Show Golint result

+1

Codecov Report

Merging #987 into master will increase coverage by 0.04%.
The diff coverage is 100%.

@@            Coverage Diff             @@
##           master     #987      +/-   ##
==========================================
+ Coverage      55%   55.05%   +0.04%
==========================================
  Files         238      238
  Lines       23334    23367      +33
==========================================
+ Hits        12836    12865      +29
- Misses       9323     9325       +2
- Partials     1175     1177       +2

Impacted Files
Coverage Δ

pkg/configmanager/configmanager.go
95.45% <100%> (+0.8%)
:arrow_up:

pkg/module/http2/server.go
81.92% <0%> (-0.15%)
:arrow_down:

pkg/module/http2/transport.go
78.76% <0%> (-0.15%)
:arrow_down:

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 1609ae1...b8057da. Read the comment docs.

authors: codecov-io killagu nejisama

repo: mosn/mosn


text:
Missing error handling in SchemaRegistry-Communication in schemaRegistry.go

Ignoring the error response results in some trouble finding the issue with outdated configuration.
// Default version of the schema is the latest version
// If CacheSchemas is true, the client will cache the schema
if version == 0 {
	schemaInfo, _ = srClient.GetLatestSchema(subject)
} else {
	schemaInfo, _ = srClient.GetSchemaByVersion(subject, version)
}```

Fixed in https://github.com/mostafa/xk6-kafka/blob/f085bb6d6e56c925c89739a45e7c8e3be3eff573/schema_registry.go#L64-L67

authors: hildebrandttk mostafa


text:
Linear/Grid Layout

I wanted to continue the discussion of laying out subviews according to columns, tables, grids, or "typewriter" layout.
I am especially interested in grid or typewriter layouts, because I am hoping to support both iPhone and iPad from the same codebase, and the iPad will often use grids. Also, I'm trying to avoid the complexity of UITableView and UICollectionView when cell-reuse isn't needed.
I tried the proposed example for a vertical layout:
module MotionKit
  class UIViewLayout

  # inside this block, calls to 'row' will add a row to a container.  After the
  # block is called, constraints are added to the rows so that they stack
  # vertically.
  def vertical_layout(&block)
    # because MotionKit relies on delegation, it's important to store "state"
    # in the motion_kit_meta object
    rows_was = target.motion_kit_meta[:motionkit_rows]
    target.motion_kit_meta[:motionkit_rows] = []

    container = add(UIView, &block)
    rows = target.motion_kit_meta[:motionkit_rows]
    prev_row = nil

    rows.each do |row|
      context(row) do
        constraints do
          if prev_row
            top.equals(prev_row, :bottom)
          else
            top.equals(container, :top)
          end
        end
      end
      prev_row = row
    end
    target.motion_kit_meta[:motionkit_rows] = rows_was

    rows
  end

  # a shortcoming of this method, I couldn't think of any other way to set an
  # explicit height.  If you're using auto-layout *everywhere* we might be able
  # to use intrinsic sizes, but that gets complicated...
  def row(height, &block)
    row = add(UIView, &block)
    context(row) do
      constraints do
        width.is == superview.frame.size.width
        height.is == height
      end
    end
    target.motion_kit_meta[:motionkit_rows] << row

    row
  end

end

This throws an exception because in row, target is a different object than it is in vertical_layout, so target.motion_kit_meta[:motionkit_rows] isn't set.
Thanks!

These ideas might resurface, but for now I'm going to close this.

authors: colinta emptyarray

repo: motion-kit/motion-kit


text:
Can't require files with same name as sibling directory

When running our current stack I get:
[Error: Unable to resolve 'babel-runtime/core-js/symbol' from '$root/node_modules/babel-runtime/helpers' at /Users/nw/motion/packages/motion/node_modules/pundle/lib/path.js:59:15]

Fixes with:
mv node_modules/babel-runtime/core-js/symbol.js node_modules/babel-runtime/core-js/symbol/index.js

repo: motion/pundle


text:
Update to recent 0.24.* versions

Please update with latest 0.24.* versions

@motiz88 do you need any help?
I am really new to docker (don't really use it) and work on OS X, but I will have to works with people that have Windows machine, so this project is my best shot.
Maybe you could give hints on how to make a PR for a new version?

I've sent a PR for all recent versions: #3

Thanks!

authors: MoOx avaly


text:
Trouble running the app

Hi there,
This is an interesting app and I wanted to try using 435 cameras.
I am using Raspberry 4 and installed the app (I guess).
I am not an expert but I am trying to help my daughter for a project,
Could you help how t run this app?  We have done "Building the Example"
To run the example code do the following :
Open a terminal and change directory to the sample base directory
Connect your Intel RealSense depth camera and NCS device.
Type the following command in the terminal: make all
Note: Make sure your Intel RealSense libraries are installed beforehand.
We gt failure in "Running the Example"
After building the example you can run the example code by doing the following :
Open a terminal and change directory to the sample base directory- we are running in ncappzoo-master/apps/realsense_object_distance_detection
Type the following command in the terminal: make run gives follwing error
hecking OpenVINO environment...
Please initiate the Intel OpenVINO environment by going to the installation directory for openvino and running the setupvars.sh file in the bin folder.
make[1]: *** [Makefile:61: compile_model] Error 1
make[1]: Leaving directory '/home/pi/Downloads/ncappzoo-master/networks/ssd_mobilenet_v1_caffe'
cp: cannot stat 'mobilenet-ssd.xml': No such file or directory
cp: cannot stat 'mobilenet-ssd.bin': No such file or directory
make: *** [Makefile:28: default_model] Error 1

Update with more info:realsense_object_distance_detection/cpp $ make run
g++     run.cpp   -o run
run.cpp:13:10: fatal error: opencv2/highgui/highgui.hpp: No such file or directory
#include <opencv2/highgui/highgui.hpp>
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
compilation terminated.
I tried to install opencv again. But the .usr/include does not have this .
I tried to put absolute path in cpp file  for the .hpp file. Still does not work:g++     run.cpp   -o run
In file included from run.cpp:19:
/home/pi/opencv/modules/highgui/include/opencv2/highgui/highgui.hpp:48:10: fatal error: opencv2/highgui.hpp: No such file or directory
#include "opencv2/highgui.hpp"
^~~~~~~~~~~~~~~~~~~~~
compilation terminated.
make: *** [: run] Error 1
Looks like small file link eoor. please help

I fixed the livrary structure by running make install with package.
Now the new problem in my opencv2 folder is inside opencv4.
I syll have the issue:
In file included from run.cpp:14:
/usr/local/include/opencv4/opencv2/highgui/highgui.hpp:48:10: fatal error: opencv2/highgui.hpp: No such file or directory
#include "opencv2/highgui.hpp"
^~~~~~~~~~~~~~~~~~~~~
compilation terminated.
make: *** [: run] Error 1

Have you solved this problem? I have also met the same / similar problem like you. It is too difficult for me. IF you HAVE SOLVED it , please reply to me in the website

authors: RexLeeeeee sarathynp

repo: movidius/ncappzoo


text:
Draft for job decoupling discussion

What's changing
A new generic create_job_alt is proposed. The key changes are:

Job data are retrieved from a dict, which allows programmatic changes in the future, and a more general config and use right now
Job config models are stored in the same dict from a statically imported file

Currently models are used in standalone scripts, so they need to be added to lumigator somehow

The image build process could include these files somehow (maybe using the mechanisms in https://hatch.pypa.io/latest/config/build/)
The models could be included in lumigator itself, and the scripts could import the lumigator_schemas package

More dynamic imports using importlib to load models at load-time or run-time could be done later on without changes to the current job creation

Additional steps can be added as hooks, if needed, in the same way that the model code is added

The current code has not been checked; once the approach is validated, a full, working implementation will be provided.
How to test it
N/A; draft for discussion at the moment.
Additional notes for reviewers
N/A
I already...

[ ] added some tests for any new functionality
[ ] updated the documentation
[ ] checked if a (backend) DB migration step was required and included it if required

Closing this PR as the issue has been discussed internally and issues have been created.

repo: mozilla-ai/lumigator