text:
Return evicted values to user

I am currently working on a DBMS and consider this library as a good replacement for a self-written buffer pool. But at the moment there aren't alternative functions in those places where entry eviction can occur.
I added the suffix _evict to such functions so as not to violate the public interface. I still have questions about the name of such suffix, but there are no other ideas yet.
Also bumped version to 0.3.1, according to semver, and updated dependencies.

Thank you for your contribution.
In the past, I thought about implementing this, but wasn't sure what to do in the scenarios where more than one entry gets evicted (with weighting). This is also bad because all but the drop are happening inside shard.rs while holding the exclusive lock.
Any thoughts on that? At a minimum, I think the evict suffixes should mention in their comment that only the last evicted value is returned.

The issue was solved in the stupidest way - by return vector of such evictions wrapped in an Option (vector is guaranteed to be non-empty).
Yes, there are more allocations... Through the benchmark, it turned out that the performance regressed by 10-20%, but considering that the initial figures were about 2 ms on my i7-4500U, it's not so scary. Maybe :)
In particular, tests for correct behavior have not yet been written. I'm still thinking about this question... Of course, if performance regression is optimal for you.

Sadly, I cannot accept the PR as is because of the performance regressions for the common use case (no eviction listeners).
I think an Ejector trait could work nicely :+1:

I've added an experimental Lifecycle trait to master https://github.com/arthurprs/quick-cache/commit/ae2a0f6bf396bc36da588b2fe959f8c11fc34568. It might need a little bit more though, but the default impl adds no overhead compared to the current release.

authors: arthurprs sicikh

repo: arthurprs/quick-cache


text:
spherov2.controls.PacketDecodingException: Bad response checksum when connecting to multiple Spheros

I'm trying to connect to multiple Sphero Bolts at once but when I get to around 3 connections sometimes I'll get the following error
spherov2.controls.PacketDecodingException: Bad response checksum

I modified v2.py to log the unescaped packet that didn't have the correct checksum
Sphero 1:
0x8d 0x30 0x11 0x2 0x18 0x2 0xff 0x3f 0x7f 0xf3 0x84 0x3c 0x28 0xcf 0xc2 0x3c 0x87 0xcb 0xf5 0x38 0x5f 0xd 0xfc 0x3f 0x97 0x23 0x72 0x3f 0xf3 0x26 0x3a 0xbb 0xc7 0xba 0x18 0x3c 0xff 0xdf 0x38 0xbc 0x6a 0xd5 0x56 0x3f 0x7e 0x5d 0xb8 0x8d 0x30 0x11 0x2 0x18 0x2 0xff 0x3f 0x7f 0xf3 0x8f 0x3c 0x26 0x36 0xdf 0x3c 0x88 0x46 0x62 0x38 0x69 0x11 0xb9 0x3f 0x94 0xcf 0xf8 0x3f 0xf4 0x1 0x9e 0xbb 0xd0 0xb1 0xab 0x23 0x3c 0xff 0x13 0x60 0xbc 0xb5 0x98 0x98 0x3f 0x7e 0x5e 0x4c 0x3f 0x7e 0x8e 0x75 0xb6 0x98 0x56 0xfd 0xb8 0x2d 0x1a 0xfd 0xb6 0x8f 0x38 0x75 0xb7 0x85 0x64 0x50 0x41 0xde 0xbc 0xb1 0x3c 0xca 0xae 0x24 0xbe 0xb3 0x22 0x36 0x0 0x0 0x0 0x0 0x43 0xbd 0xcf 0x5c 0x75 0xd8

Sphero 2:
0x8d 0x30 0x11 0x2 0x18 0x2 0xff 0x3f 0x7f 0xc3 0x25 0x3d 0x6 0x18 0xd0 0xbc 0xe5 0x73 0x85 0xb8 0x2a 0x12 0x8d 0x30 0x11 0x2 0x18 0x2 0xff 0x3f 0x7f 0xc2 0xe9 0x3d 0x6 0xd5 0x43 0xbc 0xe4 0xc6 0xb9 0xb8 0xc 0xa 0x3 0x40 0x71 0x8c 0x74 0xc0 0x4c 0xbc 0x13 0x3b 0x7a 0xf9 0x23 0xbd 0x4d 0x7a 0xdd 0xbd 0x8b 0x7a 0x68 0x3f 0x80 0x5 0x2d 0x3f 0x80 0x7a 0x2c 0x36 0xb6 0x59 0x20 0x39 0x5 0xe0 0x32 0x37 0xc 0xd9 0x11 0xb7 0x87 0xd 0x55 0x41 0xba 0x97 0xa7 0x3c 0xc8 0xb8 0xb4 0x3e 0x58 0x6d 0x91 0x0 0x0 0x0 0x0 0x43 0x9c 0x18 0x0 0xfb 0xd8

Sphero 3:
0x8d 0x30 0x11 0x2 0x18 0x2 0xff 0x3f 0x7f 0xd0 0x2d 0x3d 0x1b 0xeb 0x8c 0xbb 0x4d 0x57 0x17 0xb9 0x45 0xc3 0x93 0x40 0x8b 0x9e 0x83 0xbe 0xb8 0x1e 0x4d 0x3c 0xb1 0x2d 0x42 0xbb 0xb4 0x54 0x9c 0xbd 0x99 0x7e 0x72 0x3f 0x7f 0xc8 0xfb 0x8d 0x30 0x11 0x2 0x18 0x2 0xff 0x3f 0x7f 0xcf 0xdc 0x3d 0x1c 0x77 0xd1 0xbb 0x48 0x8b 0x6b 0xb9 0x4c 0x79 0xde 0x40 0x8c 0x1c 0x29 0xbe 0xb3 0xd7 0xd9 0x3c 0xb7 0x30 0xe6 0xbb 0xb4 0x75 0x53 0xbd 0x99 0x79 0xc 0x3f 0x7e 0xc7 0xe5 0x3f 0x7f 0x81 0x86 0xb5 0xdb 0xb2 0xe9 0x36 0x34 0x2f 0xad 0xb6 0xb 0x58 0x91 0x38 0x30 0xf2 0xaa 0x41 0x50 0x84 0xb5 0xbd 0x87 0x97 0xaf 0xbd 0x2e 0x69 0x9d 0x0 0x0 0x0 0x0 0x42 0xea 0xc3 0xd6 0xa0 0xd8

Looking through the packets each has a SOP byte after the initial SOP byte which is why I assume the checksum is failing

I had Wireshark opened at the same time and it looks like some packets are being dropped. Attached is a file with the faulty packets for Sphero 1. What's wrong is that it's a mash of two different Sphero commands with some bluetooth packets just being dropped.
faulty_packets.pcapng.zip

appreciate the investigation. i'll look into it as well once i came back from vacation.

Just to link things together, I found that the DBUS API is not sending the packets to Bleak – here's the issue on the Bleak repo: https://github.com/hbldh/bleak/issues/1343

Ok it looks like it's a BlueZ issue, I tried using AcquireNotify instead of StartNotify and it also gives the error (with even less ~5 instead of ~12) simultaneous connections. Issue at: https://github.com/bluez/bluez/issues/539

source: gharchive/issue

authors: r-bt superfashi

license: MIT

license_type: permissive

license_source: github-api


text:
artwork buttons do not work

go to artwork page, try to tap contact button, nothing happens, tapping heart, share, auction results, nothing happens. Go to different artwork try all the same buttons again, nothing.
http://cl.ly/image/0q210b0z1j0N

I don't see this happening for me

i got this to happen in the simulator, but i can't figure out how

i can not for the life of me figure out how to make this bug happen but it is real

repo: artsy/eigen


text:
[Live/Auctions] Auction Information shows per-auction details about buyer's premum

@katarinabatina happy to change the wording on this button if you'd like?

Looks like this when you click:

Not perfect, but could be made to look nicer in force pretty easily, which I can take a look at. I do need to make more of an effort on that side.

Screenshots are a little different than reality ( we have a title for the Buyer's premium page, and there's a ' in the button now )

Cool beans 👍

source: gharchive/pull-request


text:
feat(FX-3667):  Applying rounding when converting a value from cm to in

The type of this PR is: Feature

This PR resolves FX-3667
Context
If the user specifies the same custom size values for Force and Eigen, they will be converted to inches differently. In turn, this can add problems when working with saved search alerts
Force

width: 100 - 199 cm -> 39.37 - 78.35 in
height: 200 - 299 cm -> 78.74 - 117.72 in

Eigen

width: 100 - 199 cm -> 39.37007874015748 - 78.34645669291338 in
height: 200 - 299 cm -> 78.74015748031496 - 117.71653543307086 in

Acceptance Criteria

Values from cm to in should be converted equally to Force and to Eigen

PR Checklist (tick all before merging)

[x] I have included screenshots or videos to illustrate my changes, or I have not changed anything that impacts the UI.
[x] I have tested my changes on iOS and Android.
[x] I have added tests/stories for my changes, or my changes don't require testing/stories, or I have included a link to a separate Jira ticket covering the tests.
[x] I have added a feature flag, or my changes don't require a feature flag. (How do I add one?)
[x] I have documented any follow-up work that this PR will require, or it does not require any.
[x] I have added an app state migration, or my changes do not require one. (What are migrations?)
[x] I have added a changelog entry below or my changes do not require one.

To the reviewers 👀

[ ] I would like at least one of the reviewers to run this PR on the simulator or device.

Changelog updates
Changelog updates

Cross-platform user-facing changes

iOS user-facing changes

Android user-facing changes

Dev changes

Applying rounding when converting a value from cm to in - dimatretyak

This PR contains the following changes:

Dev changes (Applying rounding when converting a value from cm to in - dimatretyak)

  Generated by :no_entry_sign: dangerJS against 429ad6e28a5bce2b2997fe6fb0898a113a3006d8

Updated logic on Force: artsy/force#9096

authors: ArtsyOpenSource dimatretyak


text:
chore: Remove find-node.sh from react-native (patch-package)

The type of this PR is: chore

Description
Removes find-node.sh from  from node_modules/react-native/scripts/generate-specs.sh with patch-package to the"Command PhaseScriptExecution failed with a nonzero exit code" build error related to node version managers.
The script seems to be removed completely from newer RN versions (https://github.com/facebook/react-native/pull/33146).
PR Checklist (tick all before merging)

[ ] I have included screenshots or videos to illustrate my changes, or I have not changed anything that impacts the UI.
[ ] I have tested my changes on iOS and Android.
[ ] I have added tests/stories for my changes, or my changes don't require testing/stories, or I have included a link to a separate Jira ticket covering the tests.
[ ] I have added a feature flag, or my changes don't require a feature flag. (How do I add one?)
[ ] I have documented any follow-up work that this PR will require, or it does not require any.
[ ] I have added an app state migration, or my changes do not require one. (What are migrations?)
[ ] I have added a changelog entry below or my changes do not require one.

To the reviewers 👀

[ ] I would like at least one of the reviewers to run this PR on the simulator or device.

Changelog updates
Changelog updates

Cross-platform user-facing changes

iOS user-facing changes

Android user-facing changes

Dev changes

@pvinis I decided to just remove the find-node.sh from the script that caused my build to fail. We could also remove it completely in the patch but I don't see why this would be necessary.

Closing this PR. Removing the unused folder $HOME/.nvm/nvm.sh fixed the issue.


text:
MX-100 - Removes SearchLink from Fair

This is the Emission side of MX-100
Paired with @brainbicycle on this as a first-issue
MX-100

:rocket: PR was released in v1.19.17 :rocket:

authors: artsyit kierangillen

repo: artsy/emission

license: mit

license_source: bigquery


text:
Unrelated or no completion at all

Either I get no suggestions or suggestions that have nothing to do with the object. For example when typing "a" one expects something like "add()" but instead I get all of these suggestions. Add was not in the list.

Here is an example where I get no completion options for the Scanner object. This doesn't happen to all objects. For example Integer works like expected.

EDIT
Okay. The unrelated seems to have something to do with neocomplete. But the lack of completion for some object is still there.

Yes, thank you. Can confirm both. Will look what is the reason, and report the results.

Latest commits should fix it.

Well scanner and a lot more objects are now responding. But the first example with "list" still gives no options.

I can confirm exception completion problem, thanks.
And can you try call that completions twice or more, because sometimes server doesn't start immediatly. And if it won't work, please, can you execute command :call javacomplete#GetLogContent() and put content here. Because it works for me.

Yes, it always takes twice to start.
Here is the log after  in the the try catch block at "Inter"
JavaComplete_Home: /home/USER/.vim/bundle/vim-javacomplete2
Default sources:
Restart server
Classpath: /home/USER/.vim/bundle/vim-javacomplete2/libs/javavi/target/classes:/home/USER/.vim/bundle/vim-javacomplete2/libs/javaparser.jar:::/usr/lib/jvm/java-8-openjdk/lib/dt.jar::/usr/lib/jvm/java-8-openjdk/lib/jconsole.jar::/usr/lib/jvm/java-8-openjdk/lib/sa-jdi.jar::/usr/lib/jvm/java-8-openjdk/lib/tools.jar:/usr/lib/jvm/java-8-openjdk/lib
P1. "str".|
GetDeclaredClassName for "Thread"
F3. "Thread.|"  typename: ""
F4. "TypeName.|"
RunReflection: -E "Thread" [FetchClassInfo in Batch]
RunReflection: -E "java.lang.Thread" [FetchClassInfo in Batch]
RunReflection: -E "java.util.Thread" [FetchClassInfo in Batch]
F5. "package.|"
RunReflection: -p "Thread" [s:DoGetInfoByReflection]
P1. "str".|
GetDeclaredClassName for "Thread"
F3. "Thread.|"  typename: ""
F4. "TypeName.|"
RunReflection: -E "Thread" [FetchClassInfo in Batch]
finish completion  0.171766s
RunReflection: -P "-" [s:DoGetInfoByReflection]

Sorry, I mean logs for Sys and list completions that doesn't work for you. What about Inter I can confirm that there is an issue in catch block comletions, I'll check it later.

e37fa2e71c364f8b289f728de7462d53f4e9f0e8 should fix Inter issue.

Yeah the try/catch issue seems to be resolved! But "list" from above still doesn't respond.

So can you please show me logs exactly after you run list completion?

There is a snippet for ArrayLists d.al which I used. The dot in d.al started the server.
d.al   -->   List<Integer> list = new ArrayList<Integer>();

Then I typed list. and neocomplete wanted to complete it but it didn't work. Then I pressed  and it still didn't work.
Here is the output
JavaComplete_Home: /home/USER/.vim/bundle/vim-javacomplete2
Default sources:
Restart server
Classpath: /home/USER/.vim/bundle/vim-javacomplete2/libs/javavi/target/classes:/home/USER/.vim/bundle/vim-javacomplete2/libs/javaparser.jar:::/usr/lib/jvm/java-8-openjdk/lib/dt.jar::/usr/lib/jvm/java-8-openjdk/lib/jconsole.jar::/usr/lib/jvm/java-8-openjdk/lib/sa-jdi.jar::/usr/lib/jvm/java-8-openjdk/lib/tools.jar:/usr/lib/jvm/java-8-openjdk/lib
P1. "str".|
GetDeclaredClassName for "d"
F3. "d.|"  typename: ""
F4. "TypeName.|"
RunReflection: -E "d" [FetchClassInfo in Batch]
RunReflection: -E "java.lang.d" [FetchClassInfo in Batch]
F5. "package.|"
RunReflection: -p "d" [s:DoGetInfoByReflection]
P1. "str".|
GetDeclaredClassName for "d"
F3. "d.|"  typename: ""
F4. "TypeName.|"
RunReflection: -E "d" [FetchClassInfo in Batch]
RunReflection: -E "java.lang.d" [FetchClassInfo in Batch]
F5. "package.|"
RunReflection: -p "d" [s:DoGetInfoByReflection]
P1. "str".|
GetDeclaredClassName for "d"
F3. "d.|"  typename: ""
F4. "TypeName.|"
RunReflection: -E "d" [FetchClassInfo in Batch]
RunReflection: -E "java.lang.d" [FetchClassInfo in Batch]
F5. "package.|"
RunReflection: -p "d" [s:DoGetInfoByReflection]
P1. "str".|
GetDeclaredClassName for "list"
F3. "list.|"  typename: "List<Integer>"
RunReflection: -E "List<(Integer|java.lang.Integer)>" [FetchClassInfo in Batch]
RunReflection: -E "java.lang.List<(Integer|java.lang.Integer)>" [FetchClassInfo in Batch]
P1. "str".|
GetDeclaredClassName for "list"
F3. "list.|"  typename: "List<Integer>"
RunReflection: -E "List<(Integer|java.lang.Integer)>" [FetchClassInfo in Batch]
RunReflection: -E "java.lang.List<(Integer|java.lang.Integer)>" [FetchClassInfo in Batch]
P1. "str".|
GetDeclaredClassName for "list"
F3. "list.|"  typename: "List<Integer>"
RunReflection: -E "List<(Integer|java.lang.Integer)>" [FetchClassInfo in Batch]
RunReflection: -E "java.lang.List<(Integer|java.lang.Integer)>" [FetchClassInfo in Batch]

Hm, looks like it cannot find right package for List. Do you still have those import java.util.*; in your file?

Yes, but it also doesn't work when I import "ArrayList" and "List" specifically.

Can you, please, switch on branch issue_11 and again, run completion and show logs?

Alright this is the Log when on issue_11 branch. This time I did it a little different. I manually imported the List, ArrayList before. And then did not use the snippet "d.al" to create the ArrayList object, but typed it manually. After that I typed list. let neocomplete give me suggestions. It didn't work. Then I tried it with <C-x><C-o> to make sure it didn't work.
JavaComplete_Home: /home/USER/.vim/bundle/vim-javacomplete2
Default sources:
/usr/bin/java
  0.101430s to exec "java -XshowSettings" by Get java settings
Restart server
Classpath: /home/USER/.vim/bundle/vim-javacomplete2/libs/javavi/target/classes:/home/USER/.vim/bundle/vim-javacomplete2/libs/javaparser.jar:::/usr/lib/jvm/java-8-openjdk/jre/lib/charsets.jar::/usr/lib/jvm/java-8-openjdk/jre/lib/ext/cldrdata.jar::/usr/lib/jvm/java-8-openjdk/jre/lib/ext/dnsns.jar::/usr/lib/jvm/java-8-openjdk/jre/lib/ext/localedata.jar::/usr/lib/jvm/java-8-openjdk/jre/lib/ext/nashorn.jar::/usr/lib/jvm/java-8-openjdk/jre/lib/ext/sunec.jar::/usr/lib/jvm/java-8-openjdk/jre/lib/ext/sunjce_provider.jar::/usr/lib/jvm/java-8-openjdk/jre/lib/ext/sunpkcs11.jar::/usr/lib/jvm/java-8-openjdk/jre/lib/ext/zipfs.jar::/usr/lib/jvm/java-8-openjdk/jre/lib/jce.jar::/usr/lib/jvm/java-8-openjdk/jre/lib/jsse.jar::/usr/lib/jvm/java-8-openjdk/jre/lib/management-agent.jar::/usr/lib/jvm/java-8-openjdk/jre/lib/resources.jar::/usr/lib/jvm/java-8-openjdk/jre/lib/rt.jar::/usr/lib/jvm/java-8-openjdk/jre/lib/security/US_export_policy.jar::/usr/lib/jvm/java-8-openjdk/jre/lib/security/local_policy.jar:/usr/lib/jvm/java-8-openjdk/jre/lib
RunReflection: -p "java" [s:DoGetInfoByReflection]
RunReflection: -p "java" [s:DoGetInfoByReflection]
finish completion  0.411110s
RunReflection: -p "java.util" [s:DoGetInfoByReflection]
finish completion  0.117393s
finish completion  0.006707s
finish completion  0.020868s
P1. "str".|
GetDeclaredClassName for "list"
F3. "list.|"  typename: "List<Integer>"
import: java.util.List,1
import: java.util.ArrayList,2
direct:
import: java.util.List,1
import: java.util.ArrayList,2
star imports:
['java.lang.']
import: java.util.List,1
import: java.util.ArrayList,2
direct: java.util.List
RunReflection: -E "java.util.List<(Integer|java.lang.Integer)>" [FetchClassInfo in Batch]
P1. "str".|
GetDeclaredClassName for "list"
F3. "list.|"  typename: "List<Integer>"
import: java.util.List,1
import: java.util.ArrayList,2
direct:
import: java.util.List,1
import: java.util.ArrayList,2
star imports:
['java.lang.']
import: java.util.List,1
import: java.util.ArrayList,2
direct: java.util.List
RunReflection: -E "java.util.List<(Integer|java.lang.Integer)>" [FetchClassInfo in Batch]

Now I see that package found. And it is really strange for me that it doesn't show you completions. May it be that some other script prevent showing the results of javacomplete script? May be neocomplete?
For me I tried to reproduce your issue, I use snippet d.al, everything worked fine.

I don't think it is a script. I just deleted all of my plugins except pathogen and vim-javacomplete. And the problem persists. I don't get completions for any Collection actually.

Btw, when you last time compile javavi library? May be you have some old classes? Could you call this  function javacomplete#CompileJavavi() to force recompilation?

When I run this :call javacomplete#CompileJavavi() then I get these errors
/home/USER/.vim/bundle/vim-javacomplete2/libs/javavi/src/main/java/kg/ash/javavi/Javavi.java:205: error: cannot find symbol
                reader.setTypeArguments(typeArguments);
                      ^
  symbol:   method setTypeArguments(List<String>)
  location: variable reader of type ClassReader
/home/USER/.vim/bundle/vim-javacomplete2/libs/javavi/src/main/java/kg/ash/javavi/Javavi.java:221: error: constructor PackagesSearcher in class PackagesSearcher cannot be applied to given types;
                new PackagesSearcher(sources).collectPackages(cachedPackages, cachedClassPackages);
                ^
  required: String,String
  found: String
  reason: actual and formal argument lists differ in length
/home/USER/.vim/bundle/vim-javacomplete2/libs/javavi/src/main/java/kg/ash/javavi/Javavi.java:227: error: constructor PackagesSearcher in class PackagesSearcher cannot be applied to given types;
                new PackagesSearcher(sources).collectPackages(cachedPackages, cachedClassPackages);
                ^
  required: String,String
  found: String
  reason: actual and formal argument lists differ in length
/home/USER/.vim/bundle/vim-javacomplete2/libs/javavi/src/main/java/kg/ash/javavi/Javavi.java:233: error: constructor PackagesSearcher in class PackagesSearcher cannot be applied to given types;
                new PackagesSearcher(sources).collectPackages(cachedPackages, cachedClassPackages);
                ^
  required: String,String
  found: String
  reason: actual and formal argument lists differ in length
4 errors

Hm, can you completely remove vim-javacomplete2 directory. And then pull it again?

I just deleted the folder and cloned the master branch. Now it works :)

Ou, fine :smile:
Thanks.

authors: artur-shaik wxxn

license: Vim


text:
refactor: scanner

Scanner 的流程为

scanEnvList
scanManifestByEnv

获取应用配置的所有框架层级路径并完成扫描
此时插件是全量的，继续按照原插件处理逻辑加载框架和应用配置的所有插件
最后完成应用目录自身文件的扫描

将 walk 的逻辑独立出来
getItemsFromMap 里面恢复覆盖顺序完成的状态，无需再次按照 framework, plugin, app 的顺序过滤再合并

注意：此 PR 旨在局部重构 Scanner 逻辑，API 完全兼容之前逻辑，不会 break 原有流程

cc @noahziheng

@noahziheng 已经修改了，有空再看下

repo: artusjs/core


text:
Problems to get/play RTMP stream

Hi
Got a problem when trying to get a RTMP stream, this problem dosen't happend when I use just 1 worker, but with more workers I got the problem randomly, when I add a lot of workers, the problem happens almost always.
The ingest is ok, is sending without issue, when I resend the stream to the server, clients start to reproduce the stream.
I have the version tag 1.9.1 compiled with the ubuntu source of the package 1.6.2 and 1.10.0 with the same results.
If you need some more info or data, just ask for it.
Cheers, have a good day.
Here some log from VLC debug
[00000000016b5088] core libvlc debug: art not found for rtmp://dev-ngx-rtmp.ned.lan:1935/live/stream
HandShake: Type Answer   : 03
HandShake: Server Uptime : 198961556
HandShake: FMS Version   : 0.0.0.0
HandShake: Handshaking finished....
RTMP_Connect1, handshaked
RTMP_SendPacket: fd=29, size=181
  0000:  03 00 00 00 00 00 b5 14  00 00 00 00               ............
  0000:  02 00 07 63 6f 6e 6e 65  63 74 00 3f f0 00 00 00   ...connect.?....
  0010:  00 00 00 03 00 03 61 70  70 02 00 04 6c 69 76 65   ......app...live
  0020:  00 05 74 63 55 72 6c 02  00 25 72 74 6d 70 3a 2f   ..tcUrl..%rtmp:/
  0030:  2f 64 65 76 2d 6e 67 78  2d 72 74 6d 70 2e 6e 65   /dev-ngx-rtmp.ne
  0040:  64 2e 6c 61 6e 3a 31 39  33 35 2f 6c 69 76 65 00   d.lan:1935/live.
  0050:  04 66 70 61 64 01 00 00  0c 63 61 70 61 62 69 6c   .fpad....capabil
  0060:  69 74 69 65 73 00 40 2e  00 00 00 00 00 00 00 0b   ities.@.........
  0070:  61 75 64 69 6f 43 6f 64  65 63 73 00 40 a8 ee 00   audioCodecs.@...
  0000:  c3                                                 .
  0000:  00 00 00 00 00 0b 76 69  64 65 6f 43 6f 64 65 63   ......videoCodec
  0010:  73 00 40 6f 80 00 00 00  00 00 00 0d 76 69 64 65   s.@o........vide
  0020:  6f 46 75 6e 63 74 69 6f  6e 00 3f f0 00 00 00 00   oFunction.?.....
  0030:  00 00 00 00 09                                     .....
Invoking connect
RTMP_ReadPacket: fd=29
  0000:  02 00 00 00 00 00 04 05  00 00 00 00               ............
  0000:  00 4c 4b 40                                        .LK@
HandleServerBW: server BW = 5000000
RTMP_ReadPacket: fd=29
  0000:  02 00 00 00 00 00 05 06  00 00 00 00               ............
  0000:  00 4c 4b 40 02                                     .LK@.
HandleClientBW: client BW = 5000000 2
RTMP_ReadPacket: fd=29
  0000:  02 00 00 00 00 00 04 01  00 00 00 00               ............
  0000:  00 00 10 00                                        ....
HandleChangeChunkSize, received: chunk size change to 4096
RTMP_ReadPacket: fd=29
  0000:  03 00 00 00 00 00 be 14  00 00 00 00               ............
  0000:  02 00 07 5f 72 65 73 75  6c 74 00 3f f0 00 00 00   ..._result.?....
  0010:  00 00 00 03 00 06 66 6d  73 56 65 72 02 00 0d 46   ......fmsVer...F
  0020:  4d 53 2f 33 2c 30 2c 31  2c 31 32 33 00 0c 63 61   MS/3,0,1,123..ca
  0030:  70 61 62 69 6c 69 74 69  65 73 00 40 3f 00 00 00   pabilities.@?...
  0040:  00 00 00 00 00 09 03 00  05 6c 65 76 65 6c 02 00   .........level..
  0050:  06 73 74 61 74 75 73 00  04 63 6f 64 65 02 00 1d   .status..code...
  0060:  4e 65 74 43 6f 6e 6e 65  63 74 69 6f 6e 2e 43 6f   NetConnection.Co
  0070:  6e 6e 65 63 74 2e 53 75  63 63 65 73 73 00 0b 64   nnect.Success..d
  0080:  65 73 63 72 69 70 74 69  6f 6e 02 00 15 43 6f 6e   escription...Con
  0090:  6e 65 63 74 69 6f 6e 20  73 75 63 63 65 65 64 65   nection succeede
  00a0:  64 2e 00 0e 6f 62 6a 65  63 74 45 6e 63 6f 64 69   d...objectEncodi
  00b0:  6e 67 00 00 00 00 00 00  00 00 00 00 00 09         ng............
RTMP_ClientPacket, received: invoke 190 bytes
(object begin)
Property: <Name:           no-name., STRING:	_result>
Property: <Name:           no-name., NUMBER:	1,00>
Property: <Name:           no-name., OBJECT>
(object begin)
Property: <Name:             fmsVer, STRING:	FMS/3,0,1,123>
Property: <Name:       capabilities, NUMBER:	31,00>
(object end)
Property: <Name:           no-name., OBJECT>
(object begin)
Property: <Name:              level, STRING:	status>
Property: <Name:               code, STRING:	NetConnection.Connect.Success>
Property: <Name:        description, STRING:	Connection succeeded.>
Property: <Name:     objectEncoding, NUMBER:	0,00>
(object end)
(object end)
HandleInvoke, server invoking <_result>
HandleInvoke, received result for method call <connect>
RTMP_SendPacket: fd=29, size=4
  0000:  02 00 00 00 00 00 04 05  00 00 00 00               ............
  0000:  00 4c 4b 40                                        .LK@
sending ctrl. type: 0x0003
RTMP_SendPacket: fd=29, size=10
  0000:  42 00 00 00 00 00 0a 04                            B.......
  0000:  00 03 00 00 00 00 00 00  01 2c                     .........,
RTMP_SendPacket: fd=29, size=25
  0000:  43 00 00 00 00 00 19 14                            C.......
  0000:  02 00 0c 63 72 65 61 74  65 53 74 72 65 61 6d 00   ...createStream.
  0010:  40 00 00 00 00 00 00 00  05                        @........
Invoking createStream
RTMP_ReadPacket: fd=29
  0000:  03 00 00 00 00 00 1d 14  00 00 00 00               ............
  0000:  02 00 07 5f 72 65 73 75  6c 74 00 40 00 00 00 00   ..._result.@....
  0010:  00 00 00 05 00 3f f0 00  00 00 00 00 00            .....?.......
RTMP_ClientPacket, received: invoke 29 bytes
(object begin)
Property: <Name:           no-name., STRING:	_result>
Property: <Name:           no-name., NUMBER:	2,00>
Property: NULL
Property: <Name:           no-name., NUMBER:	1,00>
(object end)
HandleInvoke, server invoking <_result>
HandleInvoke, received result for method call <createStream>
SendPlay, seekTime=0, stopTime=0, sending play: stream
RTMP_SendPacket: fd=29, size=35
  0000:  08 00 00 00 00 00 23 14  01 00 00 00               ......#.....
  0000:  02 00 04 70 6c 61 79 00  40 08 00 00 00 00 00 00   ...play.@.......
  0010:  05 02 00 06 73 74 72 65  61 6d 00 00 00 00 00 00   ....stream......
  0020:  00 00 00                                           ...
Invoking play
sending ctrl. type: 0x0003
RTMP_SendPacket: fd=29, size=10
  0000:  c2                                                 .
  0000:  00 03 00 00 00 01 00 00  0b b8                     ..........
RTMP_ReadPacket: fd=29
  0000:  05 00 00 00 00 00 60 14  01 00 00 00               ......`.....
  0000:  02 00 08 6f 6e 53 74 61  74 75 73 00 00 00 00 00   ...onStatus.....
  0010:  00 00 00 00 05 03 00 05  6c 65 76 65 6c 02 00 06   ........level...
  0020:  73 74 61 74 75 73 00 04  63 6f 64 65 02 00 14 4e   status..code...N
  0030:  65 74 53 74 72 65 61 6d  2e 50 6c 61 79 2e 53 74   etStream.Play.St
  0040:  61 72 74 00 0b 64 65 73  63 72 69 70 74 69 6f 6e   art..description
  0050:  02 00 0a 53 74 61 72 74  20 6c 69 76 65 00 00 09   ...Start live...
RTMP_ClientPacket, received: invoke 96 bytes
(object begin)
Property: <Name:           no-name., STRING:	onStatus>
Property: <Name:           no-name., NUMBER:	0,00>
Property: NULL
Property: <Name:           no-name., OBJECT>
(object begin)
Property: <Name:              level, STRING:	status>
Property: <Name:               code, STRING:	NetStream.Play.Start>
Property: <Name:        description, STRING:	Start live>
(object end)
(object end)
HandleInvoke, server invoking <onStatus>
HandleInvoke, onStatus: NetStream.Play.Start
[00007fb1f4000e88] avio access debug: not seekable, size=-38
[00007fb1f4000e88] core access debug: using access module "avio"
[00007fb1f401acd8] core stream debug: Using stream method for AStream*
[00007fb1f401acd8] core stream debug: starting pre-buffering
RTMP_ReadPacket: fd=29
  0000:  05 00 00 00 00 00 18 12  01 00 00 00               ............
  0000:  02 00 11 7c 52 74 6d 70  53 61 6d 70 6c 65 41 63   ...|RtmpSampleAc
  0010:  63 65 73 73 01 01 01 01                            cess....
RTMP_ClientPacket, received: notify 24 bytes
(object begin)
Property: <Name:           no-name., STRING:	|RtmpSampleAccess>
Property: <Name:           no-name., BOOLEAN:	TRUE>
Property: <Name:           no-name., BOOLEAN:	TRUE>
(object end)
RTMP_ReadPacket: fd=29
RTMPSockBuf_Fill, recv returned -1. GetSockError(): 11 (Resource temporarily unavailable)
RTMP_ReadPacket, failed to read RTMP packet header
[00007fb1f401acd8] core stream error: cannot pre fill buffer
[00007fb1f4000e88] core access debug: removing module "avio"
[AVIOContext @ 0x7fb1f401ab20] Statistics: 0 bytes read, 0 seeks
RTMP_SendPacket: fd=29, size=34
  0000:  43 00 00 00 00 00 22 14                            C.....".
  0000:  02 00 0c 64 65 6c 65 74  65 53 74 72 65 61 6d 00   ...deleteStream.
  0010:  40 10 00 00 00 00 00 00  05 00 3f f0 00 00 00 00   @.........?.....
  0020:  00 00                                              ..
Invoking deleteStream
[00007fb2000009b8] core input warning: cannot create a stream_t from access

I just read the multi worker reference and see how solve this, sorry

repo: arut/nginx-rtmp-module


text:
Snapshot working copy state

Currently, if you run git amend and merge the working copy changes into the currently-checked-out commit, there is no easy way to undo that operation and restore your changes to the working copy. git undo also has the problem that there's no good way to preserve your working copy changes, even by committing them!, because then git undo will immediately undo that commit. You also can't undo back into a previous merge-conflict resolution that you were doing.
I think the best way to handle this problem is to lean into jj's approach of unifying the working copy and commits to some degree. Before carrying out an amend, we should make a synthetic commit which contains the working copy state. In the event of staged changes, I imagine including trailers like this, which indicate the commit contents according to the base commit + changes in that stage:
Branchless-stage-1: abc123
Branchless-stage-2: def456
Branchless-stage-3: ghi789

To handle applying the working copy state, we can do one or more of the following:

Count on the user to notice and work around working-copy-state commits. They're responsible for unapplying a working copy commit themselves. (We would want an uncommit command to help with that, as per https://github.com/arxanas/git-branchless/discussions/48).
When using git branchless checkout, if the target appears to be a working copy commit, after checking it out, immediately uncommit it.

Similarly, when running git branchless checkout to go to a different commit, it should automatically "stash" the current changes in a working copy commit. If --merge was passed, it should then attempt to apply it to the target commit.

As part of the post-checkout hook, if the current commit is a working copy commit, immediately uncommit it, or at least warn the user that they might want to uncommit it themselves.

We could also surface the working copy commits differently in the smartlog (including displaying if it's in a conflicted state).

This is implemented in #382. However, the user doesn't directly appear in the smartlog. If the user really wants to manipulate snapshots, then they can use git branchless snapshot create and git branchless snapshot restore.

repo: arxanas/git-branchless


text:
Any planned integration with Atria

First and foremost, fantastic work here and your ICFP paper was a nice read.
I was curious if you have given any thought to your previous work on Atria and building additional capabilities (or even compatibility) with immer.

Hi Paul!
Tthanks a lot for the compliments, that's very encouraging!
And, yeah, I have given it a thought to the Atria question---in some way, this project is just a "follow up" on that one...  The two clearest ways of potential interaction are:

Transducers. Basically, overloading Atria's reduce using immer::for_each_chunk_p for very efficient transformations of immutable sequences. There is the open question of doing buffered lazy transformations a-la Clojure, which I think might fit somewhere at the intersection of the two libraries.

There is this module in Atria called funken, which we never really talked about [1] but is maybe one of the most interesting modules there. The goal of that library is to fill the impedance mismatch between immutable data in the "single atom" architecture and imperative subsystems that consume or update the data (e.g. traditional UIs with frameworks like Qt). This library was indeed conceptually conceived when we were building that library, because without efficient immutable data-structures it is hard to scale apps written with those tools.

Now, what will actually happen in that direction? I personally doubt that much will happen inside Atria itself. My involvement with it is in "maintenance mode", there is noone inside Ableton developing features for it, and there are almost no active users that I know of [2].
In the mid-term I would like to extract the transducers module as a separate library so it is easier to consume and better documented. Also a good chance to reimplement it exploring different approaches [3]. This might happen within the a year from now or so---I want to do the associative containers for immer first, so it depends on how long that takes.
I would like to build a new library in the direction of Funken too, but I am not sure I would just take the atria::funken API "as-is". Over the last couple of years I have been quite inspired by Reagent and would like to achieve something with some syntactic similarities, but adapted to the problems we have in the C++ world. I have lots of ideas of what that could entail, but I am afraid of turning it into vaporware if I talk too much about them already 😄  Some of the fundamentals in Funken might be useful to implement that---they are a bit like reactive cursors---but this needs more research...  I hope I can find some generous sponsors to be able to tackle this problem with all the focus it deserves.
Anyways...and sorry for the long response---I think I just used this as a brain-dump 💩. I must admit it also made me super excited to see that some Cognitec people are following this project. Is Cognitec exploring things in the native/systems technologies world?

[1] (@brentshields did a talk once at Ableton about a Clojure implementation he made first, not sure if that was ever recorded there. The C++ version has significant conceptual differences.
[2] Someone from Ableton told me recently they are using the match() module, but admittedly the recent work on variant deconstruction from @SuperV1234 is more complete in almost every sense (excepting deducing a ?:-operator-like common type for the result of the expression, which is on the other hand kind of a niche feature).
[3] C++14 minimum requirement, plus change some of the details of how the state wrapping process works...

Hi @ohpauleez, should I close the issue?

Hi @arximboldi - thanks for the detailed/thoughtful response and checking in!
You can do whatever you like with the issue :)  I mostly wanted you to know that you have a fan and that I care to see the vision/story evolve.

authors: arximboldi ohpauleez

repo: arximboldi/immer


text:
add noise to phenotypes

so we can control the variance in generate_phenotypes.py
you can sample from a gaussian for this

closed in befee5a857f950b86eaaf9541aaaa6c2d0c8cafb


text:
Support for custom factory methods

In this particular situation I need to map an array to a nested object.
From
{p:[3,4]}
To
X
_p
__a
__b

The Jackson Java library supports custom factory methods, e.g., through the @JsonCreator annotation, that allow me to realize such a mapping in the following way. Jackson then searches for a suitable factory method whenever it has to map int[] to P. Support for some sort of factory methods would be a powerful feature.
public class X {
    @JsonProperty("p")
    private P p;
}

public class P {
    private int a;
    private int b;

    public P(int a, int b) {
        this.a= a;
        this.b= b;
    }

    @JsonCreator
    public static P fromValue(int[] array) {
        return new P(array[0], array[1]);
    }
}

Good Idea, will add this as a feature. Can you confirm that below is the type of feature you were talking about?
[mappingProvider mapFromKey:@"country" toProperty:@"country" withTransformer:^(id countryString) {
    Country *country = [[Country alloc] init];
    return country;
]};

The difference between the Java example and your suggestion is that you are specifiying the mapping configuration through the parent object (User in this case) instead of the object itself (Country). Therefore one would have to repeat the configuration for other Objects with a country property (say, Business). However, I believe that your approach is consistent with the existing mapping provider API and I am not going to complain about this solution :)

oh and will you pass in the primitive type (int, array, string, ...) into the transformer or only the raw string? or will users be able to change the header of the transformer function according to what the json is expected to look like? e.g:
[mappingProvider mapFromKey:@"country" toProperty:@"country" forClass:[User class] withTransformer:^(NSArray* a) {
    Country *country = [[Country alloc] initWithX:a[0] andY:a[1]];
    return country;
]};

No transformer would take whatever is in the dictionary for the given key, so it could be anything (string, number, array, dictionary)

Feature is implemented in a separate branch and docs are updated. Will do more testing and merge into master

authors: aryaxt laenger

repo: aryaxt/OCMapper


text:
viewDidappear is just called once

Hi
There's a way to change the content of the SlidenavigationController each time you open it?
I'm trying change the content in viewDidAppear but this method is just called one time
Thank you

That's expected because menu is no inside a UINavigationController, and it's not the root either.
Use one of the notifications: https://github.com/aryaxt/iOS-Slide-Menu#notifications

repo: aryaxt/iOS-Slide-Menu


text:
Update scalafmt-core to 3.1.2

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

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

labels: library-update, early-semver-major, semver-spec-major

Superseded by #69.

repo: asakaev/leftpad


text:
Extra blank line inserted above index item if item is forced to break

If an item in the index is forced to break, the converter adds an extra blank line above the item.
For example:
flags

    FLAG_THAT_IS_SO_LONG_IT_MUST_BE
    _BROKEN

It should appear as:
flags
  FLAG_THAT_IS_SO_LONG_IT_MUST_BE
    _BROKEN

The solution for now is to eliminate the line height normalization for index terms. But the cause of the problem (line height normalization) will show up elsewhere and still needs to be addressed in those places.

repo: asciidoctor/asciidoctor-pdf


text:
checkVersion Task fails for 4-digit version numbers

When trying to build a release with a 4-digit version number like 1.5.4.1 the check version task fails with an exception:
* Where:
Script '/Users/robertpanzer/dev/asciidoctorj/gradle/versioncheck.gradle' line: 40

* What went wrong:
Execution failed for task ':asciidoctorj:checkVersion'.
> com.github.zafarkhaja.semver.UnexpectedCharacterException (no error message)

The java-semver library throws an exception if a version does not match the criteria of a semantic version. A 4 digit number is not valid. I actually don't know how maven handles this situation internally.
But it really doesn't matter in this situation.
I'll catch the exception and log a warning. PR follows...

👍 For now I simply skipped the task.

Hmm...maybe the tasks should be more isolated. At present the check task depends on checkVersion.
If something goes wrong in case of an exception the whole build will fail.
The tasks should be a helper not a blocker. I suggest to remove the task dependency.

authors: ancho robertpanzer

repo: asciidoctor/asciidoctorj


text:
feat(other-parts):  その他の高度なAPI

思ってたよりECMAScriptの章と被った感じなので、最悪省いても大丈夫そう。
fix #348

Deploy preview for js-primer ready!
Built with commit 0a137d23e8314b4276d8eee5d18278038d71a9c8
https://deploy-preview-549--js-primer.netlify.com

authors: azu bot-user

repo: asciidwango/js-primer


text:
Fix yaourt install line (cannot be run as root)

Running yaourt as root eventually errors out with "Running makepkg as
root is not allowed as it can cause permanent, catastrophic damage to
your system."

Thanks!

authors: JohnMaguire sickill


text:
Correct examples - thanks to @cjauvin

thanks @cjauvin

[Current coverage][cc-pull] is 100%

Merging [#72][cc-pull] into [master][cc-base-branch] will not change coverage

@@           master   #72   diff @@
===================================
  Files           7     7
  Lines         325   325
  Methods         0     0
  Messages        0     0
  Branches        0     0
===================================
  Hits          325   325
  Misses          0     0
  Partials        0     0

Powered by Codecov. Last updated by [a3872ab...cbb72bf][cc-compare]
[cc-base-branch]: https://codecov.io/gh/ascribe/transactions/branch/master?src=pr
[cc-compare]: https://codecov.io/gh/ascribe/transactions/compare/a3872ab3485adcc488608b15f4b1816005a77e41...cbb72bf57ffc27868dd85a761aad71538eae368a
[cc-pull]: https://codecov.io/gh/ascribe/transactions/pull/72?src=pr

authors: codecov-io sbellem

repo: ascribe/transactions


text:
Publish Android Archive Library (.aar) file with Github Actions

Now that we push Android loadable libraries, we should bundle them together and publish .aar files for Android devs.

SQLite's as inspiration: https://www.sqlite.org/2024/sqlite-android-3460100.aar
op-sqlite inspiro: https://github.com/OP-Engineering/op-sqlite/tree/main/android/src/main

Great


text:
How to perform 3D touch on collectionViews inside of TableViewCells

Hello,
Just a quick question, i'm trying to perform the "peek" and "pop" functionality and have setup my tableview and embedded collectionView per your tutorial.  Any pointers on how to best assemble the code in order to "peek" and preview the collectionView cell?  I've seen a ton of tutorials but they all cover tableview Or collection view only.  Thanks!

Good question! I'm not sure, I've never used those apis. When you figure it out can you let us know?

Will do!


text:
.NET 8.0 CI compatibility

Hi, we're just upgrading our .NET projects to 8.0 and while EphemeralMongo tests still work locally, in the CI pipeline which uses mcr.microsoft.com/dotnet/sdk:8.0 image, it fails with the following error:
Error Message:
#18 69.43    System.TimeoutException : MongoDB connection availability took longer than the specified timeout of 30 seconds. Consider increasing the value of 'ConnectionTimeout'.
#18 69.43   Stack Trace:
#18 69.43      at EphemeralMongo.MongodProcess.StartAndWaitForConnectionReadiness()
#18 69.43    at EphemeralMongo.MongodProcess.Start()
#18 69.43    at EphemeralMongo.MongoRunner.RunInternal()
#18 69.43    at EphemeralMongo.MongoRunner.Run(MongoRunnerOptions options)

Any thoughts on why that could be happening when it worked without issues with .NET 7.0?

After doing some more digging, I found that mongod requires libssl1.1 which is no longer available in dotnet sdk 8.0 image because it has been upgraded to Debian 12 (Bookworm)

Just wanted to say a big thank you @vypsim as I spent about a miserable few hours on this today and I would never have fixed it without your insight.

Hi,
If you don't want to install the libssl1.1 maybe you want to use the  EphemeralMongo7.runtime.ubuntu.22.04-x64 package.
But looks like there's an issue in this package that throws a System.IO.FileNotFoundException : Could not find mongod in the following paths: '/runtimes/linux-x64/native/mongodb/bin/mongod'**
I posted a simple workaround to this issue here:

This is what helped me for now https://github.com/Mongo2Go/Mongo2Go/issues/149#issuecomment-1863137835

This is a duplicate of https://github.com/asimmon/ephemeral-mongo/issues/36

There is currently also the following issue when trying to use the current workaround on > .NET 8 SDK:
warning NETSDK1206: Found version-specific or distribution-specific runtime identifier(s): ubuntu.22.04-x64. Affected libraries: EphemeralMongo7.runtime.ubuntu.22.04-x64. In .NET 8.0 and higher, assets for version-specific and distribution-specific runtime identifiers will not be found by default. See https://aka.ms/dotnet/rid-usage for details.

Ref: https://learn.microsoft.com/en-us/dotnet/core/tools/sdk-errors/netsdk1206
This was already mentionen in this Issue: https://github.com/asimmon/ephemeral-mongo/issues/56

authors: 616b2f TruffleMuffin einsteine89 slonopotamus vypsim wcgomes

repo: asimmon/ephemeral-mongo


text:
add vae-gru and repo cleanup v2

add new architectures
Create no-teacher-0.pt
add better loss function
add teacher forcing to _v2 and _v3
add image logging to wandb
minor image logging fix
minor fix v2
add better loss function to training
fix loss function in evaluate
gru_v3_improvement
Slight change
.
Update gru_v2.py
fix teacher forcing
fix evaluate
fix teacher forcing again
minor fix
fix teacher forcing (once again)
Update GRU_MI.ipynb
Create v2_w-teacher-0
Update GRU_MI.ipynb
add smiles enumeration
minor fix
review dataset
quick fiq
minor fix
Create v3_w-teacher-w-enumeration-0
Update GRU-smiles-enumerator.ipynb
Create results_visualisation.ipynb
move alphabet outside the notebook
Update chembl_prep.ipynb
Update chembl_prep.ipynb
Update chembl_prep.ipynb
Update .gitignore
Update .gitignore
move old data files elsewhere
delete old datasets
add scaffold split
minor fix
rename
Update .gitignore
add train and test to .parquet
minor fix
Update results_visualisation.ipynb
Exceptions added
add exception handling
add auto parameters saving
add mkdir for each new model
minor fix
Update example_printer.py
fix example printer
minor fix in example printer
fix whatever was wrong with train
minor fix
minor fix
wahtever at this point
GRU_v4
Example Printer fix & New Architecture
fix vectorization
fix interactive mol view
add fragments visualisation
add comments
add Highlighter
add manual
fix Highlighter class
add multiple molecules generation
add shell script
fix script
Delete enviroment.yml
move
Create enviroment.yml
Update train_gru.ssh
Update train_gru.ssh
Update train_gru.ssh
Update train_gru.ssh
update script
Update train_gru.ssh
Update train_gru.ssh
Update train_gru.py
change wandb login
update train script
update train script
Update train_gru.py
CVAE->VAE
Update train_gru.py
Update train_gru.py
Update train_gru.py
Update train_gru.py
Update train_gru.py
Update train_gru.ssh
comment out wandb commands
Update train_gru.py
Update train_gru.py
Update train_gru.py
Update train_gru.py
rename classes and modules
add validation
remove useless code
fix dataset path
quick fix
prepare training script
change gru num_workers
Update train_gru.py
Update train_vae.py
Update train_vae.py
prepare for sweep
Update train_vae.py
quick fix
prepare run
add vae+gru architecture
add vae and gru model
prepare for run
quick fix
prepare for run
Compounds Filter
remove old notebooks
add ring size control
remove ring control
Update results_visualisation.ipynb
Update vae_gru.py
Filter update
Filter update
Update .gitignore
add trained models
add fp sampler
name change
prepare for run
fix cross-entropy
prepare for training
whoooop
repo cleanup
repo cleanup
Update results_visualisation.ipynb
fix val

buggy


text:
🛑 Root is down

In 9bf833e, Root (https://asm0dey.ru) was down:

HTTP code: 0
Response time: 0 ms

Resolved: Root is back up in 8ba7d3d.


text:
Makes RN window key window to handle events

Platform: iOS
With this commit React Native UI application window is set as key window after Unity initialization.
This solves the following issues:

After Unity is initialized, alerts not showing up because of "window not in hierarchy" error. The alerts are meant to be handled in RN window, but since Unity becomes the key window in the hierarchy, the error happens.

Events like focusing keyboard which are supposed to be handled in RN are instead sent to Unity as key window which creates bugs

@asmadsen Can you please check this out?

repo: asmadsen/react-native-unity-view


text:
Character literal syntax

Discussing with Andy, the existing syntax is !c for the character literal 'c' (if this were C++).
(seen in live code in https://github.com/perimosocordiae/advent-of-code/blob/9de86a79aeb5213539dd71647ab0c6abc51db13f/advent2021/day06.ic#L12)
Some possible alternatives:

!x (current)
!'x'
|x
|x|, | | (space char, i.e. ' ')
\x``
%c{x}
Of course, this works today: "a"[0]
So you could do this: "a"'as_char or as_char("a") (as_char or to_char)
For array: to_char_array("abc")

Andy notes that for something like %c{x}, you're burning a unary operator, % without a great reason. And you could just write it as char("x")

Purely going with gut feelings here, I like !'x' the best. The leading ! makes the parse unambiguous, allowing us to reuse ' without losing it's meaning for function calls.
I don't see significant value in supporting array versions, given that "abc" is already a slice of characters.

Why add single quotes at all? The !x syntax was strange at first but I've gotten used to it. The only major issue is !  IMO, but that's not too different from other languages that have \  syntax for escaped spaces.

authors: asoffer perimosocordiae wrhall

repo: asoffer/Icarus


text:
chore: fix rules_lint in non-bzlmod

Changes are visible to end-users: no
Test plan

Covered by existing test cases

Reverting instead for now https://github.com/aspect-build/rules_js/pull/1831


text:
[Bug]: [AssertionError]: Failure: Invalid byte length!

What happened?
Just got this on our CI - first time I've seen it:
Worker process did not return a WorkResponse:
---8<---8<--- Start of log snippet, file at /root/bazel/762abfc380be15f4878bfa091fdda4af/bazel-workers/worker-8-TsProject.log ---8<---8<---
[... truncated ...]
oog.asserts.DEFAULT_ERROR_HANDLER=function(a){throw a;};goog.asserts.errorHandler_=goog.asserts.DEFAULT_ERROR_HANDLER;

Error [AssertionError]: Failure: Invalid byte length!
    at new goog.asserts.AssertionError (/root/bazel/762abfc380be15f4878bfa091fdda4af/execroot/web/bazel-out/k8-opt-exec-2B5CBBC6-ST-887e3c1d132f/bin/external/npm_typescript/tsc_worker.sh.runfiles/npm_typescript/node_modules/.aspect_rules_js/google-protobuf@3.20.1/node_modules/google-protobuf/google-protobuf.js:87:1065)
    at Object.goog.asserts.fail (/root/bazel/762abfc380be15f4878bfa091fdda4af/execroot/web/bazel-out/k8-opt-exec-2B5CBBC6-ST-887e3c1d132f/bin/external/npm_typescript/tsc_worker.sh.runfiles/npm_typescript/node_modules/.aspect_rules_js/google-protobuf@3.20.1/node_modules/google-protobuf/google-protobuf.js:90:89)
    at jspb.BinaryDecoder.readBytes (/root/bazel/762abfc380be15f4878bfa091fdda4af/execroot/web/bazel-out/k8-opt-exec-2B5CBBC6-ST-887e3c1d132f/bin/external/npm_typescript/tsc_worker.sh.runfiles/npm_typescript/node_modules/.aspect_rules_js/google-protobuf@3.20.1/node_modules/google-protobuf/google-protobuf.js:369:276)
    at jspb.BinaryReader.readBytes (/root/bazel/762abfc380be15f4878bfa091fdda4af/execroot/web/bazel-out/k8-opt-exec-2B5CBBC6-ST-887e3c1d132f/bin/external/npm_typescript/tsc_worker.sh.runfiles/npm_typescript/node_modules/.aspect_rules_js/google-protobuf@3.20.1/node_modules/google-protobuf/google-protobuf.js:395:405)
    at Function.deserialize (/root/bazel/762abfc380be15f4878bfa091fdda4af/execroot/web/bazel-out/k8-opt-exec-2B5CBBC6-ST-887e3c1d132f/bin/external/npm_typescript/tsc_worker.sh.runfiles/npm_typescript/node_modules/.aspect_rules_js/@bazel+worker@5.4.2/node_modules/@bazel/worker/src/worker_protocol.js:70:53)
    at /root/bazel/762abfc380be15f4878bfa091fdda4af/execroot/web/bazel-out/k8-opt-exec-2B5CBBC6-ST-887e3c1d132f/bin/external/npm_typescript/tsc_worker.sh.runfiles/npm_typescript/node_modules/.aspect_rules_js/@bazel+worker@5.4.2/node_modules/@bazel/worker/src/worker_protocol.js:181:127
    at jspb.BinaryReader.readMessage (/root/bazel/762abfc380be15f4878bfa091fdda4af/execroot/web/bazel-out/k8-opt-exec-2B5CBBC6-ST-887e3c1d132f/bin/external/npm_typescript/tsc_worker.sh.runfiles/npm_typescript/node_modules/.aspect_rules_js/google-protobuf@3.20.1/node_modules/google-protobuf/google-protobuf.js:385:329)
    at Function.deserialize (/root/bazel/762abfc380be15f4878bfa091fdda4af/execroot/web/bazel-out/k8-opt-exec-2B5CBBC6-ST-887e3c1d132f/bin/external/npm_typescript/tsc_worker.sh.runfiles/npm_typescript/node_modules/.aspect_rules_js/@bazel+worker@5.4.2/node_modules/@bazel/worker/src/worker_protocol.js:181:36)
    at Object.<anonymous> (/root/bazel/762abfc380be15f4878bfa091fdda4af/execroot/web/bazel-out/k8-opt-exec-2B5CBBC6-ST-887e3c1d132f/bin/external/npm_typescript/tsc_worker.sh.runfiles/npm_typescript/node_modules/.aspect_rules_js/@bazel+worker@5.4.2/node_modules/@bazel/worker/src/worker.js:96:73)
    at Generator.next (<anonymous>) {
  reportErrorToServer: true,
  messagePattern: 'Failure: Invalid byte length!'
}
---8<---8<--- End of log snippet, 1555 chars omitted ---8<---8<---

Version
Development (host) and target OS/architectures:
Ubuntu, amd 64
Output of bazel --version:
c07d97b61c35a08460cb7c2ebf7851bc68787ad7 (6 pre from a few weeks ago - unsure of the version number)
Version of the Aspect rules, or other relevant rules from your
WORKSPACE or MODULE.bazel file:
rules_ts-1.0.0-rc5
Language(s) and/or frameworks involved:
How to reproduce
I don't know yet.

Any other information?
No response
Fund our work

[ ] Sponsor our open source work by donating a bug bounty

the stack trace is helpful here but this is the first time I am seeing this. Probably something in bazel worker protocol has changed. I'll investigate

@matthewjh neither i was able to reproduce this or see it happen anywhere else.  do you still see this issue happening?

We don't have the resources to maintain the persistent worker code, and we're turning it off by default in 2.0. Closing as infeasible.

authors: alexeagle matthewjh thesayyn


text:
Provide Guidance on when to turn on EnableForHttps for Response Compression

The current docs state:
> Compressed responses over secure connections can be controlled with the EnableForHttps option, which is disabled by default. Using compression with dynamically generated pages can lead to security problems such as the CRIME and BREACH attacks.
I think there are occasions when it is permissable to turn this flag on i.e. when the content of any requests or responses contain no secrets. An example might be a public API about star wars characters.

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

ID: 9795b92f-db24-8f1f-88c0-c36666d3526f
Version Independent ID: 2d56d9b6-3d7b-0204-6c08-8e584fccecc2
Content: Response compression in ASP.NET Core
Content Source: aspnetcore/performance/response-compression.md
Product: aspnet-core
GitHub Login: @guardrex
Microsoft Alias: riande

@blowdart

The text doesn't say not to use it ... just warns about the risk of doing so.

The text is accurate, and fine as is and we're not about to hedge our bets around security statements.

I have to agree with @RehanSaeed and I suggest re-opening this issue. Adding more guidance would help people make an informed decision about when Microsoft recommends using response compression with HTTPS.

authors: APIWT RehanSaeed blowdart guardrex


text:
Missing step

Before creating a new Visual Studio project, Preview version of the SDK need to be enabled in Visual Studio.
Tools -> Options and search for .NET Core you'll see a checkbox that says "Use previews of the .NET Core SDK".

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

ID: dbdcc295-2262-311c-99d4-7ece67c5f6ed
Version Independent ID: 20152398-0971-0302-21f8-b17308f02183
Content: Get started with Blazor
Content Source: aspnetcore/client-side/spa/blazor/get-started.md
Product: aspnet-core
Technology: aspnetcore-blazor
GitHub Login: @guardrex
Microsoft Alias: riande

It's Step 2 in the list.

authors: dawidgrey guardrex


text:
Inconsistency between ApiBehaviorOptions.ClientErrorMapping and ReasonPhrases.GetReasonPhrase() using 500

Asp.net Core 3.0
Windows 10
vs 2019 16.3.7
There was a new 500 status code added to ClientErrorMapping as seen at https://github.com/aspnet/AspNetCore/blob/2e4274cb67c049055e321c18cc9e64562da52dcf/src/Mvc/Mvc.Core/src/DependencyInjection/ApiBehaviorOptionsSetup.cs
options.ClientErrorMapping[500] = new ClientErrorData
            {
                Link = "https://tools.ietf.org/html/rfc7231#section-6.6.1",
                Title = Resources.ApiConventions_Title_500,
            };

The resource file was updated on Aug 5 to include the new ApiConventions_Title_500:
https://github.com/aspnet/AspNetCore/commit/709b390157912de0d41b99ec562ed1456d33b6a4#diff-9bdb4982da4faebe331804556c9f3a74
  <data name="ApiConventions_Title_500" xml:space="preserve">
    <value>An error occured while processing your request.</value>
  </data>

That is all well and good but it looks like the ReasonPhrases.GetReasonPhrase() is no longer in sync and so calling ReasonPhrases.GetReasonPhrase(500) still returns Internal Server Error. Isn't this a bug in that it is out of sync?
I saw that it looked like ReasonPhrases was going to get moved but I can't find that it has. Is the issue that I am using an old API and there is a new one that is updated with the new 500 error message?
When running a 2.2 app, ClientErrorMapping does NOT contain a 500 but running as 3.0 as seen below, it does have a 500 error mapping:
public MyClass(IOptions<ApiBehaviorOptions> apiOptions)
        {
            var options = apiOptions.Value;
            var msg = options.ClientErrorMapping[500];
            // msg = "An error occured while processing your request."
        }

My code uses ClientErrorMapping when the mapping is not supressed and I have a test that I used in 2.2 that verifies the Title of a ProblemDetails is the same as the Reason phrase and now the test is failing in 3.0.
Thanks!

@ts46235 thanks for contacting us.
@pranavkm can you take a look?

@ts46235 you should be able to configure ApiBehaviorOptions as part of Startup to provide a different message. Would that resolve your issue?

@pranavkm  I am not blocked on this as it is only a unit test issue at this point, but I do want to ask if ReasonPhrases is intended to be updated to include this updated 500 message or is it that we can no longer count on there being correlation between these two?

Thanks for contacting us, @ts46235.
Are you willing to send us a PR for this?

https://github.com/aspnet/AspNetCore/pull/17038

ReasonPhrases are RFC defined values and should not be modified. Note these are only used in HTTP/1.1 response messages and are rarely visible to the user. They're obsolete in HTTP/2.
https://tools.ietf.org/html/rfc7231#section-6.6.1
Where did the text An error occurred while processing your request. come from?

@Tratcher that was part of the issue report for creating Problem. We typically use text from RFC for most 4xx status codes, we should update MVC to do the same for 500. That's effectively what the issue is tracking at this point.

@Tratcher  see above....that error message was recently added to Resources.resx and used in ApiBehaviorOptions.ClientErrorMapping ....so if a client app uses the error mappings it will return that error message when 500 occurs.

@pranavkm #17038 tried to do the opposite, changing ReasonPhrases to match MVC.

authors: Tratcher javiercn mkArtakMSFT pranavkm ts46235

repo: aspnet/AspNetCore


text:
Bootstrap intellisense not working in Blazor projects in Visual Studio

Bootstrap intellisense isn't showing up in Blazor projects:

Visual Studio provides intellisense based on the CSS files in the project, but it only looks at the unminified versions.

Closing as this is external.


text:
Ambient distributed tracing context

Motivation
Propagate W3C headers to dependant components and make distributed tracing context available even when monitoring is not enabled.
Propagation of headers will ensure that distributed trace will correlate services even when unmonitored ASP.NET app is deployed in-the-middle. Let's take service A that injects distributed tracing context and calls ASP.NET app B. Service B calls service C that expects distributed tracing context in incoming request.
If B is not being monitored for distributed traces - it should propagate distributed tracing context unmodified. When analysing telemetry from services A and C it will look like A calls C directly. Once distributed tracing monitoring will be enabled for B - B have to start modifying context according to W3C specification. So telemetry analysis will show A calls B which calls C.
In both scenarios any other telemetry like ILogger traces or stack dumps can be attributed with the distributed tracing context. This will allow to correlate failures of service B with the distributed trace those failures affected.
CC: @seth-capistron, @vancem, @jacpull, @lmolkova, @glennc, @davidfowl

Epic https://github.com/aspnet/AspNetCore/issues/8924

@davidfowl to investigate the design here to enable Activity tracking by default.

Closing this

authors: SergeyKanzhelev anurse davidfowl


text:
adding FMRL and BlazorPass app links

Hello @ebekker ... Thanks for submitting the links.
Could you provide more detail in the description? I noticed the one from TMWSD ...

TMWSD is a secure messaging service. Messages sent are encrypted, securely transferred, and automatically deleted when they are retrieved.

Could you write something out for the FMRL.link description similar to that?

Awesome ... thanks @ebekker! :rocket:

authors: ebekker guardrex


text:
Fix #195: Separate config source implementation to their own packages

cc @muratg, @troydai

Are we keeping the namespaces with ConfigurationModel?
Otherwise, :shipit:

I kept it here but I am going to change this as part of this PR. Reason being, Configuration class name needs to change otherwise I cannot change the namespace to Configuration

:+1:

XmlConfigurationExtension and JsonConfigurationExtension in Microsoft.Framework.Configuration.Xml and Microsoft.Framework.Configuration.Json respectively are not plural so I did not make these plural too.

All extension method contains should be plural... https://github.com/aspnet/Home/wiki/Engineering-guidelines#extension-method-patterns

Ok. I will update them.

authors: Eilon kirthik muratg

repo: aspnet/Configuration


text:
DeveloperExceptionPage needs better text spacing on OSX/Safari

@kichalla when figuring this out, if it turns out we just have "too much" CSS then consider dramatically simplifying CSS. It could be that we went overboard at some early point and added complex styles that just don't work well.

This is also the case on Edge

authors: Eilon rynowak

repo: aspnet/Diagnostics


text:
Update "Your First ASP.NET 5 Web App Using Visual Studio"

Fixes #1076
Update screen shots and did some minor text update. The tutorial should now match the latest released bits.
@Rick-Anderson @rachelappel @shirhatti @CreepyGnome Please review

squirrels away :shipit:

authors: danroth27 rachelappel shirhatti

repo: aspnet/Docs


text:
Update BrowserLink instructions for 2.0 to 2.1

Upgrading an ASP.NET Core project from 2.0 to 2.1 requires one to manually add the BrowserLink package.

@haraldnagel  Thanks for you contribution. You can check my commit for minor changes I made.

authors: Rick-Anderson haraldnagel


text:
[ComputedAttibute] Column with optional behavior

This attribute should be enriched with optional  behavior that specified if or no refresh select SQL statement is generated.
That behavior apparently seems banal, but it is very important for further ef's flexibility.
When poco class element is decorated with [Computed] attribute, should be possible define an other optional parameter on which specified the behavior aforementioned.
This behavior just exist in EF core, why not should  exits in ef 6?

@mmsgg,
Thanks for your contribution.
To ensure that the project team has proper rights to use your work, please complete the Contribution License Agreement at https://cla2.dotnetfoundation.org.
It will cover your contributions to all .NET Foundation-managed open source projects.
Thanks,
.NET Foundation Pull Request Bot

Looks like the wrong commits??

@mmsgg Please update with appropriate code. Also, how would this differ from [DatabaseGenerated(DatabaseGeneratedOption.Computed)]. Finally, I'm not saying we definitely would not take a PR for this, but the bar is pretty high for any new attribute classes.

authors: ErikEJ ajcvickers dnfclas mmsgg


text:
Navigations 'x' and 'y' were separated into two relationships as ForeignKeyAttribute was specified on navigations on both sides.

I have foreign keys on both sides (circular references) but I get this warning when adding migration.

Microsoft.EntityFrameworkCore.Model[10612]
Navigations 'Player.Info' and 'PlayerInfo.Player' were separated into two relationships as ForeignKeyAttribute was specified on navigations on both sides.

Is there any way to disable this warning, or better way to solve this? What I'm trying to accomplish is to have history of changes as I need relations to old entries in some of my models. So if I change something I want some of the tables to still reference entries before change. I need circural reference as I want my Player.Info (foreign key) to always point to the most up to date entry.

@ajcvickers There you go:
public class PlayerInfo
{
    public int Id { get; set; }

	// is outdated or not
	public bool IsActive { get; set; }

	[ForeignKey("PlayerId")]
	public virtual Player Player { get; set; }
}

public class Player
{
    public int Id { get; set; }

	// info with IsActive == true, or most up to date one
	[ForeignKey("InfoId")]
	public virtual PlayerInfo Info { get; set; }

	//public virtual IReadOnlyCollection<ContractorInfo> Infos { get; set; }
}

@enemyofthedawn I think if your intention is to create two relationships (see below), then you can probably ignore this warning. The warning is basically saying that using ForeignKeyAttribute in this way creates two relationships because it is not uncommon for people to do this by mistake not intending it to create two relationships.
Note for triage: the resulting model for this has two FKs:
EntityType: Player
  Properties:
    Id (int) Required PK AfterSave:Throw ValueGenerated.OnAdd 0 0 0 -1 0
    InfoId (no field, Nullable<int>) Shadow FK Index 1 1 1 0 1
  Navigations:
    Info (<Info>k__BackingField, PlayerInfo) ToPrincipal PlayerInfo 0 -1 2 -1 -1
  Keys:
    Id PK
  Foreign keys:
    Player {'InfoId'} -> PlayerInfo {'Id'} Unique ToPrincipal: Info
EntityType: PlayerInfo
  Properties:
    Id (int) Required PK AfterSave:Throw ValueGenerated.OnAdd 0 0 0 -1 0
    IsActive (bool) Required 1 1 -1 -1 -1
    PlayerId (no field, Nullable<int>) Shadow FK Index 2 2 1 0 1
  Navigations:
    Player (<Player>k__BackingField, Player) ToPrincipal Player 0 -1 2 -1 -1
  Keys:
    Id PK
  Foreign keys:
    PlayerInfo {'PlayerId'} -> Player {'Id'} ToPrincipal: Player

However, only one FK constraint is created in the database:
      CREATE TABLE [PlayerInfo] (
          [Id] int NOT NULL IDENTITY,
          [IsActive] bit NOT NULL,
          [PlayerId] int NULL,
          CONSTRAINT [PK_PlayerInfo] PRIMARY KEY ([Id])
      );

      CREATE TABLE [Player] (
          [Id] int NOT NULL IDENTITY,
          [InfoId] int NULL,
          CONSTRAINT [PK_Player] PRIMARY KEY ([Id]),
          CONSTRAINT [FK_Player_PlayerInfo_InfoId] FOREIGN KEY ([InfoId]) REFERENCES [PlayerInfo] ([Id]) ON DELETE NO ACTION

Doing explicit configuration like this:
modelBuilder
    .Entity<Player>()
    .HasOne(e => e.Info)
    .WithOne()
    .HasForeignKey<Player>("InfoId");

modelBuilder
    .Entity<PlayerInfo>()
    .HasOne(e => e.Player)
    .WithMany()
    .HasForeignKey("PlayerId");

also results in the same tables.

@ajcvickers Because the relationships are cyclic, the foreign key is added out of band of the CREATE TABLE statement:
ALTER TABLE [PlayerInfo] ADD CONSTRAINT [FK_PlayerInfo_Player_PlayerId] FOREIGN KEY ([PlayerId]) REFERENCES [Player] ([Id]) ON DELETE CASCADE;

@bricelam Indeed.

authors: ajcvickers bricelam enemyofthedawn

repo: aspnet/EntityFrameworkCore


text:
how to use snapshot in team develop in three branch

i have three branch with .net core web api that use ef core 2.0
every branch has it own db
we develop in dev  and use dev db  and add-migration .... update database and the snapshot is good
when i merge the dev to master  i  want to sync the change in dev db  to master db
but add migration is empty  because snapshot is not match with my db
is there any solution

@bricelam  I look forward to your reply.

@RenshuozZ We looked at this in triage, but there is not enough information here to be able to give any meaninful guidance. Can you create a github repo with simple projects in the layout that you are using and then describe where/when the issue happens?

@RenshuozZ We need more detailed information about what you are doing. Ideally,, can you create a github repo with simple projects in the layout that you are using and then describe where/when the issue happens?

https://github.com/RenshuozZ/efcoredemo

@RenshuozZ Thanks for the code! Can we also get some detailed steps to reproduce what you are seeing? For example, it's not clear to me what, "delete the migration in dev db" means.

@ajcvickers  thank you for your help , I have already solved my problem. I got it wrong.

authors: RenshuozZ ajcvickers


text:
Query: conditional operator with type check throws InvalidOperationException

The following throws InvalidOperationException:
var rssBlog = context.Set<Blog>()
    .Where(x => x is Blog ? false : true)
    .ToList();

Exception:
System.InvalidOperationException : Operation is not valid due to the current state of the object.
   at Microsoft.EntityFrameworkCore.Relational.Query.Pipeline.RelationalQueryableMethodTranslatingExpressionVisitor.TranslateWhere(ShapedQueryExpression source, LambdaExpression predicate) in /home/roji/projects/EFCore/src/EFCore.Relational/Query/Pipeline/RelationalQueryableMethodTranslatingExpressionVisitor.cs:line 814
   at Microsoft.EntityFrameworkCore.Query.Pipeline.QueryableMethodTranslatingExpressionVisitor.VisitMethodCall(MethodCallExpression methodCallExpression) in /home/roji/projects/EFCore/src/EFCore/Query/Pipeline/QueryableMethodTranslatingExpressionVisitor.cs:line 425
   at Microsoft.EntityFrameworkCore.Relational.Query.Pipeline.RelationalQueryableMethodTranslatingExpressionVisitor.VisitMethodCall(MethodCallExpression methodCallExpression) in /home/roji/projects/EFCore/src/EFCore.Relational/Query/Pipeline/RelationalQueryableMethodTranslatingExpressionVisitor.cs:line 61
   at System.Linq.Expressions.MethodCallExpression.Accept(ExpressionVisitor visitor)
   at System.Linq.Expressions.ExpressionVisitor.Visit(Expression node)
   at Microsoft.EntityFrameworkCore.Query.Pipeline.QueryCompilationContext.CreateQueryExecutor[TResult](Expression query) in /home/roji/projects/EFCore/src/EFCore/Query/Pipeline/QueryCompilationContext.cs:line 58
   at Microsoft.EntityFrameworkCore.Storage.Database.CompileQuery[TResult](Expression query, Boolean async) in /home/roji/projects/EFCore/src/EFCore/Storage/Database.cs:line 72
   at Microsoft.EntityFrameworkCore.Query.Internal.QueryCompiler.CompileQueryCore[TResult](IDatabase database, Expression query, IModel model, Boolean async) in /home/roji/projects/EFCore/src/EFCore/Query/Internal/QueryCompiler.cs:line 108

Confirmed on 4f1f0191f5c4ed86aeab5e5f590a4c8323bf90db

Assigning to @roji
x is Blog is EntityReferenceExpression in the tree at translation pipeline. It should have been removed earlier.

[ConditionalTheory]
        [MemberData(nameof(IsAsyncData))]
        public virtual Task Where_is_conditional(bool isAsync)
        {
            var customer = new Customer();

            return AssertQuery<Product>(
                isAsync,
                ps => ps.Where(p => p is Product ? false : true));
        }

authors: roji smitpatel


text:
Latest builds incompatible with some PostgreSQL array scenarios

When syncing EFCore.PG to latest preview9, some array scenarios are now breaking.
Exception:
Processing of the LINQ expression 'AsQueryable<int>(NavigationTreeExpression
    Value: EntityReferenceSomeArrayEntity
    Expression: (Unhandled parameter: s).SomeArray)' by 'NavigationExpandingExpressionVisitor' failed. This may indicate either a bug or a limitation in EF Core. See https://go.microsoft.com/fwlink/?linkid=2101433 for more detailed information.
   at Microsoft.EntityFrameworkCore.Query.Internal.NavigationExpandingExpressionVisitor.VisitMethodCall(MethodCallExpression methodCallExpression) in /home/roji/projects/EFCore/src/EFCore/Query/Internal/NavigationExpandingExpressionVisitor.cs:line 573

Query:
var count = ctx.SomeEntities.Count(e => e.SomeArray.Any());

Expression tree before NavigationExpandingExpressionVisitor:
value(Microsoft.EntityFrameworkCore.Query.Internal.EntityQueryable`1[Npgsql.EntityFrameworkCore.PostgreSQL.Query.ArrayQueryTest+SomeArrayEntity]).Count(e => e.SomeArray.AsQueryable().Any())

Basically NavigationExpandingExpressionVisitor freaks out when it sees a queryable method (AsQueryable) on an array.
/cc @smitpatel

How is the query getting translated to server eventually? (if this error did not happen)

I've got some pattern matching logic in a simple method translator which identifies it and produces the following:
SELECT COUNT(*)::INT FROM ""SomeEntities"" AS s WHERE array_length(s.""SomeArray"", 1) > 1

Basically I need the the expression to make it all the way to translation...

@roji How breaking is this for Postgres? (i.e. We need to decide whether we're going to try to take this in ask mode, or whether we fix it in 3.1.)

Well, it prevents translation of several array operations, including inside JSON documents (the new feature). Specifically, this prevents translating Any and Contains.
It would definitely be a shame to not have this - but I guess it's not completely critical if this goes into 3.1 instead?

In our projects we are using pg arrays and jsonb fields extensively. For us this is a breaking change that would prevent us from upgrading to preview 9 and 3.0 release. For now, on preview 8 all working fine.

@SonicGD just making sure - as far as I know this is only blocking the translation of Contain on arrays (as Any can be rewritten with a length check). This is the functionality blocking you from upgrading?

Yes. We have many queries like
query.Where(e => e.SiteIds.Contains(site.Id));

and they are failing with
Processing of the LINQ expression 'AsQueryable<Guid>(NavigationTreeExpression
    Value: EntityReferencePost
    Expression: (Unhandled parameter: p).SiteIds)' by 'NavigationExpandingExpressionVisitor' failed. This may indicate either a bug or a limitation in EF Core. See https://go.microsoft.com/fwlink/?linkid=2101433 for more detailed information.

Thanks for confirming. Note that 3.1 will be coming out quite quickly after 3.0, and this is definitely planned to be fixed for that release - so even at worse case you're not going to be waiting for long.

Having similar regression here too after updating to 3.0 and preview9 of PostgreSQL in array join such as:
var userPictures = await _userService.AppUserPicturesStatic.Join(allUsersIds, up => up.AppUserId, userId => userId, (up, userId) => up).ToListAsync();//allUsersIds = string[]
and the error from this is:
[23:18:01 ERR] Error from source=[Admin] with message=[Processing of the LINQ expression 'Join<AppUserPicture, string, string, AppUserPicture>(     outer: DbSet<AppUserPicture>,     inner: (Unhandled parameter: __p_0),     outerKeySelector: (up) => up.AppUserId,     innerKeySelector: (userId) => userId,     resultSelector: (up, userId) => up)' by 'NavigationExpandingExpressionVisitor' failed. This may indicate either a bug or a limitation in EF Core. See https://go.microsoft.com/fwlink/?linkid=2101433 for more detailed information.]

@thepra - join with client side array is not supported since that join has to be client eval. It has no correlation with PostgreSQL arrays.

@smitpatel what's the alternative then in this brave new world?

@thepra - That query was doing client evaluation before. And now we don't do that implicitly. Query should be rewritten for explicit client eval.
var userPictures = (await _userService.AppUserPicturesStatic.ToListAsync()).Join(allUsersIds, up => up.AppUserId, userId => userId, (up, userId) => up).ToList();

@smitpatel mmmmm, quite inefficient then pulling all the records and then joining it, but I guess this is how it was before implicitly.
If you can help me with this, what efficient way would be to write this query and make it do the join database side?

@thepra yes, the important point is that this is the same behavior as in 2.x, but the inefficiency was being hidden by client evaluation - it is now much easier to understand what's going on.
If I'm reading your code correctly, allUsersIds is an array parameter. You can't join a table with an array, but it seems like the main point of the query is to filter out rows whose ID isn't in the array. If that's the case, the query can simply be rewritten as follows:
_userService.AppUserPicturesStatic.Where(a => allUsersIds.Contains(a.AppUserId)).ToList()

Unfortunately Contains on an array currently doesn't work (that's what this issue is about), but this is planned to be fixed for 3.1.0.
Another more extreme option is to use the unnest PostgreSQL function to expand the array to a table-like set of rows, and join on that:
CREATE TABLE numbers_table (num INT, name TEXT);
INSERT INTO numbers_table (num, name) VALUES (1, 'name1'), (2, 'name2'), (3, 'name3');
SELECT num, name FROM numbers_table JOIN (SELECT unnest(ARRAY[1, 3]) AS arr_num) AS arr_table ON arr_num = num;

EF Core will not generate this kind of advanced, PostgreSQL-specific SQL, and most probably never will. However, you can use raw SQL to write it yourself and have EF materialize the results back to entity instances.

Unfortunately Contains on an array currently doesn't work (that's what this issue is about), but this is planned to be fixed for 3.1.0.

@roji There's no issue on that, I can alter that array to a list. Still, moving to 3.0 have broken many of such similar queries.
Fortunately filtering out the solution for ".Join(" can easily point me to the parts that I need to rework 😌.
So right now the correct way left to use the .Join() method is to use the virtual properties in the model to generate the query with those entities in mind, am I right?

Still, moving to 3.0 have broken many of such similar queries.

This is true and we're aware of the one-time porting pain that disabling client evaluation may cause. We do believe it's the better way for EF Core to function, as it makes perf issues much more visible and improves compatibility across versions.

So right now the correct way left to use the .Join() method is to use the virtual properties in the model to generate the query with those entities in mind, am I right?

You should be able to use Join, but you must use it on entity types rather than on array parameters as you tried above.

@roji ...Now I went back and optimized the query, making it explicitly simple, but still have issue with such simple query:
var userPictures = await _userService.AppUserPicturesStatic.Where(up => up.AppUser.CollaborationEntityId == user.CollaborationEntityId).ToListAsync();
where AppUser is a virtual entity.
the error:

Exception data:
Severity: ERRORE
SqlState: 42703
MessageText: la colonna a.AppUserId1 non esiste
Hint: Forse intendevi referenziare la colonna "a.AppUserId".
Position: 146
File: parse_relation.c
Line: 3293
Routine: errorMissingColumn

Which translates to:

MessageText: the column a.AppUserId1 doesn't exist
Hint: Maybe you intended the column "a.AppUserId".

I think the join was supposed to be on a.AppUserId but instead the column AppUserId1 was generated for the query. This is type of query is almost everywhere in the codebase, this is going to bother big time o_o
Do you have any clue? @smitpatel @roji

@thepra can you please open a new issue with a minimal code sample (and schema) that shows the problem?

@roji I deleted that answer because I found a solution, I just needed to apply the fluent configuration between the entities to make it work properly. This thanks to another open issue.

Great, thanks for confirming.

好大一个坑，好惨

authors: SonicGD ajcvickers roji smitpatel thepra wuchang


text:
Add CancellationToken to IQueryable.AsAsyncEnumerable

Lets make a simple repository style wrapper around a database context!
public IEnumerable<Job> GetByPipeline(int pipelineId)
{
    return context.Jobs.Where(job => job.Pipeline.Id == pipelineId);
}

Easy! Now lets make it async!
public IAsyncEnumerable<Job> GetByPipeline(int pipelineId)
{
    return context.Jobs.Where(job => job.Pipeline.Id == pipelineId).AsAsyncEnumerable();
}

It worked! Now lets add a CancellationToken!
public IAsyncEnumerable<Job> GetByPipeline(int pipelineId, CancellationToken cancellationToken)
{
    return context.Jobs.Where(job => job.Pipeline.Id == pipelineId).AsAsyncEnumerable(cancellationToken);
}

error CS1501: No overload for method 'AsAsyncEnumerable' takes 1 arguments

Uh oh! Maybe we can use WithCancellation?
public IAsyncEnumerable<Job> GetByPipeline(int pipelineId, CancellationToken cancellationToken)
{
    return context.Jobs.Where(job => job.Pipeline.Id == pipelineId).AsAsyncEnumerable().WithCancellation(cancellationToken);
}

error CS0029: Cannot implicitly convert type 'System.Runtime.CompilerServices.ConfiguredCancelableAsyncEnumerable<Astra.Domain.Entities.Job>' to 'System.Collections.Generic.IAsyncEnumerable<Astra.Domain.Entities.Job>'

WithCancellation does not return an IAsyncEnumerable!
Ok... I guess we can loop over it ourselves in an async function?
public async IAsyncEnumerable<Job> GetByPipeline(int pipelineId, CancellationToken cancellationToken)
{
    await foreach(var job in context.Jobs.Where(job => job.Pipeline.Id == pipelineId)
        .AsAsyncEnumerable()
        .WithCancellation(cancellationToken))
    {
        yield return job;
    }
}

It compiles, but since this library function now has await in it, we should probably ConfigureAwait as well.
public async IAsyncEnumerable<Job> GetByPipeline(int pipelineId, CancellationToken cancellationToken)
{
    await foreach(var job in context.Jobs.Where(job => job.Pipeline.Id == pipelineId)
        .AsAsyncEnumerable()
        .WithCancellation(cancellationToken)
        .ConfigureAwait(false))
    {
        yield return job;
    }
}

Pfew I think we're done........wait. A new warning?

warning CS8425: Async-iterator 'JobRepository.GetByPipeline(int, CancellationToken)' has one or more parameters of type 'CancellationToken' but none of them is decorated with the 'EnumeratorCancellation' attribute, so the cancellation token parameter from the generated 'IAsyncEnumerable<>.GetAsyncEnumerator' will be unconsumed

EnumeratorCancellationAttribute to the rescue!
public async IAsyncEnumerable<Job> GetByPipeline(int pipelineId, [EnumeratorCancellation] CancellationToken cancellationToken)
{
	await foreach(var job in context.Jobs.Where(job => job.Pipeline.Id == pipelineId)
		.AsAsyncEnumerable()
		.WithCancellation(cancellationToken)
		.ConfigureAwait(false))
	{
		yield return job;
	}
}

Isn't she beautiful?
...
...
...
Please add a CancellationToken parameter to AsAsyncEnumerable. Thanks.

The pain you went through, exactly same I went through while trying to add CancellationToken to the method. You can also remove EF from picture. If you are using any method which returns IAsyncEnumerable, you cannot pass cancellationToken unless you go through above exercise. It's beautiful but the beauty is created by BCL (especially result type of WithCancellation() being different. ) I would suggest filing issue with them if you want to suggest any changes.
Since all the methods returning IAsyncEnumerable (EF or without EF) hits the same fate, this is how we suggest to use the API.
await foreach (var element in GetByPipeline(pipelineId).WithCancellation(cancellationToken))
{
///
}

The pain you went through, exactly same I went through while trying to add CancellationToken to the method.

It gives me comfort knowing I'm not alone.

created by BCL

I remember reading somewhere that ConfiguredCancelableAsyncEnumerable not implementing IAsyncEnumerable was a design decision. And since pretty much every other async IQueryable methods support CancellationToken, I figured I would have more luck here with a small change. It only needs to be done once, so the higher up the chain the better. But I'll definitely consider also posting an issue on the corefx repository.

pretty much every other async IQueryable methods support CancellationToken

Is there a method we have which returns IAsyncEnumerable & also support cancellationToken? EF Core provides async methods mainly for single result (where enumerable is not returned) or methods which enumerates and populate collection objects. They all take cancellationToken since they enumerate asynchronously inside the body to generate the result (rather than streaming).

Closing as by-design since, as @smitpatel says, this is how cancellation support was designed for the async enumerable language feature. If there is something simple we could do in EF to make the experience easier, then we would consider doing that. As it stands, we are limited by the language feature.

authors: ajcvickers rick-de-water smitpatel


text:
Multiple users get registered with same email id

I am using entityframework 2.2. to sign up I am using the below code
[HttpPost("[action]")]
public async Task<ActionResult<ResultViewModel>> Register([FromBody] RegisterViewModel model)
{
    if (ModelState.IsValid)
    {
        IdentityResult result = null;
        var user = await _userManager.FindByNameAsync(model.Email);
        if (user != null)
        {
            return new ResultViewModel
            {
                Status = Status.Error,
                Message = "User already exist.",
            };
        }

        user = new ApplicationUser
        {
            UserName = model.Email,
            Email = model.Email.ToLower(),
            FullName = model.Name,
            Gender = model.Gender,
            CreatedDate = DateTime.UtcNow.Ticks
        };

        try
        {
            result = await _userManager.CreateAsync(user, model.Password);

            if (result.Succeeded)
            {
                var token = Helper.UtilityFunctions.GetSecurityToken(_configuration, user, "App User");
                await _userManager.AddToRoleAsync(user, "App User");

                return Ok(new
                {
                    Status = Status.Success,
                    Message = "User successfully created.",
                    Token = new JwtSecurityTokenHandler().WriteToken(token),
                    Expiration = token.ValidTo,
                });
            }
            else
            {
                if (result.Errors != null)
                {
                    List<string> resultError = new List<string>();

                    foreach (var error in result.Errors)
                    {
                        resultError.Add(error.Description);
                    }

                    return new ResultViewModel
                    {
                        Status = Status.Error,
                        Message = string.Join(",", resultError)
                    };

                }
            }
        }
        catch (Exception ex)
        {
            return new ResultViewModel
            {
                Status = Status.Error,
                Message = string.Join(",", ex.Message)
            };
        }
    }

    return new ResultViewModel
    {
        Status = Status.Error,
        Message = Helper.UtilityFunctions.ModelValidation(ModelState)
    };
}

Above post method is working perfectly fine until I used the PostMan tool to hit the post API with same post body with the gap of neno seconds. Above function need to insert first request and for subsequent API requests above function need to return error message

User already exist.

Because post request frequency is in neno seconds  and before first request reach to  result = await _userManager.CreateAsync(user, model.Password); line two or three (some time more) requests pass  var user = await _userManager.FindByNameAsync(model.Email); (user find check in database) and all the passed requests get inserted in the database with same email id.
Is there any solution to at entity framework level to handle this kind case scenario?
Thanks

Typically this case is handled by having a unique constraint on the user's email, meaning that an error would be generated by the database. This error would be caught in your code and returned as a User already exists error to the user. This would obviate the need for the FindByNameAsync check before insertion (which introduces another database roundtrip).
Regarding Identity specifically, I'm not an expert. However, there seems to be a RequireUniqueEmail option (see the docs). I'm not sure if that affects the EF Core model as well though; if not, you can add a unique constraint by setting up a unique index.

authors: harjit-neo roji


text:
Upgrade Angular template to Angular4

Is it OK if I do this and create a PR?
Do we need to create some sort of official issue that I'm assigned to so nobody else sets of to do the same thing?
I'd like to contribute, got a pluralsight course coming out soon on building SPAs with aspnet core and javascriptservices,I'd love to bump the version :-)
Ping @SteveSandersonMS

https://github.com/aspnet/JavaScriptServices/issues/800

@flightlevel cool, I'll close this one then.

authors: ajtowf flightlevel

repo: aspnet/JavaScriptServices


text:
Common middleware to handle npm command based dev servers

Common code from React and Angular middlewares extracted
Addresses #1704

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

Hi, this pull request is being closed because this repo is archived and all the source code and issues have been moved to the https://github.com/aspnet/AspNetCore repository. If you would like to send a new PR, you can find the new location for the source code here: https://github.com/aspnet/AspNetCore/tree/master/src/Middleware/NodeServices
Thanks,
Eilon

authors: Eilon buldo dnfclas


text:
HTML response was truncated。

i have an asp.net 5 project, When I use the VS debugging when everything works, but when I publish to IIS, then, the HTML response has been truncated, and there are lot of 502 error,  502 most from font (. ttf) files. Beta8 version without any problems even when publishing to IIS, these happened when I upgraded to RC2., please help, thanks!
(dnx: RC2-16302, Kestrel package: 1.0.0-rc2-16236)
BTW: sorry for my bad English, thanks again!
i look my application log, The following recording:
Warning: Connection processing ended abnormally
System.NullReferenceException: 未将对象引用设置到对象的实例。
在 Microsoft.AspNet.Hosting.Internal.HostingApplication.DisposeContext(Context context, Exception exception)
在 Microsoft.AspNet.Server.Kestrel.Http.Frame`1.d__3.MoveNext()

Do you have your application sources hosted somewhere, or can you show us your project.json file?

Sorry for the late reply, because these days are the Chinese new year holiday, my app host in China Azure VM, and i found maybe ILoggerFactory is causing the problem, if i dispose ILoggerFactory before( i want to clear logger， no other methods ) the issue will occurs, and when i add a "trace level" LogProvider , For example, I invoke  ILoggerFactory.AddDebug(LogLevel.Trace) after dispose  , everything will ok. and I invoke  ILoggerFactory.AddDebug(LogLevel.Info) after dispose  , issue will occurs.

Can you share the pieces of code making the calls to AddDebug and Dispose?

@endink Do you still have this issue?

@muratg it seems like fixed! thanks!

authors: cesarbs endink muratg

repo: aspnet/KestrelHttpServer


text:
Question about threading

Given that Kestrel is different from IIS I was wondering how background threads are handled with Kestrel. Is it possible to have a reliable process running within ASP.NET Core?

You own the process when hosting with Kestrel, background threads aren't different here, they are just normal threads. The process will stay alive for as long as you run it (unless it crashes or something). Also, nothing will reboot your process if it dies.

Gotcha, I was referring to things like how IIS would recycle the application pool every 29 hours or so.

Yea, nothing will do that for you.

Thanks for the confirmation!


text:
[Prototype] Using Configuration Monitor in Logging

Logging consumption side of the proposed changes to move away from IChangeToken, we should expose something similar for the equivalent of IFileProvider.Watch as well...
https://github.com/aspnet/Configuration/pull/412
@divega @lodejard thoughts?  I definitely think hiding the logic revolving change token subscriptions is worth doing if we can

Hi @HaoK, I'm your friendly neighborhood .NET Foundation Pull Request Bot (You can call me DNFBOT). Thanks for your contribution!
You've already signed the contribution license agreement. Thanks!
The agreement was validated by .NET Foundation and real humans are currently evaluating your PR.
TTYL, DNFBOT;

authors: HaoK dnfclas

repo: aspnet/Logging


text:
Swapped IsDNX and IsMono to fix running Mono Mobile(Xamarin.Android/Xamarin.iOS)

Crash happens when IsDNX method is loaded because it tries to load System.Runtime.Versioning.FrameworkName type which is not present on Mono Mobile. If IsMono is called first IsDNX is never called, hence no crash.

Hi @DavidKarlas, I'm your friendly neighborhood .NET Foundation Pull Request Bot (You can call me DNFBOT). Thanks for your contribution!

This seems like a small (but important) contribution, so no Contribution License Agreement is required at this point. Real humans will now evaluate your PR.

TTYL, DNFBOT;

This is too subtle to not write a giant comment saying why the ordering of conditions within the if statement matter. Why doesn't the try catch work on iOS and Android?

Added comment.
Reason why try catch is not working is because exception happens while constructing method and not finding FrameworkName type, so before entering try catch statement.
Added new PR that you might like more:
https://github.com/aspnet/Microsoft.Data.Sqlite/pull/217

This PR has been superseded by #225

authors: DavidKarlas bricelam davidfowl dnfclas


text:
Where is ActionFilterAttribute?

Which package can I find to create custom action filters? In previous mvc, I can create one by inheriting from ActionFilterAttribute. Now this class seems to have moved. Please help. Thanks

This is still here: https://github.com/aspnet/Mvc/blob/dev/src/Microsoft.AspNet.Mvc.Core/ActionFilterAttribute.cs
If you're building a site, you should reference Microsoft.AspNet.Mvc which will include this package.

authors: XiaoweiJia rynowak

repo: aspnet/Mvc


text:
Identity UI Scaffolding Code Bug: duplicate "_LoginPartial.cshtml" cause some Anti-forgery token error.

From kapr1k0rn
I searched and did not see this bug was mentioned.
Following the instruction in the 2.1 Identity UI, I added the identity code back to my project, then found this: if I logout from any of the "Manage your account" pages, an anti-forgery token error would happen and caused a 400 status page. It turned out that there were 2 _LoginPartial.cshtml in the project, /Pages/Shared/_LoginPartial.cshtml and /Views/Shared/_LoginPartial.cshtml. Removing /Pages/Shared/_LoginPartial.cshtml fixed the error for me.
See related
https://github.com/aspnet/Identity/issues/1659

@prafullbhosale

I think we have logic to check for the existence of the file before adding a new one.  If this is still an issue, please re-open.

authors: javiercn vijayrkn

repo: aspnet/Scaffolding