Support intersection types

E.g.
/**
 * @interface
 * @name Bar
 */
/** @property {string} Bar#bar1*/
/** @property {number} Bar#bar1*/

/**
 * @interface
 * @name Foo
 */
/** @property {string} Foo#foo1 */
/** @property {number} Foo#foo2 */

/** @type Bar&Foo */ // implements both Bar and Foo
var x = new Something();
console.log(x.foo1 + x.bar1);

or even
@typedef {{bar: number}} Bar
@typedef {{baz: number}&Bar} Baz // has members of both itself and Bar

thank you in advance

@hegemonic any opinion on this? Would like to get this into cartharsis and doctrine so that TypeScript and Flow docs can benefit from this. Thanks!

Sorry, but JSDoc only supports Closure Compiler type expressions, not Flow or TypeScript type expressions. This is unlikely to change anytime soon.

@blickly/@MatrixFrog Just a wider question, probably not the best venue. Wondering if you have any opinions on how the larger JavaScript ecosystem should deal with documentation syntax standards. Popular supersets such as TypeScript/FlowType's are supporting type expressions that are increasingly difficult to represent with CC's expressions.
I'm concerned that the only stable option is going to be to omit types in tags entirely and rely on the given IDE or doc generator to do its own static analysis on a per-language basis. I think that's reasonable since otherwise the burden is shifted to doc parsers, I'm just concerned about fragmentation.

Enhancing the Closure Compiler type system is likely the best option.  Intersection types such as (Bar & { bar : number}) are just anonymous subtypes.  The most useful intersections (record, interface and class instance intersections are representable in the current type intrastructure, there just isn't a way to "write it".
For example, here is a "Foo" with an added property:
http://closure-compiler-debugger.appspot.com/#input0%3D%252F**%2520%2540constructor%2520*%252F%250Afunction%2520Foo()%2520%257B%250A%2520%2520%252F**%2520%2540type%2520%257Bnumber%257D%2520*%252F%250A%2520%2520this.a%2520%253D%2520123%253B%250A%257D%250A%250A%252F**%2520%2540param%2520%257B%257Bb%253Anumber%257D%257D%2520x*%252F%250Afunction%2520f(x)%2520%257B%250A%2520%2520return%2520x%253B%250A%257D%250A%250Avar%2520x%2520%253D%2520new%2520Foo%253B%250Ax.b%2520%253D%2520123%253B%250A%250Af(x)%253B%250A%250Avar%2520%252F**%2520null%2520*%252F%2520n%2520%253D%2520x%253B%26input1%26conformanceConfig%26externs%26refasterjs-template%26includeDefaultExterns%3D1%26CHECK_SYMBOLS%3D1%26MISSING_PROPERTIES%3D1%26TRANSPILE%3D1%26CHECK_TYPES_NEW_INFERENCE%3D1%26CLOSURE_PASS%3D1%26PRESERVE_TYPE_ANNOTATIONS%3D1%26PRETTY_PRINT%3D1

I too am looking for a way to express an intersection type in jsdocs, however not because I am using typescript/flow/ect... Just regular ES6 javascript, and through the use of proxies.
For example, where x and y are class instances, with their own methods and properties:
const xy = new Proxy(x, {
  get: function handler(target, param) {
    return param in x ? x[param] : y[param];
  }
});

xy should be @typedef {(x & y)} xy

If anyone sees this, I put together a jsdoc plugin that converts the TypeScript intersection types to JSDoc compatible union types - allowing you to use them without killing your jsdoc flow. Since this is an issue that, reasonably, won't be added to JSDoc, using the plugin system is the right direction.

Hello from 2020!  Is there any chance of reconsidering the decision from a few years ago?
Proper intersection types -- not rewritten union types as per Christopher's plugin above -- are required to correctly express an index signature that applies to a class, as in:
class RowBase {
  add() { ... }
  remove() { ... }
}
type Row = RowBase & Record<string, number | boolean>;

Expressing this in JSDoc is currently not possible.  Using a union would mean myRow.add() fails, because add types as number | boolean | Function.


Generator.generate_swagger is not working if destination path is not provided

Destination path parameter in generate_swagger function of Generator class is optional. It works when the parameter is passed. But when destination path is not provided then it throws below error:
Traceback (most recent call last):
  File "e:/OpenSource/flask-swagger-generator/test.py", line 28, in <module>
    generator.generate_swagger(app)
  File "e:\OpenSource\flask-swagger-generator\flask_swagger_generator\generators\generator.py", line 53, in generate_swagger
    self.file = open(destination_path, 'w')
TypeError: expected str, bytes or os.PathLike object, not NoneType

Example:
generator.generate_swagger(app)

I have also found the solution. And have created the below PR for the fix.
https://github.com/coding-kitties/flask-swagger-generator/pull/23


⚠ Bofrost.be has degraded performance

In 67b9e02, Bofrost.be (https://www.bofrost.be) experienced degraded performance:

HTTP code: 200
Response time: 2290 ms

Resolved: Bofrost.be performance has improved in 7a926a2.


How to add custom tnsnames.ora to Oracle <IP_ADDRESS> se

How can I add my custom tnsnames.ora to Oracle <IP_ADDRESS>?
I can successfully build the base image. I've build it twice (one with the VOLUME for oracle data and once without (prebuilt image)).
My Dockerfile looks like this (I don't want to work with mounts)
FROM oracle/database:<IP_ADDRESS>-se2-prebuilt
COPY tnsnames2.ora /opt/oracle/product/<IP_ADDRESS>/dbhome_1/network/admin/tnsnames2.ora
USER root
RUN chown oracle:oinstall /opt/oracle/product/<IP_ADDRESS>/dbhome_1/network/admin/tnsnames2.ora
USER oracle
But it always seems to check sqlnet.ora (even not the default tnsnames.ora or am I wrong?)
In the container :
total 224K
-rw-r--r-- 1 oracle dba       373 Oct 31  2013 shrept.lst
drwxr-xr-x 2 oracle dba      4.0K Mar  7 08:58 samples
drwxr-xr-x 1 oracle dba      4.0K Mar  7 09:00 ..
-rwxr-xr-x 1 oracle oinstall 203K Mar  7 09:44 tnsnames2.ora
lrwxrwxrwx 1 oracle oinstall   47 Mar  7 14:49 sqlnet.ora -> /opt/oracle/oradata/dbconfig/ORCLCDB/sqlnet.ora
lrwxrwxrwx 1 oracle oinstall   49 Mar  7 14:49 listener.ora -> /opt/oracle/oradata/dbconfig/ORCLCDB/listener.ora
lrwxrwxrwx 1 oracle oinstall   49 Mar  7 14:49 tnsnames.ora -> /opt/oracle/oradata/dbconfig/ORCLCDB/tnsnames.ora
drwxr-xr-x 1 oracle dba      4.0K Mar  7 14:49 .

tns ping log:
TNS Ping Utility for Linux: Version <IP_ADDRESS>.0 - Production on 07-MAR-2019 14:52:32

Copyright (c) 1997, 2014, Oracle.  All rights reserved.

Used parameter files:
/opt/oracle/product/<IP_ADDRESS>/dbhome_1/network/admin/sqlnet.ora

Hi,
tnsping is checking sqlnet.ora to use places to resolve name. There is option NAMES.DIRECTORY_PATH which describe order for resolving eg.: NAMES.DIRECTORY_PATH = (LDAP, TNSNAMES, HOST).
tnsnames.ora name is always checking so try to overwrite it.
Regards,
Mariusz

@mawasak Thanks, overwriting made it work


Grant admin and cloud_admin heat_stack_owner role

Enables admin and cloud_admin user to able to deploy heat stack out of the box.
In addition, we are no longer going to create project_admin user as cloud_admin can create once then have been on-boarded.

This will have docs/onboarding impact.

You know where I can find current onboarding document? This was to address the gap where we created project_admin user but never communicated in onboarding document.
On out of the box enablement of admin and cloud_admin to able to use heat is a bug.
I will ensure rbac customer facing document covers heat_stack_owner role requirement for user to able to deploy heat stacks.


The two MonacoEditor instances call registerCompletion separately, code returned by the model affected both instances, their states are not isolated

monacopilot version: 0.15.6
monaco-editor version: 0.50.0
node version: v16.19.0

Problem description:
I rendered two MonacoEditor instances on one page using the react-monaco-editor module, and then registered the smart code completion function using the monacopilot module's registerCompletion function, and I found that the code returned by the model affected both instances. Rendering on two editors, their states are not isolated, here's my code.
Relevant code or config
<MonacoEditor
        language={language}
        height="90%"
        width="100%"
        value={code}
        theme={'vs-dark'}
        onChange={setCode}
        options={{
          roundedSelection: false,
          cursorStyle: 'line',
          wordWrap: 'on',
          readOnly: readonly,
        }}
        editorDidMount={editorDidMountHandle}
/>
const editorDidMountHandle = (
    editor: monaco.editor.IStandaloneCodeEditor,
    monaco: typeof monaco,
  ) => {
    editorRef.current = editor;
    monacoRef.current = monaco;
    registerCompletion(monacoRef.current, editorRef.current, {
      language: language,
      trigger: 'onTyping',
      maxContextLines: maxContextLines,
      endpoint: 'bccc8cb00b004568aa2e6404276875c5',
      requestHandler: requestHandler,
    });
  };

I found that this problem is not a bug in the monacopilot module.


Console logs page fails to display logs if the selected resource is starting

Start Aspire app
Quickly navigate to console logs page and choose a resource that is still starting

Once the resource has started:

Expected result is the page shows console logs and status reports watching.
Actual result is the page shows nothing and the status says it has finished watching.

Switching to another resource's logs then back again fixes the problem.

@karolz-ms Are we still implementing streaming logs in DCP?

@davidfowl yes, that is still the goal. It has been delayed repeatedly by more urgent issues, but I want to get that done before GA

What I'm seeing when the resource hasn't started yet is that the call to DasbhoardClient.WatchResourceConsoleLogs returns an AsyncServerStreamingCall<WatchResourceConsoleLogsUpdate> object as expected, but then AsyncServerStreamingCall<WatchResourceConsoleLogsUpdate>.ResponseStream.ReadAllAsync(...) returns an empty enumerator (or whatever else is needed to break the async foreach (it's not canceled as far as I can tell).
That ends the loop in LogView.SetLogSourceAsync, which ultimately gets us to:
https://github.com/dotnet/aspire/blob/66d14b17f6b7628efd6bc18bbbf1a0e71836b8c2/src/Aspire.Dashboard/Components/Pages/ConsoleLogs.razor.cs#L202-L206
So it thinks things are done before they get started.
The question I guess is where should this be handled? Should whatever underlies the ReadAllAsync call be held open while it's starting? Or do we need to add some logic into the console logs page to handle it (perhaps wait until in a running state before starting the watch?). The latter seems maybe safer, but its not clear to me what the intent of the underlying system is.
I don't know much about the underlying implementation of that AsyncServerStreamingCall or even where it lives. I guess that's part of the grpc work that's new since I last looked at this code.  @JamesNK @drewnoakes for input on that side of things.
@karolz-ms would any changes here be mooted by the streaming logs in DCP? Or would the same issue still exist?

@tlmii my guess would be that before the program has started, there is no log data available, so the request for logs terminates without returning any data.
I will make sure that in the new API, if the client requests the logs in "follow" mode, the server will start streaming the logs when they become available, no matter how early in the Executable lifecycle the client asks for them.

@tlmii my guess would be that before the program has started, there is no log data available, so the request for logs terminates without returning any data.

It shouldn't work that way. The server should wait for logs. If the client wants to stop waiting, then that's up to it.
The server should only return if there is an unexpected error or the dashboard asked for logs for a non-existant resource.

It shouldn't work that way. The server should wait for logs. If the client wants to stop waiting, then that's up to it. The server should only return if there is an unexpected error or the dashboard asked for logs for a non-existant resource.

Agreed, but it does not do this today: https://github.com/dotnet/aspire/blob/main/src/Aspire.Hosting/Dashboard/ConsoleLogPublisher.cs#L29

Is the ConsoleLogPublisher going to continue to be in use once the streaming log implementation is finished? In other words, is it worth fixing this now, or should we just close the issue (or mark it dependent on the streaming logs issue)?

As far as I know, it will be replaced by what @karolz-ms does in DCP. If the replacement is landing in P4 (or even P5) then we could leave it broken for now.

Yes, that is the plan. To be quite honest, the part where we wait for the Executable to start may land in P5 not in P4. But it is definitively in scope for GA.

Let's close and re-evaluate once console logging is refactored.


Switch to UBI base images for egeria docker image(s)

See #3560
Recently we discovered the jre image used for egeria was not being regularly updated by the openjdk team. This could expose anyone running the code to more bugs/security issues - and most recently to incompatabilities.
Work is underway to build an egeria operator, and redhat produce freely usable 'UBI' standard images including a few standard frameworks. As of July 2020 java is included & supported. This makes for a more standard base OS/jre for anyone putting the egeria operator into production
The base image will become RHEL rather than alpine which means the necessary changes ie apk->yum but the amount of work should be small.
Aiming to do this alongside the operator work in the 2.3 timescale

More info on the redhat UBI image : https://developers.redhat.com/blog/2020/06/25/introducing-the-red-hat-build-of-the-openjdk-universal-base-images-now-in-red-hat-enterprise-linux-8-2/

The image is licensed under:   https://www.redhat.com/en/about/red-hat-end-user-license-agreements#UBI - specifically the current text is at https://www.redhat.com/licenses/EULA_Red_Hat_Universal_Base_Image_English_20190422.pdf .
The image help is accessed via  docker run registry.access.redhat.com/ubi8/openjdk-11 cat /help.md
The relevant environment variables that would help us to run our apps include:
* JAVA_APP_DIR - location of the application
* JAVA_ARGS - arguments for the application
* JAVA_CLASSPATH (or can be set via the file JAVA_APP_DIR/classpath)

Optionally
* JAVA_LIB_DIR - for extra libraries - ie server/lib for the main app
* JAVA_MAIN_CLASS - could be useful if running something different

Some functionality we scripted - but no longer needed
* JAVA_DEBUG (true/false) - to enable debugging - port is 5005 by default but can be overriden - unnecessary
For persistant storage we also need to consider
* JAVA_DATA_DIR - location of data files when we add persistance (a volume could be placed over here)

The intent should be to run egeria in a similar way to today -- run egeria chassis itself by default, UI if required (or other tools)

The image runs as user 185 (different to our choice today - but I see no reason to change from default)
Ports 8080, 8443 are open by default - we'll stick with 8443 (UI) and 9443 (chassis)
The launch script is /usr/local/s2i/run by default.

Simple changes made to work with UBI.
Results is we can start up the egeria chassis as before - ie no parms
jonesn:egeria/ (issue3580) $ docker run egeria                                                                                [16:07:29]
/usr/local/s2i/run: line 15: /opt/jboss/container/maven/default//scl-enable-maven: No such file or directory
Starting the Java application using /opt/jboss/container/java/run/run-java.sh ...
INFO exec  java -javaagent:/usr/share/java/jolokia-jvm-agent/jolokia-jvm.jar=config=/opt/jboss/container/jolokia/etc/jolokia.properties -XX:+UseParallelOldGC -XX:MinHeapFreeRatio=10 -XX:MaxHeapFreeRatio=20 -XX:GCTimeRatio=4 -XX:AdaptiveSizePolicyWeight=90 -XX:MaxMetaspaceSize=100m -XX:+ExitOnOutOfMemoryError -cp "." -jar /deployments/server/server-chassis-spring-2.3-SNAPSHOT.jar
WARNING: An illegal reflective access operation has occurred
WARNING: Illegal reflective access by org.jolokia.util.ClassUtil (file:/usr/share/java/jolokia-jvm-agent/jolokia-jvm.jar) to constructor sun.security.x509.X500Name(java.lang.String,java.lang.String,java.lang.String,java.lang.String,java.lang.String,java.lang.String)
WARNING: Please consider reporting this to the maintainers of org.jolokia.util.ClassUtil
WARNING: Use --illegal-access=warn to enable warnings of further illegal reflective access operations
WARNING: All illegal access operations will be denied in a future release
I> No access restrictor found, access to any MBean is allowed
Jolokia: Agent started with URL https://<IP_ADDRESS>:8778/jolokia/
 ODPi Egeria
    ____   __  ___ ___    ______   _____                                 ____   _         _     ___
   / __ \ /  |/  //   |  / ____/  / ___/ ___   ____ _   __ ___   ____   / _  \ / / __    / /  / _ /__   ____ _  _
  / / / // /|_/ // /| | / / __    \__ \ / _ \ / __/| | / // _ \ / __/  / /_/ // //   |  / _\ / /_ /  | /  _// || |
 / /_/ // /  / // ___ |/ /_/ /   ___/ //  __// /   | |/ //  __// /    /  __ // // /  \ / /_ /  _// / // /  / / / /
 \____//_/  /_//_/  |_|\____/   /____/ \___//_/    |___/ \___//_/    /_/    /_/ \__/\//___//_/   \__//_/  /_/ /_/

 :: Powered by Spring Boot (v2.3.3.RELEASE) ::

15:07:39.414 [main] INFO  o.s.b.w.e.tomcat.TomcatWebServer - Tomcat initialized with port(s): 9443 (https)
15:07:45.935 [main] INFO  o.s.b.w.e.tomcat.TomcatWebServer - Tomcat started on port(s): 9443 (https) with context path ''

Mon Sep 14 15:07:40 GMT 2020 No OMAG servers listed in startup configuration
Mon Sep 14 15:07:45 GMT 2020 OMAG server platform ready for more configuration
^C%

To startup an alternative tool, the easiest way is by setting the name of the jar to run ie
jonesn:egeria/ (issue3580) $ docker  run --env JAVA_APP_JAR=user-interface/ui-chassis-spring-2.3-SNAPSHOT.jar  egeria                                                                                [16:10:28]
/usr/local/s2i/run: line 15: /opt/jboss/container/maven/default//scl-enable-maven: No such file or directory
Starting the Java application using /opt/jboss/container/java/run/run-java.sh ...
INFO exec  java -javaagent:/usr/share/java/jolokia-jvm-agent/jolokia-jvm.jar=config=/opt/jboss/container/jolokia/etc/jolokia.properties -XX:+UseParallelOldGC -XX:MinHeapFreeRatio=10 -XX:MaxHeapFreeRatio=20 -XX:GCTimeRatio=4 -XX:AdaptiveSizePolicyWeight=90 -XX:MaxMetaspaceSize=100m -XX:+ExitOnOutOfMemoryError -cp "." -jar /deployments/user-interface/ui-chassis-spring-2.3-SNAPSHOT.jar
WARNING: An illegal reflective access operation has occurred
WARNING: Illegal reflective access by org.jolokia.util.ClassUtil (file:/usr/share/java/jolokia-jvm-agent/jolokia-jvm.jar) to constructor sun.security.x509.X500Name(java.lang.String,java.lang.String,java.lang.String,java.lang.String,java.lang.String,java.lang.String)
WARNING: Please consider reporting this to the maintainers of org.jolokia.util.ClassUtil
WARNING: Use --illegal-access=warn to enable warnings of further illegal reflective access operations
WARNING: All illegal access operations will be denied in a future release
I> No access restrictor found, access to any MBean is allowed
Jolokia: Agent started with URL https://<IP_ADDRESS>:8778/jolokia/
 ODPi Egeria

       ______                        _                  __  __   ____
      / ____/ ____ _  ___    _____  (_) ____ _         / / / /  /  _/
     / __/   / __ `/ / _ \  / ___/ / / / __ `/        / / / /   / /
    / /___  / /_/ / /  __/ / /    / / / /_/ /        / /_/ /  _/ /
   /_____/  \__, /  \___/ /_/    /_/  \__,_/         \____/  /___/
           /____/

 :: Powered by Spring Boot (v2.3.3.RELEASE) ::

2020-09-14 15:11:06.003 - INFO 1 --- [           main] o.o.o.u.u.springboot.EgeriaUIPlatform    : Starting EgeriaUIPlatform on e0ffcd3f85f6 with PID 1 (/deployments/user-interface/ui-chassis-spring-2.3-SNAPSHOT.jar started by jboss in /deployments)
2020-09-14 15:11:06.009 - INFO 1 --- [           main] o.o.o.u.u.springboot.EgeriaUIPlatform    : No active profile set, falling back to default profiles: default
^C%

Note that in both cases above there are some errors with jolokia
Will research redhat info to determine why - seems odd this should happen on a supported image

There's some further info on jolokia at https://developers.redhat.com/blog/2016/03/30/jolokia-jvm-monitoring-in-openshift/ --  jolokia adds a jvm agent, and can expose jvm metrics to openshift for better monitoring of java applications.

The warnings with egeria are no different to that seen by other users ie https://access.redhat.com/sites/default/files/attachments/read_timed_out.log
Looks like a deficiency in the base image. We saw similar issues with reflection on Java 11 with groovy - until that tool was updated correctly.
It's possible the jdk8 version may avoid this issue -- but since we're using a supported image, will look at following up /raising an issue

Followed up on the redhat UBI mailing list - see https://www.redhat.com/mailman/listinfo/ubi
Response from the dev team:
The good news is these are two known issues that we are going to resolve
in a release in the very near future.

 • https://issues.redhat.com/browse/OPENJDK-45 (Jolokia illegal
 reflective access) - being resolved by dropping Jolokia

 • https://issues.redhat.com/browse/CLOUD-3387
   (s2i/run attempts to source missing scl-enable-maven)

The next OpenJDK cumulative patch update is due in late October. We will
release a new container image with fixes for the above two issues (and
more) approx. a week later — this is so that folks who want a bit more
time with the bundled Jolokia get the updated OpenJDK in a micro-version
update before we remove it, and they have a little more breathing room
to plan a migration without worrying about unpatched CVEs at the same
time.

There's an excellent summary of available base images at
http://crunchtools.com/comparison-linux-container-images/
UBI clearly has a bigger image footprint, though that % difference seems noticeably less once Java is in use.
The key rationale for the change is around security and support -- long term support, security updates, tracking CVEs etc
Alpine is at the opposite extreme - it benefits from being small and light, but does not address these aspects -- and indeed the openjdk images based on alpine are similar. fine for developer, but not suitable for production.
Since the egeria docker image is key for production use - direct, or via an operator, it is important to address these issues
As above, the additional images used for tutorials & other demo environments are not so critical, and so at that point they will remain as-is.

I have also opted to go for Java 11 as the runtime, since this is the current supported LTS release. Experience over more than a year has suggested any compatability issues are addressed, amd this should offer a better security stance as well as performance for a production environment

completed


chore: add pr tmpl

For #373

@LinuxSuRen If there are no other issues, this pr is ready to be merged.


rendering/environment/defaults/default_environment environment isn't applied by default in the editor

Tested versions

Not reproducible in 3.x (tested in 3.6.stable)
Reproducible in 4.x (tested in both 4.0.4 and 4.4.dev)

System information
Godot v4.4.dev (8c9139f31) - macOS 14.6.1 - Multi-window, 1 monitor - Metal (Forward+) - integrated Apple M3 Max (Apple9) - Apple M3 Max (16 threads)
Issue description
3.x
default_env_3x.webm
4.x
default_env_44.webm
Steps to reproduce

Create a new project
Create a new Environment resource at the root of the project
Set rendering/environment/defaults/default_environment to your new environment
Modify the default environment resource
See that changes in the environment are not applied to the 3D viewport

Minimal reproduction project (MRP)
3.x-default-env.zip
4.x-default-env.zip

Does it work after restarting the editor?

Does it work after using Scene > Reload Saved Scene or restarting the editor?

I tried reloading the editor, with no luck.

I thought we removed the default environment in 4.0? Is there still code that handles it?

I thought we removed the default environment in 4.0? Is there still code that handles it?

There's all the code handling the "fallback environment". From what I saw, it's because the editor sets the preview environment as it doesn't see any set environment. The default environment is set as a fallback environment in the RenderingServer (scenario->fallback_environment), so it doesn't count and gets overridden.

Just tested the MRP locally. It seems to be working correctly actually

@clayjohn Forgot to add that I wanted the result in the editor.
I see that the preview environment popup "replaces" the default environment in the editor.

But the problem is that the settings clash with toon shaders. (i.e. the sky ambient lighting applies to the model, see the weird shadows in the model)

Just turn off the preview environment!

Just turn off the preview environment!

😬


ctr images pull fails with error failed to mount: no such device

Hi,
I experienced the newly released containerd 1.0.0, and I met an issue. It stops me from pulling an image from the very beginning before I experience more other operations.

INFO[0700] Apply failure, attempting cleanup             error="rpc error: code = Unknown desc = failed to mount: no such device" key="extract-812895026-I3_X sha256:70a75f17542ef0e6d2686f6ab9f89c22a859c0fe9f9c3abaddb1a893af4f476d"
ctr: failed to extract layer sha256:350d50e58b6cb4cef21d4b4a3460e82c3221bad93b31175c2cc387f744f3b5c2: rpc error: code = Unknown desc = failed to mount: no such device

What kind of device I miss?
And here is my environment:
~ # ctr --version
ctr github.com/containerd/containerd v1.0.0
~ # uname -a
Linux iZbp15v9x6qahe7kdrs7plZ 3.13.0-65-generic #106-Ubuntu SMP Fri Oct 2 22:08:27 UTC 2015 x86_64 x86_64 x86_64 GNU/Linux
~ # cat /etc/issue
Ubuntu 14.04.2 LTS \n \l

~ #

Do I need to add more patch to my system?

Kernel 3.13 is not supported atm https://github.com/containerd/containerd#runtime-requirements
AUFS snapshotter (https://github.com/containerd/aufs) may work, but no one has tested, I think
There are specific features used by containerd core code and snapshotters that will require a minimum kernel version on Linux. With the understood caveat of distro kernel versioning, a reasonable starting point for Linux is a minimum 4.x kernel version.

The overlay filesystem snapshotter, used by default, uses features that were finalized in the 4.x kernel series. If you choose to use btrfs, there may be more flexibility in kernel version (minimum recommended is 3.18), but will require the btrfs kernel module and btrfs tools to be installed on your Linux distribution.

Either way, 3.13.0-65-generic (2015) should not be used, as it has some vulnerabilities including dirtycow

Yeah, DirtyCow is severe and we have patched that.
I am not sure if my understanding is correct. Linux 3.18- cannot experience containerd 1.0.0+ in the future? I think it is really amazing.
How about the industry? They are much more legecy data centers which has a long way to upgrade kernel.

@allencloud The best approach here is for you to figure out the root cause of the mount failure (probably missing overlay) and make a case for supporting the changes required to support a specific kernel.
Even for Ubuntu 14.04.5, the kernel in use is 4.4, so that should support what is required.
For older kernels like this, we should probably looking adding full support for the naive snapshotter so that you can at least try it out. In the interim, give the btrfs snapshotter a try and see if that works.

For older kernels like this, we should probably looking adding full support for the naive snapshotter

should we reopen https://github.com/containerd/containerd/issues/830 ?


do not show users in last day of project as unavailable [PEOPLE-122]

JIRA: https://netguru.atlassian.net/browse/PEOPLE-122
Changes:

use Date.current.beginning_of_day date instead of Time.now when checking if Membership is unfinished

LGTM 👍


INET type should not assign a netmask based on tuple size

I noticed that INET and CIDR implementations are the same, but it's not the correct way to handle them. INET is just an IP address and it should not have netmask auto-assigned (here). Should we drop it?
The issue it's causing right now is that if we do any read operation it corrupts the Posgrex.INET struct, here is an example:
# stored in database
# retrieved by Ecto.Adapters.SQL.query!(Repo, "SELECT * FROM devices")
%Postgrex.INET{address: {10, 3, 2, 2}, netmask: nil}

# returned by repo operations and corrupted due to mask-guessing
# retrieved by Repo.one(Device)
%Postgrex.INET{address: {10, 3, 2, 2}, netmask: 32}

If you are okay with the change I'll make a PR.

I'm not sure I'm seeing the issue, but it's been some time since I've used Elixir.
Could you make a failing test case? Perhaps that would help me understand.

@adam12 you can see the test and changes at https://github.com/firezone/ecto_network/

I'm still unsure about the drawbacks of this change, but I'll accept a PR for it and we can ship it as a minor semver bump.

I'm going to close this for now. If you're still willing to submit a PR, please go ahead.


LGTM.com - false positive - Format expects 2 arguments but given 1

Description of the false positive
Format expects 2 arguments but given 1
Seems to be missing func as an argument?
URL to the alert on the project page on LGTM.com
https://lgtm.com/projects/g/haiku/haiku/snapshot/d26be28c9c1882a2fe59ca80fbcf9410053b590f/files/src/add-ons/kernel/bluetooth/btCoreData/BTCoreData.cpp?sort=name&dir=ASC&mode=heatmap#x84553362d74646aa:1

also
https://lgtm.com/projects/g/haiku/haiku/snapshot/d26be28c9c1882a2fe59ca80fbcf9410053b590f/files/src/add-ons/kernel/bluetooth/btCoreData/ChannelInterface.cpp#xf0961682136884f7:1

also
https://lgtm.com/projects/g/haiku/haiku/snapshot/d26be28c9c1882a2fe59ca80fbcf9410053b590f/files/src/add-ons/kernel/bluetooth/hci/acl.cpp#xba333aeaedca5123:1

also
https://lgtm.com/projects/g/haiku/haiku/snapshot/d26be28c9c1882a2fe59ca80fbcf9410053b590f/files/src/add-ons/kernel/bluetooth/hci/acl.cpp#x82dacf0a4f0ec54d:1

also
https://lgtm.com/projects/g/haiku/haiku/snapshot/d26be28c9c1882a2fe59ca80fbcf9410053b590f/files/src/add-ons/kernel/bluetooth/hci/acl.cpp#x15778d816ea76adc:1

also
https://lgtm.com/projects/g/haiku/haiku/snapshot/d26be28c9c1882a2fe59ca80fbcf9410053b590f/files/src/add-ons/kernel/bluetooth/hci/bluetooth.cpp#x7349db345b1eed06:1

I believe all of these will be fixed by https://github.com/Semmle/ql/pull/1987 (please allow approximately 2 weeks for the changes to reach LGTM).


Paperclip issue with multipart

Hi,
i used Active Admin and see they use Formtastic for the form code, i try to implement paperclip but i don't have luck, my form code are:
form :html => { :multipart => true } do |f|
f.inputs "Details" do
f.input :name
f.input :created_at, :label => "Publish Product at"
f.input :category
end
f.inputs "Images" do
f.has_many :assets do |p|
p.input :asset, :as => :file, :input_html => { :multiple => true }, :label => "Image", :hint => p.object.asset.nil? ? p.template.content_tag(:span, "No Image Yet") : p.template.image_tag(p.object.asset.url(:thumb))
p.input :_destroy, :as=>:boolean, :required => false, :label=>'Remove'
end
end
f.inputs "Content" do
f.input :description
end
f.buttons
end
My asset model is this:
class Asset < ActiveRecord::Base
belongs_to :product
has_attached_file :asset, :styles => { :large => "340x330#", :medium => "140x80#", :thumb => "70x70#" },
:url => "/products/:id/:style/:basename.:extension",
:path => ":rails_root/public/products/:id/:style/:basename.:extension"
validates_attachment_presence :asset
end
When i try to upload a new one, automatic load a missing.png and i search the image with the "choose File" button and when save, a "Can't Be Empty" message appears down my choose file button.
Are you see any error o problem with my code, thanks for the time.

On 04/11/2011, at 10:54 AM, Estanislao Vizcarra wrote:

f.has_many :assets do |p|
p.input :asset, :as => :file, :input_html => { :multiple => true }, :label => "Image", :hint => p.object.asset.nil? ? p.template.content_tag(:span, "No Image Yet") : p.template.image_tag(p.object.asset.url(:thumb))
p.input :_destroy, :as=>:boolean, :required => false, :label=>'Remove'
end

I don't recognise the code f.has_many :assets -- is that vanilla Rails, or something provided by a ActiveAdmin, or…?
Your form code looks nothing like well-formed ERB or haml, so I have no idea where to start helping you :)
Justin

Justin i put my solution here...
https://github.com/gregbell/active_admin/issues/719


Confusion around password grant

The documentation around the password grant currently states:

To obtain a token you should POST to /oauth/token. You should include your client credentials in the Authorization header ("Basic " + client_id:client_secret base64'd)

But isn't that a security concern? Lets say I embed the base64 of the client_id and client_secret in my JS, couldn't  anyone then unbase64 it and get my client_secret? I would have thought that you would only need to send the client_id for identification and the username + password for verification.
According to blogs like this one you're only ever meant send the client_id.

I'm a recent consumer of this node module. I too had the same question.
+1

The blog uses information from an old draft http://tools.ietf.org/html/draft-ietf-oauth-v2-16#section-4.3 from May 2011. But this Internet-Draft has expired on November 20, 2011.
So, no, you cannot use only client_id for password_grant

@visvk I'm no expert on OAuth, out of curiosity where is the requirement for client_secret based on?
Looking at https://tools.ietf.org/html/rfc6749#section-4.3 it seems like neither client_id or client_secret are required.

I'll just add my workaround for anyone who might be interested
app.post('/oauth/token', function (req, res) {

    req.body.client_id = '<clientID>';
    req.body.client_secret = '<clientSecret>';

    return result = app.oauth.grant()(req, res, function(response){
        res.statusCode = response.code;
        res.send(response);
    });
});

@visvk @mickadoo I believe the spec only requires clients to authenticate if they have client credentials:
...
   The authorization server MUST:

   o  require client authentication for confidential clients or for any
      client that was issued client credentials (or with other
      authentication requirements)
...

@ekosz I agree it is a security concern for public clients but not for confidential ones. Although I admit the main use cases for password grants are probably with public clients.
It seems node-oauth2-server should allow password grants for unauthenticated public clients and require authentication for confidential clients.

@abalmos you're right, but i saw that ekosz had client credentials issued, so by RFC he must use client authentication (client_id + client_secret). In my opinion ekosz is right too, that client credentials should not be used in public client (JS application).
... The authorization server should take special care when
  enabling this grant type and only allow it when other flows are not
  viable.

I think the auth server and client should minimize use of this granttype and utilize other grant types whenever possible.
I only quote from RFC. I'm no expert in OAuth 2.

I am also curious about this, can we get @maxtruxa to confirm this? It appears that currently the password grant (which I understand to be the resource owner password credentials grant outlined in the OAuth 2.0 spec, requires that a client secret be submitted but isn't the purpose of this flow to allow for trusted hosts to submit user credentials without the redirect?
For my application, I have a deployed OAuth 2.0 authentication server and an SPA served as static content from an nginx deployment so that they can be developed and redeployed in parallel. I want to authenticate users from my SPA without the need to have an active backend that exists only to proxy my OAuth requests.

To reiterate: Yes, the RFC requires clients to send the client_secret when using the password grant.
This requirement exists probably because the typical usage of OAuth is one where you don't expose username and/or password to the (often third-party) client. To prevent arbitrary clients from using the password grant you must ensure that the client is in fact allowed to use the password grant. You can't assume the client's identity by just looking at the client_id since it's public, so you need the public client_id and the private client_secret. The client_secret must not be exposed, so the conclusion is that only confidential clients can use the password grant.
If you need this functionality anyways, you can disable client authentication for selected grants through the requireClientAuthentication server option.
new OAuth2Server({
  // ...
  requireClientAuthentication: {password: false} // defaults to true for all grants
});

Possible keys for the object include all supported values for the token request's grant_type field (authorization_code, client_credentials, password and refresh_token).

[...] but isn't the purpose of this flow to allow for trusted hosts to submit user credentials without the redirect?

Trusted hosts, yes. If you're sending the token request from a SPA you're not a trusted host though.

@maxtruxa is this feature available in V3.0.0-b3.1 ? because I have this version on this module in my project but when I look into the code it is different than the github repository and there is no requireClientAuthentication in the code.

Trusted hosts, yes. If you're sending the token request from a SPA you're not a trusted host though.

What about the implicit flow for OAuth 2.0? How would you suggest a native application authenticate with an OAuth 2.0 endpoint? The client secret cannot be securely held in the native application in the same way it cannot be held in an SPA. I ask this legitimately, as I'm apparently missing some secret to setting this up as clearly native applications and SPAs do make use of these flows.


[GOBBLIN-349] Add gauges for number of job scheduler for gobblin cluster

Dear Gobblin maintainers,
Please accept this PR. I understand that it will not be reviewed until I have checked off all the steps below!
JIRA

[x] My PR addresses the following Gobblin JIRA issues and references them in the PR title. For example, "[GOBBLIN-XXX] My Gobblin PR"

https://issues.apache.org/jira/browse/GOBBLIN-349

Description

[x] Here are some details about my PR, including screenshots (if applicable):

Tests

[x] My PR adds the following unit tests OR does not need testing for this extremely good reason:
Only build is required.

Commits

[x] My commits all reference JIRA issues in their subject lines, and I have squashed multiple commits if they address the same issue. In addition, my commits follow the guidelines from "How to write a good git commit message":

Subject is separated from body by a blank line
Subject is limited to 50 characters
Subject does not end with a period
Subject uses the imperative mood ("add", not "adding")
Body wraps at 72 characters
Body explains "what" and "why", not "how"

@zxcware  Can you review? Changing histogram to gauge so that we know the total counts for different metrics. Original histogram has a window size=1min, which is almost similar to a counter metrics (because counter shows as a rate in sensor based ingraphs)


Allow method hooks to be disabled globally

Add a T::Utils.disable_method_hooks method to allow users to disable processing of method additions past that point.
Motivation
Recently, we've had a case in our codebase where we experienced a 100% slowdown in an endpoint due to the addition of a signature in one of our Active Record models. My research into what caused the problem lead me to realize that the method was triggering many Active Record callback methods to be defined on the returned object for every call of the method. This was causing all those methods to trigger the method added hooks since Sorbet was activated on the model class, thus causing the slowdown.
While I am still investigating the root cause of the problem in our codebase (i.e. understanding why all those callback methods are being added in the first place), I also wanted to make Sorbet behaviour more deterministic in production by adding an optional method to disable method hooks.
Afterall, in production, we eager load our application, and unwrap all of our signatures after boot. Thus, we don't expect any methods with signatures to be defined after that point, and can safely disable the method hooks. The added T::Utils.disable_method_hooks method should allow us to do that.
Test plan
I am not sure how to test this, since it changes global behaviour. I am open to suggestions.

Afterall, in production, we eager load our application, and unwrap all of our signatures after boot

As an alternative, what about a solution that raised in _on_method_added? That way, it would fail fast and you could tell what was going wrong, rather than having some methods silently never run their hooks.

... what about a solution that raised in _on_method_added?

The problem is that some Rails constructs add (or re-add) methods to classes at runtime during normal operations. For example, class_attribute setters will redefine their respective getter methods due to the way the feature is designed. If we chose to raise in those cases, our application would stop working.
However, those dynamically added methods have no relationship to Sorbet, since they will NOT be coming with their signatures anyway. There is not much point in Sorbet runtime trying to process those added methods, so I would like to be able to suppress their handling after some point where we feel confident that we were able to load all static methods with signatures.
BTW, I've examined the weird behaviour of the increased response time on our application and the reason seems to be related to a weird behaviour of Kernel#clone redefining the singleton class of the object being cloned, which, in our application ends up redefining all of the class methods of the original object on the newly created singleton class copy. Again, I am investigating further to understand the root cause and mitigate it, but I would also like to be able to tell Sorbet runtime to not consider any more method additions in hooks past a certain checkpoint.

My problem with this is that this implicitly gives people an API to turn off runtime method wrapping, which is a much larger API change than the problem witnessed.
i.e., it’s even more powerful than any T::Configuration thing that’s exposed right now (like default_checked_level)
for the problematic method / class, can you solve it by using T::Sig::WithoutRuntime.sig instead of sig?

This is indeed too big of a hammer, I will find a different way to solve the problem. Thanks for the consideration.


Add --hostname alias to odo url create

What type of PR is this:

/kind feature
What does this PR do / why we need it:
This adds the --hostname alias to the odo url create command since
similar tools such as oc use --hostname to create routes, and thus
a user may accidently enter --hostname instead.
This PR also reorganized the help usage so it's more inline with
"building up" on each example.
Which issue(s) this PR fixes:

Fixes https://github.com/redhat-developer/odo/issues/5379
PR acceptance criteria:

[ ] Unit test

N/A

[ ] Integration test

N/A

[X] Documentation

How to test changes / Special notes to the reviewer:
N/A
Signed-off-by: Charlie Drage<EMAIL_ADDRESS>

/lgtm
/approve


Add python_requires in setup.py

This argument prevents accident install pipenv on not supported python versions.
The syntax for this string you can find in PEP440.
Note: this feature works with pip 9.0+.

Sweet, thanks, good idea
Can you add python 3.3 to the exclude list?  Much appreciated!

@techalchemy done.

@techalchemy don't forget about README.md label with python versions, update too?

@techalchemy do not pay attention on my previous comment, that label updated after publishing.


Wrong output in REPL

---- elm repl 0.16.0 -----------------------------------------------------------
 :help for help, :exit to exit, more at <https://github.com/elm-lang/elm-repl>
--------------------------------------------------------------------------------
> square x = x * x
<function> : number -> number
> square 3
9 : number
> square 4
16 : number
> square 5
25 : number
> square 3
9 : number
> square 4
9 : number
> square 5
25 : number

Notice the second square 4 returns 9 instead of 16.

Cannot reproduce:
---- elm repl 0.16.0 -----------------------------------------------------------

 :help for help, :exit to exit, more at <https://github.com/elm-lang/elm-repl>
--------------------------------------------------------------------------------

> square x = x * x
<function> : number -> number
> square 3
9 : number
> square 4
16 : number
> square 5
25 : number
> square 3
9 : number
> square 4
16 : number
> square 5
25 : number
>

It's not deterministic.
---- elm repl 0.16.0 -----------------------------------------------------------
 :help for help, :exit to exit, more at <https://github.com/elm-lang/elm-repl>
--------------------------------------------------------------------------------
> square x = x * x
<function> : number -> number
> square 3
9 : number
> square 4
9 : number

Something funny happening on your machine (concurrently to the elm-repl session)?
Like, some other thread preventing elm-repl from writing the temporary files to disk (quickly enough) that it uses to talk to the compiler (or some such)?

That might be. It does seem to be related to the speed at which things are entered into the REPL. Perhaps related to #76 ?

Yep, looks like it is #76. You might close this issue here and instead leave a comment over there with your additional report. Specifically, reporting that the problem persists with Elm 0.16 (whereas the report there was with an older version).

Closing in favor of #76.


Add update  to display themes on marketplace

Github search api is broken so need to update to have repo displayed

Does having a new commit get them included in search results? That is bizarre...

@theRealPadster Yup, believe github might've done some weird mass purging of the topic for some reason.


go build fails due to undefined references

Go build fails with the following errors.

../sweetiebot/sweetiebot.go:499: undefined: discordgo.ChannelType
../sweetiebot/sweetiebot.go:500: undefined: discordgo.ChannelTypeGuildText
../sweetiebot/sweetiebot.go:500: undefined: discordgo.ChannelTypeGuildCategory
../sweetiebot/sweetiebot.go:500: undefined: discordgo.ChannelTypeGuildVoice

From the readme:

Note that sweetiebot requires the develop branch of discordgo. To switch, you will need to find where
Golang downloaded the discordgo library, open a terminal in that directory, and use the command git
checkout develop. Failure to do so will cause random compilation errors due to missing features. If
you're having any additional issues getting sweetiebot working, check INSTALLATION.md for more information.

I didn't see that in the readme.md. I was following INSTALLATION.md which makes no mention of switching/downloading the development branch.

Install the required libraries with the commands go get github.com/go-sql-driver/mysql and go get github.com/blackhole12/discordgo.

I deleted INSTALLATION.md, which was out of date.


Implement -printf/-fprintf

Based on a patch by Fangrui Song<EMAIL_ADDRESS>Closes #16.

Thanks! -printf '%P\n' is really helpful to me . Its output can be fed rofi to get a nice launcher. https://github.com/MaskRay/Config/blob/master/home/bin/rofi-file-browser


Remove AWS SDK v1 from S3 Source

Is your feature request related to a problem? Please describe.
The S3 Source imports aws-java-sdk-s3 v1 in order to use the S3 Event Notification model. This adds unnecessary dependencies into Data Prepper.
Describe the solution you'd like
Create an internal model representation of the S3 Event Notification structure. Use Jackson's @JsonIgnoreProperties so that we can model only the parts we need.

@dlvenable I can take this one. Then I'll try to stop taking your "good first issue" ones. :)

Thanks @jzonthemtn ! Feel free to take as many "good first issue" items as you'd like. :)

Resolved in #1628 .


Non-linear terms in a Nedelec vector space

Hello !
I would like to solve the following equation :

in a Nedelec vector space.
Do you have any idea of an example that can help me? At first glance I don't really see a similar example.

Hi @LeilaSalomon,
Can you clarify what the weak formulation is?
Typically you would not use H(curl) elements for u.
Tzanio


Restore-DbaDatabase: Feature Request - add file counter to progress

Feature Request
User may want to know how much files restored, for big TLOG files its maybe useful to see when restore process finished (%
Problem to solve
Be informed on how process going

Rolling this into you other issue as it's fairly simple
Going with "Backup x of y" as an addition to the progress bar. That OK?

Yeah! It ok =)

Cool, will close this now


in the README the datastore sample does not compile.

For example, Datastore datastore = DatastoreOptions.getDefaultInstance().service();
does not seem to work with 0.0.10

Yes, the README examples got updated too soon.  This example will work once we release version 0.0.11, which should be coming very soon (pending some testing in core).  The old way should still work, for example:
StorageOptions options = StorageOptions.builder().projectId("my_project_id").build();  Storage storage = StorageFactory.instance().get(options);

Also the javadoc (available on the website and also packaged with version 0.0.10) should have examples that are in sync with the release version.

Got it, thanks!

@ajkannan just released 0.0.11 so maven should be consistent with site again.

0.0.11 does not work with:
Datastore datastore = DatastoreOptions.getDefaultInstance().service();

@ludoch Sorry for this, the method getDefaultInstance is not part of the DatastoreOptions interface, I don't know how it happened to be in the README. To get a Datastore service instance with default options try:
Datastore datastore = DatastoreOptions.builder().build().service();

I'll take care of fixing this, either by adding the getDefaultInstance method or by updating the READMEs

@ludoch In #357 we add back a defaultInstance method to StorageOptions and DatastoreOptions and update both READMEs and website's landing page (will be available on the next release).
Do you think we can close this?

0.0.12 which includes adding back the defaultInstance methods is out but I think we need to merge #389 before closing this issue.

#357 and #389 are merged so I am closing this. Feel free to reopen it if need be.


feat: First release of the MemGPT Helm chart

Please describe the purpose of this pull request.
This pull request adds a new Helm Chart for the memgpt server. This allows managing different instances on a Kubernetes cluster.
How to test
Clone the branch, then run: helm upgrade --install my-memgpt ./helm/charts/memgpt
Follow the instructions provided by Helm.
Please note the following requirements:

A Kubernetes cluster or Docker with Kubernetes enabled
The Helm CLI

Have you tested this PR?
Yes, I'm testing the Helm chart with a live run.
Related issues or PRs
No related issues.
Is your PR over 500 lines of code?
I cannot split it. The Helm chart is self-contained in the initial release.
Additional context

Thanks for contributing this! Should I test this with the instructions in helm/README.md?
I wonder if there is a way to add automated tests for this in the way that we have for the docker container. Even if not, we can merge this in as a v1.

Thanks for contributing this! Should I test this with the instructions in helm/README.md?
I wonder if there is a way to add automated tests for this in the way that we have for the docker container. Even if not, we can merge this in as a v1.

Yes, you can test it right now :) I forgot to document it! You can test the Helm chart by simply typing: helm test <release-name>. The tests make a call to the service of the frontend application.
It might be better to have a health check API for the application that could be invoked, or a set of APIs to simulate a chat or similar interactions.
For further information, you can check the Helm Chart documentation at Chart test.


Allow specifying loopback interface to listen on in aquireTokenInteractive method of PublicClientApplication class

Core Library
MSAL Node (@azure/msal-node)
Wrapper Library
Not Applicable
Public or Confidential Client?
Public
Description
I have an electron application for windows that is using aquireTokenInteractive to login the user and fetch access token.
The problem is, this method starts a node server on a random port and all interfaces which forces windows to show a firewall prompt to the user.
Windows won't show the prompt if it's only listening on localhost which is how the authentication process works currently.
Solution: Allow to define the interface for the server to listen for incoming requests.
Source
External (Customer)

@tnorling I think this issue and #5442 can be discussed in tandem. Any thoughts on configurability of the server address here? I'm assuming the random port was an intentional design choice?

@hectormmg Yes - these are similar but different so let's leave both open for now. @pratikfuse I've created an internal work item to track these and we'll provide an update here when we have committed to it.

Sure, thank you for your input @hectormmg and @tnorling

@pratikfuse a loopback client interface for acquireTokenInteractive API has been added to msal-node, which will be available in the next release (see). This should help mitigating the issue you are having. Please have a look at the ElectronSystemBrowserTestApp sample for a usage example. Closing, but let us know if you have more questions or issues.


Add questions

Add questions for the game

Question Format: Each question is presented as a brief text-based statement or query that requires a concise and quick response.

Time Limit: As the name suggests, players have a limited amount of time to respond to each question, usually set at 30 seconds. This time constraint adds an element of urgency and excitement to the game.

Objective: The objective of the game is to answer as many questions as possible within the given time frame. Points or scores may be awarded for correct answers.

Variety of Questions: "30 Seconds" games often include a wide variety of questions that can cover a broad range of topics, such as general knowledge, trivia, word puzzles, riddles, or even personal and subjective questions.

Turn-Based or Rapid Fire: Depending on the specific rules of the game, it can be turn-based, where each player or team takes turns answering questions, or it can be rapid-fire, where questions keep coming one after the other, and players must respond quickly.

Correct Answers: Correct answers are typically rewarded with points or some form of in-game currency. These points may contribute to a player's overall score or determine the winner.

Incorrect Answers: In some versions of the game, incorrect answers might result in a time penalty or the loss of a turn.

Winning Condition: The player or team with the highest score or the most correct answers at the end of the game wins.

Game Variations: There can be variations of the "30 Seconds" game with additional rules or challenges, such as bonus rounds, special categories, or unique gameplay mechanics.

Issue is depending on:
#21

Good luck @123HelloBob !

where should i put the questions? is there a specific file or just anywhere?

a specific folder in the src directory would do. however if you have a creative approach to this matter then go ahead!


Add ECAdd() Bloq

Adds ECAdd bloq with classical simulation. I broke the bloq into the 6 steps shown in https://arxiv.org/abs/2306.08585. I classically simulated all steps. I put in a shimmed ModInv classical implementation (it's not montgomery mod inversion, but it still works on ECPoints not in montgomery form; I'm a little stuck on understanding what to do for R in montgomery mod inversion).

Dependent on https://github.com/quantumlib/Qualtran/pull/1424. For testing purposes I put the bug fix in this branch too, but it should be merged first.


Further update of kong role to be dynamic based on ingressClass

Signed-off-by: Kristian Haugene<EMAIL_ADDRESS>
What this PR does / why we need it:
Same as #10263, the Kong role needs to be dynamic based on what is set as ingressClass.
Previous PR seems to have used "kong" as ingressClass, and so it worked with ...kong-{{...}. The election-id is however also based on ingressClass so we need to substitute twice.
Special notes for your reviewer:
Since the configmap is a concatenation of election-id and ingressClass, can we skip the ingressClass in election-id itself?
So we go from:
- --ingress-class={{ .Values.ingressController.ingressClass }}
- --election-id=kong-ingress-controller-leader-{{ .Values.ingressController.ingressClass }}

to
- --ingress-class={{ .Values.ingressController.ingressClass }}
- --election-id=kong-ingress-controller-leader

And can then have resourceNames:
- "kong-ingress-controller-leader-{{ .Values.ingressController.ingressClass }}

Checklist
[Place an '[x]' (no spaces) in all applicable fields. Please remove unrelated fields.]

[x] DCO signed
[x] Chart Version bumped
[x] Variables are documented in the README.md

/assign @shashiranjan84

/ok-to-test

@haugene Thank you for the fix!
/lgtm


Using bearssl as backend provider

Should check carefully the changes and make sure wrappers are working as expected
#184

Closed, because this should not be merged into master.
See --> https://github.com/cossacklabs/themis/issues/184


[WIP] :bug: sharded-test-server: Add external-hostname flag

Summary
We are seeing real cluster deployments of KCP fail because the external-hostname and shard-external-url flags typically point to the front-proxy endpoint, this aligns the e2e behavior so we can work through the issues with chicken/egg availability during shard bootstrapping and discuss the best solution.

@ncdc I think this reproduces the issues seen in "real" cluster deployments, because we're using the ExternalAddress for the vwURL since https://github.com/kcp-dev/kcp/pull/2407 - I tried to work around that in https://github.com/kcp-dev/kcp/pull/2667
How is controller sharding handled?  I assume we can't just use ShardBaseURL for the controller traffic because it may potentially need to be routed to another shard via the proxy indexer?

@hardys I think I missed your question above somehow. Wanted to follow up and see if we still want this PR? If so, how can I help?


GC unused includes and code.

Unify with nested includes.
@toregge PR

Build failure is unrelated.


[FEA] decide skip agg or not based on not only first batch

This is a follow up issue on #11712 per requested by https://github.com/NVIDIA/spark-rapids/pull/11712#discussion_r1850391778.
(for skip agg logic) :

Right now we check the first batch and decide for the entire task if we want to skip full aggregation or not. I think it would probably be better if we did it for each batch individually. We could even do it for each batch when we merge them too.

This priority of this issue depends on whether we'll need it in real customer cases. For now we just leave it as a TODO

@revans2  https://issues.apache.org/jira/browse/SPARK-31973  looks like in progress, why you mentioned " is in all versions of Spark that we support." ?


cmd/go: options missing from cgo whitelists

The recent security patches for cmd/go (#23672) added a whitelist of options permitted for use with cgo.  Several different people have reported packages that fail to build by default because they use options that are not on the whitelists.  This issue is intended to collect a list of all the missing options, so that we can add them in a single CL.

#23737 reports that flags generated by pkg-config -libs are being checked against the compiler whitelist, and CGO_CFLAGS_ALLOW, when they should instead by checked against the linker whitelist and CGO_LDFLAGS_ALLOW.  There is a CL to fix this: https://golang.org/cl/92755.

The linker whitelist should accept .a files as it already accepts .o, .so, etc., files.  There is a CL to fix this: https://golang.org/cl/92855.

Comments on #23672 list these compiler options:
-fno-exceptions
-fno-rtti
-fpermissive

and these linker options:
-Wl,-framework
-Wl,--no-as-needed

#23742 suggests adding the compiler option  -fmodules.  The clang compiler supports a number of -fmodules options, but it's not clear that they are all safe.  In particular -fmodules-cache-path and -fmodules-user-build-path would seem to permit specifying a path that clang will use to read modules, which could perhaps change the compilation mode in various ways.

#23743 suggests adding the linker option -Wl,--no-as-needed.  There is a CL for this: https://golang.org/cl/92795.

#23744 suggests adding these compiler options:
-finput-charset=UTF-8
--std=c99
-pedantic-errors

There are many compiler and linker options that may be used with either a single dash or a double dash.  We should be similarly lax in the whitelists.

For orthogonality, I forget if the option to add a directory to -framework's search path is already covered or not. I also forget what option that is. (The typical use case that I can think of is /Library/Frameworks, which is where Apple puts app-specific frameworks, and is not searched by default.

When using:
#cgo !windows pkg-config: --static ${SRCDIR}/vendor/libgit2/build/libgit2.pc

compilation fails with the following message:
invalid pkg-config package name: --static

Looking over the code it appears there aren't any enviroment variables that can be used to whiteslist pkg-config arguments.

@rgburke pkg-config output goes through the same FLAGS_ALLOW variables as other outputs.
However, it appears that pkg-config -libs checks CGO_CFLAGS_ALLOW when it ought to check CGO_LDFLAGS_ALLOW.

We link a large number of C libraries statically in a closed-source project. Up until now we have been doing the following:
#cgo LDFLAGS:/path/to/one/liblibrary1.a
#cgo LDFLAGS:/path/to/two/liblibrary2.a
etc.

This is of course disallowed now. A workaround:
#cgo LDFLAGS:-L/path/to/one -llibrary1
#cgo LDFLAGS:-L/path/to/two -llibrary2

However some of these directories contain dynamic libraries too, which confuses the linker. Another option is to add '/' to the list of allowed "names" in https://go-review.googlesource.com/c/go/+/92855
the latter option fixes our issue.

@mirtchovski there's a patch for that (the issue is that .a was not whitelisted, but other object file formats were)

.a is not whitelisted so 'libsomething.a' will work, but '/path/to/libsomething.a' will not work.

@ianlancetaylor @rgburke I actually ran into the very same problem with --static which lead me down the hole to #23737.  --static is rejected because it doesn't appear to be a valid package name before attempting to execute pkg-config, here https://github.com/golang/go/blob/master/src/cmd/go/internal/work/exec.go#L939-L940.
Our quick fix internally was to point PKG_CONFIG to a script which simply executed pkg-config --static "$@".

@jeddenlea - Thank you very much! I was trying to find a workaround but didn't think of that.

We hit this with -msse and -msse4.2.

I hit this issue with "${SRCDIR}/file.o" in cgo LDFLAGS.
I'd like to argue that we should allow plain filenames that is linker input
files in LDFLAGS
(at least *.a, *.o and *.so).
Unlike .a and .so which in theory could be handled with "-L${SRCDIR}
-lname", adding
extra object files to linker command cannot be fixed that way.
A workaround is to set CGO_LDFLAGS_ALLOW, but that's very cumbersome.
Another
alternative is to rename my file.o into file.syso, however, for my specific
case, I can't use
this option because I only include that file.o when a specific build tag is
included (the
build tag applies to file that contains the #cgo LDFLAGS preamble) and
there is no way
to set arbitrary build tag in syso filenames.
If we ignore previous deployed Go versions, we might be able to include a
new
"#cgo LDLIBS" that is designed specifically for adding more files to linker
command line.
Then we can have a stricter rule for LDLIBS (filenames only, and no dash
allowed in prefix.)

We've hit this with --std=c99

-std=c++11
I guess -std= should be white listed?

Probably on whitelist: -fopenmp
Error when building bimg package using Go v1.10rc2,
23:24 ~/go-test
master ms 130 % go get -v github.com/h2non/bimg
github.com/h2non/bimg (download)
github.com/h2non/bimg
go build github.com/h2non/bimg: invalid flag in pkg-config --cflags: -fopenmp

I'm unable to whitelist -isystem as the argument next to it (which is a path) will be denied

We also needed to use this workaround: https://github.com/golang/go/issues/23749#issuecomment-364239496
We previously had:
#cgo linux LDFLAGS: ${SRCDIR}/../../../../path/to/thing/libthing_static.a

and have shifted to:
#cgo linux LDFLAGS: -L${SRCDIR}/../../../../path/to/thing -lthing_static

The .../path/to/thing is outside ${SRCDIR}.
Adding this comment so this issue includes an example with a libthing.a reference that needs SRCDIR expansion to resolve.

What is -Wl,-framework for? If that's the Apple framework, it has an argument, so you'd probably want -Wl,-framework,foo. But if it's the Apple framework then -framework (no -Wl,) works just as well.

With 1.10rc2, golang.org/x/net/internal/socket doesn't build any more for Solaris.
$ GOOS=solaris go build golang.org/x/net/ipv4
# golang.org/x/net/internal/socket
ext/src/golang.org/x/net/internal/socket/sys_solaris.go:24:3: //go:cgo_import_dynamic libc___xnet_getsockopt __xnet_getsockopt "libsocket.so" only allowed in cgo-generated code
ext/src/golang.org/x/net/internal/socket/sys_solaris.go:25:3: //go:cgo_import_dynamic libc_setsockopt setsockopt "libsocket.so" only allowed in cgo-generated code
ext/src/golang.org/x/net/internal/socket/sys_solaris.go:26:3: //go:cgo_import_dynamic libc___xnet_recvmsg __xnet_recvmsg "libsocket.so" only allowed in cgo-generated code
ext/src/golang.org/x/net/internal/socket/sys_solaris.go:27:3: //go:cgo_import_dynamic libc___xnet_sendmsg __xnet_sendmsg "libsocket.so" only allowed in cgo-generated code

@piotrnar CGO_LDFLAGS_ALLOW='.*\.a$'

@ianlancetaylor, thank you!
that will do for me, but telling all the other people who use my project to do CGO_LDFLAGS_ALLOW='.*\.a$' for go 1.9.4 seems a bit dodgy.
hopefully there will be a better (out of the box) solution in the future.

@piotrnar Yes, the point of this issue is to collect all the changes we need to make to the whitelist.  Certainly we will be whitelisting .a files.

can you please add also fstack-protector?
thanks :)

Whitelist -static-libstdc++ please.

The package https://github.com/flynn/hid fails to build with 1.9.4 due to passing -fconstant-cfstrings via LDFLAGS on darwin.

Please add these linker flags to the white list
-Wl,-Bstatic
-Wl,-Bdynamic
-Wl,--start-group
-Wl,--end-group

Honestly: At this point a blacklist of bad options seems more useful than such an extensive whitelist to me.

Going forward, a blacklist would mean that if some new potentially-insecure compiler option were introduced, all Go releases would become vulnerable to that option.  To the extent that we can protect against this kind of attack at all, I think it has to be a whitelist.

some new potentially-insecure compiler option were introduced

I still think blacklist is preferable. Because it cuts both ways. If any new compiler option can't be utilized until it is whitelisted, that would seem to require a new Go release every time any new C compiler adds a flag...

@glycerine That's why we provide the environment variables as an escape hatch.  You can always use the environment variables until the whitelist is updated.

The problem is that env variables don't work for projects that are installed purely through 'go get'.
Another approach: allow the top level, named go project to set environment variables.
Then the primary 'go build' project being installed can whitelist the flags it needs, e.g. using the ALLOW regex, while still preventing dependent projects from doing aribitrary things.

@glycerine I'm not sure I understand how that would work.  But I suggest that you open a separate issue for that suggestion, rather than discussing it on this issue, which is intended to collect options that need to be whitelisted.

For now we've decided on a whitelist. That may change in the future but this issue is not the place to discuss it (feel free to file a new one). We are trying to collect options that should be whitelisted here and nothing more.
Thank you.

invalid flag in #cgo CFLAGS: -pipe

go build github.com/zchee/docker-machine-driver-xhyve/vendor/github.com/zchee/libhyperkit: invalid flag in #cgo CFLAGS: -fno-common

Hi, please add these flags to the whitelist, -Wl,--enable-new-dtags

Can't build therecipe/qt
go build github.com/therecipe/qt/core: invalid flag in #cgo CFLAGS: -pipe

Adding ".*.a" to the allowed flags would be great.
See https://github.com/golang/go/issues/23807

--mms-bitfields also seems be required.

Isn't it reasonable to assume that every compiler option exists for a reason, and the whitelist should cover all of them except the ones specifically deemed dangerous? Obviously there's hundreds of them and the maintenance of the white list isn't going to be fun, but if that's the path that's decided on...

Isn't it reasonable to assume that every compiler (and linker, etc) option exists for a reason, and the whitelist should cover all of them except the ones specifically deemed dangerous? Obviously there's hundreds of them and the maintenance of the white list isn't going to be fun, but if that's the path that's been decided on...

At which point does a whitelist full of wildcards and regexes becomes a blacklist in disguise?

Isn't it reasonable to assume that every compiler (and linker, etc) option exists for a reason, and the whitelist should cover all of them except the ones specifically deemed dangerous? Obviously there's hundreds of them and the maintenance of the white list isn't going to be fun, but if that's the path that's been decided on...

This has probably been discussed internally but I found the thing surprising for a patch release: I would have expected the offending flags to have been blacklisted first to plug the compiler plugin hole, and a whitelist system enabled for 1.10, whose list could have been built up during RC. The extra env vars are not quite practical to integrate in some build systems, and I observed this leads to people just reverting to 1.9.3 and thus being completely unprotected, which I believe is entirely counterproductive.
At which point does a whitelist full of wildcards and regexes becomes a blacklist in disguise?

gomobile uses the flags -fobjc-arc -fmodules -fblocks:
https://github.com/golang/mobile/blob/5704e182c7003d4b7e94c23373f3fad4e5ceb25a/bind/genobjcw.go#L319

https://github.com/augustoroman/v8 uses -pthread:
https://github.com/augustoroman/v8/blob/master/v8.go#L15

-flto
Could you put an alphabetically sorted list of the "approved" ones at the top of this issue for overview until the next update is out? Whoever submits the CL may appreciate that as well.

Right now (especially since this issue exists) I'm more concerned about what's slipping through the cracks: what build flags people have removed from their projects without consulting us first, giving them the misguided belief that cgo (and by extension Go) is broken and buggy and has regressions and its developers don't know what they are doing. :S (Or worse, you don't know what you are doing and are obviously building my package wrong, because you are the one missing dependency xyz!)
Some of the "referenced this issue" links list more blacklisted flags that aren't in this issue proper yet,
This makes me wonder if gcc and clang themselves could, or even should, provide an option --no-unsafe-options that a) would do the dirty work for us b) be resilient to future changes and c) cannot be turned off by another option (once it's there, it's there, period).

If we insist on a whitelist, then I don't know why there needs to be any delay waiting for input.
The compilers document their flags. As someone said above, each flags is there for a reason.
Sampling by waiting for user input on usage will be under-representative, unreliable, and produce painful results for all of us who in the future find need for a flag that wasn't realized or sampled now.
Moreover it seems straightforward to derive the white list by this procedure, in pseudo code:
List all the C/C++ compilers and versions of each compiler supported;
For each compiler-version, list all the flags available from their docs;
For each flag, decide to put it on the whitelist or the (invisible) blacklist.
Add whitelisting code for all the flags on the accumulated whitelist.
I still think this is crazy (verging on reductio ad absurdum) compared to blacklisting the one (or two) vulnerable flags. But in all seriousness, if we're going to insist on a whitelist, the algorithm above is correct, eliminates the guesswork, and can be executed without delay.  Perhaps the only additional user input required would be to establish the range of compilers/versions to be supported.

The only options that matter here are the ones that are reasonable to put on a #cgo CFLAGS or #cgo LDFLAGS line in a .go file, or are reasonable to output from a call to pkg-config --cflags or pkg-config --libs.  That is a small subset of the total number of compiler options.

You also vastly underestimate how many options gcc and clang even have. I doubt they are all documented, even in the source code — I wouldn't be surprised if some are generated at runtime!

@anacrolix Over in #23672 you suggested that we need to whitelist -Wl,-framework.  But -framework normally takes an option.  Can you show the exact use case?  Thanks.

You also vastly underestimate how many options gcc and clang even have

@andlabs Ian is a gcc developer. I'm sure he's well aware.

I sent a CL that I think covers all of the above options: https://golang.org/cl/93836.
Please let me know if you see any problems with it or if you know of any options people are using that it does not cover.  Thanks.

From LLVM Go bindings point of view, following linker options should be in the white list.

-Wl,-search_paths_first
-Wl,-headerpad_max_install_names

@magical I was talking to @glycerine

@andlabs Ah, sorry

@ianlancetaylor With that CL I still cannot build golang.org/x/net/internal/socket for Solaris. It's not obvious to me from the error what flags I need to ask for.
$ ./bin/go version
go version devel +09dc376990 Tue Feb 13 20:58:04 2018 -0800 darwin/amd64
$ GOOS=solaris ./bin/go build golang.org/x/net/ipv4
# golang.org/x/net/internal/socket
../../ext/src/golang.org/x/net/internal/socket/sys_solaris.go:24:3: //go:cgo_import_dynamic libc___xnet_getsockopt __xnet_getsockopt "libsocket.so" only allowed in cgo-generated code
../../ext/src/golang.org/x/net/internal/socket/sys_solaris.go:25:3: //go:cgo_import_dynamic libc_setsockopt setsockopt "libsocket.so" only allowed in cgo-generated code
../../ext/src/golang.org/x/net/internal/socket/sys_solaris.go:26:3: //go:cgo_import_dynamic libc___xnet_recvmsg __xnet_recvmsg "libsocket.so" only allowed in cgo-generated code
../../ext/src/golang.org/x/net/internal/socket/sys_solaris.go:27:3: //go:cgo_import_dynamic libc___xnet_sendmsg __xnet_sendmsg "libsocket.so" only allowed in cgo-generated code

@calmh Yes.  I think we're going to have to fix that one with changes to golang.org/x/net.  It is already relying on many internal details, and I think we need to change the way it does so.

@calmh Would you be able to test https://golang.org/cl/94015 on an actual Solaris system?

@rsc @ianlancetaylor @anacrolix I figured out where -Wl,-framework is coming from: it's coming from the pkg-config file for GLib, which is a dependency of GTK+. Specifically, it includes the CoreFoundation link for internationalization purposes.
Specific references: https://gitlab.gnome.org/GNOME/glib/blob/master/glib-2.0.pc.in#L14 where @INTLLIBS@ gets -Wl,-framework -Wl,CoreFoundation from https://gitlab.gnome.org/GNOME/glib/blob/master/m4macros/glib-gettext.m4#L143
There are other -Wl,-framework instances in various other pkg-config files; some are part of the projects themselves (as above), and some are injected by Homebrew. On my system right now, I see libcdio and SDL both use -Wl,framework,FrameworkName. (Which means, yes, both -Wl,-framework -Wl,FrameworkName and -Wl,-framework,FrameworkName are found in pkg-config files. Go figure.)

@calmh Trying a different approach in https://golang.org/cl/94018.

@andlabs Thanks, added to CL 93836.

I'm static linking SDL and the pgkconfig contains -Wl,--no-undefined as well as preprocessor defines.

I need you to add the flags below the white list, so they can compile projects that use the cgoemitter package
go build github.com/supermock/cgoemitter-demo/x: invalid flag in #cgo LDFLAGS: -Wl,-unresolved-symbols=ignore-all
Thank you very much in advance

Update CL again.

I've added a wiki page to describe this problem at https://golang.org/wiki/InvalidFlag, and I'm updating the CL so that the error message points people to the wiki.

invalid flag in #cgo LDFLAGS: -O3

Also receiving this issue, if the following can be added
go build github.com/andlabs/ui: invalid flag in #cgo LDFLAGS: -mmacosx-version-min=10.8

@bgk- The patch that has been applied addresses that. If upgrading to 1.10 isn't feasible right now, I'd have to suggest waiting to see if a 1.9.5 happens.

Should 1.10 have fixed the invalid pkg-config package name: --static issue? I jus pulled down the latest version from homebrew and I'm still seeing it:
➜  ~ go version
go version go1.10 darwin/amd64
...
➜  ~ go build
...
go build github.com/flier/gohs/hyperscan: invalid pkg-config package name: --static

@ptoomey3 See #23875

Reopening for 1.9.5.

I will avoid the X Y problem and rather explain fully what I'm doing. I'm creating an postgresql extension in go with -buildmode=c-shared.
In the documentation for creating C extensions for postgresql is this as the way to build the shared object:
cc -fPIC -c foo.c
cc -shared -o foo.so foo.o

So I've added #cgo LDFLAGS: -shared to my source code. It worked until recently (go1.10) when it stops building with:
invalid flag in #cgo LDFLAGS: -shared

Just grabbed go 1.10, ran into this:
invalid flag in #cgo LDFLAGS: -Wl,-static
This is a gcc linker flag to force static linking for anything after that option on the link line.

@spackard For the record, that is not what that option means.  You are thinking of -Bstatic.  The -static option directs the linker to not search for any shared libraries to satisfy any -l options.  -static is not a positional option; it doesn't matter where it appears on the command line.

@ianlancetaylor You're correct about the positional. It is how we're forcing static linking regardless. For the record, adding it to CGO_LDFLAGS_ALLOW does work.

I am having the same issue
invalid flag in #cgo CFLAGS: -m32

We hit this -O3, -static-libgcc and -static-libstdc++
-O3:
#cgo windows LDFLAGS: -O3 -L./ -lmass -static-libgcc -static-libstdc++
#cgo linux LDFLAGS: -O3 -L./ -lmass -ldl -lm -lrt -static-libgcc -static-libstdc++
#cgo CFLAGS: -O3
invalid flag in #cgo LDFLAGS: -O3
-static-libgcc:
#cgo windows LDFLAGS: -L./ -lmass -static-libgcc -static-libstdc++
#cgo linux LDFLAGS: -L./ -lmass -ldl -lm -lrt -static-libgcc -static-libstdc++
invalid flag in #cgo LDFLAGS: -static-libgcc
-static-libstdc++:
#cgo windows LDFLAGS: -L./ -lmass -static-libstdc++
#cgo linux LDFLAGS: -L./ -lmass -ldl -lm -lrt -static-libstdc++
invalid flag in #cgo LDFLAGS: -static-libstdc++
using hardcoded static whitelists is a bad idea, maybe we should use an config file with some default settings like
$GOROOT/bin/cgo.cfg
[whitelists]
blablabla
...

@kruglinski You can customize by using the CGO_CFLAGS_ALLOW environment variable and friends.

@ianlancetaylor
Sorry, I just missed about this, :-) Good to know, many thinks!

#24124 reports the following linker option:
-Wl,-z,relro

Compiler option -Wl,--subsystem,windows and linker option -mwindows are both missing.

I'm trying to make gomobile/gobind generate standalone bindings. Some of that work involves converting CGO_*FLAGS environment variables to #cgo directives, which uncovered a few more flags:
-isysroot <path> (ios)
-mios-simulator-version-min=<version> (ios)
-miphoneos-version-min=<version> (ios)

-target <machine-tuple> (for android)
-sysroot <path> (for android)
-gcc-toolchain <path> (for android)

I believe all but the last, -gcc-toolchain, are safe to add to the whitelist.

Following flags are needed to build Go bindings for Godot game engine without CGO_LDFLAGS_ALLOW on macOS:
-Wl,-undefined,dynamic_lookup

More CFLAGS from zchee/libhyperkit:

-fmessage-length=152
-fdiagnostics-show-note-include-stack
-fmacro-backtrace-limit=0

v8worker needs -stdlib=libstdc++ on Mac OS X.

CL 102818 OK for Go 1.9.5

I couldn't see it on the list, could libtool also be whitelisted
invalid flag in #cgo LDFLAGS: -I/usr/local/share/libtool

@PassKit -I is a cflag (which is in the list) not a ldflag, why are you putting it in ldflags?

Re-opening to collect more whitelist requests.

From #24703
CFLAGS: -fno-plt

At this point I think it's OK to decide that we will only update the 1.9 and 1.10 release branches if some popular package to fail to build and that has somehow not been reported yet.  I don't think we need to keep backporting every random option.  We can just add them to tip for 1.11.  Whether we track them in this issue or elsewhere, I don't care.

sgtm

@AlexRouSg my issue was related to this library, which recommended whitelisting "-I" as an ldflag, which I am currently using as a workaround.  https://github.com/miekg/pkcs11/issues/63

Sorry for being late, but it would be great if these would be whitelisted in 1.9.5 or 1.10.2
CXXFLAGS: -F/Users/user/Qt/5.10.1/clang_64/lib
CFLAGS: --sysroot=/Users/user/android-ndk-r14b/sysroot
CFLAGS: -mfloat-abi=softfp
CFLAGS: -fno-builtin-memmove
CFLAGS: -mthumb
CFLAGS: -fobjc-nonfragile-abi
CFLAGS: -fobjc-legacy-dispatch
CFLAGS: -fno-keep-inline-dllexport
CXXFLAGS: -mthreads
CFLAGS: -Wp,-D_FORTIFY_SOURCE=2
CFLAGS: --param=ssp-buffer-size=4
CFLAGS: -mfloat-abi=hard
CFLAGS: -fvisibility-inlines-hidden
CFLAGS: -mfpmath=sse
CFLAGS: -fasynchronous-unwind-tables
CFLAGS: -feliminate-unused-debug-types
CFLAGS: -marm
CFLAGS: -mabi=aapcs-linux
CFLAGS: -mthumb-interwork

and
LDFLAGS: -headerpad_max_install_names
LDFLAGS: -Wl,-syslibroot,/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.12.sdk
LDFLAGS: -Wl,-rpath,@executable_path/Frameworks
LDFLAGS: --sysroot=/Users/user/android-ndk-r14b/platforms/android-16/arch-arm/
LDFLAGS: -Wl,-rpath-link=/Users/user/Qt/5.10.1/android_armv7/lib
LDFLAGS: -Wl,--allow-shlib-undefined
LDFLAGS: -Wl,-e,_qt_main_wrapper
LDFLAGS: -Wl,-O1
LDFLAGS: -Wl,-rpath-link,/opt/Qt/5.10.0/gcc_64/lib
LDFLAGS: -Wl,-s
LDFLAGS: -Wl,-subsystem,console
LDFLAGS: -mthreads
LDFLAGS: -rdynamic
LDFLAGS: -mfloat-abi=hard

Thanks in advance.

@therecipe We can add those to 1.11.  But for 1.9.5 or 1.10.2: what package(s) need these?

@ianlancetaylor Those are all needed for the different targets of https://github.com/therecipe/qt
It's okay if you won't whitelist them all at once, but please let me know which one I would need to take care myself of.

I am going to guess it's their own Qt package, which I know is old enough to be well established; I'm not fully sure if it is.
That being said:

Aren't some of the LDFLAGS already whitelisted without the -Wl, prefix?
Does -e have an effect in Go?
Wasn't -F already whitelisted? That turns out to be the option I was referring to above.
(To @therecipe) Why are you guarding a -D with a -Wp? Is there a reason to have a macro defined but only in the preprocessor? I don't know what kind of voodoo Qt does here...
(To @ianlancetaylor) I can sort of understand not backporting new options to 1.9 (I'm ambivalent on the issue because I don't have Go version usage metrics), but why not 1.10 until 1.12 is released?

@andlabs Only because we have to stop sometime, so why not stop now?  But I'm OK with continuing to backport patches if it seems sufficiently useful.

@therecipe in that case, where did you get them from? I'm curious now.
I still wonder how many of your LDFLAGS warnings go away if you remove -Wl, prefixes; try that and see?

@andlabs Yeah, one of Qt's build tools "qmake" consumes ".pro", ".spec" (mkspec), ".conf" and a lot of other  formats to generate regular Makefiles. I just feed it some dummy ".pro" files and extract the flags from the Makefiles. That way, I don't really have to resolve dependencies myself, the build process can work easier with 3rd-party libs, I don't have to manually manage the c or ld flags and untested targets or newer/older versions of Qt work out of the box most of the time. I just occasionally have to blacklist some flags that cause trouble, but that's very rare.
I tried to find the sailfish mkspec that pulls in "-Wp,-D_FORTIFY_SOURCE=2", but it's probably buried somewhere in the mersdk or so. But here is the official list of targets TQtC maintains support for: https://github.com/qt/qtbase/tree/5.11/mkspecs and there are a lot of unofficial ones maintained by independent parties. That's why I really don't want to manually mess with the flags.
I can whitelist them in the build tool used by the binding (which wraps go) in meantime, but the regular Go user who just wants to use go build ... will sooner or later raise an issue ... (at least for the desktop targets)

-ffast-math

The official SAP HANA client driver (the cgo based shared library) comes with #cgo LDFLAGS: -Wl,-rpath -Wl,\$ORIGIN which results in go build SAP/go-hdb/driver: invalid flag in #cgo LDFLAGS: -Wl,-rpath. Also see SAPs documentation at https://help.sap.com/viewer/0eec0d68141541d1b07893a39944924e/2.0.03/en-US/fba20e31f75c4f7ca5629083869069e5.html?q=golang driver for details.

@cbgo see #23672
Code that passes a flag and argument pair to the linker must now use one -Wl flag instead of two: use #cgo LDFLAGS: -Wl,-rpath,$ORIGIN, not #cgo LDFLAGS: -Wl,-rpath -Wl,$ORIGIN.

@AlexRouSg thanks a lot. I should have read that more carefully :-)

@PassKit Did you solve this problem？

@zcm211 If you're talking about https://github.com/miekg/pkcs11 they removed the -I... linker flag in feb. If you're using a package that uses it then you have to set the environmental variable CGO_LDFLAGS_ALLOW="-I.*"

darwin 64-bit, go1.10.2, I thought .o files were whitelisted for LDFLAGs, but I'm getting:
jaten@jatens-MacBook-Pro ~/go/src/github.com/go-interpreter/chezgo (master) $ make run
cd chez_scheme_9.5.1/c; make
make[1]: Nothing to be done for `doit'.
go build && ./chezgo
go build github.com/go-interpreter/chezgo: invalid flag in #cgo LDFLAGS: ./chez_scheme_9.5.1/boot/a6osx/kernel.o
make: *** [run] Error 1
jaten@jatens-MacBook-Pro ~/go/src/github.com/go-interpreter/chezgo (master) $ go version
go version go1.10.2 darwin/amd64
jaten@jatens-MacBook-Pro ~/go/src/github.com/go-interpreter/chezgo (master) $

due to the cgo preamble in https://github.com/go-interpreter/chezgo/blob/master/embed.go#L10
#cgo LDFLAGS:  -liconv -lm -lncurses -L/usr/local/lib ./chez_scheme_9.5.1/boot/a6osx/kernel.o

@glycerine According to https://go-review.googlesource.com/c/go/+/94676 they are. Maybe try a full path instead of a relative one?

Is the .o file in the source directory? If so, this situation is what ${SRCDIR} was provided for.

@andlabs Even if there are klunky workarounds, relative paths should be linkable, and that is clearly a bug.

It is, except IIRC there is no guarantee that the link would be relative TO the source directory...

gtk4 uses -mfpmath=sse

@ianlancetaylor Instead of having separate whitelists for cflags and ldflags, should there just be one list? gcc/llvm doesn't seem to care that you mix ldflags into cflags and vice versa. And it seems sometimes C devs do that causing issues like #25493 or https://github.com/golang/go/issues/23749#issuecomment-379969818

Ah, I see we have a ticket already, so let me mention "-D_THREAD_SAFE" from protobuf as documented in #25493

Hey Guys,
Why is this issue closed when we still cannot build bimg with the latest version of Go as of 9/4/2018 ?
Please see issue: https://github.com/h2non/bimg/issues/230
We cannot build anything that imports bimg since Go 1.10 and the problem still persist in Go 1.11
The error message we get is this:
# go build
go build gopkg.in/h2non/bimg.v1: invalid flag in pkg-config --libs: -Wl,--export-dynamic

Any advise?

I believe this whitelist is responsible for the following: https://github.com/alexflint/gallium/issues/63


FIX ignore hidden files when loading datasets, solvers, etc

When working on remote machines (e.g. with sshfs), macos automatically creates hidden files.
For example, if there is a file datasets/mnist.py, then it automatically creates a metadata file datasets/._mnist.py.
Thus, benchopt loads datasets/mnist.py but also datasets/._mnist.py which creates errors since  datasets/._mnist.py only contains metadata. To prevent this, this PR changes the regex that loads submodules to ignore hidden files.

Should we add a UT ?

Yes, can you add a test? You can use something similar to what is done here: https://github.com/benchopt/benchopt/blob/79e4608b6a26a02d832668bc7d18b1960b311b69/benchopt/tests/test_benchmark_features.py#L54C1-L54C1

Codecov Report

Merging #625 (f2e2e6c) into main (e04168a) will increase coverage by 0.06%.
The diff coverage is 100.00%.

:exclamation: Your organization is not using the GitHub App Integration. As a result you may experience degraded service beginning May 15th. Please install the Github App Integration for your organization. Read more.
@@            Coverage Diff             @@
##             main     #625      +/-   ##
==========================================
+ Coverage   55.02%   55.09%   +0.06%
==========================================
  Files          44       44
  Lines        2853     2855       +2
  Branches      524      525       +1
==========================================
+ Hits         1570     1573       +3
  Misses       1165     1165
+ Partials      118      117       -1


URLs are not properly escaped!

After quite a bit of digging, I found out why cordova-plugin-wkwebkit-file-xhr is not correctly loading Mapbox GL JS URLs, even when the following preference is set in config.xml.
<preference name="InterceptRemoteRequests" value="all" />

The following error is displayed any time I want to get a MapBox URL:
ERROR: {"message":"Bad Request"}
The reason is simple (but hard to find!): URLs are not being correctly escaped!
The fix is even simpler.
Replace line 339 in platforms/iOS/[Project Name]/Plugins/CDVWKWebViewFileXhr.m from this:
NSURL *url = [NSURL URLWithString:urlString];

To this:
NSURL *url;
if ([urlString<EMAIL_ADDRESS>== NSNotFound) {
    url = [NSURL URLWithString:[urlString stringByAddingPercentEscapesUsingEncoding:NSUTF8StringEncoding]];
} else {
    url = [NSURL URLWithString:urlString];
}

I haven't bothered to create a pull request, as Oracle have stated they will not accept them. You will have to apply this patch manually.

Update: I created a fork with my fix. You can use that in your Cordova project if you prefer.
See: https://github.com/Pigsnuck/cordova-plugin-wkwebview-file-xhr

Thanks @Pigsnuck. We will get back to you upon this with the fix

This fix is not working for me, Please double check...

@Pigsnuck Can you provide a sample app demonstrating the issue you faced.

Closing this issue due to lack of response.


ElasticSearch 1.x support

Doesnt seem to be any backwards compatibility in 1.x api for stats:
'2014-03-24 09:03:01: GET http://rd03:9200/_cluster/nodes/stats?all=true'
Unhandled exception in thread started by <function get_metrics at 0x1b7fb90>
Traceback (most recent call last):
  File "./es2graphite.py", line 129, in get_metrics
    node_stats_data = urllib2.urlopen(node_stats_url).read()
  File "/usr/lib/python2.7/urllib2.py", line 127, in urlopen
    return _opener.open(url, data, timeout)
  File "/usr/lib/python2.7/urllib2.py", line 407, in open
    response = meth(req, response)
  File "/usr/lib/python2.7/urllib2.py", line 520, in http_response
    'http', request, response, code, msg, hdrs)
  File "/usr/lib/python2.7/urllib2.py", line 445, in error
    return self._call_chain(*args)
  File "/usr/lib/python2.7/urllib2.py", line 379, in _call_chain
    result = func(*args)
  File "/usr/lib/python2.7/urllib2.py", line 528, in http_error_default
    raise HTTPError(req.get_full_url(), code, msg, hdrs, fp)
urllib2.HTTPError: HTTP Error 404: Not Found

This was resolved with #4 and can be closed.


chore: Correction of target version

Description of changes
The target version has been revised as ES2023 is now supported in LLRT 0.2.0-beta.
Checklist

[x] Created unit tests in tests/unit and/or in Rust for my feature if needed
[x] Ran make fix to format JS and apply Clippy auto fixes
[x] Made sure my code didn't add any additional warnings: make check
[x] Added relevant type info in types/ directory
[x] Updated documentation if needed (API.md/README.md/Other)

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

Is all of es2023 supported? I feel like the async iterator didnt work last time I tried.

Is all of es2023 supported? I feel like the async iterator didnt work last time I tried.

We have not tried every feature of the ES2023 from one end to the other. Unfortunately, I do not have the skills to do so...
We felt it was acceptable to list ES2023 as supported for generally the following reasons.

ES2023 is mentioned for the first time in the CHANGELOG of LLRT 0.2.0-beta (although it does not say "fully supported"...).

And this is what the QuickJS website says as well.

Introduction
QuickJS is a small and embeddable Javascript engine. It supports the ES2023 specification including modules, asynchronous generators, proxies and BigInt.

Looking at test262.fyi, it is true that QuickJS ES2023 compliance is not 100%, but then even V8 is 97%.

Especially since QuickJS says it supports ES2023, I thought we should separate this from the issue of individual functions not working. Unless it is truly fatal..
FYI:
There is a Web site called runtime-compat. On the surface, the screen looks at WebAPI compliance, but the survey itself extends to Javascript build-in functionality.
As far as the status of LLRT's survey, it appears to be compliant as the results of several asyncIterator surveys.
Do the latest test results show any difference?


实时监控图表显示BUG

http://cdn.07other.xingkwh.com/TIM%E6%88%AA%E5%9B%BE20181218200021.png

收到，多谢反馈
On Tue, Dec 18, 2018 at 4:03 AM YXY1109<EMAIL_ADDRESS>wrote:

http://cdn.07other.xingkwh.com/TIM截图20181218200021.png
http://url
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
https://github.com/TinkerPatch/tinkerpatch-sdk/issues/112, or mute the
thread
https://github.com/notifications/unsubscribe-auth/AAbvYkgcgp15OBrKySvTg6vMPVNVnFVMks5u6NmngaJpZM4ZYKv4
.


perlasm/x86_64-xlate.pl: typo fix in comment.

Description of change
Trivial: ingex to index

@agl The CLA bot doesn't recognise the email address you used in the "Author" field because you are registered with your google address not your chromium one. That means the git hooks are going to reject this if we try to push it. Can you amend the Author field?

The change was stated as and is trivial, no CLA should be required. But I took liberty of snatching it in #2585...


Cut down default dependencies

You need only renderer. Without default-features = false, all default dependencies for bevy become required for this plugin.

OK, merged. Thanks!

@JonahPlusPlus, could you draft a new minor release?


SST breaks an API Gateway V2 that is using an OpenAPI spec

I am trying to deploy an API Gateway V2 vanilla CDK Construct along with a NextjsSite in SST.
While doing so, I ran into a strange bug where SST adds tags to the Construct:
 "Tags": {
     "sst:app": "sst-nextjs",
     "sst:stage": "samgoodwin"
    }

This should be fine, but there's a weird edge case where it breaks if you are configuring that API using OpenAPI
|  Site service/Gateway AWS::ApiGatewayV2::Api CREATE_FAILED Resource handler returned message: "Redundant fields [tags={"sst:app":"sst-nextjs","sst:stage":"samgoodwin"}] provided when either Body or BodyS3Location is not empty (Service: null; Status Code: 0; Error Code: null; Request ID: null; Proxy: null) (Service: null; Status Code: 404; Error Code: BadRequestException; Request ID: null; Proxy: null)" (RequestToken: 6c87e720-6a2d-eb8d-64fe-6792d8a2729d, HandlerErrorCode: GeneralServiceException)

API Gateway only allows tags to be in the OpenAPI spec.

This is a bug in AWS CDK, not SST. Closing.


Suggestion for  the IJulia Installation guide - especially for Mac users

After several hours of trying, I was able to get a Julia 0.5 kernel to talk to my macOs Sierra Jupyter Notebook (via Anaconda & Python 2.7).  Pkg.add("IJulia") kept failing but the error messages went by so fast, it took a long time and a lot of searching to debug.
I suggest the following additions for https://github.com/JuliaLang/IJulia.jl for Mac users.

Install Xcode for the git tools required in the installation process
ZMX on the Mac requires Brew: http://zeromq.org/intro:get-the-software followed by brew install zmq before running the Pkg.add("IJulia")

Neither Xcode nor Brew should be required, because all the dependencies should have precompiled binaries for Mac.
e.g. ZMQ uses Homebrew.jl to set up its own homebrew installation inside the .julia directory, so you should not need to install Brew.
If any of the IJulia dependencies failed to install without Xcode or Brew, that is a bug and should be reported (with the exact error message and the output of versioninfo(true) at the appropriate package).


Make emit resolver and node builder lazily created

Noticed these while working on other things. If we never emit, we never need the resolver. If we never print a node, then we don't need the builder immediately either.

@typescript-bot perf test this