calculate the perplexity on penntreebank using LSTM keras got infinity

I am very new to KERAS, and I use the dealt dataset from the RNN Toolkit and try to use LSTM to train the language model
I have problem with the calculating the perplexity though. It always get quite large negative log loss, and when using the exp function, it seems to get the infinity, I got stuck here.
Below is my model code, and the github link( https://github.com/janenie/lstm_issu_keras ) is the current problematic code of mine. Can someone help me out?
the test_y data format is word index in sentences per sentence per line, so is the test_x.
class LSTMLM:
def init(self, input_len, hidden_len, output_len, return_sequences=True):
self.input_len = input_len
self.hidden_len = hidden_len
self.output_len = output_len
self.seq = return_sequences
self.model = Sequential()
def build(self, maxlen=50, dropout=0.2):
    self.model.add(Embedding(self.input_len, self.hidden_len, input_length=maxlen))
    self.model.add(LSTM(output_dim=self.hidden_len, return_sequences=True))
    #self.model.add(Dropout(dropout))
    self.model.add(TimeDistributedDense(self.output_len))
    self.model.add(Activation('softmax'))
    self.model.compile(loss='categorical_crossentropy', optimizer='rmsprop')

def train(self, train_x, train_y, dev_x, dev_y, batchsize=16, epoch=1):
    hist = self.model.fit(train_x, train_y, batch_size=batchsize, nb_epoch=1, \
                    show_accuracy=True, validation_data=(dev_x, dev_y))
    print hist.history

def saveModel(self, save_file):
    self.model.save_weights(save_file)

def computePPL(self, test_x, test_y, maxLen=100):
    predictions = self.model.predict(test_x)
    test_num = len(test_y)
    maxlen = predictions.shape[1]
    ppl = 0.0
    total_words = 0
    for i in xrange(test_num):
        pred_idx = test_y[i]
        #print np.max(pred_idx)
        sent_len = len(test_y[i])
        padding = maxlen - sent_len
        for j in xrange(sent_len):
            prob_ = predictions[i, j+padding, pred_idx[j]]
            ppl -= np.log(prob_)
        total_words += sent_len
    return np.exp(ppl)/(float(total_words))

Please make sure that the boxes below are checked before you submit your issue. Thank you!

You can add perplexity as a metric as well:
def perplexity(y_true, y_pred, mask=None):
    if mask is not None:
        y_pred /= K.sum(y_pred, axis=-1, keepdims=True)
        mask = K.permute_dimensions(K.reshape(mask, y_true.shape[:-1]), (0, 1, 'x'))
        truth_mask = K.flatten(y_true*mask).nonzero()[0]  ### How do you do this on tensorflow?
        predictions = K.gather(y_pred.flatten(), truth_mask)
        return K.pow(2, K.mean(-K.log2(predictions)))
    else:
        return K.pow(2, K.mean(-K.log2(y_pred)))

though, this doesn't work on tensor flow because I'm only using Theano and haven't figured out how  nonzero() works in tensorflow yet.
In general, though, you average the negative log likelihoods, which forms the empirical entropy (or, mean loss).  This is the quantity used in perplexity.  Additionally, perplexity shouldn't be calculated with e.  It should be calculated as 2 ** L using a base 2 log in the empirical entropy.
See Socher's notes here, the wikipedia entry, and a classic paper on the topic for more information.

@braingineer Thanks for the code! Unfortunately, the log2() is not available in [Keras' backend API] (https://keras.io/backend/). Is there another way to do that? (Or is the log2()going to be included in the next version of Keras?)

hey @cheetah90
rather than futz with things (it's not implemented in tensorflow), you can approximate log2.   log_2(x) = log_e(x)/log_e(2)
so, precompute 1/log_e(2) and just multiple it by log_e(x).
the following should work (I've used it personally):
oneoverlog2 = 1.442695
result = K.log(x)*oneoverlog2

Hi @braingineer. Thanks! Yeah, I should have thought about that myself :)
Btw, I looked at the Eq8 and Eq9 in Socher's notes, and actually implemented it differently.
def perplexity(y_true, y_pred):
    time_steps = y_pred.shape[0]
    cross_entropy_over_time = - K.dot(T.flatten(y_true), T.log2(T.flatten(y_pred))) / time_steps
    return pow(2, cross_entropy_over_time)

(Of course, my code has to import Theano which is suboptimal in this case. But let me know if there is other way to leverage the T.flatten function since it's not in the Keras' backend either)
Let me know what you think! Thank you!

Hi @cheetah90
That won't take into account the mask. It's for fixed-length sequences.
There's a nonzero operation that requires theano anyway in my version. Now that I've played more with Tensorflow, I should update it. I have some deadlines today before I have time to do that, though.  I'll try to remember to comment back later today with a modification

That's right! It's for the fixed-length and thanks for telling me what the Mask means - I was curious about that so didn't implement it. Yeah I will read more about the use of Mask! But anyway, I think according to Socher's note, we will have to dot product the y_pred and y_true and average that for all vocab in all times.

Hi @braingineer
Thanks for sharing your code snippets! I went with your implementation and the little trick for 1/log_e(2). Seems to work fine for me. I wondered how you actually use the mask parameter when you give it to model.compile(..., metrics=[perplexity])?

Accordings to the Socher's notes that is presented by @cheetah90 , could we calculate perplexity by following simple way?
def perplexity(y_true, y_pred):
        cross_entropy = K.categorical_crossentropy(y_pred, y_true)
        perplexity = K.exp(cross_entropy)
        return perplexity

Hi, everyone.
I implemented perplexity according to @icoxfog417 's post, and I got same result - perplexity got inf.
But in my case, I set perplexity as a metrics in model.compile(), then perplexity always got inf on training, and got some reasonable value on validation.
Does anyone solve this problem or implement perplexity in other ways?

Hi.
I found a simple mistake in my code, it's not related to perplexity discussed here.
After changing my code, perplexity according to @icoxfog417 's post works well.
Just a quick report, and hope that anyone who has same problem will  resolve.

Ok so I implemented the perplexity according to @icoxfog417 , now i need to evaluate the final perplexity of the model on my test set using model.evaluate(), any help is appreciated.

@janenie Do you have an example of how to use your code to create a language model and check it's perplexity?

I implemented a language model by Keras (tf.keras) and calculate its perplexity. Please refer following notebook (it uses my preprocessing library chariot).
language modeling

Accordings to the Socher's notes that is presented by @cheetah90 , could we calculate perplexity by following simple way?
def perplexity(y_true, y_pred):
    cross_entropy = K.categorical_crossentropy(y_true, y_pred)
    perplexity = K.pow(2.0, cross_entropy)
    return perplexity

But what is y_true,, in text generation we dont have y_true

Accordings to the Socher's notes that is presented by @cheetah90 , could we calculate perplexity by following simple way?
def perplexity(y_true, y_pred):
    cross_entropy = K.categorical_crossentropy(y_true, y_pred)
    perplexity = K.pow(2.0, cross_entropy)
    return perplexity

@icoxfog417 what is the shape of y_true and y_pred?


Suggested submodule updating in README doesn't update

git submodule update --init --recursive doesn't do what the README seems to be suggesting it for because the setup suggests a bare git submodule add for dotbot itself. submodule add checks out the repo with a detached HEAD, which makes subsequent updates do nothing because the submodule is not tracking any branch.
To get the desired behavior you could check out the submodule and point it to the master branch:
# add submodule to track master branch
git submodule add -b master https://github.com/anishathalye/dotbot

# update your submodule
git submodule update --remote

Detailed info: http://stackoverflow.com/a/9189815/368697

I believe the command could then become:
git submodule update --init --recursive --remote

Nix that... if you do both --recursive and --remote you will point the dotbot submodule to new dependencies that it likely doesn't want. Two commands looks like it will work:
- ["git submodule update --init --recursive", "Installing/updating submodules"]
- ["git submodule update --remote", "Updating remote tracking submodules"]

Because of this, I just noticed a typo that was fixed in c32b6f0. Thanks!
I don't actually want to update Dotbot or any other submodules automatically in the install.conf.yaml. Fixing it on a specific version (hash) is good for security, and it prevents things from unexpectedly breaking or anything else weird happening.
If someone wants to upgrade Dotbot, they can manually run git submodule update --remote dotbot.
As you point out, the README isn't exactly clear on what it's doing. Thanks for pointing that out!
I fixed that in 37846b7. Let me know if you think I should make any other changes.


Refactor Scala code

Remove clutter from Scala

[ ] Rewrite calibration plot generator in a separate post-processing script and remove org.deepdive.calibration._
[ ] Remove org.deepdive.settings.models._ and have the rest of the code use Config.get* directly as much as possible
[ ] Rewrite SettingsParser.scala to simply validate and fallback to default values for

[ ] db.default, schema, calibration, sampler, pipeline
[ ] every extraction.extractors
[ ] every inference.factors
[ ] except for providing some utilities

[ ] Drop json_extractor support

Remove Akka by emitting an execution "Plan" instead of immediately executing SQL queries and commands

[ ] Add a Plan class to hold SQL queries and arbitrary commands
[ ] Add easy ways to emit SQL queries and commands
[ ] Add an easy way to group them to create an hierarchy
[ ] Add an easy way to declare dependency among them
[ ] Rewrite org.deepdive.inference._ and .extraction._
[ ] Write a code generator that translates a Plan holding a DAG of SQL/commands into a shell script
[ ] Have deepdive command first generate the shell script, then execute it

Decouple database drivers

[ ] Duplicate InferenceRunner implementation for every backend, inlining *Datastore: postgresql, greenplum, postgresql-xl, mysql, mysqlcluster
[ ] Duplicate ExtractorRunner for every backend as well

+1


added my info in contributors.js & contributors.md

Congrats @Azhar221  🎉, your PR got merged. To be eligible for the swags from ClueLess. Follow this steps.

Star this repository. ⭐

SignIn / SignUp in ClueLess Website .

Go to profile section from the top right hand corner.

Comment your profile URL under this comment tagging the person who merged your PR.

That’s it. Follow the leaderboard !
And don’t forget to share your achievement with your friends.

@Debajyoti14 Here is my profile on Clueless Community.


sidebar drag bug

Does this issue occur when all extensions are disabled?: Yes/No

VS Code Version:
OS Version:

Steps to Reproduce:

when I install an extension from vsix, if I drag the area left and right, it is always in active state, it is a serious bug, can you help to fix?

What do you mean by always in active state? Why is that a serious bug?
Can you please provide a screen recording?

ok，Thanks for your reply
this video is the problem, I think it is a serious bug, can you help to fix? thank you !
------------------ 原始邮件 ------------------
发件人:                                                                                "microsoft/vscode"                                                                                @.>;
发送时间: 2022年1月5日(星期三) 下午4:30
@.>;
<EMAIL_ADDRESS>主题: Re: [microsoft/vscode] sidebar drag bug (Issue #139799)
What do you mean by always in active state? Why is that a serious bug?
Can you please provide a screen recording?
—
Reply to this email directly, view it on GitHub, or unsubscribe.
Triage notifications on the go with GitHub Mobile for iOS or Android.
You are receiving this because you authored the thread.Message ID: @.***>

Can you please provide a screen recording?

hello
 I have already provide you a screen recording
------------------ 原始邮件 ------------------
发件人:                                                                                "microsoft/vscode"                                                                                @.>;
发送时间: 2022年1月10日(星期一) 晚上9:13
@.>;
<EMAIL_ADDRESS>主题: Re: [microsoft/vscode] sidebar drag bug (Issue #139799)
Can you please provide a screen recording?
—
Reply to this email directly, view it on GitHub, or unsubscribe.
Triage notifications on the go with GitHub Mobile for iOS or Android.
You are receiving this because you authored the thread.Message ID: @.***>

hello,
 this is the screen recording, I think it is a serious bug, can you help to fix?
------------------ 原始邮件 ------------------
发件人:                                                                                "microsoft/vscode"                                                                                @.>;
发送时间: 2022年1月10日(星期一) 晚上9:13
@.>;
<EMAIL_ADDRESS>主题: Re: [microsoft/vscode] sidebar drag bug (Issue #139799)
Can you please provide a screen recording?
—
Reply to this email directly, view it on GitHub, or unsubscribe.
Triage notifications on the go with GitHub Mobile for iOS or Android.
You are receiving this because you authored the thread.Message ID: @.***>

Please come to GitHub and attach the screen recording. Sending it via e-mail doesn't work.


Fix behaviour of determining dhcp primary/secondary

When there is more than one CARP address per interface with different
skews, check only the first CARP if and skew in order to determine
primary. This prevents a misconfiguration where both hosts are
configured as dhcp primary due to each host having one VIP with skew <20.
Technically, active/active isn't advisable in general, however we have a setup where we balance clients using separate dhcp pools with different default routers, ensuring clients "stick" to the same firewall except in a failover/maintenance scenario.
Checking the skew of the first VIP should suffice either way, as the recommended configuration is to ensure the same skew for all VIPs on one host.

hmm, the logic in this block is rather confusing as it is, $skew is actually a boolean, let's see if we can clarify this a bit.

@AdSchellevis sure, it's used later as an integer (>10 determines secondary). I was going for least amount of change, but it could of course be made clearer overall.

@AdSchellevis thanks, that's it for now!

@fredronnv more of this please and thanks for your contributions ❤


feat: Add option for user's on exit callback

Motivation:
If I close LazyGit after having done some changes (Commit something/change branch…) I often run into some minor inconsistency with the UI on screen, that does not get updated to reflect the changes.
In particular the issue I’m having is with the color of the files inside the neo-tree view. I understand this is a really insignificant issue, but I still would like to fix it.
Proposed solution:
I have added an option that allow an user of the plugin to add a callback that is automatically executed after exiting LazyGit, so that I can put there the necessary code to refresh my UI

That looks good to me! Thanks for making the PR!


Problem: bitrate: N/A and No FPS info

Hi @pedroSG94,
I use the latest version (1.7.8) and all version before then it has a problem, when I check live's infomation with ffmpeg:
Metadata:
    server          : SRS/2.0.263(ZhouGuowen)
    srs_primary     : SRS/2.0release
    srs_authors     : winlin,wenjie.zhao
    server_version  : 2.0.263
  Duration: N/A, start: 0.000000, bitrate: N/A
    Stream #0:0: Data: none
    Stream #0:1: Audio: aac (LC), 44100 Hz, stereo, fltp
    Stream #0:2: Video: h264 (High), yuv420p(tv, bt709/bt709/smpte170m, progressive), 1080x1920, 1k tbr, 1k tbn

bitrate: N/A and not have fps.

Hello,
That info is optional in RTMP protocol. You can add metadata info here:
https://github.com/pedroSG94/rtmp-rtsp-stream-client-java/blob/master/rtmp/src/main/java/com/github/faucamp/simplertmp/io/RtmpConnection.java#L366

Thank @pedroSG94,


Migrate samples for AppService and WorkloadMonitor

Contributing to the Azure SDK
Please see our CONTRIBUTING.md if you are not familiar with contributing to this repository or have questions.
For specific information about pull request etiquette and best practices, see this section.

Please resolve the conflicts

API change check
API changes are not detected in this pull request.


"vue": "2.6.12" & "vue-grid-layout": "^2.3.11", system fault...

Software version (please complete the following information):

Browse: chrome 87.0.4280.88
Vue Version : 2.6.12
vue-grid-layout Version: 2.3.11

Describe the bug
Browser stop and fault;
Also announce a interactive.js problem.
To Reproduce
Infinitively loop.
Expected behavior
Screenshots
Infinitively loop.
Additional context

Sorry, but "Infinitively loop." is not a proper description of the problem.


Integrations of four more sides

Hi Sir Thanks for this wonderful library.
Actually we are using this library in our project and want to extend it. Currently the library provides
five options 'top', 'right', 'bottom', 'left' or 'auto'. and we want to include four more sides i.e the corners of the rectangles

The brown one are those these library providing and green one are those that we want can you suggest/guide which functions/code we modify/update in source code to achieve that.

Hi @narendersaini32, thank you for the comment.
You can point anywhere in the element or the document by using pointAnchor attachment.

Thanks Sir

:smile:

Hi Sir
I tried with pointAnchor which is good but not fulfill my requirements we can change the x,y positons of starting and end of a connection but we need diagonally direction for connection

Something between bottom and right direction

Something like shown in the above pic pointAnchor only change the x,y but we required direction also do you have some suggestions

Sorry, your English is difficult for me...
Could you add period and commas?

Sir I can change the location of the connection's start and end point on element using pointAnchor.
But I also need to rotate the starting and end of connection. For example:- I can create socketEnd, socketStart direction using right, left, top, bottom values but i need to create something middle of right and bottom which is not possible using pointAnchor.

how i create socketEnd and socketStart with green arrow directions as shown in image

Do you mean that you want to specify the direction of line (not only point)?

yes

Something like this

I see.
For example: https://jsfiddle.net/psum8veb/

yes thanks Sir :+1

:smile:


API for obtaining CIP-0019 formatted addresses

Adjacent to #271.
This is the addr1, test1, stake1 and etc type addresses, which is just a set standard prefixes with bech32.
This is normally handled by cardano-api, however it might be convenient to expose this separately (via a bech32 library), since cardano-api doesn't work with ghc9...
Arguably, this could be within the purview of a separate library, exposing utils for cardano without the dependency footprint.

It could be in the same repository.


Fixed issue#3333 music and sound in classpath not load on Android.

I solve this issue : https://github.com/libgdx/libgdx/issues/3333

I'm not sure how I feel about this extracting to the cache directory every time a classpath audio is loaded business. Is there a reason you are not first checking for the existence of the file before copying it again?

I delete the file after the MediaPlayer is prepare in order to avoid keeping useless files in caches.
If you load 2 times the same audio file it will caches 2 time because first file in cache was delete.
That why i don't check if the file is already in cache.

I think it is OK to leave the file in the cache.

If i understand correctly, the issue is that Android mediaplayer isn't able to load classpath files and the solution is to copy the file to a temp file. What would be an actual valid use-case for this? Isn't it better to advise not to place assets on the classpath in the first place and to update the docs?

That's what I would favor, classpath assets should be used sparingly.

The docs already advise to not put assets on classpath.
But even if user should not put assets on classpath, i think libgdx could load file form there.
If you choose to not handle this use-case i can code the exception.
A use-case could be a audio file in a library you import.

Isn't this unnecessary strain on the flash of the device? Who puts audio files in libraries anyway?

No assets in the classpath on Android!


STS Regionalized Endpoints

SEP: /seps/accepted/shared/sts_regionlization/
internal id: 174915599

Swift SDK already uses regional endpoints and there is no legacy global endpoint concept at first place.
Closing.


Needs License

This library should have a license attached to it.
If you are interested, you could just use the license that opencv is released under:
http://opencv.org/license.html

Thanks!


Issue with ATEM Feedback One ME preview source from variables

"One ME preview source from variables"
I've been playing with this feedback a lot lately.
Is it expected that the M/E field that is supposed to support variables is only working with M/E 1 ?
I've created a variable that contains the number of a specific M/E (1 is for M/E1, 2 is for M/E2 , etc.)
But it seems that field is only working with "1" (through designed and specific variable or direct input number). When the variable is "2", the feedback returns nothing. Is this correct ?
Thank you in advance for your reply on this matter.

Yes It was. But problem is solved with a reboot of the software... It's working now as expected.


Handle .ico

Could be nice to be able to do a catimg ./favicon.ico to see what it looks like :)

Hi!
That would be indeed nice. The lib I use for loading images doesn't handle ico files. Do you know about any tiny lib that does that? Otherwise I'd have to code it myself as I'm concerned about the final executable file size

I know that the convert command utility that comes with ImageMagick should handle ico files.
$ convert favicon.ico txt:-
# ImageMagick pixel enumeration: 16,16,65535,srgba
0,0: (100%,100%,100%,0)  #FFFFFFFFFFFF0000  srgba(255,255,255,0)
1,0: (100%,100%,100%,0)  #FFFFFFFFFFFF0000  srgba(255,255,255,0)
2,0: (100%,100%,100%,0)  #FFFFFFFFFFFF0000  srgba(255,255,255,0)
3,0: (100%,100%,100%,0)  #FFFFFFFFFFFF0000  srgba(255,255,255,0)
4,0: (66.2745%,5.88235%,9.41176%,1)  #A9A90F0F1818  srgba(169,15,24,1)
5,0: (66.2745%,5.88235%,9.41176%,1)  #A9A90F0F1818  srgba(169,15,24,1)
6,0: (66.2745%,5.88235%,9.41176%,1)  #A9A90F0F1818  srgba(169,15,24,1)
7,0: (66.2745%,5.88235%,9.41176%,1)  #A9A90F0F1818  srgba(169,15,24,1)
8,0: (66.2745%,5.88235%,9.41176%,1)  #A9A90F0F1818  srgba(169,15,24,1)
9,0: (66.2745%,5.88235%,9.41176%,1)  #A9A90F0F1818  srgba(169,15,24,1)
10,0: (82.7451%,12.1569%,16.4706%,1)  #D3D31F1F2A2A  srgba(211,31,42,1)
11,0: (82.7451%,12.1569%,16.4706%,1)  #D3D31F1F2A2A  srgba(211,31,42,1)
12,0: (100%,100%,100%,0)  #FFFFFFFFFFFF0000  srgba(255,255,255,0)
13,0: (100%,100%,100%,0)  #FFFFFFFFFFFF0000  srgba(255,255,255,0)
14,0: (100%,100%,100%,0)  #FFFFFFFFFFFF0000  srgba(255,255,255,0)
15,0: (100%,100%,100%,0)  #FFFFFFFFFFFF0000  srgba(255,255,255,0)
0,1: (100%,100%,100%,0)  #FFFFFFFFFFFF0000  srgba(255,255,255,0)
1,1: (100%,100%,100%,0)  #FFFFFFFFFFFF0000  srgba(255,255,255,0)
2,1: (100%,100%,100%,0)  #FFFFFFFFFFFF0000  srgba(255,255,255,0)
3,1: (66.2745%,5.88235%,9.41176%,1)  #A9A90F0F1818  srgba(169,15,24,1)
4,1: (66.2745%,5.88235%,9.41176%,1)  #A9A90F0F1818  srgba(169,15,24,1)
5,1: (66.2745%,5.88235%,9.41176%,1)  #A9A90F0F1818  srgba(169,15,24,1)
6,1: (66.2745%,5.88235%,9.41176%,1)  #A9A90F0F1818  srgba(169,15,24,1)
7,1: (66.2745%,5.88235%,9.41176%,1)  #A9A90F0F1818  srgba(169,15,24,1)
8,1: (82.7451%,12.1569%,16.4706%,1)  #D3D31F1F2A2A  srgba(211,31,42,1)
9,1: (82.7451%,12.1569%,16.4706%,1)  #D3D31F1F2A2A  srgba(211,31,42,1)
...

Sorry for the late answer. Adding support for those enumeration and adding a note on the help and readme seems enough. I'll find the time to do it someday 😅

I just tried using catimg with an ico file, and it worked fine.

You must have used the script 😄

I'm not sure I'm following here. I just tried with http://www.google.com/favicon.ico and it failed

There's the C program that is installed with brew and compiled with the Makefile and there's also a shell version at project's root that relies on ImageMagick to print images and therefore handle pretty much any format ImageMagick can handle

I tried both version, script and binary and both were giving me errors with Google favicon:
Binary:

Script:

I then started hacking on my own Ruby version (repo here) and it's now working. It is way slower than your binary, though.

Added in #24


TweedieDevianceScore producing nan results when setting power=1.0

🐛 Bug

To Reproduce
>>> targets=torch.tensor([0,1,0,1])
>>> preds=torch.tensor([0.1,0.1,0.1,0.1])
>>> td(preds,targets)
tensor(nan)
>>> td=TweedieDevianceScore(power=1.0001)
>>> td(preds,targets)
tensor(1.5038)```

I assume this is a bug since the documentation says targets >= 0 (obviously Poisson data will often be 0).

Hi @EvanZ, thanks for reporting this. This is indeed a bug and it happens due to a unsafe log operation in the metric calculation. Will be fixed in PR #847.

Oh that's great to hear. Thanks!

Don't know if anyone will ever read this but here goes. Thanks for fixing the bug. It definitely works now in terms of calculating the loss. However, a secondary problem has arisen, which maybe is just unfixable. I'm trying to use the deviance score as a loss function. There exists a poisson loss function in PyTorch, which I'm currently using, but it would be convenient to use TweedieDevianceScore because that way I could model Poisson, Gamma, and mixed Poisson-Gamma distributions with the same code, only changing one parameter.
Anyway, to the point. I am able to use TweedieDevianceScore as a loss function when power is set to 2.0 (Gamma) or in the range 1-2 (Poisson-Gamma). But now that I am trying to set power=1.0, I am getting nan values in the second batch of training. I checked and there are no nan values in the first batch and a finite loss is calculated. But for some reason in the second batch of training, nan values pop up.
My guess is that it is an issue with the derivative when power=1.0 and somehow even though the loss can be calculated now (thanks to this bug fix), the derivative of the loss is blowing up. If this is the case, I will probably just give up and use the built-in Poisson loss. But I thought I'd mention it here for posterity and in case anyone might have a clue. Maybe there's something else going on...

Hi @EvanZ,
Thanks for reporting this back. To easier debug this (and maybe solve) would it be possible for you to provide an example input that result in Nan?

@SkafteNicki appreciate your quick reply. The problem as I'm trying to explain (maybe not well) is that it's not the TweedieDevianceScore that is directly giving me nan values. You guys definitely fixed that issue. This "new" issue is occurring at some point after the loss for the first batch is calculated and backprop step (I assume this is when the nan values are being generated). But it definitely has something to do with setting power=1.0 in TweedieDevianceScore because it's not happening with other values (1.01, 1.5, 2.0, etc). I wish I could paste my entire model and dataset, but I don't think that's possible (my employers wouldn't like it!).
As I said, I think this may be very difficult to figure out. But my guess is that it has something to do with autograd . Maybe TweedieDevianceScore is not differentiable when power=1.0?


New version: blacktop.ipsw 3.1.464

Checklist for Pull Requests

[ ] Have you signed the Contributor License Agreement?
[ ] Is there a linked Issue?

Manifests

[ ] Have you checked that there aren't other open pull requests for the same manifest update/change?
[ ] This PR only modifies one (1) manifest
[ ] Have you validated your manifest locally with winget validate --manifest <path>?
[ ] Have you tested your manifest locally with winget install --manifest <path>?
[ ] Does your manifest conform to the 1.6 schema?

Note: <path> is the name of the directory containing the manifest you're submitting.

Automated with GoReleaser
Microsoft Reviewers: Open in CodeFlow

URL: https://github.com/blacktop/ipsw/releases/download/v3.1.464/ipsw_3.1.464_windows_arm64.zip
Status Code: 200
(Automated message - build 876)

Automatic Validation ended with:

URI: https://github.com/blacktop/ipsw/releases/download/v3.1.464/ipsw_3.1.464_windows_x86_64.zip, Validation result: Failed, Http status code: NotFound

(Automated response - build 876.)

sorry mucking around with CI/CD the zips should be there now.


Log exception's code

Problem Statement
I work a lot with the Twilio SDK. In case of an error, a RestException is thrown with a text description of the error, as well as a code in their internal error system. In the current implementation, I can't see this code.
Solution Brainstorm
According to Sentry's documentation, there is a exception's meta information, which seems to be the way to provide the wanted information.
I have tried to implement it, but it seems like Sentry filters out this field on the service side (I checked that this field presented just before JSON encoding when a request is about to be sent).

Ok, I managed to get it to work!

Seems like this is a backlog item, so moving it there

Closed in #1451

The collection of exception code is great! It nicely pops up in the Sentry issue report after upgrading PHP SDK to latest.
But, it seems we are unable to filter on it in the issues overview. Will that feature be added soon?
Will Sentry also be able to based on that exception code more reliably group issue occurrences? That will allow us to more extensively use variables in the exception message (that sometimes lead to Sentry reporting issues as separate ones).

@rvanlaak Gald you like the new feature! I passed on your feedback to our product team, thanks for letting us know.

Thanks! Happy to help wherever I can, really love your product and the transparency on the development of it.

@rvanlaak Didn't forget about this! 😄
You can subscribe to https://github.com/getsentry/sentry/issues/45760.
It's sadly a bit more involved, but we'll get there.


Lazily pack and unpack textures in WebGL kernels

Changes

Add packedInput boolean property to GPGPUProgram to identify WebGL kernels that require packed inputs (batchMatMul, conv2DWithIm2Col).
Such kernels no longer unpack their outputs, and they only pack their inputs if they are not already packed.
In compileAndRun, check whether the GPGPUProgram requires packed inputs. If it does not, and an input texture is packed, unpack it before passing it to the program.

PERF

For repository owners only:
Please remember to apply all applicable tags to your pull request.
Tags: FEATURE, BREAKING, BUG, PERF, DEV, DOC, SECURITY
For more info see: https://github.com/tensorflow/tfjs/blob/master/DEVELOPMENT.md

This change is

@nsthorat
If I dispose the input tensors to a kernel immediately after packing / unpacking them, gradient operations stop working because the inputs to engine.runKernel are disposed by the time they get passed to the tape node.
Maybe it would make sense to have the gradient scope dispose of the tensors instead? But I'm sure how to approach implementing that - is there a straightforward way that takes advantage of existing infrastructure that you know of?

Note - this PR now depends on https://github.com/tensorflow/tfjs-core/pull/1327 because the batchNorm tests need to be able to print 4D packed outputs


[Feature][Module Name] User Management, session management

Search before asking

[X] I had searched in the issues and found no similar feature requirement.

Description
Have you considered adding user management and session management functions, administrators deploying services, distributing links to users, and users being able to register for their own logins and see only their own session records and public repositories, you can also create your own private knowledge base, so that the production environment can be more friendly
Use case
No response
Related issues
No response
Feature Priority
None
Are you willing to submit PR?

[ ] Yes I am willing to submit a PR!

hi, @Storm0921 , User login management We have retained user_code and sys_code in the table design. We hope that community users can carry out secondary development by themselves.


Sensor harmonisation does not affect headphone data

Unit and reference frame harmonisation does not seem to be applied to headphone IMU data when enabled for phone data.

That is indeed the case. The harmonisation option is currently applied to phone sensors only -- not AirPods and, as a matter of fact, Apple watches too. However, I agree it should. I will update the harmonisation option in the next update so that it is more consistent across the board.

Can now confirm that this will be available as part of version 1.30

Version 1.30 is now available. Do re-open this issue if you run into further issues.


[Memory Leak] Plugin exposes Hammer globally on window

Not a major memory leak or anything, but this plugin should not expose the entire Hammer library to the window object.
├──<EMAIL_ADDRESS>├──<EMAIL_ADDRESS>├──<EMAIL_ADDRESS>├──<EMAIL_ADDRESS>├──<EMAIL_ADDRESS>├──<EMAIL_ADDRESS>├──<EMAIL_ADDRESS>├──<EMAIL_ADDRESS>├──<EMAIL_ADDRESS>├──<EMAIL_ADDRESS>├──<EMAIL_ADDRESS>├──<EMAIL_ADDRESS>├──<EMAIL_ADDRESS>├──<EMAIL_ADDRESS>├──<EMAIL_ADDRESS>├──<EMAIL_ADDRESS>├──<EMAIL_ADDRESS>├──<EMAIL_ADDRESS>├──<EMAIL_ADDRESS>└──<EMAIL_ADDRESS>

We don't do that. Hammer probably does that itself. Nothing we can do about it.


How to update GraphEndpoint to graph.microsoft.com from graph.windows.net

As per the documentation I am trying to retrieve a list of users for a daemon application.  \
"https://graph.microsoft.com/v1.0/users"

However executing the code snippet below results in an error:
The required environment variables are set.
  authorizer, err := auth.NewAuthorizerFromEnvironment()
    if err != nil {
        fmt.Println(err)
    }

    client := graphrbac.NewUsersClient(os.Getenv("AZURE_TENANT_ID"))
    client.Authorizer = authorizer

    if _, err := client.List(context.Background(), "", ""); err != nil {
        fmt.Println("list users", err)
    }

Error Message
graphrbac.UsersClient#List: Failure responding to request: StatusCode=401 -- Original Error: autorest/azure: Service returned an error. Status=401 Code="Unknown" Message="Unknown service error" Details=[{"odata.error":{"code":"Authentication_MissingOrMalformed","message":{"lang":"en","value":"Access Token missing or malformed."}}}]

 \
https://graph.windows.net/1bd79572-bd51-4db0-a48b-490933792ad3/users\?api-version\=1.6
{"odata.error":{"code":"Authentication_ExpiredToken","message":{"lang":"en","value":"Your access token has expired. Please renew it before submitting the request."}}}%

I suspect if I change the GraphEndpoint to graph.microsoft.com I should have some success. However, the following does not take effect:
azure.PublicCloud.GraphEndpoint = "https://graph.microsoft.com"

Some guidance on this would be appreciated.

Hi @haani-niyaz thanks for this issue!
graphrbac package in this repo is the Azure graph APIs, and the end point of graph.microsoft.com belongs to MSGraph, which although has the similar name, but actually a different set of SDKs.
A valid go version of this SDK could be found here

Thanks. I found this to be confusing until I cam across https://github.com/Azure/azure-sdk-for-go/issues/7352. Closing.

Hi @haani-niyaz ,
Did this solvethe issue, i am facing same issue while creating Azure AD app using azure-sdk-for-go and getting 403 error:
"error": "graphrbac.ApplicationsClient#Create: Failure responding to request: StatusCode=403 -- Original Error: autorest/azure: Service returned an error. Status=403 Code=\"Unknown\" Message=\"Unknown service error\" Details=[{\"odata.error\":{\"code\":\"Authorization_RequestDenied\",\"date\":\"2021-12-23T11:43:25\",\"message\":{\"lang\":\"en\",\"value\":\"Insufficient privileges to complete the operation.\"},\"requestId\":\"9ff0a11d-ad06-4b34-9fe4-e32d2cd1a0d1\"}}]"
with below code for initializing appclient:
	appClient := graphrbac.NewApplicationsClient(tenantID) 	credConfig := auth.NewClientCredentialsConfig(clientID, clientSecret, tenantID) 	credConfig.Resource = azure.PublicCloud.ResourceIdentifiers.Graph 	authorizer, err := credConfig.Authorizer() 	if err != nil { 		return appClient, err 	} 	appClient.Authorizer = authorizer 	err = backoffAlg.RetryOnError(a.Log, []string{}, 8, func() error { 			app, err = appClient.Create(context.Background(), graphrbac.ApplicationCreateParameters{ 				AvailableToOtherTenants: to.BoolPtr(false), 				DisplayName:             to.StringPtr(appName)}) 			return err 		}) 		if err != nil { 			return app, err 		}
Any suggestion would be appreciated.


Missing RepositoryCredentials attribute for ContainerDefinition object

Hi!
This is regarding this attribute: https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ecs-taskdefinition-containerdefinitions.html#cfn-ecs-taskdefinition-containerdefinition-repositorycredentials


Dependency issue with Docusaurus 2.0.1

When running:
npm install docusaurus-theme-search-typesense@next --save
The result is:
ERESOLVE unable to resolve dependency tree
npm ERR!
npm ERR! While resolving<EMAIL_ADDRESS>npm ERR! Found<EMAIL_ADDRESS>npm ERR! node_modules/@docusaurus/core
npm ERR<EMAIL_ADDRESS>from the root project
npm ERR!
npm ERR! Could not resolve dependency:
npm ERR! peer<EMAIL_ADDRESS>from<EMAIL_ADDRESS>npm ERR! node_modules/docusaurus-theme-search-typesense
npm ERR<EMAIL_ADDRESS>from the root project
Is this not compatible with the latest docusaurus 2.0.1?
Metadata

Could you try with v0.5.3 of docusaurus-theme-search-typesense?

Thanks! That did it :-)

Hey!
Oddly, we're still seeing this error. It looks like I'm using the right versions — any ideas?   using --force or --legacy-peer-deps resolves it, but if there's something else we can fix that'd be ideal!

@saltcod Could you try with 0.6.0-0 of docusaurus-theme-search-typesense?

Sweet! That looks to have done it. Thanks @jasonbosco !


fix: event listener to work with page-load

Fixes #55
Changes the event listener from DOMContentLoaded to astro:page-load to support Astro's View Transitions feature.
Note: I'm not sure when this event got added to Astro so we'll want to test and possibly update the readme to state what version of Astro is supported.

@shishkin are you interested in merging this?

Hi @joshmedeski. Thanks for the PR and sorry for a delay. I'm definitely interested in getting it merged, but unfortunately I just don't seem to get view transitions to assess the implications.
Maybe you can answer my concerns which I could not figure out by reading Astro docs:

Does astro:page-load event get fired when view transitions are not in use? If not, how to handle normal transitions and view transitions at the same time?
Does it break compatibility with Astro 2.0? If yes, it would require a major version bump.

I've added support for view transitions in 6feefb904eea5c600c0b6f788087e72e6689c606, released in 1.4.0. It turned out that astro:page-load event is not fired without ViewTransitions router.

Hey, I've been focused on other things this week, thanks for getting it done! 🎉


Using home-manager on Ubuntu

I'm currently setting up an Ubuntu machine and wanted to give home-manager a try to manage my nix config.
Unfortunately, this fails after the nix-shell $HM_PATH -A install step.
In particular, the shell invocation seems to download and install stuff, but I can't access home-manager within the shell:
$ nix-shell $HM_PATH -A install
downloading ‘https://github.com/rycee/home-manager/archive/master.tar.gz’... [0/0 KiB, 0.0 KiB/s]
unpacking ‘https://github.com/rycee/home-manager/archive/master.tar.gz’...
these derivations will be built:
  /nix/store/1kvigm7xrn265b8294vnyz8ya733x872-home-manager.drv
these paths will be fetched (65.48 MiB download, 383.55 MiB unpacked):
...
fetching path ‘/nix/store/1fhlzxwchqnfg3q6dy1jg661jf5jq6q8-bash-4.4-p12-doc’...
...
building path(s) ‘/nix/store/n3i39rddsnw0m63p2zigjdqkgb5zg0n1-home-manager’
install: creating directory '/nix/store/n3i39rddsnw0m63p2zigjdqkgb5zg0n1-home-manager'
install: creating directory '/nix/store/n3i39rddsnw0m63p2zigjdqkgb5zg0n1-home-manager/bin'
'/nix/store/pzd76az2grpfxhpw0fp9l6ihspixkaq1-home-manager' -> '/nix/store/n3i39rddsnw0m63p2zigjdqkgb5zg0n1-home-manager/bin/home-manager'
$ which home-manager
home-manager not found
$ ^D

Creating initial Home Manager generation...

these derivations will be built:
  /nix/store/1v3di0mbgfwn85daxq77v3nny3g17lcs-link.drv
...
Starting home manager activation
Activating checkLinkTargets
Activating writeBoundary
Activating uninstallHomeManager
Activating installPackages
installing ‘home-manager-path’
building path(s) ‘/nix/store/sspclkff7c6r1ifz8i0lh3x10ss48a15-user-environment’
Wide character in die at /nix/store/64jc9gd2rkbgdb4yjx3nrgc91bpjj5ky-buildenv.pl line 79.
collision between ‘/nix/store/gy4yv67gv3j6in0lalw37j353zdmfcwm-nix-1.11.16/bin/nix-build’ and ‘/nix/store/cbrjfmfdc2p0vx56jzl7ip31gyr0daxv-home-manager-path/bin/nix-build’; use ‘nix-env --set-flag priority NUMBER PKGNAME’ to change the priority of one of the conflicting packages
builder for ‘/nix/store/rr70b71w1wlzmc0gmfsc3gj5v6av5xda-user-environment.drv’ failed with exit code 255
error: build of ‘/nix/store/rr70b71w1wlzmc0gmfsc3gj5v6av5xda-user-environment.drv’ failed

Uh oh, the installation failed! Please create an issue at

    https://github.com/rycee/home-manager/issues

if the error seems to be the fault of Home Manager.

Strange enough, the build only really finishes after leaving the nix-shell (is this expected? Need to work on my nix foo).
There seems to be a conflict with the installed nix package because home-manager-path provides its own. I tried to resolve this with nix-env --set-flag priority 100 nix, but then it would only break at a later point.
Any advice?

FYI, nix-home seems to have the same problem in the final installation step. It's the top-level all derivation that's conflicting there.

Nevermind, I figured it out. nix-env -q lists the nix package at a minimum and of course I can't include that in my paths list if I want to avoid conflicts. I wasn't aware of the machinery behind home-manager and replicated most of it by hand, only to find out why this failed.

I'm glad it worked out for you! Honestly I've never tried following the setup instructions on a non-NixOS system. Do you have any suggestion on how to improve the instructions so that others can avoid the problem you encountered?

A hint that you can't have a package both show up in nix-env -q and in your paths attribute/home-manager packages would be helpful.
Also I'm not sure how nix-shell $HM_PATH -A install is supposed to work, but as you can see from the log above the shell that opens doesn't really have the right environment. Only after quitting the shell home-manager creates its initial generation. That felt weird, because it wasn't mentioned in the instructions that I was supposed to leave the shell immediately.
Otherwise this mostly works for me now, so that's great. Thanks for your efforts!

Hmm, the nix-shell $HM_PATH -A install command should never put you in an interactive shell. It should just automatically run the installation commands and then exit back into your regular shell. If you re-run nix-shell $HM_PATH -A install do you still get this shell prompt? Which version of nix do you have (nix-env --version)?
I'll add a note about not having packages installed through both home.packages and nix-env -q in the readme. Thanks!

I get the interactive shell also on re-runs. nix version is 1.11.16 on Ubuntu 17.10.


Enhance DNS logs and make them consistent

Motivation:
Always include information that helps to correlate log events.
Modifications:

Always include Channel at the beginning of every log, when channel is available;
Always include [queryId: sender] when available;
DnsQueryContext: include expected values when logging at WARN level;

Result:
Consistent logging, easier to correlate log events.

@idelpivnitskiy thanks


fix: settings allowed values check

closes https://github.com/ansys/pyfluent/issues/2778

Updated attribute check in settings exception block.

@hpohekar please add a test. If you get stuck, please check with @h-krishnan. Please ensure your test fails with the original code. The test is important as we would be patching the product with this.


Package aab contains all package ids

Feel free to close this if it isn't a problem, but I randomly noticed the b1 AndroidManifest from the aab contains all of these lines. Shouldn't it just be one?
    <package android:name="com.fsck.k9"/>

    <package android:name="net.thunderbird.android"/>

    <package android:name="net.thunderbird.android.beta"/>

    <package android:name="net.thunderbird.android.daily"/>

This is necessary to be able to import settings from another of our apps. See https://github.com/thunderbird/thunderbird-android/blob/e2097fce73da38cf72cd8e933590b2b6a2416d6a/feature/settings/import/src/main/AndroidManifest.xml#L7-L13


container parallel testing

build-depends: 31590
build-depends: https://github.com/dci-labs/bos2-ci-config/pull/148
TestBos2Sno: sno control-plane-1-parallel

retest

retest

retest

Status since last commit:

[x] preflight-green- https://www.distributed-ci.io/jobs/f79beec3-1955-4a18-b7db-a5b9ac4a853b/jobStates
[x] control-plane no parallel - https://www.distributed-ci.io/jobs/a24f2c48-1532-4a21-92b8-2a89adc4e5b2/jobStates?sort=date
[x] control-plane 1 parellel - https://www.distributed-ci.io/jobs/4c9fe71a-b0ee-4983-9964-d554fac505e4/jobStates?sort=date
[x] all feedback and comments resolved

overall looks good to me, I talked with Ying and Andrew to wait a little bit for @tkrishtop review, thanks!

retest

retest

retest

retest

recheck

retest

retest

retest

Testing to close and re-open to see if that triggers the CI job

recheck

retest

retest

retest

recheck

retest

hi @ansvu no worries about the force-push, I simply rebased your changes over the main branch to unblock the testing

retest

recheck

recheck

retest

recheck

recheck


⚠ T:Riza Docs has degraded performance

In 3f2050d, T:Riza Docs (https://docs.triza.dev) experienced degraded performance:

HTTP code: 200
Response time: 5256 ms

Resolved: T:Riza Docs performance has improved in 702f48f.


Starter project repo does not correspond

The started project repo does not correspond to this lab, the Complete Code doesn´t have the buttom "Enable foreground and background location" and doesn´t have the "android.permission.ACCESS_BACKGROUND_LOCATION". Please update the corresponding repo. Thanks.

The problem is still there.  The download files do not match the tutorial materials which are excellent. Shame I can complete the exercise.
Please update online files


test, don't merge: hmc support

@jiangphcn release generated in golang-zhmcclient here https://github.com/zhmcclient/golang-zhmcclient/releases/tag/v0.3.0 to support the new function.

thanks @jiangphcn this is really good! Would you be made the PR ready for the next release?

thanks so much @rootfs for your encourage, as always. Yes, I will try my best to make it be ready for next release.

@jiangphcn , I have converted this to a draft to indicate WIP.

thank you @sthaha


Delete unnecessary spaces

When copying from the web page, there is an unnecessary space after the code.

@changeworld : Thanks for your contribution! The author, @mikejo5000, has been notified to review your proposed change.

@changeworld @Mikejo5000 - We're in the process of pulling these commits to the private repo, so we can verify the content on staging. We'll post a new PR # shortly and then close this PR.

@changeworld @Mikejo5000 - The commits in this PR were moved to the private repo (PR #3853) for validation and staging. We'll close this PR now.


Fix contiv-crd large data and excessive logging

Reduce the data saved to crd report by storing only some basic info
about nodes
Remove logging of entire stored report when storing fails
Skip validating of CIDR for pods without any k8s CIDR defined (e.g
coredns pod) and move it at the end of validation
Fix compilation failures in contiv-crd tests
Properly register crd l2 and l3 tests to gomega

Signed-off-by: Tomas Slusny<EMAIL_ADDRESS>To see the output, run kubectl get telemetryreports.telemetry.contiv.vpp -o json

Coverage increased (+0.2%) to 76.173% when pulling 09ae39b2760ac484d07c9b41462da553fad28a2d on deathbeam:contiv-crd-fixes into d1edaf25294049c919f849f17fdfdf5d48978a83 on contiv:master.


:sparkles: Native share + updated meta description

Hey @liyasthomas,
Your changes look good to me!
View build log
TravisBuddy Request Identifier: 52f149b0-4fae-11ea-97b4-2505cffd77c3

Hey @liyasthomas,
Your changes look good to me!
View build log
TravisBuddy Request Identifier: ab528f00-4fb9-11ea-97b4-2505cffd77c3

Hey @liyasthomas,
Your changes look good to me!
View build log
TravisBuddy Request Identifier: ef0a5fc0-4fb9-11ea-97b4-2505cffd77c3


Pruning shemes for regression-based resnet_2x

Hi, thanks for sharing the code.
May I know how do you get the following pruning scheme for resent_2x in regression-pruning:
cfg_2x = [35, 64, 55, 101, 51, 39, 97, 50, 37, 144, 128, 106, 205, 105, 72, 198, 105, 72, 288, 128, 110, 278, 256, 225, 418, 209, 147, 407, 204, 158, 423, 212, 155, 412, 211, 148, 595, 256, 213, 606, 512, 433, 1222, 512, 437, 1147, 512, 440]
Is it from the original code, or you implement yourself?
BTW, it seems that according to compute_flops.py, the reduction of flops is not 2 folds, though the name is resnet_2x.py

Besides, it seems to be different from the official guidelines for resent pruning in the paper.
https://github.com/yihui-he/channel-pruning/wiki/ResNet-perserving-ratio

The resnet-2x model follows exactly the same as the authors released model. All the architecture details are the same as the released model. We just rewrote it in pytorch.

Got it. Thanks for your explanation.
It seems to be really tricky to find this pruning scheme.


Missing spacing when using katex executable

When I type in "a+b" in the demo textfield on katex.org and inspect the DOM I see the following spacing elements between "a and "+" and between "+" and "b".

The same happens if I use node and run a script with var katex = require('katex'); katex.renderToString(...). The rendering looks fine.
However, if I do the exact same thing using the katex executable installed via npm install -g katex I get this:

The spacing is missing and consequently it looks wrong in the browser. You can (presumably) reproduce the issue like this:
npm install -g<EMAIL_ADDRESS>echo "a+b" > test.tex
katex -i test.tex -o test.html
cat test.html

When I run the above and inspect the generated HTML I see  between each character. I would expect a margin of approximately 0.222em (like in the above shown above).
Am I doing something wrong? Anyway, thanks for a great library :-)

I'm confused why this is happening, but I could reproduce it. Thanks for the report!

FWIW, yarn global add katex behaves the same.  But from a Git master clone, yarn; yarn build; echo a+b | node cli.js works fine.  So maybe something to do with bin mechanism...

OK, I found the problem: a bad (0) default for maxSize.  #1739 fixes the issue, and meanwhile you can use katex -s 999 or similar.


CI(build-and-test): temporarily don't build images for arm

Problem
From time to time, we run out of space on ARM runners
Summary of changes

Temporarily disable building images on arm64 runners

Checklist before requesting a review

[x] I have performed a self-review of my code.
[ ] If it is a core feature, I have added thorough tests.
[ ] Do we need to implement analytics? if so did you add the relevant metrics to the dashboard?
[ ] If this PR requires public announcement, mark it with /release-notes label and add several sentences in this section.

Checklist before merging

[ ] Do not forget to reformat commit message to not include the above checklist

There were no issues with ARM runners, closing this one


Libtorrent BUILD_FAILED for version >1.1.7 (1.1.8 & 1.1.9) [Solution Found]

I've figured out that there is at least 1 new dependency for libtorrent v1.1.9: boost-scope-exit, (there was an error involving scope_exit.hpp being missing).
I got past some errors relating to boost after installing the entire boost package.
With PREFER_NINJA disabled, here is the log:
install-x86-windows-dbg-out_msbuild1_1_9.log
Note that the failures have nothing to do with the SHA512 hash.
After installing the entire boost distro, (i.e. vcpkg install boost) I also attempted to build:

v1.1.7 libtorrent
95479ff0cbce299edccaaeb435c31b07c05f45e319f3480645d2ae45a9bdc01866edb1329426c6835a7c0cba2d6347254f5f023009ff78405b813c131b78addb

SUCCESS with PREFER_NINJA (disabling PREFER_NINJA is untested)

config-x86-windows-out.log
install-x86-windows-dbg-out.log
install-x86-windows-rel-out.log
patch-x86-windows-0-err.log
patch-x86-windows-1-err.log

v1.1.8 libtorrent
0db79b60093fc771d3fb0a2df7d420ae874da0e5c0968e4cc28052c999ed259f339d4e8b271923a0dc71ec1433d50ad5b680d873ea3dbfa17e663e265c02975b

Output in console:
The following packages will be built and installed:
    libtorrent[core]:x86-windows
Starting package 1/1: libtorrent:x86-windows
Building package libtorrent[core]:x86-windows...
-- Downloading https://github.com/arvidn/libtorrent/archive/libtorrent-1_1_8.tar.gz...
-- Extracting source C:/Github/vcpkg/downloads/arvidn-libtorrent-libtorrent-1_1_8.tar.gz
-- Using source at C:/Github/vcpkg/buildtrees/libtorrent/src/rent-1_1_8-9ceb8a466d
-- Applying patch C:/Github/vcpkg/ports/libtorrent/add-datetime-to-boost-libs.patch
-- Applying patch failed. This is expected if this patch was previously applied.
-- Applying patch C:/Github/vcpkg/ports/libtorrent/boost-167.patch
-- Applying patch failed. This is expected if this patch was previously applied.
-- Configuring x86-windows
-- Building x86-windows-dbg
CMake Error at scripts/cmake/vcpkg_build_cmake.cmake:175 (message):
    Command failed: C:/Program Files/CMake/bin/cmake.exe;--build;.;--config;Debug;--target;install;--;-v;-j1
    Working Directory: C:/Github/vcpkg/buildtrees/libtorrent/x86-windows-dbg
    See logs for more information:
      C:\Github\vcpkg\buildtrees\libtorrent\install-x86-windows-dbg-out.log

Call Stack (most recent call first):
  scripts/cmake/vcpkg_install_cmake.cmake:24 (vcpkg_build_cmake)
  ports/libtorrent/portfile.cmake:35 (vcpkg_install_cmake)
  scripts/ports.cmake:71 (include)

Error: Building package libtorrent:x86-windows failed with: BUILD_FAILED
Please ensure you're using the latest portfiles with `.\vcpkg update`, then
submit an issue at https://github.com/Microsoft/vcpkg/issues including:
  Package: libtorrent:x86-windows
  Vcpkg version: 0.0.113-nohash

Log file (PREFER_NINJA is enabled): install-x86-windows-dbg-out.log

Log file (without PREFER_NINJA): install-x86-windows-dbg-out.log

Ok I figured it out (working, at least):
For newer versions, boost >= 1.67 is auto detected (I think), and the CMakeLists.txt file changed, so the old patch no longer works.
I used something like this as the add-datetime patch:
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 0c7d9c68d..83e1ae4b0 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -264,7 +264,7 @@ if (NOT cxx_std_11 IN_LIST CMAKE_CXX_COMPILE_FEATURES)
 endif()
 # Boost
 if(NOT DEFINED Boost_INCLUDE_DIR OR NOT DEFINED Boost_LIBRARIES)
-	find_package(Boost REQUIRED COMPONENTS ${required_boost_components})
+	find_package(Boost REQUIRED COMPONENTS date_time ${required_boost_components})
 endif()
 # now test the second requirement:
 if (Boost_VERSION VERSION_GREATER_EQUAL 106600)
diff --git a/simulation/libsimulator b/simulation/libsimulator
index 8209dcf79..e4fb5e171 160000
--- a/simulation/libsimulator
+++ b/simulation/libsimulator
@@ -1 +1 @@
-Subproject commit 8209dcf79b7ca8769165c240d8a6962b8574dd27
+Subproject commit e4fb5e171a6ed885e7de3192153ba77835d23dee

Thanks for your feedback, this issue should be fixed in https://github.com/Microsoft/vcpkg/commit/0e759709ddc7dbad0b881f9f068f1b04b2092773 with add-datetime-to-boost-libs.patch. Please re-open a issue if it is still an problem for you!


outpost, landing pads do not work

as said above ship landing pads you place in outposts just dont work at all, you will not land on them

Did you make sure your ship fits onto the landing pad? The standard landing pad without the ship builder attached only allows ships less than 40m long land.

Able to reproduce this with even the larger landing pad, albeit inconsistently. Sometimes it lands on the large pad, sometimes it lands on the planets "landing zone" but spawns me at the outpost. Its 50/50 if my ship will be on the landing pad or not.

the game doesnt even let me build ships over 40m even at staryards

Unable to reproduce this issue. My ship consistently lands on the landing pad at each of my outposts.

It seems to happen if your original landing location is close to the outpost (it prefers the original landing occasion sometimes).
It may happen more often if the landing pad is very close to the edge of the outpost circle or intersecting objects.

I've got this issue too. My ship always appears at the landing spot ~400m away from the placed landing pad.

I experienced this issue after building my 2nd or 3rd outpost. I built the large landing pad and no matter what I did the ship would land at the original "Landing Site" every time. I also encountered the outpost bug at this outpost where if you go into build mode and then switch to the overhead view the cursor changes to a spinning circle and you cannot do anything but exit build mode. I thought the landing pad (where I placed it) might be causing both issues. I moved the landing pad to another location in the outpost and both problems were resolved. My ship started landing on the landing pad and I was able to use build mode normally.


Revert "Standardize on SPDX License Header"

Reverts icsharpcode/AvalonEdit#183

See https://github.com/icsharpcode/AvalonEdit/pull/183#issuecomment-509252768 and https://github.com/icsharpcode/AvalonEdit/pull/183#issuecomment-509310173


Teradata, not Terradata

Nitpicking here. Teradata instead "Terradata".

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

ID: cfb42e0e-b056-6e2c-b8dd-8d9541f86fb8
Version Independent ID: 9212ec4a-4862-7df7-0698-b3f01e46f631
Content: What are compute pools? - SQL Server big data clusters
Content Source: docs/big-data-cluster/concept-compute-pool.md
Product: sql
Technology: big-data-cluster
GitHub Login: @MikeRayMSFT
Microsoft Alias: mikeray

@oscarzamora Thank you for the feedback, we're glad to have all the help we can get.
The documentation has been updated.


Simplify load of external custom renderer

Description
Hello,
I would like to point a problem about using custom class renderer.
As this feature was implemented by booting special file location (@see $fileName = strtr($this->reportFormat, '_\\', '//') . '.php';
on lines https://github.com/phpmd/phpmd/blob/2.15.0/src/main/php/PHPMD/TextUI/CommandLineOptions.php#L780-L811
We cannot use any class name.
I'd like to suggest to add a bootstrapping option to include whatever we want before processing PHPMD.
Especially because we cannot specify an autoloader when vendor/bin/phpmd command is invoked.
PHPUnit implement such feature with --bootstrap <file>
PHPLint implement such feature with --bootstrap <file>
PHPStan implement such feature with --autoload-file <file>
Something like will be nice
vendor/bin/phpmd /path/to/source/code '\Vendor\Ns\ReportClassName' ruleset --bootstrap path/to/my/autoloader.php
WDYT ?

Any answer will be greatly appreciated. Thanks !

is this project still maintained ?

yes

In such condition, may I expect an answer please

I think it's an ok suggestion/feature request. We are currently working on the next major version which would be a good time to add this functionality if you are able to.
https://github.com/phpmd/phpmd/blob/3.x/src/main/php/PHPMD/TextUI/CommandLineOptions.php#L682

I'll propose a solution soon !

Got an operation solution: I'll propose a PR tomorrow. In the meantime, If you've time to look on this roadmap, I'll be happy :

Extract Renderer instance creation from \PHPMD\TextUI\CommandLineOptions and add it in \PHPMD\Renderer\RendererFactory
Add --bootstrap option on  \PHPMD\TextUI\CommandLineOptions to have ability to load whatever we need before running analysis, that include of course external autoloader (in charge to load extra Renderer classes)
Load any extra Custom Renderer that follow PSR4 rule by new method \PHPMD\Renderer\RendererFactory::getRenderer()
Introduces a \PHPMD\Renderer\RendererInterface contract that all renderers should follow, even if they do not or can't extends the \PHPMD\AbstractRenderer class

For example (that works)
src/bin/phpmd /shared/backups/bartlett/sarif-php-converters/src/ '\Bartlett\Sarif\Converter\Reporter\PsalmRenderer' cleancode --bootstrap /shared/backups/bartlett/sarif-php-converters/vendor/autoload.php

Finally PR is available. I've checked for CS and Unit Tests (non regression), even if I might changed a little.

As PR was accepted and merged, I'll close this report.


This-function parameter inference fails in object with other typing features

This may relate to https://github.com/Microsoft/TypeScript/issues/10288
TypeScript Version:  2.0.0, installed via typescript@beta
Code
All code under --noImplicitThis flag.
function plainThisBound(m: {[k:string]: (this: string) => string}) {}

plainThisBound({
  method() {
    return this.substr(0) // no error
  }
})

function polymorphicThisBound(m: {[k:string]: <V>(this: string) => V}) {}
polymorphicThisBound({
  method() {
    return this.substr(0) // error in noImplicitThis
  }
})

function unionThisBound(m: {[k:string]: (this: string) => string} & {method(): string}) {}
unionThisBound({
  method() {
    return this.substr(0) // error in noImplicitThis
  }
})

Expected behavior:
All three example should compile, if this parameter is inferred on call site
Or no example should compile, if this must be explicitly annotated
Actual behavior:
Only the first example compiles.

I think some background story will be helpful.
I come up with this when trying to write a more type-safe API for vue.js
Annotating this in vue's API is difficult, so I tried this:
declare class VueTyped<T> {
  data<D>(d: D): VueTyped<T & D>;
  method<M>(m: M & { [k:string]: (this: T) => any }): VueTyped<T & typeof m>
  static new(): VueTyped<{}>
  get(): T
}

var b = VueTyped.new()
  .data({msg: '123'})
  .method({
    method() {
      return this.msgs // expected to have an error for typo
    }
  })
  .get()

on the line this.msgs I expect to have an error. But it does not.

For your polymorphicThisBound, your signature really reads to me as "each of the methods in this object is generic" (see #5737 for something related) whereas I think you really meant to just return {} or any.
In unionThisBound, I believe the issue is that we don't look to the index signature if we have a member of a certain name in the originating type.
Maybe @ahejlsberg has some insights.

Thanks for pointing out the spec.
I understand polymorphicThisBound is quite contrived and not inferred according to the spec.
It seems unionThisBound should be inferred as it has an apparent member of index signature?

The issue here is fixed by #9746. Your example works in that branch, using either a union type for the m parameter or a type constraint for the M type parameter.
This is a pretty neat trick. It is kind of magic how the correct type just pops out at the end.
One thing I noticed is that you get errors if you add additional parameters to the methods you define with method because they aren't assignable to the indexer type. But you can fix that like so:
declare class VueTyped<T> {
  data<D>(d: D): VueTyped<T & D>;
  method<M>(m: M & { [k:string]: (this: T, ...args: any[]) => any }): VueTyped<T & M>
  static new(): VueTyped<{}>
  get(): T
}

One problem that remains is that when you add explicit parameter type annotations to methods in the method argument, the contextual type disappears. We've discussed having contextual types survive in those cases and continue to affect those parameters that don't have type annotations. We should probably look at that again.
Adding @sandersn.

Should be fixed now that #9746 is merged.

@HerringtonDarkholme have you ported this into to the Vue declaration file at all?

@DanielRosenwasser @kaorun343 has already updated declaration file for Vue 2.0 and that declaration file has used a lot of TS2.0 features to give a description for Vue.
My approach needs many API changes which are unsuitable for official Vue to adopt.


How to debug the third party library and entering the source cpp file of the library  in different workspace folder?

Brief Issue Summary
How to debug the third party library and entering the source cpp file of the library  in different workspace folder?
Platform and Versions

Operating System: Ubuntu
CMake Version:  3.18.0-rc2
VSCode Version:  1.57.0
CMake Tools Extension Version:  v1.8.0
Compiler/Toolchain: GCC 7.5.0

Other Notes/Information
The main project use some third party libraries which has source files  header .h file and implementation cpp files in different workspace folder.  These libraries can be compiled into shared or static libraries and installed in system path with CMAKE_BUILD_TYPE set to Debug . The question is I cannot step into the cpp files of the third party libraries in the debuging process. Is there any suggestions to fix this problem. Thanks

This sounds like a cpptools issue.  I will transfer this over to that repository and the discussion can resume there.


do not allow for output during tests

This PR restricts output during test and suppressed existing tests with output.
It also uses $this->expectException() instead of self::expectException() calls as the method is not static.

@IonBazan can I add this PR to the next release with support for PHP8 ?

@nyamsprod yes, it’s just tests improvement 😉


Add comparer for IfAttributes

Add the ability to make comparisons directly in the ifAttribute like:
using BaseTool;
using UnityEngine;

public class MonoScript : MonoBehaviour
{
    public int Number;
    [If("Number == 0")] public int OtherNumber;
}

or:
using BaseTool;
using UnityEngine;

public class MonoScript : MonoBehaviour
{
    public enum MyEnum
    {
        A,
        B
    }
    public MyEnum Enum;
    [If("Enumr == MyEnum.A")] public int Number;
}

I've searched many informations about this and... I think this would be a really long and hard task to do that.
I now understand why tools like OdinInspector aren't free.
I would try maybe someday something, but it is a huge task...


Added option for a local path for permissions file

Added option for a local permissions file path.
Switched to copy for default permissions file and ensured that the default never overwrites existing permissions (if any).
Also fixed warnings with ansible 2.0.

LGTM


Ghidra Support

TODO

Integrate https://github.com/mahaloz/d2d-ghidra-plugin into the install of decomp2dbg, maybe as a release
Finish caching for Global Variables by computing the cache on first run then always updating it
Finish Function Name cache
Allow for ability to configure the port and host of decomp2dbg, maybe just port for now?
Look into a way to start all XMLRPC servers in python under the d2d subname, since Ghidra requires that we name URL


feat(typing): @deprecated versioning, IDE highlighting

Supporting PR to attach to #3454
Notes
Deprecation should be handled using a decorator recognized by static type checkers:

@warnings.deprecated for sys.version_info >= (3, 13)
@typing_extensions.deprecated for earlier versions
Note: need to see how these handle subclassing subclassing seems to be unrecognized statically

Ideally want to have a version keyword-only, required argument
Indicating the altair==x.y.z this was introduced

Consistently use the same decorator to mark all deprecations

Updating existing warnings.warn & @utils.deprecation.deprecated
These should provide a reference for any edge cases, that required extending @typing_extensions.deprecated

Demo
The screenshot below shows the differences in behaviour of each decorator:

This is the ideal situation, where a type checker can identify the deprecation :

https://github.com/dangotbanned/altair/blob/fe1917e3d4986dfa431f428146819622b83b6546/altair/vegalite/v5/api.py#L796-L805
Console output

Sample code block
import typing_extensions as te
from altair.utils.deprecation import deprecated, AltairDeprecationWarning, deprecate
from altair.vegalite.v5.api import (
    selection,
    selection_point,
    selection_multi,
    selection_single,
)

@deprecated("", version="5.4.0", alternative="new_function")
def old_function(*args):
    return args

@te.deprecated("Deprecated in `altair=3.2.1`.", category=AltairDeprecationWarning)
def old_function_2(*args):
    return args

@deprecate(version="5.4.0", alternative="new_function")
def old_function_3(*args):
    return args

old_function()
old_function_2()
selection("point")
selection_multi()
old_function_3()
selection_point("not deprecated")

At runtime, Sample code block outputs:

Output
./../.py:26: AltairDeprecationWarning: alt.old_function was deprecated in `altair=5.4.0`. Use alt.new_function instead.
  old_function()
./../.py:27: AltairDeprecationWarning: Deprecated in `altair=3.2.1`.
  old_function_2()
./../.py:28: DeprecationWarning: Deprecated in `altair=5.0.0`. Use 'selection_point()' or 'selection_interval()' instead.

These functions also include more helpful docstrings.
  selection("point")
./../.py:29: AltairDeprecationWarning: alt.selection_multi was deprecated in `altair=5.0.0`. Use alt.selection_point instead.
  selection_multi()
./../.py:30: AltairDeprecationWarning: Deprecated in `altair=5.4.0`. Use new_function instead.
  old_function_3()

Parameter('not deprecated', SelectionParameter({
  name: 'not deprecated',
  select: PointSelectionConfig({
    type: 'point'
  })
}))

Summary

[x] Use a single decorator, with the implementation of @deprecate but renaming to the prior @deprecated.

@deprecate and the screenshot demo are referencing fe1917e3d4986dfa431f428146819622b83b6546 which also has a class implementation

[x] Add an equivalent (in terms of parameters) warning version for deprecated code paths.

This wouldn't have the same static typing benefits, but would issue consistent messages and reduce repetition like in alt.param
https://github.com/vega/altair/blob/7f05ecbf999766ae1398dcbeb6144c128413026c/altair/vegalite/v5/api.py#L448-L482

Rejected Ideas
Applying @deprecated to individual overloads
This is a pretty interesting feature, but it comes with too many downsides.

Happy overload

Unhappy overload

Implementation

Only applicable to static type checkers, doesn't emit a runtime warning

Working around this would be possible, but not trivial
E.g. calling typing.get_overloads, writing some handler logic

Having the message displayed requires using the typing_extensions decorator

Which means manually maintaining consistent messages
Cannot enforce version included

Even with those conditions met, it still starts with The function "save" is deprecated ... - which is misleading

The deprecated part is the combination of arguments
In this case, the webdriver argument

It adds a lot of extra @overload code, which I don't think is warranted given the other issues

@binste
This isn't a direct fix for #2947, but I think its an improvement for VSCode users.

Nice one! :) Thanks for another great PR.

Thanks @binste

I'm getting the deprecation warnings at runtime which is good but is there any way how I can check if pyright correctly identifies the deprecated function as being a wrapper around te.deprecated? And does mypy support this as well?

In the top-level I've got a workspace (locally) with these settings:

Image

{
	"settings": {
		"python.analysis.diagnosticSeverityOverrides": {
            //"reportDeprecated": "warning",
            "reportInvalidTypeForm": "none",
            "reportMissingImports": "none",
            "reportMissingModuleSource": "none"
            //"reportUndefinedVariable": "none"
        },
		"python.analysis.inlayHints.functionReturnTypes": true,
    	"python.analysis.supportRestructuredText": true,
		"python.analysis.typeCheckingMode": "basic"
	}
}

I think "python.analysis.typeCheckingMode": "basic" is all that is needed for the strikethrough.
The actual diagnostic is "reportDeprecated", so you could try changing that.
When I was testing it, setting that option at all un-special-cases it into a regular warning/error/etc


Can't update jinja2 - version hardcoded

Hello!
Describe the bug
Tried to resolve a security alert:
https://github.com/advisories/GHSA-g3rq-g295-4j3m
But jinja2 version is harcoded here
https://github.com/fishtown-analytics/dbt/blob/77c10713a325d2bee91d1822951ce5d91ccc3278/core/setup.py#L62
So I was not able to bump up the version within my project.
Steps To Reproduce

I've just set this in Pipfile:

[packages]
jinja2 = ">=2.11.3"

Expected behavior
jinja2 to be upgraded
Screenshots and log output
not applicable
System information
Which database are you using dbt with?

[ ] postgres
[ ] redshift
[ ] bigquery
[ ] snowflake
[X] other (specify: not relevant)

The output of dbt --version:
0.19.1-rc1

But basically it was merged in master in: https://github.com/fishtown-analytics/dbt/commit/626f8356015aea77410868bacd5724032473cf1f
so not only
The operating system you're using:
MacOS
The output of python --version:
Python 3.7.7
Additional context
Add any other context about the problem here.

Hey @eugene-nikolaev, dbt started tightly pinning Jinja2 because of a breaking change in a patch release last year (April 2020, see https://github.com/fishtown-analytics/dbt/pull/2318/commits/626f8356015aea77410868bacd5724032473cf1f in https://github.com/fishtown-analytics/dbt/pull/2318).
Thanks for calling out the security advisory. We currently intend to bump the Jinja2 pin (https://github.com/fishtown-analytics/dbt/pull/3077), along with all other pinned dependencies, before the next minor version of dbt.

Resolved by #3077


Replace Variable.data with Variable.array in examples and functions

Variable.array is recommended and using Variable.data directly is discouraged.

The changes to the examples look good.
Some self.data in methods of Variable might be replaced by self._data.  It'll need a careful review on this point.

Thank you for your review this WIP. I found some uses of Variable.data in functions and working on them now.

Some self.data in methods of Variable might be replaced by self._data. It'll need a careful review on this point.

Appreciate this advice

Oh, that is what I'm concerned with and help me avoid violating flake8.
Is it preferred to Passing chainer.Variable directly to Reporter? (Sorry for my lack of understanding)

The fixes

.data -> .array
report(v.data, ...) -> report(v, ...)

can be in a PR or in two PRs.

As far as I know, reporting variables is OK after #2640 (v2).

Jenkins, test this please.

Jenkins CI test (for commit 5c97d0b3d56668afee1107a7cc39fd6c135caa81, target branch master) succeeded!

Jenkins, test this please.

Jenkins CI test (for commit 396ddca78d24201e63ec723d4386bf29503e0d3c, target branch master) succeeded!


Replace 'recent edits' query with a pure ORM version

Alternative fix for #3422 as proposed by @BertrandBordage.

Failing on MySQL:
NotSupportedError: (1235, "This version of MySQL doesn't yet support 'LIMIT & IN/ALL/ANY/SOME subquery'")
I guess we'll need to fall back on raw SQL for MySQL, then. That's a bit rubbish :-(

There may be an ORM workaround, I’ll try to find one in the following days.

Merged in 844cb7746cf0fbc9fbe2ef8772ad2182cc7c0c2e, as the need for a SQL fallback on MySQL isn't a blocker, and is an improvement over the current situation.


rendering quality of title changes in navbar when switching screens (scenery 0.2)

See for example https://github.com/phetsims/beers-law-lab/issues/83.
But this appears to be an issue with all sims.
Observed on Mac OS 10.9.5 with Chrome 40 and Safari 7.1.2.

This is a general issue with HSlider, tracked in https://github.com/phetsims/sun/issues/155

Whoops, closed the wrong issue. Reopening.

Is there a preference between bolder or not, in case I can get a hacky workaround to force the text rendering to be consistent?

That's a question for the designers.  I don't think that bold is particularly effective for text that small.

It looks like the "bolder" text is when Safari/Chrome renders text with subpixel antialiasing. The way we have the Canvas setup currently seems to be triggering Safari/Chrome to render the text without subpixel antialiasing.
Setting CSS fontSmoothing: 'antialiased' makes it consistent, with no switching of quality.

For reference, 'subpixel-antialiased' is the option to prefer the subpixel antialiasing, however it seems to be inconsistently applied to text. We may have to force hardware acceleration anyways on things, so 'antialiased' sounds like the safest route for now.

Assigning to @pixelzoom for verification.

Verified, closing.


Unable to use @ngneat/elf with RxJS 6.x

Which @ngneat/elf-* package(s) are the source of the bug?

@ngneat/elf-requests
@ngneat/elf-state-history

Is this a regression?
Yes
Description
RxJS 7.x exports operators as part of rxjs; developers use import {...} from 'rxjs'
RxJS 6.x exports operators only via rxjs/operators
Unfortunately, some of the code within @ngneat/elf uses formats that ONLY supports RxJS 7.x:

entity-state-history.ts uses import { Subscription, pairwise, filter, map, startWith } from 'rxjs';
request-cache.ts uses import { distinctUntilKeyChanged, Observable, pipe } from 'rxjs';

Please provide the environment you discovered this bug in
Projects using Angular 13.x + RxJS 6.5.x will not work with latest `@ngneat/elf-requests`

Here is a sample `ng build` error output:

Any reason you're not upgrading to v7? It should be seamless.


Pre-Create Federated Users in Azure B2C

Hello All,
Is it possible to pre-create federated users in Azure B2C via the Graph API? Here's the scenario:
I have added to my B2C tenant an Azure AD tenant as an IdP. However, I do not want federated users to be able to signup. I want them to only be able to signin if they are already present in the B2C directory. So, if they are not, they get an error message. So I was thinking I could create the federated users using Graph instead. Below is the request body I attempted to use but I get the error that follows, which says the UPN has to be using one of the domains in the organization. Is it possible to accomplish what I a looking to achieve with Graph? If not by Graph API, how can I accomplish? REST API call in custom policy is not desired.
{
    "givenName": "John",
    "identities": [
        {
            "signInType": "federated",
            "issuer": "abc.com",
            "issuerAssignedId"<EMAIL_ADDRESS>        }
    ],
    "surName": "Doe",
    "mail"<EMAIL_ADDRESS>    "accountEnabled": true,
    "displayName": "John Doe",
    "mailNickname": "jdoe",
    "userPrincipalName"<EMAIL_ADDRESS>    "passwordPolicies": "DisablePasswordExpiration"
}

{

    "error": {
        "code": "Request_BadRequest",
        "message": "The domain portion of the userPrincipalName property is invalid. You must use one of the verified domain names in your organization.",
        "innerError": {
            "date": "2020-08-05T03:45:26",
            "request-id": "xxxxxxxx-xxx-xxxx-xxxx-xxxxxxxxxx"
        },
        "details": [
            {
                "target": "userPrincipalName",
                "code": "InvalidValue"
            }
        ]
    }
}

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

ID: 4a4b8453-d2bc-9c8d-bb16-26fa7e4c6363
Version Independent ID: 160642fc-b5a9-1ebe-7daf-105509b6e2f4
Content: Manage users with the Microsoft Graph API - Azure AD B2C
Content Source: articles/active-directory-b2c/manage-user-accounts-graph-api.md
Service: active-directory
Sub-service: b2c
GitHub Login: @msmimart
Microsoft Alias: mimart

@SB-o-matic  Thanks for reaching out. We will investigate and update the thread accordingly.

@SB-o-matic, yes, it is possible to create federated users via Graph API.
Create a user with social and local account identities:
Create a new user, with a local account identity with a sign-in name, an email address as sign-in, and with a social identity. This is typically used for migration scenarios in B2C tenants.

Note: For local account identities, password expirations must be disabled, and force change password at next sign-in must also be disabled.

Request:
POST https://graph.microsoft.com/v1.0/users
Content-type: application/json

{
  "displayName": "John Smith",
  "identities": [
    {
      "signInType": "userName",
      "issuer": "contoso.onmicrosoft.com",
      "issuerAssignedId": "johnsmith"
    },
    {
      "signInType": "emailAddress",
      "issuer": "contoso.onmicrosoft.com",
      "issuerAssignedId"<EMAIL_ADDRESS>    },
    {
      "signInType": "federated",
      "issuer": "facebook.com",
      "issuerAssignedId": "5eecb0cd"
    }
  ],
  "passwordProfile" : {
    "password": "password-value",
    "forceChangePasswordNextSignIn": false
  },
  "passwordPolicies": "DisablePasswordExpiration"
}

Response:

Note: The response object shown here might be shortened for readability. All the properties will be returned from an actual call.

HTTP/1.1 201 Created
Content-type: application/json

{
<EMAIL_ADDRESS>"https://graph.microsoft.com/v1.0/$metadata#users/$entity",
  "displayName": "John Smith",
  "id": "4c7be08b-361f-41a8-b1ef-1712f7a3dfb2",
  "identities": [
    {
      "signInType": "userName",
      "issuer": "contoso.onmicrosoft.com",
      "issuerAssignedId": "johnsmith"
    },
    {
      "signInType": "emailAddress",
      "issuer": "contoso.onmicrosoft.com",
      "issuerAssignedId"<EMAIL_ADDRESS>    },
    {
      "signInType": "federated",
      "issuer": "facebook.com",
      "issuerAssignedId": "5eecb0cd"
    }
  ],
  "passwordPolicies": "DisablePasswordExpiration"
}

@SB-o-matic, just checking in to see if you have had a chance to see the previous response. Kindly let us know if you need further assistance on this issue or is good to be closed.

Since we have not heard back from you we will now proceed to close this thread. If there are further questions regarding this matter, please tag me in your reply and we will gladly continue the discussion.


[BUG] Editing the azure AD auth provider config before updating the endpoints result in failed to parse the 'roles' field in JWT

Setup

Rancher version: v2.6-head 82bf000 upgraded from v2.6.5
Browser type & version: Chrome

Describe the bug
When a rancher server is upgraded from versions v2.6.5 and below  we would have the old graph end points set. On a rancher server upgrade before updating the endpoints, if we try to edit the config and input the secret we get an error upon authenticating.
To Reproduce

On v2.6.5 rancher server enable Azure AD auth config with standard endpoints
Upgrade the rancher server to v2.6-head
Do not update the endpoints but click on edit config
Input the secret value and save

Result
Upon authenticating we run into the issue server error while authenticating: failed to parse the 'roles' field in JWT - either the token is malformed or lacks permissions
Following errors are seen in the rancher server logs:
2022/09/19 12:52:04 [INFO] Failed to decode the 'metadata' field of the AuthConfig. Attempting to decode 'annotations' at the top level.
2022/09/19 12:52:04 [INFO] Failed to decode the 'annotations' field of the AuthConfig.
2022/09/19 12:52:09 [INFO] failed to get the access token from cache: access token not found
2022/09/19 12:52:09 [INFO] attempting to acquire the access token by credential
2022/09/19 12:52:09 [ERROR] Unknown error: server error while authenticating: failed to parse the 'roles' field in JWT - either the token is malformed or lacks permissions
2022/09/19 12:59:41 [ERROR] Error during subscribe websocket: close sent

Expected Result
Expected the edit config to work fine without any errors.
Additional context
Found while validating https://github.com/rancher/dashboard/issues/6868
Noticed that the UI is sending the existing graph endpoints
All the required permissions are present in the azure portal for the app.

/backport v2.6.9

QA testcases
Case 1

Set up Azure AD on Rancher v2.6.6.
Upgrade Rancher to v2.6-head.
Try logging out and in. No errors.
Edit the configuration by supplying the Application Secret value and saving. No errors.
Try logging out and in. No errors.
Update the endpoints in the UI. No errors.
Try logging out and in. No errors.
Edit the configuration by supplying the Application Secret value and saving. No errors.
Try logging out and in. No errors.

Case 2

Start with Rancher v2.6.6. Do not setup Azure AD.
Upgrade Rancher to v2.6-head.
Set up Azure AD. No errors.
Try logging out and in. No errors.
Edit the configuration by supplying the Application Secret value and saving. No errors.
Try logging out and in. No errors.

Case 3

Start with Rancher v2.6-head.
Set up Azure AD. No errors.
Try logging out and in. No errors.
Edit the configuration by supplying the Application Secret value and saving. No errors.
Try logging out and in. No errors.

Verified following cases on v2.7-head b3c5e9f
Case1

Start with Rancher v2.7-head.
Set up Azure AD. No errors.
Try logging out and in. No errors.
Edit the configuration by supplying the Application Secret value and saving. No errors.
Try logging out and in. No errors.

Case 2

Start with Rancher v2.6.5. Do not setup Azure AD.
Upgrade Rancher to v2.7-head.
Set up Azure AD. No errors.
Try logging out and in. No errors.
Edit the configuration by supplying the Application Secret value and saving. No errors.
Try logging out and in. No errors.

Case3:

Set up Azure AD on Rancher v2.6.5.
Upgrade Rancher to v2.7-head.
Try logging out and in. No errors.
Edit the configuration by supplying the Application Secret value and saving. No errors.
Try logging out and in. No errors.
Update the endpoints in the UI. No errors.
Try logging out and in. No errors.
Edit the configuration by supplying the Application Secret value and saving. No errors.
Try logging out and in. No errors.

Case4:

Set up Azure AD on Rancher v2.6.8.
Upgrade Rancher to v2.7-head.
Try logging out and in. No errors.
Edit the configuration by supplying the Application Secret value and saving. No errors.
Try logging out and in. No errors.

The backport is for v2.6.10.


No new folder was created

Problem encountered on https://dotnet.microsoft.com/learn/web/aspnet-hello-world-tutorial/create
Operating System: windows
Provide details about the problem you are experiencing. Include your operating system version, exact error message, code sample, and anything else that is relevant.

@mazharwhite can you provide details about your problem?

i followed the setup for setting up when i ran the command nothing was created in the directory i was running the command also tried changing the directory file but alas still facing the same issue

@mazharwhite - Are you still having troubles? What OS are you on? I presume you're referring to these commands?
dotnet new webApp -o myWebApp --no-https
cd myWebApp

2 weeks no response, closing. Feel free to reopen if there is more info available. Thanks!


Add step to remove/toggle off "Graphics Job" to develop for Hololens 2 using "Getting Started Tutorial"

Link to Slack conversation: https://holodevelopers.slack.com/archives/C1CQKRQM6/p1592520135296500
Following the "Getting Started" tutorial does not work successfully, unless you do an additional step of turning off "Graphic Jobs" within Unity.
This information should be added to this page https://docs.microsoft.com/en-us/windows/mixed-reality/mrlearning-base-ch1, so that developer's working on Hololens 2 can get their apps to work successfully when following the tutorial.

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

ID: 62d386bb-3f93-d434-e7b3-28c58ea673e9
Version Independent ID: a1a9b02f-66a0-feb0-7a08-9a8d2cf398d1
Content: Getting started tutorials - 2. Initializing your project and first application - Mixed Reality
Content Source: mixed-reality-docs/mrlearning-base-ch1.md
Product: mixed-reality
Technology: mr-dev
GitHub Login: @jessemcculloch
Microsoft Alias: jemccull

Closing issue as mentioned in the Slack thread. The tutorial will be eventually updated to LTS, and this problem should be solved during that tutorial update.
https://holodevelopers.slack.com/archives/C1CQKRQM6/p1592701211350600?thread_ts=1592631613.333100&cid=C1CQKRQM6


Reduce ProcessQuote bottleneck.

By default, ProcessQuote receives a full order book from a venue, so
sorting can be quite long. It may not have time to process the message
before receiving a new one, to the process message inbox will grow
reducing available RAM.
One can reproduce by setting depth for bitmex more than 25.
iex(2)> Elixir.Tai.Markets.ProcessQuote_bitmex_xbtusd |> Process.whereis |> Process.info
[
  registered_name: Tai.Markets.ProcessQuote_bitmex_xbtusd,
  current_function: {:lists, :rfmerge2_2, 5},
  initial_call: {:proc_lib, :init_p, 5},
  status: :running,
  message_queue_len: 951,
  links: [#PID<0.569.0>],
  dictionary: [
    "$initial_call": {Tai.Markets.ProcessQuote, :init, 1},
    "$ancestors": [Tai.VenueAdapters.Bitmex.StreamSupervisor_bitmex,
     Tai.Venues.StreamsSupervisor, Tai.Supervisor, #PID<0.495.0>]
  ],
  trap_exit: false,
  error_handler: :error_handler,
  priority: :normal,
  group_leader: #PID<0.494.0>,
  total_heap_size: 165757675,
  heap_size: 66222786,
  stack_size: 35,
  reductions: 171878258,
  garbage_collection: [
    max_heap_size: %{error_logger: true, kill: true, size: 0},
    min_bin_vheap_size: 46422,
    min_heap_size: 233,
    fullsweep_after: 65535,
    minor_gcs: 2
  ],
  suspending: []
]
iex(3)> Elixir.Tai.Markets.ProcessQuote_bitmex_xbtusd |> Process.whereis |> Process.info
[
  registered_name: Tai.Markets.ProcessQuote_bitmex_xbtusd,
  current_function: {:erlang, :>, 2},
  initial_call: {:proc_lib, :init_p, 5},
  status: :running,
  message_queue_len: 1009,
  links: [#PID<0.569.0>],
  dictionary: [
    "$initial_call": {Tai.Markets.ProcessQuote, :init, 1},
    "$ancestors": [Tai.VenueAdapters.Bitmex.StreamSupervisor_bitmex,
     Tai.Venues.StreamsSupervisor, Tai.Supervisor, #PID<0.495.0>]
  ],
  trap_exit: false,
  error_handler: :error_handler,
  priority: :normal,
  group_leader: #PID<0.494.0>,
  total_heap_size: 174416259,
  heap_size: 66222786,
  stack_size: 39,
  reductions: 217805691,
  garbage_collection: [
    max_heap_size: %{error_logger: true, kill: true, size: 0},
    min_bin_vheap_size: 46422,
    min_heap_size: 233,
    fullsweep_after: 65535,
    minor_gcs: 2
  ],
  suspending: []
]

Also, I'd recommend rewriting the module using ETS ordered_set, so bids/asks ordering will be highly optimized.

@ihorkatkov the problem with this approach is that the price points will not be ordered. BitMEX quote_depths > 25 are experimental for the performance reasons you outlined. Can you submit a PR for the ETS ordered_set? I'd love to see how it performs.

Closing due to inactivity


Locked V1 of Grape to Rack 2

IMPORTANT!
The base branch that this PR points to should be changed to a 1.x (or whatever the name will be).
Includes reverting most of the changes added by https://github.com/ruby-grape/grape/pull/2353, which should only now be in the V2 version of Grape.

Pull Request Test Coverage Report for Build<PHONE_NUMBER>

15 of 15 (100.0%)  changed or added relevant lines in 7 files are covered.
No unchanged relevant lines lost coverage.
Overall coverage decreased (-0.001%) to 99.044%

Totals

Change from base Build<PHONE_NUMBER>:
-0.001%

Covered Lines:
15127

Relevant Lines:
15273

💛  - Coveralls


CSS: grid-template-columns

There is no relevant data about this css property.
Read more: https://css-tricks.com/introduction-fr-css-unit/

Part of http://caniuse.com/#feat=css-grid


optimal interpolation examples

I'd like to add the following examples to the code:

[ ] Optimal interpolation of a time series (used in the tests)
[ ] Optimal interpolation of a 2D field
[ ] Optimal interpolation of a 1D field

All of can use AlgebraicArrays.jl

It would be great to add a 2D objective mapping test to BLUEs! 1D is already handled in the tests, as you note above.
Also note that the term "objective mapping" better represents what you want to do, as this algorithm is not always optimal and it is not interpolation.
If you would like to make an example or tutorial rather than a test, then it is better to do it in a new environment that uses BLUEs.jl as a dependency.

Three objective mapping notebooks now exist in the notebooks branch.
2.9_objectivemapping.jl  - pedagogical example from Dynamical Insights From Data class
objectivemapping_blues.jl - objective mapping that uses BLUEs to solve the Gauss-Markov problem
objectivemapping_BLUES_AlgebraicArrays.jl - full featured notebook using whole ecosystem, including BLUEs for the Gauss-Markov problem, AlgebraicArrays.jl to handle conversion from a 2D grid to matrices and vectors, and DimensionalData.jl for labeling the variables.
Take a look. If there are no problems, we can close this issue as completed.