[SPARK-16473][MLLIB] Fix BisectingKMeans Algorithm failing in edge case

[SPARK-16473][MLLIB] Fix BisectingKMeans Algorithm failing in edge case where no children exist in updateAssignments
What changes were proposed in this pull request?
Fix a bug in which BisectingKMeans fails with error:
java.util.NoSuchElementException: key not found: 166
at scala.collection.MapLike$class.default(MapLike.scala:228)
at scala.collection.AbstractMap.default(Map.scala:58)
at scala.collection.MapLike$class.apply(MapLike.scala:141)
at scala.collection.AbstractMap.apply(Map.scala:58)
at org.apache.spark.mllib.clustering.BisectingKMeans$$anonfun$org$apache$spark$mllib$clustering$BisectingKMeans$$updateAssignments$1$$anonfun$2.apply$mcDJ$sp(BisectingKMeans.scala:338)
at org.apache.spark.mllib.clustering.BisectingKMeans$$anonfun$org$apache$spark$mllib$clustering$BisectingKMeans$$updateAssignments$1$$anonfun$2.apply(BisectingKMeans.scala:337)
at org.apache.spark.mllib.clustering.BisectingKMeans$$anonfun$org$apache$spark$mllib$clustering$BisectingKMeans$$updateAssignments$1$$anonfun$2.apply(BisectingKMeans.scala:337)
at scala.collection.TraversableOnce$$anonfun$minBy$1.apply(TraversableOnce.scala:231)
at scala.collection.LinearSeqOptimized$class.foldLeft(LinearSeqOptimized.scala:111)
at scala.collection.immutable.List.foldLeft(List.scala:84)
at scala.collection.LinearSeqOptimized$class.reduceLeft(LinearSeqOptimized.scala:125)
at scala.collection.immutable.List.reduceLeft(List.scala:84)
at scala.collection.TraversableOnce$class.minBy(TraversableOnce.scala:231)
at scala.collection.AbstractTraversable.minBy(Traversable.scala:105)
at org.apache.spark.mllib.clustering.BisectingKMeans$$anonfun$org$apache$spark$mllib$clustering$BisectingKMeans$$updateAssignments$1.apply(BisectingKMeans.scala:337)
at org.apache.spark.mllib.clustering.BisectingKMeans$$anonfun$org$apache$spark$mllib$clustering$BisectingKMeans$$updateAssignments$1.apply(BisectingKMeans.scala:334)
at scala.collection.Iterator$$anon$11.next(Iterator.scala:328)
at scala.collection.Iterator$$anon$14.hasNext(Iterator.scala:389)
How was this patch tested?
The dataset was run against the code change to verify that the code works.  I will try to add unit tests to the code.
(Please explain how this patch was tested. E.g. unit tests, integration tests, manual tests)
(If this patch involves UI changes, please attach a screenshot; otherwise, remove this)
Please review http://spark.apache.org/contributing.html before opening a pull request.

Can one of the admins verify this patch?

Jenkins, test this please.

@imatiach-msft Can you add a test case?

@imatiach-msft , thanks for creating pull request and committing change which I have shared , I will try to share some sample dataset for this issue.

Good point.  It looks like we should be checking if the map contains the child or not.  However, I'm not sure if that is the correct solution either.  I need a repro dataset from the bug reporter.

That makes more sense as a fix, yes. Sounds like there is still a to-do to verify the fix. If it's possible to write a simple unit test to cover it, all the better.

Yep, there is still a TODO to verify the fix.  I'm waiting for the dataset from Alok to reproduce the issue:
https://issues.apache.org/jira/browse/SPARK-16473

You can get sample vectors at this location https://github.com/alokob/SparkClusteringDataSet/SampleVectors.txt.
Also while executing bisecting K-Means , we have set following configuration settings ,
BisectingKMeans.setK(100);
BisectingKMeans.setMinDivisibleClusterSize(4);
BisectingKMeans.setMaxIter(4);
Please let me know if any additional details are needed.

@imatiach-msft Did you find the dataset suitable. Is anything else needed from my side?

Hi Alok!
Sorry I was away for holiday break.  I will try to reproduce the failure.
Thank you, Ilya

Thats ok , enjoy Xmas.
Please keep me posted if you find that issue is not resolved.

I have very good news :).  I was not only able to repro the issue with your dataset, but I was also able to verify that with the suggested fix the algorithm does not fail (adding the val newClusterChildren = children.filter(newClusterCenters.contains(_)) fixed the issue).
The error I saw was:
Job aborted due to stage failure: Task 0 in stage 53.0 failed 1 times, most recent failure: Lost task 0.0 in stage 53.0 (TID 105, localhost, executor driver): java.util.NoSuchElementException: key not found: 162
I need to figure out how to actually add the test case to spark though - my understanding is that checking in dataset files is not allowed?  My test code (not cleaned up yet) was:
import org.apache.spark.mllib.linalg.{
Vector => OldVector,
Vectors => OldVectors,
DenseVector => OldDenseVector,
SparseVector => OldSparseVector}
import org.apache.spark.ml.linalg.{
Vector => NewVector,
Vectors => NewVectors,
DenseVector => NewDenseVector,
SparseVector => NewSparseVector
}
@transient var loadedDataset: Dataset[_] = _
override def beforeAll(): Unit = {
super.beforeAll()
dataset = KMeansSuite.generateKMeansData(spark, 50, 3, k)
loadedDataset = spark.createDataFrame(sc.textFile("/home/ilya/SampleVectors.txt")
.map(line => Row({ OldVectors.parse(line.substring(1, line.length - 1)) match {
case sv: OldSparseVector => NewVectors.sparse(sv.size, sv.indices, sv.values)
case dv: OldDenseVector => NewVectors.dense(dv.values)
} })),
StructType(Seq(StructField("features", SQLDataTypes.VectorType))))
}
.....
test("SPARK-16473: Verify Bisecting K-Means does not fail in edge case where no children exist") {
val bkm = new BisectingKMeans().setK(100).setMinDivisibleClusterSize(4).setMaxIter(4)
assert(bkm.getK === 100)
assert(bkm.getFeaturesCol === "features")
assert(bkm.getPredictionCol === "prediction")
assert(bkm.getMaxIter === 4)
assert(bkm.getMinDivisibleClusterSize === 4)
val model = bkm.fit(loadedDataset)
assert(model.hasSummary)

}

ok to test

Test build #70679 has started for PR 16355 at commit 55ab179.

Nice to know that , codefix I suggested is working. Its really nice to contribute in spark.

Test build #70679 has finished for PR 16355 at commit 55ab179.

This patch passes all tests.
This patch merges cleanly.
This patch adds no public classes.

Merged build finished. Test PASSed.

Test PASSed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/70679/
Test PASSed.

I've updated with a new commit.  I was able to reproduce the issue by generating a synthetic sparse dataset similar to the one Alok sent me, in accordance with the test-style of spark test methods.  Hence, I was able to verify the fix.  Please review the new code changes and let me know who else needs to review in order for the changes to be committed.

Jenkins, retest this please

Test build #70682 has started for PR 16355 at commit 75192a7.

Test build #70682 has finished for PR 16355 at commit 75192a7.

This patch fails Scala style tests.
This patch merges cleanly.
This patch adds no public classes.

Merged build finished. Test FAILed.

Test FAILed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/70682/
Test FAILed.

Jenkins, retest this please

Test build #70688 has started for PR 16355 at commit 14c7ce3.

Test build #70688 has finished for PR 16355 at commit 14c7ce3.

This patch passes all tests.
This patch merges cleanly.
This patch adds no public classes.

Test PASSed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/70688/
Test PASSed.

Merged build finished. Test PASSed.

@jkbradley @srowen any comments on the changes?  Thank you!

@yu-iskw Pinging on this since you wrote bisecting k-means originally.  Do you have time to take a look?  Thanks!

the only problem I see is that with this code we generate k-1 clusters instead of k, but it states in the algorithm documentation that it is not guaranteed to generate k clusters, it could be fewer if the leaf clusters are not divisible (see spark/mllib/src/main/scala/org/apache/spark/mllib/clustering/BisectingKMeans.scala):
Iteratively it finds divisible clusters on the bottom level and bisects each of them using
k-means, until there are k leaf clusters in total or no leaf clusters are divisible.
It seems in the dataset Alok gave, one of the clusters which was assumed to be divisible and was divided ended up generating two clusters, one which contained all the points and the other none, which is what created the error (his cluster 162, child of 81, was empty, but cluster 163 was non-empty after reassignment).

@jkbradley Thank you for taking a look! I've updated the code based on your comments.

Test build #70994 has started for PR 16355 at commit a8cf2f0.

Test build #70994 has finished for PR 16355 at commit a8cf2f0.

This patch passes all tests.
This patch merges cleanly.
This patch adds no public classes.

Test PASSed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/70994/
Test PASSed.

Merged build finished. Test PASSed.

@jkbradley @yu-iskw @srowen can you please take another look at the bisecting k-means algorithm fix?  Thank you!

Hi
Here is a dataset that makes it fails with K=100 and maxIter=2
I know K>distinct features but I can reproduce the error with bigger datasets.
The fix seems to make it go further, but it fails later in the code with similar exception.

@filousen could you please share the code that you used to load and run the dataset and the full error message with stack trace you are seeing?  I'm a bit confused since the dataset is not a vector and all values in label are unique.
Thank you, Ilya

@imatiach-msft thank you for checking this.
I'm using a VectorAssembler to transform the dataset I read from the json I pasted earlier.
VectorAssembler assembler = new VectorAssembler()
.setInputCols(new String[]{"count"})
.setOutputCol("features");
Dataset ds = assembler.transform(jsonDs).
Then I use the transformed dataset with BisectingKMeans.
BisectingKMeans bkm = new BisectingKMeans().setK(100).setFeaturesCol("features").setMaxIter(2);
BisectingKMeansModel model = bkm.fit(ds);
Dataset res = model.transform(ds);
I have had about 30% of my datasets that failed with the similar error.
Thanks

How did you verify that this change does not fix it?  I ran the following code and it ran without errors:
test("Verify issue from user") {
val jsonDs = spark.read.json("/home/ilya/ReproBisectingKMeansFailure.txt")
val assembler = new VectorAssembler()
.setInputCols(Array("count"))
.setOutputCol("features")
val ds = assembler.transform(jsonDs)
val bkm = new BisectingKMeans().setK(100).setFeaturesCol("features").setMaxIter(2)
val model = bkm.fit(ds)
val res = model.transform(ds)

}

@filousen   I must have fixed your issue, because if I undo my changes and run your code I can reproduce the error, you must be running your code without this fix:
Job aborted due to stage failure: Task 0 in stage 26.0 failed 1 times, most recent failure: Lost task 0.0 in stage 26.0 (TID 27, localhost, executor driver): java.util.NoSuchElementException: key not found: 68
at scala.collection.MapLike$class.default(MapLike.scala:228)
at scala.collection.AbstractMap.default(Map.scala:59)
at scala.collection.MapLike$class.apply(MapLike.scala:141)
at scala.collection.AbstractMap.apply(Map.scala:59)
...

@filousen please note this fix is still in review and hasn't been checked into spark yet.  Can you send me the error you are seeing?  Also, are you sure you have ported my entire fix to your codebase where you are testing?

The changes proposed in updateAssignments solved partially the problem, because the key exception is still there.
There another key exception in buildSubTree method, if I do i_f (isInternal && clusters.contains(rightChildIndex(rawIndex))_ instead if (isInternal) there is no more exceptions.
I should perform some tests in order to check if the results are good enough, and comments about this suggestion are welcome.

It looks like you don't have all of my changes.  I also updated the buildSubTree method.  Please take a look at the latest commit.

@carocat @filousen
Please look at these changes that I updated on December 28:

   val height = math.sqrt(Seq(leftIndex, rightIndex).map { childIndex =>

   val indexes = Seq(leftIndex, rightIndex).filter(clusters.contains(_))

   val height = math.sqrt(indexes.map { childIndex =>
     KMeans.fastSquaredDistance(center, clusters(childIndex).center)
   }.max)

   val left = buildSubTree(leftIndex)

   val right = buildSubTree(rightIndex)

   new ClusteringTreeNode(index, size, center, cost, height, Array(left, right))

   val children = indexes.map(buildSubTree(_)).toArray

   new ClusteringTreeNode(index, size, center, cost, height, children)

@jkbradley @yu-iskw @srowen can you please take another look at the bisecting k-means algorithm fix? Thank you!

You are right, I didn't add all changes you had proposed for buildtree.
Everything works fine with your changes :-) Many thanks

@imatiach-msft I can confirm the fix works after copying the full source to make sure no mistake was done.
I ran it with around 200 datasets, and they all worked 👍
Thank you for you time and the fix!

@jkbradley thanks, I've updated the code based on your latest comments - I removed k and the verification for the setters.

Test build #71289 has started for PR 16355 at commit 138ab34.

Test build #71289 has finished for PR 16355 at commit 138ab34.

This patch passes all tests.
This patch merges cleanly.
This patch adds no public classes.

Merged build finished. Test PASSed.

Test PASSed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/71289/
Test PASSed.

ping @jkbradley would you be able to take another look at the bisecting K-Means fix?

test this please

LGTM pending a fresher run of the tests
Thanks @imatiach-msft !

Test build #71533 has started for PR 16355 at commit 138ab34.

I was about to say this is ready, but I do think we should add the seed.  Other than that, this should be ready!

@jkbradley done, added seed.  Thanks!

Test build #71538 has started for PR 16355 at commit ba00ad0.

Test build #71533 has finished for PR 16355 at commit 138ab34.

This patch passes all tests.
This patch merges cleanly.
This patch adds no public classes.

Test PASSed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/71533/
Test PASSed.

Merged build finished. Test PASSed.

Test build #3538 has started for PR 16355 at commit ba00ad0.

Test build #71538 has finished for PR 16355 at commit ba00ad0.

This patch passes all tests.
This patch merges cleanly.
This patch adds no public classes.

Merged build finished. Test PASSed.

Test PASSed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/71538/
Test PASSed.

Test build #3538 has finished for PR 16355 at commit ba00ad0.

This patch passes all tests.
This patch merges cleanly.
This patch adds no public classes.

ping @jkbradley would you be able to take another look at the bisecting kmeans model?  I've updated with the random seed as requested.

ping @jkbradley would you be able to take another look at the bisecting kmeans model? I've updated with the random seed as requested, and the build succeeded.  Thank you!

ping @jkbradley would you be able to take another look at the bisecting kmeans model?  Thanks!

ping @jkbradley would you be able to take another look at the bisecting kmeans model? Thanks!

LGTM
Thanks!
Will merge after fresh tests

Test build #3548 has started for PR 16355 at commit ba00ad0.

Test build #3548 has finished for PR 16355 at commit ba00ad0.

This patch passes all tests.
This patch merges cleanly.
This patch adds no public classes.

Merging with master.  Will try to backport to branch-2.1 as well.
Thanks!

I was able to check out this commit and test it with branch-2.1, but now I can't get the merge script to merge it for branch-2.1.  @srowen would you mind trying?  Thanks!

but now I can't get the merge script to merge it for branch-2.1

I just had some issues with that too. But manually merging (git cherry-pick + git push) seems to still work, so maybe try that.

It's an apache-github sync issue:
https://github.com/apache/spark/commits/branch-2.1
is missing the latest commit from
https://git-wip-us.apache.org/repos/asf?p=spark.git;a=shortlog;h=refs/heads/branch-2.1
I'll cherry-pick onto apache/branch-2.1 and push as that might also kick the sync to try again.

Done, and it synced now. Merged to master/2.1

Oh OK!  Thanks @srowen


Error: spawn @newrelic\next ENOENT

I follow this instruction https://newrelic.com/blog/how-to-relic/nextjs-monitor-application-data and get the error message
For my case
 "next:dev": "cross-env next dev"

becomes
 "next:dev": "cross-env NODE_OPTIONS='-r @newrelic/next' next dev"

but it doesn't work. And logs doesn't give me a clue, what is wrong.
The system cannot find the path specified.
node:events:505
      throw er; // Unhandled 'error' event
      ^

Error: spawn @newrelic\next ENOENT
    at notFoundError (C:\Projects\alterra\Sitecore-Headless-Mammoth-2\mammoth-headless\node_modules\cross-spawn\lib\enoent.js:6:26)
    at verifyENOENT (C:\Projects\alterra\Sitecore-Headless-Mammoth-2\mammoth-headless\node_modules\cross-spawn\lib\enoent.js:40:16)
    at ChildProcess.cp.emit (C:\Projects\alterra\Sitecore-Headless-Mammoth-2\mammoth-headless\node_modules\cross-spawn\lib\enoent.js:27:25)
    at Process.ChildProcess._handle.onexit (node:internal/child_process:291:12)
    at Process.callbackTrampoline (node:internal/async_hooks:130:17)
Emitted 'error' event on ChildProcess instance at:
    at ChildProcess.cp.emit (C:\Projects\alterra\Sitecore-Headless-Mammoth-2\mammoth-headless\node_modules\cross-spawn\lib\enoent.js:30:37)
    at Process.ChildProcess._handle.onexit (node:internal/child_process:291:12)
    at Process.callbackTrampoline (node:internal/async_hooks:130:17) {
  code: 'ENOENT',
  errno: 'ENOENT',
  syscall: 'spawn @newrelic\\next',
  path: '@newrelic\\next',
  spawnargs: [ 'next', 'dev' ]
}
ERROR: "next:dev" exited with 1.

What could be wrong?
Where should I look at?

It looks like some issue with cross-env.


AWS EC2 instances left unnamed on failure

Found an interesting riddle to solve. I have an ec2 instance on our account that was running for a few days without activity. It has no name, unlike other cml self-hosted runners, but it was using a keypair with a name that was prefixed with "Iterative-", which is pretty telling that CML did deploy this instance. [...] What happened here? Did CML get interrupted in such a way that the instance was started but not named? Are there other ways for CML to skip naming an instance? (From Discord)

Currently, instances are being created first and then tagged with a Name tag that gets displayed on the web console as the instance name. Any failure between the creatin and tagging process can leave unnamed instances as described.
https://github.com/iterative/terraform-provider-iterative/blob/4044aee23ea8209ba5244faeaafa8fdbfe92a26e/iterative/aws/provider.go#L270-L286

Indeed,  as seen here https://github.com/iterative/terraform-provider-iterative/pull/187#issuecomment-916090240 the name is not empty but dashed and the guilty is not even that bit the Id. The main reason it can not be destroyed is because of the Id.
I can see the code here:
func SetId(d *schema.ResourceData) {
	if len(d.Id()) == 0 {
		d.SetId("iterative-" + uid.NewProvider36Size(8).MustGenerate().String())

		if len(d.Get("name").(string)) == 0 {
			d.Set("name", d.Id())
		}
	}
}**

For some reason its coming with - instead of empty

@DavidGOrtega, https://github.com/iterative/terraform-provider-iterative/pull/187 solves this: now, normal instances are being tagged on creation (i.e. if it exists, it has tags) and spot instance requests are being cancelled after the 10 minute timeout.
I suspect that the issue was that some spot instance requests take more than 10 minutes to fulfill, and we were erroring and failing wihtout cancelling the request, so the spot instance would get allocated anytime in the future and out provider wouldn't be running to tag it.
https://github.com/iterative/terraform-provider-iterative/blob/f7755f7b656c92503beb515adf7ea8fc4dd24921/iterative/aws/provider.go#L231-L242
https://github.com/iterative/terraform-provider-iterative/blob/f7755f7b656c92503beb515adf7ea8fc4dd24921/iterative/aws/provider.go#L271-L286
Since #187, we wait those 10 minutes and then cancel the request before exiting. Not a perfect solution, but good enough for winning the race lottery. 🙃

Yeah it could be, however... why I was able to reproduce it with the code of #187 applied? @0x2b3bfa0

Anyway lets close this once #187 is published!

My other question would be.... why a dash? Its an AWS thingy?

My other question would be.... why a dash? Its an AWS thingy?

Yes, that's what AWS displays when there is no Name tag for the resource. 🙃

Closed with #187


8.0 Non blade view doesn't load (worked in 7.*)

A view (non blade) that's a php file gives error, but worked perfect in 7.* laravel, the error:
Too few arguments to function Illuminate\View\Engines\PhpEngine::__construct(), 0 passed in C:\BitNami\wampstack-7.4.7-0\apache2\laravel80up\vendor\facade\ignition\src\IgnitionServiceProvider.php on line 128 and exactly 1 expected

It's called in controller like:
        return view('dog/indexadmin')
                ->with('dogs', $dogs)
                ->with('pagelinks', $pagelinks);

// also tried

        return view('/dog/indexadmin')
                ->with('dogs', $dogs)
                ->with('pagelinks', $pagelinks);

In view I even tried this:
<!DOCTYPE html>
<html lang="en">
    <head>
        <meta charset="utf-8">
        <title>hello</title>

    </head>

    <body>
        <?php echo 'hello';
        die;
        ?>
        <div>
        //  more code

Got same error.  And ignition seems to show it's error where you can't see actual error.
Note original name was:
indexadmin.php

// changing it to

indexadmin.blade.php it worked

All prior versions, the view worked without blade if using php as template language.

vendor\facade\ignition\src\IgnitionServiceProvider.php

It's a problem with ignition, please check their issues

@mfn  I am not worried about ignition, my concern is:

someview.php does not work any more.
Renaming to someview.blade.php works.

Never had to do this prior to version 8.

Yep, that seems to be caused by the issue in ignition?

Never had to do this prior to version 8.

It's because the PhpEngine template engine was changed in Laravel 8 in a breaking way, requiring all implementors adapting their code.
And this means also Ignition, that's why you get this in your error:

Too few arguments to function Illuminate\View\Engines\PhpEngine::__construct(),

and that's how I know it's a "problem" with Ignition:

vendor\facade\ignition\src\IgnitionServiceProvider.php

I've just tagged a release on Ignition that solves this. Run composer update to pull it in. Let me know if this fixes the issue for you.


Make the persist annotations constants

Description:
Currently, persist module consist of 3 annotations,
@persist:Entity
@persist:AutoIncrement
@persist:Relation

These annotations must be resolved at compile time and not at runtime. For instance the annotation attachment,
string[] keyArray = ["needId"];

@persist:Entity {
    key: keyArray
}
public type MedicalNeed record {|
    readonly int needId = 1;
    int? itemId;
    int beneficiaryId;
    string period;
    string urgency;
    int quantity;
|};

The above should not be valid as the keys must be defined and processed at compile time.
The above requirement can be achieved by making the annotation constant,
public const annotation EntityConfig Entity on type;

This has additional value sine this will make tooling experience much cleaner(Related issue: https://github.com/ballerina-platform/ballerina-standard-library/issues/3635)

When looking into this aspect, I found that annotation with array type fields cannot be made constant. This is valid even if user defines in-line array as such,
@persist:Entity {
    key: ["needId"]
}

@MaryamZi Is there any workaround for this?

When looking into this aspect, I found that annotation with array type fields cannot be made constant. This is valid even if user defines in-line array as such,
@persist:Entity {
    key: ["needId"]
}

Please create a lang issue for this. Right now, we only support a limited set of constant expressions. For annotations though, we allow some extra expressions with source-only annotations. We should be able to do the same with non-source const annotations.

@MaryamZi Is there any workaround for this?

Are these annotations required at runtime too? If not, you could make this a source-only annotation as a workaround for now.
public const annotation EntityConfig Entity on source type;

After trying out source annotation, I found a blocker https://github.com/ballerina-platform/ballerina-lang/issues/38743
Pausing this effort till the 2201.3.0-rc3 is released with the fix

After testing on RC3 pack the final conclusions are,

All persist annotations can be defined as source annotation.  source annotation are only read at compile time. This matches with the persist module use case.
Further validation we have to do is not support referring const variables in annotation declaration. This should be a custom restriction for persist module on top of Conclusion 1. This is because these values are used for client generation and not available at syntax tree when generated clients, thus cannot be processed.

This is on hold due to persist module design V2

This can be an issue when we support constraint annotation. https://github.com/ballerina-platform/ballerina-standard-library/issues/3360
Constraint usecase has to be looked into.


Plural type name memoization

This PR introduces plural type name memoization since there is no need to search for it every time we do a phrase transformation if locale doesn't change.

I've just rebased this; please feel free to add the test on top of it.


The F10.7 81-days average value miss information

Dear Developer,
As I try to use the msis2 model, the input parameter is
dates=np.datetime64('2020-12-15T00:00:10')
lons=-69.797
lats=-51.809
alts=504.7

And I try to sed the F107 and Ap index is None, so that the model could down the latest space weather data, but it return:
*** ValueError: Input data has non-finite values, all input data must be valid.
I found the pymsis.utils.get_f107_ap(dates) return the f107as is nan (np.nan),
so that cause the main function return the error above.
Is there some way to fix this?
Thank you

The data source has been updated in v0.7.0, so please update to the newly released version and this should work as expected.


Possible solution for MIDIPacketNext .pointee Swift crashes

Disregard - issue persists and remains elusive after further testing.

Thanks for the information in any case! I wasn’t aware of `

The issue is brutally elusive so I'm taking a hint from your implementation to see if a C-based MIDIPacketNext wrapper and unsafe memory access can prevent crashes.
This has been a long-standing issue with CoreMIDI in Swift and I really wish Apple would care enough to fix it.
I've seen many other libraries dogged with this issue because it doesn't always crop up right away.

Yes unsafeSequence() and the event iterator work well but they are only available on more recent Apple platforms - macOS 10.15, iOS 13.0, macCatalyst 13.0.
What I found was different memory issues and crashes would appear depending on the OS version, so I had to add some robustness to handling the pointers on older platforms. If you're curious I can link some of the solutions. But If you're comfortable dropping support for older platforms then just go with the new API.


'str' object has no attribute 'custom_id'

Traceback (most recent call last):
File "c:\Users\redme\OneDrive\바탕 화면\python\bot.py", line 1444, in
client.run(token[0])
File "C:\Users\redme\AppData\Local\Programs\Python\Python39\lib\site-packages\discord\client.py", line 729, in run
return future.result()
File "C:\Users\redme\AppData\Local\Programs\Python\Python39\lib\site-packages\discord\client.py", line 708, in runner
await self.start(*args, **kwargs)
File "C:\Users\redme\AppData\Local\Programs\Python\Python39\lib\site-packages\discord\client.py", line 672, in start
await self.connect(reconnect=reconnect)
File "C:\Users\redme\AppData\Local\Programs\Python\Python39\lib\site-packages\discord\client.py", line 572, in connect
await self.ws.poll_event()
File "C:\Users\redme\AppData\Local\Programs\Python\Python39\lib\site-packages\discord\gateway.py", line 559, in poll_event
await self.received_message(msg.data)
File "C:\Users\redme\AppData\Local\Programs\Python\Python39\lib\site-packages\discord\gateway.py", line 509, in received_message
func(data)
File "C:\Users\redme\AppData\Local\Programs\Python\Python39\lib\site-packages\discord\state.py", line 561, in parse_interaction_create
self.dispatch('button_click', interaction, interaction.component)
File "C:\Users\redme\AppData\Local\Programs\Python\Python39\lib\site-packages\discord\interactions.py", line 230, in component
self._component = utils.get(self.message.all_buttons, custom_id=custom_id)
File "C:\Users\redme\AppData\Local\Programs\Python\Python39\lib\site-packages\discord\utils.py", line 297, in get
if pred(elem) == v:
AttributeError: 'str' object has no attribute 'custom_id'

What Version are you using?


Support disabling a whole class of rules

Is your feature request related to a problem? Please describe.
I'm frustrated because Chef callback scripts and Capistrano scripts in my codebase keep getting picked up by rubocop-rails rules, and when folks follow them, trying to be helpful, it causes problems. The most recent example is following Rails/Pluck breaking a Chef script.
Describe the solution you'd like
I'd like to be able to say:
Rails/*:
  Exclude:
    - "deploy/**/*"

So Rails-related rules don't ever get called for non-Rails stuff.
Describe alternatives you've considered
What we've been doing is adding rubocop:disable comments where the Rails rules hit, but when a new one comes along, some good-intentioned person follows it and breaks stuff.
We could add every Rails/ rule to .rubocop.yaml with the exclude above, but it will also fail to capture the case where a new rule comes along and a good-intentioned person follows it and breaks stuff.

RuboCop can set Exclude for each department. Is it possible to resolve this issue with the following setting for .rubocop.yml?
Rails:
  Exclude:
    - "deploy/**/*"

I believe you can achieve that by overriding the rules per directory with a custom .rubocop.yml file:
e.g.
deploy/.rubocop.yml
inherit_from: ../.rubocop.yml
Rails:
  Enabled: false

@vlad-pisanov that works! thanks


the bundle has much empty module

the bundle(eg. react.bundle.js) has much empty module.
    /* 176 */,
    /* 177 */,
    /* 178 */,
    /* 179 */,
    /* 180 */,
    /* 181 */,
    /* 182 */,
    /* 183 */,
    ......

Can you provide some sort of test case (sample project)? It's hard to say anything concrete without.

@bebraw you can see: https://github.com/webpack/webpack/tree/master/examples/multiple-commons-chunks#jscommonsjs
it contains:
 /* 1 */,
 /* 2 */,
 /* 3 */,

That's a side effect of CommonsChunkPlugin. The modules that are empty are loaded by other files; for example, the skipped /* 2 */ is loaded by pageA.js.

It's an optimization:
If a chunk contains the modules 3, 4, 6 it would emit them as:
{3:xxx,4:xxx,6:xxx}

where xxx is a function containing the module.
But webpack has an optimization which emits the modules as array, which results in this:
[,,,xxx,xxx,,xxx]

You may notice that this is shorter in many cases.
This looks like there are empty modules, but this isn't the case. These module ids are just not in this chunk.


Delete wasn't removing versioned rows

Delete wasn't removing versioned rows. array_map expects second parameter to be an array not an object which $this->getAffectedRecords() returns.

Thanks again! :)


Rendering a table inside of a show page

Here is the question
https://stackoverflow.com/questions/53907543/rails-admin-rendering-a-table-inside-a-model-show-action

This is an issue tracker. No support requests, please.

The issue is that there is no normal way to render table on the 'show' page.


Scope

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

Hey @sapjr , this functionality was implemented in a recent PR💯
BR Robert


ReferenceError: app is not defined

ReferenceError: app is not defined
    at eval (eval at eval_script (/workspaces/snaptik-app/src/index.js:38:23), <anonymous>:3:300)
    at module.exports.eval_script (/workspaces/snaptik-app/src/index.js:38:140)
    at module.exports.process (/workspaces/snaptik-app/src/index.js:109:16)
    at process.processTicksAndRejections (node:internal/process/task_queues:95:5)

SnapTik embedded error handling within the obfuscated script, which triggers app.showAlert() when an error occurs. Should be fixed now!


Move to pytest-dev organization

As discussed with @jmcgeheeiv, it would be a good idea to transfer this repo to the pytest-dev organization. This would help to ensure continued maintenance, and also possibly to get more eyes for issues and code reviews (given enough eyeballs...).
While pyfakefs is not only a pytest plugin, as it can also be used with other test frameworks, pytest-dev seems like a good match, as the majority of new pyfakefs users seem to use it via the fs fixture, and improving pytest support is a sensible goal for pyfakefs.
We seem to meet most of the preconditions, except the name (nothing we can do about this, changing it now would not be a good idea), and the authors info, which can easily be added.
The first step will be to clarify if pyfakefs is feasible for pytest-dev - I will write a respective mail in the pytest-dev list, and we can go on from there of we get a go.
cc @nicoddemus

I also offer domain pyfakefs.org to the PyTest community.
If you do not care for it I will continue to maintain it and point it to the right location for a few years at least.

Unfortunately, it turned out that pyfakefs seems not really to fit into pytest-dev.
There has been a couple of suggestions for another organization: PyCQA, which I don't think will fit, as it is almost exclusively about linting tools, and a new organization cogs-of-testing, which was meant to be about testing, but is still empty.
I still like the idea about transfer to an organization for obvious reasons, and still think that pytest-dev would fit best of the existing ones, but as long as there is no fitting organization, I see no real way to do this at the moment.
Sorry about that - I really thought that this would work...

I think it was a good idea to propose it. If the other organizations do not care for pyfakefs, that is their prerogative.

Closing this for now.

Reopen as the move is now approved.
Some things to do after the move:
[ ] adapt all URLs in the README and documentation
[ ] change master to main, while at it
[ ] optional: add automatic release to PyPi

Transfer to @nicoddemus requested.

Thanks folks!
Move has been completed, invite sent to @jmcgeheeiv to join the pytest-dev organization. 👍

I plan to make a 5.0 release soon, where the automatic release will be tested. Hopefully not forgetting anything for that...

In case you want a template, you can take a look at: https://github.com/pytest-dev/pytest-mock/blob/main/.github/workflows/deploy.yml
You need to create a pypi_token secret in this repository with an upload token from PyPI, then you can just drop it in the .github folder and it will work. 👍

Ok, the release workflow is working on second try, but Read the Docs does not trigger. Maybe I misconfigured something or removed too much...


Fix docker build

replace find_library with find_package

will open another pull request only changing CMakefile

test passed, close now


Launch Geth from Electron

Run from ./bin/, configure RPC to use Geth + Connector,

@splix after our last redesign should we continue to use the word Connector in relation to emerald-rs, because now it's just offline personal wallet, no more?


create post require auth and saves to database, small error with foot…

…er overlapping submit button on certain display sizes

please look closely before mergeing


Fix Datastore::Transaction unit tests

A change in minitest exposed what appears to be redundant mock setup. This setup is already made in lines 21-5:
let(:connection)  do
   mock = Minitest::Mock.new
   mock.expect :begin_transaction, begin_transaction_response
   mock
end

Makes sense. I've been following the discussion on changes Minitest::Mock that causes this. :+1:


High CPU usage of lastest version (<IP_ADDRESS>9 Beta)

After updating gogs to 0.5.10 (build from source)
gogs web eat up 99.99% of CPU cycle and never drop.
When falling back to version <IP_ADDRESS>3 Beta (Binary build) or <IP_ADDRESS>5 Beta (build from source), CPU usage back to normal around (~2% when idle).

This is happening to demo server, too. I've found it's because it's executing git-fsck, and I'm adding a switch option for this.

Yes, after monitoring the server for a few hours.
git fsck seems to be the cause of high CPU usage.
This is my server's CPU usage graph.

There are a constant CPU spikes per hours.
Around 10:00 the CPU usage stay at 100% and never drop until I stop gogs web and down grade to v0.5.9.
But I cannot reproduce this by switching back v0.5.10, maybe there is some misconfiguration on my side.
I think there should also be a configuration option to control the frequency of git fsck.
I don't known much about git fsck, is it necessary to run per hour?

Hi, I've pushed a fix on dev which make 24 hours as default interval, and of course, you're now able to disable it.

Still no luck with <IP_ADDRESS>2 Beta.
I've tried to reset all my custom settings but got the same result (top command showing gogs eat up 99% of CPU cycle).
This how I build gogs from, am I doing it wrong?
cd $GOPATH/src/github.com/gogits/gogs
git pull
git checkout dev
go get -u -tags "redis" ./...
go build -tags "redis"
cp -r /opt/gogs/custom/ ./custom
Thanks for the hard work, but I better stay at v0.5.9 right now until I found what was wrong with my server.

Looks like git-fsck just one reason, and there is something deadlock.

@TonyTsangHK OK, I've found this is a bug in macaron-contrib/cache , fixes are pushed.

It works!
Good job


[FLINK-24189] Perform buffer debloating per single gate

What is the purpose of the change
This PR moves calculating throughput as well debloating buffers to
the gate level. It should help with situations when there is a
significant difference in gates throughput.
Does this pull request potentially affect one of the following parts:

Dependencies (does it add or upgrade a dependency): (yes / no)
The public API, i.e., is any changed class annotated with @Public(Evolving): (yes / no)
The serializers: (yes / no / don't know)
The runtime per-record code paths (performance sensitive): (yes / no / don't know)
Anything that affects deployment or recovery: JobManager (and its components), Checkpointing, Kubernetes/Yarn, ZooKeeper: (yes / no / don't know)
The S3 file system connector: (yes / no / don't know)

Documentation

Does this pull request introduce a new feature? (yes / no)
If yes, how is the feature documented? (not applicable / docs / JavaDocs / not documented)

@flinkbot run azure

@flinkbot run azure

@flinkbot run azure


Bring stopwatch functionality back to Task class

https://github.com/kostrykin/repype/blob/f0baeb2e5ae38e09ef9fbf8e59da48b35014f47e/repype/task.py#L467
Maybe also add memory benchmarking?

Fixed in #29


Add "const" to function prototypes where appropriate

In particular, this should be done at least for functions that accept char * strings but do not modify them.  If a string literal (by definition a const char *) is passed into function argument that is declared a non-const char *, a compiler warning may be generated and the build will fail if compiled with strict settings.
This ticket will add "const" to function parameters where appropriate.

Imported from trac issue 9.  Created by jphickey on 2014-12-30T20:44:18, last modified: 2019-03-05T14:57:55

Trac comment by jphickey on 2015-01-26 13:18:17:
Merged into ticket #59

Trac comment by jhageman on 2019-03-05 14:57:55:
Milestone renamed


Wishlist Issue with B2b Portal

Type: (Select one)

[ ] Bug Report

Summary:
I m using B2b portal. In that wish list link there(home page, category page). When i click it is going to B2b login Page. After login it is continuous going to login page popup.
Expected Behavior:

After login it should be redirect to wish list page.

Actual Behavior:

It is redirect to login to login page even i m  login

More information :
screencast-bpconcjcammlapcogcnnelfmaeghhagj-2024.06.27-17_45_59.webm
Let us know if you need more information

Hi @SunilP-WassDigital, according to your test it redirected you to the login page. But by default it should redirect to register. Is there any customizations from your part on this workflow? thanks

Hello @bc-victor
As I see you are checking shopping list, i m asking for wishlist.
Please disable shopping list from company and check it.

@SunilP-WassDigital could you show me the exact setting? I can't reproduce by disabling it here:

Video of test:

Hello @bc-victor
No setting we added into our side, may be recently did some fix for that.
but still it is not right. after login should be redirect to wish list page directly, currently it is redirect to account page and still item not adding item into wish list.

@SunilP-WassDigital

after login should be redirect to wish list page directly
AFAIK there is no Wish List page in the buyer portal. If so could you direct me to the hash route or provide a screenshot?
If you mean it should redirect to the stencil wish list page - I'd have to ask the product team if that is actually expected behavior.

According to our product team stencil wish lists page should never exists for Buyer Portal stores, once the user logged in, a better place to redirect would be the Buyer Portal Shopping Lists tab - will create a ticket for this behavior

Closing as no further communication continued


QRPGLESRC

I can see my source physical files in the libraries.  I can open source from all the other source physicals but QRPGLESRC.  I click or double click and nothing happens.
Thoughts,
Matt

@mattsheawave What if you disable SQL in the connection settings, reconnect, and try again?

Did you get this error?

I have disabled SQL
gives me this error: "Source date support is disabled. SQL must be enabled."

I have disabled SQL,
gives me this error: "Source date support is disabled. SQL must be enabled."

I have disabled SQL
gives me this error: "Source date support is disabled. SQL must be enabled."

For source dates to work, your QCCSID must not be 65535.

can i change it?

280?

Upon VS Code startup I receive a message "QCCSID is set to 65535. Disabling SQL Support."  So it appears, SQL is already disabled.
I can successfully edit CL and DDS source, just not RPGLE.

@mattsheawave what is stopping you from editing RPGLE?

@worksofliam When I click on an RPGLE member, nothing happens.  It doesn't open in the editor window.  Single click, double click.  When I single click on CL or DDS members, they open fine in the editor window.

@mattsheawave can you go to the Code for IBM i output tab and paste me the content after you try to open the member?

@mattsheawave You have a different issue.

Database file CCSID is 65535

This is because your source file is in CCSID 65535. You can override this by changing the 'source file CCSID' connection setting.

@mattsheawave Source date support will be enable-able without SQL support as of tomorrow.

Possible dupe of #534


Question about training on action recognition

Hi, Thanks to your excellent work!
However, when I try to train action UCF101 or HMDB51 following ur README, I found some error, the major is as belows:
When it comes to sample() in train_actions.py, I found that the shape of batch_att is (101,300), after samling the shape is (64,300). But the shape of input_att should be (64,115), so the code could not do copy().
PS: I used the att_splits.mat in ur google drive.
Looking forward to your reply!

@bobo199830 Can you show the errors while you run the code?


Redundant checks may be needed in the future

In https://github.com/SoftEtherVPN/SoftEtherVPN/commit/564ca6087fc489ba3551e5b5aa0afc0f18093494 we removed the redundant checks on Ready == false inside the lock.
Currently it's fine because in the code Ready is never changed. However there is no guarantee that this won't happen in the future. If it happens, one is very unlikely to remember to add back these checks and it is possible that Ready changes after the lock.
Can we revert the commit? @chipitsine

I think we'd better to use thread sanitizer to catch race condition

Sorry I am not sure how that relates to my question.


Add Github templates

related to: https://blog.github.com/2016-02-17-issue-and-pull-request-templates/

Can you create the same PR for master too? That kind of template would be useful right now, no need to wait for 3.2.


Configuration property not detected by the Documenter

I created a project using modulith tests (v 1.3.0) but the endpoint property hasn't been detected by the modulith Documenter. I cannot find the property and the related javadoc in the .adoc file.
The code and the tests are versioned here: https://github.com/ecostanzi/modulith-tests
The configuration class
@Configuration
@ConstructorBinding
@ConfigurationProperties(prefix = "configb")
public class ConfigB {

    /**
     * The endpoint to call
     */
    String endpoint;

    public String getEndpoint() {
        return endpoint;
    }

    public void setEndpoint(String endpoint) {
        this.endpoint = endpoint;
    }
}

In the generated asciidoc file the configuration class has been detected, but the endpoint property is missing.
[%autowidth.stretch, cols="h,a"]
|===
|Base package
|`com.example.modulithtest.modules.moduleb`
|Spring components
|_Services_

* `c.e.m.m.m.ServiceB`

_Configuration properties_

* `c.e.m.m.m.ConfigB`
|Published events
|* `c.e.m.m.m.EventB` created by:
** `c.e.m.m.m.ServiceB.doSomething()`

|Properties
|none
|===

The documentation generation is based on the spring-boot-configuration-processor artifact, documented in the Spring Boot reference documentation. This one needs to be present in your build to produce the metadata, extract Javadoc information etc.


ci: Speed up arm64 build

Hi.
In this PR, I used cross compilation to reduce the time taken to cross-build the arm64 images.
Basically, all the steps in the builder stage will occur on the build platform (amd64 in our case) while the other stage will be run for the target platform (so emulated in our case).
It permitted to decrease the build time from around 35 minutes to approximately 15 minutes which I think is acceptable so I enable the arm64 cross building for all branches (instead of main and tag previously).
I sadly cannot use a matrix for the platform as it will lead to only one image created on our registry.
Best regards.

Looks very nice. Could you describe the problems with Ubuntu? I'd like to avoid switching building image if possible.

specially because we're introducing a new build dependency: buildx

I also would have liked to avoid using buildx and use conventionnal build, but the BUILTPLATFORM and TARGETARCH variables are only available with buildx.
So, it would have mean having two versions of the Dockerfiles:

one for native build
another for cross-building

which I would have found heavy for no really added value.

You can use docker build --build-arg to pass the platform and the arch, like it was done for native + cross-building local-gadget in a single Dockerfile (see Makefile#L77-L78 and local-gadget.Dockerfile#L27)


Failed to unload

I get "failed to unload", after I've pressed "restart" on the eufy-security-ws under addons.

A clear and concise description of what the bug is.
Just restart eufy-security-ws under addons.
This is my logfile:
2024-09-14 21:21:03.573 ERROR (MainThread) [homeassistant.config_entries] Error unloading entry <IP_ADDRESS> for eufy_security
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/config_entries.py", line 819, in async_unload
result = await component.async_unload_entry(hass, self)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/config/custom_components/eufy_security/init.py", line 69, in async_unload_entry
unloaded = await hass.config_entries.async_unload_platforms(entry, PLATFORMS)
^^^^^
NameError: name 'entry' is not defined. Did you mean: 'entity'?
Expected behavior
That I can restart eufy-security-ws without having to restart all of home assistant :) I have 10 lamps from eufy, and unless I restart it once in a while, I lose connection to one or more lamps - so being able to restart it is quite important.
Additional information
Go to Settings -> System -> Repairs -> Click on 3 dots (...) -> System Information and get Version and Installation Type to below fields;
Version 	core-2024.9.1
Installation type 	Home Assistant OS
eufy-security-ws (1.9.0),
Eufy Security Integration Version: 8.0.3 - The issue was not there in the previous version.

Would you share your device with me in case further debugging required? (Yes/No): Its not a device issue I think ...

same problem here :(


Trace SDK: support span limits

Reference
Link

Spec
https://opentelemetry.io/docs/specs/otel/trace/sdk/#span-limits

Java implementation
SpanLimits.java

The purpose is to keep the number of a) Attributes, b) Links, and c) Events under the configured limit.
Aside from dropping the overflowing ones, we should also track how many have been dropped.
1) Design SpanLimits and SpanLimits.Builder
There is a draft implementation which can be helpful.
Tests should include the discipline's HashTest. The example - RetryPolicySuite.
2) Design a generic collection container with fixed bounds
OpenTelemetry Java, for example, keeps track of dropped attributes right into the span's (or event's or link's) state.
The example, and the simplified version:
class SpanLink {
  def attributes: Attributes
  def totalAttributesCount: Int // how many attributes were submitted to be recorded
  def droppedAttribuesCount: Int = totalAttributesCount - attributes.size
}

To keep track of dropped attributes, links, or events, we can use the generic container:
sealed trait Bounded[A, C <: immutable.Iterable[x]] {
  def limit: Int // the max size
  def dropped: Int // how many elements have been dropped
  def elements: C
  def append(a: A): Bounded[A, C]
}

object Bounded {
  def attributes(limit: Int): Bounded[Attribute[_], Attributes]
  def links(limit: Int): Bounded[LinkData, Vector[LinkData]]
  def events(limit: Int): Bounded[EventData, Vector[EventData]]
}

We may bikeshed the name 🙂 e.g: Bounded, Fixed, Limited, etc.
3) Use Bounded container in the SDK implementation:
For example - https://github.com/typelevel/otel4s/pull/325/files#diff-b00a1cedc0fb0cc94255f20aea84be95187a261e07f8ad033de3375f70d43f8cR151-R160.
4) Add the number of dropped elements to the proto encoders
The SpansProtoEncoder. The proto models already have the properties and we need to populate them.
The change would be similar to:
SpanProto.Link(
  traceId = ByteString.copyFrom(data.spanContext.traceId.toArray),
  spanId = ByteString.copyFrom(data.spanContext.spanId.toArray),
  traceState = traceState,
- attributes = ProtoEncoder.encode(data.attributes),
+ attributes = ProtoEncoder.encode(data.attributes.elements),
+ droppedAttributesCount = data.attributes.dropped
)

5) Implement SpanLimitsAutoConfigure
We need this to autoconfigure the SpanLimits using configuration properties.
The example - TelemetryResourceAutoConfigure.
The configuration options - https://opentelemetry.io/docs/specs/otel/configuration/sdk-environment-variables/#span-limits.

Hi. Can I try to implement this or is it already being done by someone?

Hey @bio-aeon, you can work on it. Thanks in advance!


file include.jodit.js exports css without css vars

Why is jodit/es5/jodit.min.css exported rather than the css from any of the other folders (es2015, es2018, es2021, es2021.en)??
The one from es5 is the only one with hardcoded colors, as opposed to css vars.
That makes it much harder and uglier to customize.

I agree with you. This problem has been around for a long time. This is one of the reasons why we don't use jodit-react on our project, as we need customization of theme colors. It would be cool if fixed that

es5

what do you use ?


It will support "Go to Definition" is ?

I hope...

Yes, it must be! :)

Thank you for message.
I'm look forward to it! :)


Metro-ui-css not supported jquery 2.2+

download latest version

yes its working in jquery 2.1.3 but not working in jquery 2.2+.By the way im currently working a project using mvc6 and bower always getting the latest version of jquery..
using jquery-3.1.0

yes its working in jquery 2.1.3 but not working in 2.2+. By the way im working a project using mvc6 and the bower always getting the latest version of jquery..

i found out the cause of the problem..


我无法执行 flutter upgrade -v

Steps to reproduce
执行 flutter upgrade -v
Expected results
[        ]      | The process cannot access the file because it is being used by another process.
[  +65 ms] Error: Unable to update Dart SDK. Retrying...
[   +8 ms] ERROR: Input redirection is not supported, exiting the process immediately.
[  +57 ms] Checking Dart SDK version...
[   +1 ms] Downloading Dart SDK from Flutter engine 5eedfefe38c1a465283e7352a542881497efc681...
[ +366 ms] Rename-Item: C:\Users\miaom\flutter\bin\internal\update_dart_sdk.ps1:81
[        ] Line |
[        ]   81 |          Rename-Item $dartSdkPath "$oldDartSdkPrefix$oldDartSdkSuffix"
[        ]      |          ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
[        ]      | The process cannot access the file because it is being used by another process.
[  +65 ms] Error: Unable to update Dart SDK. Retrying...
[   +9 ms] ERROR: Input redirection is not supported, exiting the process immediately.
[  +60 ms] Checking Dart SDK version...
[   +1 ms] Downloading Dart SDK from Flutter engine 5eedfefe38c1a465283e7352a542881497efc681...
[ +377 ms] Rename-Item: C:\Users\miaom\flutter\bin\internal\update_dart_sdk.ps1:81
[        ] Line |
[        ]   81 |          Rename-Item $dartSdkPath "$oldDartSdkPrefix$oldDartSdkSuffix"
[        ]      |          ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
[        ]      | The process cannot access the file because it is being used by another process.
[  +65 ms] Error: Unable to update Dart SDK. Retrying...
[   +9 ms] ERROR: Input redirection is not supported, exiting the process immediately.
[  +64 ms] Checking Dart SDK version...
[   +1 ms] Downloading Dart SDK from Flutter engine 5eedfefe38c1a465283e7352a542881497efc681...
[ +366 ms] Rename-Item: C:\Users\miaom\flutter\bin\internal\update_dart_sdk.ps1:81
[        ] Line |
[        ]   81 |          Rename-Item $dartSdkPath "$oldDartSdkPrefix$oldDartSdkSuffix"
[        ]      |          ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
[        ]      | The process cannot access the file because it is being used by another process.
Actual results
正常执行 flutter upgrade -v
Code sample
Code sample
[Paste your code here]

Screenshots or Video

Screenshots / Video demonstration
[Upload media here]

Logs
Logs
[Paste your logs here]

Flutter Doctor output
Doctor output
[Paste your output here]

Try killing "dart.exe" in Task Manager.

ty


Allow extracting records from stream

For scenarios involving file uploads where only the file stream is provided such as web uploads.

Is this still relevant? I've been looking for this feature.

Hi Marc
Thank you for your contribution.
Matthias


documentation fix:samplingIncludedTypes

SamplingIncluded doesn't behave the same as samplingExcludedTypes.

@AartBluestoke : Thanks for your contribution! The author(s) have been notified to review your proposed change.

@brettsam can you confirm these suggestions?

Thanks @AartBluestoke for providing a fix here. I've cherry-picked your commit into a PR in our private repo to fix the conflict and to be included with some other changes to this article.  You'll get credit for your commit, and should see the updates live by this afternoon. Thanks again! #please-close


Integration tests on 22 04

Testing fix for https://github.com/charmed-kubernetes/actions-operator/issues/39#issuecomment-1243717042

Also hold this PR until the jenkins charm is fixed

This pull request https://github.com/canonical/jenkins-agent-k8s-operator/pull/14 moved integration test to using operator-workflows. The pull request runs the integration test in 22.04, so this pull request is no longer needed.
Brief description on how to determine the version of Ubuntu in integration test with operator-workflows.
The integration test is ran with:
https://github.com/canonical/operator-workflows/blob/main/.github/workflows/integration_test.yaml
Which uses this to determine the image to run the integration test with:
https://github.com/canonical/operator-workflows/blob/main/.github/workflows/get_runner_image.yaml
Which checks the build image in charmcraft.yaml. For that pull request is was already set to 22.04 Ubuntu.


HLS playback firing only a fraction of the documented events

Browser: Google Chrome Version 72.0.3626.109 (Official Build) (64-bit)
OS: macOS 10.14.3
Clappr Version: 0.3.3
Steps to reproduce:

configure a Clappr instance to play an HLS stream
loop through all events declared in Clappr.Events and register a listener for each
Interact with the player and observe that only a handful of PLAYER_* events are firing. Nothing fires for playback intent or buffering, nothing fires when the media controls are shown or hidden, etcetera, etcetera.

Here is a test case:
https://codepen.io/kad3nce/pen/MxWpbN
The code:
const player = new Clappr.Player({
  parentId: "#player",
  source: "https://storage.googleapis.com/qualcomm-san-jose/video/best-bus-stop-ever.m3u8"
})

Object.keys(Clappr.Events).forEach(evt => {
  let label = Clappr.Events[evt]
  if (typeof label !== 'string') return
  // Skip the timeupdate event because that creates a lot of noise
  if (label === 'timeupdate') return
  console.log('~> Registering listener for event', label)
  player.on(label, () => console.log(evt))
})

And the output in the console:
~> Registering listener for event ready
~> Registering listener for event resize
~> Registering listener for event fullscreen
~> Registering listener for event play
~> Registering listener for event pause
~> Registering listener for event stop
~> Registering listener for event ended
~> Registering listener for event seek
~> Registering listener for event playererror
~> Registering listener for event error
~> Registering listener for event volumeupdate
~> Registering listener for event subtitleavailable
~> Registering listener for event playback:progress
~> Registering listener for event playback:timeupdate
~> Registering listener for event playback:ready
~> Registering listener for event playback:buffering
~> Registering listener for event playback:bufferfull
~> Registering listener for event playback:settingsupdate
~> Registering listener for event playback:loadedmetadata
~> Registering listener for event playback:highdefinitionupdate
~> Registering listener for event playback:bitrate
~> Registering listener for event playback:levels:available
~> Registering listener for event playback:levels:switch:start
~> Registering listener for event playback:levels:switch:end
~> Registering listener for event playback:playbackstate
~> Registering listener for event playback:dvr
~> Registering listener for event playback:mediacontrol:disable
~> Registering listener for event playback:mediacontrol:enable
~> Registering listener for event playback:ended
~> Registering listener for event playback:play:intent
~> Registering listener for event playback:play
~> Registering listener for event playback:pause
~> Registering listener for event playback:seek
~> Registering listener for event playback:seeked
~> Registering listener for event playback:stop
~> Registering listener for event playback:error
~> Registering listener for event playback:stats:add
~> Registering listener for event playback:fragment:loaded
~> Registering listener for event playback:level:switch
~> Registering listener for event playback:subtitle:available
~> Registering listener for event playback:subtitle:changed
~> Registering listener for event core:containers:created
~> Registering listener for event core:active:container:changed
~> Registering listener for event core:options:change
~> Registering listener for event core:ready
~> Registering listener for event core:fullscreen
~> Registering listener for event core:resize
~> Registering listener for event core:screen:orientation:changed
~> Registering listener for event core:mousemove
~> Registering listener for event core:mouseleave
~> Registering listener for event container:playbackstate
~> Registering listener for event container:dvr
~> Registering listener for event container:bitrate
~> Registering listener for event container:stats:report
~> Registering listener for event container:destroyed
~> Registering listener for event container:ready
~> Registering listener for event container:error
~> Registering listener for event container:loadedmetadata
~> Registering listener for event container:subtitle:available
~> Registering listener for event container:subtitle:changed
~> Registering listener for event container:timeupdate
~> Registering listener for event container:progress
~> Registering listener for event container:play
~> Registering listener for event container:stop
~> Registering listener for event container:pause
~> Registering listener for event container:ended
~> Registering listener for event container:click
~> Registering listener for event container:dblclick
~> Registering listener for event container:contextmenu
~> Registering listener for event container:mouseenter
~> Registering listener for event container:mouseleave
~> Registering listener for event container:seek
~> Registering listener for event container:seeked
~> Registering listener for event container:volume
~> Registering listener for event container:fullscreen
~> Registering listener for event container:state:buffering
~> Registering listener for event container:state:bufferfull
~> Registering listener for event container:settingsupdate
~> Registering listener for event container:highdefinitionupdate
~> Registering listener for event container:mediacontrol:show
~> Registering listener for event container:mediacontrol:hide
~> Registering listener for event container:mediacontrol:disable
~> Registering listener for event container:mediacontrol:enable
~> Registering listener for event container:stats:add
~> Registering listener for event container:options:change
~> Registering listener for event mediacontrol:rendered
~> Registering listener for event mediacontrol:fullscreen
~> Registering listener for event mediacontrol:show
~> Registering listener for event mediacontrol:hide
~> Registering listener for event mediacontrol:mousemove:seekbar
~> Registering listener for event mediacontrol:mouseleave:seekbar
~> Registering listener for event mediacontrol:playing
~> Registering listener for event mediacontrol:notplaying
~> Registering listener for event mediacontrol:containerchanged
~> Registering listener for event mediacontrol:options:change
PLAYER_PLAY
PLAYER_PAUSE
PLAYER_PLAY
PLAYER_VOLUMEUPDATE
PLAYER_VOLUMEUPDATE
PLAYER_FULLSCREEN
PLAYER_RESIZE
PLAYER_FULLSCREEN
PLAYER_RESIZE
PLAYER_SEEK
PLAYER_PLAY
PLAYER_SEEK
PLAYER_PLAY
PLAYER_PAUSE

Hi, @kad3nce.
It happens because of the scope of the events.
You are adding the bind only to the player. This way, only the events triggered by the player will be shown.
The events that the player propagates from the others layers are mapped on the player.js:
https://github.com/clappr/clappr/blob/b5d9e24d2d3551b801f123cdea70c98cf790bd2c/src/components/player.js#L343-L391
If you want to listen for specific events you need to add the bind for the specific scope. For example, the BUFFERING event is triggered by the container, so you need to add a bind for that like player.core.activeContainer.on(label, () => console.log('container: ', evt))

Ahhh. It's all clear now. Thank you!


Support partial matching for loadcheckpoints + allow cp clearing

Support /loadcheckpoints <partial runname> so full run name doesn't need to be typed out
Allow clearing loaded checkpoints more easily by specifying rank -1
Checkpoint loading will now fail if requested run has no checkpoint times

Now handles color codes and case sensitivity too.


Deprecation warning logged to console

OpenSeadragon 3.1.0 logs a warning to the browser console on initialization:
Viewer.buttons is deprecated; Please use Viewer.buttonGroup
This happens without any custom code and can even be seen on the offical website. It is not just irritating, but can mess up automatic testing of apps that include OpenSeadragon.

I've been wondering about why this happens too so I decided to dig into it. I haven't tested this yet but here's my guess as to what's going on:
It appears that it's triggered by the $.extend() method which was taken from jQuery long ago. While extending an object, the value is accessed:
//openseadragon.js lines 1104-1105
src = target[ name ];
copy = options[ name ];

And, similarly, it is copied by value a few lines lower in the function.
So, the getter is called just by involving the class in extending a prototype/object, which is not ideal when using a getter that has side effects - and can cause outright bugs because setting the value returned by the getter is copied, not the getter itself. This is a known issue in jQuery's implementation that they decided not to deal with as beyond the scope of what they were trying to accomplish: https://bugs.jquery.com/ticket/6145
It would probably be better to use something like the following, in order to support extending objects with getters/setters:
    src = Object.getOwnPropertyDescriptor(target, name);
    copy = Object.getOwnPropertyDescriptor(options, name);
    //...
    Object.defineProperty(target, name, copy);

Wow, good catch, and great analysis!
Would either of you be interested in working up a fix for this?

I'm not sure I fully understand, but it's seems just changing copy = options[ name ]; to copy = Object.getOwnPropertyDescriptor(options, name).value; removes the warning for me.
Anything else, gives the "too much recursion" error, or various errors and warnings.
I've made a pull request if no one's against this change. #2201

Fixed by #2201.


cangjie input with fcitx5

I'm trying to get access to cangjie with no luck, none of these options seem to have any effect:
    inputMethod = {
      enabled = "fcitx5";
      fcitx.engines = with pkgs.fcitx-engines; [ fcitx5-table-extra chinese-addons table-extra ];
      fcitx5.addons = with pkgs; [ fcitx5-table-extra fcitx5-rime fcitx5-table-extra ];
    };

I would expect to find the extra input methods in the fcitx5 settings.

fctix5.addons = with pkgs; [ fcitx5-chinese-addons ];
does it.
I'm not sure why nix doesn't complain about nonsense settings here.


Update run-node.py

Purpose of the Changes
addresses several issues and improvements:

Dynamic Version Control: Implementing version control with variables at the top of the script for easy updates and maintenance. Each network (local, devnet, testnet, and mainnet) now has specified versions, with 'mainnet' support newly added.

Database Backend Selection: In response to recent updates which included additional database backend options, the script now prompts the user to choose their preferred database backend. This ensures compatibility and customization according to user needs.

Dependency Management: Checks for and installs missing Python packages automatically or alerts to install [requests].

Enhanced Error Handling and Console Logs: Added error handling just based on issues I ran into during this rework, added a few console messages during setup confirming selections.

Impact of Changes
Makes the script functional again and is easy to maintain throughout version changes.
Testing
Tested on my local machine, arctic-1, sei-db. Notifies if missing 'requests' package, prints network and version number upon selecting, node syncs without app hash.

Codecov Report
All modified and coverable lines are covered by tests :white_check_mark:

Project coverage is 61.73%. Comparing base (954bd21) to head (d9acef3).
Report is 6 commits behind head on main.

Additional details and impacted files

@@            Coverage Diff             @@
##             main    #1617      +/-   ##
==========================================
+ Coverage   61.46%   61.73%   +0.26%
==========================================
  Files         365      365
  Lines       26107    26169      +62
==========================================
+ Hits        16047    16155     +108
+ Misses       8994     8944      -50
- Partials     1066     1070       +4

see 5 files with indirect coverage changes


Switch jira ticket method from respond to hear.

The description states the bot should respond to ticket id mentions but at the minute the bot has to be addressed directly for this to happen. This changes the functionality to bring it in line with the doc block.

Closing since there isn't really consensus, and this would be better as an external script.


[BUG] Alias is not supported in mysql query.

Description
The mysql alias doesn't show up. This is an issue when joining tables having columns with the same name.
https://www.mysqltutorial.org/mysql-alias/
Steps to reproduce the behaviour:

Go to mysql query
Type the following query select id asidname from guests;
The alias doesn't show up

Good items to include here include:

Console / network logs from your browser

What you expected to happen
The alias should show up as the name of the column.
Screenshots
If applicable, add screenshots to help explain your problem.

Important Details
How are you running appsmith?
SaaS (appsmith.com)
Which browser / OS are you using?

OS: MacOSX
Browser chrome

Thank you for reporting this @sagargulabani . We'll look into this and revert with a fix..

@sagargulabani We've merged the fix for this issue in. It should now be working as expected! 😄
Do let us know if you face any further problems

I think this has not yet been merged with app.appsmith.com

@sharat87 can you check? It looks like the pr has been merged but @sagargulabani is still facing an issue

Hi @sagargulabani, this issue should now be resolved. Sorry for the back-and-forth on this. Let us know if you face any further problems with this. Thanks!


[SPARK-17770] [CATALYST] making ObjectType public

What changes were proposed in this pull request?
In order to facilitate the writing of additional Encoders, I proposed opening up the ObjectType SQL DataType. This DataType is used extensively in the JavaBean Encoder, but would also be useful in writing other custom encoders.
As mentioned by @marmbrus, it is understood that the Expressions API is subject to potential change.
How was this patch tested?
The change only affects the visibility of the ObjectType class, and the existing SQL test suite still runs without error.

Can one of the admins verify this patch?

ok to test

Test build #66840 has started for PR 15453 at commit 173dced.

Test build #66840 has finished for PR 15453 at commit 173dced.

This patch passes all tests.
This patch merges cleanly.
This patch adds the following public classes (experimental):
case class ObjectType(cls: Class[_]) extends DataType

Merged build finished. Test PASSed.

Test PASSed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/66840/
Test PASSed.

Test build #66926 has started for PR 15453 at commit 520e207.

Test build #66926 has finished for PR 15453 at commit 520e207.

This patch fails Scala style tests.
This patch merges cleanly.
This patch adds the following public classes (experimental):
case class ObjectType(cls: Class[_]) extends DataType

Merged build finished. Test FAILed.

Test FAILed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/66926/
Test FAILed.

Test build #66929 has started for PR 15453 at commit 232c01e.

Test build #66929 has finished for PR 15453 at commit 232c01e.

This patch fails Scala style tests.
This patch merges cleanly.
This patch adds the following public classes (experimental):
case class ObjectType(cls: Class[_]) extends DataType

Merged build finished. Test FAILed.

Test FAILed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/66929/
Test FAILed.

Test build #66930 has started for PR 15453 at commit e064667.

Test build #66930 has finished for PR 15453 at commit e064667.

This patch passes all tests.
This patch merges cleanly.
This patch adds the following public classes (experimental):
case class ObjectType(cls: Class[_]) extends DataType

Merged build finished. Test PASSed.

Test PASSed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/66930/
Test PASSed.

Thanks, merging to master!


Fix for workflow search SQL

Added a changeset to change empty workflowname to null in 1.4.0
Changed Manual register to always create null workflow name if name is empty
Made a constraint for workflowname to check for empty string
Expanded all workflow manual register, refresh, and refresh all to check that the workflow name is not empty string even when trying to register with empty string.

Coverage decreased (-0.005%) to 71.104% when pulling af69cf716831833f4acae69c7e43737a82d49bf9 on feature/workflowSQLsearchFix into 9281d5221168eeb2d8d108615b279eb50affa061 on develop.

Looking better, let's get some positive and negative tests on this.

Coverage increased (+0.03%) to 71.14% when pulling afd7432dfe1202d5caac49336dca1cb724e1f58e on feature/workflowSQLsearchFix into 9281d5221168eeb2d8d108615b279eb50affa061 on develop.

Coverage increased (+0.03%) to 70.925% when pulling 9be086591eb14f6e3804c7d88bb58271f5be5ea1 on feature/workflowSQLsearchFix into 52285b9c9bad93bf94d950417a5a74d7343a8caa on develop.

Needs re-review


Parsing app package name, version etc.

Hi,
Thanks for your contribution to the community. I can't find any documentation for this script. Is there any way to retrieve package name and all other general info? If yes, then please update some examples.

from apkutils.apk import APK

apk = APK('test.apk')
mf = apk.get_manifest()
pkg_name = mf['@package']

The mf is a dict.
Later I will write some examples, thanks your feedback.


S2E cannot be compiled successfully

The Makefile and multiple necessary files are missing in the S2E source folder.

Many thanks for the prompt reply. I have another question: Does the repo include complete the modification of php-src and s2e ?


No object detected in test_image

No object is getting detected in the test_image
i tried to pass two images for testing, but there is an empty array in the console

Please comment if you are able to solve this. Facing the same issue.

This is because your network is not working good enough. On line 146 you can find the
bbox_threshold = 0.8
Which is set to 0.8. This means that your netwerk will only show the bounding boxes of which it is at least 80% sure that it is in a class. Big chance that if you set this really low that you will see a lot of boxes

I'm using biological data as well and it is very hard indeed. I found out that the RPN_model is doing a great job finding the regions of intrest. But after that the classifier doesn't work at all.
I think this is because the pretrained network that I'm loading in is not trained on biological data.  And I think that this is not a big problem for the RPN model since that one is just looking for general regions. Since the pretrained network did the same it is already good in it. But the classifier is not pretrained on my network at all so it has a difficult time adjusting.
Anyway what I did and it seems to work is: I first just trained the full network on 2000 images for 30 epoches. After I took a look at the RPN and it was doing a great job. So then I stopped training the RPN and just trained the classifier for another 10 epoches. This seems to work but I'll have to look deeper into how good it works.

If you want to check if  your RPN_model is working you can add following code in the frcnn_test_vgg code just behind this line:
R = rpn_to_roi(Y1, Y2, C, K.common.image_dim_ordering(), overlap_thresh=0.7,max_boxes = max_boxes)
So just behind that line you can add the following code and it will show you the 20 best boxes of the rpn model:
    tel=0
    for co in R:
        if tel<20:
            (real_x1, real_y1, real_x2, real_y2) = get_real_coordinates(0.0625*ratio, co[0], co[1], co[2], co[3])
            kleur_1=0
            kleur_2=0
            kleur_3=60
            kleur_1 = 254-tel
            kleur_2 = tel
            if kleur_1<0:
                kleur_1 = 0
                kleur_2 = 254
                kleur_3 = tel-200

            cv2.rectangle(img,(real_x1, real_y1), (real_x2, real_y2), (kleur_3, kleur_1, kleur_2),6)
        tel+=1

Extra: The 0.0625 is there for some reason but I'm not 100% sure. I think it's because the model divide the image by 16 but anyway it should be there. If your boxes are super small or huge then you can change that number

To be honest I have no idea.
Here this guy talks about how the epoch length works but I don't fully understand what he means. Maybe you can take a fresh look at it and let me know what you think.
I'm struggling with the following question on epoch length:
Do you decide the batch size first and calculate the epoch lenght based on the batch size or is it the other way around and does the batch size changes when you change the epoch length
https://github.com/kbardool/keras-frcnn/issues/25#issuecomment-572170152
I took 500 and I have 1400 pictures. It takes me 12 minutes per epoch. I did turn all the data augmentation off (turning, mirroring images) because I already did that in my preprocessing step. This made the training significantly faster.

This could be the case indeed. In that link they do say that in one epoch you go through the full data set no matter the epoch length. But this seems weird to me because when I set the epoch length to 1000 it takes double the time to train the model.
So I think you are right. Also because of this line of code. Here it is clear that the model will stop after epoch_length pictures.

What I don't understand is how we can see the batch size. I assume it is one since you only take one image at a time.  But would there be a possibility to change that. Since this could limit the training time which would be nice because my full data set has 16.000 images.
I also found somewhere else that the batch size could be the number of regions of intrest that we send to the classifier at once. Which is 4 normally (in this code). But to me it looks like this is the batch size of the classifier but not of the rpn which will take in the images.
Sorry it got kinda long I just putted my thoughts on here.
I do think your right with the epoch length but then the question is how can we change the batch size to make the training go faster.

What looks weird to me is this.
This happend after training for 160 epoches with an epoch_length of 500. So you would assume that there are 80k batches but this is not the case.
Here my data set is 1500 images so if the program took all of them you would exspect 240k batches which is not the case neither. It just doesn't make sense to me but maybe you can do something with the information.

No object is getting detected in the test_image
i tried to pass two images for testing, but there is an empty array in the console

Hi. I am facing the same issue. Please help me out if you have solved it. I have total 98 images of sugar sacks and ran on 50 epochs.
Would be grateful.

I'm using biological data as well and it is very hard indeed. I found out that the RPN_model is doing a great job finding the regions of intrest. But after that the classifier doesn't work at all.
I think this is because the pretrained network that I'm loading in is not trained on biological data. And I think that this is not a big problem for the RPN model since that one is just looking for general regions. Since the pretrained network did the same it is already good in it. But the classifier is not pretrained on my network at all so it has a difficult time adjusting.
Anyway what I did and it seems to work is: I first just trained the full network on 2000 images for 30 epoches. After I took a look at the RPN and it was doing a great job. So then I stopped training the RPN and just trained the classifier for another 10 epoches. This seems to work but I'll have to look deeper into how good it works.

Can you please help… on how to train only classifier model

@Arthur023  where to find detection result?.. i dont find any detection results after testing.


Stuck at install desktop environment

I've done many manual Arch installs before. Using the script to automate an install in a VM. I kind of guessed from manual install experience what was needed for "custom locale string". I note that the prompt for the change locale option says, "Do you wish to install a Desktop environment?". After that there was an error regarding keyboard layout and now I can't seem to proceed as answering the desktop environment question just shows it again.
-[Change locale]---------------------
1: English - United States
2: English - UK
3: English - Canada
4: French  - Canada
5: French  - France
C: Custom
E: exit
Do you wish to install a Desktop environment? [1-5,c,e] : c
Enter the custom locale string : en_AU.UTF-8
------------------------------------------------
-[Change keyboard layout]---------------------
1: United States
2: UK
3: Français - Canada
4: Français - France
Cc: Custom
e: exit
Valid keyboard layouts:
Failed to open keyboard mapping list.

OK, I fixed the prompt and added extra validation for review, thanks for the issue reporting.


Add Nomander2's file

So far i have created a branch, a file, made a commit and opened a pull request.
I am going to learn more

So far i have created a branch, a file, made a commit and opened a pull request

i was able to create a branch, a file and made a pull request


postcss-calc parse error?

Current Behavior:
I am seeing this warning in Next.js production builds. Should we be concerned?
 ⚠ Compiled with warnings

<EMAIL_ADDRESS>Warning

(414:3) postcss-calc: Parse error on line 4:
...c(calc(var(--overlay-height) * var(--region-viewport-anchor-y)) / 100) -
------------------------------------------------------------------------^
Expecting end of input, "ADD", "SUB", "MUL", "DIV", got unexpected "RPAREN"

Import trace for requested module:
<EMAIL_ADDRESS>
Expected Behavior:
No such warning / error.
Steps To Reproduce:

Environment:

Framework: React
Meta Framework: Next.js
Node: 18.17.1

This has been removed in the latest @next release. It seems you're on 0.6.x which is deprecated. Upgrading will resolve the issue :)


Flutter TextField Long Press Gray Screen

Hello In Flutter only when I long press any TextField on real devices the screen turns completely gray.
My TextField
                          Container(
                                child: TextFormField(
                                  inputFormatters: [maskFormatter],
                                  controller: phoneController,
                                  style: TextStyle(color: Colors.white),
                                  cursorColor: Colors.white,
                                  keyboardType: TextInputType.phone,
                                  decoration: new InputDecoration(
                                      focusedBorder: OutlineInputBorder(
                                        borderRadius: const BorderRadius.all(
                                          const Radius.circular(25.0),
                                        ),
                                        borderSide: BorderSide(
                                            color: Color(0xffD50231),
                                            width: 2.0),
                                      ),
                                      border: new OutlineInputBorder(
                                        borderRadius: const BorderRadius.all(
                                          const Radius.circular(25.0),
                                        ),
                                      ),
                                      filled: true,
                                      hintStyle: new TextStyle(
                                        color: Colors.grey,
                                      ),
                                      hintText: AppLocalizations.of(context)
                                          .translate('type_in_your_phone'),
                                      fillColor: Color(0xff101114)),
                                  validator: (value) {
                                    print(value);
                                    if (value.isEmpty) {
                                      return AppLocalizations.of(context)
                                          .translate('cannot_be_left_blank');
                                    } else if (value.length != 14) {
                                      return AppLocalizations.of(context)
                                          .translate('invalid_phone_number');
                                    }
                                    return null;
                                  },
                                ),
                              ),

Document :

Hello @ufukhawk ,
Could you please post the outputs of flutter run -v and flutter doctor -v and a complete minimal reproducible code sample?
Thank you!

flutter doctor -v
 ufukbermuda$ flutter doctor -v
[✓] Flutter (Channel stable, 1.22.4, on macOS 11.0.1 20B29 darwin-x64, locale en-TR)
    • Flutter version 1.22.4 at /Users/ufukbermuda/Developer/flutter
    • Framework revision 1aafb3a8b9 (6 days ago), 2020-11-13 09:59:28 -0800
    • Engine revision 2c956a31c0
    • Dart version 2.10.4

[✓] Android toolchain - develop for Android devices (Android SDK version 30.0.2)
    • Android SDK at /Users/ufukbermuda/Library/Android/sdk
    • Platform android-30, build-tools 30.0.2
    • Java binary at: /Applications/Android Studio.app/Contents/jre/jdk/Contents/Home/bin/java
    • Java version OpenJDK Runtime Environment (build 1.8.0_242-release-1644-b3-6915495)
    • All Android licenses accepted.

[✓] Xcode - develop for iOS and macOS (Xcode 12.2)
    • Xcode at /Applications/Xcode.app/Contents/Developer
    • Xcode 12.2, Build version 12B45b
    • CocoaPods version 1.10.0

[✓] Android Studio (version 4.1)
    • Android Studio at /Applications/Android Studio.app/Contents
    • Flutter plugin installed
    • Dart plugin version 201.9245
    • Java version OpenJDK Runtime Environment (build 1.8.0_242-release-1644-b3-6915495)

[✓] Connected device (1 available)
    • iPhone 8 (mobile) • 66A8A1FD-E366-4DFC-A687-B1A18888DD16 • ios • com.apple.CoreSimulator.SimRuntime.iOS-14-2 (simulator)

• No issues found!

Hi @ufukhawk
ì need you to provide a complete minimal reproducible code sample that ones can just copy/paste to reproduce the issue.
Thanks

O solved, Thanks.
added GlobalCupertinoLocalizations.delegate in localizationsDelegates.

I solved, Thanks.
added GlobalCupertinoLocalizations.delegate in localizationsDelegates.

Can you explain how you fixed it please ? I have the same problème on my App.
I don't know where I need to modify why ...

I solved, Thanks.
added GlobalCupertinoLocalizations.delegate in localizationsDelegates.

Can you explain how you fixed it please ? I have the same problème on my App.
I don't know where I need to modify why ...

To Solve add "GlobalCupertinoLocalizations.delegate" to your list of delegates in the MaterialApp widget.
localizationsDelegates: [
              AppLocalizations.delegate,
              GlobalMaterialLocalizations.delegate,
              GlobalWidgetsLocalizations.delegate,
              GlobalCupertinoLocalizations.delegate  // <---- add this
            ],

The bug in my case was happening only when on a language other than the english language.

I have the same problem.
By adding GlobalCupertinoLocalizations.delegate  was able to fix this for English.
But when the locale is Japanese I am still getting this issue.
I have following in my main.dart file
locale: lang.appLocal,
          supportedLocales: [
            const Locale('ja', ''),
            const Locale('en', 'US'),
          ],
          localizationsDelegates: [
            AppLocalizations.delegate,
            GlobalMaterialLocalizations.delegate,
            GlobalWidgetsLocalizations.delegate,
            GlobalCupertinoLocalizations.delegate
          ],

Is there a work around for this?


Platform.localeName always returns en_US on Android

getenv("LANG") returns NULL. This causes standalone/io/locale_name_test.dart to fail.

We should add a callback to _Platform that the embedder can set to use instead of trying to fish the locale out of an environment variable.

I'm facing up with this issue on flutter 3.10.x
flutter doctor -v
[✓] Flutter (Channel stable, 3.10.5, on macOS 13.3.1 22E772610a darwin-arm64,
    locale en-RU)
    • Flutter version 3.10.5 on channel stable at /Users/nikotron/sdk/flutter
    • Upstream repository https://github.com/flutter/flutter.git
    • Framework revision 796c8ef792 (13 days ago), 2023-06-13 15:51:02 -0700
    • Engine revision 45f6e00911
    • Dart version 3.0.5
    • DevTools version 2.23.1

[✓] Android toolchain - develop for Android devices (Android SDK version 33.0.1)
    • Android SDK at /Users/nikotron/sdk/android-sdk
    • Platform android-33, build-tools 33.0.1
    • ANDROID_HOME = /Users/nikotron/sdk/android-sdk
    • Java binary at: /Applications/Android
      Studio.app/Contents/jbr/Contents/Home/bin/java
    • Java version OpenJDK Runtime Environment (build
      11.0.15+0-b2043.56-8887301)
    • All Android licenses accepted.

[✓] Xcode - develop for iOS and macOS (Xcode 14.3)
    • Xcode at /Applications/Xcode.app/Contents/Developer
    • Build 14E222b
    • CocoaPods version 1.12.1

[✓] Chrome - develop for the web
    • Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome

[✓] Android Studio (version 2022.1)
    • Android Studio at /Applications/Android Studio.app/Contents
    • Flutter plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/9212-flutter
    • Dart plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/6351-dart
    • Java version OpenJDK Runtime Environment (build
      11.0.15+0-b2043.56-8887301)

[✓] VS Code (version 1.80.0-insider)
    • VS Code at /Applications/Visual Studio Code - Insiders.app/Contents
    • Flutter extension version 3.66.0

[✓] Connected device (3 available)
    • Android SDK built for arm64 (mobile) • emulator-5554 • android-arm64  •
      Android 10 (API 29) (emulator)
    • macOS (desktop)                      • macos         • darwin-arm64   •
      macOS 13.3.1 22E772610a darwin-arm64
    • Chrome (web)                         • chrome        • web-javascript •
      Google Chrome 114.0.5735.133

[✓] Network resources
    • All expected network resources are available.

• No issues found!

@NiKoTron This issue has been closed for over five years. Please file a new issue with full details in the flutter/flutter issue tracker.


Fixes publish yaml.

:tada: This PR is included in version 2.1.0 :tada:
The release is available on:

npm package (@latest dist-tag)
GitHub release

Your semantic-release bot :package::rocket:


sync api

Nice library! It would be possible to have a sync API ?
I'm trying to use it with linux_embedded_hal

Hello and welcome! Are you familiar with APIs for sharing implementations between sync and async? I'd like to reuse tests and impls where possible to avoid duplication.

Taking a deeper look at the problem here, which boils down to me wanting to reuse the async implementation in any sync APIs, makes me realize there's no good way to do this currently. There's an initiative to make this possible, but I suspect it's not coming to stable Rust soon.
One alternative is to have callers use something like async_std::task::block_on. Have you tried something like this with linux-embedded-hal?
There's also the possibility to add async support into linux-embedded-hal for this crate's needed APIs. There's precedence there with the async DelayNs being supported in rust-embedded/linux-embedded-hal#109, though this only targets the tokio runtime. Is there a chance you'd be able to use an async runtime on Linux in your project?
In the meantime, I'll take a closer look at your PR.


How to handle Lunar holidays

Holidays like Eid al Fitr and Chinese New Year are lunar holidays, which change every year and no explicit pattern to calculate them out. So I wonder if we can explicitly list out the holiday date for the past and upcoming 10 years, but not sure how to write the rules.

Hi @pcgreat,
Is there an authority providing the data? If so, we can follow what we did for timezones.
Otherwise, a simple HashMap can store the information.

I don't know if there is any authority providing the data. I just get them from https://en.wikipedia.org/wiki/Eid_al-Fitr and https://en.wikipedia.org/wiki/Chinese_New_Year

Ok so the HashMap solution seems the way to go.


[Lite] [Android] Conditional disable builtin extensions

Disable/Enable is controlled by the GYP flag disable_builtin_extensions.
This flag is 1 for the Lite branch.
BUG=XWALK-3436

"builtin", not "buildin"

[Lite][Android] -> [Lite] [Android]. And please change buildin to builtin in all places as @zliang7 suggested.

@halton , modification done, please help to give a review. thanks.

LGTM, merging. Please monitor the [buildbot] (https://build.crosswalk-project.org/waterfall) status because we do not have trybot to check.


Add access parameter

The idea behind adding the "access" parameter is to generate documentation by only displaying objects that match the parameter settings. The parameter can have the values public, protected, undefined or private and multiple access parameters may be specified.
E.g. --access public --access protected will exclude undefined and private objects from the documentation.
To facilitate this a split between 'access undefined' and 'access public' is being introduced, which allows detection later on in the process. Tests have been expanded to include new test cases.
(This is a revised version of pull request jsdoc3/jsdoc#816)

You're welcome!
Closing this pull request in favor of the squashed version: pull request #860


ARROW-1410: Remove MAP_POPULATE flag when mmapping files in Plasma store.

cc @pcmoritz @atumanov

The reasoning for removing this is the following one: MAP_POPULATE will pre-populate the page entries when the mmap is executed. While this speeds up accessing the file from the client, it also induces a large latency penalty when a new memory mapped file is created. This latency can be on the order of several 10s of seconds for very large memory mapped files and we would like to avoid this behavior which can make the object store performance unpredictable.

the difference in performance behavior with and without MAP_POPULATE is the following: with MAP_POPULATE perf degradation occurs (and is tangible) only when we run out of space to place a new object and, thus, need to mmap a new file. Without MAP_POPULATE, we distribute degraded performance (due to page faulting on the server side) uniformly across most object puts. As stated, the advantage of the latter is throughput predictability.
It is important to note that, in steady state, when the object store has been fully warmed up, presence/absence of MAP_POPULATE doesn't matter. It only matters during the object store ramp up.
My favorite longer-term solution continues to be preallocating the configured capacity on object store startup as a single mmapped file and pre-faulting it in the background.

+1, the build failure in AppVeyor is unrelated