Adding Rayon support to Rand

I have made a PR to Rand to add support for Rayon. It is very much in the 'just exploring' phase. It would be great if someone who is more familiar with Rayon could weight in.
We have one basic problem: every PRNG needs to store its state somewhere and mutate it to produce the next random number. Just cloning the state would produce two identical streams of random numbers.
One solution that works right now is to use thread_rng() https://github.com/rust-lang-nursery/rand/issues/398. It does nothing special (from our perspective), it just sets up one RNG in thread-local storage for every thread in Rayons thread-pool. This may be a costly operation, but only has to be done once during the lifetime of the application. At least if the thread-pool also remains available all that time.
What I am exploring is somehow splitting/reseeding an RNG every time Rayon splits a job. If this a good idea at all, or in no way better than using RNGs in thread-local storage, is something to explore. And so are the details around splitting RNGs and keeping things correct, but that seems like a problem for us in Rand. It would have the advantage that users can choose their favourite, or most appropriate, RNG.
Can someone review the approach, and maybe answer some questions?
Is implementing IndexedParallelIterator, and setting the number of values to generate up front the right choice? I tried working with UnindexedProducer, but that expects to somehow finish by itself, which is something an RNG never does.
Is my abuse of DoubleEndedIterator okay, to implement the necessary traits? It will just produce the next random number like Iterator, it can't produce something like the previous random number. For normal PRNGs that is a computationally expensive operation (and not supported by Rand), and for cryptographic PRNGs impossible.
It is hard to predict what will happen to the statistical quality of PRNGs when they are split off many times, and only very short runs are used. So it seems sensible to set a minimum for the number of items that should be used from the PRNG, to hopefully keep similar statistical properties as one PRNG used continuously. Is setting a hard limit with min_len the best approach? Which Rayon supports increasing by users?
And from the final comment (currently): I wonder if Rayon is designed do deal with situations like ours, where every split of the job is not a basically free operation? So ideally it would split the job as little as possible, instead of splitting it into many manageable chunks. I don't know what drives Rayons decision here...

It would have the advantage that users can choose their favourite, or most appropriate, RNG.

Considering that one of the reasons to choose an RNG is to have control over reproducibility, which cannot be guaranteed when using automatic migration of some samples to sub-RNGs, there is less need to have this flexibility.

It is hard to predict what will happen to the statistical quality of PRNGs when they are split off many times, and only very short runs are used.

If we switch streams and ensure each thread has a unique stream this isn't an issue. If we use freshly-seeded RNGs this is harder to reason about; with CSPRNGs there is no problem since these must ensure any output cannot be used to predict future output; with some simple PRNGs like Xorshift this is definitively a problem (without an extra permutation step); with other PRNGs I don't think statistical quality/independence is easy to reason about, though e.g. the PCG family are supposed to be difficult to predict.
There is also a potential circular dependency problem.

Wouldn't it be much simpler if the thread pool managed the RNGs? This should also be more performant, because then the RNG initialization is only done once per worker instead of once per stolen work.
This could possibly implemented in ThreadPoolBuilder:
/// For each thread, initialize an RNG from the thread ID.
pub fn with_rng<C>(self, rng_constructor: C) -> ThreadPoolBuilder where
    C: Fn(usize) + Send + Sync + 'static -> impl rand_core::RngCore,

Isn't that equivalent to using thread_rng()? Not quite I suppose; it could use SmallRng or another PRNG instead for some applications and could maybe get its entropy from somewhere other than EntropyRng.

Yes, you could choose and initialize the RNG, which is not possible with thread_rng().
Interestingly enough, rayon already uses an internal per-thread RNG as an implementation detail for deciding which job to steal:
pub struct WorkerThread {
    /// the "worker" half of our local deque
    worker: Worker<JobRef>,

    index: usize,

    /// are these workers configured to steal breadth-first or not?
    breadth_first: bool,

    /// A weak random number generator.
    rng: UnsafeCell<rand::XorShiftRng>,

    registry: Arc<Registry>,
}

Does it make sense to expose this RNG to the user?
Does it make sense to let the users swap out this RNG for another? This can break rayon if the RNG is pathological.
Does it make sense to have an optional user-defined RNG in addition to the internal one?

@pitdicker

Is implementing IndexedParallelIterator, and setting the number of values to generate up front the right choice? I tried working with UnindexedProducer, but that expects to somehow finish by itself, which is something an RNG never does.

We ran into a similar dilemma with repeat in #397, and decided to leave it unindexed and infinite, but also add a repeatn which is bounded.  Repeat also has its own take and zip methods to turn it into RepeatN or Zip<RepeatN, _>.  I think this design is OK, but I'm not sure if it really gets used.
But once you implement IndexedParallelIterator, you do need to be precise with the splits and how many items you produce.  If nothing else, collect_into_vec() will panic if it gets the wrong number of items.

Is my abuse of DoubleEndedIterator okay, to implement the necessary traits? It will just produce the next random number like Iterator, it can't produce something like the previous random number. For normal PRNGs that is a computationally expensive operation (and not supported by Rand), and for cryptographic PRNGs impossible.

If "normal" PRNGs are supposed to be deterministic, then I would say this is problematic, but may be something you could just paper over as a documented limitation.  The simplest test is that .rev() could be observed not to actually reverse anything.

It is hard to predict what will happen to the statistical quality of PRNGs when they are split off many times, and only very short runs are used. So it seems sensible to set a minimum for the number of items that should be used from the PRNG, to hopefully keep similar statistical properties as one PRNG used continuously.

I don't know too much about PRNGs, but it seems to me that one which actually degrades on splitting is not really suitable here.

Is setting a hard limit with min_len the best approach? Which Rayon supports increasing by users?

Suppose I tried to zip your random source with my own vector of 100 heavy work items.  Your forced min_len of 100 means I won't get any parallelism at all!
Generally, I think splitting isn't something you should have to worry much about.  Rayon will start with approximately the number of threads, and only split further when work is actively stolen.  This can lead to small splits at the tail end of a run, but it's usually not noticeable except in microbenchmarks.  Plus your benchmark can always call with_min_len itself, just as a user could.

I wonder if Rayon is designed do deal with situations like ours, where every split of the job is not a basically free operation? So ideally it would split the job as little as possible, instead of splitting it into many manageable chunks. I don't know what drives Rayons decision here...

Is your split so expensive that it would be noticeable compared to practical use of this data?  Your benchmarks are just collecting the random data, so the workload is basically just a memory write.
@vks - I don't think we'd want to make rand a public dependency of rayon-core, at least not until rand is 1.0.  If anything, I'm wondering if we even need to use rand internally, because our needs are so simple -- a direct implementation of a weak PRNG would probably suffice.

Taking a step back - If you just had some RNG wrapper which resets/reseeds when cloned, then I think one could just use that as the value for map_with.  Then rand and rayon don't need to implement anything specifically for each other.  It would be used something like:
(0..100_000).into_par_iter().map_with(RngCloner(r), |r, i| i + r.gen())...

Would this meet your needs?  (Are your needs even well defined?)

Thank you for the reply, very helpful!

We ran into a similar dilemma with repeat in #397, and decided to leave it unindexed and infinite, but also add a repeatn which is bounded. Repeat also has its own take and zip methods to turn it into RepeatN or Zip<RepeatN, _>. I think this design is OK, but I'm not sure if it really gets used.

Yes, that is exactly my problem! In one way it looks a bit ugly (zip or take have to be the first method in the chain), on the other hand very smart. I'll try the same thing.

But once you implement IndexedParallelIterator, you do need to be precise with the splits and how many items you produce. If nothing else, collect_into_vec() will panic if it gets the wrong number of items.

Returning the right number of items seems easy, I now just use a counter.

If "normal" PRNGs are supposed to be deterministic, then I would say this is problematic, but may be something you could just paper over as a documented limitation.

 But I understand why (reproducibility of results), so definitely something to document. But it does not seem like Rayon depends on DoubleEndedIterator for correctness or something, only to offer the rev method? In that case the ability to collect results seems worth the trade-off to me.

Suppose I tried to zip your random source with my own vector of 100 heavy work items. Your forced min_len of 100 means I won't get any parallelism at all!

I have a little trouble imagining when somebody would do so, but it would not be good style then... Maybe it is best to just recommend users use with_min_len, but I'll think a bit more about the ensuring the quality.

Is your split so expensive that it would be noticeable compared to practical use of this data?

For some RNGs it could be basically free, for others I suspect one split can easily take as much time as 50 iterations of practical use (and for HC-128 something like a 1000 iterations, but I suppose that just disqualifies it here).

Taking a step back - If you just had some RNG wrapper which resets/reseeds when cloned, then I think one could just use that as the value for map_with.

That is an interesting function! Sounds almost as something we could use. But how do you prevent a second clone from ending up the same as the first clone? Except by always reseeding  the RNG with something like OsRng? On a split I both modify the source iterator/RNG and produce another one.

Taking a step back - If you just had some RNG wrapper which resets/reseeds when cloned, then I think one could just use that as the value for map_with.

That is an interesting function! Sounds almost as something we could use. But how do you prevent a second clone from ending up the same as the first clone? Except by always reseeding the RNG with something like OsRng? On a split I both modify the source iterator/RNG and produce another one.

We don't prevent them from looking the same, nor does rayon even care.  But with a custom wrapper, Clone can behave however you like.  It could even use Cell or RefCell if you really need to modify the source -- note the map_with type is not required to be Sync, unlike most things rayon uses.

I'm not a specialist of rayon at all, but about parallel independent random generator, you should look at the Lecuyer random generator. It allows one to have parallel independent (reproducible) streams of random numbers.
Here is a link to the research paper: https://www.iro.umontreal.ca/~lecuyer/myftp/papers/handstat.pdf
And a link to some implementation: https://www.iro.umontreal.ca/~lecuyer/myftp/streams00/

@cuviper

I don't think we'd want to make rand a public dependency of rayon-core, at least not until rand is 1.0.

Does this matter if it is behind a feature flag?

Would this meet your needs?

I think it would be nice to make it reproducible given a seed, but I'm not sure whether that is feasible with the work-stealing approach.

I don't think we'd want to make rand a public dependency of rayon-core, at least not until rand is 1.0.

Does this matter if it is behind a feature flag?

I don't see how the flag changes that consideration -- it's still a first-class part of the API for semver concerns.  Even our former "unstable" feature caused problems when we made any changes, which is why we switched to the out-of-band --cfg rayon_unstable flag to enable it. (making it harder to opt into)

I think it would be nice to make it reproducible given a seed, but I'm not sure whether that is feasible with the work-stealing approach.

Note that any kind of thread-local solution also fails to be reproducible, since you can't control which thread each part will run on.  Only an indexed Producer has a chance at generating deterministic results.

Thanks for all the help so far! I am going with the wrapper approach. Wrote a lengthier comment a couple of days ago in this issue, but somehow it is lost...
Using Cell does the trick.
And if a user wants reproducible results I am thinking of adding a comment somewhere in our documentation to use both with_min_len and with_max_len. I don't think it really fits the philosophy of Rayon, with work-stealing and making the parallelism basically invisible. But it fits the common case where random number are not expected to be deterministic. And it also fits the solution I believe larger simulations in other languages now use of just splitting up the job over the number of cores, or some multiple of that.
@cuviper For me this issue can be closed. But as there are some more ideas floating around in this issue, can I leave deciding on that to you?

There's also #136 as an enhancement request for a parallel PRNG.  I'll file a quick bug about the possibility of rolling our own PRNG for rayon-core.  If there are any other individual ideas that should be tracked, please comment or raise them again in separate issues!


SAK-31846 Email tool options Add to Email Archive checkbox misaligned.

@Johnson-Mickey , please submit a licensing agreement to<EMAIL_ADDRESS>.
If you doing this work on behalf of your employer, we require a CCLA (Corporate Contributor License Agreement) and an ICLA (Individual Contributor License Agreement).
If you are working on your own then only an ICLA is needed.
Please read about Apereo Licensing and fine the CLA forms to use at
https://www.apereo.org/licensing
Thanks!

@ncaidin
CCLA sent March 16, my ICLA was sent a few moments ago.
Thank you.

Sorry for the delay. The licensing agreements have been received.


New demobot

The delete functionality is messing up. I know it's related to deleting things that I'm currently iterating through. Also I want to be able to delete the message when there are no embeds left but interaction.message 404s.

Okay delete functionality appears to be working. I also added return type hinting and docstrings to some functions that were missing them.


Add Upgrade Enrollment Dialog

Pre-Flight checklist

[ ] Screenshots and design review for any changes that affect layout or styling

[x] Desktop screenshots
[ ] Mobile width screenshots

[ ] Testing

[ ] Code is tested
[x] Changes have been manually tested

What are the relevant tickets?
Fix #386
What's this PR do?
Add Upgrade Enrollment Dialog
design: https://projects.invisionapp.com/share/KH11D3ZN53GC#/screens/455477372
How should this be manually tested?
Set up a product page for a course. Go to the product page as a learner and try to enroll.

@annagav looks like a python test is failing

@rhysyngsun it is fixed now. Thanks

@rhysyngsun I addressed your comments, thank you

LGTM, although there is a conflict from another PR that got merged.


Wait-RSJob and Receive-RSJob pipeline streaming

Is there currently a way to output Jobs as they complete from the pipeline?
Currently, if you run code like this:
1..100 | Start-RSJob -Throttle 25 {Start-sleep -seconds 2; $_} | Wait-RSJob -ShowProgress | Receive-RSJob
You will see the progress track, but no output is produced until all jobs complete. Would it be possible for Wait-RSJob to output jobs as they complete, rather than all at once?
Receive-RSJob has this same problem. It collects all pipeline input during process and waits to spit it all out in the end block. I'd much rather see it output Jobs during the process block.
This is incredibly important when there is a chance of a job hanging. Some WMI calls can hang in a pretty bad way, and allowing streaming output means that any jobs that finished (usually all but one) can have their output written via Export-csv or similar, even if one hangs.
Is there a way to submit a fix for this? I ended up writing a working fix for both Wait-RSJob and Receive-RSJob before I pressed the submit button.

The Wait-Job was by design with everything being outputted at the end to mirror the PSJobs infrastructure with Wait-Job. That being said, if you want, you can fork my repo and add the changes and then submit a pull request to me so I can review the code.
I see your point about being able to stream the jobs as they complete onto the next cmdlet/function in line and will need to give this some thought. I think an extra parameter to support this might be a good idea to allow the jobs to stream through Wait-RSJob. With Receive-RSJob, there definitely is no reason why that shouldn't be streaming the output vs. display in the End block.

I was going to suggest a switch to control the behavior.  -Passthru or something.  Not what Passthru traditionally does, but in this case you're no longer outputting the job object but the job output so I think it could work.

Is there a good reason for Wait-RSJob to behave that way beyond it mirroring Wait-Job?
I can't think of any case where streaming the output would be detrimental (this applies to Wait-Job as well). Whenever you are piping the output of Wait-RSJob to another pipeline enabled cmdlet/scriptblock there will always be a performance benefit and no downside. Anyone that wants all the jobs to be processed at once can simply assign the output of the Wait-RSJob pipeline to a variable, then process that variable after, no real need for a switch due to how the pipeline functions.
I'll take a look at the forking and pull request. I've not used Github at all beyond downloading. I have an edit that should keep all original functionality intact while enabling streaming output.

Well, to me the idea of a Wait type of command is that you are waiting for everything to complete before moving on. Allowing items to be passed thru the pipeline while it is supposed to be waiting means that it really isn't "waiting" anymore. This is based on the verb guidance here: https://technet.microsoft.com/en-us/library/system.management.automation.verbslifecycle.wait(v=vs.85).aspx

That's actually a good point. I admit I have never really used jobs since I read from many sources that they didn't perform well with the overhead for a large number of jobs. I jumped onto the runspace concept pretty much as I was learning powershell after seeing it in practice and reading about it on a number of articles (including your own), eventually settling on Invoke-Parallel for my needs.
When I look at Wait-RSJob I see it as a method to wait for a job to finish before returning. I also know that I would always want to see those jobs either in my console as they process (if I'm not piping it anywhere or capturing the output, or have the next command in line to immediately start processing on that object for performance.
To be precise, the description of Wait you linked specifies pausing an operation before continuing. That is a vague enough definition that it could also be applied to just the one object or the whole collection. Even if it is streaming output, it's still waiting for the job to complete before sending it off, and the command still won't return completely until all jobs are processed. It just helps performance within a pipeline without affecting its non-pipeline behavior. It's still waiting, just on a per object context, instead of a whole collection context. The usage and end result is still the same, but it provides a bit better pipeline performance and a built in countermeasure to hung runspaces.
Also, there isn't any functionality currently present in the module that allows for jobs to .be started and returned as soon as possible down a pipeline without writing your own custom version of a wait function.

Another option would be a switch in Receive-Job:  -Wait, or -Streaming, something along those lines that would change its behavior.

One workaround is to do something similiar to the following after starting the jobs:
while (Get-RSJob)
{
Start-Sleep -Milliseconds 200
$done = Get-RSJob |
Where-Object State -in 'Completed','Failed','Stopped','Suspended','Disconnected'
$done | Receive-RSJob
$done | Remove-RSJob
}

True, you can do that. At that point your literally just re-writing Wait-RSJob though. Wait-RSJob already does a loop like that, except it waits for all jobs to be finished and returns the jobs, rather than feeding them to Recieve-RSJob. It's expected that you do this after.
I'd much rather it either be implemented by default via the pull request I made, or made into a switch on Wait-RSJob as someone else suggested. My preferred workaround was to just alter the behavior of Wait-RSJob myself.

Have you been able to re-submit a PR against my latest updates? I have more people hit me up in favor of streaming for Wait-RSJob and would like to integrate that as well as RecieveRSJob into the module.

Sorry, I only just got back from a small 4 day vacation, and quite sick at that too. I'll see if I can make a new fork today and resubmit

Cool! I've merged the PR for Receive-RSJob. Thanks for that! If you want, go ahead and do another for Wait-RSJob.

Fixed with latest PR.

Is there a way to wait for the first runspace to finish and return that runspace as a variable? PowerShell jobs has the command "Wait-Job -Any" which will return the first Posh job to finish.
It would be useful to have a switch like this for Wait-RSJob so that you may remove the completed runspace and spin up a new one, keeping the total parallel runspaces at the max capacity.

I see the PR is merged however due to me being newbie on PS cannot figure how to make it work. The progress is shown ok but the For-each is invoked after all all jobs finished
$projects|start-rsjob  $sb -argumentlist $paramObject -Throttle $throttle -ModulesToImport $modules |Wait-RSJob -ShowProgress |Receive-RSJob  |ForEach-Object{

so i tried the next declaration
$projects|start-rsjob  $sb -argumentlist $paramObject -Throttle $throttle -ModulesToImport $modules |Wait-RSJob -ShowProgress  |ForEach-Object{
    $j=Get-RSJob $_ |Receive-RSJob

which works fine and $j contains the return values however it looks I am doing something wrong as I do not pipe my commands.
needs some expert advice please

please see discussion on #180. I implement this in my fork

thanks
any plans to for an entry in PSGallery for your fork?

no, at least until next year :)


dapp corpora import with filename as speaker name

Speakers have multiple recordings each, meaning data from multiple recordings aren't being mapped to the right speaker.

Steps to fix this:

Move files associated with each speaker into speaker-level directories
Change the MAUS parser in PolyglotDB to use DirectorySpeakerParser instead of the filename parser.


feat!: Added import table feature and AWS provider v5 upgrade

Description
Adds import_table functionality.
Motivation and Context
https://github.com/hashicorp/terraform-provider-aws/pull/27253
https://github.com/hashicorp/terraform-provider-aws/pull/33802
Breaking Changes
Yes, AWS provider version v5 upgrade.
How Has This Been Tested?

[x] I have updated at least one of the examples/* to demonstrate and validate my change(s)
[x] I have tested and validated these changes using one or more of the provided examples/* projects

[x] I have executed pre-commit run -a on my pull request

Please update the examples section in the root README.md and rename examples/s3_import to examples/s3-import (like we have in most other recent terraform-aws-modules.

This PR is included in version 4.0.0 :tada:


userScopes is not appearing on install URL

Description
I am creating a slack app with oauth authorization, I have setup scopes and userScopes at backend site but when I inspect the URL after click on "Add to slack" I cant see the userScopes, I just see scopes.
What type of issue is this? (place an x in one of the [ ])

[X] bug
[ ] enhancement (feature request)
[ ] question
[ ] documentation related
[ ] example code related
[ ] testing related
[ ] discussion

Requirements (place an x in each of the [ ])

[X] I've read and understood the Contributing guidelines and have done my best effort to follow them.
[X] I've read and agree to the Code of Conduct.
[X] I've searched for any related issues and avoided creating a duplicate issue.

Bug Report
Code at backend site
const app = new App({
    signingSecret: process.env.SLACK_SIGNING_SECRET,
    clientId: process.env.SLACK_CLIENT_ID,
    clientSecret: process.env.SLACK_CLIENT_SECRET,
    stateSecret: 'XXXXXXXXX',
    scopes: ['channels:history', 'channels:read', 'chat:write', 'chat:write.public', 'groups:history', 'groups:write', 'im:history', 'mpim:history', 'groups:read', 'im:read', 'mpim:read'],
    userScopes: ['channels:read', 'groups:read', 'im:read', 'mpim:read'],
    installationStore: {
       .........
    },
    logLevel: LogLevel.DEBUG
})

URL after click on "Add to slack" without userScopes
https://xxxxxx.slack.com/oauth?client_id=xxxxxxx&scope=channels:history,channels:read,chat:write,chat:write.public,groups:history,groups:write,im:history,mpim:history,groups:read,im:read,mpim:read&user_scope=&redirect_uri=&state=xxxxxxxx&granular_bot_scope=1&single_channel=0&install_redirect=&tracked=1&team=
Reproducible in:
package version: "@slack/bolt": "^3.3.0"
node version: v16.1.0
OS version(s): MacOS BigSur 11.3.1
Steps to reproduce:

Create the app, enable bot and user scopes, enable public distribution
Setup at backend site
Go to https://mydomain/slack/install
Click on "Add to slack"
Inspect URL

Expected result:
Show userScopes in installation URL
Actual result:
userScopes is empty
Attachments:
Logs, screenshots, screencast, sample project, funny gif, etc.

Hey @aaaguirrep,
I believe you have to pass userScopes inside installerOptions. That should fix it. Let me know if it works!

Thanks @stevengill it worked.


Single Input - validation for currency

I'm hoping to set up validation on a 'single input' field that checks that a value entered includes a $ and numbers (e.g., $123.30, or at least $123).  Are there any plans to include a validator for this?
Thanks

@bowtree00 You may use inputType: "number" for text question and/or add regex
validators: [{ type: "regex", regex: "^[+-]?[0-9]{1,3}(?:,?[0-9]{3})*(?:.[0-9]{2})?$", text: "Please enter a number" }]

Great, thank you!


liquibase generatechangelog not working as expected with enums

Environment - Docker - liquibase:4.5.0
Liquibase Version: 4.5.0
Liquibase Integration & Version: CLI
Liquibase Extension(s) & Version:
Database Vendor & Version: mysql 8.0
Operating System Type & Version:
Description
The changelog generated by liquibase generateChangeLog does not work as expected for ENUM. It provides values in reverse order.
Steps To Reproduce

Create source db and a database test
In the database
CREATE TABLE sizes (   size ENUM('small', 'large') );
Now run liquibase generateChangeLog

Actual Behavior
    <changeSet author="alpha (generated)" id="1637671757006-1">         <createTable tableName="sizes">             <column name="size" type="ENUM('large', 'small')"/>         </createTable>     </changeSet>
It creates ENUM large than small
Expected/Desired Behavior
It directly affects functionlity
https://stackoverflow.com/questions/17603907/order-by-enum-field-in-mysql/17603993
Screenshots (if appropriate)
If applicable, add screenshots to help explain your problem.
Additional Context
Add any other context about the problem here.

Hi @nimishagarwal76 Thanks for the alert on this issue.  I think ENUMs are User Defined Types. I could be wrong.  Is the problem that is creates the ENUMs in the wrong order?
If so, we can add it to the list of issues we are processing.
If you have a fix, please create a PR.

Yes, enums are used defined types. Now if I create enum('A', 'B', 'C'), to have everything consistent, generated sql should be enum('A', 'B', 'C'). But liquibase generates enum(CBA) .
This works fine in stuff like mysqldump.

This is still an issue in 4.15.0.

I also have the same problem in 4.11.0
The order of enum is reversed.


Test Issue

Hi,
I'm going through the Code Kata which by the way is a great way to learn. I'm having an issue with one of the exercises.
In ExercisesAdvancedFinder testQ5a and testQ5b
//-------------- Question 5 ------------------------------------------------------
// Find the average age of all Person objects.  This is a two stage question:
// 1) Find the average without using any special Mithra features.
// 2) Find the average using Mithra's AggregateList feature.

    public double getAverageAgeNormalMithra()
    {
        return  new PersonList(PersonFinder.all()).stream().mapToInt(p -> p.getAge()).average().getAsDouble();
    }

    @Test
    public void testQ5a()
    {
        Assert.assertEquals(34.75, this.getAverageAgeNormalMithra(), 0.0);
    }

    public double getAverageAgeUsingAggregateList()
    {
        AggregateList agg = new AggregateList(PersonFinder.all());
        agg.addAggregateAttribute("avgAge", PersonFinder.age().avg());
        return agg.get(0).getAttributeAsDouble("avgAge");
    }

    @Test
    public void testQ5b()
    {
        Assert.assertEquals(34.75, this.getAverageAgeUsingAggregateList(), 0.0);
        final Person person = new Person();
        person.setName("Michael Caine");
        person.setCountry("USA");
        person.setAge(65);
        person.insert();
        Assert.assertEquals(this.getAverageAgeNormalMithra(), this.getAverageAgeUsingAggregateList(), 0.0);
    }

The above is my answers to the questions. testQ5a produces a pass but testQ5b produces a fail.
I can't for the life of me see how to get testQ5b to work. The data type of the Person.age column is an int and the avg function in H2 would produce an int result from what I read of H2 (I'm new to H2). So it would appear that the getAttributeAsDouble will not affect the answer returned from H2. I get 34 returned and not the 34.75 answer which is what I got in testQ5a.
Can you tell me how this should work?
My only suggestion on the Kata is that it would be great to have the solutions to check against.
Reladomo is looking great as I progress through its features. Thanks for the work.

Sorry about that... it's a bit of a trick question, more suitable when this Kata is done in a classroom setting.
You essentially have to figure out a way to cast from int to double on the database side. It's not really H2 specific; the same thing happens with all databases.
So this is the trick: use a bit of math to force a double:
PersonFinder().age().times(1.0).avg()
Hope that helps.
P.S. Wouldn't it be nice if there was a simpler castToDouble() method on IntegerAttribute? 💡 for contribution?

@gs-rezaem
Ah I see thanks for the tip there.
I'd love to make use of reladomo in my project Just a little question.
Is reladomo alive and kicking?
I assume it is as you use it internally in a number of projects and the quick response above makes me think it is.
I would love to contribute and offer ideas where I can.

Very much alive and kicking 😄

@gs-rezaem
Fantastic :)


make prepare updates project url and org name

This extends make prepare with an ORG command line parameter and updates deployment-teplates/.goreleaser.yml and provider/resources.go to use the key abc as a replacement value for the org name. It also updates those files to use the github.com/pulumi/pulumi-xyz repo value where they weren't already and extends make prepare to replace those values with the REPOSITORY configuration variable (instead of relying on the -xyz replacement as before, which did not properly update the repo location for 3rd party repos).
The only manual modifications remaining are to add the proper upstream terraform go module, define the resource mappings, and set various values in provider/resources.go as required (ie download url, image, etc)
This may be sufficient to close #75

Thanks for this, I was having trouble chasing the references down manually. This change helped me get everything working!


Disconnected bones export with the wrong rotation

Describe the bug
Disconnected bones export with the wrong rotation. It doesn't seem to be all disconnected bones in general, as I tried recreating the bug in a new .blend file, but the rotation error did not happen there. Perhaps there's some specific scenario with disconnected bones that causes the bug.
To Reproduce + Expected Behaviour
File with the issue
I've attached the original offending .blend file where the problem can be reproduced. Inside the .blend file you'll see the following mesh and rig:

In the NLA, you'll see a single track "IdleTrack" with a single-frame "IdlePose" action in it. This is what the pose should look like:

Export to GLTF
Export to .glb with the following settings:

Geometry > Material > Material = No Export
Animation > Animation > Always Sample Animations = OFF
Animation > Animation > Always Sample Animations = OFF
Animation > Animation > Group by NLA Tracks = ON
Animation > Animation > Optimize Animation Size = ON
Animation > Animation > Export all Armature Actions = OFF

Then re-import the resulting .glb file into a fresh new blender scene. Here, you'll that the pose has been exported with the wrong rotations on the pelvis and shoulder bones. I think some of the bones in the hand are also incorrect, but it might be simpler to see and debug the problem isolated in the other two areas.

You can import this .glb into other viewers and confirm that the problem is on the exporter side, not the importer side.
.blend file / .gltf
disconnected-bones-gltf-io-bug.zip
Version

OS: macOS Big Sur 11.5.2
Blender Version 3.3.1

Additional Context
Probably not relevant here, but FWIW I've been trying to export the Rigify rig to GLTF, and had a lot of complications there where poses would export, so I gave up and started just using the plain MetaRig without all the IK constraints etc.

Hello,
Thanks for your report.
I can confirm.
Seems the issue is already solved in main branch (that will become 3.6), because 3.6 will come with a refactored code for animation export.
You can test 3.6 alpha here: https://builder.blender.org/download/daily/
Let's close this ticket. If you still have an issue, feel free to comment and reopen this ticket.

Appreciate the reply! 🙏 Confirmed this resolves it, although I reported a new issue in 3.6 here: https://github.com/KhronosGroup/glTF-Blender-IO/issues/1884


The sweep transaction isn't treating withholding tax correctly.

Too much money is coming into the bank account when sweeping cash from the RIF.
The full amount is coming in, instead of being reduced by the withholding tax.

This bug isn't as serious as I first thought. The core cash flows and tax return were sound.
It's true the bank was getting too much money. That extra money was simply spent, and didn't inflate the core cash flows.
The logging of the amount swept to the bank was inflated though, and so misleading.

The stat for total cash swept isn't being updated.


Adding CI - Installing Flake8 tool

we will use the “Flake8” tool and set things up so that it scans our code automatically as we send PRs and provides feedback on the PR review screen.
The purpose of CI is to fail when issues exist in the code.

I see this Pr and PR #4 are both adding a Pipfile and a Pipfile.lock. Once we merge one of these PRs it will cause a severe conflict for the other because you can't edit those files manually to resolve it.
I suggest you choose which one goes in first and rebase the other on top of it in advance while also noting the dependency in the PR description so everyone knows what should be merged first.


tests: Use schema constants in unit and integration tests

Signed-off-by: Elvira García Ruiz<EMAIL_ADDRESS>

Coverage remained the same at ?% when pulling d477d7bf29afff384ff719949359848688aaa20d on elvgarrui:schema_constant into da707f31370a5fd2951e72fb585aedd31d9cfc60 on nmstate:master.


SCM_DO_BUILD_DURING_DEPLOYMENT parameter does not work

I have a python application that is deployed to App Service Linux from zip.
Build pipeline that creates zip is as follows:
python -m pip install --upgrade pip
export<EMAIL_ADDRESS>pip install setup
pip install -r requirements.txt

It succeeds and publishes artifact correctly.
When I consume it in the release pipeline and deploy it to App Service, this error appears during runtime:
ModuleNotFoundError: No module named 'MyModule' // package from private feed
Documentation suggests setting SCM_DO_BUILD_DURING_DEPLOYMENT to 1 or true to ensure proper build of application during first startup. PIP_EXTRA_INDEX_URL is set as app setting for the underlying App Service.
But after I do that, the error persists. Any ideas how to ensure build is actually running?

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

ID: 682f3cfc-22d7-c367-1215-a692d6031089
Version Independent ID: ec754538-109a-4062-2acf-a5fbbaa5fb41
Content: Configure Linux Python apps - Azure App Service
Content Source: articles/app-service/configure-language-python.md
Service: app-service
GitHub Login: @cephalin
Microsoft Alias: cephalin

@crow-ua
Thanks for your feedback! We will investigate and update as appropriate.

Apologies for the delay. As per the doc, the steps are for built-in Linux container, are you leveraging built-in container or custom container? Following the doc steps, I was able to configure/migrate existing applications to App Service.
Overwrite the PIP Environment variable with PIP credentials for Azure DevOps Artifacts feed and then publish Webapp. Similar discussion for Function app (in specific)
Please take a look the suggestions in this article:
Python on Linux App Service and ModuleNotFoundError
If you haven’t done, Also, review the requirements.txt for missing modules.
You may flow the steps, as this, and check:

python -m venv antenv
source antenv/bin/activate
python -m pip install --upgrade pip
pip install setup
pip install -r requirements.txt

Enable logging to fetch more info:
Enable application logging (Linux/Container).  Thanks for your patience!

We will close this out, but if you feel you need more information please just let us know.
As a side note, this channel is reserved for ‘Azure docs’ feedback- for sharing doc feedback and suggesting content improvements.


Fix a typo affecting Luke

This PR fixes a minor typo (currupted -> corrupted) that affects the Luke tool.

Thank you.


Remove DB Tests.

Remove db tests so tests just test ui elements.

This PR is being closed in favor of this merge https://github.com/ryanAllMad/js-job-helper/commit/5992fde8342fe729178010824bda64589d712693


Prompt out needed when logout

I don't see it necessary anymore. Logout with re-confirming might be a better idea.


[WIP] Arabic translation

[X] Have you followed the contributing guidelines?
[X] Have you explained what your changes do, and why they add value to the Guides?

Please note: we will close your PR without comment if you do not check the boxes above and provide ALL requested information.
This PR is a WIP to translate opensource.guide to Arabic.
Articles translation completed

[ ] Best Practices
[ ] Building Community
[ ] Code of Conduct
[ ] Finding Users
[x] Getting Paid
[ ] How to Contribute
[ ] Leadership and Governance
[ ] Legal
[ ] Metrics
[ ] Starting a project

Other items:

[ ] RTL styling

Hey, thanks for the PR! Need to fix the test failures here:
https://travis-ci.org/github/opensource.guide/builds/410079074

@ibrasho Ping on the test failures.

support

te="1548556922070" type="2" body="I agree 100 percent!!" read="1"  service_center="" name="" />

<sms address="31681" time="Jan 26, 2019 10:39:33 AM"

Thank you for your efforts

Nice

Quero contribuir<EMAIL_ADDRESS>

thanks

yes

cfbfc84

thanks

Closing this as it's inactive and has failing CI. Sorry!

No worries @MikeMcQuaid . If anyone wants to pick this up, please feel free.

Any updates?


As of Istio 1.9 creating a gateway-fallback certificate secret does not prevent a connection reset when the secret specified in the gateway doesn't exist

Bug description
Previous to istio 1.9 you were able to specify a secret called gateway-fallback that would be used in place of the specified secret in the gateway specification if it was not found. This allowed the service to be accessible even if there were certificate issues or the certificate took a long time to issue and create the certificate. Currently if the certificate is not found the users receive a connection reset. Unless I missed it this change was not disclosed in the release notes.
I dug through the code and when SDS was moved to istiod it appears that all references to FallbackSecretName were removed from the code. it appears to be related to this commit 03e89d4fb372c5e29773c0aedbe05d229dad3dc7.
[x ] Docs
[ ] Installation
[x ] Networking
[ ] Performance and Scalability
[ ] Extensions and Telemetry
[x] Security
[ ] Test and Release
[ ] User Experience
[ ] Developer Infrastructure
[ ] Upgrade
Expected behavior
Connection should not be reset, and the fallback certificate should be presented.
Steps to reproduce the bug
Delete secret specified in the gateway and try and access the service.
How was Istio installed?
Istio Operator
Environment where the bug was observed (cloud vendor, OS, etc)
On Prem/GKE

bump....


Add Support for Xcode 11 xcresult & xccovreport

With Xcode 11, Apple has changed up the file format of xcresult so that you can't simply inspect into the xcresult's file structure.  Instead, you need to go through their tool xcresulttool in order to retrieve files like xccoverage out of the xcresult.

For anyone who comes upon this, our intern worked on creating a Swift command line tool (http://github.com/ChargePoint/xcparse) that can help in extracting files like the code coverage report out of Xcode 11+ xcresult files.  It's installable via Homebrew & we're using it in our cloud CI to workaround this.  Once you extract out the action.xccovreport using xcparse, your Dangerfile just needs to be updated with the "xccov_file_direct_path" key to point at the filepath to the extracted file.  Example below:
# Check code coverage
xcov.report(
   scheme: 'KillerApp',
   workspace: 'KillerApp.xcworkspace',
   minimum_coverage_percentage: 0.0,
   output_directory: './reports',
   xccov_file_direct_path: 'action.xccovreport'
)

Do note that this tool relies on you knowing the path of your XCResult file.  Our cloud CI has a handy environment variable for that.

@joshdholtz Any updates about xcov & xcov-danger's future given the repo ownership change from NakioStudio? https://twitter.com/nakiostudio/status/1171835206300504065

@abotkin-cpi Yeah yeah, sorry! Its current transferred to my personal github account (as you can tell) and I will be transferring in into https://github.com/fastlane-community so that there is a good support team behind 😊
There will be some spin up time since I have never worked in this codebase but I will try to get all the support you need for xcresult/xcode11 and other things as fast as I can 💪

And I'm pretty familiar_ with the new xcresult format. I just recently added support for it inside of trainer here -  https://github.com/fastlane-community/trainer/pull/34
So hopefully this isn't too complicated of a change 😊

Sounds great!  Any plans to expand out in fastlane a tool to extract all the files out of the xcresult like screenshots (which snapshot would likely want to take advantage of) in addition to the code coverage file?  We've been using our own Swift CLI to do so in our CI but would be nice for one of the fastlane tools like trainer or snapshot to consolidate all the xcresult file extraction into one fastlane tool that snapshot & trainer could then depend on (as well as others like us to depend on to get at screenshots in our XCResult files).

@abotkin-cpi No plans at the moment but also no objections 😊 TBH, I had no idea this xcresult stuff existed until last week but its been really fun to jump into and learn 😇 Are you able to provide me with an example of what you are thinking or what you have been using so that I have something to go off of? I can connect the dots easier when I see the end result 😉

We've so far been using the Swift tool our intern @rsukumar-cpi worked on this summer (https://github.com/ChargePoint/xcparse) to do this.  It's mostly just about getting down to the ActionTestActivitySummary which should have the array of attachments in ActionTestAttachment.  Then using the filename & payloadRef's Reference ID, you can extract all the screenshots out with xcresullttool.  Biggest thing is there is a whole lot of nesting with ActionTestMetadata, ActionTestSummaryGroups, etc. that you have to go through multiple xcresultool JSON retrievals before you get to the attachments.  You can check out the code in here for the high-level (https://github.com/ChargePoint/xcparse/blob/master/Sources/xcparse/XCPParser.swift) & the coding/decoding stuff is all here (https://github.com/ChargePoint/xcparse/tree/master/Sources/XCParseCore).
Code coverage file is pretty straightforward, just need to grab the Reference ID off of the ActionRecord's ActionResult's CodeCoverageInfo's reportRef.
In terms of what would be nice in a fastlane tool, it'd be great to similarly have what xcparse is doing where it takes an xcresult path & will just export out the screenshot files in a given directory or get the code coverage file.  That would allow other tools like snapshot & trainer to take advantage of a centralized XCResult parser and not get into the business of having to know the XCResult format in each of the tools themselves.  It would also help situations like our CI where we want to be able to keep all the PNG screenshots from UI automation as build artifacts that can be viewed on the web.  Example from our CI step:
# Extract the screenshots from the XCResult
xcparse -s $BITRISE_XCRESULT_PATH .

# Copy the screenshots over into the deployment folder
find testScreenshots -type f -name 'CPTAutomation*.png' -exec cp {} $DEPLOY_DIR \;

Here's a snapshot of what the end result would be if we run a command to extract various files from the XCResult like screenshots (using -s in xcparse) or the code coverage (using -x in xcparse).  Note the raw action.xccovreport that we can access (and which xcov & xcov-danger would want to get at) & the folder filled with all the screenshot attachments from the test runs in the XCResult

@abotkin-cpi This is beautiful 🙌  Thanks for taking the time to write all that app and provide screenshots ❤ I would love to be able to get as much of this working in fastlane as we can 💪 Cool if I hit you up if I have any questions on any of this as I start playing around with it?

Yep, hit me up if you have any questions.  My email should be visible on my GitHub profile & I do use Slack if you have any Slack workspace.

@abotkin-cpi Got a PR out for adding Xcode 11 support into xcov ☝ I currently don't have any great way to test a danger setup for this but if you (or somebody) else is able to test this that would be 💯 The PR I made should just work since I didn't need to add any new options or anything 🙃🤞
I think you can test this by...
Update your Gemfile to 👇 and run bundle install or bundle update xcov
gem 'xcov`, :git => 'https://github.com/fastlane-community/xcov.git', :branch => 'joshdholtz-xcresult-support'

If you use this in your Gemfile it might work better:
gem 'xcov', :git => 'https://github.com/fastlane-community/xcov.git', :branch => 'joshdholtz-xcresult-support'`

Cannot test this right now since we switched to danger-xcov last week. But yeah would be interested in a working solution too :-)

I can confirm using the xcov fork fixes things without needing any additional configuration changes

@joshdholtz I'll give this a try later this afternoon/evening with our CI setup & get back to you in 12 hours.

@abotkin-cpi The xcov gem has a new official release that fixes this issue, you should be able to just do a simple bundle update and be good to go.

My co-worker @mgorkani-cpi ran it & confirms this works.
One thing that is preventing us from using it in our CI is that our CI provider is placing the XCResult file outside of the derived data folder.  When we extracted the code coverage file ourselves, we could used the xccov_file_direct_path argument, but now that we're experimenting with having xcov do the extraction itself, we hit the issue of xcov not providing a way to pass the path to an xcresult directly.  I'll write a separate PR over in the xcov project about that.


--Eval options parsing sequence

When I use -- Eval options to parse a sequence, I find that it is not possible to parse a sequence in a key value pair, but a string directly
    parser.add_argument(
        '--eval-options',
        nargs='+',
        action=DictAction,
        help='custom options for evaluation, the key-value pair in xxx=yyy '
        'format will be kwargs for dataset.evaluate() function')

--eval-options "iou_thrs=[0.1]"
In this case, I found that only "[0.1]" could be parsed as a string, not a list

It seems a bug, we will fix it soon.


Add shifted arrow keys

Currently, ConnectBot ignores the Shift key state when processing arrow keys. Shift + arrow keys is commonly used to select text, e.g. in Emacs and mcedit.
I fixed this in ConnectBot VX, here: https://github.com/vx/connectbot/commit/274e2574139da337528f3b0bf665a266130e161b

Feel free to open a PR with this and note it here.


Dev

https://github.com/OfficeDev/PnP/issues/762
https://github.com/OfficeDev/PnP/issues/763

Hi @maratbakirov, I'm your friendly neighborhood Microsoft Pull Request Bot (You can call me MSBOT). Thanks for your contribution!

In order for us to evaluate and accept your PR, we ask that you sign a contribution license agreement. It's all electronic and will take just minutes. I promise there's no faxing. https://cla.microsoft.com.

TTYL, MSBOT;

@maratbakirov, Thanks for signing the contribution license agreement so quickly! Actual humans will now validate the agreement and then evaluate the PR.
Thanks, MSBOT;

Thank you this PR! Good additions indeed. I've implemented them, but a bit differently. You proposed to update the file property parsing and you modified the FileFolderExtensions.cs file for that. However, that's a core library class, which not necessarily knows about the tokenparser static class. E.g. it might not be initialized. I've implemented your proposed functionality in the Files Object Handler (ObjectFiles.cs) of the engine now, as that one is aware of the TokenParser.
I've also updated the site and sitecollection token to strip the trailing slash.
See PR #767 and PR #766 for the implementation.
I will close this PR now.


"short message" error with larger SRV response

Resolving a SRV record that has multiple entries using resolve gives me a "ShortMessage" error:
Error: failed to resolve record: error decoding message: short message
An example SRV lookup with 6 responses that results in an error:
;; ->>HEADER<<- opcode: QUERY; status: NOERROR; id: 25682
;; Flags: qr; QUERY: 1; ANSWER: 6; AUTHORITY: 0; ADDITIONAL: 0

;; QUESTION SECTION:
;; 795655663df60fab8f793ff4fb11de321a71c5ea.dat.local.  IN      SRV

;; ANSWER SECTION:
795655663df60fab8f793ff4fb11de321a71c5ea.dat.local. 120 IN      SRV     0 0 1024 <IP_ADDRESS>.
795655663df60fab8f793ff4fb11de321a71c5ea.dat.local. 120 IN      SRV     0 0 3282 <IP_ADDRESS>.
795655663df60fab8f793ff4fb11de321a71c5ea.dat.local. 120 IN      SRV     0 0 48628 <IP_ADDRESS>.
795655663df60fab8f793ff4fb11de321a71c5ea.dat.local. 120 IN      SRV     0 0 3282 <IP_ADDRESS>.
795655663df60fab8f793ff4fb11de321a71c5ea.dat.local. 120 IN      SRV     0 0 3282 <IP_ADDRESS>.
795655663df60fab8f793ff4fb11de321a71c5ea.dat.local. 120 IN      SRV     0 0 61360 <IP_ADDRESS>.

  IN      SRV

;; ANSWER SECTION:
892e5ef0875a89ac7e0b2c0184db9b09fccbcf36.dat.local. 120 IN      SRV     0 0 48628 <IP_ADDRESS>.

;; Received 152 B
;; Time 2018-02-15 20:24:48 PST
;; From <IP_ADDRESS>@53(UDP) in 207.9 ms```

This is some non-standard DNS usage (eg, not `_protocol.` style in a SRV lookup), but the single-response message works fine.

Non-standard usage should not affect the validity of messages being sent and received. This is a bug. I'll look into it right away.

In case it helps, here's my (straightforward) rust code using resolve: https://github.com/bnewbold/geniza/blob/master/src/discovery.rs#L19


Bot thinks you are softbanned when you are not and closes

Expected Behavior
OpenPoGoBot will try to spin, if it can't it should walk away and not try to spin that for at least 5 mins.
Actual Behavior
OpenPoGoBot Spins the same Stop multiple times, reports that you are softbanned, and closes
Steps to Reproduce
Run OpenPoGoBot and wait for it to spin a Stop
Other Information
Also reported here: https://github.com/OpenPoGo/OpenPoGoBot/pull/42
OS: Windows/Linux
Git Commit: Happening on latest commit: db376bb

Is it possibly related to the "Try again later." message you get sometimes in the app?

I can confirm this bug.
It's an issue if you already spun the stop and got things from it once, but it's already on cooldown.
An easy repro is the following:

Start the bot in a location, wait for it to spin a stop and get things.
kill the bot
start it again in the same location, it will likely go to spin that same stop again
OH NOES UR SOFTBAND.

We should probably keep track of visited pokestops and their cool down and ignore them until they're usable

Unless you're talking about saving them to a file, that won't work if you kill the bot and restart it.
I believe we already keep track of the stops spun in memory anyways.
I think the issue is that if it doesn't get anything from the stop, it doesn't bother marking the stop as "spun" and explodes.

I think we should then remove the crash and just print a red warning or some equivalent

Also worth noting if you comment out the exception, the bot just keeps trying to spin the stop over and over.
So the fix for this should also mark that stop as "spun" and move on as well as spitting a big red warning

It should work saving it to a file just something like
reset_time = current_time + 5 mins
check the list each time it is searching for a stop and once current_time > reset_time remove it from the list.
and anything on the list will be ignored.
Should work when restarting bot aswell?

is there not a separate response from server for spin failed and spun but no reward?

Has anyone gotten this error? I haven't gotten it myself for a few days.

Closing since this error seems to have been fixed.


Command for easy change of light / dark theme

Switching from dark to light themes and vice versa every day is annoying. A simple command like Toggle Light / Dark Theme would be great.
Today, when you try to change the theme through the command Preference: Color theme, it opens the pannel with the current theme in the focus of the selection. The themes are grouped by type (light, dark, high contrast, etc), so to find the light or dark theme of whatever you are using involves searching through the list, scrolling down and up. Today I don't even bother to go to the light/dark version of the theme I'm using, because it would consume more time.
Many themes exist in the light and dark theme, so for those, it should be easy to have a command that just toggles between the light or dark version. For example, the default theme, and the Github theme support this.
This may involve adding a field in the theme that lists what are the opposite version(s) of them to use them.
Using a list can be easier because you can list alternatives. This would allow a theme that doesn't have a light or dark version to suggest one opposite one. And the toggle command could change to the first theme in the list that is installed. Being able to overwrite the theme list in the user's settings could also be a nice feat.
With this, it could tackle other issues related to theme preferences. A few ones that I found that may benefit from this are:
https://github.com/microsoft/vscode/issues/100460
https://github.com/microsoft/vscode/issues/84486
https://github.com/microsoft/vscode/issues/114807
https://github.com/microsoft/vscode/issues/114751
https://github.com/microsoft/vscode/issues/112387
https://github.com/microsoft/vscode/issues/107669
https://github.com/microsoft/vscode/issues/91231

Only a few themes comes in light/dark pairs and connecting these by name is not easy. But we have the preferred light and preferred dark theme setting that we could use.
Give that such an option would be quite easy to implement. If anyone want to give it a try with a PR, help is welcome.

I'd like to give it a try!
Could I get a code pointer to see where quick input commands are?


added force_loop (+propagation of write parameters)

The main change is a force_loop option, which enforces writing even single-line data frames as a loop. This helps a lot with hybrid Relion/cryoSPARC workflows, as cryoSPARC does not cope with the normal (non-loop) structures, which requires annoying and error-prone editing.
Also, I added propagation of the na_rep and sep parameters in the write() function - I guess that was a bug?

caught me at a good time :) glad it's useful!

https://github.com/alisterburt/starfile/actions/runs/1320531095
should be on PyPI imminently


no vendor folder that contains all the jquery and css

there should be vendor/AdminLTE/ folder. Am i making mistakes or the files are actually missing?

You need to install it with bower (I wrote at readme) or you could manually donwload AdminLTE and move under the vendor folder.

my bad. thanks for the fast reply.

You're welcome.


beforeunload event documentation: add details about XHR/sendBeacon

Request type

[ ] Please close this issue, I accidentally submitted it without adding any details
[ ] New documentation
[x] Correction or update

Details

beforeunload event:
Add information about not being able to send async XHR and mention/set a link to navigator.sendBeacon()

https://developer.mozilla.org/en-US/docs/Web/API/WindowEventHandlers/onbeforeunload

Hey @xyz0815
On the Navigator.sendBeacon() page, there's now a recommendation to avoid using sendBeacon on the beforeunload event. The recommendation is to use the visibilitychange event.

I've added notes to the onbeforeunload and beforeunload pages to mention that you shouldn't use them with sendBeacon(), and pointed to the sendBeacon() page for more details. I think we can close this now.


Readme for developers

README.txt should contain a recipe for developers and for getting started with developing (installing, run tests, guidelines for contributions, etc). Examples of use (as today) should be in the documentation.

Closing since this is now contained in CONTRIBUTING.md and in the documentation


[PROPOSAL] integration/spark to Use Proposed Filtering Feature.

Hello OpenLineage team,
Purpose:
Upon reviewing the event filtering mechanism in integration/spark, I've observed that event filtering goes through specific classes like DatabricksEventFilter, where the job names such as "{JOB_NAME}-adaptive_spark_plan" are filtered out.
Given the proposed filtering functionality in #2054, it might be more maintainable and scalable to utilize this general filtering feature, rather than having individual classes for each filtering purpose.
Proposed Changes:

Deprecate or refactor specific filtering classes such as DatabricksEventFilter.
Integrate the filtering functionality as proposed in issue #2054 to handle these filters more universally. which can be done through : spark.lineage.filters: [{type: exact, match: job}, type: regex, match: ^.*adaptive_spark_plan.*$]

I don't how much does it impacts the other filters and if all their names appears in the job's name. But it can still have both of them the spark.openlineage.filters option in addition to the some class filters.
If this direction aligns with the project's vision, I'd be happy to assist in the implementation or provide more details.
Thank you for considering this suggestion!
Best,
Abdallah

Filter classes (SparkNodesFilter, DeltaEventFilter, DatabricksEventFilter, CreateViewFilter and AdaptivePlanEventFilter) do a bit more that job name (Spark logical plan node) checking. I don't think it would be doable to get rid of them.
Even though we create methods in openlineage-java client, there is still a need to configure which events to filter.
Please also keep in mind that current filtering implementation not only prevents events being sent but also prevents event being constructed as filtering is done at the beginning of the openlineage integration code:
https://github.com/OpenLineage/OpenLineage/blob/41dbbf1799595bd9cd1567df0a7027de08619741/integration/spark/app/src/main/java/io/openlineage/spark/agent/lifecycle/SparkSQLExecutionContext.java#L64


redo types

I tried going over the whole thing again. I expect I'll need to answer some questions on this.

Hm. I wonder if CI picked up on that TS 2.0. Getting through with 0 errors here.

Think I found why Travis bailed earlier; I hadn't noticed the test command used the global TS version rather than the locally committed version.


arkade: 0.11.16 -> 0.11.19

Automatic update generated by nixpkgs-update tools. This update was made based on information from https://github.com/alexellis/arkade/releases.
meta.description for arkade is: Open Source Kubernetes Marketplace
meta.homepage for arkade is: https://github.com/alexellis/arkade
Updates performed

Golang update

To inspect upstream changes

Release on GitHub

Compare changes on GitHub

Impact
Checks done

built on NixOS
The tests defined in passthru.tests, if any, passed
found 0.11.19 with grep in /nix/store/cl35kp5w44kg93kscbggy60n5g843gy0-arkade-0.11.19
found 0.11.19 in filename of file in /nix/store/cl35kp5w44kg93kscbggy60n5g843gy0-arkade-0.11.19

Rebuild report (if merged into master) (click to expand)

2 total rebuild path(s)

2 package rebuild(s)

First fifty rebuilds by attrpath

arkade

Instructions to test this update (click to expand)

Either download from Cachix:
nix-store -r /nix/store/cl35kp5w44kg93kscbggy60n5g843gy0-arkade-0.11.19 \
  --option binary-caches 'https://cache.nixos.org/ https://nix-community.cachix.org/' \
  --option trusted-public-keys '
  nix-community.cachix.org-1:mB9FSh9qf2dCimDSUo8Zy7bkq5CX+/rkCWyvRCYg3Fs=
  cache.nixos.org-1:6NCHdD59X431o0gWypbMrAURkbJ16ZPMQFGspcDShjY=
  '

(The Cachix cache is only trusted for this store-path realization.)
For the Cachix download to work, your user must be in the trusted-users list or you can use sudo since root is effectively trusted.
Or, build yourself:
nix-build -A arkade https://github.com/r-ryantm/nixpkgs/archive/fd50f7202fc20d358fccb9c1e13b30ce821b854f.tar.gz

Or:
nix build github:r-ryantm/nixpkgs/fd50f7202fc20d358fccb9c1e13b30ce821b854f#arkade

After you've downloaded or built it, look at the files and if there are any, run the binaries:
ls -la /nix/store/cl35kp5w44kg93kscbggy60n5g843gy0-arkade-0.11.19
ls -la /nix/store/cl35kp5w44kg93kscbggy60n5g843gy0-arkade-0.11.19/bin

Pre-merge build results
We have automatically built all packages that will get rebuilt due to
this change.
This gives evidence on whether the upgrade will break dependent packages.
Note sometimes packages show up as failed to build independent of the
change, simply because they are already broken on the target branch.
Result of nixpkgs-review run on x86_64-linux 1

1 package built:

arkade

Maintainer pings
cc @welteki @techknowlogick @qjoly for testing.

Add a :+1: reaction to pull requests you find important.

Result of nixpkgs-review pr 333328 run on aarch64-darwin 1

1 package built:

arkade


"Microsoft Windows Malicious Software Removal Tool - 5.82.17046.2 wants to reset your settings."

[16-May-2021 16:04:36] Tried 1 | Line : 417 | Message: unknown error: net::ERR_PROXY_CONNECTION_FAILED
(Session info: chrome=90.0.4430.212)
Running on windows 10 from source.
When running it opens two tabs for each chrome instance. The first tab(and the one that has focus) is chrome://settings/triggeredResetProfileSettings       this stays there indefinitely
It also does not close the chrome instance and has dozens of them open at once.
The other tab is the url of the video.
The proxies are good.

what type of proxy category you are using? premium?

what type of proxy category you are using? premium?

Rotating

I mean you provide username and password as well with proxy?

I mean you provide username and password as well with proxy?

Yes i had i working well a few days ago on a different machine

using the same credentials

well, I think "Microsoft Windows Malicious Software Removal Tool" detects extension as a risk.

I mean you provide username and password as well with proxy?

Yes i had i working well a few days ago on a different machine

That's because few days ago it was different. Now script use a simple extension to authenticate proxy with credentials.
"Microsoft Windows Malicious Software Removal Tool" this isn't a default tool that comes with windows, right? You can disable it safely. But if you don't want to disable this tool then authenticate your IP on your proxy provider service then provide proxy without credentials.


LEGO: Pull request from lego/hb_835_20170803084527341 to Release/1_0

LEGO: Pull request from lego/hb_835_20170803084527341 to Release/1_0 with localized lcls

Please stop merging to Release/1_0, this branch is snipped and closed. Localization should be done in the master which has different structure. Evelyn and Daniel can explain further.


Fix version number in Python

__version__ hardcoded to 0.0.4, this should ideally be taken from BUILD_INTO.txt or about.py (#501) but before the release let's just swap it to 0.2.0.

LGTM


Deleted package detected

I'm a Cyber Security researcher and developer of PackjGuard [1] to address open-source software supply chain attacks.
Issue
During my research, I detected a deleted package in this repository.
Details
Specifically, the package stpyv8 mentioned in file README at line 101 does not exist on the public PyPI registry. A bad actor can hijack this package to propagate malicious code.
Impact
Not only your apps/services using https://github.com/cloudflare/stpyv8 repo code are vulnerable to this attack, but the users of your open-source Github repo could also fall victim.
You could read more about such attacks here<EMAIL_ADDRESS>Remediation
Please highlight this in file README and register a placeholder package for stpyv8 on public PyPI soon to remediate.
To automatically fix such issues in future, please install PackjGuard Github app [1].
Thanks!

PackjGuard is a Github app that monitors your repos 24x7, detects vulnerable/malicious/risky open-source dependencies, and creates pull requests for auto remediation: https://github.com/marketplace/packjguard

I created the PyPI release a few minutes ago and can see it in the PyPI public registry. Maybe you just checked too early?

Thanks!


Please support android

This features does not support android platform.

Please talk about you device, input method and usage situation.

This features does not support android platform.


VSCode CPU Utilization on macOS Catalina

VSCode Version: 1.42.1
OS Version: macOs Catalina 10.15.3

Steps to Reproduce:
Open VSCode with a moderately sized mono-repository and Code Helper (renderer on macOS) is running on 15 threads and >250% of CPU (this metric seems strangely defined since the user CPU is nowhere near the this amount). VS Code Alone is consuming > 20% of available CPU (User CPU) for more than 20 minutes since opening.

Does this issue occur when all extensions are disabled?: Yes (I disabled the extensions one by one in an attempt to identify the culprit).

To find out more about this issue, we need to get at the process that is causing the high load. VS Code creates multiple processes, each with different tasks.
When Code is consuming lots of CPU, please run "code --status" from the command line (or "code-insiders --status" if you are using VS Code Insiders edition).
Please attach the output of this command to this issue. Thanks!

@bpasero I'm unable to replicate the behavior today without the extensions enabled. The behavior I had seen in activity monitor didn't reflect the issue I had been seeing last week. However, it does appear a
large amount of CPU is being utilized by an electron process ( 666	    33	  8254	       electron_node package.js). I'm assuming this has something do do with the JavaScript extension?
With Extensions Eabled:
Version:          Code 1.42.1 (c47d83b293181d9be64f27ff093689e8e7aed054, 2020-02-11T14:44:27.652Z)
OS Version:       Darwin x64 19.3.0
CPUs:             Intel(R) Core(TM) i9-8950HK CPU @ 2.90GHz (12 x 2900)
Memory (System):  16.00GB (2.95GB free)
Load (avg):       6, 12, 9
VM:               0%
Screen Reader:    no
Process Argv:     .
GPU Status:       2d_canvas:                     enabled
                  flash_3d:                      enabled
                  flash_stage3d:                 enabled
                  flash_stage3d_baseline:        enabled
                  gpu_compositing:               enabled
                  metal:                         disabled_off
                  multiple_raster_threads:       enabled_on
                  oop_rasterization:             disabled_off
                  protected_video_decode:        unavailable_off
                  rasterization:                 enabled
                  skia_renderer:                 disabled_off
                  surface_control:               disabled_off
                  surface_synchronization:       enabled_on
                  video_decode:                  enabled
                  viz_display_compositor:        enabled_on
                  viz_hit_test_surface_layer:    disabled_off
                  webgl:                         enabled
                  webgl2:                        enabled

CPU %	Mem MB	   PID	Process
    1	    98	  8220	code main
    0	    66	  8230	   gpu-process
    2	   213	  8232	   window (Welcome — CloudSentry)
    5	    82	  8235	     extensionHost
    0	    33	  8236	     watcherService
    0	    33	  8252	     searchService
  666	    33	  8254	       electron_node package.js
    0	    33	  8241	   utility
    2	   131	  8255	   shared-process
    0	     0	  8271	     /bin/ps -ax -o pid=,ppid=,pcpu=,pmem=,command=

Workspace Stats:
|  Window (Welcome — CloudSentry)
|    Folder (CloudSentry): more than 35459 files
|      File types: go(3568) py(2269) bazel(1190) xml(463) rst(406) txt(405)
|                  h(367) c(317) sh(311) runfiles_manifest(304)
|      Conf files: package.json(22) makefile(21) cmake(11) tsconfig.json(3)
|                  sln(3) settings.json(2) tslint.json(2)
|                  gulp.js(1)```

<b>With Extensions Disabled</b>:

Version:          Code 1.42.1 (c47d83b293181d9be64f27ff093689e8e7aed054, 2020-02-11T14:44:27.652Z)
OS Version:       Darwin x64 19.3.0
CPUs:             Intel(R) Core(TM) i9-8950HK CPU @ 2.90GHz (12 x 2900)
Memory (System):  16.00GB (3.04GB free)
Load (avg):       5, 10, 9
VM:               0%
Screen Reader:    no
Process Argv:     . --disable-extensions
GPU Status:       2d_canvas:                     enabled
flash_3d:                      enabled
flash_stage3d:                 enabled
flash_stage3d_baseline:        enabled
gpu_compositing:               enabled
metal:                         disabled_off
multiple_raster_threads:       enabled_on
oop_rasterization:             disabled_off
protected_video_decode:        unavailable_off
rasterization:                 enabled
skia_renderer:                 disabled_off
surface_control:               disabled_off
surface_synchronization:       enabled_on
video_decode:                  enabled
viz_display_compositor:        enabled_on
viz_hit_test_surface_layer:    disabled_off
webgl:                         enabled
webgl2:                        enabled
CPU %	Mem MB	   PID	Process
4	    98	  8320	code main
0	    66	  8330	   gpu-process
7	   213	  8332	   window (Welcome — CloudSentry)
0	    66	  8335	     extensionHost
0	    66	  8336	     watcherService
0	    33	  8357	   utility
2	   115	  8375	   shared-process
0	     0	  8390	     /bin/ps -ax -o pid=,ppid=,pcpu=,pmem=,command=
Workspace Stats:
|  Window (Welcome — CloudSentry)
|    Folder (CloudSentry): more than 36190 files
|      File types: go(3568) py(2316) bazel(1190) h(465) xml(463) txt(406)
|                  sh(311) c(311) runfiles_manifest(304) bzl(275)
|      Conf files: package.json(22) makefile(21) cmake(11) tsconfig.json(3)
|                  sln(3) settings.json(2) tslint.json(2)
|                  gulp.js(1)

I'm not sure why it shows electron_node package.js  under the searchService. If a search is happening, it should show the ripgrep command is being run. But I assume that's what's happening? Does it show basically the same thing if you try this again?
Typically this is due to an extension triggering an expensive search, but you said it happens when extensions are disabled. To check why a search is being triggered, you can run "Set Log Level", pick Trace, then find the search logs


Added iut.u-bordeaux.fr & etu.u-bordeaux.fr

Student email addresses from the Technical College in Bordeaux (France)

@SebouChu Did you close this request accidentally or on purpose? Feel free to reopen it if necessary.

On purpose !
Le lun. 1 oct. 2018 à 23:40, Philip Torchinsky<EMAIL_ADDRESS>a
écrit :

@SebouChu https://github.com/SebouChu Did you close this request
accidentally or on purpose? Feel free to reopen it if necessary.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/JetBrains/swot/pull/5370#issuecomment-426072495, or mute
the thread
https://github.com/notifications/unsubscribe-auth/AHZt6n9s4JPp9u9Z_aw4rEdFnH4qn3Blks5ugou4gaJpZM4W-bHe
.


[ARM] az deployment group create: Support supplemental parameters when used with .bicepparam parameter file

Related command

az deployment
Description

Add support for specifying supplemental inline parameters when using .bicepparam files.
Testing Guide
az deployment group create \
  -g myRg \
  -p parameters.bicepparam  \
  -p override=test

Notes

Integration tests in this PR are LiveScenarioTest because we need to do a Bicep CLI version check (meaning it has to be installed) before performing any .bicepparam related logic

History Notes

[ARM] az deployment group create: Support supplemental parameters when used with .bicepparam parameter file

This checklist is used to make sure that common guidelines for a pull request are followed.

[x] The PR title and description has followed the guideline in Submitting Pull Requests.

[x] I adhere to the Command Guidelines.

[x] I adhere to the Error Handling Guidelines.

ARM

Corresponding AzPwsh PR: https://github.com/Azure/azure-powershell/pull/22904

This change is supposed to be part of az cli version 2.54.0.
But running this command in an Azure DevOps pipeline does not seem to work when passing in multiple inline parameters.
Trying to run the following code in an AzureCLI@2 task:
 az deployment group create
  --name api-deleteme-api
  --subscription '62394fa1-c454-4478-944e-3bcadc25b8d1'
  --resource-group 'integrationServices-dev'
  --template-file 'D:\a\1/drop/api.bicep'
  --parameters 'D:\a\1/drop/deleteme-api/azuredeploy.parameters.bicepparam'
  --parameters version='v0.45' apiRevision='13' apiManagementServiceName='hofor-api-management-dev'

Having a bicepparam file with the following content
...other parameters
param apiManagementServiceName = '#apiManagementServiceName - override from devops pipeline#'

When running the deployment I get the error:
The Resource 'Microsoft.ApiManagement/service/#apiManagementServiceName - override from devops pipeline#' under resource group 'integrationServices-dev' was not found
Clearly indicating that the parameter value is still the value from the bicepparam file and NOT being overridden by the inline parameter passed to az deployment command.
Is this not how it was supposed to work? - the above code is running in the AzureCLI@2 task with the correct version (2.54.0):

Yes, this PR had been released in 2.54.0. @anthony-c-martin Could you please take a look at this issue?

@tnsholding would you mind raising a new issue to track this?


Update information in toolbar after htmx request

I have a django application that uses htmx. So when I load a page I see the debug toolbar and e.g. all SQL queries that were executed. When I now click on a button that triggers a htmx request and some view response with a htmx response that replaces or add somethings to the DOM like a modal/sidebar/.... In the view some SQL queries where executed as well, but the debug toolbar does not update any of the information, it is still the same as were shown after I loaded the initial page.
I would have expected it to update the information. Is this something that does not work at the moment?
I added all my configuration regarding debug toolbar below:
In my django.py settings file:
# Debug Toolbar
IS_RUNNING_TESTS = 'test' in sys.argv

if DEBUG and not IS_RUNNING_TESTS:
    INSTALLED_APPS += ['debug_toolbar',]
    MIDDLEWARE += ['debug_toolbar.middleware.DebugToolbarMiddleware',]

def show_toolbar(request: HttpRequest) -> bool:
    if DEBUG and not IS_RUNNING_TESTS:
        if request.META['REMOTE_ADDR'] not in INTERNAL_IPS:
            logger.error(
                'Local remote address not found in internal IPs',
                error={'remote_addr': request.META['REMOTE_ADDR'], 'internal_ips': INTERNAL_IPS},
            )
        return True

DEBUG_TOOLBAR_CONFIG = {
    'SHOW_TOOLBAR_CALLBACK': show_toolbar,
    'INSERT_BEFORE': '<head>',
    'ROOT_TAG_EXTRA_ATTRS': 'hx-preserve',
}

INTERNAL_IPS = [
    '<IP_ADDRESS>',
    'localhost',
    '<IP_ADDRESS>',  # Internal docker ip
]

In my urls.py:
if DEBUG and not IS_RUNNING_TESTS:
    urlpatterns += debug_toolbar_urls()

In my _base.html template:
In the header:
    {% if debug %}
      <script>
          document.addEventListener('htmx:afterSettle', (event) => {
              if ('djdt' in window) {
                  window.djdt.init();
              }
          })
      </script>
    {% endif %}

At the end:
  {% if debug %}
    <script>
        if (typeof window.htmx !== 'undefined') {
            htmx.on('htmx:afterSettle', function(detail) {
                if (
                    typeof window.djdt !== 'undefined' &&
                    detail.target instanceof HTMLBodyElement
                ) {
                    djdt.show_toolbar();
                }
            });
        }
    </script>
  {% endif %}

A few other questions:

Does the history panel show the requests?
What versions of django, the toolbar are you using?
Are you using async views or channels?
The line 'INSERT_BEFORE': '<head>', seems incompatible. The toolbar should be inside of the body tag at least.

@tim-schilling thanks for the quick reply, my answers:
Does the history panel show the requests?
Yes, the request are shown in the history panel
What versions of django, the toolbar are you using?
toolbar: version = "4.4.6"
django: version = "5.1"
Are you using async views or channels?
No,  I don't use any async views or channels.
The line 'INSERT_BEFORE': '', seems incompatible. The toolbar should be inside of the body tag at least.
I also had </head> and did not setting 'INSERT_BEFORE' at all.  All different variants seem to behave the same for me, except that the toolbar is flickering when I don't set it like this.
I also noticed that after I opened a modal the toolbar does not react to any input, but when I open it a second time it reacts to input again. But I guess this is not related, maybe something with my CSS, idk yet? Also for this changing INSERT_BEFORE  to </head> or don't set it all does not change anything.

I'm having a tough time fully understanding what's happening and what you'd like to change. If the toolbar has the history panel and the htmx requests show up in there after clicking refresh (or enabling UPDATE_ON_FETCH), to me that means the toolbar is working as expected.
If you're replacing the entire DOM and want the toolbar to be supported, you may need to tell htmx to not swap that part.

Oh, I was not aware about 'UPDATE_ON_FETCH': True, that does exactly what I wanted. Thanks for your time :)
I still have a bug that when I every other htmx request, the toolbar becomes frozen (clicking does not do anything) and after doing another htmx request it works again (clicking on e.g the SQL button opens the sql view). But for that I guess I need to make some small reproducible example.

Oh, I was not aware about 'UPDATE_ON_FETCH': True, that does exactly what I wanted. Thanks for your time :)
I still have a bug that when I every other htmx request, the toolbar becomes frozen (clicking does not do anything) and after doing another htmx request it works again (clicking on e.g the SQL button opens the sql view). But for that I guess I need to make some small reproducible example.

For anyone who comes across this, having `'INSERT_BEFORE': '', is not good, mixes up the whole html structure. I had importmaps that stopped working and all my  content was moved into the  content. Only use  or , but it now flickers again for me when I load a new page.


QC reports is not exporting

The method used to ship the QC reports seems to be broken (no sync'ing files in samba)
https://github.com/maxplanck-ie/nanoporeReads_dataTransfer/blob/709e4b05baee1c1e5907e315289d2c553e7ee597/src/npr/communication.py#L15

Target dir indeed have the files, so missing sync could be infrastructure related, closing as there is nothing to do.


Update the Linux service scripts to use systemd services instead of init.d

Is your feature request related to a problem? Please describe.
Most current linux distributions support systemd services by default. It would be more convenient if Percussion services provided systemd scripts instead of init.d scripts.
Describe the solution you'd like
systemd instead of init.d or both options
Describe alternatives you've considered
We can create our own but the package should include them by default or as an alternative.

Can you tell me which files needs to be updated

Sure! For the CMS service this script is installing the service on Linux:
system/Tools/jetty/service/install-jetty-service.sh
and for the delivery tier services, these scripts installing the production and staging dts services:
deliverytiersuite/delivery-tier-suite/delivery-tier-distribution/src/main/rootFiles/DTSProductionService.sh
deliverytiersuite/delivery-tier-suite/delivery-tier-distribution/src/main/rootFiles/DTSStagingService.sh

@natechadwick can you please review


Update links from Upload.io -> Bytescale (rebrand)

Hey @Nutlope 👋
We've rebranded!
This PR updates roomGPT.io to use our new website's address & company name.
Hope all is well with you!

Congrats on the rebrand @ljwagerfield!


Internal Files Creation Settings

In short
There is no way to set up flags, date, locale, and compression to intertal files: (signature),  (listfile), (attributes).
What for?
Old game patches may have issues with opening modern internal files. Thus, giving errors of corrupt file.
Current implementation
Normaly there are two ways to replace/create file with this library:

SFileAddFileEx which is load file from file system.
SFileCreateFile which create MPQFile writeable handler, and allows most customization.
None of them permits to write internal files. It's intended hardcoded restriction.
Both of them using SFileAddFile_Init to create file. This function is internal one, and does not have such restriction.

You can try to overwrite internal file with SFileAddFile_Init, which is kinda pain, but even if you did it, anyways it will be overwritten again by SFileFlushArchive called from SFileCloseArchive.
Default settings

Flags = GetDefaultSpecialFileFlags(...) | MPQ_FILE_REPLACEEXISTING
Date = N/A (0)
LANG_NEUTRAL
Compression = ZLib

Workarounds

Simple: modify SFileAttributes.cpp, SFileListFile.cpp, SFileVerify.cpp with hardcoded values that you need.
Dirty hack: before closing file:

call SFileFlushArchive, it will generate updated internal files.
read existing internal files into memory, because we erase them next
call InvalidateInternalFiles(mpq)
mpq->dwFlags |= MPQ_FLAG_SAVING_TABLES. This is to disable auto InvalidateInternalFiles when new file is made
call DefragmentFileTable(mpq)
write internal files using SFileAddFile_Init
remove from mpq->dwFlags flags NEW and NONE for appropriate internal list files.
May be I'm overcomplicating dirty hack, but now I'm doing in this way. Perhaps you can just replace files and clear flags. Not sure.

Compression
There is SFileSetDataCompression function which should set default compression.
It turns out... its value is used only in SFileAddFileEx.
But internal files using SFileAddFile_Init. Thus, it has no effect for internal files.
They always use ZLib compression. In my case, it's not acceptable.
Ways to implement it

Use default compression for saving internal files.
Remember old properties of internal files during invalidation. (does not fix compression, because it's not property, there is only flag "I'm compressed")
Introduce new function for setting things up. (messy)
Add toggle to allow rewrite internal files, and disable their automatic overwriting.

I suggest (1) and (4) at the same time. Also, I can implement it and make pull request.
Writing things here, just to start discussion.

When opening existing archive:

TMPQArchive::dwFileFlags1 gets flags for (listfile)
TMPQArchive::dwFileFlags2 gets flags for (attributes)
TMPQArchive::dwFileFlags3 gets flags for (signature)

The intent is to save those special files with the same flags like they were before, because like you wrote, various games have various flags for tose files.
Then creating new archive: the SFileCreateArchive2, takes the SFILE_CREATE_MPQ structure as parameter. Its dwFileFlags1, dwFileFlags2 and dwFileFlags3 are used as input for those internal files.

So it's keeping flags. Good.
But if I wan't to change them, I need to create other MPQ. Bad.
I'll repeat. In my case, game crash because ZLib applied for internal files.
And SFileCreateArchive2 won't help.

Actually, SFileCreateArchive2 does help in my case!
Because I can create MPQ without compression of internal files, and thus, avoid them being ZLib compressed.
Other workaround is doing this way:
((TMPQArchive*)mpq)->dwFileFlags1 &= ~MPQ_FILE_COMPRESS;
((TMPQArchive*)mpq)->dwFileFlags2 &= ~MPQ_FILE_COMPRESS;
((TMPQArchive*)mpq)->dwFileFlags3 &= ~MPQ_FILE_COMPRESS;

Confirmed working.
But there is one corner case, if resulting dwFileFlags1 exactly MPQ_FILE_EXISTS, then two lines:
https://github.com/ladislav-zezula/StormLib/blob/e9f9b9bc58c63a72285920b889c8d434e74e8a28/src/SFileListFile.cpp#L389
https://github.com/ladislav-zezula/StormLib/blob/e9f9b9bc58c63a72285920b889c8d434e74e8a28/src/SBaseCommon.cpp#L342
Will give compressed file.
So, in my top post, I was wrong about Default flags: if internal file was in archive, it will keep same flags.

Fixed in commit adac4aa0f586c7aa2a3c19aa4e687d827dc86195.
You can now set MPQ_FILE_DEFAULT_INTERNAL (a new constant, equals to 0xFFFFFFFF) as dwFileFlags1, dwFileFlags2 and dwFileFlags3. StormLib will set default flags if you do.
If you want to set just MPQ_FILE_EXISTS, then you can and it will stay unchanged.


Claimed entities don't dissapear after owner inactivity

Protected entities are still protected after the claims dissapear and the owner is long gone.
They should also be unclaimed after a certain owner inactivity, just like terrains.
Spigot:  CraftBukkit version git-Spigot-4bd94dc-4a03053 (MC: 1.12.2)
GP: 16.7.1

@MithrandirCraft This repo is for the Sponge version of GP. Your issue is caused by this code
https://github.com/TechFortress/GriefPrevention/blob/master/src/me/ryanhamshire/GriefPrevention/EntityEventHandler.java#L920-L965
It has nothing to do with claims expiring as tamed entities store their owner with their data. All GP is doing is checking to see if the owner matches the attacker and if not denies it assuming the other checks passed. One fix could be to check if the owner has been active recently and if not allow the attack to occur. But this would be a discussion with the GP Bukkit devs.
Report it to https://github.com/TechFortress/GriefPrevention/issues

Appollogies for the mistake.


Investigate on the context created by spring cloud stream binder

To know why does each binder create an extra context

The binder context by default inherits from the application context with all the parent configuration. And it supports seperation from the application context for each binder component and then the configuartion customization can be achieved.


Input: Set IME position

As I was refactoring winit's interaction throughout Cushy, I realized we never call set_ime_position.

After the change referenced above, the input field should have the IME near it now. Currently, multi-line editing isn't really officially supported (#121), so this is kinda-ok for now. But really, we should restrict the rectangle to the current line being edited, which would allow the OS to place any helper windows even closer to the text being edited.

This is a duplicate of #46. Oops. I couldn't find it last week somehow.


picturefill with slick slider?

I have a site that is using http://kenwheeler.github.io/slick/
It has a lazyload option where you set lazyLoad: 'ondemand' in the JS options and add data-lazy="whatever.jpg" instead of src on each img tag.
picturefill does its thing with the first image, but then the next image that (either auto or by button click) slides into view isn't the correct image based on the sizes set. If you resize the window even a tad when a new image is in view picturefill kicks in.
Is there any way of adding some extra JS so that picturefill "has a sniff" when another image is displayed by the slider?
Thanks :)

Hey @kevadamson,
It looks like Slick has event handlers, so you could for example listen to 'beforeChange' and run the picturefill() function once that happens. For more information on this, check out the docs:
http://scottjehl.github.io/picturefill/#api
This may be a bit wonky depending on how Slick's lazy loading works, you may have to play around to find the first event handler that runs after the next image has been lazy-loaded.
Hope that helps!

@jegtnes Excellent many thanks. I owe you a pint. And if it works I owe you several :)

This is how I sorted it:
$('.your-slick-slider-class').on('afterChange', function(event, slick, currentSlide){
picturefill({
    reevaluate: true
});

});

Glad it worked for you! If you ever find yourself in Bristol, UK, I'll happily accept those beverages. :)


I don' see history for my attributes

Hi all,
I had to re-install homeassistant but, my bad, I have not done backup of configuration.yaml.
I have configured it again but now i am not able to see anymore the history of the attributes I have entered in the configuration.yaml.
What I am doing wrong? I'm getting mad 👎
Attached the configuration.yaml and the history I see in HA
Thanks for the ones willing to help me!

configuration.yaml.txt

Did you enable the Home assistant recorder? You can configure the number of days to keep via the argument: purge_keep_days.

Yes it is enable by the default_config:  that is at the beginnin of the configuration.yaml

Solved, I was calling wrongly the entity :-


Docker won't start with existing bridge and fixed CIDR of <IP_ADDRESS>/24

Hi,
I recently was configuring three Ubuntu hosts to talk over the same subnet i.e.
172.17.x.x
and ran into problems.
I have a pre-created bridge which has the following configuration:
auto docker0
iface docker0 inet static
    bridge_ports eth0
    address <IP_ADDRESS>
    netmask <IP_ADDRESS>

Then I attempted to start docker with the following options configured in /etc/default/docker
DOCKER_OPTS="-b=docker0 --fixed-cidr=<IP_ADDRESS>/24"

docker fails to start and reports the following in the log:
INFO[0000] -job init_networkdriver() = ERR (1)
FATA[0000] network does not contain specified subnet
INFO[0000] +job serveapi(unix:///var/run/docker.sock)
INFO[0000] Listening for HTTP on unix (/var/run/docker.sock)
INFO[0000] +job init_networkdriver()
network does not contain specified subnet

I have two other machines configured in an identical manner, one with an ip of <IP_ADDRESS> and a fixed CIDR <IP_ADDRESS>/24 and the other with an ip of <IP_ADDRESS> and fixed CIDR of <IP_ADDRESS>/24 and when starting docker on those hosts there is no problem.
After double checking my configuration I experimented and updated the network and cidr:
auto docker0
iface docker0 inet static
    bridge_ports eth0
    address <IP_ADDRESS>
    netmask <IP_ADDRESS>

/etc/default/docker
DOCKER_OPTS="-b=docker0 --fixed-cidr=<IP_ADDRESS>/24"

Docker started without complaint.
Is there something I'm missing here?
  Waiting to hear the status of that PR before proceeding.

closed becaue #10215 was merged


[Performance] Enable the SLPVectorizer to improve flash attention performance

The SLPVectorizer + IGC_DisablePHIScalarizer improves the overall 3% performance on flash attention forward kernel.
Enable the SLPVectorizer before the IGCVectorizer could do the same transformation.

There is no need to enable the SLP Vectorizer on Triton side because:

IGC is going to improve the IGC vectorizer to cover our requirements.
We can get FA performance without PHI node vectorization improvement already.


Conditional build:remove depending on environment

So I have an Angular app and 1.3 requires you to specify a <base href="/">.
The problem is that if I want to wrap my app for iOS using Cordova, that tag breaks all resources, so it needs to be removed only when building for Native.
If I do the following, then it gets removed every time, even when needed for production:
<!-- build:remove -->
<base href="/">
<!-- endbuild -->

What do you think? Is there already a way to achieve this? I thought it would look something like the following:
var options = {
    native: true/false
};
useref(options);

<!-- build:remove if(native) -->
<base href="/">
<!-- endbuild -->

<!-- build:remove if(!native) -->
<script id="cordova-js" src="cordova.js"></script>
<!-- endbuild-->

+1 for this feature
Here the use case I would like to write:
<!-- build:js:production inline -->
<script src="GoogleAnalytics.js"></script>
<!-- endbuild -->

or
<!-- build:remove if(!production) -->
<script src="GoogleAnalytics.js"></script>
<!-- endbuild-->

or
<!-- build:remove if(!production) -->
<script>
  // Google Analytics code
</script>
<!-- endbuild-->

This way I don't have Google Analytics code when in development.
grunt-processhtml supports this feature.