Add Guideline for Exported Cmdlet Naming Conventions

To ensure that DSC Resource kit modules exported functions don't conflict with each other, we should add a naming policy around exported functions. See: https://github.com/PowerShell/DscResources/issues/273#issuecomment-305637218

The guideline, should it say something like this?
"Since we don't use the RootModule key in the module manifest, we should not use NestedModules key to add modules that export functions that are shared between resource modules.
Normally a single module listed in RootModule key can restrict what is exported using Export-ModuleMember. Since we don't use the RootModule key we can't restrict what is exported, so every nested module will export all the commands (or all the commands restricted by Export-ModuleMember in that individual nested module). If two resource modules would use this method that would result in one of them unable to install since they have conflicting exported commands. "

@PlagueHO I added PR #393.


SkipToContent property href does not work with HashRouter

@nxn-4-wdf commented on Fri Aug 09 2019
Environment

Operating system

Any.

Browser

Any.
Detailed description

What version of the Carbon Design System are you using?
10.4

As instructed in the Carbon tutorial, app uses a UI-Shell with header navigation and react-router-dom Link components, which lead to different pages sorted by a HashRouter. In order to enable navigation to internal page anchors, page also uses HashLink components from react-router-hash-link.

What did you expect to happen?

With keyboard navigation, pressing on the Enter-key when on the SkipToContent should remain on the same page and scroll to the HTML element with id="main-content".

What happened instead?

Application tries to navigate to /#/main-content which renders the default Router page, instead of staying on the same page.
Steps to reproduce the issue
Example application on CodeSandBox: https://37eph.csb.app/
From there, using keyboard navigation ("Tab" and "Shift-Tab"):

Select header navigation Page two and press the Enter-key
With Shift-Tab combination, get back to display SkipToContent element. Partial screenshot:

Press the Enter-key: page is changed (NOT expected), and as a side-effect, scroll amount is wrong (page heading is masked by the header bar)

Please create a reduced test case in CodeSandbox

Code is here : https://codesandbox.io/s/skiptocontent-37eph
Additional information

Screenshots or code: see above

@dakahn commented on Mon Sep 30 2019
Hello friend! I think this issue should be filed against the Carbon Tutorial repository.

Moved this from the carbon repository as it seems to pertain to the tutorial.


Auto add retest label after updating licenses

This is a quick experiment checking is this will fix our dependabot automated workflow after the licenses get fixed.
All Submissions:

[ ] Have you signed our CLA?
[ ] Put closes #XXXX in your comment to auto-close the issue that your PR fixes (if there is one).
[ ] Update docs/release-notes/release-notes-template.md if your changes should be included in the release notes for the next release.

Replaced by #1743


Manual Instantiation of Cells : Draft version 1.

A lot of people have been asking for an explicit cell instantiation method.
Currently, Cell automatically figures out what elements to turn into Cells by searching from global variables with a $cell key. This works in most cases, but there are many other cases where it makes sense to manually create cells.
Some of the problems brought up were:
1. Namespace
From https://github.com/intercellular/cell/issues/12#issuecomment-308876874

"The one thing I would still like to find a solution for is the fact that declarative cells must not be lexically scoped -- only var or a global declaration will do, and neither const nor let will work."

Like @Caffeinix pointed out in above comment, Cell won't be able to automatically detect const and let variables since they are not global variables.
2. Integration into legacy frameworks
The power of Cell comes from its pluggable nature. You can use it with any existing framework and any web library with zero hassle because it creates an actual, completely encapsulated HTML node instead of a virtual DOM.
@kingoftheknoll mentioned integrating with angular https://github.com/intercellular/cell/issues/12#issuecomment-310935220 and I think this argument generally applies to all other frameworks/libraries out there.
It would be great to be able to create cells that can be injected into other frameworks. Cell is well positioned for that since it doesn't create any extra data structure like virtual DOM but instead creates native HTML elements that contain everything they will ever need to work when plugged into any context.
3. Doesn't work in dynamically loaded contexts
This is related to #2 above, but nowadays many web apps use dynamic module loading, and web browsers themselves will natively support them in the future via ES6.
To be clear, I think most of these modular approaches on the frontend web context are convoluted and mostly unnecessary (which was the main reason I wrote Cell), but I also see no reason not to support these approaches since allowing manual instantiation has very clear and powerful benefits.
Currently it's not easy to integrate Cell into existing web apps that dynamically load modules. Maybe you're using angular, maybe you're using Backbone.js, or anything else really. This is because the main Cell creation logic creates cells this way:

Wait for window.onload event
Find all global variables that have a $cell attribute
Automatically build cells from these variables

This means, by default there's only one opportunity to create cells--at the very beginning.
Liberating Cell from this specific lifecycle will allow dynamic creation of cells, making Cell truly injectable into all kinds of context.
One possible approach (and why it's not optimal)
A lot of people suggested an option to add something like this:
const $node = Cell({
  $type: "p",
  $text: "I will be created by a global Cell variable"
})

Well the thing is, it would be best if we could avoid the global variable Cell altogether. To understand the rationale behind this, please read https://github.com/intercellular/cell/issues/111
Basically, we already have a decentralized DOM, why not utilize it instead of creating a centralized constructor? This would be in line with the philosophy of the library after all.
Goals
The main goals:

The Creator function does not pollute the global namespace but belongs to each HTML element, including the body.
Any regular HTML node should have the ability to: Evolve into a cell.
Any regular HTML node should have the ability to: Create a new cell without directly adding it to the DOM.

Solution
Here's the solution:

Add a $cell() function to window.Element.prototype.
The $cell() function can be used in two different ways, depending on the existence of the $cell key on the JSON argument.

With this addition, we should be able to achieve the 3 goals mentioned above.
1. Evolving into a cell
Let's say we already have an HTML page, and we want to morph parts of it into Cells.
This is already somehow possible in a 100% declarative manner by using the "id" attribute But that approach assumes you're using Cell as standalone, because it depends on the window.onload event.
Anyway, sometimes you may want to use Cell along inside an existing web app that dynamically loads modules, which means using window.onload event won't work. We want to be able to instantiate these Cells inside each module after they're loaded.
The new Element.prototype.$cell() function allows you to take ANY regular HTML element, pass the blueprint object (gene) as a parameter, and morph into a cell. Here's an example: https://jsfiddle.net/euzrzk8n/1/

Here's another example: https://jsfiddle.net/3v1ttcga/2/
I took an example template from bootstrap website and just converted static components into Cells.
2. Create a new cell without directly adding it to the DOM.
Above method should cover a lot of the use cases where you want to manually create cells.
But since we're at this, let's go deeper.
The previous approach assumes that we already have an HTML node we want to transform. What if we just want to create a cell from scratch, without adding it to the DOM directly?
In this case, you can just get rid of the $cell attribute from the argument when calling the $cell() function, and it will only create the cells in memory.
Here's an example of creating a
 element from  without automatically appending : https://jsfiddle.net/vj5bwjxb/
let gene = {
  $type: "p",
  $text: "I will be created by 'body' but you'll have to manually add me to the DOM"
};
for(let index=0; index<10; index++){
  let cell = document.body.$cell(gene);
  document.body.appendChild(cell);
}

Notice:

There is no $cell attribute on the gene object.
You manually add them to the DOM with document.body.appendChild(cell)

Conclusion
By adding the additional $cell() method on window.Element.prototype we were able to avoid creating a global variable that creates cells.
This is also in line with the core philosophy since it is not some centralized entity that creates cells, but any node can create a cell, which means no compromise was made.
Let me know what you think
Here's the branch for this feature: https://github.com/intercellular/cell/tree/plan
And you can try this version in action by including:

I think these two features powered by a single addition of the $cell() function should address most of the problems brought up so far, while preserving the decentralized nature of Cell.
But I want to make sure I'm not missing anything, and also would love to hear your thoughts. Let me know. Thanks!

Nice turnaround! I think you're taking the right approach here. I was describing Cell.js to a coworker today and I described it as 'an extension to the DOM api' which I think this aligns with. It's why my attention was caught by Cell.js in the first place. There's a Clojurescript framework call Hoplon which takes a similar approach of extending the element's api. There might be some ideas to glean from there about further abstractions which might be useful.
Again, nice work!

lgtm

$cell() method seems to me like a good addition and a novel approach, but it's missing one of the (main?) concerns, at least mine: the magic behing the declarative style of create elements. That's why I think we still needs a Cell() namespace, but not as a creator returning Cell objects, but as an appender to the body element. It's said, as an alternative to the current "main Cell creation logic":

Wait for window.onload event
Find all global variables that have a $cell attribute
Automatically build cells from these variables

Probably the window.onload event is the main concern, since user would need to be conscious about the page structure and events, removing abstraction. That's why I wanted that logic to be hidden inside the Cell() function. This could be as simple as:
// Sort-of Promise on the `DOMContentLoaded` event
let DOMContentLoaded = false
window.addEventListener('DOMContentLoaded', function()
{
  DOMContentLoaded = True
})

function Cell(gene)
{
  const body = document.body

  if(DOMContentLoaded) return body.$cell(gene)

  window.addEventListener('DOMContentLoaded', function()
  {
    body.$cell(gene)
  })
}

that by way, would be done as an independent module (cell-primordialsoup? :-P) and help to remove references to the window.onload event and others from the cell.js module and make it more oriented as a pure DOM nodes expansion. How do you see it?

i definitely agree that DOMContentLoaded should be used over load although i'm still not sure about a global Cell namespace

That's why I said that maybe makes sense the global Cell namespace being hosted on an independent module :-)

I'm thinking... in case of the global namespace, better window.$cell() so people don't confuse it as a class, isn't it?

better make it cElL just to be sure

@piranna  I don't think I quite understand the use case you have in mind for this, could you share a specific example where this is necessary? That would be helpful. Thanks!

@kingoftheknoll thanks! taking a look at hoplon.

Don't need to polute the global context with the genes, and instead of need
to wait to window.onload so cell.js can query the window object for the
genes to add them to the body, be able to add them at any time, before or
after the page DOM has fully loaded.
El 27/06/2017 10:29, "gliechtenstein"<EMAIL_ADDRESS>escribió:
@piranna https://github.com/piranna I don't think I quite understand the
use case you have in mind for this, could you share a specific example
where this is necessary? That would be helpful. Thanks!
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/intercellular/cell/issues/125#issuecomment-311289935,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AAgfviKG2E4UDJtKLRmZmpCVGjGexuyoks5sIL1agaJpZM4OF8QA
.

Assuming that you're purely using Cell and not integrating into other libraries or frameworks (since you mention DOMContentLoaded) I don't think there's any pollution of the global context nor the need to wait for the load event. You just need to place the scripts at the bottom of the HTML.
1. The first approach
Morphs the body itself into a cell https://jsfiddle.net/3spkvjdj/

2. The second approach
Creates a cell and appends it to body https://jsfiddle.net/bnadvaku/

blah blah

halb halb

Note that neither of the two options uses the automatic cell creation (There is no global variable that contains the $cell attribute).
Let me know if you have a specific example where neither of these approaches would work. Thanks!

I know I can set


Fix failing Circle-Ci Swiftlint

Fixes #474
Screenshots for the change:
N/A

@chashmeetsingh do you have any idea why deploy job is not triggering? lint and test is triggering but deploy is not

Maybe there is a limit on the number of jobs that can be run. Not sure though.


No login window when adding OBS Browser

Hi. Trying this module, following the instructions.
In OBS adding a "browser source" no login window appears, only the Foundry background body image. Not working with or without the /join in the URL.

Needs OBS on Windows to fix their browser source for Foundry to work.
https://github.com/sPOiDar/fvtt-module-stream-view/issues/6#issuecomment-908757433


separate keys for log concat and regexp matching

Support separate keys for regexp matching and log concatenation.
For containerd/cri in Kubernetes, logs are written as plaintext and long lines are split on a configurable size.  Partial lines are prefixed with a P and the final line of a multi-line or single line log are prefixed with F:
2018-06-28T18:04:27.18380794Z stdout P long log 1
2018-06-28T18:04:27.183861445Z stdout P long log 2
...
2018-06-28T18:04:27.183892587Z stdout F long log N

In order to avoid including the split line flag in the concatenated message, I propose to support regexp matching against a different record key than the key you want to concatenate.

This is very similar to #42.
I will consider this next week.

Released v2.3.0.


Abstract system-agent-installer image resolution

The dependency graph of rancher's bootstrap and controlplane providers is too tightly coupled with rancher specific implementation details, use dependency injection to invert the dependency of the controlplane controller on rancher's settings API, as well as allow the ability to mock during unit tests.
SURE-6250

Reopening this since there are no automated tests

@sowmyav27 Tests are here: https://github.com/rancher/rancher/pull/41168/files#diff-d3bc1cf510959c64453c9c58e7aed7dc119bfc746d450f580b9a563c7bd1a5c3

Basic rke2/k3s provisioning - linode/AWS node driver and custom clusters work on 2.7-head commit id: 1f014b7 "No other specific checks needed". Closing this issue.


When upgrading to 1.16/stable 2019-09-25 (920) unable to use cluster until change of configs

It looks like the default port the kube-apiserver was changed from 16443 to 6443.  The problem is some autogenerated files in /var/snap/microk8s/current/credentials: controller.config, kubelet.config, proxy.config, and scheduler.config all had the line
    server: https://<IP_ADDRESS>:16443

which needed to be corrected before the cluster would come up all the way (e.g. nginx-ingress worked).
I post this as both to help those that might be upgrading (no thanks to the design flaw of snap for forcing this upgrade) and to let the microk8s team know that this upgrade is not as smooth as I think they would like.

Looking at the source, I think it moved from 6443 to 16443 instead.

Indeed every MicroK8s update that pushes a new upstream release (in this case v1.16) may introduce breaking changes. If you are interested in having a long lasting MicroK8s cluster it is safer to select the channel you want to follow (eg sudo snap install microk8s --classic --channel=1.16/stable). Ephemeral clusters you want to keep for a few hours or days can use the latest stable version by skipping the --channel during installation.

@ktsakalozos Thank you for that info.  That's super helpful.  Would it make sense to put that in the README.md some where?


Route53Provider dynamic record support

[x] Code up a POC/mostly working setup that's uncommitted and messy (just happens to be how I went about this.)
[x] Break up ^ into logical/meaningful commits and make sure bits are tested as committed
[x] Write tests for all the new dynamic bits
[x] Go back through and address remaining TODOs or call them out as 🏈s
[ ] Review
[ ] :shipit:

Just ran through a "complete" test of the fallback before and things work as desired/expected.

The GH review comments around the overall logic were really useful, would be great to copy those in to inline code comments for posterity/future readers.

Moved everything that wasn't specific to the review process & refactoring into actual code comments. @theojulienne this should be ready for final review.


multiple concat transforms in one node

PGSync version: 2.1.8
Postgres version: 11.7
Elasticsearch version: 7.15.0
Redis version: 6.2.6
Python version: 3.9
Feature Request:
The rename transform clearly supports multiple renamings for a given node. I've not succeeded in doing the same with concat transforms. I've tried multiple transform clauses (each with a concat), multiple concat clauses in one transfer clause, pointing "concat" at an array of structs (ala rename), and repeating the concat fields in one concat. In all of these, the last one in the JSON wins, and the others are no-ops. Is this just not supported?  If not, could I suggest following the rename pattern and having concat be an array of structs, each as the current concat is defined?

Thats a good suggestion. I didn't think of it.
This has been implemented in master. Here is an example
It should also be backward compatible. Might need a bit of testing though.

Just tested this out in 2.1.9 - looks great:
				"concat": [ 					{ 						"columns": [ 							"https://clinicaltrials.gov/ct2/show/", 							"nct_id" 						], 						"destination": "url" 					}, 					{ 						"columns": [ 							"clinical trial" 						], 						"destination": "entity" 					} 				]

Note that this is a slick way to inject a constant literal pseudo-column, as well.


Add proper check for redundant fields in the analysis pipeline

Verify if the check for fields with redundancy (horizontal blocks) is still needed and thus it should be added to the analysis pipeline for GridTools backends.
Note: started from discussions with @egparedes and @lukasm91

What is a field with redundancy?


Expired vk8s credentials are not updated in module.volterra

Terraform is not aware that the vk8s credentials have expired, so volterra_api_credential.cred and local_file.kubeconfig are not updated.  Results in the following error:
│ Error: failed to create kubernetes rest client for read of resource: Get "https://tenant.console.ves.volterra.io/api/vk8s/namespaces/demo-app/demo-app-vk8s/api?timeout=32s": remote error: tls: expired certificate │  │   with module.kubectl.kubectl_manifest.documents[6], │   on modules/kubectl/main.tf line 28, in resource "kubectl_manifest" "documents": │   28: resource "kubectl_manifest" "documents" {
Thanks

@s-archer,
Here's a quick hack to get you unstuck if you're ever in a position where the kubeconfig is expired.
terraform state rm module.volterra.volterra_api_credential.vk8s_cred module.volterra.local_file.kubeconfig && \
terraform apply -var-file="some.tfvars"

The idea is remove the cred and the kubeconfig file from state and then apply again. This should recreate the cred and localfile, and then apply any other (manifest) changes.
I'm going to suggest that expiry be returned as a property of the cred and then maybe we could do something about it in the TF run (or use the 'kubernetes' providers exec capabilities?). In the meantime I've extended the cred expiry to 89 days to make sure we've all forgotten about this when it comes up again in ~3 months.


merge package template from arlac77/npm-package-template

Updated standard to latest version

Coverage remained the same at 93.567% when pulling 0970db9ee99781a9efa62fed2eed8f1a370586a8 on template-sync-1 into e7dd6295d710828f954bcdfc0e8dcd394ed8872e on master.

Codecov Report

Merging #142 into master will not change coverage.
The diff coverage is n/a.

@@           Coverage Diff           @@
##           master     #142   +/-   ##
=======================================
  Coverage   93.56%   93.56%
=======================================
  Files          18       18
  Lines         171      171
=======================================
  Hits          160      160
  Misses         11       11

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update e7dd629...0970db9. Read the comment docs.


Permission problem on Notion Enhanced for Mac

Hi ! I tried to fix my problem, but already I don't find any solution so, I need your help :(
I have an error message when I try to open my Notion Enhance Application

Notion is ok, but this one doesn't work.
I have this message

In english : "You do not have the permissions to open the "Notion Enhanced" application. Contact your network or computer administrator for assistance."
Anyone can help me ?
Thank a lot !

I'm sorry, I don't have a Mac, so I don't know why would this happen. Is your user allowed to run unsigned apps? Maybe there is a user policy setting that doesn't allow you to do this.
Also, even if your user has permissions to do that, you'll get a warning for opening an unsigned app, for that check this issue:
https://github.com/notion-enhancer/notion-repackaged/issues/4


Can't run llama model on Intel GPU on Linux platforms

ipex version: ipex-llm==2.2.0b20241010
System: Ubuntu 22.04
Intel OneAPI 2024.2
Description
IPEX cannot infer with multi-round chat (i.e. prefill a new prompt without clearing the KV cache)
When we tried a multi-round chat the library crashes.
The error message is as following:
llm_chat_cli: /home/runner/_work/llm.cpp/llm.cpp/llm.cpp/bigdl-core-xe/llama_backend/sdp_kernel.cpp:639: void sdp_fp8_casual_kernel(const void *, const uint8_t *, const uint8_t *, void *, const size_t, const size_t, const size_t, const size_t, const size_t, const size_t, const size_t, const size_t, const size_t, const size_t, const size_t, const size_t, const size_t, const size_t, const size_t, const size_t, const size_t, float *, float, sycl::queue &) [GS = 32, HD = 96]: Assertion `(context_length-seq_len)%GS==0 && "ubatch must be set as the times of GS\n"' failed.

Also, it works well on Windows system, everything is just fine without modofying any codes.

We tried ipex-llm[cpp]==2.2.0b20240928, no problems found and no crashes.
Also, the Windows version mentioned above is also this 2.2.0b20240928 version.

We have reproduced your issue and are currently working on a fix.

It's fixed now，you can update ipex-llm[cpp] to 2.2.0b20241021 and try again. @acane77

@acane77 @qiuxin2012 also ipex-llm works with 2024.0 in linux  & 2024.2 for windows

It's fixed now，you can update ipex-llm[cpp] to 2.2.0b20241021 and try again. @acane77

We've tried this version and it fixes, thanks


Error message: XGetWindowProperty[_NET_WM_DESKTOP] failed (code=1)

When I run:
./save_page_as 'https://www.tradingview.com/symbols/ETHUSD/' --destination /tmp/eth.html

I get:
XGetWindowProperty[_NET_WM_DESKTOP] failed (code=1)

I do have xdotool installed.  Please advise...
Many thanks!

Hi! Could you try my version? https://github.com/AlexBaranowski/save_page_as


Fix issue with String#contains

Atom seems to like String#includes over String#contains all of a sudden on my install. If you can verify this is a problem for others, here's the change. Closes #13

The fix
Yeah, I just updated from 0.186.0 to 0.189.0 and experienced this.
Given that this would break 0.186.0, do you think its reasonable to do this? Which I assume will work on both:
(capturedError.contains || capturedError.includes)('LoadError')

Or, alternatively, there is apparently a "polyfill" (taken from the MDN docs)
if (!String.prototype.includes) {
  String.prototype.includes = function() {'use strict';
    return String.prototype.indexOf.apply(this, arguments) !== -1;
  };
}

Investigation

Don't see any discussion / explanation on their forum
Their docs don't seem to cover the language itself
Looking through their source, I found "String.contains is not a standard method in Chrome 41" 2620c95d86dc98aae2f5730a193f23c7ff46f803
And looking at v8 source, found a "discussion" about this at  which didn't give me any useful context.
I find JavaScript to be completely opaque :(
My copy of node has neither (modified for readability):
$ node --version
v0.10.26

$ node -pe '"abc".includes("b")'
TypeError: Object abc has no method 'includes'
"abc".includes("b")
      ^

$ node -pe '"abc".contains("b")'
TypeError: Object abc has no method 'contains'
"abc".contains("b")
      ^

MDN docs say it should be includes, but that it's an "experimental technology, part of the ECMAScript 6 (Harmony) proposal".
And I can't figure out how to get a list of methods for strings, yet somehow Chrome and Node can provide an autocomplete list:

It makes no sense to me. I'll switch it to includes, but I have no confidence it won't just magically break again at some point. I swear this language is fkn capricious.

And how does this not break the web? Is the dev console able to use methods that normal JS can't? Won't there be tons of code that hits this issue suddenly?
And am I modifying all JS across Atom by adding the polyfill? Implies I should go with the first solution, then.
Why does the polyfill go so far out of its way to get to the function? Why don't they define it like this?

I'm going to merge this and switch it to indexOf so that I don't break anyone on an older version. Happy to hear any input you have, Steve. And thanks for the fix ^_^ I didn't even know it was broken >.<
You going to DCamp this year? https://twitter.com/ruby_dcamp/status/582963878327353344 Would love to see y'all again!

I think indexOf is the way to go. Don't get me started on JS...

@JoshCheek See you there!


Add start-env and stop-env commands

This pull-request adds start-env and stop-env commands to the CLI. The commands are very useful when a create-env deployment needs maintenance work as DB major update or migration.
Things to notice

the stop-env command reuses parts of the delete-env command and I notice, that the CLI doesn't execute the pre-stop and post-stop scripts. I extended the code to execute those scripts, which makes it more compatible with the bosh stop workflow. If you think this is unnecessary we can remove the pre-stop and post-stop script execution.
the stop-env command doesn't require a manifest, but I added it as argument to be consistent with the start-env command, which requires a manifest.

Executed tests

manual tests
unit-tests
integration-tests
couldn't execute the acceptance tests.

fixes #558

Tested it out and seems to be fine. There are a few typos(findDeploymend) in private methods but they'll be easy enough to refactor in the future. When you get the chance, a docs pr here: https://github.com/cloudfoundry/docs-bosh/blob/17267d8e1365fa63a5555d2300a3b73cafdbbf34/content/cli-envs.md would be great with a note about which cli version (v6.3.2+) it will be in.

@mrosecrance Thank you for reviewing and merging! The docs pr is: https://github.com/cloudfoundry/docs-bosh/pull/728


Fix hover tooltip not updated after character deletions

References
https://github.com/jupyter-lsp/jupyterlab-lsp/issues/866

Code changes
Changed EditorAdapter to emit update signals when nontrivial change.removed exists.

User-facing changes
None.

Backwards-incompatible changes
My concern is that the original behavior might have been intentional as was in the comment.
// deletion - ignore

If so, this PR may affect other signal receivers.

Chores

[x] linted
[x] tested
[ ] documented
[ ] changelog entry

FYI: I could reproduce the CI error about jupyter serverextension list in the following minimum environment.
mamba create -c conda-forge -n py37-minimum-test python=3.7 jupyterlab=3.3 jupyter_server
conda activate py37-minimum-test
jupyter serverextension list

My concern is that the original behavior might have been intentional as was in the comment.

I think that the original intent was to avoid triggering completer on deletion, but indeed this is not where this should be handled. I think it is fine to change it - let's give it a try.


Add a ScatterplotWidget example to sample-app

Thanks to the new widget, available at carto-react lib from 1.1.0-alpha.3

Filtering of other widgets not applying correctly. To review

This requires a new carto-react release > 1.1.0-alpha.3 (which has a small issue on filters).


feat: raw strings: distinguish delimiters from actual string

We could set the delimiters to a different highlight group. Example @punctuation.special:

To see all available groups, hit :h treesitter-highlight-groups. I could see:

@punctuation.special
@punctuation.delimiter
@tag.delimiter
@string.escape
@string.special
@string.special.symbol

Any opinions?
Edit: with highlights now in nvim-treesitter, this feels a bit weird. But we can still maintain our own highlights :D

Thanks


Fix for CI build?

It looks like the CI builds are not working.  Any plans to update them?

Hard to motivate with little progress on the Glimpse front.
It looks like the build for Glimpse fails when trying to compile vNext related projects. So either need to install those bits during the build script or only build the required Glimpse projects instead of the whole suite.


ctest -j16 failed about<EMAIL_ADDRESS>on centos8

Describe the bug
Hello, I meet a problem:ctest -j16 failed about<EMAIL_ADDRESS>on centos8
Steps to reproduce the issue
os:centos8_x86_64
command:ctest -j16
errors:
          1 - cmake-consumer (Failed)
          3 - igrep (Failed)
          5 - oiiotool (Failed)
          8 - oiiotool-copy (Failed)
         12 - oiiotool-subimage (Failed)
         13 - oiiotool-text (Failed)
         19 - maketx (Failed)
         20 - oiiotool-maketx (Failed)
         39 - texture-levels-stochaniso (Failed)
         40 - texture-levels-stochmip (Failed)
         49 - texture-udim (Failed)
         50 - texture-udim2 (Failed)
         73 - texture-levels-stochaniso.batch (Failed)
         74 - texture-levels-stochmip.batch (Failed)
         83 - texture-udim.batch (Failed)
         84 - texture-udim2.batch (Failed)
         93 - oiiotool-color-broken (Failed)
         94 - heif-broken (Failed)
         95 - openvdb-broken (Failed)
         96 - texture-texture3d-broken (Failed)
         97 - openvdb.batch-broken (Failed)
         98 - texture-texture3d.batch-broken (Failed)
         99 - ptex-broken (Failed)
        113 - unit_timer (Failed)

os：centos8_aarch64
command:ctest -j16
errors:
          1 - cmake-consumer (Failed)
          3 - igrep (Failed)
         13 - oiiotool-text (Failed)
         19 - maketx (Failed)
         20 - oiiotool-maketx (Failed)
         32 - texture-crop (Failed)
         34 - texture-half (Failed)
         35 - texture-uint16 (Failed)
         37 - texture-interp-bilinear (Failed)
         38 - texture-interp-closest (Failed)
         39 - texture-levels-stochaniso (Failed)
         40 - texture-levels-stochmip (Failed)
         42 - texture-mip-onelevel (Failed)
         44 - texture-mip-stochastictrilinear (Failed)
         45 - texture-mip-stochasticaniso (Failed)
         51 - texture-uint8 (Failed)
         55 - texture-skinny (Failed)
         73 - texture-levels-stochaniso.batch (Failed)
         74 - texture-levels-stochmip.batch (Failed)
         93 - oiiotool-color-broken (Failed)
         94 - heif-broken (Failed)
         95 - openvdb-broken (Failed)
         96 - texture-texture3d-broken (Failed)
         97 - openvdb.batch-broken (Failed)
         98 - texture-texture3d.batch-broken (Failed)
         99 - ptex-broken (Failed)
        115 - unit_simd (Failed)

And I found out：
texture-crop|texture-half|texture-uint16|texture-interp-bilinear|texture-interp-closest|texture-mip-onelevel|texture-mip-stochastictrilinear|texture-mip-stochasticaniso|texture-uint8|texture-skinny|unit_simd

These test cases support Intel but do not support ARM,Do you need to set some switches on different platforms to test during the test?
Can you help me see how to solve it?

I don't think "do not support ARM" is quite right, but it may be that we have to update the reference output that it uses to verify the tests. Many of the tests are very challenging to have bit-for-bit identical output across different hardware platforms. The testsuite can accommodate this by having multiple valid reference outputs for each test, any one of which matching will let the test pass.
After running the full testsuite, can you zip up the entire contents of build/testsuite and put it someplace I can download? That will contain the non-passing output of all the failed tests, and I can look at them by hand and see which ones simply need additional valid reference output and which are failing for other reasons.

Also, another thing to try: can you make sure that this environment variable is set:
PYTHONPATH=$PWD/build/lib/python/site-packages

and rerun the tests? (This assumes that PWD is where the oiio checkout lives.) Then any tests that continue to fail, zip up as I described before.

@lgritz I have compressed the files in build/testsuite as follows:
Because the file is too large, the error File size too big:25 MB are allowed,316 MB were attempted to upload. is reported, so I can only transfer a few failed compressed files.
testsuite_aarch64/x86-64::
cmake-consumer.tar.gz
oiiotool-copy.tar.gz

@lgritz Can you tell me how to test the test, what parameters need to be added, and how to add the Python dependency, but the problem is still reported?

I'm not sure what's going wrong from those files. Can you try something else?
Please run ctest with these arguments:
cd build
ctest --force-new-ctest-process --output-on-failure  -R igrep >& test.log
tar czvf test.log testsuite/igrep/*.* test.log

And send that? That one seems like a simple test that if we understand why it fails, may give us some insight.

Sorry, I got the third line wrong. It's edited now, but if you're reading this in email, it should have been
tar czvf test.tgz test.log testsuite/igrep/*.*

@lgritz Following your steps, the installation package looks like this:
test.tar.gz

Thanks. This output:
igrep: ../oiio-images/tahoe-gps.jpg: No such file or directory

makes me think that you do not have the oiio-images project checked out in the build/testsuite area, which contains many files that tests depend on.
I'm not quite sure how this is possible, because https://github.com/OpenImageIO/oiio/blob/master/src/cmake/testing.cmake#L406 should automatically download that when you first do the cmake configure step.

@lgritz I'll try downloading oiio-images again to test the other errors.

@lgritz I'm now testing with the master version.
The following error information is displayed:
cmake-consumer.tar.gz
oiiotool-text.tar.gz

I find that the test cases in the bin directory are different from the test cases in the ctest directory. The test cases in the ctest directory are not complete in the bin directory. Do you only need to test the test cases in the bing directory?
[root@localhost bin]#
argparse_test  compute_test     fmath_test  idiff  imagebuf_test      imageinout_test  maketx          parallel_test   span_test      strongparam_test  thread_test       typedesc_test
atomic_test    filesystem_test  hash_test   igrep  imagebufalgo_test  imagespec_test   oiiotool        paramlist_test  spin_rw_test   strutil_test      timer_test        ustring_test
color_test     filter_test      iconvert    iinfo  imagecache_test    imagespeed_test  optparser_test  simd_test       spinlock_test  testtex           type_traits_test

The test programs in build/bin are low-level unit tests, mostly of utility classes, that consist largely of assertion-like tests of individual function calls. An example is typedesc_test.cpp which exercises the TypeDesc class in various ways. There tends to be one of these test programs for each important class. A tiny fraction of the overall testsuite consists of tests that directly call one of those specialized test programs.
The vast majority of the testsuite tests are python programs or invocations of oiiotool and other tools to fully exercise all the functionality of the library and utilities. An example would be testsuite/oiiotool-copy/run.py which invokes oiiotool 28 different times to test all sorts of different kinds of ways to copy files with oiiotool: can it copy and change the file format, can it copy and change the pixel data type, can it crop, can it copy just a subset of channels, can it copy just one subimage out of a file, etc. For most of these tests, it's producing images (sometimes many) or text output, and the tests pass or fail based on whether the outputs match saved outputs that we know are correct.
As far as the two in particular you mentioned:
simd_test doesn't surprise me at all that it fails on aarch64, given that it's an entirely different hardware architecture. It's possible that there are some LSB differences in the floating point math that could be responsible, and the solution is to have some of the assertions allow a little more room for the result to differ than what it expects.
For example, one of the things in that log where it failed was
/home/stage/root/spack-stage-openimageio-<IP_ADDRESS>-ielcu5qk3c4fvsfwkedokackkejg672j/spack-src/src/libutil/simd_test.cpp:1592:
FAILED: fast_log(expA) == mkvec<VEC>(fast_log(expA[0]), fast_log(expA[1]), fast_log(expA[2]), fast_log(expA[3]))
	values were '-1 0 1 4.5 -1 0 1 4.5' and '-1 0 1 4.5 -1 0 1 4.5'

And we can see that line here:
    OIIO_CHECK_SIMD_EQUAL_THRESH (fast_log(expA),
                mkvec<VEC>(fast_log(expA[0]), fast_log(expA[1]), fast_log(expA[2]), fast_log(expA[3])), 0.00001f);

It's already testing with some threshold, 0.00001, which maybe is enough on Intel but not ARM. The fact that there is a threshold there at all already (most of the tests do not have thresholds and test for exact results) indicates that this is a test where I already know that it's hard to achieve exact results from different platforms and allow for a tiny difference. Maybe it's just not enough for ARM and the threshold needs to be adjusted.
I'm not sure what's up with the filesystem_test... it might be that you are invoking it differently than it would be in CI, I'm just not sure yet.

I should point out that the fast_log function it's testing is an approximation, so it's known to not be exactly the same as the IEEE-compliant std::log (but is much faster). It's not the least bit surprising to see it squeak past the threshold on a different hardware platform and need some adjustment of the thresholds.

FYI: Arm and x86_64 are going to do bit identical math if you're using full precision math. The only places it would differ are the approximate instructions: rsqrt and rcp. The other fail case is if the compiler generates different math, such as with -ffast-math, in which case different compilers can generate slightly different results, and fusing such as by -ffp-contract which generates madd. I'm going to guess the slight differences in fast_log are due to the madd instructions being performed on one arch and not the other.

Yeah, in the fast/approximate math functions, we use a lot of mad, knowing that it will be a true fused implementation on some platforms and a multiply followed by a separate add on others. I think it's telling that the simd test failures above were only when testing fast_exp, fast_log, and fast_pow_pos, all of which already had a tolerance in the comparison (whereas most of the testing in simd_test is exact), so even among the x86 machines, we clearly had experienced some platform-to-platform LSB differences on those particular ops.
The solution in this case is simple: just bump the tolerance a teeny bit. The trick is that without an ARM machine to test on, it's hard to know how much. (Another possible route is to really dissect these functions and figure out exactly where and why the scalar and simd implementations differ and decide if we should fix them. But considering it only affects these particular functions that are specifically advertised as being approximate, I'm not sure how much trouble it is worth to ensure it's bit identical.)

Ha, fast_pow_pos is implemented with fast_exp and fast_log. So those are the two functions that probably have one more LSB differing than we accounted for.

I've found that if you change the test method, many test cases can pass.
command:make -j126 USE_PYTHON=0 test

centos8_x86:
The following tests FAILED:
          1 - cmake-consumer (Failed)
          5 - oiiotool (Failed)
          8 - oiiotool-copy (Failed)
         12 - oiiotool-subimage (Failed)
         13 - oiiotool-text (Failed)
         19 - maketx (Failed)
         20 - oiiotool-maketx (Failed)
         49 - texture-udim (Failed)
         50 - texture-udim2 (Failed)
         83 - texture-udim.batch (Failed)
         84 - texture-udim2.batch (Failed)
Errors while running CTest
make: *** [Makefile:307: test] Error 8

centos8_aarch64:
The following tests FAILED:
          1 - cmake-consumer (Failed)
         13 - oiiotool-text (Failed)
         19 - maketx (Failed)
         20 - oiiotool-maketx (Failed)
         32 - texture-crop (Failed)
         34 - texture-half (Failed)
         35 - texture-uint16 (Failed)
         37 - texture-interp-bilinear (Failed)
         38 - texture-interp-closest (Failed)
         39 - texture-levels-stochaniso (Failed)
         40 - texture-levels-stochmip (Failed)
         42 - texture-mip-onelevel (Failed)
         44 - texture-mip-stochastictrilinear (Failed)
         45 - texture-mip-stochasticaniso (Failed)
         51 - texture-uint8 (Failed)
         55 - texture-skinny (Failed)
        108 - unit_simd (Failed)
Errors while running CTest
make: *** [Makefile:307: test] Error 8

 55/120 Test  #55: texture-skinny ..........................***Failed    0.53 sec
Comparing "out.exr" and "ref/out.exr"
512 x 512, 4 channels
  Mean error = 7.26273e-07
  RMS error = 3.6227e-05
  Peak SNR = 88.8194
  Max error  = 0.012207 @ (485, 41, R)  values are 0.8901367, 0.8901367, 0.8901367, 1 vs 0.8779297, 0.8779297, 0.8779297, 1
  2 pixels (0.000763%) over 0.008
  6 pixels (0.00229%) over 0.004
FAILURE
newsymlink /home/stage/root/spack-stage-openimageio-<IP_ADDRESS>-ielcu5qk3c4fvsfwkedokackkejg672j/spack-src/testsuite/texture-skinny/ref ./ref
newsymlink /home/stage/root/spack-stage-openimageio-<IP_ADDRESS>-ielcu5qk3c4fvsfwkedokackkejg672j/spack-src/testsuite/texture-skinny/src ./src
newsymlink /home/stage/root/spack-stage-openimageio-<IP_ADDRESS>-ielcu5qk3c4fvsfwkedokackkejg672j/spack-src/testsuite/texture-skinny ./data
command = ../../bin/testtex  src/vertgrid.tx  --scalest 4 1   >> out.txt  ;

comparisons are ['ref/out.exr']
comparing out.exr to ref/out.exr
NO MATCH for out.exr
FAIL out.exr

Closing because this is concerning an old version


run sonarcube

Update the development branch so it passes sonarcube checks. This issue is needed so that all the other branches can make sonarcube updates which are relevant only to the changes in those branches.

This task should be completed before merging any other PRs. So this task is a high priority.

Use the solution builder pipeline to run sonarcube on this project. Close this issue when sonarcube checks pass for the development branch, and sonarcube checks are included in the pr-workflow.

Redundant to https://github.com/aws-solutions/amazon-marketing-cloud-uploader-from-aws/issues/74
Closing.


false positive for Style/Mixin

I get a complaint for the following code:
module X
  def foo
    include Bar
  end
end

"Style/MixinUsage: include is used at the top level. Use inside class or module"
No, it's not used at the top level.
$ rubocop -v
0.52.0

Definitely, the include is an instance method of X, so the cop should not complain about the code. cc: @koic

Thanks for the feedback.  I confirmed this reproduction. I'm thinking about opening a PR for this issue later.


EMSDK setup

The latest version of Emscripten is not working for me. Added setup for specific version of Emscripten and other minor configuration changes.

Hi @troyedwardsjr thanks for this contribution!
When I run the emsdk setup on my Mac M1 I get this error:
...
HEAD is now at 891b449 3.1.10 (#1046)
Cloning from https://chromium.googlesource.com/emscripten-releases...
Cloning into '/Users/jason/dev/sdks/emsdk/releases'...
remote: Finding sources: 100% (75/75)
remote: Total 33915 (delta 20096), reused 33913 (delta 20096)
Receiving objects: 100% (33915/33915), 14.53 MiB | 18.81 MiB/s, done.
Resolving deltas: 100% (20096/20096), done.
error: failed to find build of any recent emsdk revision
make: *** [setup_emsdk] Error 1

Any idea why this would be happening?

Ok this looks to be a Mac specific issue due to SSL certs not being set up for Python. That can be resolved by following the setup instructions here:
https://bugs.python.org/issue43404
I've also adjusted the make file to support Mac better re zsh.

I'm going to merge as is, and apply Mac specific changes after.


An Example of how to use this would be nice

....

Indeed! Please provide some examples. I would be happy to help with putting together a decent documentation!

ready.

Project still alive or not? Last commits from 2014. Any alternatives?

gpu.js seems closest, but nodejs support seems sketchy


hard code kraan-controller in template but build kraan/kraan-controller-prerelease:v0.1.20-dev

We hard code kraan-controller in https://github.com/fidelity/kraan/blob/711059b0ac74d4cff34d3eadf3fbe8fbb1d94553/chart/templates/kraan/deployment.yaml#L38
but in ci we build  kraan/kraan-controller-prerelease:v0.1.20-dev, seems we should have a value to override this so we can use that build?
Am I missing something?
@saada thoughts

You're absolutely right. I'll create a PR to fix this.


Upgrade BadgeApp to Rails 5

@david-a-wheeler Please review. The only real issue here is ensuring that fastly-rails runs correctly with Rails 5, but you'll need to do that off of master. Also, please note that Rails 5 has stricter enforcement of strong parameters, which I solved in projects_helper.rb.

Excellent, I'll definitely look.  Anything I should be especially wary of?

Only what I mentioned. Note that are other PRs for updating gems depending on this one, to keep this as small as possible.

We're not on Ruby 2.4 yet and I haven't looked into this, so I would
encourage you to do so, as I am planning to add a Ruby 2.4 PR shortly.
On Fri, Dec 30, 2016 at 11:18 AM, David A. Wheeler<EMAIL_ADDRESS>
wrote:

@david-a-wheeler commented on this pull request.
In config/initializers/new_framework_defaults.rb
https://github.com/linuxfoundation/cii-best-practices-badge/pull/556#pullrequestreview-14778655
:

+# This file contains migration options to ease your Rails 5.0 upgrade.
+#
+# Once upgraded flip defaults one by one to migrate to the new default.
+#
+# Read the Guide for Upgrading Ruby on Rails for more info on each option.

+# Enable per-form CSRF tokens. Previous versions had false.
+Rails.application.config.action_controller.per_form_csrf_tokens = false
+
+# Enable origin-checking CSRF mitigation. Previous versions had false.
+Rails.application.config.action_controller.forgery_protection_origin_check =

false

+# Make Ruby 2.4 preserve the timezone of the receiver when calling to_time.
+# Previous versions had false.
+ActiveSupport.to_time_preserves_timezone = false
I presume that "ActiveSupport.to_time_preserves_timezone = false" means
that we'll continue to store all logs, etc., in UTC - correct? I think it's
important to have servers run on UTC - that makes movement easy, since no
one really cares about the current timezone of the server.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
https://github.com/linuxfoundation/cii-best-practices-badge/pull/556#pullrequestreview-14778655,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AC8MBsZYl0snPit5F2jw_wk8F5QZzW6fks5rNUsMgaJpZM4LYSjX
.

--
Dan Kohn<EMAIL_ADDRESS>Executive Director, Cloud Native Computing Foundation https://cncf.io/
tel:+1-415-233-1000

I'd encourage you to open an issue as a reminder.
On Fri, Dec 30, 2016 at 11:21 AM, David A. Wheeler<EMAIL_ADDRESS>
wrote:

@david-a-wheeler commented on this pull request.
In config/initializers/new_framework_defaults.rb
https://github.com/linuxfoundation/cii-best-practices-badge/pull/556#pullrequestreview-14778827
:

@@ -0,0 +1,26 @@
+# frozen_string_literal: true
+# Be sure to restart your server when you modify this file.
+#
+# This file contains migration options to ease your Rails 5.0 upgrade.
+#
+# Once upgraded flip defaults one by one to migrate to the new default.
+#
+# Read the Guide for Upgrading Ruby on Rails for more info on each option.

+# Enable per-form CSRF tokens. Previous versions had false.
+Rails.application.config.action_controller.per_form_csrf_tokens = false
+
+# Enable origin-checking CSRF mitigation. Previous versions had false.
+Rails.application.config.action_controller.forgery_protection_origin_check =
I think these are the right values for now while we upgrade, to
minimize the changes due to Rails 4 -> 5:
Enable per-form CSRF tokens. Previous versions had false.
Rails.application.config.action_controller.per_form_csrf_tokens = false
Enable origin-checking CSRF mitigation. Previous versions had false.
Rails.application.config.action_controller.forgery_protection_origin_check = false
However, I think once we're confident in Rails 5, we should turn these to
"true".  They reduce slightly the
risk of a defect becoming an exploitable vulnerability. We're already doing
a number of things to prevent vulnerabilities anyway, but making two more
flags "true" is a pretty easy thing to enable :-).
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
https://github.com/linuxfoundation/cii-best-practices-badge/pull/556#pullrequestreview-14778827,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AC8MBh1OQvIeJQcA7ZzgdBbuLXUILTRDks5rNUusgaJpZM4LYSjX
.

--
Dan Kohn<EMAIL_ADDRESS>Executive Director, Cloud Native Computing Foundation https://cncf.io/
tel:+1-415-233-1000

And I cc'ed you on the pull request:
https://github.com/fastly/fastly-rails/pull/67
On Fri, Dec 30, 2016 at 11:24 AM, David A. Wheeler<EMAIL_ADDRESS>
wrote:

@david-a-wheeler commented on this pull request.
In Gemfile
https://github.com/linuxfoundation/cii-best-practices-badge/pull/556#pullrequestreview-14779060
:

@@ -9,22 +9,24 @@ gem 'bootstrap-will_paginate', '0.0.10'
gem 'bootstrap_form', '2.5.2'
gem 'chartkick', '2.2.1' # Chart project_stats
gem 'faker', '1.6.6'
-gem 'fastly-rails', '0.7.1' # Use Fastly CDN
+gem 'fastly-rails', git: 'https://github.com/dankohn/fastly-rails',

               ref: 'a909d09'

I really appreciate that you're fixing problems in gems... but I hate
that you need to do it. If they fix other stuff, this may be hard to deal
with.
I see that this version:
dankohn/fastly-rails@a909d09
https://github.com/dankohn/fastly-rails/commit/a909d09d23a3ea5af0a89af175ea47bf490566fd
Removes the railties dependency spec:
s.add_dependency "railties", '< 5'
Have you tried to get this upstream?
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
https://github.com/linuxfoundation/cii-best-practices-badge/pull/556#pullrequestreview-14779060,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AC8MBmOAiTUjvkL8heclVfDd9CEFaJWIks5rNUxygaJpZM4LYSjX
.

--
Dan Kohn<EMAIL_ADDRESS>Executive Director, Cloud Native Computing Foundation https://cncf.io/
tel:+1-415-233-1000

Good point. Will do.
--- David A.Wheeler

Pulled.  It's not currently working.
Details in https://circleci.com/gh/linuxfoundation/cii-best-practices-badge/1488 - it fails with this:
remote:        (called from block in <top (required)> at /tmp/build_00fe76161a30abb64f745dd0eed1be4d/config/environments/production.rb:110)
remote:        rake aborted!
remote:        ArgumentError: wrong number of arguments (given 2, expected 1)
remote:        /tmp/build_00fe76161a30abb64f745dd0eed1be4d/vendor/bundle/ruby/2.3.0/gems/actionpack-5.0.1/lib/action_dispatch/middleware/static.rb:16:in `initialize'
remote:        /tmp/build_00fe76161a30abb64f745dd0eed1be4d/vendor/bundle/ruby/2.3.0/gems/heroku_rails_deflate-1.0.3/lib/heroku_rails_deflate/serve_zipped_assets.rb:16:in `new'
remote:        /tmp/build_00fe76161a30abb64f745dd0eed1be4d/vendor/bundle/ruby/2.3.0/gems/heroku_rails_deflate-1.0.3/lib/heroku_rails_deflate/serve_zipped_assets.rb:16:in `initialize'
remote:        /tmp/build_00fe76161a30abb64f745dd0eed1be4d/vendor/bundle/ruby/2.3.0/gems/actionpack-5.0.1/lib/action_dispatch/middleware/stack.rb:35:in `new'
remote:        /tmp/build_00fe76161a30abb64f745dd0eed1be4d/vendor/bundle/ruby/2.3.0/gems/actionpack-5.0.1/lib/action_dispatch/middleware/stack.rb:35:in `build'

We specifically request Ruby 2.3.1 (e.g., in .ruby-version), and the beginning of the build acknowledges this.  Yet by this point it appears that we're at 2.3.0. Why? I don't know.

It's not clear that ruby 2.3.0 vs. 2.3.1 is the source of trouble.  Here's a look at the backtrace...
My ~/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/actionpack-5.0.1/lib/action_dispatch/middleware/static.rb
require 'rack/utils'
require 'active_support/core_ext/uri'

module ActionDispatch
  # This middleware returns a file's contents from disk in the body response.
  # When initialized, it can accept optional HTTP headers, which will be set
  # when a response containing a file's contents is delivered.
  #
  # This middleware will render the file specified in `env["PATH_INFO"]`
  # where the base path is in the +root+ directory. For example, if the +root+
  # is set to `public/`, then a request with `env["PATH_INFO"]` of
  # `assets/application.js` will return a response with the contents of a file
  # located at `public/assets/application.js` if the file exists. If the file
  # does not exist, a 404 "File not Found" response will be returned.
  class FileHandler
    def initialize(root, index: 'index', headers: {})  ## THIS IS LINE 16!
      @root          = root.chomp('/')
      @file_server   = ::Rack::File.new(@root, headers)
      @index         = index
    end

My ~/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/heroku_rails_deflate-1.0.3/lib/heroku_rails_deflate/serve_zipped_assets.rb
require 'action_controller'
require 'active_support/core_ext/uri'
require 'action_dispatch/middleware/static'

# Middleware to serve the gzipped version of static assets if they exist
# Adapted from https://gist.github.com/guyboltonking/2152663
module HerokuRailsDeflate
  class ServeZippedAssets
    # Params:
    #   root: the public directory
    #   asset_prefix: config.assets.prefix
    #   cache_control: config.static_cache_control
    def initialize(app, root, asset_prefix, cache_control=nil)
      @app = app
      @asset_prefix = asset_prefix.chomp('/') + '/'
      @file_handler = ActionDispatch::FileHandler.new(root, cache_control)  ## THIS IS LINE 16
    end

Good news, I can reproduce the error locally using:
FASTLY_API_KEY=... RAILS_ENV=production rails s

That doesn't fix the problem, but it's a helpful step along the way.

Fixed. The deflate gem is broken on Rails 5.
On Wed, Jan 4, 2017 at 5:08 PM, David A. Wheeler<EMAIL_ADDRESS>wrote:

Good news, I can reproduce the error locally using:
FASTLY_API_KEY=... RAILS_ENV=production rails s
That doesn't fix the problem, but it's a helpful step along the way.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
https://github.com/linuxfoundation/cii-best-practices-badge/pull/556#issuecomment-270501214,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AC8MBjZsXindFVRl7DRDImaRp88gSVcIks5rPBhmgaJpZM4LYSjX
.

--
Dan Kohn<EMAIL_ADDRESS>Executive Director, Cloud Native Computing Foundation https://cncf.io/
tel:+1-415-233-1000

Seems to be a problem with deflating.  Current hypothesis: heroku_rails_deflate is setting "config.static_cache_control" to a value that's confusing it. Info below.
$ grep -R 'config.static_cache_control' /home/dwheeler/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0 | grep -v 'test.rb' | grep -v 'dummy'| grep -v '\.md'
/home/dwheeler/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/railties-<IP_ADDRESS>/lib/rails/application/default_middleware_stack.rb:            middleware.use ::ActionDispatch::Static, paths["public"].first, config.static_cache_control
/home/dwheeler/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/heroku_rails_deflate-1.0.3/lib/heroku_rails_deflate/serve_zipped_assets.rb:    #   cache_control: config.static_cache_control
/home/dwheeler/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/heroku_rails_deflate-1.0.3/lib/heroku_rails_deflate/railtie.rb:                                         app.config.static_cache_control
/home/dwheeler/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/heroku_rails_deflate-1.0.3/lib/heroku_rails_deflate/railtie.rb:      app.config.static_cache_control = 'public, max-age=31536000'

Oh, good!  I see that while I was typing, you already fixed.  I like that :-).

I suggest making the fix a separate PR.  I already did a squash merge on the other changes for Rails 5.

I pushed the fix to master already. Do you want me to revert it from master and cherry pick it into another branch to do a PR?

No, that's fine.

Your fix is the right answer for now.  I hate dropping heroku_rails_deflate, though.  This problem is already known upstream, and there's even a proposed patch:
https://github.com/mattolson/heroku_rails_deflate/pull/24
Hopefully upstream will fix, and then we can restore heroku_rails_deflate.

Great news! I ran this separate automated test several times:

rake fastly:test

Fastly purged and re-cached the badge value correctly multiple times.  That was one of the concerns with this upgrade, and it appears all is okay.


Add GetMany method to store

The pipeline and GetP method are generic, one pipeline can include multiple stores and multiple keys, so we can't apply store's Singleflight config here. So I will add another method GetMany to each store, this method can get multiple keys from same store with 1 redis hit. And benefit from Singleflight option. Also this method should be unordered. That means ["a", "b"] and ["b", "a"] should be in same singleflight call, because they ask for same elements, just in different order.
Two options in my mind:

param struct:

// FooParams is created by code generation
FooStore.GetMany(ctx, []FooParams{{ID: "a", Name: "a"}, {ID: "b", Name: "b"}})
// will return []model.Foo{...}

OR

call chain:

FooStore.GetM("a", "a").GetM("b", "b").Do(ctx)
// will return []model.Foo{...}

Both options should return reuslts directly, same order as input.

Maybe better choice is return a map map[string]model.Foo, key would be the combination of all params: "a-a", "b-b".
This way also lead to an optimization: if you query same key multi times, cacheme can remove duplicate ones when sending command to redis.
Also some detail steps of this command:

wrap following steps in a singleflight, if singleflight on
send mget to redis
collect redis results
for all nil results, call fetch function
complete the redis results and return
if error happens in any step, should return error


Tool leads to memory leakage

Please see https://github.com/mrdoob/three.js/issues/18759#issuecomment-592223144
TL;DR just by installing and enabling this tool AND NOT using API in the app code in any way memory leakage is created. That leads to false assumptions when developing app based on Three.js. My assumption was first that my code leaks, then that Three.js lib has bug - based on latest tests leakage occurs when this tool is installed in Chrome.

Thanks for the detailed report! I'll check it out

In that case, you might be able to put __THREE_DEVTOOLS__ = null at the top of your script to disable it on a specific page -- does this only happen when thousands of renderers are created?

Setting to null will not work.
/* global __THREE_DEVTOOLS__ */
if (typeof __THREE_DEVTOOLS__ !== 'undefined') {
  __THREE_DEVTOOLS__ = null; // eslint-disable-line no-global-assign
}

In strict mode will fail with a bang

Uncaught TypeError: Cannot assign to read only property '__THREE_DEVTOOLS__' of object '#<Window>'

In non strict will probably fail silently.

via https://github.com/mrdoob/three.js/issues/18759, this looks like it was an issue with a large amount of renderers, an edge case with three.js -- closing this issue for now


Search indicator

Issue Type: Bug
When i go back to file when i searched for a passphrase, indicator shows me that my selected occurence is first(1), after going forward in search indicator shows actual value.
How to reproduce:

Open a file and search for repeated phrase
Go to second or third occurence of phrase
Go to next opened file in VS Code
Go back to file where search was
Look at indicator, it shows 1 and not your last search position (i.e. 2 or 3)
Search next phrase (indicator go back to correct value)

VS Code version: Code 1.33.1 (51b0b28134d51361cf996d2f0a1c698247aeabd8, 2019-04-11T08:27:14.102Z)
OS version: Windows_NT x64 10.0.17134

System Info

Item
Value

CPUs
Intel(R) Core(TM) i5-4460  CPU @ 3.20GHz (4 x 3193)

GPU Status
2d_canvas: enabledchecker_imaging: disabled_offflash_3d: enabledflash_stage3d: enabledflash_stage3d_baseline: enabledgpu_compositing: enabledmultiple_raster_threads: enabled_onnative_gpu_memory_buffers: disabled_softwarerasterization: enabledsurface_synchronization: enabled_onvideo_decode: enabledwebgl: enabledwebgl2: enabled

Memory (System)
15.88GB (11.16GB free)

Process Argv
C:\Users\pokoniewski\Desktop\butor-mirjan24.hu-error_log

Screen Reader
no

VM
0%

Extensions (12)

Extension
Author (truncated)
Version

vscode-intelephense-client
bme
1.0.13

vscode-faker
dee
1.3.0

vs-code-xml-format
fab
0.1.5

code-runner
for
0.9.8

beautify
Hoo
1.4.11

smarty
imp
0.3.0

vscode-placeholder-images
Jak
0.1.0

css-grid-snippets
oha
0.0.5

material-icon-theme
PKi
3.7.0

LiveServer
rit
5.5.1

open-in-browser
tec
2.0.0

bootstrap4-vscode
the
6.1.0

(1 theme extensions excluded)

Sorry I'm not sure what you mean by "indicator", can you explain some more?

Well, by indicator i mean number which shows position of actual searched word i.e. 1 of 5.
It's next to regular expression option in Find.

/duplicate
we don't support it at this moment.


[Bug]: There are 7 physical tables, but only 4 are extracted when the logical table is extracted

ODC version
4.3.2
OB version
no related
What happened?
There are 10 physical tables, but only 4 logical tables are extracted

What did you expect to happen?
The number of physical tables extracted from logical tables is the same as the actual number
How can we reproduce it (as minimally and precisely as possible)?
Run CREATE TABLE 'qym1'.'test[00-03]' (
A1 varchar(120) NULL,
A2 float(10, 0) NULL
) DEFAULT CHARSET = utf8mb4 COLLATE = utf8mb4_general_ci ;
ddl statement, and then run the CREATE TABLE 'qym1'.'test[04-07]' (
A1 varchar(120) NULL,
A2 varchar(10) NULL
) DEFAULT CHARSET = utf8mb4 COLLATE = utf8mb4_general_ci ;
Create a table statement in the DDL logical database, and then extract the logical table only to the logical table of qym1.'test[00-03].
Anything else we need to know?
No response

You created 'qym1'.'test[00-03]' which is 4 tables. Why you will have 10 tables?


Enhancement suggestion: Provide default styles override option

It would be great if the default styles could be easily overridden. Something like:
  constructor(props) {
    super(props)

    this.state.styles = { styles, ...props.styles }
  }

and then use this.state.styles instead of styles in the code. Right now, it's a little cumbersome to have to provide a new render function just to change the style of a skip/next/done text button.
Thanks!

I have now added dotStyle, activeDotStyle, buttonTextStyle, and buttonStyle to props, hope that covers it.


DSA unverifiable unsupported

Hi all!
Running some lab-provided test vectors via libacvp (1.4.0) with openssl-fips 2.0.16 and openssl 1.0.2u, and noticed DSA pqgGen, unverifiable tests are currently unsupported in libacvp.  Looking at the fips testcode (fips_dssvs.c) it looks like this mode should work similarly to canonical, but with the seedlen and index set to -1.
I've tried to tweak the processing code to allow unverifiable with the above changes, but get an error from dsa_builtin_paramgen2() (a divide by zero from bn_div.c, as i recall).
Is there a reason unverifiable is not supported?  Is there something obvious i am missing on what would need to be supported for unverifiable?
Thanks!

Looks the ACVP server does not provide a seed nor an index for unverifiable.  I don't believe dsa_builtin_paramgen2() will work without a seed and index and that's likely what is triggering your divide by zero. Which leads me to believe that fips_dssvs.c never truly supported unverifiable for FOM 2.0.
The ACVP spec provides a pointer to FIPS 186-4 appendix A for how unverifiable G should be calculated, it looks a bit different than cannonical.

hmm... looks like dsa_builtin_paramgen2() does support unverifiable in this case, but q is actually zero when actually passed to it due to a switch in acvp_dsa_pqggen_init_tc() not parsing and storing the TC values for p and q.  I'll update more once i cleanup a bit.


There is a function main being exported in the library

Hi,
There is a function main() at the end of viewer/svpaint.cpp, which is compiled and exported when building the library. I think it shouldn't be there, or it should be protected by some define so you only compile it when you need it

Did you oversaw #ifndef GRAPHICS_DISABLED ?

I saw it, but as graphics is enabled by default, and as it enables more functions (apart from main), I thought that disabling graphics would also disable more functions and disable some functionality (perhaps all those functions are only used by that main() so it doesn't matter, but I don't know)
So, by default the library is compiled with a main() function, I could --disable-graphics. However, I don't think it's a good idea to put main inside a library or, if needed (why?), to be the default behavior.
Could it be that main() is used by some the executable and it is also included in the library by mistake?
Cheers.


refactor(google-analytics): Warning if ordernumber element is not found

1. Why is this change necessary?
When looking into the issue https://github.com/shopware/shopware/issues/4157 I found, that actually the if condition does not make sense, as the event handler will error out, before coming to that.
2. What does this change do, exactly?
Do not walk into an JS error, but rather a log a warning.
3. Describe each step to reproduce the issue or behaviour.
Remove the .finish-ordernumber element on the finish page and try to track the order with Google Analytics.
4. Please link to the relevant issues (if any).
-
5. Checklist

[x] I have rebased my changes to remove merge conflicts
[ ] I have written tests and verified that they fail without my change
[x] I have created a changelog file with all necessary information about my changes
[ ] I have written or adjusted the documentation according to my changes
[ ] This change has comments for package types, values, functions, and non-obvious lines of code
[x] I have read the contribution requirements and fulfill them.

@aragon999 Your changes were merged to trunk ✅ https://github.com/shopware/shopware/commit/9d2465848f0ac07d73661057cbcb618f0b2c5a42
Thank you for your contribution. 🎉


Need fix the go vet errors

Description
There are still some go vet errors from Go Report Card.
Some errors will result in problem when write logs.
Like this:
https://github.com/hyperledger/fabric/blob/master/core/crypto/peer_impl.go#L67
Maybe we need consider to add the go_vet examines as a necessary condition in our CI verification. The go vet examines must 100% green before run other tests.

I took care a most of them (if not all) in PR #1855

Great, will close this issue.

Duplicate #1855


Copy build.sbt from scala/hello-world.g8

That style of build is simpler, hopefully preventing mistakes. Furthermore, it contains very detailed comments, which explain what each line does, and guide the user.

https://github.com/scala/scala3.g8/pull/139 is contained within these changes
I.e. a comma has been added at the end of the library dependency line in the "multi-project" section


Missing data/nuScenes/infos_test_10sweeps_withvelo_filter_True.pkl file.

Hi:
I have an issue with missing.
FileNotFoundError: [Errno 2] No such file or directory: 'data/nuScenes/infos_test_10sweeps_withvelo_filter_True.pkl'
when I run the code to generate the detection.
Does anyone have this problem with me?
Thanks

Hi for test set inference, the info file is located at data/nuScenes/v1.0-test/info.pkl you may need to change the path for some configs

Let me know if you get further questions

HELLO I have the same problem."FileNotFoundError: [Errno 2] No such file or directory: 'data/nuScenes/infos_test_10sweeps_withvelo_filter_True.pkl'"  And i d like to ask ,where does the folder "v1.0-test"come from?
i v been following "Getting Started with CenterPoint on nuScenes" , i finished "Create data" step and now have all the other folders except "v1.0-test" w.r.t the orgnization required in "Test Set" part.

You do not need to download this. You can generate this by using the data generation file. Just follow the instruction. You probably need to change the file name in the config file.


Typescript error on compile

node_modules/firesql/firesql.d.ts:16:83 - error TS2694: Namespace '"node_modules/firebase/app/dist/app/index"' has no exported member 'firestore'.
16 export declare type FirestoreOrDocument = firebase.firestore.Firestore | firebase.firestore.DocumentReference | AdminFirestore | AdminDocumentReference;
Versions:
"firebase-admin": "^11.7.0"
"firesql": "^2.0.2"
"firebase": "^9.0.0"

fixed by downgrading firebase to 8.0.0


speak_text_async() is not async

I have this line of code
result = speech_synthesizer.speak_text_async(text).get()
which is supposed to be async. I have created a callback handler to intercept the streamed data in chunks like so
`class MyPushAudioOutputStream(speechsdk.audio.PushAudioOutputStreamCallback):
def init(self, frame_rate, sample_width, channels):
super().init()
self.frame_rate = frame_rate
self.sample_width = sample_width
self.channels = channels
self.audio_data = bytearray()
self.chunk_count = 0
def write(self, audio_buffer):
    audio_data = bytes(audio_buffer)
    self.audio_data.extend(audio_data)

    # Add WAV headers to the audio data
    wav_data_with_header = self.add_wav_header(audio_data)
    encoded_audio_data = base64.b64encode(wav_data_with_header).decode('utf-8')
    socketio.emit('audio_stream', {'audio_data': encoded_audio_data})

    return len(audio_data)`

I am able to get the data right as its coming in. emitting the daat through sockets is not working untill synthesis is complete (speak_text_async). It is blocking the emit behavior of sockets. However the function specifically has a comment description saying "Performs synthesis on plain text in a non-blocking (asynchronous) mode." which is clearly not the case
Here is my main code
`@socketio.on('synthesize_text')
def handle_synthesize_text(data):
start_time = time.time()
text = data['text']
print('Speaking!!!')
# Define audio parameters
frame_rate = 16000  # Example frame rate, set this to your desired frame rate
sample_width = 2    # 2 bytes for 16-bit audio
channels = 1        # Mono audio

# Create a push audio output stream with the callback
push_stream_callback = MyPushAudioOutputStream(frame_rate, sample_width, channels)
audio_output_stream = speechsdk.audio.PushAudioOutputStream(push_stream_callback)
audio_output_config = speechsdk.audio.AudioOutputConfig(stream=audio_output_stream)

# Create a speech synthesizer with the push audio output stream
speech_synthesizer = speechsdk.SpeechSynthesizer(speech_config=speech_config, audio_config=audio_output_config)

# Emit the initial WAV header to the client
num_channels = channels
sample_rate = frame_rate
byte_rate = sample_rate * num_channels * sample_width
block_align = num_channels * sample_width
bits_per_sample = sample_width * 8
subchunk2_size = 0
chunk_size = 36 + subchunk2_size

wav_header = struct.pack('<4sI4s4sIHHIIHH4sI',
                         b'RIFF',
                         chunk_size,
                         b'WAVE',
                         b'fmt ',
                         16,
                         1,
                         num_channels,
                         sample_rate,
                         byte_rate,
                         block_align,
                         bits_per_sample,
                         b'data',
                         subchunk2_size)
encoded_wav_header = base64.b64encode(wav_header).decode('utf-8')
socketio.emit('audio_stream', {'audio_data': encoded_wav_header})

result = speech_synthesizer.speak_text_async(text).get()
print('Done Speaking!!!')
end_time = time.time()

# Print synthesis time for debugging
print(f"Synthesis time: {end_time - start_time} seconds")

if result.reason == speechsdk.ResultReason.SynthesizingAudioCompleted:
    print("Synthesis completed.")
elif result.reason == speechsdk.ResultReason.Canceled:
    cancellation_details = result.cancellation_details
    if cancellation_details.reason == speechsdk.CancellationReason.Error:
        # Emit detailed error information to the client
        socketio.emit('synthesis_error', {'message': 'Speech synthesis canceled due to an error.',
                                          'details': cancellation_details.error_details})
    else:
        socketio.emit('synthesis_error', {'message': 'Speech synthesis was canceled.'})
else:
    socketio.emit('synthesis_error', {'message': 'Failed to synthesize speech for unknown reasons.'})`

I am not able to stream to my socket in realtime because of this error.
Version of the Cognitive Services Speech SDK: 1.37.0
Which version of the SDK are you using: Latest.
Platform, Operating System, and Programming Language

OS: [Windows]
Hardware - x64
Programming language: Python
Browser: I'm running the front end in React and using Firefox for playing the stream data.

Additional information: I'm using sockets in async mode and monkey patching with gevent. The code is hosted on an azure web app (Linux) basic b1 tier.

@yulin-li Can you please check.

Here is my solution to avoid blocking flow when using .get method from azure python
def your_method_is_blocked_util_get_result(your params,...):
....
result = speech_synthesizer.speak_text_async(text).get()
....
async def wrap_async_method:
result_method = asyncio.to_thread( your_method_is_blocked_util_get_result , your params)
await result_method

your main flow
await wrap_async_method(param....)

It's true that the speak_text_async() API is not an asyncio API in Python. Actually the Speech SDK doesn't support asyncio now.

Here is my solution to avoid blocking flow when using .get method from azure python
def your_method_is_blocked_util_get_result(your params,...): .... result = speech_synthesizer.speak_text_async(text).get()
....
async def wrap_async_method: result_method = asyncio.to_thread( your_method_is_blocked_util_get_result , your params) await result_method
your main flow
await wrap_async_method(param....)

Let me try this solution. Am i correct in assuming that this is a workaround more than a full on solution?

yes. azure async is not an async API. So you should put this blocking to another thread, while your main runs on main thread.


The editor doesn't follow the .editorconfig options

Please see https://github.com/prettier/prettier-atom/issues/715
Involved .editorconfig-files
# EditorConfig is awesome: http://EditorConfig.org

# top-most EditorConfig file
root = true

# Unix-style newlines with a newline ending every file
[*]
charset = utf-8
end_of_line = lf
indent_style = space
indent_size = 2
insert_final_newline = true
trim_trailing_whitespace = true

[*.md]
trim_trailing_whitespace = false
indent_size = 4
indent_style = space

Directory structure
My working directory is very huge.

Hi @florianb.
When I try to fix my .md files, editorconfig doesn't repair a 2 spaces indent to 4 spaces.

@TJProgrammer how do you invoke the fix?

From command pallette.

Okay - and you have the file you're trying to fix open?

Yup 👍

Yup 👍

@TJProgrammer i just got it, you're trying to fix from spaces to spaces, this is not implemented because it is impossible to fix.
Since we don't know with how many spaces the indentation in the current file is laid out, we can't safely change the indentation.

But if I want to fix it, the script just has to do the indentation according .editorconfig file, no?
And, when I indent pressing twice the tab key (2 spaces * 2), the files seems to translate it to a hard tab instead of a soft tab.
And I opened this issue because the .md files need the 4 spaces of indentation to make a sublist working.

When editing the file, the current rules should be applied to your textbuffer. You might check the applied rules using EditorConfig: Check State.
The Fix-command works only for transformations between tabs and spaces.
If you press the tab key twice and the check state command shows you spaces are applied it is very likely another plugin is interfering the settings.

Ok, thank you. I'll see another plugins in my atom editor.
PS: I checked the same file with nano and all indentatio is in spaces (as you said, some configuration or the edito itself behaves like that).

You're welcome @TJProgrammer!


[doc]: add doc for pytorch2onnx

Hi,
Add a document for the usage and the list of supported models of pytorch2onnx .

The tutorial is not added to the doc index.

@hellock
This doc is added as reference  in MMDetection model to ONNX (experimental) part in  docs/usefull_tools.md.


ENH: add "by" attribute to all plot methods

Code Sample, a copy-pastable example if possible

boxplot has a grouby attribute "by" which makes it easy to plot all months of a year in a facet grid of subplots: http://stackoverflow.com/a/37687386
It would be greta to have this also for other plot types such as scatter, line, historgram

I checked and other isssues on subplot & grouby are rather related to histogramms.
This here aims for a quick method how to create subplot facet grid for the same variable(s) on different sections or intervals of the dataframe:

1 plot for every year of a multi-year timeseries
1 plot for each average day of a full year series

In theory, this would a facet grid of subplots where each plot is made from a column of a 2-d pivot table, e.g. a table with teh 12 months on x-axis and values on x-axis.
Expected Output

https://plot.ly/~MattSundquist/11035.png from http://blog.plot.ly/post/117105992082/time-series-graphs-eleven-stunning-ways-you-can & http://nbviewer.jupyter.org/gist/mkcor/0ee7c73d9ba4c68ddc1a/
http://i.stack.imgur.com/dGhai.png from http://stackoverflow.com/a/37126436

Similar functionality is provided by calmap
==> I hope this suggestion is not beyond the scope of pandas.
--> similar functonality but with less convenience is provided by seaborn
http://stanford.edu/~mwaskom/software/seaborn/generated/seaborn.FacetGrid.html

I think this would be a decent amount of work, for something that seaborn handles well already.
For the specific issue about multiple plots by year, one solution is to use unstuck and subplots
In [18]: import pandas.util.testing as tm

In [19]: ts = tm.makeTimeSeries(nper=1000)

In [20]: ts.index = pd.MultiIndex.from_arrays([ts.index.year, ts.index.month, ts.index.day])

In [21]: ts.unstack(0).plot(subplots=True, layout=(2, 2))

OK, agree.
Thanks for the example. Maybe will add to the cookbook albeit requires still to tweak the x-axis (date). I though that date labels was supported natively by pandas plots.


imageview should be able to work without an index

imageview reads an index and displays the images listed therein.  In particular, it requires the index to exist.  It should also be able to work without the index.  In this case it should display all images in the image directory or listed in the command line.

The obvious solution is to create the index ad hoc in memory.  This requires the following other issues to be solved first:

[ ] Issue #6, because this in memory index will not have any tags set.
[ ] Issue #12, because calculating checksums is pointless for an in memory index and takes too much time in directories with many images.

I chose a different solution: if the index file cannot be read imageview resorts to an ad hoc in memory index and disables the tag select dialog.  The latter works around Issue #6.  The tag select dialog is pretty pointless for an in memory index anyway.


Allow running tests with the native image server

This PR starts the native image server and configures Micronaut Test to use so that integration tests can also test the native image build

Interesting approach. Why can't you use ProcessBuilder#inheritIO()? To do it on a different thread?

I did try ProcessBuilder#inheritIO() but it didn't seem to work, there was no output from Gradle. I think gradle swaps out the system out some point later in the lifecycle


Don't fatal error if there is no where to install command line

It's possible that /usr/local/bin and /etc/paths.d are not available.
On fresh Sierra install /etc/paths.d wasn't available.
In this case we should log warning instead of erroring otherwise we'll show this error on every app start.
In the future, we should show a UI to tell the user (once?) that they can manually add keybase to their path.

@keybase/react-hackers

In settings we can add some page to install the cli. @malgorithms ?
On Friday, August 26, 2016, Gabriel Handford<EMAIL_ADDRESS>wrote:

@keybase/react-hackers
https://github.com/orgs/keybase/teams/react-hackers
—
You are receiving this because you are on a team that was mentioned.
Reply to this email directly, view it on GitHub
https://github.com/keybase/client/pull/4078#issuecomment-242862340, or mute
the thread
https://github.com/notifications/unsubscribe-auth/AAfhU0nAUHiFrTYvMVGEzuJB8txiHNvMks5qj2H7gaJpZM4JugIQ
.

In settings we can add some page to install the cli. @malgorithms ?

so if you do a fresh sierra install, keybase won't work from the CLI...what would the settings screen do to fix this, and can't we just do it during the install?

is there some process which actually makes /etc/paths.d ? why isn't it doing it when keybase is installed? can we find another place to install instead? (add a line to their bash_profile?)

On fresh install... Terminal will load /etc/profile, which uses path_helper:
if [ -x /usr/libexec/path_helper ]; then
	eval `/usr/libexec/path_helper -s`
fi

The path_helper utility reads the contents of the files in the directo-
 ries /etc/paths.d and /etc/manpaths.d and appends their contents to the
 PATH and MANPATH environment variables respectively.

But a lot of people create a .bash_profile in which case, /etc/profile is not used... but hopefully in this case they have /usr/local/bin in their path, and we also try to put a symlink in /usr/local/bin.
I've filled an issue with Apple about /etc/paths.d not existing on Sierra, seems like a regression.
We could also create this directory, which would require a helper tool update since it requires a root privilege.
So currently, keybase is in you path if:

You use default system /etc/profile. You don't have custom .bash_profile
You have /usr/local/bin in you PATH

It seems like (anecdotally) 99% of users fall into those 2 categories.
If not, we probably wan't to show an message with link to online doc about how to add keybase to your path.
I don't think we can edit your .bash_profile (what if you don't have one, or don't use bash)?

If Sierra GM still doesn't have /etc/paths.d we should consider a fix where we create it.
Because we can't cover 100% of PATH scenarios, I've created this:
https://keybase.atlassian.net/browse/DESKTOP-1799

Ok I've changed the PR to create /etc/paths.d if missing, in the helper tool. Instead of working around the error, this will fix it, so people on fresh installs will have keybase in their path on Sierra.
Instead of incrementing the version, I'm including a build number in the helper tool, which we can increment for changes (like this) that aren't required updates.

BTW, I've have a VM Sierra snapshot (vmware) that I test stuff like this on, repeatably.

bump

this sounds good to me, although someone other than me should review your code. @chrisnojima  is out today, so if you want it today, maybe grab someone in your office?

:+1:

@maxtaco


Question: How can I obtain a request-handler's input and output types at compile time?

Hi, folks.
First off - thank you for building such a wonderful library. Our team has really enjoyed working with it.
It appears that the typical way that a developer would implement a contract/router defined with ts-rest is by defining an object literal containing a bunch of functions w/out input or output types:
import { initContract } from '@ts-rest/core';
import { z } from 'zod';
import { initServer } from '@ts-rest/express';

export const EchoSchema = initContract().router({
  echo: {
    method: 'POST',
    path: '/echo',
    body: z.object({
      call: z.string(),
    }),
    responses: {
      201: z.object({
        response: z.string(),
      }),
    },
  },
});

const router = initServer().router(EchoSchema, {
  echo: async (req) => {
    return {
      status: 201,
      body: {
        response: `you said: ${req.body.call}`,
      },
    };
  },
});

In our application, we'd like to use an instance of a class to implement our contract/router:
import { initContract } from '@ts-rest/core';
import { z } from 'zod';
import { initServer } from '@ts-rest/express';

export const EchoSchema = initContract().router({
  echo: {
    method: 'POST',
    path: '/echo',
    body: z.object({
      call: z.string(),
    }),
    responses: {
      201: z.object({
        response: z.string(),
      }),
    },
  },
});

class Controller {
  public async echo(req: any): Promise<any> {
    return {
      status: 201,
      body: {
        response: `you said: ${req.body.call}`,
      },
    };
  }
}

const router = initServer().router(EchoSchema, new Controller());

Does ts-rest provide any mechanism for defining proper types for the methods on our Controller class such that we could change public async echo(req: any): Promise<any> to something like public async echo(req: EchoSchema['echo']['input']): EchoSchema['echo']['output']?
Thanks again for the great library!

Hi @laser! Glad your team's experience has been great so far.
Have a look at https://ts-rest.com/docs/core/infer-types this should be exactly what you are looking for. So in your case you'll need to use ServerInferRequest<typeof EchoSchema> and ServerInferResponses<typeof EchoSchema>

Lovely, thanks a bunch! Apologies for missing that - I should have read the docs closer.

resolved

Lovely, thanks a bunch! Apologies for missing that - I should have read the docs closer.

@Gabrola - One final question: I note that if I use ServerInferRequest<typeof EchoSchema>['echo'] that the res property of the req (the Express response) is not available, which means that I can't use request locals.
If I use ServerInferRequest, is there any way to get at that value?
Example:
class Controller {
  public async echo(req: ServerInferRequest<typeof EchoSchema>['echo']): Promise<ServerInferResponse<typeof EchoSchema>['echo']> {
    console.log(`middleware value: ${req.res.locals.someval}`);

    return {
      status: 201,
      body: {
        response: `you said: ${req.body.call}`,
      },
    };
  }
}

Note: Although passing an instance of Controller that uses ServerInferRequest and ServerInferResponses does compile, the server fails to boot. See this GitHub issue for more information.


Leak if not reading the output of Query function

A sample program:
package main

import (
	"fmt"
	"net/http"
	_ "net/http/pprof"
	"time"

	"github.com/gomodule/redigo/redis"
	rg "github.com/redislabs/redisgraph-go"
	"github.com/sirupsen/logrus"
)

func process() {
	for {
		queryStr := fmt.Sprintf("MATCH (X) RETURN X")

		_ = query("mesh7Graph", queryStr)
		logrus.Println("blah")
	}
}

func query(graphName, query string) error {
	conn := pool.Get()
	defer conn.Close()

	g := rg.GraphNew(graphName, conn)
	if false {
		_, err := g.Query(query)
		if err != nil {
			logrus.Errorf("GraphDB query error: %v", err)
			return err
		}
	} else {
		res, err := g.Query(query)
		if err != nil {
			logrus.Errorf("GraphDB query error: %v", err)
			return err
		}

		for res.Next() {
			_ = res.Record()
		}
	}

	return nil
}

var pool *redis.Pool

const (
	address  = "<REDIS_SERVER_URL>:6379"
	password = "<REDIS_PASSWORD>"
)

func main() {
	pool = &redis.Pool{
		MaxIdle:     100,
		MaxActive:   100,
		IdleTimeout: 240 * time.Second,
		// Dial or DialContext must be set.
		// When both are set, DialContext takes precedence over Dial.
		Dial: func() (redis.Conn, error) {
			c, err := redis.Dial("tcp", address)
			logrus.Tracef("Dialing redis @ %v", address)
			if err != nil {
				logrus.Errorf("Dial failed. Error: %v", err)
				return nil, err
			}
			if _, err := c.Do("AUTH", password); err != nil {
				logrus.Errorf("Authorization failed. Error: %v", err)
				c.Close()
				return nil, err
			}
			return c, nil
		},
		TestOnBorrow: func(c redis.Conn, t time.Time) error {
			if time.Since(t) < time.Minute {
				return nil
			}
			_, err := c.Do("PING")
			return err
		},
	}

	go process()

	logrus.Fatal(http.ListenAndServe("localhost:8080", nil))
}

Now run the above program toggling the if block with false and true. The program will just continuously do some redisgraph calls and not parse the response in one case, will parse the response in another case.
When the above program is running, do:
curl -sK -v http://localhost:8080/debug/pprof/heap > heap.out
go tool pprof heap.out
(pprof) lines
(pprof) web

In the case when we ignore the output of Query function, we get a memory leak in the pprof output. When the response is parsed and the record are read, there is no leak reported in the pprof output.
The docs do not mention anything about reading the Query function output. There is no close function on the QueryResult struct either, if I have to call it via defer. There is no other function except Query (like an Exec in the SQL) which I can do to not read results.
I will be happy to provide any other debugging information if you want.

To minimize the effects of this leak, I tried to create a single instance of the Graph object, via the following code. But it consistently crashes, proving that Graph object as returned by rg.GraphNew is not thread-safe. This is an important information that must be documented. But the docs do not mention about this.
type t struct {
	graph rg.Graph
}

var p *t

main() {
	conn := pool.Get()
	p = &t{
		graph: rg.GraphNew("test-graph", conn),
	}
	go f(1)
	go f(2)
}

func f(n int) {
	for {
		_, err := p.graph.Query("MATCH (X) RETURN X")
		if err != nil {
			logrus.Fatal(err)
			return
		}
		logrus.Println("Thread: ", n)
	}
}

To minimize the effects of this leak, I tried to create a single instance of the Graph object, via the following code. But it consistently crashes, proving that Graph object as returned by rg.GraphNew is not thread-safe. This is an important information that must be documented. But the docs do not mention about this.
type t struct {
	graph rg.Graph
}

var p *t

main() {
	conn := pool.Get()
	p = &t{
		graph: rg.GraphNew("test-graph", conn),
	}
	go f(1)
	go f(2)
}

func f(n int) {
	for {
		_, err := p.graph.Query("MATCH (X) RETURN X")
		if err != nil {
			logrus.Fatal(err)
			return
		}
		logrus.Println("Thread: ", n)
	}
}

Hi @sankarp-kavach, Thank you for reporting this, I'll update here on my progress

Hi @sankarp-kavach, Thank you for reporting this, I'll update here on my progress

I did some more analysis and found that we embed a connection object inside the graph response struct which is possibly what is causing the leak. We seem to have needed the conn object to parse the response body. But once the parsing is done, after that we do not require the conn object. But we did not had a way to destroy/finalise that connection.
Also, I could be wrong as my debugging was not very thorough.

I did some more analysis and found that we embed a connection object inside the graph response struct which is possibly what is causing the leak. We seem to have needed the conn object to parse the response body. But once the parsing is done, after that we do not require the conn object. But we did not had a way to destroy/finalise that connection.
Also, I could be wrong as my debugging was not very thorough.


Change value doesn't work when enableTime is false

Hello guys, i have problems with getting value from input after i select the date. Here is the error which i got "Uncaught TypeError: Cannot set property 'value' of undefined"
It only occurs when enableTime is false.

I am also having this problem. Breaks here:
self.hourElement.value = self.pad(
	!self.config.time_24hr ? (12 + hours) % 12 + 12 * (hours % 12 === 0) : hours
);


Search mis-calculates string size

Entering a team number or name in the search bar exposes a bug: the string size is being mis-calculated by 1. This means you need to enter an extra character in order for the full string to be searched.
For example, if you want to search for any team with the number "1" in it, you have to enter "1X" where X is any character. If you want to search for team "12345" you have to enter "12345X" where X is any additional character (including space).

You are right.
Please follow trimox/angular-mdc-web#1541


feat(interview-prep): Converting and transferring Rosetta problems

[ ] I have read freeCodeCamp's contribution guidelines.
[ ] My pull request has a descriptive title (not a vague title like Update index.md)
[ ] My pull request targets the master branch of freeCodeCamp.
[ ] None of my changes are plagiarized from another source without proper attribution.
[ ] All the files I changed are in the same world language (for example: only English changes, or only Chinese changes, etc.)
[ ] My changes do not use shortened URLs or affiliate links.

Closes #XXXXX

@scissorsneedfoodtoo Hey! Here are some Rosetta problems from the curriculum repo. Can you check these out?

@scissorsneedfoodtoo Thank you for the review! I think the changes you suggested are correct. I have made these changes. Please check if everything is correct.

Everything LGTM! Will just ask for another review in the gitter chat.

Sure :)

@scissorsneedfoodtoo @thecodingaviator I have done some changes you suggested. Let me know which descriptions to move to the instruction section and if any other changes are needed.

@NitronR Let it be. We'll do it for all challenges together!

@thecodingaviator Changes done.

It's pretty much the same for every test, should we let the tests that the correct type is returned be there or let them go? @scissorsneedfoodtoo

@thecodingaviator, you bring up a good point -- a lot of these tests that check for a function or a type of return value are probably unnecessary. But I think it's alright to leave them for now! They can always be removed in a future PR if we decide to do so. Thank you for being so thorough in your review :+1: :+1:

Alright! Since I already have your approval @scissorsneedfoodtoo , I'm merging

Thanks a lot for all the work @NitronR


test for spec.version update

@gaohoward how best to manage the version, to keep this test fresh? I need some ideas!
currently the tests use Latest, as the default image url, but can we be sure that latest-1 will exist?

@gaohoward how best to manage the version, to keep this test fresh? I need some ideas! currently the tests use Latest, as the default image url, but can we be sure that latest-1 will exist?

I don't have better idea. The latest-1 should exist, if not the test should fail, which is not a bad thing.