[clang-tidy] enable undefined-bool-conversion check

Motivation and Context

This check was initially disabled because it was failing.
How Has This Been Tested

Build
Types of changes

[ ] Docs change / refactoring / dependency upgrade
[X] Bug fix (non-breaking change which fixes an issue)
[ ] New feature (non-breaking change which adds functionality)
[ ] Breaking change (fix or feature that would cause existing functionality to change)

Checklist

[ ] My code follows the code style of this project.
[ ] My change requires a change to the documentation.
[ ] I have updated the documentation accordingly.
[X] I have read the CONTRIBUTING document.
[X] I have completed my CLA (see CONTRIBUTING)
[ ] I have added tests to cover my changes.
[ ] All new and existing tests passed.

Argh sorry about this one. This (the error the CI produces) at https://github.com/facebookresearch/habitat-sim/blob/9af1f62bd8fe9b41149c08e9a22f29decb94863f/src/esp/bindings/bindings.cpp#L46-L53 is a dirty leftover from the time when I ported to Magnum's own Python bindings. When Python's GC comes into play, the invariants in C++ code (where a feature is always attached to a scenegraph object) no longer hold and this was a check for that. I'll see if that can be exposed / checked for in a saner way.

Argh sorry about this one. This (the error the CI produces) at
https://github.com/facebookresearch/habitat-sim/blob/9af1f62bd8fe9b41149c08e9a22f29decb94863f/src/esp/bindings/bindings.cpp#L46-L53
is a dirty leftover from the time when I ported to Magnum's own Python bindings. When Python's GC comes into play, the invariants in C++ code (where a feature is always attached to a scenegraph object) no longer hold and this was a check for that. I'll see if that can be exposed / checked for in a saner way.

Should I just remove this check. It may get optimized out. If it does not get removed, I don't think it will work. What would cause the reference to be NULL?

What would cause the reference to be NULL?

Like I'm saying above -- when C++ deletes an object that still has some features referenced from python, node() of those features becomes null. So removing the check is not a solution.
Is this critical (do I need to jump on this immediately)? Can we live with this thing disabled for a while?

No. Not critical. I can ignore the warning for this particular code if you think that is best.
I agree that removing the check is not a solution. However, I'm not sure leaving the check in is a solution either. It gives a false sense of security. clang will optimize out the check for optimization level O1 and above:
https://godbolt.org/z/JTv_Nc
This is because the check is relying on undefined behavior (null dereference).
Spent some time looking through the logic and now understand where the nullptr is coming from:

When the LinkedList is destroyed it calls clear()
clear() calls erase() on each item
erase() calls doErase() which calls cut()
cut() sets _list to nullptr.

if you think that is best

I'm not saying it's best, not at all. Problem is that i need to expose this check somehow through the scenegraph APIs in order to make it possible to check for this condition without relying on UB, and I don't know how to do that yet without adding an API that says

"look, thing.object() will always return a valid reference so you can totally trust it ... except for this one little case where Python's refcounting gets involved and in that case you might want to call isThisFeatureReallyStillAttachedToAnObjectLikeItIsSupposedToBe() in order to avoid dereferencing a null pointer"

To save time for both you and me, can we put this PR aside for a while (and thus keep the bool conversion check disabled globally) until I figure a non-confusing solution? :) Then I'll push to this branch and fix it properly. Thanks!

if you think that is best

I'm not saying it's best, not at all. Problem is that i need to expose this check somehow through the scenegraph APIs in order to make it possible to check for this condition without relying on UB, and I don't know how to do that yet without adding an API that says

"look, thing.object() will always return a valid reference so you can totally trust it ... except for this one little case where Python's refcounting gets involved and in that case you might want to call isThisFeatureReallyStillAttachedToAnObjectLikeItIsSupposedToBe() in order to avoid dereferencing a null pointer"

To save time for both you and me, can we put this PR aside for a while (and thus keep the bool conversion check disabled globally) until I figure a non-confusing solution? :) Then I'll push to this branch and fix it properly. Thanks!

Why not just disable it on a line-by-line basis like I'm doing here? What is the concern? I think this is a good check. Its catching something legitimate. I'm disabling it for this case but would like to prevent new occurrences.

Okay then :) Will follow up with #353.

Thanks much!


(question): why are you using setImmediate?

I noticed you've used setImmediate here but I'm not sure why that is.
Could you please describe why you've chosen to do this? Thanks.

Hi
Proably it is a small strick where he is looking that server begins to listen after all the declarations because of setImmediate goes to the eventloop in javascript and it would be called after all.
Regards


Wifi-UDP: sendto return ENOMEM only with short buffer or if a client is disconnected (IDFGH-5068)

Environment

Development Kit:     none
Module or chip used:  ESP32-WROVER-IE
IDF version: v4.0.1 AND v4.2-rc
Build System:         idf.py
Compiler version: xtensa-esp32-elf-gcc (crosstool-NG esp-2019r2) 8.2.0
Operating System:     Linux
Using an IDE?: [no]
Power Supply:         external 3.3V

Problem Description
In this project, the ESP send UDP data to two clients. Every second, we send 15 packets of data at each client.
As is done in the iperf.c example, when sendto return -1, we add a delay and re-call sendto if errno == ENOMEM:
static int udp_send_data(ip4_addr_t ip ,char* buf, size_t buf_len)
{
    cliaddr.sin_addr.s_addr = ip.addr;
    return sendto(udp_server_socket, (const char *)buf, buf_len, 0, (const struct sockaddr *) &cliaddr, socklen);;
}

int udp_send_data_blocking(ip4_addr_t ip ,char* buf, size_t buf_len, uint32_t timeout_ms)
{
    int64_t start = esp_timer_get_time()/1000;
    int64_t now = start;

    int err_code = 0;
    int32_t actual_send = 0;
    bool timeout = false;

    int tries = 0;

    do
    {
        actual_send = udp_send_data(ip, buf, buf_len);
        tries++;

        err_code = (actual_send < 0) ? errno : 0;

        now = esp_timer_get_time()/1000;
        timeout = (now-start) > timeout_ms;

        if(!err_code || (err_code != ENOMEM))
            break;

        vTaskDelay(1);

    }while(!timeout);

    if(timeout || err_code)
        ESP_LOGE(TAG, "SENDTO - %s (%d) (timeout: %d, socket: %d, ip_addr: %s, socklen: %d)", strerror(err_code), err_code, timeout, udp_server_socket, ip4addr_ntoa(&ip), socklen);

    if((tries > 1) || (actual_send != buf_len))
        ESP_LOGW(TAG, "SENDTO in %d tries and %d ms (size:%d, buf_len:%d)", tries, (uint32_t)(now-start), actual_send, buf_len);

    return (timeout || err_code || (actual_send != buf_len) || (tries > 1));
}

We have observed different behavior between the esp-idf 4.2-rc and 4.0.1 if we change the packet size. (The number of packet per second doesn't change !)

packet size (bytes)
esp-idf
average sendto time  (us)
Comment

256
4.0.1
360~440
many retries

256
4.2-rc
260~300
many retries

1024
4.0.1
400~470
some retries

1024
4.2-rc
415~480
some retries

2048
4.0.1
900~1100
never return -1 ! No trouble !

2048
4.2-rc
500~600
never return -1 ! No trouble !

A. Why when the size of the buffer increase (but the number of packet doesn't change), sendto never return -1 ?
B. Only on 4.2 (not every time), when a client is disconnected (power off), no event has observed, sendto return -1 and errno returnENOMEM...:

Why there is a difference of behaviour with 4.0.1 ?
How to managed a disconnection ?

E (1236391) UDP_MANAGER: SENDTO - Not enough space (12) (timeout: 1, socket: 54, ip_addr: <IP_ADDRESS>, socklen: 16)
W (1236392) UDP_MANAGER: SENDTO in 127 tries and 252 ms (size:-1, buf_len:24)
E (1236653) UDP_MANAGER: SENDTO - Not enough space (12) (timeout: 1, socket: 54, ip_addr: <IP_ADDRESS>, socklen: 16)
W (1236654) UDP_MANAGER: SENDTO in 127 tries and 251 ms (size:-1, buf_len:24)
E (1236915) UDP_MANAGER: SENDTO - Not enough space (12) (timeout: 1, socket: 54, ip_addr: <IP_ADDRESS>, socklen: 16)
W (1236916) UDP_MANAGER: SENDTO in 127 tries and 252 ms (size:-1, buf_len:24)
E (1237177) UDP_MANAGER: SENDTO - Not enough space (12) (timeout: 1, socket: 54, ip_addr: <IP_ADDRESS>, socklen: 16)
W (1237178) UDP_MANAGER: SENDTO in 127 tries and 252 ms (size:-1, buf_len:24)
E (1237439) UDP_MANAGER: SENDTO - Not enough space (12) (timeout: 1, socket: 54, ip_addr: <IP_ADDRESS>, socklen: 16)
W (1237440) UDP_MANAGER: SENDTO in 127 tries and 252 ms (size:-1, buf_len:24)
E (1237701) UDP_MANAGER: SENDTO - Not enough space (12) (timeout: 1, socket: 54, ip_addr: <IP_ADDRESS>, socklen: 16)
W (1237702) UDP_MANAGER: SENDTO in 127 tries and 251 ms (size:-1, buf_len:24)
E (1237963) UDP_MANAGER: SENDTO - Not enough space (12) (timeout: 1, socket: 54, ip_addr: <IP_ADDRESS>, socklen: 16)
W (1237964) UDP_MANAGER: SENDTO in 127 tries and 252 ms (size:-1, buf_len:24)
E (1238225) UDP_MANAGER: SENDTO - Not enough space (12) (timeout: 1, socket: 54, ip_addr: <IP_ADDRESS>, socklen: 16)

Code to reproduce this issue
Code for esp-idf 4.0.1: wifi_udp_4_0_1.tar.gz
Code for esp-idf 4.2-rc: wifi_udp_4_2.tar.gz

Thanks for the very detailed report, and sorry for the inconvenience, we will look into.

Hi @Alvin1Zhang,
I have additional info to help you in the debugging. With esp-idf 4.2, in lwip component (https://github.com/espressif/esp-lwip/blob/889c3875bf2154356aab10b36025add28909a933), when the client is disconnected:

if the buffer size is 24,  netif->output(netif, p, dest) is called and return -1 (ENOMEM) (https://github.com/espressif/esp-lwip/blob/889c3875bf2154356aab10b36025add28909a933/src/core/ipv4/ip4.c#L1089)

if the buffer size is 2048, ip4_frag(p, netif, dest) is called:
(https://github.com/espressif/esp-lwip/blob/889c3875bf2154356aab10b36025add28909a933/src/core/ipv4/ip4.c#L1082), then netif->output(netif, rambuf, dest) is called twice https://github.com/espressif/esp-lwip/blob/889c3875bf2154356aab10b36025add28909a933/src/core/ipv4/ip4_frag.c#L872 return -1 but the output of netif->output(netif, rambuf, dest)  isn't used and that's why I never see any error with a buffer of 2048...: https://github.com/espressif/esp-lwip/blob/889c3875bf2154356aab10b36025add28909a933/src/core/ipv4/ip4_frag.c#L887

@pbruynbroeck Thanks for sharing the extra details.

hi @pbruynbroeck thanks for reporting.
A. Why when the size of the buffer increase (but the number of packet doesn't change), sendto never return -1 ?

B. Only on 4.2 (not every time), when a client is disconnected (power off), no event has observed, sendto return -1 and errno returnENOMEM...:
Why there is a difference of behaviour with 4.0.1 ?
How to managed a disconnection ?
This issue is a little complicated.
Firstly, the differences between v4.0 with v4.2 may because some reasons that we not backport this fix to v4.0.
Secondly, the root cause of this issue is that, when station connect to softap, station go to sleep and poweroff, the softap will buffer the station's pkts(the power save buffer of softap is only 16), however the station already poweroff, so the softap will keep buffer this station's pkts until pkts timeout, which will cause always return ENOMEM.

Hi @MaxwellAlan,
A. Why do not return the error when the packet is fragmented ?
B.1 So, what its your advice to detecting a disconnection ?
B.2 How is it managed in broadcast mode ?

@MaxwellAlan,

the softap will keep buffer this station's pkts until pkts timeout

How long this timeout last ? Can we reduce it ?

hi @pbruynbroeck , you can try esp_wifi_set_ps(WIFI_PS_NONE) to disable power save and test.

@pbruynbroeck Thanks for reporting, would you please help share if any updates for this issue? Thanks.

Thanks for reporting, will close due to short of feedback, feel free to reopen.

we have the same problem, I want to ask that you have solved the problem or not

I have the same problem too. And during a while of sendto() cycle, it always report ENOMEM and crash.
I'm using esp_wifi_set_ps(WIFI_PS_MAX_MODEM) for power save. How to avoid such issue.

@yihuangong @fredy0219
The simplest easy fix is to add a vTaskDelay() before sendto() in the loop. This gives the TCP/IP task some time to send out UDP packets. But this limits your maximum transmission rate to 1 packet per tick (approx 960KB/sec with 960 byte packets and default 1ms ticks.) This reduces the failure rate by a lot, although there are still some ENOMEM results due to timing (sometimes the TCP/IP task doesn't get a chance to clear it's backlog due to a higher priority task running instead).
while(1) {
	ret = sendto(sock, buffer, 960, 0, (struct sockaddr*)&toAddr, sizeof(toAddr));
	ESP_LOGI(TAG, "ret=%d errno=%d", ret, errno);
	if (ret < 0) {
	    if (errno == ENOMEM) {
	        ESP_LOGW(TAG, "lwip_sendto fail. %d", errno);
	        vTaskDelay(10);
	    } else {
	        ESP_LOGE(TAG, "lwip_sendto fail. %d", errno);
	    }
	}
}

The default wifi station config (WIFI_INIT_CONFIG_DEFAULT) uses static TX buffer type (CONFIG_ESP32_WIFI_TX_BUFFER_TYPE = 0) whether you're using PSRAM or not. The IDF documentation recommends dynamic TX buffer for non PSRAM use, and static for when you have access to this extra memory.
In higher latency scenarios this caused enomem issues for me. Changing the TX buffer type to dynamic seems to have solved this issue. Also increasing the number of dynamic TX buffers can also help, at the expense of higher mem usage.
Redefining :
#define CONFIG_ESP32_WIFI_TX_BUFFER_TYPE 1
#define WIFI_DYNAMIC_TX_BUFFER_NUM 16


Documentation | Navigation | Add a sponsor Button that redirects to the Sponsor program of GitHub for kitchen

@jerembdn / @ImAzyx where ?


Multiple model in single page

how can i use multiple model in single page?
for Ex. :

Dear @vijay21soni!
If you want to control both of your modal from a component controller you should have 2 @ViewChild decorator, like that:
@ViewChild('Modal1') modal1:ModalComponent;
@ViewChild('Modal2') modal2:ModalComponent;

Now you can handle your modals from component after ngAfterViewInit* hook like that:
this.modal1.open();
this.modal2.open();

You wrote Model not Modal - as you can see.
*F:Y.I.:https://angular.io/docs/ts/latest/guide/lifecycle-hooks.html

Thanks for reply,
it is working.
it is a great toll but you have to update according to angular 2 currnet
release.
Sincerely,
Vijay Soni
sky id: vijaysoni.net
mobile: +91-9067635885
On Tue, Jun 28, 2016 at 1:31 AM, fuitattila<EMAIL_ADDRESS>wrote:

Dear @vijay21soni https://github.com/vijay21soni!
If you want to control both of your modal from a component controller you
should have 2 @ViewChild https://github.com/ViewChild decorator, like
that:
@ViewChild('Modal1') modal1:ModalComponent;
@ViewChild('Modal2') modal2:ModalComponent;
Now you can handle your modals from component after ngAfterViewInit*
hook like that:
this.modal1.open();this.modal2.open();
You wrote Model not Modal - as you can see.
*F:Y.I.:https://angular.io/docs/ts/latest/guide/lifecycle-hooks.html
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/dougludlow/ng2-bs3-modal/issues/66#issuecomment-228857961,
or mute the thread
https://github.com/notifications/unsubscribe/AF6u0syFH5hZVWlS70hnIl55ctlsddRxks5qQCwHgaJpZM4I7mcL
.

Thanks. My problem was I was doing this:
@ViewChild('Modal1')
@ViewChild('Modal2')
modal1: ModalComponent;
modal2: ModalComponent;

Which seemed close enough to the code examples. Might want to adjust the examples to show them on the same line to avoid confusion going forward.

@Methodician ha ha, yeah you'll want to annotate the correct property. :)
@vijay21soni glad it's working for you now.
@fuitattila thanks for your help!


Let-binding (let ... in)

Search Terms

Let-binding
"Let ... in"

Suggestion
Add "let ... in" construct as seen in ML-family languages.
Use Cases
The ternary operator is the next best thing to an expression-level "if-else" – see #10841. But it's impeded by not having a way to structure initialization before either expression.
Example
const a = b ? let c = d in (e) => { c(e) } : f;

This would transpile to something like the following JavaScript:
var a = b ? (function() {
    var c = d;
    return function(e) {
        return c(e);
    }
}) : f;

Checklist
My suggestion meets these guidelines:

[x] This wouldn't be a breaking change in existing TypeScript / JavaScript code
[x] This wouldn't change the runtime behavior of existing JavaScript code
[x] This could be implemented without emitting different JS based on the types of the expressions
[x] This isn't a runtime feature (e.g. new expression-level syntax)

It is new expression-level syntax (ie it's syntax that impacts expressions). If JavaScript chooses to implements something similar or use the let keyword for another propose this would break the Typescript is a superset of JavaScript goal. Typescript is generally very conservative when adding syntax that could potentially break this design goal, generally only adding expression-level syntax that is slated for inclusion in JS standards or very limited things like ! for not null assertion or type assertions.


Don't Merge! PR real time test for target branch full build

Docs Build status updates of commit 177f836:
:clock10: Full build: the average full build time is 5 min(s) 26 sec(s), this is based on the last 30 build(s) for this repository.

Docs Build status updates of commit 177f836:
:warning: Validation status: warnings

File
Status
Preview URL
Details

docs-ref-conceptual/testing.md
:warning:Warning
View (azure-cli-latest) View (azure-cli-2017-03-09-profile) View (azure-cli-2018-03-01-hybrid)
Details

docs-ref-conceptual/testing.md

[Warning] Missing attribute: either ms.prod or ms.service is required. Use ms.prod for on-premise products, or ms.service for cloud services.
[Warning] Missing attribute: title.
[Warning] Missing attribute: either ms.prod or ms.service is required. Use ms.prod for on-premise products, or ms.service for cloud services.
[Warning] Missing attribute: title.
[Warning] Missing attribute: either ms.prod or ms.service is required. Use ms.prod for on-premise products, or ms.service for cloud services.
[Warning] Missing attribute: title.

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


ENH: New architecture: supply callable classes to tf.dataset.map()

Instead of supplying lambda expressions or other functions as the first parameter to tensorflow.dataset.map() calls, we now supply callable classes.  For each callable class, this makes initialization code be encapsulated in the __init__ method and the actual dataset manipulation be encapsulated in the __call__ method.  Subroutines of these methods are encapsulated as private methods of the callable classes.
The steps of a function implementing a pipeline are now much simpler and more compact.  They require two basic operations, construction of the callable class and supplying the callable class to the tensorflow.dataset.map() function.  An entire pipeline might now fit on a single page because the parts that should be internal to any given pipeline step now are internal.

Looking nice!


Transform api operations based upon middleware wrappers

I came across the need to modify the api spec based on properties of middleware transformers. In our case it was RBAC middleware which specified different roles for different endpoints.
This change adds another trait to the parameter on the Resource wrapper, TransformApi. In this use case it allowed the roles required on the endpoints to be automatically added to operation.tags and into operation.description, which seems like it will be very useful.
I have a couple of concerns about it though:

this changes the signature of wrap so it is a breaking change for users of that function - it could be given a new name
I've made RouteWrapper public - maybe it should use a different type?
the transformers need to be cloned to be passed into the inner and kept in the wrapper - but in my case they are very small
the transformers are being kept in the wrapper in a type-system linked list, this avoided allocations and is fine in my case but maybe others would have a problem with it

BTW, would not the roles required on endpoint better managed with Apiv2Security derive?
We are managing this internally via FromRequest handlers on a User and AccessToken, that seems like better fit in actix world. Not sure about your use case details though.
In regards to back compatibility - we are doing 2 phase initialization of actix-web, first is for all services which we exclude from schema, then doing wrap_api and all schema based initializations. I guess this can be adviced as a migration approach if your PR would be accepted.

Yes I think it might be a nice solution to have a security parameter which contained type information about the roles that are allowed access and to implement the schema documentation there. But for now that seems to big of a change for this project. The role information is already there in the middleware and available at runtime, it seems reasonable that middleware could alter the spec as it could change anything about the handling of resources.
I have only worked on this one actix web project so I don't know anything about how they generally look, but I feel that more extensibility would be helpful to paperclip.

There is a different way to pass data from middleware now ReqData so that might be a better way to modify the schema via wrapped types? https://github.com/wafflespeanut/paperclip/issues/300

@dunnock Thank's for the info - I'll keep that in mind if we update to actix-web 3 at some point


[jvm_packages]Can you add watchlist features to XGBoost4j-Spark

I noticed that in XGBoost4j-Spark source code, the train method of the XGBoostClassifier class doesn't have the watchlist features. While in XGBoost4j, the watchlist features is implemented. Do you have plans to add it to the XGBoost4j-Spark package? Also, any plans to add cross validation to XGBoost4j-Spark?

The watchlist feature is already in the feature request list #3439.

If you'd like a detailed discussion on the proposed feature, feel free to post at https://discuss.xgboost.ai/. We appreciate your contribution.

I went ahead and migrated your post to https://discuss.xgboost.ai/t/jvm-packages-watchlist-feature-for-xgboost4j-spark/39, since it may be interest to other people.

@18321171817 There is a watchlist feature in the works: #3544.

Actually never mind. The linked PR was watchlist for XGBoost4J, not XGBoost4J-Spark.


Blog post TPI Jupyter

Some more padding to @casperdcl's blogpost. Kept the example/repo the same, which means it does provision a Tensorboard instance that is not really the focus of this blog post.
Goal: easy to follow tutorial for data scientists who're googling "jupyter notebooks in cloud".

[x]  Is the content technically correct (examples are working and can be reproduced, code in the repo is up to date, etc.)
[x]  There are no grammatical errors, jargon, or obvious stylistic issues.
[x]  The flow and messaging correspond to what has been defined in the Phase 3.
[ ]  Have images been run through tiny.png?
[x]  Are all lines 80 characters or less?
[x]  Are Oxford commas observed?
[ ]  Content Creator has done a complete review for typos/language after taking a break from content
[x]  links checked in piece
[x]  Have reviewed what the piece looks like on your own machine using yarn develop

Merged some of the easier comments in a75886e, feel free to unresolve/revert/contest if you like.

Ah looks like some miscommunication, sorry didn't realise "it was supposed to be a quick retelling."

the entire goal of the original tutorial was to be posted on an external site and not dvc.org
if the original (external) posts are missing text/context, we can update them
it is exceedingly bad for SEO to re-post a slightly tweaked existing blog, esp. since we don't currently do canonical links
it's also not worth our time to post non-original content

To be clear:

quick retelling of the Hackernoon post [...] don't see why we should scrap the post unless you have major objections. It's as good as done, and even if doesn't add much, it surely doesn't hurt either.

quick retelling of Hackernoon: already done in Dev.to
I (and more importantly search engines) will not categorise this as "scrapping" - it's more like "not duplicating/plagiarising" (see point 3 above)
I agree the original (Hackernoon) post could be improved (despite being thoroughly reviewed and iterated on by half a dozen people in detail)

TL;DR yes major objection, it will probably hurt.
I still think it's been a useful process, we can port over useful suggestions/improvements to the original post(s)?

Ah looks like some miscommunication, sorry didn't realise "it was supposed to be a quick retelling."

the entire goal of the original tutorial was to be posted on an external site and not dvc.org
if the original (external) posts are missing text/context, we can update them
it is exceedingly bad for SEO to re-post a slightly tweaked existing blog, esp. since we don't currently do canonical links
it's also not worth our time to post non-original content

Point-wise reply for clarity:

Yes, and the entire goal of this derivative is to be posted on dvc.org rather than an external site. Different outlets can serve different purposes. I can imagine Hackernoon was chosen in part for their platform and the people who visit that site. I can also imagine people searching our own outlets (Blog, docs, Youtube, ...) if they're looking for something specific. A post on dvc.org provides an extra opportunity for people to discover they can do this. Moreover, I think the target audience varies; here I tried to cater to more junior data scientists than the ones who might read the original post.
I think the original blog post is targeted well and serves its purpose; I don't see the immediate need to update it.
It is not a slightly tweaked blog when looking at the text; it's a near-total rewrite. Conceptually it covers the same ground, but it does so with new content. It uses the original example you created, but the elaboration around is completely new. I don't see how this would have such a severe SEO impact.
To an extent I agree, although as outlined in [1] I believe these two posts should serve different purposes. Regardless, we're at the point where we spent the time anyway. We should definitely pay more mind to this in future instances, but at this point, we just need to dot the i's and cross the t's.

Just to clarify: with quick retelling I meant quick for the process, not the post itself. This post is far more verbose than your original publication.

@RCdeWit hey, any updates on this blog post? do we plan to publish or close this?


update rio-cogeo for newer morecantile

nothing I saw at a quick glance needed changing so let's see what happens with the ci

hmm okay I though the builds didn't need approval, I'll look again tomorrow and build locally/actually read the changelogs

needed to drop python 3.8 in this PR as rasterio isn't shipping wheels anymore for python 3.8 after version 1.4

hey @vincentsarago wondering if we can merge this as it's blocking some CI builds I have, if something needs fixing happy to do it.

Sorry I've been super busy recently with travelling/conferences
Not sure about timeline as next week looks also super busy I'm sorry

@vincentsarago are there more significant changes needed outside of updating the version pin? if so then that's cool and understandable, i'd take a stab at them but nothing I saw when I looked last needed updates... but maybe I am totally missing something

I do not now


prop to control value and operator reset functionality on field change.

Hi,
Using query builder when I update operator and value  before field.
Setting field  resets  operator and value to defaults.
I need to prevent this from happening using a prop.
We have a use-case where field, operator and values are independent sets and the current reset mechanism is not expected.

You can accomplish what you want with the current functionality, using a combination of custom components, useEffect, and the usePrevious hook found here.
Basically you just ignore the current value and reset it to the previous value when the field changes. Do this for both the ValueSelector and the OperatorSelector components.
Here's some example code, based off the default create-react-app setup:
// usePrevious.js

import { useRef, useEffect } from 'react';

const usePrevious = value => {
  const ref = useRef(null);

  useEffect(() => {
    ref.current = value;
  }, [value]);

  return ref.current;
};

export default usePrevious;

// ValueEditor.js

import React, { useEffect } from 'react';
import usePrevious from './usePrevious';

const ValueEditor = props => {
  const prevField = usePrevious(props.field);
  const prevValue = usePrevious(props.value);

  useEffect(() => {
    if (prevField !== props.field) {
      props.handleOnChange(prevValue);
    }
  });

  return (
    <input
      value={props.value}
      onChange={ev => props.handleOnChange(ev.target.value)}
    />
  );
};

export default ValueEditor;

// OperatorSelector.js

import React, { useEffect } from 'react';
import usePrevious from './usePrevious';

const OperatorSelector = props => {
  const prevField = usePrevious(props.field);
  const prevValue = usePrevious(props.value);

  useEffect(() => {
    if (prevField !== props.field) {
      props.handleOnChange(prevValue);
    }
  });

  const options = props.options.map(opt => (
    <option value={opt.name}>{opt.label}</option>
  ));

  return (
    <select
      value={props.value}
      onChange={ev => props.handleOnChange(ev.target.value)}
    >
      {options}
    </select>
  );
};

export default OperatorSelector;

// App.js

import React from 'react';
import QueryBuilder from 'react-querybuilder';
import OperatorSelector from './OperatorSelector';
import ValueEditor from './ValueEditor';

const App = () => {
  const fields = [
    { name: 'FIELD1', label: 'Field 1' },
    { name: 'FIELD2', label: 'Field 2' },
  ];
  const controlElements = {
    valueEditor: ValueEditor,
    operatorSelector: OperatorSelector,
  };
  const initialQuery = {
    id: 'group',
    combinator: 'AND',
    rules: [
      { id: 'rule1', field: 'FIELD1', operator: '=', value: 'Test 1' },
      { id: 'rule2', field: 'FIELD2', operator: '=', value: 'Test 2' },
    ],
  };

  return (
    <QueryBuilder
      fields={fields}
      onQueryChange={q => console.log(q)}
      controlElements={controlElements}
      query={initialQuery}
    />
  );
};

export default App;

If you run that, try to change the field selection and you'll see that the operator and value do not change automatically.
You can get pretty sophisticated with your useEffect code here. Where I work, we have a query builder that uses a completely different ValueEditor depending on the field and operator selections, so sometimes the value needs to be reset but sometimes it doesn't.
Hope that helps.

@jakeboone02 thank you for the reply we have already implemented the approach you have given above.
But we think it would be good to have first-class support to control reset functionality with the additional property.
May you please look into PR #122.

@lakk1 - I have implemented your change in version 3.1.0.


The new version is causing the build to fail with the error message "Can't resolve 'js-md5'"~

hi. did an update. also added support for zustand v5 types

js-md5 is used for leitenAsync, very similar to react query usages


Provide mechanism to configure XContent parsing constraints (after update to Jackson 2.15.0)

Is your feature request related to a problem? Please describe.
The OpenSearch used to have no constants (at least officially) on maximum fields sizes that could be uploaded using supported XContent types (JSON/CBOR/YAML/Smile). Since Jackson 2.15.0, there are streaming constraints in place.
Describe the solution you'd like
Provide the way to alter  Jackson 2.15.0 streaming constraints for supported XContent types. Since all factories are initialized statically, the suggestion is to use system property opensearch.xcontent.string.length.max.  The default has also been increased from ~5Mb to ~50Mb.
Describe alternatives you've considered
Lift the  streaming constraints by setting the maximum string size to Integer.MAX_VALUE.
Additional context
https://github.com/opensearch-project/OpenSearch/pull/7286
https://github.com/FasterXML/jackson-core/issues/1001#issuecomment-1527216221

Documentation update https://github.com/opensearch-project/documentation-website/issues/4089

Thanks @reta , I see the Jackson 2.15.0 version bump also backported to 2.x branch https://github.com/opensearch-project/OpenSearch/pull/7300. Is that must have? This will introduce string length limit, which is a breaking change.If user store big strings in index, it will stop working after upgrading to 2.8.

@ylwu-amzn we bumped the limit 10x to accomodate for such possible regression, however to your point, we may lift the content limit for 2.x branches.


Update updated_at of state even when nothing has been changed

The timestamp should be updated to avoid timeout as long as the conversation is continuing.

https://github.com/uezo/linebot-template/commit/50e50ef7495b1e1de9b5ad3fcf3a811465b06c6c

🙃


do logmessage (info) instead of erroring when writing a non-uint8_t value

Kinda prefer the error come to think of it 😉

Well, at least we have the option now.. The change might have been a bit too strict for a 'one day until release' merge. I can live with both options.


PUT Request with Content-Type: application/json header

When I trying to send cpr::Put request... it just stuck with no response at all from server.
But it happening only if I using header (Content-Type: application/json) header.
So I need it, because I want to send PUT requset with body json.
cpr version 1.5.0

Okay.... I was wrong. It is stuck because I use cpr::Body in cpr::Put Request. It works when I use cpr::Payload or cpr::Multipart


Match expressions should be formatted like enums and structs

Match expressions are currently being formatted like function arguments, but should be formatted like enums and structs.

Closed by #2539


CodeQL-identified gremlins

Describe the bug
CodeQL complains about these things:

Missing MessageEvent.origin verification in postMessage handlers (https://github.com/metacpan/metacpan-web/security/code-scanning/33?query=ref%3Arefs%2Fheads%2Fmaster)
Incomplete string escaping or encoding - "This replaces only the first occurrence of" /%3A/i and # (https://github.com/metacpan/metacpan-web/security/code-scanning/34?query=ref%3Arefs%2Fheads%2Fmaster and https://github.com/metacpan/metacpan-web/security/code-scanning/35?query=ref%3Arefs%2Fheads%2Fmaster)

To Reproduce
I think CodeQL is probably right. Have you considered using CodeQL, e.g. by imitating (or just copying) https://github.com/metacpan/metacpan-web/blob/master/.github/workflows/codeql-analysis.yml ?
Expected behavior
Not security warnings? :-)

@mohawk2 the links you pasted (e.g. https://github.com/metacpan/metacpan-web/security/code-scanning/33?query=ref%3Arefs%2Fheads%2Fmaster) are 404 for me.

You can also do:

Security tab.
Setup code scanning button.
CodeQL Analysis: setup this workflow button.
...

@tschaub Oops! The explanatory text for the first one:

If you use cross-origin communication between Window objects and do expect to receive messages from other sites, always verify the sender's identity using the origin and possibly source properties of the recevied MessageEvent.

The second:

Sanitizing untrusted input is an important technique for preventing injection attacks such as SQL injection or cross-site scripting. Usually, this is done by escaping meta-characters such as quotes in a domain-specific way so that they are treated as normal characters.

If you use cross-origin communication between Window objects and do expect to receive messages from other sites, always verify the sender's identity using the origin and possibly source properties of the recevied [sic] MessageEvent.

We do not use cross-origin communication between Window objects.

Sanitizing untrusted input is an important technique for preventing injection attacks such as SQL injection or cross-site scripting. Usually, this is done by escaping meta-characters such as quotes in a domain-specific way so that they are treated as normal characters.

If you can provide detail on where these instances of "incomplete string escaping or encoding" occur, we could better gage whether there is a legitimate concern.  Otherwise, this broad truism ("sanitizing untrusted input is an important technique") isn't much to go on.

The code that triggers the first warning about %3A:
var t=this.auth||"";t&&(t=(t=encodeURIComponent(t)).replace(/%3A/i,":"),t+="@")

ends up in the distributed ol.js but doesn't seem (based on a lack of .auth found in the repo) to be directly from your code. Instead, it's this:
Url.prototype.format = function() {
  var auth = this.auth || '';
  if (auth) {
    auth = encodeURIComponent(auth);
    auth = auth.replace(/%3A/i, ':');
    auth += '@';
  }
// ...

from url version 0.11.0, apparently brought in by either node-libs-browser (it won't be from webpack-dev-server). It could be called a false positive, but it'd still probably be more correct for it to have a /g.

The second warning, about Worker and messages. The relevant code is in src/ol/source/Raster.js:
function createWorker(config, onMessage) {
  const lib = Object.keys(config.lib || {}).map(function (name) {
    return 'var ' + name + ' = ' + config.lib[name].toString() + ';';
  });

  const lines = lib.concat([
    'var __minion__ = (' + createMinion.toString() + ')(',
    config.operation.toString(),
    ');',
    'self.addEventListener("message", function(event) {',
    '  var buffer = __minion__(event.data);',
    '  self.postMessage({buffer: buffer, meta: event.data.meta}, [buffer]);',
    '});',
  ]);

  const blob = new Blob(lines, {type: 'text/javascript'});
  const source = URL.createObjectURL(blob);
  const worker = new Worker(source);
  worker.addEventListener('message', onMessage);
  return worker;
}

The CodeQL bit says:

Recommendation
Always verify the sender's identity of incoming messages.
Example
[...]
In the second example, the MessageEvent.origin is verified with an unsecure check. For example, using event.origin.indexOf('www.example.com') > -1 can be bypassed because the string www.example.com could appear anywhere in event.origin (i.e. www.example.com.mydomain.com)

function postMessageHandler(event) {
    let origin = event.origin.toLowerCase();

    let host = window.location.host;

    // BAD
    if (origin.indexOf(host) === -1)
        return;

    eval(event.data);
}

window.addEventListener('message', postMessageHandler, false);

The third example they give hardcodes an origin, which isn't suitable for your library code. But I'd have thought changing the check in the second example to be event.origin.toLowerCase() === window.location.host.toLowerCase() would be a good idea for maximum certainty?


Fence gates changes

In this pull request I have fixed fence gates rotations and mirroring. Now they act like any other block with a direction.
I have also added a renderer for fence gates(they show if they are open and in which direction they are open):

It's really good! Thanks

Wow sweet! Does it still use the shitty images I cut up and added to the terrain.png?
(these)

Or does it pull from the wood texture like it actually does for minecraft? Shouldn't matter too much since I pulled those from the wood texture anyway.

Very nice, now we just need to fix the regular fence renderer's texturing and fences will be done. Currently if you have multiple kinds of fences in the same chunk it will pick one and texture all of the fences in that chunk with that single wood type.

@TrazLander It uses those textures for the sides and the plank textures for the top(so that it looks solid on top).
@Khroki I forgot to mention that I also fixed that bug. I based the code after the fence renderer and noticed the comment so I ported the fix I made for the fence gates back to the fence renderer.

Ah cool, thanks, that bug has been taunting me forever.


Remove binary dependency and update Node

Remove binary buffertools dependency (more portable, can run on Node nightly builds)
Use Buffer.concat instead of buffertools.concat
Use buffer-indexof module instead of buffertools.indexOf (Buffer.prototype.indexOf is present since Node 4 but this module is still needed for legacy support)
Use events.EventEmitter instead of process.EventEmitter (the latter shows a deprecation message in Node 6)

I could get the tests to pass on Node 0.8.0 to 6.0.0.

This commit is absolutely necessary to get Flowdock API support for AWS Lambda functions without having to re-build on an AWS machine.
+1 for merging this in.

The buffertools dependency has cost us at least 3 days and counting of working around this, on both Windows AND AWS Elastic Beanstalk.  I still don't have a reasonable workaround on ELB.
Another +1 to merge this, then update hubot-flowdock.

Associating this pull request to Issue #20.

Hey, just merged this in, going to get it into NPM soon. Thanks!


Add total number of proposals in a space to space query

This is already in place

we can make this figure a show in the space, just like spaces num in the homepage. @bonustrack

@bonustrack what is the query for this?


Line numbers not showing for gcc 2.8.1 -g2

Fixed in https://github.com/pmret/binutils-papermario/pull/7


Update types for require and require.context

Summary:
It's been 1½ years since the merge of https://github.com/facebook/metro/pull/822 and my hope is that this feature is ready to be documented and made available through types.
Changelog:
[GENERAL] [ADDED] - Added types for require.context, which is provided by Metro at build time.
Test Plan:
I've tested this manually in a project.

cc @EvanBacon
What do you think? Is this ready for general consumption?
I would love to rely on these types in examples of another package of mine.

I think we need to ship the feature as stable (and on by default) before we ship types that assume it's on.

@motiz88 great point! I honestly don't know why I didn't realize this wasn't enabled by default. How about making the context property optional, forcing code to check for it's presence before relying on it? I've updated the PR accordingly.

Unfortunately I don't think making it nullable is sufficient. We don't support feature-detecting require.context in this way. The best way forward is to enable it out of the box, then document it (including in types).

We don't support feature-detecting require.context in this way.

Why wouldn't this work?
if (require.context) {
  require.context(/* ... */);
}

Trying to verify this fix this today, I see that this change conflicts with the require global declared by @types/node which are included into the project, at least one place:

https://github.com/facebook/metro/blob/main/packages/metro-core/types/index.d.ts#L11

This is my experience in VSCode:

Because of NodeRequire being declared in @types/node/globals.d.ts and it being automatically included in the project, this PR currently needs a declare const to pin the type of require in user-space:
declare const require: ReactNativeRequire;

if (require.context) {
  require.context('.');
}

I hope to investigate other workarounds for this.

Never mind, now I noticed there's runtime code throwing if we simply get context off the require object: I suspect that's the reason we can't feature-detect it 😞 thanks for mentioning this @motiz88.

ERROR Error: The experimental Metro feature require.context is not enabled in your project.
This can be enabled by setting the transformer.unstable_allowRequireContext property to true in your Metro configuration.

Even if we enable this by default, the types won't be accurate if users disable it - perhaps that's good enough?
The TS issue of require being declared as NodeRequire remains 🤔 I'll draft this for now.

To be clear, at the point when we enable require.context by default (or soon afterwards), we'll probably remove the option entirely.

I'm guessing this is not stale


Add a structure of Credit/Bank Card Recognizer and Achieve SimpleConsole version in Chinese

Following the implement of PhoneNumber.
Now, it can only work by SimpleConsole. No yaml file added; Can not be tested; Can not be compiled.
Added Modules
Microsoft.Recognizers.Text.Sequence
Extractor:
BaseCreditCardExtractor.cs
Config:
CreditCardExtractorConfiguration.cs
Models:
CreditCardModel.cs
Parser:
CreditCardParser.cs
Constants
SYS_CREDIT_CARD = "builtin.creditcard"
MODEL_CREDIT_CARD = "creditcard"
CREDIT_CARD_REGEX_CN = "CNCreditCard"
Definition
BaseCreditCard.cs
Chinese
CreditCardDefinitions.cs
Chinese
Extractors
ChineseCreditCardExtractorConfiguration.cs
SequenceRecognizer
Public static List RecognizeCreditCard
Public IModel GetCreditCardModel
RegisterModel
Other Changes
IExtractor.cs
Add new fields : Validation and Issuer (Maybe this can be done better)
IParser.cs
Add new fields : Validation and Issuer (Maybe this can be done better)
ResolutionKey
Add new fields : Validation and Issuer
Program.cs
Add SequenceRecognizer.RecognizeCreditCard(query, culture)
Test Cases
这是中国的银行卡6200 0000 0000 0000 123
这是中国的银行卡6200 0000 0000 0000
这是中国的银行卡6200000000000000123
这是中国的银行卡6200000000000000
这是中国的银行卡6200 0000<PHONE_NUMBER>3
这是中国的银行卡62 0 00 0000 0000 000
这是中国的银行卡3100 0000 0000 0000 123
这是中国的银行卡3100000000000000123
这是中国的银行卡3100 0000 00000 000123

These codes are semi-finished and should be implemented completely in the future.


openai.error.InvalidRequestError: The model gpt-4 does not exist or you do not have access to it.

Hi,
I'm getting an 'openai.error.InvalidRequestError: The model gpt-4 does not exist or you do not have access to it.' error. I haven't made any changes to this code. I contacted OpenAI support and they confirmed I'm using the right API key. Although, OpenAI did say there're different chatgpt instances.
Any idea how I can fix this? Can anyone confirm how to make sure I'm using the right API key?

Hi @resonates7 , have you get solution to this error ?

gpt4 is not yet available for all. Feel free to change from gpt4 to gpt3.5-turbo in config/config.py file.

You can also set this in .env or environment variable:
SMART_LLM_MODEL=gpt-3.5-turbo

Thanks! Changing the Smart LLM Model setting in the config.py file to 'gpt-3.5-turbo' fixed the issue.


[0.0.44] build dev failed

Note: for support questions, please use one of these channels:
https://forum.ionicframework.com/
http://ionicworldwide.herokuapp.com/
Short description of the problem:
[22:59:08]  build dev failed: Cannot read property 'length' of undefined
What behavior are you expecting?
Build Successful
Steps to reproduce:

Ionic serve

insert any relevant code between the above and below backticks

Which @ionic/app-scripts version are you using?
0.044
Other information: (e.g. stacktraces, related issues, suggestions how to fix, stackoverflow links, forum links, etc)
6.4.0
Ionic Framework Version: 2.0.0-rc.2
Ionic CLI Version: 2.1.8
Ionic App Lib Version: 2.1.4
Ionic App Scripts Version: 0.0.44
ios-deploy version: Not installed
ios-sim version: Not installed
OS: Windows 10
Node Version: v7.1.0
Xcode version: Not installed
The resource from “http://localhost:8100/build/main.css” was blocked due to MIME type mismatch (X-Content-Type-Options: nosniff).
The resource from “http://localhost:8100/build/main.js” was blocked due to MIME type mismatch (X-Content-Type-Options: nosniff).

I have this same issue if I use yarn, are you using it?
If so, try to use npm install instead.

Nope I am not using yarn.
Have perform npm install and update npm to 4.0.2 but still build fail and browser show resource block on console log

I've just implemented yarn here, just copy the package.json deps. I have also added an example to an integration with gitlab continuous integration.
The error you are getting came from typescript. Block the version to 2.0.10 without the ^ and probably yarn will not complain. To make it work I have also added tslint to devDep.

This should be resolved.
Thanks,
Dan


Enable model-level entity properties to be associated to a backing field but no property getter or setter

Currently the string version of Property<T>() can only be used to create a shadow state property. This issue is about enabling declaring model-level properties on CLR types that are backed by a field but don't have a property getter or setter. E.g. assuming a fluent API for setting the "BackingField" annotation, we could enable code like this:
ModelBuilder.Entity<Person>().Property<DateTimeOffset>("BirthDate").UseBackingField("_birthdate");

For triage: I am almost sure we said this had to be in the backlog but leaving the milestone empty just in case.

@divega @rowanmiller @anpete @AndriySvyryd
Here is a proposal based on the discussion we had yesterday. Thoughts?
.Property(e => e.Id).UseField("_key");
.Property("Id").UseField("_key");

If the property is a CLR property, then this just configures the backing field to use for that property--i.e. it is just fluent API for what we already have.
If the property is not a CLR property, then this makes the property always use the field for storage. So it is no longer a shadow property and becomes a mapping to the field.
.Property("_key").UseField("_key");
.Property("_key").UseField();

These both do the same thing--the property in our metadata is now named the same as the CLR field. This is functionally the same as the field mapping above.
Related to this is #4855 which is about whether to use the property or the backing field directly when accessing properties. Proposal is to have three modes:

PreferProperty (Everywhere uses the property if possible)
PreferFieldForQuery (Materialization prefers field; everywhere else prefers property)
PreferField (Everywhere uses the field if possible)

If we are preferring properties, then we will use the property getter/setter if available, otherwise fall back to using the field. Likewise, if we are preferring field, then we will use the field unless the field is not specified or cannot be found, in which case we fall back to using the property.
The default is PreferFieldForQuery, which matches our current behavior.
This mode can be set at the Model, Entity, or Property level:
modelBuilder.HasPropertyAccessMode(PreferProperty);
modelBuilder
    .Entity<Foo>()
    .HasPropertyAccessMode(PreferProperty);
modelBuilder
    .Entity<Foo>()
    .Property(e => e.Id)
    .HasPropertyAccessMode(PreferProperty);

So if you map all your fields and use PreferField on the model, then we will never access your properties and you get complete mapping to backing fields.
Very open to suggestions for naming.

Looks good. Question:
When there is no CLR property "_key", will
.Property("_key");

add a field-backed property if a matching field is found?
Perhaps HasPropertyAccessMode -> UsePropertyAccessMode

@anpete Depends whether or not we think that any significant number of people are currently doing this and have working apps with shadow state properties. Safest thing is to not do it. Best experience assuming we think we can make the break is to do it.

@ajcvickers Could be a feature flag, too.

Can we have a shortcut syntax that infers, based on a convention, the name of the backingField to avoid a bunch of magic strings e.g.
.Property(e => e.Id).UseField();
infers to use a backing field called _id
In this case the convention uses by default a field which is named _{camelCasedPropertyName}. It would be even nicer if we can replace this convention with a custom one.

@ilmax EF Core already does that.

At first glance the proposal looks good and it seems that having UseField() and HasPropertyAccessMode() defined like this should be fine because they are different (one is an explicit configuration API and the other is to select default behaviors) however there seems to be some ambiguity or overlap between them, in particular when HasPropertyAccessMode() is applied to property configuration. E.g.:

Being able to write something like this seems pointless:

modelBuilder
   .Entity<Foo>()
   .Property(e => e.Id)
   .UseField("_id")
   .HasPropertyAccessMode(PropertyAccessMode.PreferProperty);

There doesn't seem to be a way to explicitly indicate that a field should not be used, e.g. something like UseField(false) on property configuration.

I have a few ideas of tweaks we could try on this proposal but I think it would be more productive to chat in person.
Orthogonal to that:

Assuming 'PropertyAccessModeis an enum, we could name its members justProperty, Field, etc. then we could make the second API DefaultPropertyAccessMode()`
All the behaviors we have talked about seem to be centered only on how property values are set. I wonder if how EF reads property values from objects (e.g. during fixup and on SaveChanges()) is interesting enough to add granular control for it.

Notes from triage
// Configure a field (will be used during materialization but not fix-up etc.)
modelBuilder
  .Entity<Foo>()
  .Property(e => e.Id)
  .HasField("_id");

// Configure a field and enforce it is always used
modelBuilder
  .Entity<Foo>()
  .Property(e => e.Id)
  .HasField("_id")
  .UsePropertyAccessMode(PropertyAccessMode.Field);

// Skip using field even if it was found by convention
modelBuilder
  .Entity<Foo>()
  .Property(e => e.Id)
  .UsePropertyAccessMode(PropertyAccessMode.Property);

// Enforce that a field was found and should be used
modelBuilder
  .Entity<Foo>()
  .Property(e => e.Id)
  .UsePropertyAccessMode(PropertyAccessMode.Field);

// Stop using fields even where they were found by convention
modelBuilder.UsePropertyAccessMode(PropertyAccessMode.Property)

// Enforce that all access goes thru fields (except shadow properties)
modelBuilder.UsePropertyAccessMode(PropertyAccessMode.Field)

PropertyAccessMode.Field
PropertyAccessMode.FieldDuringConstruction
PropertyAccessMode.Property

Also note that an atribute would allow you to use nameof to set the field


Generate convenience target alongside binary.sh target that changes the current working directory

Akin to theoremlp/rules_multitool#29, as an addition to the existing support in binary.bzl, it would be great to also have a convenience target that makes it easier to bazel run the generated @bundle//bin:{tool} target in the current directory. This can be worked around with a custom script and runfiles.bash, but it would be much easier for me to just bazel run @bundle//bin/{tool}:cwd or something like that. Kind of like this.
Not sure if you're interested in this, but the support in multitool has already been very helpful to me 🙌🏼

Can you give me an example of how you would use this with rules_ruby? Would you use it with a linter or a custom Ruby script? I'd use this as a test during the implementation.


Data Export failing

After requesting a data export for either the GZ101 or Hubble's Law activity, trying to obtain the exported data yields a "No export available for this classroom and assignment or the export failed" error. This error appears for both the CSV and Google Drive export options.
This was initially reported by a user trying to test out the system using a second account as a test student. I was able to recreate the error in a test classroom with myself as the only student.
Screenshot showing export was successfully processed and appears to be ready for download:

Resulting error message after either CSV or Google Drive options are clicked.

potentially a caesar issue.

@codydirks Could you try the system to see if it works with 2 students, 3 students, 4 students, or 5 students? We're trying to understand if this happens only if there's only 1 student.
From Julia's email, it seems she never tested it with all her students? Granted, I can imagine a lot of instructors would do this kind of test, so it will be important to make sure it works for only 1 student as well.

@trouille Is there a simple way to create fake users for the sake of testing (other than registering a bunch of new Zooniverse accounts with various emails)? I may ask the intro2astro channel to contribute some test classifications, but I'd like more control over exactly how many users are in the classroom.

@srallen do you have a good response (re: creating multiple users for testing purposes)?

I'm not really sure we need to test group sizes. I had commented to @trouille that if this was an issue just in testing that it's a low priority vs an issue in a classroom setting which would be high priority. I didn't mean to imply that group sizes are a variable in causing the issue. This failure sounds like a caesar issue. Basically the export to Google Sheets or download will fail because it does some parsing of the original caesar export CSV to make it more human-readable friendly. It'll fail if the original caesar CSV is empty. I think we've seen empty caesar CSVs when there are classifications made on the project outside of the classroom group. What would be helpful for testing:
A new classroom with a student joined. Have that student user classify not in the group. Then have that student classify in the classroom group. Request the export.
@amyrebecca is there any way we can check on the reductions for workflow ids 5521 and 5522 to see if there are any recent issues? Or is that difficult without a user group id?

@amyrebecca I'm not really sure how urgent this is since it sounds like it was a bug reported in a testing scenario initially. I can check with @trouille

Correct, it's not urgent (i.e., it can wait for a couple weeks). Tommy has provided the instructors 'sample' files to use with their classes. We do want to fix this in May so that any summer courses that want to use these materials can do that, starting in June. Just knowing what might be causing the issue is very helpful. I'll touch base in May with @amyrebecca to find time at that point to clear out the old extracts and do some tests with @codydirks at that time. Thanks all.

Once this pull request is merged, the behavior should be a lot better: https://github.com/zooniverse/caesar/pull/286

@codydirks I just tested this to confirm that it is fixed. I created a new classroom and had two separate tester accounts join as students. I had one student logged out classify on the galaxy classification project and the other classify logged in. The logged out student's classifications do not count toward the counts nor are included in the aggregated exports, but it is not breaking the exports any longer.
Could you confirm that this appears to be fixed for new classrooms? For old classrooms, we may need to clear out some bad data out of caesar. Do you know if there are any classrooms that have failing exports that we need to clean the data for?

Closing and will reopen if there is still an issue.


Automatic merging of vertices based on angle

In Better outline rendering with surface IDs we can see that using a surface ID buffer gives you more stable outlines vs just a normal buffer.
One problem with this is you might need to go through your geometry and merge a lot of vertices manually for faces that should all be considered one surface.
I think it should be possible to do this almost completely automatically. It would work like this:

Use an algorithm like ThreeJS EdgesGeometry that looks at the all the triangles, and determines if an edge should be drawn based on the angle of the two triangles it's connected to
If an edge does NOT pass this angle test, its vertices should be merged so that it appears as one surface, and the edge does not render
If an edge DOES pass the angle test, you should leave the vertices alone (or duplicate them if they are already merged?)

The only manual part about this is setting the threshold, but I think that's something that would be far easier to tweak than the normal buffer parameters.
If we can have a utility like that, then you'll be able to have very clean outlines by default, while still allowing you to edit individual edges in the model. It'd be the best of both worlds.

This is now resolved by: https://github.com/OmarShehata/webgl-outlines/tree/main/vertex-welder#vertex-welder
However, there's a number of caveats which I have listed at the end of that README. The biggest one is that texture coordinates get messed up when you delete vertices.


Remove .ToLower() on URLs to preserve case sensitive parameters

Fixes #45

Thanks for the contribution!

Created release https://github.com/nref/BrowseRouter/releases/tag/0.12.4


Discussion: (suggested) mappings for treesitter and remote

Remote
gs, gS (linewise), g<c-s> (blockwise)? Do we need linewise (and blockwise) by default?
Treesitter
Dedicated linewise keys would be great, since they are much more efficient (filtering).
gy/gY, ga/gA, gb/gB, gl/gL... ?

gy, gY - the only ones that have at least some mnemonic value ("y" looks like a branching tree). Note: If "clever-y" is configured, one can use <alt-y> to yank the current selection (:h v_META).

ga/gA - comfortable, work fine with  ; and , (different hand). No mnemonics. "clever-a" is awkward with the pinky.

Remote + treesitter
What about shortcuts, basically require'leap.remote'.action { input = '<treesitter-trigger>' }?

[Disclaimer: I'm new to leap and have only started using it since yesterday 😄]
With regard to remote, I'm not sure you need line-wise or block-wise by default. The documentation encourages users to use normal remote mode versus operator remote mode to allow greater flexibility with making selections anyways. And for those that use the operator remote mode solely (like me), I still don't have a problem making line-wise selections using standard vim methods. And in the worse case, I can always just press V before selecting what I want. So, I don't think it's worth taking up more keys for something that's probably not really needed. And, for that reason, I've chosen to stick with r in operating remote mode only, so I don't waste another normal mode mapping. My brain is wired for operator then motion, so I'll never get used to the normal remote mode. Plus, it doesn't work well with the tip #1 for auto pasting after a yank.
With regards to treesitter, I lean towards to gy/gY for the slight mnemonic (and ga/gA are used by mini.align in my config). But, again in the spirit of minimizing how many keys need to be defined, I've opted only for the non-line-wise binding to <C-Space>. I picked that binding up from my LazyVim days and it has stuck with me ever since. While I think line-wise treesitter offers great utility, when I want to use it, I just press V before <C-Space>.
Finally, with regards to remote and treesitter, I don't need any shortcuts as the above compose well. If I want to do a remote yank of a line-wise treesitter selection, then it's yr{leap}V<C-Space>{leap}.  Obviously, I'm a fan of minimizing the amount of keys consumed by mappings.
My leap configuration for reference and the basis for my comments above (not shown, I use LeapBackdrop to make the labels easier to read instead of reverse text in a single cell):
require("leap").opts.equivalence_classes = { " \t\r\n", "([{", ")]}", "'\"`" }
require("leap.user").set_repeat_keys("<enter>", "<backspace>")

-- I prefer bi-directional searches as the downsides are mostly compensated
-- for by the above set_repeat_keys. I lose dot-repeats, but I'm not using
-- them anyways because I don't want repeat.vim. The other downside is
-- that we don't get as many autojumps, but we'll see how that pans out.
--
-- I had to move mini.surround to gz to make room for this binding.
vim.keymap.set({ "x", "n", "o" }, "s", function()
  require("leap").leap({
    target_windows = { vim.api.nvim_get_current_win() },
  })
end)

-- With bi-directional searching enabled, I use this binding to search other
-- windows. I originally combined them all into one binding to search all
-- windows, but one of leap's benefites is that first autojump, so this helps
-- improve the odds by limiting matches.
vim.keymap.set({ "x", "n", "o" }, "S", function()
  require("leap").leap({
    target_windows = require("leap.util").get_enterable_windows(),
  })
end)

-- I only use remote operations via operating pending mode. This allows me to
-- save wasting another key in my normal mode mappings.
vim.keymap.set({ "o" }, "r", function()
  require("leap.remote").action()
end)

-- This mapping is what LazyVim uses for the built-in treesitter plugin
-- incremental selection, so using it doesn't waste another key in my
-- configuration as I already had this one bound to the same function..
vim.keymap.set({ "n", "x", "o" }, "<C-Space>", function()
  require("leap.treesitter").select()
end)

-- Automatically paste when doing a remote yank operation.
vim.api.nvim_create_augroup("LeapRemote", {})
vim.api.nvim_create_autocmd("User", {
  pattern = "RemoteOperationDone",
  group = "LeapRemote",
  callback = function(event)
    vim.notify(event.data.register)
    -- Do not paste if some special register was in use.
    if vim.v.operator == "y" and event.data.register == "+" then
      vim.cmd("normal! p")
    end
  end,
})


There is such an error in the logs

warn: Microsoft.EntityFrameworkCore.Model.Validation[30000]
No type was specified for the decimal column 'Rate' on entity type 'TaxRate'. This will cause values to be silently truncated if they do not fit in the default precision and scale. Explicitly specify the SQL server column type that can accommodate all the values using 'HasColumnType()'.  @thiennn @alinooshabadi @mickey35vn

I Solved The Problem That Must Be That Way
[Column(TypeName = "decimal(18,2)")]
public decimal Price { get; set; }


feat : added scroll bar component

I’ve created the scroll bar component, along with an example to demonstrate its functionality. Please let me know if it meets your expectations. @yashchaudhari008 I'm eager to contribute further to your project and would appreciate your consideration for sponsorship to support my work. I look forward to your feedback. could you also be kind enough to consider my PR under hacktoberfest2024

@yashchaudhari008 k i'll work on it . could you please considers this PR under #hacktoberfest-accepted , #hacktoberfest2024 , gssoc2024-ext

@yashchaudhari008 i have updated it . See if its correct. Could you please consider this PR under hacktoberfest-accepted  , gssoc2024-ext

@yashchaudhari008 . Review my PR and merge . Consider this under hactoberfest-accepteed , gssoc-ext.

@abishek1740P could you please send before and after screenshots

BEFORE:

AFTER:

Scroll Bar , Changes when you apply the scrollbar.scss

Does it work on app widgets?


Fixes

What's up with the test failure?  Seems related to the HikariConfig changes possibly?
com.zaxxer.hikari.TestMetrics
testHealthChecks(com.zaxxer.hikari.TestMetrics)  Time elapsed: 2.021 sec  <<< ERROR!
java.lang.NullPointerException: null
	at com.zaxxer.hikari.TestMetrics.testHealthChecks(TestMetrics.java:145)

Selectively merged.


shell mode: implement clear

Looks like we have to look in the terminfo database on clear for the right sequence to send.

@crawshaw I want to look into this. It would take time though as I am completely unfamiliar with project.

@vbmade2000 go for it! No rush at all.

on linux and OSX /usr/bin/clear does the right thing -- is this necessary?


Throws [Error: Number of columns on line xxx does not match header] for the empty line at the end of the file.

I was uploading this data set (url: http://www.bart.gov/dev/schedules/google_transit.zip) with version 0.4.5. It threw the followinf error when processing transfers.txt.
[Error: Number of columns on line 8 does not match header]
I checked the file and saw line 8 is an empty line at the end of the file.
I found this issue also appears in version 0.1.1
I was uploading san-francisco-municipal-transportation-agency (with version 0.1.1 and 0.1.0) and it threw
san-francisco-municipal-transportation-agency: Importing data - routes
san-francisco-municipal-transportation-agency: Importing data - shapes
[Error: Number of columns on line 104007 does not match header]

Again, line 104007 appeared to be an empty line at the end of the file shapes.txt

This issue should be resolved with the latest version of node-gtfs. Please reopen if you experience the same issue.


A Typing Game

I would like to contribute as a GSSOC participant by adding a typing game to this project. Please assign me this issue

Can you show me the demo @cryptofox17 ?

@urvashi-code1255  sure. So here is what i have worked on so far : https://cryptofox17.github.io/typingGame/
I will be using API to generate random words and also improve the UI to make to look more interactive

@cryptofox17 That's why I asked for the demo!
A very similar typing speed tester game is already present in the project!


Add Immersive Reader

The Immersive Reader gets a token from the cloud, then uses that token to make calls to the SDK
I did some initial cleaning of the tutorial text, but I think there's a lot of formatting that I missed. It should be easy to add regexes to pick off each case
Once I get the cloud going I'll drop an upload target!
I'll make a separate PR to make it work nicely on skillmap -- should only be adjusting the button

Just realized I never dropped gifs >>

🚨🚨🚨 Uploadtrg here!!!!!!
https://arcade.staging.pxt.io/app/764b6aa1736bcd8c2d8708b50723a0fa460b7511-56cb6c0231
running with staging cloud, has all changes (including new error ticks that i'm gonna upload)
lemme know what you think!

Looks great. Ship it.


Must require manually after gem rename

After renaming the gem to checkr-rb, you now must manually require Checkr to use it.
To reproduce on a fresh install:

Add checkr-rb to the Gemfile

$> rails c

rails c> Checkr
NameError: uninitialized constant Checkr

rails c> require 'checkr'
rails c>Checkr
Checkr

It looks like Bundler is no longer autloading. It looks like it autoloads based on gem name. Not sure of the best way to tell it how to load the gem properly.
In the meantime, we may consider updating the Readme to reflect needing to require checkr
require 'checkr'
Checkr.configure do |c|
  c.api_key   = ENV['CHECKR_API_KEY']
end

A suggested fix:
Rename the gem to


Fix using the right functions for retrieving physical device info

Changelog:
- Fixed bug where the wrong functions were used for retrieving physical device info.
- Fixed minor bug in retrieving features from the physical device.

Just a small fix for a bug that was giving validation errors.

Always like getting closer to the goal of being validation error free!


Updated tflint support for new JSON format.

Recent versions of tflint have changed the return values and output format. This PR updates the execution and parsing support for the new format.

Exit codes for errors properly handled.
Issues parsed for the new JSON format.

Tested against tflint 0.13.4 on MacOS.

Any chance to get this merged? 🙏

@mauve @robikovacs I don't mean to be 'that guy' but in #229 (which this PR fixes) it was mentioned we could get a release with these fixes if they properly handled the new tflint error codes, which I think I do here. This is sort of a painful thing where it'd be nice to get a fix in. Is there a possibility we could see this get merged and released? If not, is there something else that needs to be done here that I could help with to allow that to happen?

We just released v2.0.0-rc.1 of the extension. The main features include:

Added syntax support for 0.12
Added terraform-ls usage by default (currently on 0.3.0, which offers basic provider code completion)

You can find additional information and specifics in the release notes and CHANGELOG.
With this release we expect that many of the prior issues and PRs are no longer relevant or have been addressed, and are therefore being closed. If you feel the action taken on an issue or PR is in error, please comment as such and we can figure out the appropriate way to address it.
We plan to add the final 2.0.0 release to the marketplace soon, but are actively seeking your feedback now on the release candidates. You can download the .vsix from the releases page and manually install it in VS Code to try it out.


SSL BOSH endpoint does not appear to work

I'm troubleshooting switching my BOSH endpoint to SSL. I can connect fine over SSL with Pigin, as well as telnet, but stanza.io appears to hang.
      var client = XMPP.createClient({
            jid: from_JID,
            password: 'password',
            transport: 'bosh',
            boshURL: config.get('xmpp.bosh_url') // https://domain.com/http-bind

        });

Can I rule out stanza.io? Am I doing something wrong?

Is this in browser or node?
Is it a self-signed or any type of cert that would require accepting a security prompt?
Do you have CORS enabled?

node.js server-side. Standard cert. CORS enabled.

I have what appears to be the same problem with node-xmpp-client, which I use exclusively for prebinding.

Gut feeling is still for a cert validation issue. Does your server have its cert installed properly with cert + chain? Especially if using a CA with an intermediary cert.

I did that today. https://idelog.me Would you able to verify? I just followed the AWS Load balancer instructions... Don't know much about certs. :)

Yep, this is what node is giving:
 [Error: UNABLE_TO_VERIFY_LEAF_SIGNATURE]

You've got two intermediary certs (Gandi Standard SSL CA 2, and USERTrust RSA Certificate Authority).
I'd check that you have those two included in your PEM bundle, and in the right order (your cert at the top, followed by Gandi, then USERTrust).

Awesome thank you - I do not.

That fixed it. Sorry to have bothered you with that. Thank you.


Add Java implementation for ordered flag

Thanks!
I'll enable an integration test for ordered support in Archery later.


Builds Failing On UTF Step "Error Receiving Header"

Latest builds for J1939 and Modbus Modules are both failing at run-utf step, reporting the following error.
Error receiving header: Header bytes missing, received 0 of 4 bytes
I am able to run the same labview-cli step from the command line on a virtual machine with the following packages without any errors.
LV CLI <IP_ADDRESS>
CLI Common Steps <IP_ADDRESS>

The build machines are using LV CLI <IP_ADDRESS> and common steps <IP_ADDRESS>.
I'll try updating the build machines.

@jacobson3  Looks like that fixed it, at least for Modbus.

@jacobson3  - J1939 also makes it through.

Awesome, thanks for kicking off the builds as well.

No problemo.  I will mark this as closed.


Hovering a setting does not wrap the description popup in the grid editor build

VS Code version: Code - Insiders 1.24.0-insider (41a7c4976ebd1f6ced20c034485300f46ab1829f, 2018-05-29T06:09:34.618Z)
OS version: Windows_NT x64 10.0.16299

#50458
Pretty bad one, appears to be a regression only in this build:

@joaomoreno this is because white-space:nowrap (here) seems to travel all the way down to the editor. Seems a bit weird that a component down in the tree has to unset this property, but maybe that is the way to go?

I can take this.


Transforming Handler

Is there currently a way (and if not, a plan) for supporting any other Monad besides Handler when resolving queries / mutations? servant accomplishes through a monad morphism. I'd really like to be able to further transform Handler. If this is not supported, and there is no current architecture for doing so, I wouldn't mind giving this a shot. Do advise. cc @jml

All through Handler as of today. What other monad do you want to use?
On Fri, 1 Jun 2018 at 01:49, David Johnson<EMAIL_ADDRESS>wrote:

Is there currently a way (and if not, a plan) for supporting any other
Monad besides Handler when resolving queries / mutations? servant
accomplishes through a monad morphism. I'd really like to be able to
further transform Handler. If this is not supported, and there is no
current architecture for doing so, I wouldn't mind giving this a shot. Do
advise.
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
https://github.com/haskell-graphql/graphql-api/issues/185, or mute the
thread
https://github.com/notifications/unsubscribe-auth/AAHq6us7NjYJU5kXN_A4RYkjItNhX3Ioks5t4I-PgaJpZM4UV8Am
.

I'm not rejecting your use case—it's a good point. I'm just curious as to the specific motivation.
By all means, do give this a shot.

For example, ReaderT r IO would be a monad I’d like to use. Would it be as simple as making an instance for HasResolver?

I genuinely don’t know. I’d look at what servant does and try to copy from
that.
On Fri, 1 Jun 2018 at 10:37, David Johnson<EMAIL_ADDRESS>wrote:

For example, ReaderT r IO would be a monad I’d like to use. Would it be as
simple as making an instance for HasResolver?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/haskell-graphql/graphql-api/issues/185#issuecomment-393828535,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AAHq6uAgkThzowtmUGLM61gSFOkGszhxks5t4QtegaJpZM4UV8Am
.


Unauthorized Error on IPostToBot.PostAsync

Bot Info

SDK Platform: .NET
SDK Version: <IP_ADDRESS>
Active Channels: Slack
Deployment Environment:  Azure

Issue Description
We've had a bot in production for several months that now just suddenly stopped working. It works normally on the Bot Framework Emulator, but on Azure, it returns a 500 Internal Server Error (see stack trace below)
Code Example
The bot authenticates fine, but it crashes as soon as it attempts to go into a Dialog.
if (activity.Type == ActivityTypes.Message)
{
           await Conversation.SendAsync(activity, () => new RootDialog());
 }

That ends up crashing on the IPostToBot.PostAsync call:
public class PostUnhandledExceptionToUser : IPostToBot
    {
        private readonly ResourceManager resources;
        private readonly IPostToBot postToBot;
        private readonly IBotToUser botToUser;
        private readonly TraceListener trace;

        public PostUnhandledExceptionToUser(IPostToBot inner, IBotToUser botToUser, ResourceManager resources, TraceListener trace)
        {
            SetField.NotNull(out this.postToBot, nameof(inner), inner);
            SetField.NotNull(out this.botToUser, nameof(botToUser), botToUser);
            SetField.NotNull(out this.resources, nameof(resources), resources);
            SetField.NotNull(out this.trace, nameof(trace), trace);
        }

        async Task IPostToBot.PostAsync(IActivity activity, CancellationToken token)
        {
            try
            {
                await this.postToBot.PostAsync(activity, token); // <---- Crashes here
            }
            catch (Exception ex) {......}}

Here's the Stack Trace for the error thrown:
Unauthorized at Microsoft.Bot.Connector.MicrosoftAppCredentials.<RefreshTokenAsync>d__34.MoveNext()
--- End of stack trace from previous location where exception was thrown ---

at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Microsoft.Bot.Connector.MicrosoftAppCredentials.<GetTokenAsync>d__27.MoveNext()
--- End of stack trace from previous location where exception was thrown ---

at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Microsoft.Bot.Connector.MicrosoftAppCredentials.<ProcessHttpRequestAsync>d__26.MoveNext()
--- End of stack trace from previous location where exception was thrown ---

at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.ValidateEnd(Task task)
at Microsoft.Bot.Connector.BotState.<GetConversationDataWithHttpMessagesAsync>d__8.MoveNext()
--- End of stack trace from previous location where exception was thrown ---

at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Microsoft.Bot.Connector.BotStateExtensions.<GetConversationDataAsync>d__7.MoveNext()
--- End of stack trace from previous location where exception was thrown ---

at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Microsoft.Bot.Builder.Dialogs.Internals.ConnectorStore.<Microsoft-Bot-Builder-Dialogs-Internals-IBotDataStore<Microsoft-Bot-Connector-BotData>-LoadAsync>d__2.MoveNext() in D:\a\1\s\CSharp\Library\Microsoft.Bot.Builder\ConnectorEx\BotData.cs:line 203
--- End of stack trace from previous location where exception was thrown ---

at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Microsoft.Bot.Builder.Dialogs.Internals.CachingBotDataStore.<LoadFromInnerAndCache>d__11.MoveNext() in D:\a\1\s\CSharp\Library\Microsoft.Bot.Builder\ConnectorEx\BotData.cs:line 372
--- End of stack trace from previous location where exception was thrown ---

at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Microsoft.Bot.Builder.Dialogs.Internals.CachingBotDataStore.<Microsoft-Bot-Builder-Dialogs-Internals-IBotDataStore<Microsoft-Bot-Connector-BotData>-LoadAsync>d__9.MoveNext() in D:\a\1\s\CSharp\Library\Microsoft.Bot.Builder\ConnectorEx\BotData.cs:line 350
--- End of stack trace from previous location where exception was thrown ---

at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Microsoft.Bot.Builder.Dialogs.Internals.BotDataBase`1.<LoadData>d__16.MoveNext() in D:\a\1\s\CSharp\Library\Microsoft.Bot.Builder\ConnectorEx\BotData.cs:line 553
--- End of stack trace from previous location where exception was thrown ---

at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Microsoft.Bot.Builder.Dialogs.Internals.BotDataBase`1.<LoadAsync>d__8.MoveNext() in D:\a\1\s\CSharp\Library\Microsoft.Bot.Builder\ConnectorEx\BotData.cs:line 514
--- End of stack trace from previous location where exception was thrown ---

at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Microsoft.Bot.Builder.Dialogs.Internals.DialogTaskManagerBotDataLoader.<LoadAsync>d__11.MoveNext() in D:\a\1\s\CSharp\Library\Microsoft.Bot.Builder\ConnectorEx\BotData.cs:line 473
--- End of stack trace from previous location where exception was thrown ---

at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Microsoft.Bot.Builder.Dialogs.Internals.PersistentDialogTask.<Microsoft-Bot-Builder-Dialogs-Internals-IPostToBot-PostAsync>d__3.MoveNext() in D:\a\1\s\CSharp\Library\Microsoft.Bot.Builder\Dialogs\DialogTask.cs:line 478
--- End of stack trace from previous location where exception was thrown ---

at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Microsoft.Bot.Builder.Dialogs.Internals.ExceptionTranslationDialogTask.<Microsoft-Bot-Builder-Dialogs-Internals-IPostToBot-PostAsync>d__2.MoveNext() in D:\a\1\s\CSharp\Library\Microsoft.Bot.Builder\Dialogs\DialogTask.cs:line 403
--- End of stack trace from previous location where exception was thrown ---

at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Microsoft.Bot.Builder.Dialogs.Internals.SerializeByConversation.<Microsoft-Bot-Builder-Dialogs-Internals-IPostToBot-PostAsync>d__4.MoveNext() in D:\a\1\s\CSharp\Library\Microsoft.Bot.Builder\ConnectorEx\PostToBot.cs:line 129
--- End of stack trace from previous location where exception was thrown ---

at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.GetResult()
at Az.Eller.eSMS.WebApi.Extensions.PostUnhandledExceptionToUser.<Microsoft-Bot-Builder-Dialogs-Internals-IPostToBot-PostAsync>d__5.MoveNext() in C:\Users\muebele\Documents\SecretSauce\eSMS\Az.Eller.eSMS.WebApi\Extensions\BotDialogs.cs:line 507

The Exception message just says "Unauthorized" so we're not sure what's going wrong since that happens after the bot has successfully authenticated and just last week there was no problem at all.
Any insight into this issue would be appreciated, thanks!

Is the time on your server set correctly?
What is your BotHandle and MicrosoftAppId?

Handle: esmsbot_dev_01
App Id: ba0eae0f-f0e5-4a5e-9ec6-143d1447b463
For the server, we're using an Azure web app, which I believe the time automatically configures to UTC?

Does restarting the app service fix the issue?

We've tried restarting the service - no change in behavior unfortunately.

Is this bot using the default state service?  This service is being deprecated: https://blog.botframework.com/2018/04/02/reminder-the-bot-framework-state-service-has-been-retired-what-you-need-to-know/
Here is a blog that describes how to use Bot Builder Azure Extensions to implement a custom state:
https://blog.botframework.com/2017/07/18/Saving-State-Azure-Extensions/

This should not be causing the Unauthorized exception you are seeing, but if you ARE using the default state service and that is where the exception is occurring, then implementing a custom state client will "fix" the issue.

What exactly is the default state service and how can I tell if I'm using it? We store all of our bot's data internally, but we do use serialized class variables to manage conversation flow; I didn't think that was part of the state service, but correct me if I'm wrong!

i'm confused about why the bot would suddenly stop working, and why it would be throwing unauthorized exceptions.  Are you using v<IP_ADDRESS> of Microsoft.Bot.Builder AND  v<IP_ADDRESS> of Microsoft.Bot.Connector ?
Dialog fields are persisted in the state store, as well as UserData, ConversationData and PrivateConversationData.  If you have not implemented a custom state client, then you are using the default state service.  More information can be found here: https://docs.microsoft.com/en-us/azure/bot-service/dotnet/bot-builder-dotnet-state

Yes, we're on v<IP_ADDRESS> on both.
I'm still not entirely sure what exactly is going wrong, but I've identified the source of the problem at least:
We're using our own customized mechanism for authentication - rather than storing the app id and password in the web.config file, we pull them dynamically from a secure storage and match them against the request (we have multiple bots running on the same code base, so we have to be able to authentication for multiple bots) .
I don't know why, but if I replace this with the web.config method of authentication, then the bot functions properly as before. (our logs show that our calls are pulling the correct values for the App Id and Password)
The code we're using can be seen below:
[BotAuthentication(CredentialProviderType = typeof(CustomCredentialProvider))]
    public class BotFrameworkController : ApiController
    {
        BotService BotService = new BotService();
        private static bool configured = false;

        /// <summary>
        /// POST: api/BotFramework
        /// Receive a message from a user and reply to it
        /// </summary>
        public async Task<HttpResponseMessage> Post([FromBody]Activity activity)
        {
            if (!configured)
            {
                var builder = new ContainerBuilder();

                // Get authentication values
                string MicrosoftAppId = await BotService.GetMicrosoftAppIdAsync();
                string MicrosoftAppPassword = await BotService.GetMicrosoftAppPasswordAsync();
                builder.Register(c => new MicrosoftAppCredentials(MicrosoftAppId, MicrosoftAppPassword)).SingleInstance();

                // Override default exception handling with our own class
                builder.RegisterModule(new DefaultExceptionMessageOverrideModule());

                builder.Update(Conversation.Container);

                configured = true;
            }

        if (activity.Type == ActivityTypes.Message)
        ....
     }

And the CustomCredentialProvider class:
/// <summary>
    /// Custom class for authenticating requests to our bot
    /// </summary>
    public class CustomCredentialProvider : ICredentialProvider
    {

        /// <summary>
        /// Verifies app id
        /// </summary>
        public async Task<bool> IsValidAppIdAsync(string appId)
        {
            BotService botService = new BotService();
            string MicrosoftAppId = await botService.GetMicrosoftAppIdAsync(); // Pulls our app id from secure location

            return await Task.FromResult(appId == MicrosoftAppId);
        }

        /// <summary>
        /// Verifies password
        /// </summary>
        public async Task<string> GetAppPasswordAsync(string appId)
        {
            BotService botService = new BotService();
            string MicrosoftAppPassword = await botService.GetMicrosoftAppPasswordAsync(); // Pulls our app password from secure location

            return await Task.FromResult(MicrosoftAppPassword);
        }
}

Replaced my configuration code with what you have in Global.Asax.cs and it's working again! Thanks so much for the help!


Add missing move/toggle methods & fix position property

A few fixes for curtains. Add missing methods (move/toggle) and fix position/state values

I would like to invite you to be a maintainer of this project. If you would like to, please let me know! 🙏

I would like to invite you to be a maintainer of this project. If you would like to, please let me know! 🙏

That would be great!

That would be great!


Add Se7en (1995)

Checklist for submitting a pull request to Movies For Hackers:

[x] I have carefully read and comply with the Contributing Guidelines of this repo.
[x] I have searched the PRs of this repo and believe that this is not a duplicate.

Title: Se7en
Link: https://www.imdb.com/title/tt0114369
Genre: Crime/Drama/Mystery
Rating: 8.6/10

Description: Two detectives, a rookie and a veteran, hunt a serial killer who uses the seven deadly sins as his motives.

Closes https://github.com/k4m4/movies-for-hackers/issues/230

a decent movie but what makes it "for hackers"?

@k4m4 can this be closed?


PR: Add support for eslint-plugin-compat

This eslint plugin lints against APIs that are only supported by target browsers 🎉 Would a PR for this be welcome?
Here's a demo of it in action

Hi @amilajack -- this repo is deprecated in favor of https://github.com/walmartlabs/eslint-config-walmart Maybe ask there and see if there are some takers? Thanks!

@ryan-roemer thanks for the heads up!


how to active mode??

Hi~
I am using vscode-sftp very well.
How do I set it to acitve mode?
Thank you for making a good program.

SFTP extension is not working for me and I think it is because I can not set active mode. Is possible to set active ftp mode via config settings?
Thanks.

This SFTP is woking fine with passive mode. But When I try with active mode there is no option to make it.


Allow revoke button to be placed manually on page

I've only just switched to using the Opt-In functionality, and due to GDPR, have to enable the revoke button.
The button and its placement cause some nuisance and present all kinds of issues with many layouts.
For my clients using WordPress, I've found a plugin that will allow usage of a shortcode, which can be manually placed in the footer, the content of any page, etc. - site visitors are informed that they can revoke their consent "using the link provided on page x" for example.
It would be really helpful if CC came with a similar option. Specifically for the revoke button NOT to be displayed all the time at its fixed (and somewhat inflexible) position, but rather allowing for manual placement of a revoke link freely, which will then trigger the revoke button event.
Should such functionality already exist, I haven't found it in the documentation :/

I was looking for something like this as well!
For now I'm using a solution of a custom button of mine that simple deletes the cookie 'cookieconsent_status'. To be able to rely on the name of the cookie in the future (even if the default changes with an update) I explicitly set the config value cookie.name to 'cookieconsent_status'

This feature would be great!
I thought it would be as simple as invoking the hook/triggering the event when I need it (from a button in the footer of my website) but I couldn't figure out how.
I've decided not to display the revoke button on mobile for now because I have CTAs fixed to the bottom.
@media (max-width: 576px) {   .cc-revoke {     display: none   } }


Error when executing dpex implementation of PCA workload

The numba-dpex implementation of the PCA algorithm has several calls that are currently not supported - dpnp.mean(axis=0), dpnp.linalg.eigh, etc., inside a dpjit decorated function. These functions need to supported to run PCA workload in dpbench.
How to reproduce:
Follow instructions to setup dpbench
Run PCA - python -c "import dpbench; dpbench.run_benchmark("pca")

@adarshyoga can you please list the functions currently not supported in dpjit. I am marking this issue as a future enhancement, will be good to add all details here.


Using CocoaPod to install, UIView does not have a member named 'makeToast'

I integrated the Cocoapod and when trying call the makeToast method like so:
self.view.makeToast(message: "test", duration: GlobalVars.TOAST_DURATION, position: GlobalVars.TOAST_POSITION)
I receive a warning that says 'UIView' does not have a member named 'makeToast'. I did the import ToastSwift for that class as well.
Also, it does not recognize the constants, HRToastPosition.
How do I fix this?

~> 0.1.3 has resolved some problem.

I am still having the same issue, even after the 0.1.3 update.

I'm having this issue too.

Installed with cocoapod
import ToastSwift in one of my view controllers
self.view.makeToast("blah") inside viewDidLoad() throws error: "UIView does not have a member named makeToast"

i also have this issue. how to fix it?

Having the same problem. Did same steps as @germanger

Use pods need new api like Toast.makeToast(xxxView, msg: msg)... so don't use pods now.I will design new api recently.


List of people whose feedback I need

 @blublairies deeply understands the relationship between "emotional" and "rational" worlds, between spiritual & scientific. "it's not that they might be compatible" she told me, when this idea was nascent and fragile in my mind, "they can not~ NOT work together" tweet.
I loved this flip. It wasn't that "maybe" they have some overlap, it's that the strongest possible truth is that which is compatible. This is an important theme in the book for me and I value the feedback of those who get this.
 @_____moonman was the first to see what I was doing with "the fiction / non fiction" book. It was validating to hear that he had exactly the same idea before, and ALSO i love that it itself was part of the work, part of the prediction. His was the spark that made me really believe this, and I love it so much

Contributors

ScarletAstrorum, for the description "open source guide to the future", most concise way to explain this


Ability to step over code marked with await

Observatory has this feature, and it's really useful. Would like to step over a line with await, like any other line.

for searching: async

Fixed (by @johnmccutchan)


Unified enable minify field name

https://github.com/gohugoio/hugo/blob/c6b3887696162335d806ff25e9b9db27d73611de/docs/content/en/hugo-pipes/scss-sass.md?plain=1#L32-L33
https://github.com/gohugoio/hugo/blob/c6b3887696162335d806ff25e9b9db27d73611de/docs/content/en/hugo-pipes/js.md?plain=1#L38-L39
https://github.com/gohugoio/hugo/blob/e402d91ee199afcace8ae75da6c3587bb8089ace/docs/content/en/hugo-pipes/babel.md?plain=1#L49-L50
I think can provide united minify flag control minify compiled result

@bep

if possible, i think use --minify (hugo --minify) command arguments control all CSS and JS compression, improve finally bundle size
{{ resources.Get "..." | resources.Minify }}

but, on development not need minify javascript and stylesheet

I hope
NOT production, enable sourcemaps and disable minify by default
production, disable sourcemaps and enable minify by default

@bep


DO guide step 3 using launch-code-server-linode.sh

Step 3 in Digital Ocean guide use launch-code-server-linode.sh instead of launch-code-server.sh
https://github.com/cdr/deploy-code-server/blob/main/guides/digitalocean.md

thanks for reporting!


Connect timeline to search result data

Need the timeline to get dynamic data from elastic search the same as the results page

Work with Chris seems promising, adding a watcher to the data allows it to be accessed in javascript and then transferred to the vis timeline.

Waiting pull #81