velaux 1.9.1  Configure the gateway, and convert the port into a string

Describe the bug

velaux 1.9.1  Configure the gateway, and convert the port into a string
To Reproduce

cannot generate manifests from components and traits: evaluate template trait=gateway app=third-app1-prod: invalid template of trait gateway after merge with parameter and context: outputs.service.spec.ports.0.port: conflicting values "8090" and int (mismatched types string and int) (and 3 more errors)
Expected behavior

Screenshots

KubeVela Version
1.9.1

Cluster information

Additional context

Could you provide a screenshot?

@Louse-luo : please provide an example manifest which fails, thanks.

Same issue reported in Dingtalk, I'm copy-pase the screenshoots here:

thanks @wonderflow do we know the last version where this didn't happen?
and can you publish a full repro for getting to this state shown in the screenshot?

@Kolossi Thanks Paul for investigating this issue. The reporter didn't send the full repro, so I can't provide that.
I checked the gateway trait:
https://github.com/kubevela/kubevela/blob/v1.9.2/vela-templates/definitions/internal/trait/gateway.cue#L149
It's defined as http: [string]: int in CUE, AFAIK, the port must be a int, why it become a string in this case?

Indeed, I looked and saw the same.
Also, my changes to gateway were included in v1.9.0 and doing a diff to previous 1.8.2, there's nothing changed around port - https://github.com/kubevela/kubevela/compare/v1.8.2...v1.9.1#diff-eb6e43f0e2cf800a96e1dac66f3f4871067f865d5c694d9efa5c84cb2529a5a0
Is there something hardcoded in velaux about ports which has broken (again I tried a github search and couldn't find anything).
🤔

ping @chivalryq @barnettZQG , will it possible that's a bug caused by velaux?

I will dig into this recently.

same problem in 1.9.1； now we degrade to 1.8.1 ; keep an eye  on this

@lxkaka : can you post the steps to reproduce this issue please

@Kolossi

in 1.9.1 the port will be render to "8888" in yaml

@chivalryq I really can't see anything in either kubevela or velaux diff between 1.8.1 and 1.9.1.  Perhaps it's a change in the underlying cue version that has changed the behaviour?  I'm going to have to leave this with you.

@chivalryq No worry. Will take care of this.

I try to repro with:
velaux: v1.9.1, run the server locally.
vela-core v1.9.3
gateway trait: master.
When creating trait, velaux send the request to apiserver with the value of string type.

OpenAPI schema is like below. It's like there's something wrong in grammar. Still investigating.
{
  "properties": {
    "class": {
      "default": "nginx",
      "description": "Specify the class of ingress to use",
      "title": "class",
      "type": "string"
    },
    "classInSpec": {
      "default": false,
      "description": "Set ingress class in ''.spec.ingressClassName'' instead of ''kubernetes.io/ingress.class'' annotation.",
      "title": "classInSpec",
      "type": "boolean"
    },
    "domain": {
      "description": "Specify the domain you want to expose",
      "title": "domain",
      "type": "string"
    },
    "gatewayHost": {
      "description": "Specify the host of the ingress gateway, which is used to generate the endpoints when the host is empty.",
      "title": "gatewayHost",
      "type": "string"
    },
    "http": {
      "additionalProperties": {
        "type": "integer"
      },
      "description": "Specify the mapping relationship between the http path and the workload port",
      "title": "http",
      "type": "object"
    },
    "secretName": {
      "description": "Specify the secret name you want to quote to use tls.",
      "title": "secretName",
      "type": "string"
    }
  },
  "required": [
    "http",
    "class",
    "classInSpec" [],
    "type"
    :
    "object"
    }

@chivalryq we will keep an eye on this

Openapi schema is not wrong. It's a k9s bug.


MapDeclarationExtension.find? bug

I think there is a bug in MapDeclarationExtension.find? which means that if the attribute was made in a different module to the declaration it will miss.
-- File 1
initialize translations : MapDeclarationExtension Name ← mkMapDeclarationExtension `translations

-- File 2
import File1

#eval (do
  translations.insert (← getEnv)`Mul `Add |> setEnv
  return ()
  : CoreM Unit
)

#eval (do
  dbg_trace (translations.getState (←getEnv)).find? `Mul -- prints some `Add
  dbg_trace translations.find? (←getEnv) `Mul                   -- prints none
  return ()
  : CoreM Unit
)

This can be fixed by implementing translations.find? env n  as (translations.getState env).find? n instead of trying to find the decl name directly from the oleans as in the definition of translations.find?.

Also
-- File 3
import File2

#eval (do
  dbg_trace (translations.getState (←getEnv)).find? `Mul -- prints none
  dbg_trace translations.find? (←getEnv) `Mul                   -- prints none
  return ()
  : CoreM Unit
)

It seems that both should be printing some Add here?

Noting that TagDeclarationExtensions seems to have a similar limitation.

This is by design. We can add assertions to make sure these extensions are not being misused.
The main advantage of these extensions is that they do not require any post-processing after we memory map the .olean files. To retrieve an entry, we just perform a binary search in the array stored in the memory mapped .olean.
Example:
https://github.com/leanprover/lean4/blob/7797fa3e2dbdabbef301b4f66a6ca9e2307882da/src/Lean/Environment.lean#L499

I updated the comment of MapDeclarationExtension, and added the assertions. You should now get an assertion violation (i.e., panic message) with the example above.

I understand thanks for explaining 🙂


Unhandled Promise rejection: Template parse errors: Can't bind to 'track' since it isn't a known property of 'audio-track'.

Hi,
I'm new at Angular and Ionic...I tried this plugin but still get this message:
Error: Uncaught (in promise): Error: Template parse errors:
Can't bind to 'audioTrack' since it isn't a known property of 'ion-item'.
1. If 'ion-item' is an Angular component and it has 'audioTrack' input, then verify that it is part of this module.
2. If 'ion-item' is a Web Component then add 'CUSTOM_ELEMENTS_SCHEMA' to the<EMAIL_ADDRESS>of this component to suppress this message.
3. To allow any property add 'NO_ERRORS_SCHEMA' to the<EMAIL_ADDRESS>of this component. ("

  <audio-track #track [track]="singleTrack">
    <ion-item [ERROR ->][audioTrack]="track">
      <ion-thumbnail item-left>

"): ng:///AboutModule/AboutComponent.html@33:14
Error: Template parse errors:
Can't bind to 'audioTrack' since it isn't a known property of 'ion-item'.
1. If 'ion-item' is an Angular component and it has 'audioTrack' input, then verify that it is part of this module.
2. If 'ion-item' is a Web Component then add 'CUSTOM_ELEMENTS_SCHEMA' to the<EMAIL_ADDRESS>of this component to suppress this message.
3. To allow any property add 'NO_ERRORS_SCHEMA' to the<EMAIL_ADDRESS>of this component. ("

  <audio-track #track [track]="singleTrack">
    <ion-item [ERROR ->][audioTrack]="track">
      <ion-thumbnail item-left>

"): ng:///AboutModule/AboutComponent.html@33:14
    at syntaxError (http://localhost:8100/build/main.js:105019:34)
    at TemplateParser.parse (http://localhost:8100/build/main.js:115510:19)
    at JitCompiler._compileTemplate (http://localhost:8100/build/main.js:129261:39)
    at http://localhost:8100/build/main.js:129185:62
    at Set.forEach (native)
    at JitCompiler._compileComponents (http://localhost:8100/build/main.js:129185:19)
    at createResult (http://localhost:8100/build/main.js:129070:19)
    at t.invoke (http://localhost:8100/build/polyfills.js:3:8971)
    at r.run (http://localhost:8100/build/polyfills.js:3:4140)
    at http://localhost:8100/build/polyfills.js:3:13731
    at syntaxError (http://localhost:8100/build/main.js:105019:34)
    at TemplateParser.parse (http://localhost:8100/build/main.js:115510:19)
    at JitCompiler._compileTemplate (http://localhost:8100/build/main.js:129261:39)
    at http://localhost:8100/build/main.js:129185:62
    at Set.forEach (native)
    at JitCompiler._compileComponents (http://localhost:8100/build/main.js:129185:19)
    at createResult (http://localhost:8100/build/main.js:129070:19)
    at t.invoke (http://localhost:8100/build/polyfills.js:3:8971)
    at r.run (http://localhost:8100/build/polyfills.js:3:4140)
    at http://localhost:8100/build/polyfills.js:3:13731
    at c (http://localhost:8100/build/polyfills.js:3:13190)
    at c (http://localhost:8100/build/polyfills.js:3:12876)
    at http://localhost:8100/build/polyfills.js:3:13722
    at t.invokeTask (http://localhost:8100/build/polyfills.js:3:9655)
    at r.runTask (http://localhost:8100/build/polyfills.js:3:4831)
    at o (http://localhost:8100/build/polyfills.js:3:1891)
    at <anonymous>
n.onUnhandledError @ VM74 polyfills.js:3
r @ VM74 polyfills.js:3
(anonymous) @ VM74 polyfills.js:3
n.microtaskDrainDone @ VM74 polyfills.js:3
o @ VM74 polyfills.js:3

I did everything you wrote here
Also on my text editor, I get this error
Property 'selectedTrack' does not exists on type
Any support is really appreciate, thanks!

First of all I saw the demo here that is completely different from this http://arielfaur.github.io/ionic-audio/2.0/index.html and I change it accordingly on my project...after
I edit my component page adding NO_ERRORS_SCHEMA likes below:
import { NgModule, NO_ERRORS_SCHEMA } from '@angular/core';
import { CommonModule } from '@angular/common';
import { SharedModule } from '../../app/shared/shared.module';
import { AboutComponent } from './about-component/about.component';

@NgModule({
  declarations: [
    AboutComponent
  ],
  imports: [
  	CommonModule,
  	SharedModule
  ],
  exports: [
    AboutComponent
  ],
  entryComponents:[
  	AboutComponent
  ],
  schemas: [ NO_ERRORS_SCHEMA ]
})
export class AboutModule {}

Now all errors are gone and it works.


[#74] Use 'default' in core.py.template for acSetNumThreads (4-2-stable)

CI tests passed except for one test which is being addressed in irods/irods#5667

yes, please # it

#'d

and in master please.

Yep, in #76

naturally.


Having issues lately

I'm having problems showing the map lately ( just a grey backround is shown).
I've upgraded node-red, the dashboard and this software to the lastest version. Running on node v8.15.
This is the console output of Chrome ( on MacOs) for the /ui:

Refused to apply style from 'http://<IP_ADDRESS>:1880/worldmap/leaflet/Leaflet.vector-markers.css' because its MIME type ('text/html') is not a supported stylesheet MIME type, and strict MIME checking is enabled.
<IP_ADDRESS>/:39 GET http://<IP_ADDRESS>:1880/worldmap/leaflet/Leaflet.vector-markers.min.js net::ERR_ABORTED 404 (Not Found)
<IP_ADDRESS>/:59 GET http://<IP_ADDRESS>:1880/worldmap/leaflet/tile.stamen.js net::ERR_ABORTED 404 (Not Found)
milsymbol.js:32 milsymbol.js 1.3.3 - Copyright (c) 2017 Måns Beckman  http://www.spatialillusions.com
<IP_ADDRESS>/:59 GET http://<IP_ADDRESS>:1880/worldmap/leaflet/tile.stamen.js net::ERR_ABORTED 404 (Not Found)
(index):193 CONNECT TO /worldmap/socket
(index):235 IN an iframe
dialog-polyfill.js:333 Can't upgrade : already supported <dialog id="helpWindow">…
dialogPolyfill.registerDialog @ dialog-polyfill.js:333
(anonymous) @ (index):286
(index):728 Uncaught TypeError: L.StamenTileLayer is not a constructor
at (index):728
(anonymous) @ (index):728
(index):157 CONNECTED

When I request the JS files (that generate a 404 ) directly I get them just fine.

Most odd. Have you ensured you flushed the cache in the browser ?

Thanks, I did not mention it but yes, I did clear the cache. Or at least, I thought I did.  I use a chrome extension to clear my cache ( Im a web developer so clearing a cache needs to be as easy as pressing a button :))  and all though this extension has so far worked just fine, it didnt in this case and I had to resort to chrome's clear history settings, And then it worked.
As a side note.. On my Android phone I am also running Chrome and the map also didn't display any more in that browser. After I cleared the cache there It did start to work again, but after a few hours it stopped again, showing only a grey background again.  Strange..

Is desktop OK now ? Any updates on mobile ?

Yep. No more issues on the desktop or mobile.  Thanks!


Indicator Drill-Down Errors

Hmm, not sure what's going on. Trying to drill-down on indicators from either the dashboard or Campaign page and am getting one of the following errors:
'odnsinfo'
Expecting property name: line 1 column 2 (char 1)
Just me? Thanks!

This was a bug that should be fixed in the most recent code merge.
On Sep 18, 2015 6:23 PM, "Christian P."<EMAIL_ADDRESS>wrote:

Hmm, not sure what's going on. Trying to drill-down on indicators from
either the dashboard or Campaign page and am getting one of the following
errors:
'odnsinfo'
Expecting property name: line 1 column 2 (char 1)
Just me? Thanks!
—
Reply to this email directly or view it on GitHub
https://github.com/defpoint/threat_note/issues/33.

Hmm okay. Just synced latest updates (~2 hours ago, pull #32). Maybe it's something on my end.

I see the issue. The odnsinfo field isnt being added to the database correctly. Stay tuned for a fix.

Awesome, thanks!


Actually patch the voice_all_e.sbk file

Currently I have one premade, would be better to generate the one with every voice line in it at runtime.

Done in https://github.com/Knuxfan24/Sonic-06-Randomiser-Suite/commit/3a35a252810226cd06420ee5c9a01ef292ae82a5


Rodeos with Streaming Plugin

Change Description
This builds on #9018
This is a proposed Streamer Plugin to publish messages to external brokers. As a reference,
we implement two basic streams: a rabbitmq one, using amqp-cpp lib; and also a simple logger
stream, in case you want to print the filter data to your own logs.
Consensus Changes

[ ] Consensus Changes

API Changes

[ ] API Changes

Documentation Additions

[x] Documentation Additions

To publish the queues from your filter contract, add the following code that will stream data
with the push_data intrinsic:
// struct required for streaming data
struct stream_wrapper_v0 {
    eosio::name       route;
    std::vector<char> data;
};
EOSIO_REFLECT(stream_wrapper_v0, route, data);
using stream_wrapper = std::variant<stream_wrapper_v0>;

// helper streaming serializer function
inline void push_stream(const name route, const std::string& text) {
    stream_wrapper    wrapper = stream_wrapper_v0{.route = route, .data = {text.begin(), text.end()}};
    std::vector<char> bin;
    eosio::convert_to_bin(wrapper, bin);
    eosio::push_data(bin);
}

// ... then inside your filter actions ...
// this will push the `hello world` message to the eos routing key
push_stream("eos"_n, "hello world");

--plugin b1::streamer_plugin
Enables the streamer plugin in rodeos instance
--stream-rabbits amqp://guest:guest@localhost:5672/myqueue/mykey
Adds a RabbitMQ streaming.

you can declare multiple rabbitmq connections
the template is always amqp://USER:PASSWORD@HOST:PORT/QUEUE_NAME[/KEY1,KEY2]

amqp:// prefix is fixed
USER is the rabbitmq user
PASSWORD is the rabbitmq password
HOST is the address of rabbitmq host
PORT is the rabbitmq's port
QUEUE_NAME is the name of the queue that you want to publish the messages
/KEY1,KEY2 is a set of routing keys that you want to publish to your queue. the default is empty, which means will publish any routing keys to this key; you can separate keys names by commas to restrict routing keys; the types of the key names are eosio::name, ex: eos,issue will publish only the messages that has either eos or issue as its routing key

--stream-loggers "*"
Add a Logger streaming

the logger only needs the keys that you want to print
if it's equal to * it will accept any routing keys
similar to the RabbitMQ streaming example you can restrict and filter only certain keys, separated by commas: --stream-loggers "eos,issue"

Additional Implementations
If you want to add your own streaming plugin, feel free to implement the stream_handler class, implementing the void publish(const char* data, uint64_t data_size) method. You will need to add new config params and a way to initialize it in the streamer_plugin::plugin_initialize.

      if (filter && my->streamer) {
         filter->process(*rodeos_snapshot, result, bin,

This still needs fixing. cloner_plugin needs to operate even when there is no streamer.

since amqp-cpp is apache licensed, I think we need to include its license file in the install. Toward the bottom of the root CMakeLists.txt is where we tend to add those.

Hi, I tested this stream function with rabbitmq, the connection drop because server side not receive any heartbeat. It only works when I config server side with heartbeat=0 to disable heartbeat.  is this expected ?

@swang-b1 hmmm so I guess the amqp-cpp implementation that I imported does not manage heartbeat out of the box. For now we can set the rabbitmq config heartbeat=0 and add this issue to our backlog.

The documentation is deceptive.

The default behavior of the AMQP-CPP library is to disable heartbeats

That's true if you're using a vanilla AMQP::Connection but not true if you're using AMQP::TcpConnection. AMQP::TcpConnection will accept the server's recommended heartbeat interval.
But then the asio integration doesn't set up a timer to pump the heartbeat :disappointed:
https://github.com/CopernicaMarketingSoftware/AMQP-CPP/blob/1c08399ab0ab9e4042ef8e2bbe9e208e5dcbc13b/include/amqpcpp/libboostasio.h#L533-L535
For now, this fault can be mitigated by doing something like
   uint16_t onNegotiate(AMQP::TcpConnection *connection, uint16_t interval) override {
      return 0;
   }

in our own handler. That will disable heartbeats on the connection no matter how the server is configured.

Cool, this will work.


Hint at word corrections

E.g. https://sonaveeb.ee/search/unif/dlall/dsall/ellkõig — not in the autocomplete, but in pages themselves, when autocomplete gives no results.

Done in 0.5.


Compiling into a single file not possible with the files Array/Object

Rather this
grunt.initConfig({
  ts: {
    compileTwoSetsOfFilesUsingArrayStyle: {
      // This will run tsc twice.  The first time, the result of the 'files1/**/*.ts' glob will be
      // passed to tsc with the --out switch as 'out/ArrayStyle/1.js'.
      // see https://github.com/gruntjs/grunt-docs/blob/master/Configuring-tasks.md#files-array-format
      files: [{ src: ['files1/**/*.ts'], dest: 'out/ArrayStyle/1.js' },
              { src: ['files2/**/*.ts'], dest: 'out/ArrayStyle/2.js' }],
      options: {
        fast: 'never'
      }
    },

nor this
compileTwoSetsOfFilesUsingObjectStyle: {
      // This will run tsc twice.  The first time, the result of the 'files1/**/*.ts' glob will be
      // passed to tsc with the --out switch as 'out/ObjectStyle/1.js'.
      // see https://github.com/gruntjs/grunt-docs/blob/master/Configuring-tasks.md#files-object-format
      files: {
        'out/ObjectStyle/1.js': ['files1/**/*.ts'],
        'out/ObjectStyle/2.js': ['files2/**/*.ts']
      },
      options: {
        fast: 'never'
      }

is setting the -out switch for the compiler as in the description explained.
Only if I'm using the options out it is working, but then I would have to setup one subtask per file...
Bests,
Sascha

You're absolutely correct.  This is broken and our tests didn't pick it up.  Very sorry - will resolve ASAP.

I just pushed version 4.1.1 - will you check it out and let me know if you agree that this is resolved.  Thanks for the report and sorry for the regression.

The changes in 97ad3999847b0cc7e8d78ac8e1ef99f24284fde5 broke the tsc command when paths include spaces.
For our configuration:

Previously utilised target.out, which is a relative path
Now uses outFile, which is absolute

Assume something like this is needed:

outFile = '"' + path.resolve(outFile) + '"';

@seanmailander - thanks for the report.  I just pushed 4.1.2 to npm - would you please take a look?

@nycdotnet looks-great-runs-great, thanks!

Glad to hear it.
@Linowitch - thank you for the original report.  I think things are fixed so I am going to close this issue.  Please let me know if it is not fixed for you.  Thanks!!


containerd-shim-runc-v2 and traefik left running after k3s is stopped

Version:
k3s version v1.18.4+k3s1 (97b7a0e9)

K3s arguments:
I start the service with systemctl. This is the unit file located at /etc/systemd/system/k3s.service.
[Unit]
Description=Lightweight Kubernetes
Documentation=https://k3s.io
Wants=network-online.target

[Install]
WantedBy=multi-user.target

[Service]
Type=notify
EnvironmentFile=/etc/systemd/system/k3s.service.env
KillMode=process
Delegate=yes
# Having non-zero Limit*s causes performance problems due to accounting overhead
# in the kernel. We recommend using cgroups to do container-local accounting.
LimitNOFILE=1048576
LimitNPROC=infinity
LimitCORE=infinity
TasksMax=infinity
TimeoutStartSec=0
Restart=always
RestartSec=5s
ExecStartPre=-/sbin/modprobe br_netfilter
ExecStartPre=-/sbin/modprobe overlay
ExecStart=/usr/local/bin/k3s \
    server \

Describe the bug
If I start k3s with systemctl, then stop it, 5 instances of containerd-shim-runc-v2 and one instance of traefik are left running. The containerd-shim-runc-v2 processes do not appear to handle SIGTERM signals correctly, since they block shutdown/reboot on the desktop PC where they're running.
To Reproduce

install k3s with curl -> sh installation script
systemctl start k3s
systemctl stop k3s
Observe the orphaned processes

$ ps aux | grep shim
root        3117  0.0  0.0 112504  8312 ?        Sl   13:50   0:00 /var/lib/rancher/k3s/data/3a8d3d90c0ac3531edbdbde77ce4a85062f4af8865b98cedc30ea730715d9d48/bin/containerd-shim-runc-v2 -namespace k8s.io -id e93011de5fd12f70880006cc93d34341b2ae3e159b27c3c1cedd755f60969d9f -address /run/k3s/containerd/containerd.sock
root        3344  0.0  0.0 111096  8040 ?        Sl   13:50   0:00 /var/lib/rancher/k3s/data/3a8d3d90c0ac3531edbdbde77ce4a85062f4af8865b98cedc30ea730715d9d48/bin/containerd-shim-runc-v2 -namespace k8s.io -id 1e8ac2547205e0986004fb6214202124ab0de1233adb9008d74277e3bd5293c4 -address /run/k3s/containerd/containerd.sock
root        3526  0.0  0.0 112504  7888 ?        Sl   13:50   0:00 /var/lib/rancher/k3s/data/3a8d3d90c0ac3531edbdbde77ce4a85062f4af8865b98cedc30ea730715d9d48/bin/containerd-shim-runc-v2 -namespace k8s.io -id e71704e781748c2ecff1397f13a9f7d159821ade6aebc9514716b599a025f1d5 -address /run/k3s/containerd/containerd.sock
root        3757  0.0  0.0 112504  7228 ?        Sl   13:50   0:00 /var/lib/rancher/k3s/data/3a8d3d90c0ac3531edbdbde77ce4a85062f4af8865b98cedc30ea730715d9d48/bin/containerd-shim-runc-v2 -namespace k8s.io -id b1b599741d2b830e0adc94955ff04d77bea23d8857d898996f9a169dcf88ae43 -address /run/k3s/containerd/containerd.sock
root        4014  0.0  0.0 112504  7932 ?        Sl   13:50   0:00 /var/lib/rancher/k3s/data/3a8d3d90c0ac3531edbdbde77ce4a85062f4af8865b98cedc30ea730715d9d48/bin/containerd-shim-runc-v2 -namespace k8s.io -id 6bbb2c890ebaf863b89b033fb42a696765085ccd75850e15c6d9a4f8ab049e6f -address /run/k3s/containerd/containerd.sock

ps aux | grep traefik                                                            [13:53:59]
root        3857  1.0  0.3<PHONE_NUMBER>8 ?        Ssl  13:50   0:02 /traefik --configfile=/config/traefik.toml

Expected behavior
Stopping the k3s service should stop associated processes.
Actual behavior
containerd-shim-runc-v2 and traefik are left running.
Additional context / logs
I noticed this when rebooting my machine was hanging for an extra minute while the OS was waiting for containerd-shim-runc-v2 to stop.
I run Pop_OS! 20.04
$ uname -a
Linux caeser 5.4.0-7634-generic #38~1592497129~20.04~9a1ea2e-Ubuntu SMP Fri Jun 19 22:43:37 UTC  x86_64 x86_64 x86_64 GNU/Linux

This is intentional to allow for upgrading k3s without disrupting workloads. If you want to kill all the pods, you can drain the node first or run the included k3s-killall.sh script.

Thanks for clarifying, and that makes sense. :+1:
I see the docs here: https://rancher.com/docs/k3s/latest/en/upgrades/killall/
If you're in control of that unit file, you all might consider adding a comment about this functionality in the unit file itself.


Improve performance

Right now, when printing entities filtered by --failed or --unproved, the decision if the entity's proof tree has failed attempts results in multiple calls to Has_Failed_Attempts, Is_Unproved which each cause more similar calls into all dependent objects. This should be optimized, so that such properties are only calculated once.
For further discussion see this wiki-page

The data structure we have now is mostly a vector containing other vectors. It seems more logical to represent the whole structure as a multi way tree instead.
This, of course, requires that all objects are derived from the same parent type, but that shouldn't be much of an issue.
So, instead of trying to extend the "Vector" types to insert our cached information, we could instead insert some kind of meta element which caches all information from its siblings, or (maybe a better solution) insert the concerned elements as child nodes.

Mostly fixed in b667fcaef923b90ba2bc9e56d18d919e651fc120
Which bears the question... when we are collecting the proof items, we now already know if the item would get filtered. So maybe don't add these to the tree at all. That should greatly simplify the output code.


fix ClassCastException when finalize hyperUnique metric in sql

Description
for a sql like this
select count(1) as totalData
from  (
   select count(distinct unique_user_id) as uv
   from a_table
   group by city_name
   order by uv
) t

unique_user_id is hyperUnique metric.
java.lang.ClassCastException is thrown as

java.lang.Long cannot be cast to java.lang.Double

The reason is that  count(distinct unique_user_id) is Long in row signature, but the comparator in HyperUniqueFinalizingPostAggregator is Double

This PR has:

[x] been self-reviewed.

[ ] using the concurrency checklist (Remove this item if the PR doesn't have any relation to concurrency.)

[ ] added documentation for new or modified features or behaviors.
[ ] added Javadocs for most classes and all non-trivial methods. Linked related entities via Javadoc links.
[ ] added or updated version, license, or notice information in licenses.yaml
[ ] added comments explaining the "why" and the intent of the code wherever would not be obvious for an unfamiliar reader.
[ ] added unit tests or modified existing tests to cover new code paths, ensuring the threshold for code coverage is met.
[ ] added integration tests.
[x] been tested in a test Druid cluster.

Key changed/added classes in this PR

HyperUniqueFinalizingPostAggregator

The CI failure java.lang.AssertionError: expected [200 OK] but found [401 Unauthorized] in 30393.61 (Compile=openjdk8, Run=openjdk8, ZK=3.4) leadership and high availability integration tests  should be unrelated

Is this merged or just deleted?


Add panning top to bottom

Can you add effect panning top to bottom with Slideshow Transition?
and how to load many image? I load 300 image and got error on windows because it only allow 8190 charactor in command line
Thank you

Do you mean panning during transition or panning while showing one of the images?
If you have too many images, you can process them in parts of 100 and then combine them.

Did you tried -filter_complex_script option? You can put the filter_complex contents inside a file and call it with -filter_complex_script?

I tried and it working. But input "-loop 1 C:\file1.jpg -loop 1 C:\file2.jpg -loop 1 C:\file3.jpg ... -loop file 500.jpg" take larger charactor and cannot execute in command line

You can use a filename pattern like -i C:\file%03d.jpg. It will search for files from C:\file000.jpg to C:\file999.jpg and use them as input.

Generally image2 and concat demuxers are used while working with file sequences but they are not compatible with -filter_complex as far as I know.
The only working solution I know is splitting file sets into subsets and merging them as I wrote in my first post.

ca you add panning and zoom from top to bottom for each image?

Unfortunately zoom is not possible, zoompan in ffmpeg does not support time functions. But I added a vertical panning example in a new section. You can play with duration and resolution, I hope it helps.

vertical panning in example is delayed and experience is not good :(

Well, I can try to improve it, but I need details. I don't understand how it is delayed, do you mean slow?

yes. it slow (lag)

I updated the script with Wipe In Horizontal transition and moved under the Advanced Scripts.
My interpretation of vertical panning is like that. If you need a different behaviour could you please show me an example of it?
If speed is your only concern why don't you take the script and modify it to pan faster?

I want like that https://el-tramo.be/blog/ken-burns-ffmpeg/pan.gif
can you add move from "top to bottom"?

This example is not much different than panning in 'Wipe In Horizontal with Vertical Panning'. The only difference is resolution of the video and input photos.
In 'Wipe In Horizontal with Vertical Panning' script dimensions of the video is 640x360. Input photos used were scaled to fit the screen before panning ratio in first versions. Because of that panning was working on small area.
A few minutes ago a I pushed a change in scaling ratios and now panning is working a bit different. Could you please check it?

I checked it. But it is bottom to top. Can you add top to bottom?
thanks

I checked and it is goood.
Thank you :+1:

Do you can reduct the bitrate. I see the bitrate is
frame=   75 fps=4.2 q=28.0 size=    2366kB time=00:00:02.06 bitrate=10685.6kbits/s
it take render speed is very slow

There are many ways to speed up the scripts: changing the video codec, reduce the quality, decrease the resolution, removing unused animations, etc. But all scripts are different and they don't always run faster.
For vertical panning script I prepared two versions which run faster without decreasing quality much. Can you try them?
One of them removes RGB format conversion wipe_in_horizontal_with_panning_vertical.sh.
The second one also removes the transition vertical_panning_without_transition.sh.

Unfortunately zoom is not possible,zoompan in ffmpeg does not support time functions.

I've told you that zoom is not possible because zoompan does not support time functions. There are alternative fields in zoompan filter to implement zoom. Today I created two 'Zoom & Pan' scripts using these fields. You can browse Advanced Scripts section to see them.
By the way, I removed panning scripts I created yesterday. I still feel they are not complete. Last versions are available under gists if you still need to access them.

hi.
I want same here: https://www.youtube.com/watch?v=E269Wfd0ziU
I tried some days, but I cannot find solution.

I made a few changes to Vertical Panning without Transition gist. Scene arrangement and panning is nearly identical to your video. Dimension of the photos is ~ 1024x640 px and dimension of the video is exactly 1024x320 px. The point here is to use photos with 2x height of your photos. So panning can work. Scenes has the following durations. You can update it according to your photos and their dimensions.
Photo 1 start - 3 seconds
Photo 1 panning - 5 seconds
Photo 1 end - 3 seconds
Photo 2 start - 3 seconds
Photo 2 panning - 5 seconds
Photo 2 end - 3 seconds
Photo 3 start - 3 seconds
Photo 3 panning - 5 seconds
Photo 3 end - 3 seconds
Photo 4 start - 3 seconds
Photo 4 panning - 5 seconds
Photo 4 end - 3 seconds
Photo 5 start - 3 seconds
Photo 5 panning - 5 seconds
Photo 5 end - 3 seconds

hi.
Thank for your help
I tried, but I got the problem. This script is missing part of top and bottom image.
From 2th image, dont stop when image is showing bottom.
You can try some my image:
https://drive.google.com/file/d/1b9nMEp2KDKhmMFEYn-v3esym3W5e-bia/view?usp=sharing

Did you update the dimensions?
I created a new one for you. Can you try with this? vertical panning with 6 images and 870x625 px

From 2th image, dont stop when image is showing bottom.

Do you mean the scene between 8th and 11th seconds?

Yes. New script loss bottom image between 8th and 11th seconds and same all image after.

I guess you mean this?

Dimensions of your video is around 870x320. The new script generates a 870x625 video. Look at my screenshot. Are you sure this is not related to your player. Can you try with another one?

Sorry, I'm missing, but It don't sleep when showing bottom.
Can you scale the witdh to 1280 (HD resolution) and keep ratio?

Original photos are smaller than 1280x720, so scaling decreases the quality a bit. This script does that.

"scaling decreases the quality a bit" this is no problem with me :)
But this script don't sleep 3 seconds when showing bottom.

Ok then, how about this one?

I don't known my video is error :(
https://drive.google.com/drive/folders/1UrwmE0ffBpFxcvbVV_x5hPf7Tx9ozJS-?usp=sharing
it dont sleep and it jump to bottom when spanning

According to the filter parameters video length should be 66 seconds. Somehow yours is 49. I don't know the exact error. But maybe it is related with encoding options.
I prepared a new script with different encoding profile, runs a little slower. Can you try it, new script?

When I render I got some message:
https://ibb.co/fN7TN8

Hmm, it is about the order of statements and should not cause the problem of you. Anyway I changed the order in the new one. Let's see if it will make any change?

I tried and no have different

Well, is there a video created? Lines in your screenshot are only warnings and should not stop the script.

No, my screenshot same here: https://ibb.co/fN7TN8

Hmm, I'm out of solutions here. Probably, script is using too much cpu/RAM and freezes on your computer. Are old scripts still working (with missing frames)?

my CPU and RAM is free: https://ibb.co/e1eKUo
I tried all script and have this error

All script on today, from  "Vertical Panning without Transition"

Can you try some of old ones with another video file name, maybe '../gist_panning_vertical_2.mp4'?

Can you try this?

Yes. i tried. I lastest script I found many "[6:v]"? Do you misstake?

Shouldn't be. I test them before posting. [6:v] is the black screen input. All scripts with 6 images include [6:v].
So changing file name does not work?

I can try, if you want?

ok. my teamview
120 688 131
5684

You are right about the bottom of photos. I'm trying to fix it.

I'm waiting for you.
this is important for me

It took some time. Can you try this one, vertical crop fix?

I tried and it working perfectly!
Can you tell me how to change speed and duration spanning?

y='t/5*(720-overlay_h)',trim=duration=5,select=lte(n\,150) statement controls panning duration. Current arrangement uses 5 seconds for panning. To increase/decrease it you need to change 3 parts.

t/5, should be t/<DURATION>
duration=5 should be duration=<DURATION>
lte(n\,150) should be lte(n\,<DURATION*30>)

y=0,trim=duration=3,select=lte(n\,90) line controls starting duration. You need to change 3and 90 accordingly.

y=(720-overlay_h),trim=duration=3,select=lte(n\,90) line controls ending duration. You need to change 3and 90 accordingly.

Ok bro.
you save my working days.
Thank you very much :+1:

I'm glad it worked. Thanks for visiting my project.

Split your 50 photos into smaller sets of 10 or 20 and create the video for each subset.

Create a file called list.txt with all subset videos added in each line.

file ../gist_panning_part1.mp4
file ../gist_panning_part2.mp4
...
file ../gist_panning_part10.mp4

Run ffmpeg -f concat -safe 0 -i list.txt -c copy ../gist_panning_vertical_final.mp4 command. The output video will include all subsets.

Ok. I will try :)

Hi.
I run in windows it working. But I run on centos have error: Seagment fault or libx264 not found. I tried both version: lastest and 3.4.3

libx264 not found

This error indicates that FFmpeg can not use libx264 encoding. Either libx264 is not installed or libx264 is not enabled within FFmpeg. You need to install a version which is built with libx264. Additionally it is possible to change the video codec used by replacing -c:v libx264 phrase with something like -c:v mpeg4.

Seagment fault

Does not says too much about the actual error. Please try to increase the log level with -v trace.

I installed libx264 and it working. But error with encode mp3.
If we can run on lastest version it is good

error with encode mp3.

Encoding mp3 may require lame library. Is it installed, what is the error?

I installed.
this is error:

Automatic encoder selection failed for output stream #0:0. Default encoder for format mp3 (codec mp3) is probably disabled. Please choose an encoder manually.
Error selecting an encoder for stream 0:0

Please choose an encoder manually.

Can you add -codec:a libmp3lame to your script?

I tried and got error:

[out_0_0 @ 0x5f28c40] 100 buffers queued in out_0_0, something may be wrong

[out_0_0 @ 0x5f28c40] 100 buffers queued in out_0_0, something may be wrong

This is not an error, only a warning. Is there any other messages?

Only this message :D
On linux, ffmpeg 4.0 is working

Great, then which platform and version fails, windows?

ffmpeg 4.0 is working

working with ffmpeg version less than 3.4, not working with lastest ffmpeg.

My friend, I really don't understand.

Oh sorry.
I working with with version less than 4.0

For not working versions, there should be an error somewhere. The following message is not error. You may want to add -v trace option to increase logging, it may help.
[out_0_0 @ 0x5f28c40] 100 buffers queued in out_0_0, something may be wrong

I run with ffmpeg version 4.0 and only get warning, no error.
If you have free time, can you try this for me :https://www.youtube.com/watch?v=dJPMNSoAzgY
Thank you :D

Well, I'd like to help if something is wrong with the scripts. Sometimes commands fail on specific platform & version combinations. If you need help, could you please provide 1) Command you execute, 2) Console output? So I can understand and reproduce your error.
Additionally, you are free o report your questions to<EMAIL_ADDRESS>There are many experts who can help you there.


removal of --verbosity flag

As I was tinkering with the scorecard, I encountered the --verbosity [string] flag. No options are given, and the argument string seems to be disregarded. Any input string seems to be accepted, yet it is set to the default level of 'info'.
I may be wrong, but for now this --verbosity option seems redundant and removable.
Alternatively, options such as debug, error etc. could be implemented and described in the help message.

Thank you for getting back to me about this. My bad; I will look into it and propose some changes, starting with displaying the options for the --verbosity flag in the usage message.


Some possible code bugs

https://github.com/EternityX/DEADCELL-CSGO/blob/7f41efe34e52df1c5dceaf51dfd22b180e1a0769/deadcell/util/pattern/pattern.hpp#L40
">=" here?
https://github.com/EternityX/DEADCELL-CSGO/blob/cab17a8ba8af0bdb293ac78accc1286bb9fdfcf7/csgo/features/visuals/visuals.cpp#L467
This always should be false, maybe strcmp?
https://github.com/EternityX/DEADCELL-CSGO/blob/dfad88afa0b5b862d391c31116dcf1bb6ce99b91/deadcell/math/math.cpp#L110-L113
v.z  will always 1.f(not only in else state), probably use "," instead ";" here?
Also you're doing great staff guys by creating open source cheat, thank you!

can you change it?
and Pull requests?

Sorry for late response anarch1st, didn't pay attention to this, thanks for your feedback, feel free to make pr to fix the above mentioned issues.


Missing autocomplete and documentation for ActionState functions

Version
0.1.2
Operating system & version
Windows 10
What you did
Setup the minimal example and began modifying the provided system.
What you expected to happen
When I use the methods of the ActionState, I should see suggestions and documentation for each method - provided as I type.
What actually happened
I do not see suggestions, such as "Was the button released since the last time [ActionState::update] was called?" for ActionState.just_pressed().
Additional Details
My app compiles and executes as expected - the message "I'm jumping!" displays once the appropriate key is pressed.

Hmm. I'm very unsure how to start going about fixing / reproducing this.
Which IDE and language-relevant extensions?

@alice-i-cecile Apologies, I made horrid assumptions and don't think my brain was on when I wrote this:

VS Code 1.64.0
rust-analyzer v0.2.932

rustc: 1.58.1
VS Code: 1.63.2
rust-analyzer: v0.2.867

Works on my machine, on an older version. Maybe I fixed it in on the dev branch somehow? Or check your RA autocomplete features: I have all of them enabled.
I don't think there's anything to be done on my end, sorry.

Thank you for the settings tip, did the trick :)


Animated hero image

A few things to note:

This is not perfect. The image (images/hero-poster.png) and the video (currently hosted by a third party) have the wrong aspect ratio. It must be 1.6:1, since that is the aspect ratio of the notebook's screen. This results in overlap as seen in the screenshot below.
The video is about 24 megabytes. It won't affect the page load, and shouldn't be perceptible to the user (even if it never loads) but methods of getting smaller file sizes should be explored.
While the video is loading, or if the video never loads due to browser incompatibility, hero-poster.png is shown on the screen.
If hero-poster.png does not load, the screen is black.
This scales with screen size, works on phones.
The image and video are rendered slightly larger than the frame they fit into. This is in order to prevent edge bleed issues.
When this is set up properly, the effect is really cool.

Thanks @Tajnymag for the video!

Ideas to make the video load quickly: Make it short. Avoid actions that will hamper vp8 compression, such as animated background changes.  Wait several seconds between actions, so that it doesn't feel rushed or look distracting. Don't move windows. Don't move the mouse unless necessary, don't type.

@devTristan the general idea is nice, but before we think about merging we'll want to 1. get the right aspect ratio (whether that's recording on the right resolution or resizing our laptop frame is up for discussion), and 2. record a cleaner video.
I had actually already started working on this locally this evening without seeing your branch. :stuck_out_tongue:

I totally agree with all of that. Thinking of this PR as a good start.
16:9 is the most common laptop aspect ratio, so I'm inclined to suggest that. On the other hand, the aesthetics of the notebook itself are important, so if 16:10 looks better it might be worth the hassle of getting video at that ratio.

I'm going to go ahead and close this. Since the last commit, we've massively changed how we deliver the image across sizes, as well as the model used in photos.


fix. when using a proxy encounters move will repeat 302

#194

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

Well, i tried to make as few changes as possible...
@oiooj Can you review the code for me?


Matching algorithm

Hi @yjh0410 !
Can you explain matching algorithm for training?

@developer0hye
Hi！
I just deploy the label assignment algorithm used in FCOS into my FreeYOLO to remove the anchor boxes.


Made the function to return a .png to save locally

Hi guys, don't know if it is the final product you are looking for. But this is the best I could find online..... Please let me know how it looks. Basically, it will save a .png locally once you call the function.

These look great to me! Let me know when it is merged so I can update our user examples .ipynb file


Officially support Typescript

Given the popularity of Typescript, first-party support for type definitions would be celebrated.

Hi there, great suggestion—we're also fans of Typescript so this is something we'll consider for a future release of this library! However, at the moment we have no current plans to work on this. We want to avoid duplicate work on type definitions so we can focus on making the core library great. A single type library to maintain would minimize the cost of adding new Elements to Stripe.js. For now, we recommend that you use the user-contributed Typescript definitions from DefinitelyTyped.

If this is something you will consider in the future, maybe leave the issue open so people can star it and track progress?

@fred-stripe I'd also ask you to keep the issue open please, so we have a place to track and discuss.
You see, the thing is that from a certain size of a codebase forward you'll have to have static types otherwise you can't quite grow anymore, especially when stripe seeks to get more traction in the enterprise space.

@fred-stripe you linked to a react definition, the issue is asking for generic support.

Would also love to see this re-opened so we could upvote.
I understand you don't want to work on type defs, but have you considered re-writing it in Typescript and getting type defs for free?  The node stripe sdk seems like it's already in Typescript and has beautiful types, it's a pleasure to work with.
The DefinitelyTyped repo has old unmerged PRs, it's not terribly inviting to try to go keep that up to date.  Thanks for considering it!

👋 We're currently beta testing React Stripe.js, a new library for integrating React and Stripe.js.  React Stripe.js includes built-in TypeScript definitions from Stripe. If anyone is interesting in testing out this new library, email<EMAIL_ADDRESS>with your Stripe ID for access to beta documentation.

No love for Angular?

Hi @jpike88,
We are not currently working on Angular bindings for Stripe.js, but we are shipping the types and a convenient loader for Stripe.js separately from the new React library.
You should be able to use @stripe/stripe-js in your Angular app.


TC-IDM-7.1 chip tool Darwin testing: Controller not waiting on the subscribed event with Wait set to true

As per step 1 in TC-IDM-7.1, Controller needs to subscribe to events and wait for notification when an event occurs. When Wait was set to true, the chip tool Darwin controller is not waiting on the subscribed event.  Compressed fabric ID is: 0xD099E40D93B1DC0C
[1648067189128] [39786:3724337] CHIP: [TOO] Sending command to node 0x0000000000000001
[1648067189128] [39786:3724341] CHIP: [DL] _OnPlatformEvent
[1648067189128] [39786:3724341] CHIP: [DL] Resolved interface id: 8
[1648067189129] [39786:3724341] CHIP: [DL] Mdns: OnGetAddrInfo hostname:E45F012EED540000.local.
[1648067189129] [39786:3724341] CHIP: [DL] Mdns: OnGetAddrInfo hostname:E45F012EED540000.local.
[1648067189129] [39786:3724341] CHIP: [DIS] Node ID resolved for 0x0000000000000001
[1648067189129] [39786:3724341] CHIP: [DIS]     Addr 0: [fe80::e65f:1ff:fe2e:ed54]:5540
[1648067189129] [39786:3724341] CHIP: [DIS]     Addr 1: [<IP_ADDRESS>]:5540
[1648067189129] [39786:3724341] CHIP: [CTL] OperationalDiscoveryComplete for device ID 0x0000000000000001
[1648067189129] [39786:3724341] CHIP: [IN] Generating DestinationID.  Status ../../third_party/connectedhomeip/src/controller/CHIPDeviceController.cpp:555: Success
[1648067189150] [39786:3724341] CHIP: [EM] Received message of type 0x31 with protocolId (0, 0) and MessageCounter:4060609871 on exchange 62279i
[1648067189150] [39786:3724341] CHIP: [EM] Found matching exchange: 62279i, Delegate: 0x7f8999027a38
[1648067189150] [39786:3724341] CHIP: [EM] Rxd Ack; Removing MessageCounter:3568040078 from Retrans Table on exchange 62279i
[1648067189150] [39786:3724341] CHIP: [EM] Removed CHIP MessageCounter:3568040078 from RetransTable on exchange 62279i
[1648067189150] [39786:3724341] CHIP: [SC] Received Sigma2 msg
[1648067189150] [39786:3724341] CHIP: [SC] Peer assigned session session ID 8
[1648067189150] [39786:3724341] CHIP: [SC] The device does not support GetClock_RealTimeMS() API. This will eventually result in CASE session setup failures.
[1648067189150] [39786:3724341] CHIP: [IN] Generating compressed fabric ID using uncompressed fabric ID 0x0000000000000000 and root pubkey
[1648067189150] [39786:3724341] CHIP: [IN] 0x04, 0x01, 0xba, 0x4f, 0x19, 0xdd, 0x03, 0x5e,
[1648067189150] [39786:3724341] CHIP: [IN] 0x84, 0xdf, 0x6f, 0x0a, 0x07, 0xeb, 0x3a, 0xec,
[1648067189150] [39786:3724341] CHIP: [IN] 0x55, 0xfd, 0xfb, 0x92, 0xc7, 0x53, 0x72, 0x3b,
[1648067189150] [39786:3724341] CHIP: [IN] 0x70, 0x1a, 0xcc, 0x88, 0x72, 0x5c, 0x6a, 0x3a,
[1648067189150] [39786:3724341] CHIP: [IN] 0xb5, 0x02, 0x7e, 0x0c, 0xc5, 0xea, 0x41, 0x8a,
[1648067189150] [39786:3724341] CHIP: [IN] 0x8c, 0x5f, 0x9e, 0x36, 0xae, 0x9c, 0xc7, 0xc8,
[1648067189150] [39786:3724341] CHIP: [IN] 0xd2, 0xf0, 0x1e, 0x89, 0x64, 0xde, 0x19, 0x4f,
[1648067189150] [39786:3724341] CHIP: [IN] 0x07, 0x4e, 0x09, 0x90, 0x25, 0x57, 0xc7, 0x38,
[1648067189150] [39786:3724341] CHIP: [IN] 0x05,
[1648067189150] [39786:3724341] CHIP: [IN] Generated compressed fabric ID
[1648067189150] [39786:3724341] CHIP: [IN] 0xd0, 0x99, 0xe4, 0x0d, 0x93, 0xb1, 0xdc, 0x0c,
[1648067189150] [39786:3724341] CHIP: [SC] Found MRP parameters in the message
[1648067189150] [39786:3724341] CHIP: [SC] Sending Sigma3
[1648067189151] [39786:3724341] CHIP: [EM] Piggybacking Ack for MessageCounter:4060609871 on exchange: 62279i
[1648067189151] [39786:3724341] CHIP: [IN] Prepared unauthenticated message 0x7f899a011668 to 0x0000000000000000 (0)  of type 0x32 and protocolId (0, 0) on exchange 62279i with MessageCounter:3568040079.
[1648067189151] [39786:3724341] CHIP: [IN] Sending unauthenticated msg 0x7f899a011668 with MessageCounter:3568040079 to 0x0000000000000000 at monotonic time: 764554396 msec
[1648067189151] [39786:3724341] CHIP: [SC] Sent Sigma3 msg
[1648067189159] [39786:3724342] CHIP: [EM] Received message of type 0x40 with protocolId (0, 0) and MessageCounter:4060609872 on exchange 62279i
[1648067189159] [39786:3724342] CHIP: [EM] Found matching exchange: 62279i, Delegate: 0x7f8999027a38
[1648067189159] [39786:3724342] CHIP: [EM] Rxd Ack; Removing MessageCounter:3568040079 from Retrans Table on exchange 62279i
[1648067189159] [39786:3724342] CHIP: [EM] Removed CHIP MessageCounter:3568040079 from RetransTable on exchange 62279i
[1648067189159] [39786:3724342] CHIP: [SC] Success status report received. Session was established
[1648067189159] [39786:3724342] CHIP: [IN] New secure session created for device 0x0000000000000001, LSID:1 PSID:8!
[1648067189159] [39786:3724341] CHIP: [TOO] Sending cluster (0x00000201) ReportAttribute (0x0000001C) on endpoint 1
2022-03-23 13:26:29.159 chip-tool-darwin[39786:3724342] DevicePairingDelegate Pairing complete. Status ../../third_party/connectedhomeip/src/controller/CHIPDeviceController.cpp:1478: Success
[1648067189159] [39786:3724342] CHIP: [EM] Sending Standalone Ack for MessageCounter:4060609872 on exchange 62279i
[1648067189159] [39786:3724342] CHIP: [IN] Prepared unauthenticated message 0x70000b857520 to 0x0000000000000000 (0)  of type 0x10 and protocolId (0, 0) on exchange 62279i with MessageCounter:3568040080.
[1648067189159] [39786:3724342] CHIP: [IN] Sending unauthenticated msg 0x70000b857520 with MessageCounter:3568040080 to 0x0000000000000000 at monotonic time: 764554405 msec
[1648067189159] [39786:3724342] CHIP: [EM] Flushed pending ack for MessageCounter:4060609872 on exchange 62279i
[1648067189160] [39786:3724341] CHIP: [CTL] Response Time: PFvPvhE+1849720993
[1648067189163] [39786:3724341] CHIP: [IN] Prepared secure message 0x7f899a011668 to 0x0000000000000001 (1)  of type 0x3 and protocolId (0, 1) on exchange 62280i with MessageCounter:14434177.
[1648067189163] [39786:3724341] CHIP: [IN] Sending encrypted msg 0x7f899a011668 with MessageCounter:14434177 to 0x0000000000000001 (1) at monotonic time: 764554408 msec
[1648067189163] [39786:3724341] CHIP: [DMG] MoveToState ReadClient[0x7f899849ee00]: Moving to [AwaitingIn]
[1648067189163] [39786:3724341] CHIP: [TOO] Error: ../../third_party/connectedhomeip/zzz_generated/chip-tool-darwin/zap-generated/cluster/Commands.h:59540: Success
[1648067189177] [39786:3724341] CHIP: [EM] Received message of type 0x5 with protocolId (0, 1) and MessageCounter:8573171 on exchange 62280i
[1648067189177] [39786:3724341] CHIP: [EM] Found matching exchange: 62280i, Delegate: 0x7f899849ee00
[1648067189177] [39786:3724341] CHIP: [EM] Rxd Ack; Removing MessageCounter:14434177 from Retrans Table on exchange 62280i
[1648067189177] [39786:3724341] CHIP: [EM] Removed CHIP MessageCounter:14434177 from RetransTable on exchange 62280i
[1648067189177] [39786:3724341] CHIP: [DMG] ReportDataMessage =
[1648067189177] [39786:3724341] CHIP: [DMG] {
[1648067189177] [39786:3724341] CHIP: [DMG] 	SubscriptionId = 0xaead3771a3af40c7,
[1648067189177] [39786:3724341] CHIP: [DMG] 	AttributeReportIBs =
[1648067189177] [39786:3724341] CHIP: [DMG] 	[
[1648067189177] [39786:3724341] CHIP: [DMG] 		AttributeReportIB =
[1648067189177] [39786:3724341] CHIP: [DMG] 		{
[1648067189177] [39786:3724341] CHIP: [DMG] 			AttributeDataIB =
[1648067189177] [39786:3724341] CHIP: [DMG] 			{
[1648067189177] [39786:3724341] CHIP: [DMG] 				DataVersion = 0x48c77a15,
[1648067189177] [39786:3724341] CHIP: [DMG] 				AttributePathIB =
[1648067189177] [39786:3724341] CHIP: [DMG] 				{
[1648067189177] [39786:3724341] CHIP: [DMG] 					Endpoint = 0x1,
[1648067189177] [39786:3724341] CHIP: [DMG] 					Cluster = 0x201,
[1648067189177] [39786:3724341] CHIP: [DMG] 					Attribute = 0x0000_001C,
[1648067189177] [39786:3724341] CHIP: [DMG] 				}
[1648067189177] [39786:3724341] CHIP: [DMG]
[1648067189177] [39786:3724341] CHIP: [DMG] 					Data = 1,
[1648067189177] [39786:3724341] CHIP: [DMG] 			},
[1648067189177] [39786:3724341] CHIP: [DMG]
[1648067189177] [39786:3724341] CHIP: [DMG] 		},
[1648067189177] [39786:3724341] CHIP: [DMG]
[1648067189177] [39786:3724341] CHIP: [DMG] 	],
[1648067189177] [39786:3724341] CHIP: [DMG]
[1648067189177] [39786:3724341] CHIP: [DMG] 	InteractionModelRevision = 1
[1648067189177] [39786:3724341] CHIP: [DMG] }
[1648067189179] [39786:3724341] CHIP: [DMG] MoveToState ReadClient[0x7f899849ee00]: Moving to [AwaitingSu]
[1648067189179] [39786:3724342] CHIP: [CTL] Response Time: PFvPvhE+1849720993 0.018256 seconds
[1648067189179] [39786:3724341] CHIP: [EM] Piggybacking Ack for MessageCounter:8573171 on exchange: 62280i
[1648067189179] [39786:3724341] CHIP: [IN] Prepared secure message 0x7f899a011668 to 0x0000000000000001 (1)  of type 0x1 and protocolId (0, 1) on exchange 62280i with MessageCounter:14434178.
[1648067189179] [39786:3724341] CHIP: [IN] Sending encrypted msg 0x7f899a011668 with MessageCounter:14434178 to 0x0000000000000001 (1) at monotonic time: 764554424 msec
2022-03-23 13:26:29.179 chip-tool-darwin[39786:3724342] Thermostat.SystemMode response 1
[1648067189179] [39786:3724342] CHIP: [TOO] Shutting down controller
[1648067189179] [39786:3724341] CHIP: [CTL] Shutting down the commissioner
[1648067189179] [39786:3724341] CHIP: [CTL] Shutting down the controller
[1648067189179] [39786:3724341] CHIP: [CTL] Shutting down the System State, this will teardown the CHIP Stack
[1648067189179] [39786:3724341] CHIP: [DMG] IM WH moving to [Uninitialized]
[1648067189179] [39786:3724341] CHIP: [DMG] IM WH moving to [Uninitialized]
[1648067189179] [39786:3724341] CHIP: [DMG] IM WH moving to [Uninitialized]
[1648067189179] [39786:3724341] CHIP: [DMG] IM WH moving to [Uninitialized]
[1648067189179] [39786:3724341] CHIP: [BLE] CancelConnection
[1648067189179] [39786:3724341] CHIP: [DL] Inet Layer shutdown
[1648067189179] [39786:3724341] CHIP: [DL] BLE shutdown
[1648067189179] [39786:3724341] CHIP: [DL] System Layer shutdown
[1648067189179] [39786:3724341] CHIP: [SPT] VerifyOrDie failure at ../../third_party/connectedhomeip/src/lib/support/Pool.h:217: Allocated() == 0
zsh: abort      ./chip-tool-darwin thermostat subscribe system-mode 1 1000 1 1 1
adk@adks-Mac-mini debug %

Fixed in https://github.com/project-chip/connectedhomeip/pull/16644.


杀杀杀User/mamatt/pagercontrol

Description

Motivation and Context

How Has This Been Tested?

Screenshots (if appropriate):
Types of changes

[ ] Bug fix (non-breaking change which fixes an issue)
[x] New feature (non-breaking change which adds functionality)
[ ] Breaking change (fix or feature that would cause existing functionality to change)

Hi @Wbhsuanming - what is the purpose of this pull request?

Please provide more context and update the title. After that, feel free to reopen.


remove json header check and update tests

Issue #, if available:
https://github.com/awslabs/aws-sam-cli/issues/591
Description of changes:

removed the check for header application/json
removed related tests
added one test with header binary/octet-stream

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

@jeremie-stratumn Did you by chance test this version locally with the Node SDK? I can't see a reason why it wouldn't but would like to double check. I will pull this down later today and run it as well.

Yes I did try it locally with the node AWS ask. Works perfectly fine.
On Fri, 3 Aug 2018 at 17:11, Jacob Fuss<EMAIL_ADDRESS>wrote:

@jeremie-stratumn https://github.com/jeremie-stratumn Did you by chance
test this version locally with the Node SDK? I can't see a reason why it
wouldn't but would like to double check. I will pull this down later today
and run it as well.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/awslabs/aws-sam-cli/pull/594#issuecomment-410283927,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AdO3ww_wwIxHF4TwyBfQuND9OIs6TuWGks5uNGgRgaJpZM4VtqkH
.

--
Jeremie DayanSenior Software Engineer
<EMAIL_ADDRESS>• +33 7 81 00 09 01 <javascript:void(0);>
stratumn.com • 1 bis Cité Paradis, 75010 Paris
https://www.google.com/maps/place/1+Bis+Cité+Paradis,+75010+Paris/@48.8753188,2.3478642,17z/data=!3m1!4b1!4m5!3m4!1s0x47e66e14c143d243:0x2ae24f55eb8013b8!8m2!3d48.8753188!4d2.3500529


Angular 9 Upgrade

When i run the Following Command i get this error Message
> ngcc --properties es2015 browser module main --first-only --create-ivy-entry-points
Warning: Entry point 'ngx-restangular' contains deep imports into 'C:/Projekte//node_modules/core-js/features/object'. This is probably not a problem, but may cause the compilation
of entry points to be out of order.

This appears to be a duplicate of #179

same warning :
Warning: Entry point 'ngx-restangular' contains deep imports into 'C:/../node_modules/core-js/features/object'. This is probably not a problem, but may cause the compilation of entry points to be out of order.
And when i run my project
ERROR : Cannot instantiate cyclic dependency! Restangular

Same Warning

I got the same warning using angular 9.1.4

Still no solution ?

There is no any new release of Restangular yet, so no solution. Anyway I got only a warning and everything works fine.

@pouyada
I have an error :
ERROR : Cannot instantiate cyclic dependency! Restangular
Can you tell me which version you use  (Angular / Restangular) ?
Thank you

"dependencies": {
"@angular-material-extensions/password-strength": "^6.0.0",
"@angular/animations": "^9.1.2",
"@angular/cdk": "^9.2.1",
"@angular/common": "~9.1.2",
"@angular/compiler": "~9.1.2",
"@angular/core": "~9.1.2",
"@angular/flex-layout": "^9.0.0-beta.29",
"@angular/forms": "~9.1.2",
"@angular/localize": "^9.1.2",
"@angular/material": "^9.2.1",
"@angular/material-moment-adapter": "^9.2.1",
"@angular/platform-browser": "^9.1.2",
"@angular/platform-browser-dynamic": "^9.1.2",
"@angular/router": "~9.1.2",
"core-js": "^3.6.5",
"font-awesome": "^4.7.0",
"hammerjs": "^2.0.8",
"jwt-decode": "^2.2.0",
"material-design-icons": "^3.0.1",
"moment": "^2.24.0",
"ngx-gallery-9": "^1.0.6",
"ngx-restangular": "^5.0.0",
"ngx-swiper-wrapper": "^9.0.1",
"ngx-webstorage-service": "^4.1.0",
"rxjs": "~6.5.5",
"rxjs-compat": "^6.5.5",
"tslib": "^1.10.0",
"zone.js": "~0.10.2"
},

Hello,
I would like to know if the ngx-restangular library is no longer supported ?
I could not update angular on my project since angular 9.
Version 10 of Angular is available and i have a error :
`
ERROR in node_modules/ngx-restangular/lib/ngx-restangular.module.d.ts:8:97 - error TS2314: Generic type 'ModuleWithProviders' requires 1 type argument(s).
tatic forRoot(providers?: any[], configFunction?: (provider: any, ...arg: any[]) => void): ModuleWithProviders;`
You can please tell me if you no longer support this library so that I can find another solution ?

Hello,
I would like to know if the ngx-restangular library is no longer supported ?

Hi Behnoosh,
For me its working with angular 9.x. contact me directly on mail and ill help you with that.
I don't know yet about the 10.x but it should work the same.

Angular 10 (typescript 3.9.6) generates the following:
ERROR in node_modules/ngx-restangular/lib/ngx-restangular.module.d.ts:8:97 - error TS2314: Generic type 'ModuleWithProviders' requires 1 type argument(s)

Hi! New version was released. Core-js library wasn't removed for now but all other issues should be resolved. Please let us know if
ERROR : Cannot instantiate cyclic dependency! Restangular error is still present

There is no any error however the warning persists.
Entry point 'ngx-restangular' contains deep imports into 'C:/../project-dir/node_modules/core-js/features/object'.
This is probably not a problem, but may cause the compilation of entry points to be out of order.

I always have this error in Angular 10:
ERROR : Cannot instantiate cyclic dependency! Restangular

I always have this error in Angular 10:
ERROR : Cannot instantiate cyclic dependency! Restangular

I think you are using it in a wrong way. please share the piece of code where you are importing and using Restangular.

I have been using it for about 2 years. I had no problem before Angular 9.
in app.module.ts :
`
import { RestangularModule } from 'ngx-restangular';
import { RestangularConfigFactory } from '../app/core/restangular.config';
imports: [....,,RestangularModule.forRoot([my services], RestangularConfigFactory),....
`
export function RestangularConfigFactory(RestangularProvider, mes services) { RestangularProvider.setBaseUrl(...)  RestangularProvider.setPlainByDefault(true); RestangularProvider.setDefaultHeaders({     'Content-Type': 'application/json'   }); RestangularProvider.addFullRequestInterceptor(() => {... RestangularProvider.addErrorInterceptor((response) => {...
in services, ex:
`
import { Restangular } from 'ngx-restangular';
constructor(private restangular: Restangular) {}
getAbout(): Observable {
return this.restangular.one(ABOUT_RESOURCE_URL)
.withHttpConfig({timeout: timeout})
.get();
}
`

@BehnooshShiva make sure none of your services here:
imports: [....,,RestangularModule.forRoot([my services], RestangularConfigFactory),....
have a dependency to restangular.
then in your service:
constructor(private restangular: Restangular) {}
try to use restangular as public

Make sure none of your services here !
It is a complex project and all the messages, error messages, localstorage and etc managed by services.
It is mandatory to use services in RestangularConfigFactory


Period Info

Make period info sync based on date selected on calendar instead of current date. Right now if you go to a Spring or Winter tri class and click period info you’d get the info for fall tri and not their respective tri.
Submitted via Form

@thesuperRL another trimester-related issue

Right now, this period info is not showing

yeah, it seems like clicking on Period Info just opens the view of the first student. @ajosan25 do you want to look at this and see what happened here?

I think I fixed that with #559. The place to fix this is in https://github.com/EastsidePreparatorySchool/epschedule/blob/master/app.py#L328, suggest passing in the date as a query param which can then be fed to get_term_id.

How do we know which date the user is referencing in the python app? Is there a variable?

We have it in the JS, 'globalDate'


Updating master

Codecov Report

Merging #62 into master will increase coverage by 0.01%.
The diff coverage is 100%.

@@            Coverage Diff             @@
##           master      #62      +/-   ##
==========================================
+ Coverage    99.5%   99.52%   +0.01%
==========================================
  Files          28       28
  Lines         609      629      +20
  Branches       76       77       +1
==========================================
+ Hits          606      626      +20
  Misses          3        3

Impacted Files
Coverage Δ

src/redux/actions/datatableActions.js
100% <100%> (ø)
:arrow_up:

src/proptypes.js
100% <100%> (ø)
:arrow_up:

src/redux/reducers/datatableReducer.js
99.42% <100%> (+0.03%)
:arrow_up:

...c/components/DatatableCore/Body/BodyActionsCell.js
100% <100%> (ø)
:arrow_up:

Continue to review full report at Codecov.

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


Breaks if dark mode isn't turned on

Yes as mentioned in the readme ...

Yep, that's the setting it's designed for. As mentioned in both the readme and the extension.


Move domain validation checks for URI/Username to service startup

These checks were done once per request. These instead can be static
checks done on service startup. This enforces that the Username and URI
configs appropriately set the SubjectDomain and IssuerUrl fields, with
no scheme just for the SubjectDomain field for Username.
Signed-off-by: Hayden Blauzvern<EMAIL_ADDRESS>
Summary

Ticket Link

Fixes
Release Note

Codecov Report

Merging #590 (96e8769) into main (f334c15) will increase coverage by 0.83%.
The diff coverage is 81.53%.

:exclamation: Current head 96e8769 differs from pull request most recent head 7659a0e. Consider uploading reports for the commit 7659a0e to get more accurate results

@@            Coverage Diff             @@
##             main     #590      +/-   ##
==========================================
+ Coverage   48.44%   49.28%   +0.83%
==========================================
  Files          21       21
  Lines        1515     1540      +25
==========================================
+ Hits          734      759      +25
  Misses        707      707
  Partials       74       74

Impacted Files
Coverage Δ

pkg/challenges/challenges.go
40.45% <ø> (-2.90%)
:arrow_down:

pkg/config/config.go
63.47% <81.53%> (+6.78%)
:arrow_up:

Continue to review full report at Codecov.

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


docs: resctructure to be in compliance according to Grafana Plugin Re…

docs: resctructure to be in compliance according to Grafana Plugin Re…
Grafana has a tool named Plugin Validator https://github.com/grafana/plugin-validator which tells us what is wrong in the plugin before we send to be published.
docs: fix some images links to point to the src/img/assets directory instead of public links on the internet
docs: adjust the title of the README

@alvarowolfx, fixed. Can we merge to develop?

@alvarowolfx, i needed to make a new rebase because there were another PR which was concluded first. And because of that, this branch had to be rebased and some conflicts to solve. I finished everything and it's all on the remote now (rebased and conflicts sovled)

I can finish the PR or you need to review again?


Make missing token error more actionable

TL;DR: People have been running into an issue where having multiple versions of a same plugin would cause the DI system to throw errors about missing dependencies. The error was cryptic and difficult to troubleshoot.
This PR  exposes stack information about the missing token as well as potential problematic duplicated tokens, and it offers actionable suggestions to fix the issue.
I labeled this PR w/ the feature flag because this diff adds a stack field to Token
// Before
Error: Could not resolve token: "A", which is required by plugins registered with tokens: "UnnamedPlugin". Did you forget to register a value for "A"?
    at resolveToken (/Users/lhorie/Documents/aaa/node_modules/fusion-core/src/base-app.js:202:15)
    at resolvePlugin (/Users/lhorie/Documents/aaa/node_modules/fusion-core/dist/index.js:544:31)
    at resolveToken (/Users/lhorie/Documents/aaa/node_modules/fusion-core/dist/index.js:560:20)
    at App.resolve (/Users/lhorie/Documents/aaa/node_modules/fusion-core/dist/index.js:590:7)
    at App.resolve (/Users/lhorie/Documents/aaa/node_modules/fusion-core/dist/index.js:895:20)
    at App.callback (/Users/lhorie/Documents/aaa/node_modules/fusion-core/dist/index.js:899:12)
    at reload (/Users/lhorie/Documents/aaa/node_modules/fusion-cli/entries/server-entry.js:90:1)
    at
    at process._tickCallback (internal/process/next_tick.js:189:7)
    at evalScript (bootstrap_node.js:482:13)

// After
Error: A plugin depends on a token, but the token was not registered

Required token: A
This token is required by plugins registered with tokens: "Foo", "Bar"
Error
    at new TokenImpl (/Users/lhorie/Documents/aaa/node_modules/fusion-core/dist/index.js:45:18)
    at createToken (/Users/lhorie/Documents/aaa/node_modules/fusion-core/dist/index.js:55:10)
    at Module../src/main.js (/Users/lhorie/Documents/aaa/src/main.js:10:1)
    at __webpack_require__ (/Users/lhorie/Documents/aaa/webpack/bootstrap:682:1)
    at fn (/Users/lhorie/Documents/aaa/webpack/bootstrap:59:1)
    at Module../node_modules/fusion-cli/entries/server-entry.js (/Users/lhorie/Documents/aaa/node_modules/fusion-cli/entries/server-entry.js:46:1)
    at __webpack_require__ (/Users/lhorie/Documents/aaa/webpack/bootstrap:682:1)
    at fn (/Users/lhorie/Documents/aaa/webpack/bootstrap:59:1)
    at Object.0 (/Users/lhorie/Documents/aaa/.fusion/dist/development/server/server-main.js:1518:18)
    at __webpack_require__ (/Users/lhorie/Documents/aaa/webpack/bootstrap:682:1)

Different tokens with the same name were detected:

A
Error
    at new TokenImpl (/Users/lhorie/Documents/aaa/node_modules/fusion-core/dist/index.js:45:18)
    at createToken (/Users/lhorie/Documents/aaa/node_modules/fusion-core/dist/index.js:55:10)
    at Module../src/main.js (/Users/lhorie/Documents/aaa/src/main.js:9:1)
    at __webpack_require__ (/Users/lhorie/Documents/aaa/webpack/bootstrap:682:1)
    at fn (/Users/lhorie/Documents/aaa/webpack/bootstrap:59:1)
    at Module../node_modules/fusion-cli/entries/server-entry.js (/Users/lhorie/Documents/aaa/node_modules/fusion-cli/entries/server-entry.js:46:1)
    at __webpack_require__ (/Users/lhorie/Documents/aaa/webpack/bootstrap:682:1)
    at fn (/Users/lhorie/Documents/aaa/webpack/bootstrap:59:1)
    at Object.0 (/Users/lhorie/Documents/aaa/.fusion/dist/development/server/server-main.js:1518:18)
    at __webpack_require__ (/Users/lhorie/Documents/aaa/webpack/bootstrap:682:1)

You may have multiple versions of the same plugin installed.
Ensure that `yarn list [the-plugin]` results in one version, and use a yarn resolution or merge package version in your lock file to consolidate versions.

    at resolveToken (/Users/lhorie/Documents/aaa/node_modules/fusion-core/src/base-app.js:164:17)
    at resolvePlugin (/Users/lhorie/Documents/aaa/node_modules/fusion-core/dist/index.js:522:31)
    at resolveToken (/Users/lhorie/Documents/aaa/node_modules/fusion-core/dist/index.js:538:20)
    at App.resolve (/Users/lhorie/Documents/aaa/node_modules/fusion-core/dist/index.js:568:7)
    at App.resolve (/Users/lhorie/Documents/aaa/node_modules/fusion-core/src/server-app.js:25:12)
    at App.callback (/Users/lhorie/Documents/aaa/node_modules/fusion-core/dist/index.js:877:12)
    at reload (/Users/lhorie/Documents/aaa/node_modules/fusion-cli/entries/server-entry.js:90:1)
    at
    at process._tickCallback (internal/process/next_tick.js:189:7)
    at evalScript (bootstrap_node.js:482:13)

@KevinGrandon I incorporated the old message into the new one. It now says This token is required by plugins registered with tokens: "Foo", "Bar". See updated code section above

Yeah, I'm thinking what's the best way to expose that tree. I'm going to merge this for now, and look into a DI graph viz separately


I am new here and just trying new things. Remove this entry if inappropriate. I'm looking for a way to copy group setting to another group. Somewhere I found

The issue tracker is for reporting product deficiencies. "How do I?" questions should be posted to the discussion forum at https://groups.google.com/group/google-apps-manager. When in doubt, start at the discussion forum and return here only when instructed to do so.
Please confirm the following:

I have upgraded to the latest GAM release from https://git.io/gamreleases and I still have this issue.
I am typing the command as described in the GAM Wiki at https://github.com/jay0lee/gam/wiki

Full steps to reproduce the issue:
1.
2.
3.
Expected outcome (what are you trying to do?):
Actual outcome (what errors or bad behavior do you see instead?):

This capability is available in Advanced GAM.
See: https://github.com/taers232c/GAMADV-XTD3/wiki/Groups#manage-groups

Please post "how do I?" questions to the forum where discussion is encouraged:
https://groups.google.com/group/google-apps-manager


proposal: time: direct support for Unix millis and micros

Initial tl;dr: Go could make timestamp handling much easier by providing the following functions in its time library:
func (t Time) UnixMicro() int64 { ... }
func (t Time) UnixMilli() int64 { ... }
func FromUnixMicro(us int64) Time { ... }
func FromUnixMilli(ms int64) Time { ... }

Golang has time.Time as the idiomatic way of representing a time. However, not every API we encounter has this, and lots of them return Unix-style timestamps as int64 (sometimes uint64) in units of ms, us, or ns. For example, this will always occur when using API's that operate on protocol buffers, which use integers for timestamps instead of a native time type.
If we happen to have nanosecond timestamps, go is pretty nice. However, if we're using microseconds, then it gets fairly annoying to use time.Time, as you'll have to do error-prone type conversions everywhere, or rely on a timeutil library you write yourself for something which feels like it should be built in.
This is the type of stuff we have to do right now when dealing with niceapi that uses time.Time and otherapi that uses microseconds:
ts := otherapi.GetTimestamp()
t := time.Unix(0, ts * 1000) // one unit conversion, potential cause for bugs
niceapi.Use(t)

// elsewhere
t := niceApi.WhatTime()
ts := t.UnixNano() / 1000 // second unit conversion, potential cause for bugs
otherApi.Use(ts)

But why not
t := time.FromUnixMicro(otherapi.GetTimestamp()) // seems way less error prone to me
niceapi.Use(t)

// elsewhere
ts := niceApi.WhatTime().UnixMicro() // so easy!
otherApi.Use(ts)

I'm in favor of this. At $WORK we have an auxiliary time package that defines
func FromUnixMilli(ms int64) time.Time
func UnixMilli(t time.Time) int64

and these see a fair amount of use since ms-since-epoch is a common timestamp standard (as one example, you see it a lot in Javascript/web contexts since Date.now() returns ms).

The fact that Date.now() returns ms in Javascript is good context.
What common systems use micros?
The getters on time are unobjectionable; the new constructor names are not as nice. It would be easier to accept this proposal if we had a better idea for the names.

@rsc what do you think would be nicer for the constructor names? Is it better to name them UnixMicro and UnixMilli (to match the identically named getter and constructor style already being used)?

I don't think we should add milli without adding micro, because it would be a seemingly arbitrary omission to have 10^0, 10^-3, 10^-9, completely skipping 10^-6
But in any case, I looked around and I found a few instances of use for microseconds in time as well:
https://docs.oracle.com/javase/7/docs/api/java/util/concurrent/TimeUnit.html#toMicros(long)
https://docs.python.org/2/library/datetime.html#datetime.time.microsecond
https://hackage.haskell.org/package/time-units-1.0.0/docs/Data-Time-Units.html
http://erlang.org/doc/man/erlang.html#type_time_unit
http://pubs.opengroup.org/onlinepubs/7908799/xsh/systime.h.html
http://www.cplusplus.com/reference/chrono/microseconds/
For cases that use floats instead of ints, microsecond precision also seems to be used sometimes:
http://php.net/manual/en/function.microtime.php
https://www.postgresql.org/docs/current/static/functions-datetime.html#FUNCTIONS-DATETIME-CURRENT
https://mariadb.com/kb/en/mariadb/microseconds-in-mariadb/

@aebrahim I didn't look at all of those, but the ones I did all seemed to be about turning (in Go terms) a time.Duration into microseconds, not about a time stamp expressed in microseconds since 1970. Go already does have time.Microsecond for computing with durations.

OK, I see what you mean. Here's a list of functions that use seconds, microseconds % seconds since the unix epoch:

Unix gettimeofday
Perl gettimeofday
PHP gettimeofday
python -c "import datetime; print(repr(datetime.datetime.now()))"
Erlang:now
Ruby time.at(seconds, microseconds_with_frac)

@aebrahim OK, but that's still not really motivation for adding t.UnixMicros() int64. What I'm hoping for is some evidence that this is a common serialized time format, used in file formats, network protocols, or other places where times are written down.

 One of the main arguments for passing around a Time instead of an int is that you don't have those pesky unit mismatch bugs. But because the time library uses constants instead of functions, you end up with conversion bugs ("do I multiply or divide by time.Microsecond....?").
If you're looking for how ugly things are with the current library, just read through http://stackoverflow.com/questions/24122821/go-golang-time-now-unixnano-convert-to-milliseconds and try not to scream at your monitor. If you succeed, you have more willpower than I do.

Personally I don't see anything very wrong with
t.UnixNano() * int64(time.Nanosecond) / int64(time.Microsecond)

Not that I object strongly to t.UnixMicro() but it seems easy enough to convert from nanoseconds to microseconds.
I do agree with Russ: we should add UnixMicro if there is demand.  Simply saying that it is a logical extension is not enough.  Every new feature makes the package harder to understand.  We should only add features that carry their weight.

My main issue with this is that it's the opposite of what you'd expect from unit conversions.
t.UnixNano() * int64(time.Nanosecond) / int64(time.Microsecond)

However, this is how you would do a unit conversion, with microseconds in the numerator instead of denominator:
40000 nanoseconds * 1 microsecond /  1000 nanoseconds.
This seems makes an already error prone operation even worse. This is way more error prone than just using microseconds everywhere to start with instead of using go's time.

The formula is not too hard to come up, even if from unit conversion
perspective:
to convert ns to us, we need to multiply us/ns.
assuming Go's abstract time unit is UNIT, then
time.Nanosecond = UNIT/ns, and
time.Microsecond = UNIT/us.
Therefore to get the number of us/ns, we need scale = time.Nanosecond /
time.Microsecond.
That is: t.UnixNano() * time.Nanosecond / time.Microsecond.

I personally think that the math working out only with UNIT/ns really violates the principle of least astonishment. Especially when in other places, we do things like 3 * time.Microsecond

OK, but that is an argument for a NanoToMicro function.  It's not an argument for a Time.UnixMicro method.

I for one would be ecstatic with a function like
func (d Duration) ToUnit(u Duration) {
return d / u
}
and then it would look like:
t.UnixNano().ToUnit(time.Microsecond)
(Warning I am not a golang nor naming expert)

@ianlancetaylor that's a good point. I just think there has to be a better way to to convert unix timestamps without doing unit conversions. It may not necessarily be what I proposed, and I'd be happy to change it with whatever idea we think is best here
Another potential idea I'd like to throw into the mix is:
func (d Duration) Microseconds() int64 { ... }
func (d Duration) Milliseconds() int64 { ... }
func (t Time) UnixDuration() Duration { ... }

This would let you do
time.Now().UnixDuration().Microseconds()

However, we'd still need a way to construct the time from a timestamp.

Here is another proposal which goes both directions (to/from timestamps) and can be done with only 3 additions. We could add
var UnixEpoch = time.Unix(0, 0) // a constant of the time at the start of the unix epoch
func (d Duration) Milliseconds() float64 { ... }
func (d Duration) Microseconds() float64 { ... }

This would allow the following
// int64 timestamp to time
var tsMicro int64 = 1000000
t := time.UnixEpoch.Add(time.Duration(tsMicro) * time.Microsecond)
// time to int64 timestamp
ts = time.Now().Sub(UnixEpoch).Microseconds()

The one thing I don't like about this is the kind of clunky time.Duration(tsMicro) * time.Microsecond

@mattalbr Supporting s and ns is not arbitrary at all. The full precision stored in the time.Time is nanoseconds, hence t.UnixNano() returning nanoseconds. And then it turns out that many common systems and formats - among them tar and gzip in the standard library - store Unix time in seconds (aka time_t), hence t.Unix() returning seconds.
What's missing from this proposal is a strong motivation for adding t.UnixMicro and t.UnixMilli and the reverse converters. The best motivation would be easier interoperability or less worry about overflow (since the time package could do a better job than Nano/1000) when using some existing systems, formats, or wire protocols that represent time in these formats. It's true that many Unix-based operating systems use Unix millis and micros in system calls, but Go abstracts those system calls away.
At Google we have a variety of systems that store time in Unix micros, and we too have a local conversion library to make that easier. But importance to Google alone is not a compelling argument for adding the API surface to package time, so we haven't. And more recently, the standard proto buffer Timestamp now uses nanoseconds.
@cespare mentioned that systems at his work use Unix millis internally, because Java System.currentTimeMillis and Javascript Date.now both return Unix millis, and they have a local conversion library to make that easier.
What's needed to move forward is more evidence that this is a widespread need. We have not been able to find existing systems, formats, or wire protocols that use this representation. Those would still be nice, but if there is enough evidence of internal systems at various places that need these formats, that might be enough.

@rsc I think it's pretty clear this is a pain point between stack overflow, Google code internals, and other testimonials. We're trying to solicit suggestions to alleviate that pain point. It doesn't have to be UnixNano() and UnixMicro(); we would love if you proposed something different that you think more generalizable/useful/idomatic/what have you.
I really like @aebrahim's first suggestion of UnixDuration() and the two methods on Duration.
Re: going from int64 (micros) to Time, I still don't love that you have to multiply by time.Microsecond. What would people think about a constructor for Duration that takes the units? So:
tusec := 1000000
t := time.Unix(0, newDuration(tusec, time.Microsecond).Nanoseconds())
and the reverse
t := time.Now()
tusec := t.UnixDuration().Microseconds()

@mattalbr:

I think it's pretty clear this is a pain point between stack overflow, Google code internals, and other testimonials.

As I pointed out in my previous message, Google's internal systems don't count by themselves, unless there is reason to believe that experience is shared by others. That's why I'm asking for examples of systems that would need these conversions. Concrete details are great. Vague references to stack overflow and "other testimonials" not so much.
Let's focus on understanding the justification / motivation before we start proposing or evaluating alternative APIs.

I think what Matt and I are trying to say is that time conversions in go are generally problematic. Unix microsecond timestamp conversions are a manifestation of that. I'm not looking for a FromUnixMicro function; I'm looking for any way to achieve that without doing unit conversions.
Because of the pushback on a Unix-specific microseconds function, I'm instead suggesting we change this proposal to make it simpler to just convert units for duration (which is a very common operation in many different languages), and then provide a canonical way to convert from time to Duration since the Unix epoch.
The initial list I sent out clearly establishes that converting between the equivalent of a Duration and micro/milli seconds is common in many languages. Can we at least agree on these 2 functions?
func (d Duration) Milliseconds() float64 { ... }
func (d Duration) Microseconds() float64 { ... }

A Time is an instant. A Duration is a delta between two instants. They have the same units, but it is important not to confuse them. A Duration can be meaningfully added to a Time. A Time cannot. Adding a t.UnixDuration() method violates that very helpful separation. We are not going to add that method nor in any other way encourage converting Times to Durations.
If there is a common need for UnixMicro and UnixMilli, we can add them. I am still waiting for evidence of that. @aebrahim and @mattalbr, you work at Google, where lots of internal systems store Unix micros as a time format. You're generalizing from that setting to the world outside Google, but there's no evidence here that the generalization is valid.

Regarding time.Duration conversions, the idioms are:
d := time.Duration(ms) * time.Millisecond
ms := int64(d / time.Millisecond)

I'm sorry, but that doesn't seem to me “generally problematic.” In any event, if you want to discuss the Duration API, best to start a new issue. Let's keep this one about whether to add t.UnixMicro and t.UnixMilli.

Because I was unable to find examples of this being a common need, I am leaning toward not doing this. I did web searches and asked on Twitter and got nothing back except for one or two internal uses.

https://play.golang.org/p/UaXMVCQ6pW
`package main
import (
"fmt"
"time"
)
func main() {
fmt.Println("Hello, playground")
n:=int32(1000000000)
t:=time.Now().AddDate(int(n),0,0)
fmt.Println(t)
fmt.Println(t.UnixNano())
t2:=time.Unix(0,t.UnixNano())
fmt.Println(t2)
t3:=time.Unix(t.Unix(),0)
fmt.Println(t3)
}`
prints
Hello, playground
102008-11-10 23:00:00 +0000 UTC
2528321395666673664
2050-02-12 23:29:55.666673664 +0000 UTC
102008-11-10 23:00:00 +0000 UTC
shows that due to int overflow, we have some issues with time representation. Consideration the buzz around the blockchain technology for example and what it can accomplish, and because this is an immutable distributed ledger ... if it becomes very popular maybe those entries would have to still be accessible later than year 2262 (with a consistent timestamp representation).
What if we could get a decomposed version of a time (with a Timestamp() int64,int64 method), with a seconds representation, and the additional nanoseconds precision. We already have time.Unix(sec,nanosec) that constructs time from a count of sec and nanosecond. It could help store dates as n1(sec)+n2(nanosecond) .
Then a "common" timestamp would be seconds based and we could store some additional precision (to the nanosecond) if required without overflowing. Reducing precision would just be an integer division of the nanosecond count to the precision level (for instance ns/time.Millisecond).
The first part count (seconds) of the timestamp is already returned by t.Unix(), the t.UnixNano() is the one that gets overflowed because returning the whole nanoseconds count, instead of only the precision that can not be returned by the t.Unix()

just discovered that this basically is how the timestamp is represented in protobuf: seconds + nanoseconds. So this decomposition seems relevant.

@laahs This issue is closed and you seem to be talking about a different problem in any case.  Please use a forum (https://golang.org/wiki/Questions) or open a new issue.  Thanks.


SSH enable forwarding data variable

idea source: https://stackoverflow.com/questions/67272230/pyinfra-forwarding-ssh-agent
Is your feature request related to a problem? Please describe
Sometimes it may not be possible to enable SSH forwarding via SSH config.
Describe the solution you'd like
Add a ssh_enable_forwarding data variable to the @ssh connector to explicitly enable SSH forwarding.

Implemented in https://github.com/Fizzadar/pyinfra/commit/c4981854680f7e2b6d8ccafbe6217d9bcf11c280, pending release in v1.5.


[bug] sparsity returning incorrect values

What happened + What you expected to happen
Sparsity is not being calculated correctly in the code. See below. The data clearly has 0 values and the expected sparsity is 0.5, but the code is returning a value of 0.

Versions / Dependencies
Name: tsfeatures Version: 0.4.5
Reproduction script
import pandas as pd
data = {'y': [0, 23, 0, 45, 0, 19, 0, 7, 34, 0]}
df = pd.DataFrame(data)
df["unique_id"] = "A"
from datetime import datetime, timedelta
start_date = datetime(2024, 1, 1)
df['ds'] = [start_date + timedelta(weeks=i) for i in range(len(df))]
df

# Extract features
from tsfeatures import sparsity
tsfeatures(df, freq=52, features=[sparsity])

# Expected result
np.mean(df["y"] == 0)  # 0.5

Issue Severity
Medium: It is a significant difficulty but I can work around it.

This is because the scale argument is set to True by default. To calculate the correct value, set scale to False
tsfeatures(df, freq=52, features=[sparsity], scale=False)

Looks like an enhancement request is already in place: https://github.com/Nixtla/tsfeatures/issues/40


getDailySteps returns empty array

Hello guys, I am trying to get daily steps data from my google fit app. I can see the steps data in the app but getDailySteps() is returning an empty array. I am using "react": "18.1.0", "react-native": "0.70.4", "react-native-google-fit": "^0.19.0".
Below is my code:
const getDailySteps = () => {
    GoogleFit.getDailySteps("2022-11-02T10:38:48.611Z")
      .then((res) => {
        console.log('getDailySteps >>> ', res);
      })
      .catch((err) => {console.warn(err)});
  }

const handleAuthorize = () => {
  const options = {
    scopes: [
      Scopes.FITNESS_ACTIVITY_READ,
      Scopes.FITNESS_ACTIVITY_WRITE,
      Scopes.FITNESS_LOCATION_READ,
      Scopes.FITNESS_LOCATION_WRITE
    ]
  }
  GoogleFit.authorize(options)
    .then(authResult => {
      if (authResult.success) {
        console.log("AUTH_SUCCESS");
        getDailySteps();
      } else {
        console.log("AUTH_DENIED - " + authResult.message);
      }
    })
    .catch(() => {
      console.log("AUTH_ERROR");
    });
}
handleAuthorize();

AndoridManifest.xml:
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.ACTIVITY_RECOGNITION"/>
<uses-permission android:name="android.permission.ACCESS_FINE_LOCATION"/>

<uses-sdk android:targetSdkVersion="22" />

<queries><package android:name="com.google.android.apps.fitness" /></queries>

settings.gradle:
include ':react-native-google-fit'
project(':react-native-google-fit').projectDir = new File(rootProject.projectDir, '../node_modules/react-native-google-fit/android')

Here is the console.log output:
getDailySteps >>>
[{"rawSteps": [], "source": "com.google.android.gms:merge_step_deltas", "steps": []},
{"rawSteps": [], "source": "com.xiaomi.hm.health", "steps": []},
{"rawSteps": [], "source": "com.google.android.gms:estimated_steps", "steps": []}]

Please help. Thanks!

@gibmax  did you find a solution for this?

@krisidmisso No, I wasn't able to resolve this issue

Try disconnect and reconnect it will work


Fix a bug where the jinja template for analyticstories_detection cra…

Fix a bug where the jinja template for analyticstories_detection crashed when specifying a detection.tags.asset_type. Fixes #313.

Hi @Res260 - I am having trouble replicating this bug, even using the example Detection you provided.
When I poke around at the value of detection.tags.asset_type, it is showing me it is enum 'AssetType'
This is with the latest version of contentctl in main
Did you make any other changes in your fork, potential around the use_enum_values configDict Pydantic setting?

I have not. I'm using Python 3.12, are you using the same version?

Specifically, I'm running Python 3.12.6 on Windows 11.
Here is a snippet of my pip freeze:
annotated-types==0.7.0
antlr4-python3-runtime==4.9.3
arrow==1.3.0
artifacts-keyring==0.3.6
attackcti==0.4.4
attrs==24.2.0
azure-common==1.1.28
azure-core==1.31.0
azure-identity==1.14.0
azure-mgmt-core==1.4.0
azure-mgmt-securityinsight==1.0.0
beautifulsoup4==4.12.2
bottle==0.12.25
certifi==2024.8.30
cffi==1.17.1
charset-normalizer==3.3.2
click==8.1.7
colorama==0.4.6
colour==0.1.5
contentctl==20241107.21.54
cpe==1.3.0
cryptography==43.0.1
cybox==<IP_ADDRESS>
deepdiff==8.0.1
deprecation==2.1.0
distlib==0.3.8
docker==7.1.0
docstring_parser==0.16
drawsvg==2.4.0
et-xmlfile==1.1.0
fancycompleter==0.9.1
filelock==3.16.1
fqdn==1.5.1
gitdb==4.0.11
GitPython==3.1.43
idna==3.10
iniconfig==2.0.0
isodate==0.6.1
isoduration==20.11.0
jaraco.classes==3.4.0
jaraco.context==6.0.1
jaraco.functools==4.0.2
Jinja2==3.1.4
jsonpointer==3.0.0
jsonschema==4.23.0
jsonschema-specifications==2023.12.1
keyring==25.4.1
loguru==0.7.2
lxml==5.3.0
maec==<IP_ADDRESS>
Markdown==3.7
markdown-it-py==3.0.0
MarkupSafe==2.1.5
mdurl==0.1.2
mitreattack-python==3.0.6
mixbox==1.0.5
more-itertools==10.5.0
msal==1.31.0
msal-extensions==1.2.0
msrest==0.7.1
netaddr==1.3.0
numpy==2.1.1
oauthlib==3.2.2
openpyxl==3.1.5
ordered-set==4.1.0
orderly-set==5.2.2
packaging==24.1
pandas==2.2.3
pdbpp==0.10.3
pillow==10.4.0
pipenv==2024.0.3
platformdirs==4.3.6
pluggy==1.5.0
pluralizer==1.2.0
pooch==1.8.2
portalocker==2.10.1
prettytable==3.10.0
prompt-toolkit==3.0.36
pycountry==24.6.1
pycparser==2.22
pycvesearch==1.2
pydantic==2.9.2
pydantic_core==2.23.4
pygit2==1.15.1
Pygments==2.18.0
PyJWT==2.9.0
pyparsing==3.1.4
pyreadline3==3.5.4
pyrepl==0.9.0
pySigma==0.11.17
pytest==8.3.3
python-certifi-win32==1.6.1
python-dateutil==2.9.0.post0
pytz==2024.2
pywin32==306
pywin32-ctypes==0.2.3
PyYAML==6.0.2
questionary==2.0.1
referencing==0.35.1
requests==2.32.3
requests-oauthlib==2.0.0
rfc3339-validator==0.1.4
rfc3986-validator==0.1.1
rich==13.8.1
rpds-py==0.20.0
semantic-version==2.10.0
setuptools==70.3.0
setuptools-scm==8.1.0
shellingham==1.5.4
shtab==1.7.1
sigma-cli==1.0.4
simplejson==3.19.3
six==1.16.0
smmap==5.0.1
soupsieve==2.6
splunk-sdk==2.0.2
stix==<IP_ADDRESS>
stix2==3.0.1
stix2-elevator==4.1.7
stix2-patterns==2.0.0
stix2-validator==3.2.0
stixmarx==1.0.8
tabulate==0.9.0
taxii2-client==2.3.0
tqdm==4.66.5
typer==0.12.5
types-python-dateutil==<IP_ADDRESS>40906
typing_extensions==4.12.2
tyro==0.8.11
tzdata==2024.2
uri-template==1.3.0
urllib3==2.2.3
virtualenv==20.26.5
wcwidth==0.2.13
weakrefmethod==1.0.3
webcolors==24.8.0
win32-setctime==1.1.0
wmctrl==0.5
wrapt==1.16.0
XlsxWriter==3.2.0
xmltodict==0.13.0

Thanks for the more specific debug info @Res260  - I will try to replicate this exact config and try to debug more locally 😄
We also have an issue to remove the widespread use of use_enum_values which leads to lots of.... weird requirements to use the enum or enum.value in different types of comparisons/serializations:
https://github.com/splunk/contentctl/issues/266

All the enums in our codebase have been updated to either StrEnum or IntEnum which has allowed us to remove the weird, seemingly pseudo-random usages of enumName.value all over the codebase.  This was done in the following PR: https://github.com/splunk/contentctl/pull/335 which has been merged into our next big update, the contentctl_5 PR: https://github.com/splunk/contentctl/pull/334
I believe that this will fix the issue at it's source, but I will need to do some testing to ensure that is the case.


Finetuning BertModel to extract textual features for VQA shows bad results

❓ Questions & Help
I am trying to use Bert as a textual feature extractor for VQA.
This is the code for tokenizing question text in VQA.
    self.tokenizer = pytorch_transformers.BertTokenizer.from_pretrained(
            'bert-base-uncased')
    q = self.tokenizer.encode(q_text, add_special_tokens=True)

This code is for extracting features from Bert.

  self.bert = pytorch_transformers.BertModel.from_pretrained('bert-base-uncased',
                                                                   output_attentions=True)
    question_mask_cls = torch.arange(lengths[0]).to(self.device)
    lengths_cls = lengths
    q_mask_cls = question_mask_cls[None, :] < lengths_cls[:, None]
    q_mask_cls = q_mask_cls.to(torch.float32)
    question_embed_t, _, src_attn_list = self.bert(question_padded,
                                                 attention_mask=q_mask_cls)

    output, tgt_attn_list, tgt_src_attn_list = self.q_decoder(
            tgt=obj_feature_bbox_cls.permute(1, 0, 2),
                       memory=question_embed_t.permute(1, 0, 2),
                       memory_key_padding_mask=memory_key_padding_mask,
                       tgt_key_padding_mask=tgt_key_padding_mask)

If I free the parameters of Bert, it gives better results. But when I fine tune the whole model, the model does not seem to learn. I've tried the Adam optimizer of pytorch and AdamW provided by this repository. Both of them does not work.
optimizer = pytorch_transformers.optimization.AdamW(model.parameters(), lr=3e-5)

The orange curve shows the model with Bert parameters freezed, while the pink and skyblue curve shows the model that trains Bert parameters.
Are there any potential issues I am missing?

It turned out the learning rate was too high (1e-4) using 3e-5 showed good results.


Week 1, Day 3, Tutorial 1, Equation incorrect

The equation for the optimal theta_hat
\begin{align}
\hat\theta = \sum_{i=1}^N \frac{x_i y_i}{x_i^2}
\end{align}
seems to be incorrect? Shouldn't it be:
\begin{align}
\hat\theta =  \frac{\sum_{i=1}^N x_i y_i}{\sum_{i=1}^N x_i^2}
\end{align}
Best,
Jan

Same problem in "Finding the Maximum Likelihood Estimator" section of Week 1, Day 3, Tutorial 2.

thank you for catching this bad typo

I still see this typo in the instructor notebook of W1D3- Tutorial 1.