Adding typescript typings

Added .editorconfig to force to the project code style;
Updated package.json to reference the external typings definitions and the provided self definitions;
Added a tsconfig.json file to compile and check the definition;
Added the typings.d.ts which contains the definitions of the library for typescript developers;

Some considerations:

The current change will allow that any typescript developer get all the definitions and typings for you library in the moment that he/she installs using npm install or yarn add;
There is some functions that I need to specify the type because I don't know the signature;
You can call me anytime if you need to update that!

Also, I'm not sure if this is something we want to take on ourselves. None of the maintainers are TS users (AFAIK), so we can't say if this is good or not. This probably should continue to live and be maintained on DefinitivelyTyped.

Ok, I got you decision.

I will say if someone from the community wants to come step in and back up the quality of these typings, that would be great. We've done that on Redux for both TS and Flow. But by ourselves, I don't know where to look for any improvements or bug fixes to them.

I understood and I remember to say in the commit message that you can contact me anytime. But you are right too and I can put the definitions on DefinetelyTyped too and don't mix with the current project structure, which could be a plus too.

@danfma Are you going to publish the types on DefinitelyTyped ?
We're working on a project with TypeScript and React Router 4, and are creating a definition file too.
If yours is already finished we would really like to know, and help if needed.

@timdorr I just would like to say that TypeScript definitions are really something frustrating for TypeScript developers when they don't exist.
I understand that not everybody wanna work with these tools, but nowadays statically typed JavaScript is becoming a very popular thing.
Creating a definition file on an evolving API is not something easy, and the first API change sometimes makes definition file broken.
I don't know how, but it would be really appreciable to permit a better collaboration.

@danfma Is it possible to have an access to your repo? Just read-access, we would like to try your definitions, and complete them in case.

@kube Yes, of course! https://github.com/danfma/typed-react-router
The current definition maps to the last sources in the v4 branch, no the published v4.0.0-alpha.6, then some old stuff will be missing. I'm trying to find a better way to publish this.

@kube I'm finishing some changes. When I finished, I advise you.

Ok thanks.

I had started this 18 days ago, based on the alpha-5.
https://github.com/kube/react-router-types
I don't know how much things have changed.
Most of my types were based on the Proptypes.
Maybe we can work together on this to create a definition file properly.

@danfma @kube looks great folks! let's push this to DefinitelyTyped

interface IMatch {
  path: string;
  url: string;
  isExact: boolean;
  params: { [key: string]: string };
}

declare module "react-router/Router" {
  import * as React from "react";
  import {
    History,
  } from "history";

  export interface IRouterProps {
    history: History;
    children?: React.ReactChild;
  }

  export default class Router extends React.Component<IRouterProps, any> {

  }
}

declare module "react-router/MemoryRouter" {
  import * as React from "react";

  import {
    MemoryHistoryBuildOptions,
  } from "history";

  export interface IMemoryRouterProps extends MemoryHistoryBuildOptions {
    children?: React.ReactChild;
  }

  export default class MemoryRouter extends React.Component<IMemoryRouterProps, any> {

  }
}

declare module "react-router/StaticRouter" {
  import * as React from "react";
  import {
    Action,
    Location,
  } from "history";

  export interface IStaticContext {
    action: Action;
    location: Location;
    url: string;
  }

  export interface IStaticRouterProps {
    context: IStaticContext;
    basename?: string;
    location?: string | Location;
    children?: React.ReactChild;
  }

  export default class StaticRouter extends React.Component<IStaticRouterProps, any> {

  }
}

declare module "react-router/Route" {
  import * as React from "react";
  import {
    History,
  } from "history";

  // todo & matchFn
  type TRenderFn = (props: IRouteProps & History) => JSX.Element;

  export interface IRouteProps {
    path?: string;
    exact?: boolean;
    strict?: boolean;
    component?: Function;
    render?: TRenderFn;
    children?: React.ReactChild | TRenderFn;
  }

  export default class Route extends React.Component<IRouteProps, any> {

  }
}

declare module "react-router/Switch" {
  import * as React from "react";
  import Route from "react-router/Route";

  export interface ISwitchProps {
    children?: Route | Route[];
  }

  export default class Switch extends React.Component<ISwitchProps, any> {

  }
}

declare module "react-router/Prompt" {
  import * as React from "react";

  export interface IPromptProps {
    when: boolean;
    message: string | (() => string);
  }

  export default class Prompt extends React.Component<IPromptProps, any> {

  }
}

declare module "react-router/Redirect" {
  import * as React from "react";
  import { Location } from "history";

  export interface IRedirectProps {
    to: string | Location;
    push?: boolean;
  }

  export default class Redirect extends React.Component<IRedirectProps, any> {

  }
}

declare module "react-router/withRouter" {
  import {
    ComponentClass,
    StatelessComponent,
  } from "react";

  type ReactComponent<TProps> = ComponentClass<TProps> | StatelessComponent<TProps>;

  import {
    History,
  } from "history";

  export interface IRouter extends History {
    match: IMatch;
  }

  export interface IRouterProps {
    router: IRouter;
  }

  export default function withRouter<TProps>(BaseComponent: ReactComponent<IRouterProps & TProps>): StatelessComponent<IRouterProps & TProps>;
}

declare module "react-router/matchPath" {
  interface IOptionsProps {
    exact?: boolean;
    strict?: boolean;
  }

  export default function matchPath(currentPathname: string, targetPath: string, options?: IOptionsProps): IMatch;
}

declare module "react-router" {
  export { default as Router } from "react-router/Router";
  export { default as MemoryRouter } from "react-router/MemoryRouter";
  export { default as StaticRouter } from "react-router/StaticRouter";

  export { default as Route } from "react-router/Route";
  export { default as Switch } from "react-router/Switch";

  export { default as Prompt } from "react-router/Prompt";
  export { default as Redirect } from "react-router/Redirect";

  export { default as withRouter } from "react-router/withRouter";
  export { default as matchPath } from "react-router/matchPath";
}

Updates for<EMAIL_ADDRESS>Hope it in react-router it, publishing to @types is not a good idea for maintains.
You know, react-router change apis so many times.

It's a bad idea to embed manually-created typings on a project of this size.
If somebody does not update the definition file when modifying the API, the embedded definition file will be unsynced with the API. (and we won't be able to use a separate definition, as it will be embedded)


[Bug]: Alternative HTTPS Port does not stick on desktop app. Reverts to HTTPS 443

Checks before filing an issue

[X] This issue doesn't reproduce on web browsers (such as in Chrome). If it does, issue reports go to the Mattermost Server repository.
[X] I have checked the issue tracker and have not found an issue that matches the one I'm filing.
[X] This issue is not a troubleshooting question. Troubleshooting questions go here: https://forum.mattermost.com/c/trouble-shoot/16.
[X] This issue is not a feature request. You can request features and make product suggestions here: https://mattermost.com/suggestions/.
[X] This issue reproduces on the most recent stable version, or the most recent prerelease version of the Mattermost Desktop App.
[X] I have read the contribution guidelines.

Mattermost Desktop Version
5.5.1
Operating System
Windows 11
Mattermost Server Version
9.2.2
Steps to reproduce
Port forward a port to 443 of the Mattermost Server. Add the server in the desktop app, it will initially work but any refresh or closing and reopening of the program results in it reverting back to https://sub.domain.com instead of https://sub.domain.com:44X
Expected behavior
It is expected to behave the same way as the mobile apps and web browserr which have always worked without issue.
As far as I know this has never worked on the dekstop app and app images.
Observed behavior
Add the server in the desktop app, it will initially work but any refresh or closing and reopening of the program results in it reverting back to https://sub.domain.com instead of https://sub.domain.com:44X
Log Output
No logging

Additional Information
No response

It's likely that https://sub.domain.com is your configured SiteURL correct? I believe if the system is able to hit your server via the SiteURL once it's gotten that, it will always use that URL to connect.
That's actually a feature, not a bug ;)
The Desktop App prefers to use the configured SiteURL because there are a lot of small things that depend on it, such as detecting whether a URL is outside the app or not.
Hope this helps.

My site is https://sub.domain.com:449
Kind of makes the dekstop app useless, but thanks for confirming, I'll just use the browser

@chiefplato If you change your configured SiteURL to https://sub.domain.com:449 the problem should go away.


use toString method to retrieve proper type

This utitlizes the toString method of the query parser to extract a string value from the request parameters. This resolves #574
https://expressjs.com/en/api.html#req.query

Pull Request Test Coverage Report for Build 2808

0 of 0   changed or added relevant lines in 0 files are covered.
No unchanged relevant lines lost coverage.
Overall coverage remained the same at 66.91%

Totals

Change from base Build 2806:
0.0%

Covered Lines:
2540

Relevant Lines:
3576

💛  - Coveralls


Incompatible with the latest pymongo

keyword 'safe' is not expected in save operations since 3.0 version of pymongo

  File "/usr/local/lib/python2.7/dist-packages/flaskext/mongoalchemy/__init__.py", line 264, in save
    self._session.insert(self, safe=safe)
  File "/usr/local/lib/python2.7/dist-packages/mongoalchemy/session.py", line 172, in insert
    self.add(item, safe=safe)
  File "/usr/local/lib/python2.7/dist-packages/mongoalchemy/session.py", line 188, in add
    return self.flush()
  File "/usr/local/lib/python2.7/dist-packages/mongoalchemy/session.py", line 414, in flush
    result = op.execute()
  File "/usr/local/lib/python2.7/dist-packages/mongoalchemy/ops.py", line 97, in execute
    return self.collection.save(self.data, safe=self.safe)
  File "/usr/local/lib/python2.7/dist-packages/pymongo/collection.py", line 1898, in save
    write_concern = WriteConcern(**kwargs)
TypeError: __init__() got an unexpected keyword argument 'safe'

Also had this issue and had to stick with an older version. Would be nice if this was addressed.

Unfortunately this is a bug with MongoAlchemy. I will pin the pymongo version to ensure that everything works fine, and once it's fixed in MongoAlchemy, I will fix it here as well.


Test with optional RTTI and exeption support

Put support for disabling RTTI introduced in #1670 under test and resolve failures.
Allow use of C++ standard library without exceptions (revisiting #1610) and put under test.

Coverage remained the same at 99.625% when pulling b9694f42ccc9f99585c5cf0390ec7e8159fac7ba on thetic:has-feature into 75bbd80e128b0b6c1396c8d5e2d574d15ce95e15 on cpputest:master.


New commits never released?

It looks like some changes were made to fix issues #8, #9, and #10 but were never released. When can we see this update drop? It contains functionality that better matches Sublime's plugin and would be very nice to have.

Hey @craigjennings11, thanks for the reminder! With my job change and everything this kinda got lost. I finally found time to get everything updated and added a bunch of config options to it as part of that. Check out version 2.0.0 and let me know if there are any issues. I'll try to maintain this more regularly now 🎉


Remove unneeded configuration in buildPlugin

Spotbugs reporting is being enabled by default in https://github.com/jenkins-infra/pipeline-library/pull/121, update to parent pom 4.x to use spotbugs instead of findbugs.

Closing stale PRs of mine


Update sites.yml

Important: Please read all instructions carefully.
Select the appropriate category for what this PR is about
This PR is:

[x] Adding a new domain
[ ] Updating existing domain size
[ ] Changing domain name
[ ] Removing existing domain from list
[ ] Website code changes (512kb.club site)
[ ] Other not listed

Do not tick a checkbox if you haven’t performed its action. Honesty is indispensable for a smooth review process.

[x] I used the uncompressed size of the site
[x] I have included a link to the GTMetrix report
[x] The domain is in the correct alphabetical order
[x] This site is not a ultra lightweight site
[x] The following information is filled identical to the data file

- domain: lukerissacher.com
  url: https://lukerissacher.com/blog
  size: 88.2
  last_checked: 2022-01-29

GTMetrix Report: https://gtmetrix.com/reports/lukerissacher.com/aNR8rSW5/
(Link is the blog home, but individual posts and site root page are also under 512kb)

GT Metrix shows 161KB, not 88.2 - I think you added the compressed size, not UNCOMPRESSED.  Please update and re-submit.

Sorry. Thought GTmetrix showed uncompresed but I guess that's hidden on the Waterfall tab. Fixed.


Feature Request: How to evaluate Azure Open AI Assistant

Currently in config we can provide only Open AI assistant ID.
It would be good if we can also provide Azure Open AI assistant ID and evaluate it,
Example -
providers:

id: azureopenai:assistant:asst_fEhNN3MClMamLfKLkIaoIpgB
config:
apiHost: 'xxxxxxxx.openai.azure.com'

This does not work and gives below error -

npx promptfoo@latest eval
C:\Users\Jagrati.Modi\AppData\Local\npm-cache_npx\81bbc6515d992ace\node_modules\promptfoo\dist\src\providers.js:173
throw new Error(Unknown Azure OpenAI model type: ${modelType}. Use one of the following providers: azureopenai:chat:<model name>, azureopenai:completion:<model name>);

Try with this

id: azureopenai:chat:csdep-gpt4
config:
apiHost: cs-oi-yyyyyy-testing.openai.azure.com
apiKey: 984681cXXXXXXXc20d22YYdf2a7

Try with this

id: azureopenai:chat:csdep-gpt4
config:
apiHost: cs-oi-yyyyyy-testing.openai.azure.com
apiKey: 984681cXXXXXXXc20d22YYdf2a7

Isn't this only for a model deployment, not an assistant?

#577 adds support for OpenAI assistants on Azure!

Published in 0.49.0
https://promptfoo.dev/docs/providers/azure/#assistants


Ability to disable weight / volume / count

There should be an option to outright disable item weights, volumes or counts, such that they are never displayed and never have any effect.

Resolved via commit 7eb376d4add39b02bf1d706e2e2d8463781fb156.


Add #assert_nothing_raised assertion

A counterpart to #assert_raised that asserts that the block raises no exception.

Also fix the documentation of #assert_raised.

I don't think this is necessary. An assertion on not raising exceptions is basically the same as an assertion on the output: assert this.works or assert_equal this.works, nil for example.

Necessary? No. Useful? Maybe. Expressive? Yes—but I also mostly use test frameworks that are more expressive than cutest, and that’s sort of the point of this PR.
In soveran/micromachine#27, I’m explicitly wanting to test that a regression does not improperly throw an exception. Yes, I could write my own begin/end block in the test for this purpose, but IMO good tests are expressive tests—and this increases the expressiveness of the cutest framework. Writing an assertion on the output masks the fact that I am asserting that there’s no exception thrown, which is different than asserting a return value. I could also put a comment, but that also feels like a loss in expressiveness of the code itself.

Having thought more about it, I think an assertion on not raising an exception is silly. It's an assertion you'd have to do on basically every test, save the tests you do with assert_raise.
You could even argue these assertions are already done implicitly:
test.rb
test { raise "hi" }

$ cutest test.rb
  test:
  line: test { raise 'foo' }
  file: /tmp/.psub.9KvPWcY6dy +1

RuntimeError: foo

You could argue that this is “silly” and even handled by the default assert. If one were to put forward that tests are a form of documentation, the expressiveness provided by this “silly” assertion is quite useful in documenting an expectation.
Ultimately, I don’t care whether this is added to cutest. There’s some neat ideas here, but I find cutest insufficiently expressive for my projects. I modified another project’s cutest tests when I found a bug and contributed a fix and feature expansion, and I thought that the addition that I made to that project’s test/helper.rb for expressing a particular test was more useful than an equivalent comment, so I offered it here.

@halostatue Having been a heavy PDF::Writer user in the past, I'm honored to read PRs from you. Thank you.
I don't agree with @britishtea to call this silly, but I do think that the assertion is implied. The expresiveness you aim for should be achieved by means of the test name:
test "does not raise when given X argument" do
  foo.bar(1)
end

Thanks. You are right that the name/description of the test can express this well, and that may be the guidance that cutest wishes to give on this (which would suggest taking your example and putting it in documentation) because there is a very spare design intent around cutest (that’s a compliment).
I tend to prefer richer, more expressive test frameworks in general, complete with assert and refute or must and must_not, which is why I like having an assert_nothing_raised counterpart to assert_raises. (It also, to me, clarifies errors in the test as opposed to errors in the code when there is a failure. But I also recognize that is probably bias more than anything.)

This reminded me of @zenspider's classic post on @tenderlove's implementation for assert_nothing_raised:
def assert_nothing_raised(*)
  yield
end

That said, I also think that this is implied and, the method should be added to projects when/if needed for documentation or compatibility.

Since I just got dragged into this mess, rant on:

Necessary? No. Useful? Maybe. Expressive? Yes

Let's break this down:

Necessary? No.

We agree on this being unnecessary.

Useful? Maybe.

Useful? No. This type of assertion provides a false sense of security (the water wings of the testing world). It implies that side effects and return values have been checked or aren't important (always false, otherwise why write the code?). It falsely bumps coverage metrics, if you care about such metrics. In other words, it only makes it look like something has been tested, when in fact it hasn't had any testing applied to it at all.

Expressive? Yes

Expressive? Hell no. The act of expression was done by writing tests in the first place. It isn't even an implied act of expression as @xymbol suggests above. It is the explicit contract of every test framework worth using that any unhandled exceptions are an error. By writing tests at all you're explicitly stating "there are no unhandled exceptions via these pathways".
If you do implement this assertion, stick with the plain yield and maybe add a warning to get off of the assertion (I don't know if cutest is written to be compatible with any other test frameworks and only change the run model or not--@xymbol said compatibility might be an issue: with what?).
Please go (re-)read my blog post and take it to heart that empty implementations should never make any (worthwhile) test pass.

@zenspider Thanks so much for your valuable input. -- And, sorry to drag you into it. :-)
Just to clarify my mention: I was referring to the example from your post where assert_nothing_raised gets re-implemented to make existing tests in Rails pass. I would not add this to cutest but, I would as a helper in case an existing suite asked for it.

Gotcha. Thanks for clarifying.

I agree that this is unnecessary. Mostly because of @zenspider 's input and partly because I really like the minimalism of Cutest. I'd even suggest Cutest to have only a couple of assertion methods:

assert
assert_raises
assert_equal (remove this one)

And leave other, "more expressive", assertions to a separate and optional gem that could have things like:


Cleanup integration tests to get more coverage, less randomness

Recently, a bug was introduced in PR #5132  that led to bad results when executing queries that involved indexed and non-indexed columns in a certain combination. We had a query in our integration test that tested this combination, but then queries are run at random from the query file (I think it is 100 queries out of 10k). So, some runs of travis would fail, but a re-run could well pass. The bug was discovered in LinkedIn's test environment (where the mvn test command is run repeatedly and multiple failures were noticed). The bug was fixed in PR #5328
So, we had the test for it, and still could not catch the bug.
I did a test on my desktop to see how much time would be taken if we enabled all 10k queries to be run, and it came to about 8 hours!
 Covered by FlakyConsumerRealtimeClusterIntegrationTest -->
                <exclude>**/RealtimeClusterIntegrationTest.java</exclude>
                <!-- Covered by ConvertToRawIndexMinionClusterIntegrationTest -->
                <exclude>**/HybridClusterIntegrationTest.java</exclude>
              </excludes>

But the remaining tests still add a lot of time.
The goal is to be able to discover problems early, preferably before merging. Some randomness cannot be avoided (e.g. generation of data), so we will live with that.
One way to get this is to comb the 10k queries to select a few hundred that can be enough to detect all issues. And then we add queries to this selected list as we find more bugs.
Another way is to increase travis time to whatever number of hours needed to get all 10k queries to run. This is probably not desirable, and will slow us down.
Another possibility is to set up a regular run of the full stuff (say, once a day) so that we catch the issue next day. But then we will still be left with the commit in the master.
Thoughts?

Vote for this solution: One way to get this is to comb the 10k queries to select a few hundred that can be enough to detect all issues. And then we add queries to this selected list as we find more bugs.
We can select some queries from these 10k queries, and also add some uncovered query patterns (e.g. selection queries)

Vote for this solution: One way to get this is to comb the 10k queries to select a few hundred that can be enough to detect all issues. And then we add queries to this selected list as we find more bugs.
We can select some queries from these 10k queries, and also add some uncovered query patterns (e.g. selection queries)

@jackjlli isn't that what you have done by toning down 10k to 500?

@jackjlli Should we keep this issue open to track all the PRs improving the test coverage?

@Jackie-Jiang Yes, we should keep it open. The issue auto closes itself when some PR is merged.

@mcvsubbu @jackjlli We might need to further reduce the size of the query file. Currently running all queries in the query file takes more than 2 minutes (the comparing database H2 is slow), and we have 2 query files per integration test. In the github-actions, the integration test suite takes longer than 60 minutes to finish now.


Angle tool rounding issues

Prerequisites

[x] Are you running the latest version?
[x] Are you reporting to the correct repository?
[x] Did you perform a cursory search?

For more information, see the CONTRIBUTING guide.
Description
When moving the angle tool entirely, the measured angle changes (~1deg)
Steps to Reproduce

Open the example "allImageTools"
Select angle tool and draw any angle
Move the tool (dragging a line not a handle)

Expected behavior: [What you expected to happen]
The angle shown does not change
Actual behavior: [What actually happened]
The angle changes
Codepen With Reproduction of Issue:
The issue seems to come from rounding (Math.ceil) of the current handle position.
See Ln 100-103 in:
https://github.com/cornerstonejs/cornerstoneTools/blob/master/src/imageTools/angleTool.js
Removing the Math.ceil fixes the issue.

This makes sense. If you change the position and the coordinates overall rounding moves the measurements a greater difference, you could see a shift.
@knopkem, Would you be up to PR'ing this change? Ideally against the vNext branch so we don't need to remember to port it over.

sure, will do.


proguard error

in android studio The toast show always . the textView  is null ,please help me! thank you!
this is my code

and this is my proguard-rules.rpo
-optimizationpasses 5
-dontusemixedcaseclassnames
-dontskipnonpubliclibraryclasses
-dontpreverify
-verbose
-optimizations !code/simplification/arithmetic,!field/,!class/merging/
-dontwarn
-keep public class * extends android.app.Activity
-keep public class * extends android.app.Application
-keep public class * extends android.app.Service
-keep public class * extends android.content.BroadcastReceiver
-keep public class * extends android.content.ContentProvider
-keep public class * extends android.app.backup.BackupAgentHelper
-keep public class * extends android.preference.Preference
-keep public class com.android.vending.licensing.ILicensingService
-keepclasseswithmembernames class * {
native ;
}
-keepclasseswithmembers class * {
public (android.content.Context, android.util.AttributeSet);
}
-keepclasseswithmembers class * {
public (android.content.Context, android.util.AttributeSet, int);
}
-keepclassmembers class * extends android.app.Activity {
public void *(android.view.View);
}
-keepclassmembers enum * {
public static **[] values();
public static ** valueOf(java.lang.String);
}
-keep class * implements android.os.Parcelable {
public static final android.os.Parcelable$Creator *;
}
-keep class butterknife.** { ; }
-dontwarn butterknife.internal.*
-keep class **$$ViewBinder { *; }
-keepclasseswithmembernames class * {
@butterknife.* ;
}
-keepclasseswithmembernames class * {
@butterknife.* ;
}

my studio version is <IP_ADDRESS>

i use this below it work:
Butterknife
-dontwarn butterknife.internal.**
-keep class butterknife.** { *; }
-keep class **$$ViewInjector { *; }
-keepclasseswithmembernames class * {
@butterknife.InjectView ;
}
-keepclasseswithmembernames class * {
@butterknife.OnClick ;
@butterknife.OnEditorAction ;
@butterknife.OnItemClick ;
@butterknife.OnItemLongClick ;
@butterknife.OnLongClick ;
}

in studio you can copy the java file and xml file (the file in libary )in you progect is ok

@flyou  you mean which one? can you tell me the file path?

ProGuard problems are not specific to this library and fall under usage questions since ProGuard is a completely optional thing. I would ask on StackOverflow because you'll get a lot more people who can deal with the situation and figure our what's wrong rather than just the few watching the project.


doc link

Codecov Report

Merging #18 into master will increase coverage by 0.16%.
The diff coverage is n/a.

@@            Coverage Diff             @@
##           master      #18      +/-   ##
==========================================
+ Coverage   98.23%   98.39%   +0.16%
==========================================
  Files          13       13
  Lines         624      624
  Branches       46       46
==========================================
+ Hits          613      614       +1
+ Misses         11       10       -1

Impacted Files
Coverage Δ

src/core/pool.ts
83.05% <0%> (+1.69%)
:arrow_up:

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 93725b5...0ca9238. Read the comment docs.


Added TreeNode (tree' node datastructure) and binary search tree data structure implementation in java

Please add a working code example. Like add a main function and perform some actions there also please move the 2 files into a separate directory inside Java folder.

can you put the code in /codes
and do the fixed mentioned in the above comment


CASSANDRA-16679 HintedHandoffAddRemoveNodesTest now accounts for the fact that StorageMetrics.totalHints is not updated synchronously w/ writes

patch by Caleb Rackliffe; reviewed by ? for CASSANDRA-16679

https://app.circleci.com/pipelines/github/maedhroz/cassandra?branch=CASSANDRA-16679-4.1

Committed in https://github.com/apache/cassandra/commit/adb01284852a6c7943f7038dcee3cae101f47d23


Email for Subscribing

users entering their mail and clicking the button should receive a subscription confirmation email to their valid mail ids. I will implement by creating an api in the app directory.

assigned


Creation of the event in Pretalx

Done by Mariatta, Maria José And Elka:
https://pretalx.com/orga/event/pyladiescon-2023/


Add support for ggt open command

Another new command joining the ggt entourage 🥳
-- will probably need a new design at some point too @mdamy
This pr adds support for ggt open, which takes in a subcommand of either

logs
permissions
data [modelApiIdentiifer]
schema [modelApiIdentifier]

Some requirements for ggt open to work:

the user must have already initialized their sync.json file before trying to run ggt open (ie they must've already run ggt dev or ggt sync) to run ggt open (similar to how ggt pull/push work)
a subcommand must be passed along with open, otherwise subcommand options and reference to --help will be shown and the process exits
for data and schema subcommands a valid modelApiIdentifier must be passed, otherwise

if an option was passed but is not a valid apiIdentifier then the closest suggestion is shown
if no option was passed the user is told to pass one in or run the command with --show-all to select from available options

In order to get and display all possible models to select from, we POST to the /api/graphql endpoint rather than the usual /edit/api/graphql endpoint. To generate the proper graphql types for this gadgetMeta query I've copied over the app.graphql file over from gadget api-- however this resulted in quite a lot of lines being added! I wasn't sure if it would make more sense to only copy over the types needed to make this particular getModels query, or to stick to the current behaviour which is "this *.graphql file is the exact same as the one on gadget side".
cc @scott-rc for your thoughts and opinions :)

some comments; I think it'd be good to talk to @scott-rc on how best to handle the new client

Refactored to create a new Client for the api/graphql endpoint! Most of the file diffs are a result of this + restructuring services/app folder into separate edit and api folders, and moving client and error(figured this can be shared) up a level:


fix video texture on iOS

The videoTexture would not automatically play on iOS - turns out to be a simple fix.

Hi there, does that mean Video Textures are working in Quick Look as well?

No, I don't think USDZ supports video textures at all, and that's the only format Quick Look supports currently. FYI @grorg.

Yeah I thought so. I'm wondering why it's mentioned in the release page 3.1.0?

iOS != QuickLook. This fixed it so the textures play in 3D mode on iOS. AR is a relatively narrow use case compared to what we offer for general 3D on the web.

Aside – USD (and USDZ) do support video textures. The limitation is Apple's Quick Look not supporting these textures. Ideally Safari would implement the WebXR API, so that libraries like modelviewer, three.js, and babylon.js could provide video texture support in AR/VR/XR independently.


Update onnxruntime version check

Hello,
Thank you very much for these great bindings - they are very intuitive to use and have been working great so far. I tried updating onnxruntime to 1.14.1 based on the changelog provided at https://github.com/pykeio/ort/releases/tag/v1.14.2 and it fails as a check still expects 1.14.0.
I changed that check to 1.14.1 and can confirm it allows running the latest version of onnxruntime. Opening a small PR to propose the same changes to the upstream repository.
Thank you!

Oops, nice catch!


yarn build fails

Bug Report
Steps

Pull the latest repo version
yarn install
yarn build

Expected Result
Build succeeds
Actual Result

[10:32:55] Error: Command failed: cross-env NODE_ENV=build-es babel /.../Semantic-UI-React/src -d /.../Semantic-UI-React/dist/es
Error: Requires Babel "^7.0.0-0", but was loaded with "6.26.3". If you are sure you have a compatible version of @babel/core, it is likely that something in your build process is loading the wrong version. Inspect the stack trace of this error to look for the first entry that doesn't mention "@babel/core" or "babel-core" to see what is calling Babel. (While processing preset: "/.../Semantic-UI-React/.babel-preset.js")

Version
0.82.5
Anyone else experiencing this? I tracked down that it maybe because of react-static installing older version of webpack-cli, which in turn pulls in older babel-core with exact version that fails

What OS are using? Build was successfully passed on Ubuntu recently, however there can be issue with Windows.

@layershifter I'm running OS X 10.13.5 - could you also write down node, yarn and other versions that MAY potentially impact this?

May be you have babel installed as global?

@layershifter babel or babel-cli or some other specific package?

One of them. When you're typing babel in terminal and run this command, what you will receive?

Both are not found. Do you know anyone on the team with Mac who could potentially test it?

@bytasv can you please pull latest changes and try again?

@layershifter any updates on this one?

@levithomason sorry for pinging directly, but maybe you can take a look as well? This is kinda blocker not allowing to build :/

@bytasv sorry, but I don't have any idea why it happens. I know that Levi uses Mac and we deployed the new release recently :thinking:

I pulled the latest master (79d5da8eb), removed node_modues, ran yarn, then yarn build and all is well on my 2018 MacBook.  It was also working for me just before this commit SHA as well as on versions before 0.83.0.
It looks like you have a rogue babel 6.26.3 that is getting loaded from somewhere on your PATH, in your node_modules, or possibly in a directory above your project.  Here's the relavant portion of the error:

Error: Requires Babel "^7.0.0-0", but was loaded with "6.26.3". If you are sure you have a compatible version of @babel/core, it is likely that something in your build process is loading the wrong version. Inspect the stack trace of this error to look for the first entry that doesn't mention "@babel/core" or "babel-core" to see what is calling Babel. (While processing preset: "/Users/vytautas/Projects/Semantic-UI-React/.babel-preset.js")

When our preset is called, the version loaded on your machine is incorrect for some reason.    Try these steps:

Ensure you have no babel on your path globally: which babel should return babel not found.
Remove any possible global modules:$ npm uninstall babel @babel-core @babel-cli --global
$ yarn global remove babel
$ yarn global remove @babel-core
$ yarn global remove @babel-cli

Nuke your node_modules in Semantic UI React: rm -rf node_modules
Reinstall: yarn install
Run a build: yarn build

Lastly, I would google around and punch stuff, eventually you'll find the answer and feel great.  Apologies your having difficulties with this.  Let us know if we've overlooked anything or if there is a repro and we'll gladly reopen this issue.  Best of luck 🙇

Ah, there's also the babel-node cli I would check and scrub for.  Again, best of luck!


feat: add new SerialAPI Setup commands

These were found in the Gecko SDK sources but are not documented yet. The controller methods now switch between the 8 and 16 bit variants of the get/set powerlevel methods depending on support.

@zwave-js-bot approve


Find object location in Python

Hi Dustin,
I want to get the locations of the objects that the system found in the image for object counting , however I could not find the right way to pull location variables from C++ source code.
Could you please give me advice about how to do that ?

The list of detection structs returned by detectNet.Detect includes members for the coordinates.  See detectNet.Detection class under here:
https://rawgit.com/dusty-nv/jetson-inference/python/docs/html/python/jetson.inference.html#detectNet

From: Mesut Nafiz Şimşek<EMAIL_ADDRESS>Sent: Thursday, May 28, 2020 7:15:59 PM
To: dusty-nv/jetson-inference<EMAIL_ADDRESS>Cc: Subscribed<EMAIL_ADDRESS>Subject: [dusty-nv/jetson-inference] Find object location in Python (#591)
Hi Dustin,
I want to get the locations of the objects that the system found in the image for object counting , however I could not find the right way to pull location variables from C++ source code.
Could you please give me advice about how to do that ?
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHubhttps://github.com/dusty-nv/jetson-inference/issues/591, or unsubscribehttps://github.com/notifications/unsubscribe-auth/ADVEGK42MC6ZPSHTUHIESH3RT3WC7ANCNFSM4NNRK2XA.

thank you man , you are hero


Gateway can be omitted from pool spec

This change allows the Gateway to be omitted from the Pool, preventing an error. Also, prior to this change, Gateway was required when specifying pool.spec.addresses. This change makes gateway optional when specifying pool.spec.addresses.
We took this opportunity to move what we considered business logic out of the pool utility package, and brought it back closer to the other business logic in the controller. The gateway is conditionally added to the list of in use IPs in the controller.
fixes: #89

Sorry, might have been the wrong order to merge these... Could you rebase this one please?

We expected a conflict, NP. Rebased, should be good now.


No new classes are created since JIT install

What version of @tailwindcss/jit are you using?
v0.1.6
What version of Node.js are you using?
v15.7.0
What browser are you using?
Chrome
What operating system are you using?
macOS
Reproduction repository
I am building on Elixir/Phoenix stack
Ever since installing the JIT installer, no new classes are being generated.  I can add a new class <div class"text-2xl">text and it will only be regular sized.  But if I use a class that was already generated before the JIT install, such as "text-xl", then it works fine.
I am using the Elixir framework called Phoenix, which runs Node and handles all JS-related tasks automatically, only requiring the developer to write Elixir and HTML.  Many Phoenix developers use Tailwind, and it works very well "out of the box" for our stack.  It's only been since I installed the JIT compiler (using the instructions on the GitHub readme), that this issue has been occurring.

Simply removing the JIT compiler from postcss.config.js and returning to plugins: { tailwindcss: {} ... } resolves the issue for me.  So either JIT breaks Phoenix compatibility somehow, or the installation instructions here are not sufficient.  I will keep looking into the issue and report back here with any findings.

Hey! Please provide a reproduction repository so we can actually clone it down and troubleshoot it.

Going to close since a reproduction was not provided, happy to help though if you can open a new issue that includes the required field, thanks ❤

https://github.com/rktjmp/phx-tailwindcssjit
Here is a basic repro, but phoenix comes with some baggage (needs postgres, etc, you probably need a docker repro really).
Not sure how much of it is tailwind vs phx.
It actually does work, sort of:

It does generate code for the disabled:opacity-75 example
It doesnt generate code for the custom colour or positioning ([...] syntax).
It only updates when editing the css file instead of noticing template changes

not really a tw issue (I think?)

it doesn't apply any "reset css"

doesn't replace my "@tailwind base" line in css file, not sure it these are still needed

Note that Phoenix uses webpack4 which may be an issue.
Willing to do the heavy lifting where I can, but not quite sure where I should be looking, webpack/js-builders not really my jam.
Probably worth renaming this issue to something like "Phoenix integration doesn't generate all classes" or something since that's what it's really about.

Any classes generated before the JIT install work fine for me.  It's only new classes added after the JIT install, which are not generated.  An example repo should be simple if you have Erlang/Elixir/Phoenix installed, just use run the app generator "mix phx.new app_name" at CLI.

This is likely an issue with the installation instructions missing a step which is required for other frameworks such as Phoenix.


fix: flame chart

Flame chart layout get broken (the graph gets overflow) with small data reported in https://github.com/apache/echarts-examples/pull/71#issuecomment-1682739845.
This PR is the fix

@plainheart Hi, could you please review this PR? Thank you.


Enhance long comments

Right now, long comments can be boxed or open, i.e.:
***************************
* This is boxed.          *
***************************

or
;
; This is open.
;

Each comment is a contiguous block in the generated sources.  Because comments are associated with file offsets, you can't have two in a row.
What I'd like to do is fake it by having some way to specify that a line should be left totally blank.  For example:
; This is comment #1.

; This is also comment #1, but it looks like comment #2.

This gives the same aesthetic benefits as having multiple comments, or allowing the user to insert blank lines, without actually changing the way things are put together.
The question is how to specify it.    For example, we could define a set of embedded codes that would do things like:

Indicate that a line should be completely blank.
Start or stop "boxed" mode.
Specify that a line of asterisks should be printed (currently, in box mode, you just put a '*' on a line by itself).
Change the width (affects boxing and line-wrap).
Specify that text is a URL, for the benefit of the HTML exporter.
Change text or background color, for the HTML exporter.  (I feel like this could go badly for the world.)
Note that a word is a symbol, so that the refactoring rename updates it automatically when you rename the symbol.

This feels a lot like BBCode, which I'm not overly fond of, but is relatively simple to handle.

Additional ruminations...
Steam game guides use a similar system, with [bracketed]stuff[/bracketed] for formatting.  So it's certainly a proven approach.
For backward compatibility and simplicity we'd probably want to have an "enable fancy formatting" checkbox.  If not checked, you get the old format style.
The refactoring-rename symbol reference is probably the most practically useful thing in the list, since it allows you to discuss symbols without worrying about them getting renamed, but it's also the hardest thing to get right.  The other items are either purely string formatting items, or things that only the HTML converter cares about.
So the BBCode / Steam approach would be:

Plain text is just flowed normally.
[width=40] sets the line-wrap width to 40.
[box] starts a box that maxes out the current line width; [/box] ends it.
[boxchar='#'] sets the box character to '#' (default '*').
[blank] on a line by itself adds a blank line.
[url=example.com]website link[/url], which formats with the URL showing in text output mode, but forms a proper link in HTML output mode.

If we want to get fancy:

[symbol]MySym[/symbol] would get updated during a rename.

We currently allow a little flex in assembly source generation, because some assemblers may want to format things a little differently.  For example, some assemblers allow '*' box comments to be on a line by themselves, while others require them to start with a ';', which effectively reduces the line width by one character.  We don't guarantee WYSIWYG.  We may want to force consistency by formatting with the expectation that a leading ';' is required, which would convert an 80-column box to be 79 everywhere.

Capturing some notes from e-mail...

On Wed, Jan 4, 2023 at 11:24 AM Pontus Berg wrote...
A really easy solution would be to preceed only lines containing text wit the comment marker. So a blank line, would be inserted in the source without the ";".

That could work.  Anybody who really wants a line with a ';' by itself could make it a space followed by a newline instead of just a newline.  This would only work for long comments that are nothing but blank lines though.  If any additional text appears, it would be treated like a general block comment.  So this:
<eol>
blahblahblah<eol>
<eol>
morestuff<eol>

would look like:
;
; blahblahblah
;
; morestuff

rather than:

; blahblahblah

; morestuff

because I think it looks better to have a consistent comment delimiter for the full height of the block.  To get the blank-line effect in the last one you'd need an explicit "no comment delimiter here" sort of thing like what's described in the bbcode-alike.
There are additional user interaction questions if we add a simple "insert blank line" feature, e.g.: if you do it a second time, does the blank line (a) disappear, (b) remain unchanged, (c) become two blank lines?  It's essentially just an auto-edit of the long comment, so the implementation is straightforward whichever way.
One possible source of user confusion would be over "implicit" and "explicit" blank lines.  Some blank lines are generated automatically, e.g. after an instruction that doesn't continue to the following instruction (JMP, RTS, etc.).  We would have a situation where some blank lines can be altered and some can't, with no clear visual distinction between them. It would show up differently in the "Info" window if you clicked on the line, but I'm not sure if some other minor highlighting effect would be useful.

Current proposal:

Checkbox determines whether we use "simple" or "fancy" mode for long comments.
"Simple" mode output is unchanged.

Fancy mode:

Full-comment box-mode is ignored.  Global width sets the initial width.
Default comment delimiter is ';', default box delimiter is '*'.
Most assemblers don't allow '*' to start a line; original Merlin actually requires '*' for full-line comments (the editor shoves anything starting with ';' into the comment column).
We want WYSIWYG formatting in the assembled output.  That's currently hampered by the way the box stuff is handled, and potentially by AppSettings.FMT_ADD_SPACE_FULL_COMMENT. Boxed output should be shown with the leading ';', unless the box char is ';', in which case we reduce the flow width by one character to get correct Merlin '*' output.  In other words, the box width is always line_width-5, but sometimes we suppress the comment delimiter).
Blank lines become blank lines, with no leading comment delimiter.  To get a continuous column of comment delimiters, put a space at the start of blank lines.  (Could have a [noblanks] tag to set the behavior?)
The character '[' is used to start a tag.  Escape with backslash, i.e. "\[".

Fancy mode tags:

[width=nn] sets the line-wrap width.  This is the full length of the line, so the actual number of characters will be line_width-2 to allow a leading '; '.
[box]...[/box] puts text in a box.  This can span multiple lines.  The box character can be specified as an option, e.g. [box char='#'].
[hr] adds a horizontal line, i.e. a line of characters the full width of the field.  The character can be set, e.g. [hr char='-'].  This will cause a line break if it's not on its own line.  This should work inside a box.
[url=example.com]website link[/url] formats a URL.  In text output you see both the URL and the link string, in HTML output you just see the link string.  If the link string is omitted, the full URL will be used for both.
[sym]symbol[/sym] identifies a symbol.  The goal is to have this updated during a refactoring rename.  In HTML output we can make this a link to the symbol definition.

Tags for character style (bold/italic), size, and color are possible but are only of value for HTML output.  Skip those for now.
Fancier structures, like numbered and unordered lists and tables, are of limited value.  Skip.

Available in https://github.com/fadden/6502bench/releases/tag/v1.9.0-dev3


Default port

How can i change the default port to udp/4501?
Many thanks in advance

I have Google'd many combinations including ikev2 change port, ikev2 change port 4500, ikev2 dynamic port with no luck. There's nothing I could do for now.


API key with Storage API returns null

Hello Ryan,
I was trying to follow your example for google cloud storage media upload at
https://github.com/google/google-api-nodejs-client/blob/master/examples/mediaupload.js
I am trying to do upload from server to server as I dont want API key yo be exposed in client programming. However I am always getting null response back. Here is my code for pulling the list of buckets from Project.
var google = require('googleapis');
var async = require('async');
const gApiKey = API_KEY;
var gStorage = google.storage({ version: 'v1', auth: gApiKey });
const gApiProject = PROJECT_NAME;
exports.getBucketList= function(req, res, next) {
var servResponse = new Object();
servResponse.transaction = "getBucketList";

var params = { project: gApiProject  };

async.series(
    [
        function(callback) {

            gStorage.buckets.list(params , function (err, response) {

                console.log('Bucket response', response);
                servResponse.response = response;

                callback();

            });
        }
    ],

    function done (error, results) {

        return res.send(JSON.stringify(servResponse));
    }

);

Is there something needs to be done differently?

Try using a JWT to authenticate and not a API Key. API keys are very old and only work for specific APIs, likely not a shiny new API like Drive.
Here's an example using JWT: https://github.com/google/google-api-nodejs-client/blob/master/examples/jwt.js
and heres more docs on it: https://github.com/google/google-api-nodejs-client#using-jwt-service-tokens

Did this work for you?

Hmm I'm trying to understand the idea behind scope is there any more details on it @ryanseys? Currently i'm trying to authorize for the prediction api if it matters. Is there a list of the googleapis.com I would need to use some where?

Yeah the scope for that is https://www.googleapis.com/auth/prediction  you can find that available here: https://cloud.google.com/prediction/docs/developer-guide?hl=en

Greetings folks!  There's a great NPM module for using Cloud Storage:
https://github.com/GoogleCloudPlatform/gcloud-node#google-cloud-storage
It should be a lot easier to use.  If this doesn't work for you for some reason, please feel free to re-open this issue!

There's also support for using the prediction API:
https://github.com/GoogleCloudPlatform/gcloud-node#google-prediction-api


feature(colors): docs on font/background/fill colors

Description
Added docs to use our various material color utility styles
What's included?

Background color docs
Typography color docs
Iconography color docs

Test Steps

[x] view > Style Guide > Colors
[x] view > Style Guide > Typography
[x] view > Style Guide > Iconography
[x] view > Style Guide > Product Icons

Screenshots or link to CodePen/Plunker/JSfiddle

Fixed TSLint issues
Reorg typography to have code examples inside Header and Body cards.
Everything else LGTM!

@kyleledbetter LGTM 🎸


backgroundImage

Is ther any way to animate the background change?, i'm trying the following:
$("#tag-id").velocity({
                        "background-image": "url('https://upload.wikimedia.org/wikipedia/commons/thumb/2/2f/Google_2015_logo.svg/1200px-Google_2015_logo.svg.png')",
                },
                {
                    duration: 3000,
                }
);

Sadly not - you can use the complete callback (and animate the tween value). Saying that however, in Chrome at least if you have a css transition:background-image 3s; and you change it then it will fade from one to the other over that period of time rather than simply swapping images.


about s3dis dataset

Hello, I encountered an issue during preprocessing S3DIS data, how can I solve it?
(isbnet) root@autodl-container-58ce11bf52-76ea3b1f:~/autodl-tmp/ISBNet-master/dataset/s3dis# python prepare_s3dis.py
Traceback (most recent call last):
File "prepare_s3dis.py", line 158, in
preprocess_s3dis(cfg.data_dir)
File "prepare_s3dis.py", line 143, in preprocess_s3dis
scene_data = read_scene_txt(scene_name, data_dir)
File "prepare_s3dis.py", line 120, in read_scene_txt
pts = np.loadtxt(os.path.join(data_dir + "/" + area, name, name + ".txt"))
File "/root/miniconda3/envs/isbnet/lib/python3.7/site-packages/numpy/lib/npyio.py", line 1148, in loadtxt
for x in read_data(_loadtxt_chunksize):
File "/root/miniconda3/envs/isbnet/lib/python3.7/site-packages/numpy/lib/npyio.py", line 999, in read_data
items = [conv(val) for (conv, val) in zip(converters, vals)]
File "/root/miniconda3/envs/isbnet/lib/python3.7/site-packages/numpy/lib/npyio.py", line 999, in
items = [conv(val) for (conv, val) in zip(converters, vals)]
File "/root/miniconda3/envs/isbnet/lib/python3.7/site-packages/numpy/lib/npyio.py", line 736, in floatconv
return float(x)
ValueError: could not convert string to float: '167.\x1000000'

Hi @MRCHENWJ,
There are a few errors in the S3DIS dataset. To get the dataset working with the current version of ISBNet you need to fix the following erroneous characters:

Line 180389 of Stanford3dDataset_v1.2_Aligned_Version\Area_5\hallway_6\Annotations\ceiling_1.txt
Line 741101 of Stanford3dDataset_v1.2_Aligned_Version\Area_2\auditorium_1\auditorium_1.txt
Line 926337 of Stanford3dDataset_v1.2_Aligned_Version\Area_3\hallway_2\hallway_2.txt

You can use either the lines specified or the following regex [\x00-\x1F] to find these mistakes.
You will also have to remove the underscore in the file name Stanford3dDataset_v1.2_Aligned_Version/Area_6/copyRoom_1/copy_Room_1.txt such that it reads copyRoom_1.txt.
Best,
Roberto


Add GSSAPI auth and host-based auth configuration to security overview doc

The table of security features on the security overview page should be updated for 19.1, now that we have GSSAPI authentication and configurable authentication methods by host.

Good point, @rolandcrosby. Do you think GSSAPI should be mentioned somehow in the body of that page as well?

Good point, @rolandcrosby. Do you think GSSAPI should be mentioned somehow in the body of that page as well?


Julia SDK 0.4 release

Blocking on:

#85
#79

@JuliaRegistrator register branch=release/v0.4

Error while trying to register: Register Failed
@dehann, it looks like you are not a publicly listed member/owner in the parent organization (NavAbility).
If you are a member/owner, you will need to change your membership to public. See GitHub Help

@JuliaRegistrator register branch=release/v0.4

Registration pull request created: JuliaRegistries/General/57841
After the above pull request is merged, it is recommended that a tag is created on this repository for the registered package version.
This will be done automatically if the Julia TagBot GitHub Action is installed, or can be done manually through the github interface, or via:
git tag -a v0.4.0 -m "<description of version>" c8a087dc40a7a6cdfd92cec651c4e71f98e0709c
git push origin v0.4.0


Feat: CustomeProjectType - Share original labels between annotators

Hello, this PR aims to create the feature that the imported dataset contains some original label/span keyword and these labels will be shared across multiple users, while each of them cannot see each others' annotation.
What's changed:
Backend:

backend/projects/models.py: added field shared_org_label in Project model, to enable this feature
backend/projects/serializers.py: changed Project serielizers due to change in model
backend/projects/migrations/0006_customdocumentclassificationproject_shared_org_label.py: changed migration due to change in model
backend/examples/models.py: added field user in Example model, refers to the user_id
backend/examples/migrations/0007_example_user.py: migrate Example
backend/examples/serializers.py: changed example serielizer
backend/examples/views/example.py: adjusted Example view to show all imported examples for admin view, and for each annotator, show the examples corresponded to their id only
backend/data_import/pipeline/label.py: if the project is enabled shared_org_label, then it will create the original categories and span labels for all assigned user -> then we will have the original span keyword annotation for all of them, otherwise it will work normally (imports everything as admin only)
backend/data_import/datasets.py: adjusted follow changes in create function
backend/data_import/pipeline/data.py: added param user to parser when import data
backend/data_import/pipeline/labels.py: adjusted label creation function

Frontend:

frontend/components/project/FormCreate.vue: added new param for Form Creation of Project in FE due to new param in BE
frontend/domain/models/project/project.ts: added new param in project model FE
frontend/pages/projects/create.vue: added new param for project creation page FE
frontend/services/application/project/projectData.ts: added new param for project data

Data format for the new shared_org_label mode:
(The idea is we will create the duplicated examples for each user, and show them only the texts corresponded to their id. Then they will see the original span keywords separately with each other)
{"text": "Find a flight from Memphis to Tacoma", "entities": [[0, 26, "City"], [30, 36, "City"]], "cats": ["flight"], "user": 1}
{"text": "Find a flight from Memphis to Tacoma", "entities": [[0, 26, "City"], [30, 36, "City"]], "cats": ["flight"], "user": 2}
{"text": "Find a flight from Memphis to Tacoma", "entities": [[0, 26, "City"], [30, 36, "City"]], "cats": ["flight"], "user": 3}
{"text": "I want to know what airports are in Los Angeles", "entities": [[36, 47, "City"]], "cats": ["airport"], "user": 1}
{"text": "I want to know what airports are in Los Angeles", "entities": [[36, 47, "City"]], "cats": ["airport"], "user": 2}
{"text": "I want to know what airports are in Los Angeles", "entities": [[36, 47, "City"]], "cats": ["airport"], "user": 3}

To test it, please use this data format. Create Custom project with shared_org_label enabled. Add member to the project (remember to check if the member id is the same as the user id field in your data file).
Screenshots:
Admin view:

User view:

P/s: Thank you Argi for the quick implementation of the form XD

Hello, I just update the progress bar for the user's annotation view to show the total number of texts assigned to them only, not the whole number of texts imported to project.


Enable to work --active without filtering by ports arguments

Pull Request Test Coverage Report for Build 21

0 of 4 (0.0%) changed or added relevant lines in 2 files are covered.
No unchanged relevant lines lost coverage.
Overall coverage increased (+0.1%) to 11.003%

Changes Missing Coverage
Covered Lines
Changed/Added Lines
%

cli.go
0
1
0.0%

conntrack/conntrack.go
0
3
0.0%

Totals

Change from base Build 19:
0.1%

Covered Lines:
34

Relevant Lines:
309

💛  - Coveralls


Imports missing types from typestyle

In the most recent npm version of this library, you'll find this line in types.d.ts:
import { CSSColor, CSSPercentage, CSSLength, CSSLineStyle } from 'typestyle/lib/types'
There are also a few other instances of this throughout the project. However, that particular file in typestyle doesn't actually export any types by those names, and it causes an error on typescript compilation.
ERROR in C:/Users/Frob/Projects/frontend/node_modules/csx/lib/internal/background.d.ts(1,10):
TS2305: Module '"C:/Users/Frob/Projects/frontend/node_modules/typestyle/lib/types"' has no exported member 'CSSImage'.
ERROR in C:/Users/Frob/Projects/frontend/node_modules/csx/lib/internal/background.d.ts(1,20):
TS2305: Module '"C:/Users/Frob/Projects/frontend/node_modules/typestyle/lib/types"' has no exported member 'CSSPosition'.
ERROR in C:/Users/Frob/Projects/frontend/node_modules/csx/lib/internal/background.d.ts(1,33):
TS2305: Module '"C:/Users/Frob/Projects/frontend/node_modules/typestyle/lib/types"' has no exported member 'CSSLength'.
ERROR in C:/Users/Frob/Projects/frontend/node_modules/csx/lib/internal/background.d.ts(1,44):
TS2305: Module '"C:/Users/Frob/Projects/frontend/node_modules/typestyle/lib/types"' has no exported member 'CSSPercentage'.
ERROR in C:/Users/Frob/Projects/frontend/node_modules/csx/lib/internal/background.d.ts(1,59):
TS2305: Module '"C:/Users/Frob/Projects/frontend/node_modules/typestyle/lib/types"' has no exported member 'CSSRepeatStyle'.
ERROR in C:/Users/Frob/Projects/frontend/node_modules/csx/lib/internal/background.d.ts(1,75):
TS2305: Module '"C:/Users/Frob/Projects/frontend/node_modules/typestyle/lib/types"' has no exported member 'CSSBox'.
ERROR in C:/Users/Frob/Projects/frontend/node_modules/csx/lib/internal/background.d.ts(1,83):
TS2305: Module '"C:/Users/Frob/Projects/frontend/node_modules/typestyle/lib/types"' has no exported member 'CSSColor'.
ERROR in C:/Users/Frob/Projects/frontend/node_modules/csx/lib/internal/color.d.ts(1,10):
TS2305: Module '"C:/Users/Frob/Projects/frontend/node_modules/typestyle/lib/types"' has no exported member 'CSSColor'.
ERROR in C:/Users/Frob/Projects/frontend/node_modules/csx/lib/internal/color.d.ts(1,20):
TS2305: Module '"C:/Users/Frob/Projects/frontend/node_modules/typestyle/lib/types"' has no exported member 'CSSNamedColor'.
ERROR in C:/Users/Frob/Projects/frontend/node_modules/csx/lib/internal/gradient.d.ts(1,10):
TS2305: Module '"C:/Users/Frob/Projects/frontend/node_modules/typestyle/lib/types"' has no exported member 'CSSAngle'.
ERROR in C:/Users/Frob/Projects/frontend/node_modules/csx/lib/internal/gradient.d.ts(1,20):
TS2305: Module '"C:/Users/Frob/Projects/frontend/node_modules/typestyle/lib/types"' has no exported member 'CSSColor'.
ERROR in C:/Users/Frob/Projects/frontend/node_modules/csx/lib/internal/gradient.d.ts(1,30):
TS2305: Module '"C:/Users/Frob/Projects/frontend/node_modules/typestyle/lib/types"' has no exported member 'CSSSideOrCorner'.
ERROR in C:/Users/Frob/Projects/frontend/node_modules/csx/lib/internal/gradient.d.ts(1,47):
TS2305: Module '"C:/Users/Frob/Projects/frontend/node_modules/typestyle/lib/types"' has no exported member 'CSSGradient'.
ERROR in C:/Users/Frob/Projects/frontend/node_modules/csx/lib/internal/strings.d.ts(1,10):
TS2305: Module '"C:/Users/Frob/Projects/frontend/node_modules/typestyle/lib/types"' has no exported member 'CSSUrl'.
ERROR in C:/Users/Frob/Projects/frontend/node_modules/csx/lib/internal/transforms.d.ts(1,10):
TS2305: Module '"C:/Users/Frob/Projects/frontend/node_modules/typestyle/lib/types"' has no exported member 'CSSTransformFunction'.
ERROR in C:/Users/Frob/Projects/frontend/node_modules/csx/lib/internal/transforms.d.ts(1,32):
TS2305: Module '"C:/Users/Frob/Projects/frontend/node_modules/typestyle/lib/types"' has no exported member 'CSSLength'.
ERROR in C:/Users/Frob/Projects/frontend/node_modules/csx/lib/internal/transforms.d.ts(1,43):
TS2305: Module '"C:/Users/Frob/Projects/frontend/node_modules/typestyle/lib/types"' has no exported member 'CSSPercentage'.
ERROR in C:/Users/Frob/Projects/frontend/node_modules/csx/lib/internal/units.d.ts(1,10):
TS2305: Module '"C:/Users/Frob/Projects/frontend/node_modules/typestyle/lib/types"' has no exported member 'CSSPercentage'.
ERROR in C:/Users/Frob/Projects/frontend/node_modules/csx/lib/types.d.ts(1,10):
TS2305: Module '"C:/Users/Frob/Projects/frontend/node_modules/typestyle/lib/types"' has no exported member 'CSSColor'.
ERROR in C:/Users/Frob/Projects/frontend/node_modules/csx/lib/types.d.ts(1,20):
TS2305: Module '"C:/Users/Frob/Projects/frontend/node_modules/typestyle/lib/types"' has no exported member 'CSSPercentage'.
ERROR in C:/Users/Frob/Projects/frontend/node_modules/csx/lib/types.d.ts(1,35):
TS2305: Module '"C:/Users/Frob/Projects/frontend/node_modules/typestyle/lib/types"' has no exported member 'CSSLength'.
ERROR in C:/Users/Frob/Projects/frontend/node_modules/csx/lib/types.d.ts(1,46):
TS2305: Module '"C:/Users/Frob/Projects/frontend/node_modules/typestyle/lib/types"' has no exported member 'CSSLineStyle'.

For proof, check out the latest version of types.ts in typestyle.

The most recent version of csx is v9.0.0 and it does not have an csx/lib/internal folder
ERROR in C:/Users/Frob/Projects/frontend/node_modules/csx/lib/internal/background.d.ts(1,10):
TS2305: Module '"C:/Users/Frob/Projects/frontend/node_modules/typestyle/lib/types"' has no exported member 'CSSImage'.

Checking on unpkg shows this<EMAIL_ADDRESS>Can you check your version?  TypeStyle started using types from the csstype project in version 2, and csx did the same in csx version 9.


add austinp

Checklist

[x] Used a personal fork of the feedstock to propose changes
[x] Bumped the build number (if the version is unchanged)
[ ] Reset the build number to 0 (if the version changed)
[x] Re-rendered with the latest conda-smithy (Use the phrase @conda-forge-admin, please rerender in a comment in this PR for automated rerendering)
[ ] Ensured the license file is being packaged.

This is ready for review.

@matthiasdiener -- Thanks for the PR. This is touching a lot of files that I typically don't see hand-edited. Could you give me a brief overview explaining the rationale for the changes?

@matthiasdiener -- Thanks for the PR. This is touching a lot of files that I typically don't see hand-edited. Could you give me a brief overview explaining the rationale for the changes?

The only hand edited files are the meta.yaml and build.sh (and the added patch to support newer compilers). The other changes are just due to rerendering. The handmade changes were necessary to support building austinp on Linux.

So you did the re-render locally, and then made other commits on top of the rerender? I thought it was all hand edited, since I didn't see the isolated re-render commit with the auto-generated commit message.

So you did the re-render locally, and then made other commits on top of the rerender?

Yes, that is what I did.

@conda-forge-admin, please rerender


Please export freetype-go to github

Google Code will be turning read-only on August 25th. Would you  export freetype-go to github , and change "code.google.com/p/freetype-go"  to  "github.com/*/freetype-go" ?

I've raised this with @nigeltao, who is one of the primary contributors to freetype-go.

Now we can use "import github.com/golang/freetype" instead of "import code.google.com/p/freetype-go".

Dont switch over to the github version just yet. I intend to make breaking API changes over the next week or three.

golang-nuts post about the move to github.com/golang/freetype:
https://groups.google.com/d/topic/golang-nuts/tr-MftD7kbo/discussion


Add ability to filter editions by broken links

This commit adds the ability to filter editions by broken links on the index page so users are able
to quickly see editions with broken links. This expands on the work done on https://github.com/alphagov/whitehall/pull/3582
along with the other LinkCheckerAPI integration work.

I've addressed the other comments and added a unit test @gpeng


improve debug logging #608

Fixes #608

Hi @liga-oz
I would suggest to add some logs on a central place such as
Base64JwtDecoder.getInstance().decode() instead of "consumer side".
Alternatively we can log the initial 20 characters of the provided jwtToken within HybridTokenFactory implementation in error case.

@nenaraab I don't think HybridTokenFactory would be a handy place to implement that as I would need to catch and rethrow the error again, because errors are caught and handled in Authenticators.


Reduce dependency by using Java instead of kotlin

RT.

Progress:

[ ] common
[ ] rec-accessor
[x] rec-app
[ ] rec-core
[ ] rec-initializer
[x] rec-scripting
[x] rec-sepval

For test, see #8


More descriptive batch logging

The current batch logging that we get is:
INFO Increased batch size to 16000 (com.wepay.kafka.connect.bigquery.write.batch.DynamicBatchWriter:268)

This is a bit too vague. It'd be nice to know the table.

Fixed by https://github.com/wepay/kafka-connect-bigquery/pull/46


Conditional Logic input history - form response missing

Description
After filling out and submitting a response to a published form, I didn't see an answer reflected in the downloaded response.
Steps to reproduce

Create a form with Show/Hide and branching
Publish the form
Fill out the form, Submit
Download the form response as a CSV
See error

Details

Browser: Chrome
Operating system: Mac
Environment: PR (https://4ouzqz4a6gfkj4pxecb6jjky5i0zfqfc.lambda-url.ca-central-1.on.aws/)
Language: English

Expected behaviour
Form submission answers should be reflected in the downloaded response.
Screenshots or videos
This is a super goofy form that I made at 10pm while watching TV - please excuse it haha. But the screen recording shows me filling out the published form, and downloading the form response.
Private Zenhub Video

Hi @Abi-Nada, was this tested on the forms-forms PR environment? (https://github.com/cds-snc/platform-forms-client/pull/4036)

Yup! It was tested on the forms-forms PR environment (in the video, you can see a peek of the URL when I'm filling out the form)

@Abi-Nada to retest to see if I can produce consistent results for this bug

Retested specific edge case, and issue no longer persists! Not going to close out this card yet - once the PR gets merged in, I'd like to test one more time in Staging


Apm 309526 align gcp metric dimension names with gcp log semantic attributes

Ready for review.
CompatibilityMode=False / None - for any new customer, default
reporting only new dims, e.g. gcp.project.id (project_id not there)

CompatibilityMode=True - for customers who had previous setups
reporting both old and new dims, e.g. both gcp.project.id and project_id reported

New dashboard - only new dashboard working with new data (when adding a service after an update)
To test the dashboard, I've added BeluTestin12 to the dashboards' names to force it to be recognized as a new one and pushed to Dt cluster.
Note, that as of Dt cluster version 223 & 224 dashboards are correctly uploaded, but not correctly published (set to preset=true), since a bug in RestAPI (APM-322917, https://dynatrace.slack.com/archives/GMLF457LL/p1630587604053200).

Old dashboards - for already added services, old dashboards should still be working (old dashboards use old dims, which are still reported), giving consistent view of the data. Hard for me to demonstrate this, as jxw has data from multiple sources.
Note: old dashboards SHOULD be in env since when the service was added before: BUT this might not be true if there was anything wrong in the API for uploading/publishing dashboards when service was added (the bug already mentioned in 223+ or the one in June)

References for checking what should and what shouldn't go to gcp.instance.name:
https://cloud.google.com/monitoring/api/resources
https://cloud.google.com/asset-inventory/docs/resource-name-format

FAILED tests/unit/test_activation_config.py::test_filtering_missing_configs
> load_supported_services(context, [])
I think this started failing because of 2bc7ceef (APM-309526 fix load_supported_services(selected_featuresets = []) usages: ddu & metadata generation - load all if no whitelist_exists)
@pgutkowski I think this is about what I told you that I fixed it to get my test_compatibility_mode.py running, as it was also used and failing those:
generate_ddu_estimation.py
generate_metadata.py

You've mentioned the behaviour could have changed because of some filtering implemented. I'm not here next two weeks, could you or @mswiatkowska help whoever takes this over to navigate what it should be like in the end? Should it allow loading absolutely all service configs, or is it not allowed anymore for some reasons and could only be run in test, and non-prod?
Temporarily commenting out f659d31d

Moving into the comment:
1. configs + load
DONE:

configs have new dimensions with compatibilityModeOnly=True
on configs being loaded (load_supp_services > ... > new Dimension) dimensions get filtered according to compatibilityMode env_var
test for loading of configs (unit/test_compatibility_mode) + checks en masse if nothing skipped through

TODO:

metrics.ODIN_COMP...MODE TODO BŁ - should probably be init once, but test need to patch it differently then

manual review in PR: of changes accross all config commits:
**  make sure only one of location/region + zone made it to new field gcp.region
**  make sure only one _name field made it to new field gcp.instance.name BŁ DONE

[nice to have] cleanup fields in Dimension value Class - try to make fewer of them, I tried to bring it all in one place to see how it is used in different places, next step would be to try and reduce the number of fields to some common subset

2. changes to how are dt dimension keys produced
DONE

checked by regex in configs, that magic on dimension.value in create_dimension matches dimension.id
** confirmed by PawelG that this was created automatically, so +1 to those 2 should match

tried to verify no breaking changes in dims produced - the dims produced before/after changes to create_dimension - list all dims produced per single polling before/after: ReportedDims Before & After.xlsx

run locally (local_test), works fine

TODO:

!!! review: more verification to double check no breaking changes to dims!!!
** verify output visually who can?
** verify on cluster/jxw no new dims?
** verify on cluster/jxw history continuity?
** anything that occurs to you DONE BŁ: run locally before&after results: ReportedDims Before & After.pdf

integration test > test_integration_metric.py

verify e2e test pass

make build - fix test_activation_config.py
* make build - fix test_integration_metric.py - fixed, but still to consider if something to add here. It catched something, so that's nice, [nice to have] have another scenario with compatibilityMode=true

3. dashboards
DONE
* moved exisiting dashboards to > compatibilityMode
* created new non-compatibilityMode dashboards > changed all dims there
* config changes to point to both compatibilityMode & nonCompMode dashboard
TODO
* verify script uploading dashboards for function: run bash setup.sh
* verify script uploading dashboards for kubernetes: run run_docker.py locally
* verify what we wanted - had some mindfuck concerning how, so might be the scripts do something useless
I don't know what lack of memory possessed me here, I've now fixed the dashboards to be a single set of dashboards including both dimension sets

test if it works with real data - for old dims reported, for new dims reported (compMode=false) and for both (compatibilityMode=true)
** script uploading dashboards for function: run bash setup.sh
** script uploading dashboards for kubernetes: run run_docker.py locally > lib.configure_dynatrace.ConfigureDynatrace.import_dashboards

Note nr 1, for customers who had previous setups imho we should either:

make it very explicit in the Release notes that customers with existing setups should set CompatibilityMode=True if they want to see continuous data, or
somehow make it set to true on update/helm-upgrade? I'm not sure if this is possible - I could try to investigate that, but I don't think it was originally discussed in scope of this task, so let me know what do you think
Otherwise, a customer who updates and misses setting the flag to true will only have data with old dims up to the update point, and after the update point only with new dims.

Note as to the dashboards/shareSettings restAPI bug:
Dashboards can only be published manually in the UI if you first get the uuids of the individual dashboards from container logs or via the dashboards RestAPI.
Once the dashboard shareSettings RestAPI is fixed, they still won't be published (the script won't retry that if they are already uploaded). I'd seriously consider changing the script to try to publish the unpublished ones. Otherwise, you probably need to send any customer explicitly to the RestAPI to delete them - as their owner is Dynatrace Open Source and they are not typically visible in the UI.

I've only tested full GCP setup in K8 version. Let me know if you see the need to test function setup as well.
E2E test for this would be nice, too, but imo that's definitely out of scope of this task.

after merging this we should rewrite whole extensions @sq2gxo

after your changes script generate_metadata.py starts failing on:
Failed to map units: {'By.s', 'GiBy.s', 'GBy.s'}

fix generate_metadata.py script and also check generate_ddu_estimation.py

As discussed in slack, nothing changed here, same behavior in master for both generate_metadata/ddu.
The only change from me is that they can now also be run for all services without setting locally env_var ACTIVATION_CONFIG with explicitly listing all services.


Improve explanation of Reference Object

With the addition of relative file references (notably in swagger-js, and samples), there should be an explanation of how that resolves (based on JSON Reference). Samples/petstore-separate provides a reference point that could be utilized.

On further review, the REUSE guidelines should be updated too:
https://github.com/swagger-api/swagger-spec/blob/master/guidelines/REUSE.md

@jasonh-n-austin - are you referring specifically to how relative references are resolved?

Right, so perhaps examples of what $ref links should/shouldn't look like, and what they should be relative to in pathing.
One example:
swagger.yaml
$ref: 'models/Thing.yaml'

Thing.yaml
$ref: 'models/AnotherThing.yaml' # note path is relative to swagger.yaml, not Thing.yaml

Also, deep links such as:
$ref: 'models/Common.yaml#Address' # an object within a schema file

All of this is really just how JSON Reference works, but some practical examples would probably help devs implementing the Swagger 2 spec get it right more consistently.

:+1:

@jasonh-n-austin  Hi, I'm refactoring my python client for external file reference, and feel confused with these:
swagger.yaml
$ref: 'models/Thing.yaml'

Thing.yaml
$ref: 'models/AnotherThing.yaml' # note path is relative to swagger.yaml, not Thing.yaml

In another discussion, one of your comment:

Each file resolves it's own refs, regardless where they're included from. In the swagger.yaml->Category->Person example, the $ref in Category is resolved from it's own location to find Person (as opposed to the location of swagger.yaml).

In the first comment, the base URI used to resolve 'models/AnotherThing.yaml' should be derived from swagger.yaml, although the $ref resides in Thing.yaml. But the comment in another issue states that the base URI should be derived from Thing.yaml.
Which one of my understanding is correct? Thanks for any feedback in advance. :+1:

I would expect relative references to be based on the location of the document containing the reference.

I tend to agree with you @whitlockjc (clearly contradicting my earlier statements). I think I was basing the examples on the way that @BigstickCarpet 's json-parser resolves JSON references (which could be incorrect here).
Per the RFC for JSON Reference (https://tools.ietf.org/html/draft-pbryan-zyp-json-ref-03):

Resolution is performed relative to the referring document.

When working on swagger-tools and sway, I created json-refs just for this.  While I'm not saying it's perfect or should be the guide, it's been well received.  Ever since supporting relative references in json-refs, relative references have always been resolved as I mentioned above and I'm yet to have anyone complain about it or suggest otherwise.  While the sample set is small, this tells me that the intuitive approach matches what I suggested above as well.

FWIW, I put together a sample spec which has separated files (https://github.com/OAI/OpenAPI-Specification/tree/master/examples/v2.0/json/petstore-separate). IIRC I ran swagger-tools across this to validate that everything was resolving right. This should serve as a working example for other implementers for the time being.

I'm still confused with that RFC :(

Resolution is performed relative to the referring document.

In the example above, should the referring document be swagger.yaml or Thing.yaml when resolving 'models/AnotherThing.yaml'?

I agree with @jasonh-n-austin and @whitlockjc that relative references should be based on the location of the document containing the reference.   Swagger Parser 1.x and 2.x both resolved relative paths based on the main document rather than the containing document, but there were at least three problems with that:

It proved to be very fragile.  Any time you moved files around or changed your folder structure, you had to go find and change every relative reference.

It didn't match the way people were using Swagger in the real world.  It was a constant point of confusion/frustration for people who were using Swagger Parser.

And this is the big one - the JSON Reference specfication is very clear about how relative path resolution should behave:

If the URI contained in the JSON Reference value is a relative URI,
then the base URI resolution MUST be calculated according to
[RFC3986], section 5.2.  Resolution is performed relative to the
referring document.

Swagger Parser 3.0 was a complete rewrite, and one of the main goals was to make it fully compliant with all of the specifications involved (Swagger 2.0, JSON Schema, JSON Hyper-Schema, JSON Reference, and JSON Pointer).  As a result, relative references are now resolved relative to the containing document.

I'll see what I can do about finally getting around to writing something up in REUSE.md...this discussion helped nail down some of the potential ambiguity.

I'm not sure there was ambiguity other than at some point, we have to call these what they are: JSON References.  Thankfully, if we can do that the JSON Reference specification is very clear on things.  I've had no problem understanding the spec when working on my tooling and I'm sure @BigstickCarpet has had similar success writing his.
At the same time, I doubt anyone would complain with more documentation if it meant making things simpler to understand.

:+1: to that

Used part of my open dev day and did some writing for PR #535, I'd love feedback @whitlockjc & @BigstickCarpet

@jasonh-n-austin Thanks for PR! Overall it looks good to me. I would reorganize the guide a bit, but I'd suggest we'll merge your PR first, and then I'll submit another PR reorganizing it for everyone here to review. Basically, I'd split it into cases, and change some headers and topic order, just to create a clearer flow, not changing the content itself.
Per your request, I'll wait for the feedback from @whitlockjc and @BigstickCarpet before merging.

@jasonh-n-austin - All of your edits look good to me.  But there are a few other parts of the document that I feel are a bit unclear:
1. I'm not sure exactly what this line under "Operations" means:

Remember, you cannot override the definitions, but in this case, you can add additional operations on the same path level.

What exactly is it referring to?  It doesn't seem to pertain to anything in the code sample immediately preceding it.  Maybe it just needs to be reworded?
2. In the "Responses" section, there's an example file responses.json with the following content:
{
  "NotFoundError": {
    "description": "Entity not found",
    "schema": {
      "$ref": "#/definitions/ErrorModel"
    }
  }
}

The reference to #/definitions/ErrorModel seems a bit confusing, since there's no such definition in the example.  Is it just that this example is not meant to represent the entire file?  Or is the reference incorrect?
3. At the very end, in the "Constraints" section, it says:

Referenced objects must be to JSON structures. YAML reuse structures may be supported in a future version

I assume it means that OAI 2.0 only supports references to JSON files, not to YAML files?  If so, why?  The format supports YAML for the main file, so why not support it for external files as well?  This seems like an arbitrary limitation, especially since YAML is simply an alternate syntax for JSON, not something more advanced that requires special consideration or handling.

@BigstickCarpet In Swagger/OpenAPI 2.0 we made an unfortunate mistake by allowing $ref inside the Path Item Object where we allowed $ref to co-exist with other Operation Objects breaking the rules of JSON Reference. However, by the time we learned that, it was too late to change the spec so the rule is this - any Operation Objects defined in the $ref will be included under the Path Item Object. You can add more operation definitions such as get, post, etc. but those cannot override whatever is already defined in the $ref. Defining something that overrides that reference is considered invalid by the spec. I realize this is a parsing nightmare. That's the meaning of that line under "Operations".

Sorry, should have replied to everything. For point 2, that's not @jasonh-n-austin's fault, it's mine :) It can definitely be expanded.

That's a constraint that may no longer relevant and is related to the official Swagger tools around the spec. Now that the spec has migrated to the OAI and the tools are separate, that constraint should be removed (it may also be irrelevant now, I'd need to check).

I provided my responses to the PR.  Long story short, I think we really should avoid adding too much to this.  Something like "Swagger reuse is enabled through JSON References." would be a good start.  After that, some example of the different types of JSON Reference locations (local, relative, remote, relative or remote with a hash, ...).  I also think we should remember that JSON Reference processors will not necessarily be Swagger aware and will gladly resolve references to locations within the Swagger document regardless of whether or not the JSON Reference points to a collection of definitions or not.  (Collection of definitions like we Swagger supports for definitions, parameters and responses.)

@whitlockjc reuse is also enabled with internal references to parameters, definitions etc, not just JSON references. A single schema definition is likely to be referenced multiple times in a spec, even in normal CRUD resource scenarios.

Perhaps it would be better to split the REUSE into two docs? One explaining what can be reused, and one giving more info about how to use JSON References within the current spec (first doc pointing to the other)?

@jasonh-n-austin Yep...using JSON References to get to them.  ;)

lol.   What @whitlockjc said.

My personal opinion is that it makes no sense to say "We use JSON References but we only allow them to point to certain locations when they are local references."  Over the last two years, my work and open source life has been Swagger tooling.  I have read every shred of Swagger specification documentation and their JSON Schema files so many times I can't even begin to count.  I never once have made the connection that just because these containers were created that it implied JSON References to locations within the same document could only point to those containers.  Not only that but never once has anyone brought it up when working on any of the Swagger tooling I've been involved with.
But that is probably a topic for a different issue since I guess the proposed verbiage is fine based on the unwritten rules that I've just become privy to.  I just thought you should know.

I was thinking that the internal references were JSON Pointer, and external was JSON Reference (which uses JSON Pointer for fragments). Maybe I just didn't realize JSON reference would do the local resolution stuff too. Now that I think about it, the $ref part is JSON reference, but it's using JSON Pointer for the local fragment.
#istandcorrected
I'll work on rewording this a bit. @webron are you concerned this is too long already, re: 2 docs?

Just to avoid confusion for anyone reading this later, the JSON Reference spec says that the $ref value is a URI and only the fragment portion, which would mean the whole $ref value for local references, is a JSON Pointer.  JSON Reference itself doesn't treat $ref differently whether it's a fragment only (local) or not, it is always just a URI.  At evaluation time this information matters but the end user shouldn't care about these things because it's a tooling problem.
To make things simpler, I think mentioning that JSON References are used to enable reuse should be good enough as long as we have good examples.  The reason being is that the differences between the different "types" of JSON References used in Swagger documents are just URI semantics.  For example, see the three "main" JSON Definition definition types:

Local references: These are references to somewhere within the document where the reference is defined (Example: {"$ref": "#/definitions/Pet")
Remote reference (whole document): These are references to a remote document (Example: {"$ref": "http://petstore.swagger.io/v2/swagger.json")
Remote reference (sub document): These are references to a sub portion of the remote document (Example: {"$ref": "./swagger.json#/definitions/Pet")

Are we over complicating things?

I hope this is reading right.  There is no emotion or attitude in any of this.  I'm just trying to help.

Oh the joys of text-based communication.  :-/
It reads fine to me.  Very informative and clarifying too.  Thanks for elaborating!

Any time I communicate via text, I always err on the side of caution just in case.  Thanks for the feedback.

Okay, as @whitlockjc mentioned we always use JSON References inside the spec. JSON References use JSON Pointers in some cases, as defined in the JSON Reference RFC. I really don't think we need to get into the subtleties of how and when JSON Pointers are used inside JSON References - if anyone wants to know, they should read the RFC. I know @whitlockjc have done so, I've done so, and I'm sure @BigstickCarpet and @jasonh-n-austin have done so as well. Since we use JSON References, we just need to mention where we deviate from it or what additional restrictions we add to it. In most cases, we use it as-is. Overloading the spec or our docs with information that can be easily attained from reading other specs seems wasteful to me.
@jasonh-n-austin - If it's ok with you, please keep it in one doc and concentrate on the content. I'll rework the docs afterwards and submit a PR for the contributors here to review.
@whitlockjc - I assume I annoy people by default with my comments (even though it's not my intent), and am ready to be hit by rotten tomatoes at any given time (virtually and in real life).

Excellent stuff @whitlockjc. No emotion read...remember I work with anti-social developers all day, I read that you care ;)
Totally agree it's all just JSON Reference...my apologies for confusing the matter.
I like the local, remote, remote (sub-document) language, I think I'll relabel the sections in the guidance.
I'll try to steal some time to spit polish this PR this afternoon based on all the additional input.

@webron PR should be ready for merge. This was a fun one, with all of the collaborative input! Glad to finally have that topic covered.

Thanks everyone for the great work on this. The PR has been merged. I'd like to keep the issue open for a bit more, if you don't mind. Please wait for an additional comment to come soon.

So following the recent changes, I'd propose splitting the guides into two as shown in #547. Just a proposal, can be scrapped as quickly as it was created. @jasonh-n-austin, @whitlockjc, @BigstickCarpet - thoughts?

@handrews I've got this tracked under #2099 now and it needs somebody to be in charge. Any volunteers?

@webron @darrelmiller what is the status of this one?

@philsturgeon It is closed


[Adaptive Cards][Input.Number trims first and last digits]

Platform
What platform is your issue or question related to? (Delete other platforms).

[ ] Adaptive Cards
[ ] Outlook

Author or host
Author
Organization
Version of SDK
Actionable Emails using Adaptive Cards 1.0
Details
Strange but Input.Number trims first and the last digits.
{
"type": "AdaptiveCard",
"body": [
{
"type": "Input.Number",
"placeholder": "Placeholder text",
"id": "test"
}
],
"$schema": "http://adaptivecards.io/schemas/adaptive-card.json",
"version": "1.0",
"actions": [
{
"type": "Action.Http",
"title": "Action.Http",
"body":"{{test.value}}"
}
]
}
Input: 23434
Output: 343

@dclaux another ActionableMessage bug -- who/how can we route these correctly again?

@dclaux another ActionableMessage bug -- who/how can we route these correctly again?

Please send the bug to the Actionable Messages team<EMAIL_ADDRESS>


Language switch button is partially unclickable

On the Home Menu, the language switch button on the App Header is partially covered by an invisible element, making only the right half clickable and the left half unclickable. Any additional buttons added on the left side of this button is also unclickable.
The unclickable area is highlight in red:

Tested screen sizes: iPhone 8 Plus, iPhone 6s.

FYI I was previously on an old commit 7a64e91 and that version does not exhibit this problem. So I believe this is a regression introduced in recent months.

It looks to me like 96734a0 is the culprit. Whereas the Column will let the press fall through to the underlying button, the ExpandedScrollingColumn catches the press so it blocked the click.

The fix might be one of:

Move the AppHeader to the top of the stack so it sits on top of the Content
Move ExpandedScrollingColumn down to not overlap with the AppHeader
Allow press on ExpandedScrollingColumn to fall through to the underlying widget


InvalidStateError: XMLHttpRequest has an invalid context.

Are you requesting a feature or reporting a bug?
Reporting a bug
What is the current behavior?
Sometimes (not consistent), this error: Error in Role initializer - An error occurred in ClientFunction code: InvalidStateError: XMLHttpRequest has an invalid context. occurs when trying to use a ClientFunction inside of a Role. When the error does appear, it happens to a batch of tests one after another, while other tests continue to run without this error. I am running the tests with 4 concurrent browser instances.
What is the expected behavior?
ClientFunction should behave consistently in Role
How would you reproduce the current behavior (if this is a bug)?
Errors happen when run on Firefox inside a docker container. I was not able to reproduce this outside of the container in Firefox. It's possible though that it doesn't have to do with the test being run in the container, and that just by chance it didn't reproduce for me. But figured it was worth noting.
After researching this a bit it seems like its an issue with the timing of the xhr's open(), onreadystatechange(), and send() methods (https://xhr.spec.whatwg.org/).
Provide the test code and the tested page URL (if applicable)
Tested page URL: (unfortunately cannot provide)
Test code
//test.js
...
const signin = new SignIn();
await signin.handleSignIn();
...

//sign-in.js

export default class SignIn {
     async handleSignIn() {
           await t
               .useRole(signInRole)
               .navigateTo(_____url with same origin______)
    }
}

//utils.js

export const signInRole = Role(_____url with same origin______, async t => {

    const headers = await getSignInCredentials()
        .then(result => result.headers)
        .catch(error => console.log(error))

    await t.expect(headers).ok()

    const cookieSetter = function setCookies(cookieObj) {
        const cookies = cookieObj['set-cookie'];
        for (let value of cookies) {
            const cookie = value.split(';')[0];
            document.cookie = cookie;
        }
        return true
    }

    const setSignInCookies = ClientFunction(() => {
        return cookieSetter(headers);
    }, { dependencies: { cookieSetter, headers }});

    const cookiesSet = await setSignInCookies();    //<--- here is where the error is occurring

    await t.expect(cookiesSet).ok()

}, { preserveUrl: true });

//api.js

const token = ClientFunction(() => document.getElementsByName('csrf-token')[0].getAttribute('content'));

axios.defaults.headers.common['X-CSRF-Token'] = token();
axios.defaults.headers.common['Content-Type'] = 'application/json';
axios.defaults.headers.common.Accept = 'application/json';
axios.defaults.withCredentials = true;
axios.defaults.auth = { username: ________ , password: _____________ };
axios.defaults.timeout = 10000;

export async function getSignInCredentials() {
    return await axios.post(_____route where url has same origin______)
        .then(response => response)
        .catch((error) => console.log(error));
}

Specify your

operating system: Linux
testcafe version: 0.20.5
node.js version: 8.10.0

Hi, i don't use Roles, but i have exactly the same issue with running tests on Firefox inside of the Docker container.

Firefox 61.0.0 / Mac OS X 10.13.0
testcafe v. 0.21.1
node.js v. 10.9.0

it starts happening since i'm using function to set cookies in beforeEach hook
export async function setCookie() {
const setCookie = ClientFunction(() => {
document.cookie = "multiproxy=blabla"
});
const setter = await setCookie();
return setter;

}
it works without errors on Chrome v. 68.0.3440

@edenadler @Sashikus
I am afraid this information is not sufficient to find the cause of the issue. Could you please provide a page or a small example so that we can reproduce it on our side?

I will close the issue because no activity has been encountered for a long time.
Feel free to reopen the issue if the problem persists and you can provide an example to reproduce it.