Not working on React Native

After upgrading @octokit/rest from 16.22.0 to 16.43.1 support for react native was broken. The issue seems to come from universal-user-agent that is using some node-specific packages.
First error
Unable to resolve module os from "node_modules/os-name/index.js"
Cause: https://github.com/gr2m/universal-user-agent/blob/d671405f5c3fc9922a7f61468d8ec694866825a4/src/node.ts#L1
Second error
TypeError: undefined is not an object (evaluating 'process.version.substr')
Cause: https://github.com/gr2m/universal-user-agent/blob/d671405f5c3fc9922a7f61468d8ec694866825a4/src/node.ts#L5
If you make the react-native target be the same as web it will not crash but navigator.userAgent is undefined. You can get the Platform.OS from react-native.

I'm pretty sure it is caused by the same issue as discussed in. https://github.com/gr2m/universal-user-agent/issues/23
Did you find a workaround as reference for other React Native users?
Note that I do not test the Octokit Libraries with React Native at this point. But I will look into it together with other targets such as Electron and Deno, once conditional exports are supported by Pika

I'm pretty sure it is caused by the same issue as discussed in. #23

Yeah maybe. React Native is picking the node target.

Did you find a workaround as reference for other React Native users?

I patched os-name using patch-package. I created the file node_modules/os-name/index.native.js. I also set the value of process.version to my app's version.
patches/os-name+3.1.0.patch
diff --git a/node_modules/os-name/index.native.js b/node_modules/os-name/index.native.js
new file mode 100644
index 0000000..da50ffc
--- /dev/null
+++ b/node_modules/os-name/index.native.js
@@ -0,0 +1,9 @@
+'use strict';
+
+const { Platform } = require('react-native');
+
+const osName = (platform, release) => {
+	return Platform.OS;
+};
+
+module.exports = osName;

index.js
if (!process.version) {
  process.version = require('@myapp/src/utils/constants').APP_VERSION
}

if (!process.version) {
  process.version = require('./package.json').version || ''
}

process.version is the Node version, not the package version.
I think maybe you can patch the whole package to return a single function which would just return ReactNative/1.2.3 where 1.2.3 would be the version of the current React Native at build time?

since I have a monorepo sharing code between web, mobile and server I decided to patch in a way that wouldn't affect the other platforms.
my first attempt was to create universal-user-agent/dist-node/index.native.js but for some reason it keeps using the normal index.js instead.
but yeah it's probably better to just patch universal-user-agent directly, I would just need to keep it working for the other platforms as well

Thanks for sharing Bruno, I'll leave the issue open for others who run into the same problem

for some reason it keeps using the normal index.js instead of index.native.js

Note: Changing the universal-user-agent/package.json from "main": "dist-node/index.js" to "main": "dist-node/" fixes this (but patch-package can't package package.json).

I'll add a try/catch around the navigator.userAgent, so at least it should no longer throw an error, via https://github.com/gr2m/universal-user-agent/pull/41
Once conditional exports are supported by @pika/pack, I can provide custom exports for different environments, so the resulting user agent will be more helpful than <navigator unknown>, but at least this should unblock people for the time being
Any thoughts?

navigator is available in react native.
The problem is process.version.substr and require('os').
A possible solution is the one from the comment above (change the package.json main entry point to the folder instead file, and create index.native.js)

Ah I see, I'll add a try/catch to /src/node.ts, too, until we have proper support for conditional exports. Thanks Bruno!

I've decided to greatly simplify this package to workaround the build problems y'all are experiencing. I was hoping for conditional exports to be adopted more quickly, but it does not look like it.
For React Native, I wonder if there would be a way to get a user agent such as "ReactNative/1.2.3" without importing external dependencies. Any idea?
See https://github.com/gr2m/universal-user-agent/issues/52


Using px.density_contour with both marginal_x and contours_coloring causes error

I get the error below when trying to add marginal_x to the "continuously-colored and labeled" example on this page https://plotly.com/python/2d-histogram-contour/
import plotly.express as px

df = px.data.tips()

fig = px.density_contour(df, x="total_bill", y="tip", marginal_x='box')
fig.update_traces(contours_coloring="fill", contours_showlabels=True)

"C:\Program Files\Python38\python.exe" D:/_MyFiles/Programming/scratch/scratch.py
Traceback (most recent call last):
  File "D:/_MyFiles/Programming/scratch/scratch.py", line 6, in <module>
    fig.update_traces(contours_coloring="fill", contours_showlabels=True)
  File "C:\Program Files\Python38\lib\site-packages\plotly\basedatatypes.py", line 1376, in update_traces
    trace.update(patch, overwrite=overwrite, **kwargs)
  File "C:\Program Files\Python38\lib\site-packages\plotly\basedatatypes.py", line 5067, in update
    BaseFigure._perform_update(self, kwargs, overwrite=overwrite)
  File "C:\Program Files\Python38\lib\site-packages\plotly\basedatatypes.py", line 3862, in _perform_update
    raise err
ValueError: Invalid property specified for object of type plotly.graph_objs.Box: 'contours'

...

Bad property path:
contours_coloring
^^^^^^^^

@adamerose did you ever find a solution or workaround for this?

@john-verran Nope haven't revisited this since I first made the issue, it's a pretty specific graph and I haven't personally had the need to find a workaround.
But in general when I run into a roadblock with plotly express for something important the workaround is to rebuild it from scratch using the base Plotly API, it's never failed me before but takes more effort. I would start here https://plotly.com/python/contour-plots/ and then add the histograms with shared axes like this https://plotly.com/python/subplots/#subplots-with-shared-xaxes


Is the M2 server down?

Hi there, I just tried to restart M2 on the Macaulay2Web interface, and I got this error
Macaulay2, version 1.21
/usr/share/Macaulay2/Core/option.m2:13:0:(1): error: missing semicolon or comma on previous line?
../pzinn/M2/M2/Macaulay2/m2/startup.m2.in:66:23:(0): error: --backtrace: parse error--
I am pretty sure this might be an error of the interface, but reporting in just in case.

thanks for reporting! my guess is this is what happened:
recently, I changed a setting so users can change the code of Macaulay2 itself. I had not realized a side effect would be that users could potentially break Macaulay2 by introducing bugs in there. This has become particularly easy now that error messages contain links to the source code. I might revert this change next update, I need to think about it.
In the meantime can you please do the following:
go to the CHAT window and type /kill -- this should reboot your Macaulay2 container. After that press Reset and see if things are back to normal. Let me know!

This worked!


Params with default values [feature request?]

Hi folks, consider the following example:
resource :companies do
  params do
    requires :name, allow_blank: false
  end
  post do
    # where `current_user` is the signed in user
    Company.create(declared(params).merge!(seller_id: current_user.id))
  end
end

Wouldn't be nice if we could write something like:
resource :companies do
  params do
    requires :name, allow_blank: false
    # `default` is an example, maybe another name makes more sense
    default :seller_id, default_value: ->() { current_user.id }
  end
  post do
    Company.create(declared(params))
  end
end

It would help keeping our code DRY.
What do you think? Is there some way to do something similar it today?
Note after opening this issue:
I just discover it works:
resource :companies do
  params do
    requires :name, allow_blank: false
    optional :seller_id, default: 1
  end
  post do
    Company.create(declared(params))
  end
end

declared(params) contains seller_id with the proper value 1.
but all these dont work:
optional :seller_id, default: @current_user.id
optional :seller_id, default: ->() { @current_user.id }
module ApiHelpers
  extend Grape::API::Helpers

  def current_user
    @current_user
  end
end

helpers ApiHelpers
...
optional :seller_id, default: current_user.id
# neither
optional :seller_id, default: ->() { current_user.id }
...

Does it not work because current_user is not defined in that scope? The lambda itself should be called on every request.

The @current_user is set inside a helper method, like:
extend Grape::API::Helpers

def authenticate
  authentication = Auth.new headers["Token"]
  if authentication.valid?
    @current_user = authentication.user
  else
    error! "Not authorized", 401
  end
end

Let me backup. The documentation says that this should work as you describe. So why doesn't it work? I mean you say "these don't work", but how do they not work? Do you get an error? Do the lambda methods not get called?

optional :seller_id, default: ->() { @current_user.id } raises the following error: undefined method "id" for nil:NilClass

@glaucocustodio You're incorrectly assuming that the scope of @ variables inside that function is the same as in helpers. I don't believe that's true. You should dig deeper - are helper methods available? If they are, what scope to they execute in? Most applications pass shared context like this through ENV to avoid any thread-safety issues and such.

Helpers method aren't available inside lambda. I think it would be nice if we could set default values using helpers or instance variables.

I agree, would love a PR.


sensu installation fails due to rabbitmq cookbook

Recipe: sensu::rabbitmq
* group[rabbitmq] action create
- create group rabbitmq
* directory[/etc/rabbitmq/ssl] action create
- create new directory /etc/rabbitmq/ssl
- change mode from '' to '0755'
* file[/etc/rabbitmq/ssl/cacert.pem] action create
- create new file /etc/rabbitmq/ssl/cacert.pem
- update content in file /etc/rabbitmq/ssl/cacert.pem from none to 704c98
- suppressed sensitive resource
- change mode from '' to '0640'
- change group from '' to 'rabbitmq'
* file[/etc/rabbitmq/ssl/cert.pem] action create
- create new file /etc/rabbitmq/ssl/cert.pem
- update content in file /etc/rabbitmq/ssl/cert.pem from none to 3d6db7
- suppressed sensitive resource
- change mode from '' to '0640'
- change group from '' to 'rabbitmq'
* file[/etc/rabbitmq/ssl/key.pem] action create
- create new file /etc/rabbitmq/ssl/key.pem
- update content in file /etc/rabbitmq/ssl/key.pem from none to c79a15
- suppressed sensitive resource
- change mode from '' to '0640'
- change group from '' to 'rabbitmq'
* directory[/etc/rabbitmq/ssl/client] action create
- create new directory /etc/rabbitmq/ssl/client
- change mode from '' to '0755'
* file[/etc/rabbitmq/ssl/client/cert.pem] action create
- create new file /etc/rabbitmq/ssl/client/cert.pem
- update content in file /etc/rabbitmq/ssl/client/cert.pem from none to 4092c4
- suppressed sensitive resource
- change mode from '' to '0640'
- change group from '' to 'rabbitmq'
* file[/etc/rabbitmq/ssl/client/key.pem] action create
- create new file /etc/rabbitmq/ssl/client/key.pem
- update content in file /etc/rabbitmq/ssl/client/key.pem from none to 53aa46
- suppressed sensitive resource
- change mode from '' to '0640'
- change group from '' to 'rabbitmq'
Recipe: rabbitmq::default
* directory[/var/lib/rabbitmq/mnesia] action create
* cannot determine user id for 'rabbitmq', does the user exist on this system?
================================================================================
Error executing action create on resource 'directory[/var/lib/rabbitmq/mnesia]'
================================================================================
       Chef::Exceptions::UserIDNotFound
       --------------------------------
       cannot determine user id for 'rabbitmq', does the user exist on this system?

       Resource Declaration:
       ---------------------
       # In /tmp/kitchen/cache/cookbooks/rabbitmq/recipes/default.rb

       206: directory node['rabbitmq']['mnesiadir'] do
       207:   owner 'rabbitmq'
       208:   group 'rabbitmq'
       209:   mode '775'
       210:   recursive true
       211: end
       212:

       Compiled Resource:
       ------------------
       # Declared in /tmp/kitchen/cache/cookbooks/rabbitmq/recipes/default.rb:206:in `from_file'

       directory("/var/lib/rabbitmq/mnesia") do
         action [:create]
         default_guard_interpreter :default
         path "/var/lib/rabbitmq/mnesia"
         recursive true
         declared_type :directory
         cookbook_name "rabbitmq"
         recipe_name "default"
         owner "rabbitmq"
         group "rabbitmq"
         mode "775"
       end

       System Info:
       ------------
       chef_version=13.6.0
       platform=amazon
       platform_version=2017.09
       ruby=ruby 2.4.2p198 (2017-09-14 revision 59899) [x86_64-linux]
       program_name=chef-client worker: ppid=2938;start=05:36:48;
       executable=/opt/chef/bin/chef-client

   Recipe: sensu::default
     * ruby_block[sensu_service_trigger] action create
       - execute the ruby block sensu_service_trigger

   Running handlers:
   [2017-10-31T05:37:05+00:00] ERROR: Running exception handlers
   [2017-10-31T05:37:05+00:00] ERROR: Running exception handlers
   Running handlers complete
   [2017-10-31T05:37:05+00:00] ERROR: Exception handlers complete
   [2017-10-31T05:37:05+00:00] ERROR: Exception handlers complete
   Chef Client failed. 28 resources updated in 16 seconds
   [2017-10-31T05:37:05+00:00] FATAL: Stacktrace dumped to /tmp/kitchen/cache/chef-stacktrace.out
   [2017-10-31T05:37:05+00:00] FATAL: Stacktrace dumped to /tmp/kitchen/cache/chef-stacktrace.out
   [2017-10-31T05:37:05+00:00] FATAL: Please provide the contents of the stacktrace.out file if you file a bug report
   [2017-10-31T05:37:05+00:00] FATAL: Please provide the contents of the stacktrace.out file if you file a bug report
   [2017-10-31T05:37:05+00:00] ERROR: directory[/var/lib/rabbitmq/mnesia] (rabbitmq::default line 206) had an error: Chef::Exceptions::UserIDNotFound: cannot determine user id for 'rabbitmq', does the user exist on this system?
   [2017-10-31T05:37:05+00:00] ERROR: directory[/var/lib/rabbitmq/mnesia] (rabbitmq::default line 206) had an error: Chef::Exceptions::UserIDNotFound: cannot determine user id for 'rabbitmq', does the user exist on this system?
   [2017-10-31T05:37:05+00:00] FATAL: Chef::Exceptions::ChildConvergeError: Chef run process exited unsuccessfully (exit code 1)
   [2017-10-31T05:37:05+00:00] FATAL: Chef::Exceptions::ChildConvergeError: Chef run process exited unsuccessfully (exit code 1)

Do we need to pass the user explicitly from our recipe ? Why this is required?

I am having a amazon machine which is equivalent to RHEL/Centos 6. In my own cookbook I have made the dependency of sensu cookbook for server and rabbitmq recipe. But then also it not compiling. Why we should explicitly pass any value or change any thing for user.
If I add user explicitly as user "rabbitmq" from my cookbook, then its throws
Recipe: sensu::rabbitmq
* service[restart rabbitmq-server] action restart
* service[restart rabbitmq-server]: No custom command for restart specified and unable to locate the init.d script!
================================================================================
Error executing action restart on resource 'service[restart rabbitmq-server]'
================================================================================
       Chef::Exceptions::Service
       -------------------------
       service[restart rabbitmq-server]: No custom command for restart specified and unable to locate the init.d script!

       Resource Declaration:
       ---------------------
       # In /tmp/kitchen/cache/cookbooks/sensu/recipes/rabbitmq.rb

        85: service "restart #{node["rabbitmq"]["service_name"]}" do
        86:   service_name node["rabbitmq"]["service_name"]
        87:   action :nothing
        88:   subscribes :restart, resources("template[#{node['rabbitmq']['config_root']}/rabbitmq.config]"), :immediately
        89: end
        90:

       Compiled Resource:
       ------------------
       # Declared in /tmp/kitchen/cache/cookbooks/sensu/recipes/rabbitmq.rb:85:in `from_file'

       service("restart rabbitmq-server") do
         action [:nothing]
         default_guard_interpreter :default
         service_name "rabbitmq-server"
         enabled nil
         running nil
         masked nil
         pattern "restart rabbitmq-server"
         declared_type :service
         cookbook_name "sensu"
         recipe_name "rabbitmq"
       end

       System Info:
       ------------
       chef_version=13.6.0
       platform=amazon
       platform_version=2017.09
       ruby=ruby 2.4.2p198 (2017-09-14 revision 59899) [x86_64-linux]
       program_name=chef-client worker: ppid=2917;start=09:13:34;
       executable=/opt/chef/bin/chef-client

   Recipe: rabbitmq::default
     * service[rabbitmq-server] action restart
       * service[rabbitmq-server]: No custom command for restart specified and unable to locate the init.d script!
       ================================================================================
       Error executing action `restart` on resource 'service[rabbitmq-server]'
       ================================================================================

       Chef::Exceptions::Service
       -------------------------
       service[rabbitmq-server]: No custom command for restart specified and unable to locate the init.d script!

       Resource Declaration:
       ---------------------
       # In /tmp/kitchen/cache/cookbooks/rabbitmq/recipes/default.rb

       275:   service node['rabbitmq']['service_name'] do
       276:     retries node['rabbitmq']['retry']
       277:     retry_delay node['rabbitmq']['retry_delay']
       278:     action [:enable, :start]
       279:     supports :status => true, :restart => true
       280:     provider Chef::Provider::Service::Upstart if node['rabbitmq']['job_control'] == 'upstart'
       281:     provider Chef::Provider::Service::Init if node['rabbitmq']['job_control'] == 'init'
       282:   end
       283: else

       Compiled Resource:
       ------------------
       # Declared in /tmp/kitchen/cache/cookbooks/rabbitmq/recipes/default.rb:275:in `from_file'

       service("rabbitmq-server") do
         action [:enable, :start]
         default_guard_interpreter :default
         service_name "rabbitmq-server"
         enabled nil
         running nil
         masked nil
         pattern "rabbitmq-server"
         declared_type :service
         cookbook_name "rabbitmq"
         recipe_name "default"
         retries 0
         retry_delay 2
         supports {:status=>true, :restart=>true}
       end

       System Info:
       ------------
       chef_version=13.6.0
       platform=amazon
       platform_version=2017.09
       ruby=ruby 2.4.2p198 (2017-09-14 revision 59899) [x86_64-linux]
       program_name=chef-client worker: ppid=2917;start=09:13:34;
       executable=/opt/chef/bin/chef-client

   Running handlers:
   [2017-10-31T09:13:41+00:00] ERROR: Running exception handlers
   [2017-10-31T09:13:41+00:00] ERROR: Running exception handlers
   Running handlers complete
   [2017-10-31T09:13:41+00:00] ERROR: Exception handlers complete
   [2017-10-31T09:13:41+00:00] ERROR: Exception handlers complete
   Chef Client failed. 11 resources updated in 06 seconds
   [2017-10-31T09:13:41+00:00] FATAL: Stacktrace dumped to /tmp/kitchen/cache/chef-stacktrace.out
   [2017-10-31T09:13:41+00:00] FATAL: Stacktrace dumped to /tmp/kitchen/cache/chef-stacktrace.out
   [2017-10-31T09:13:41+00:00] FATAL: Please provide the contents of the stacktrace.out file if you file a bug report
   [2017-10-31T09:13:41+00:00] FATAL: Please provide the contents of the stacktrace.out file if you file a bug report
   [2017-10-31T09:13:41+00:00] ERROR: Chef::Exceptions::MultipleFailures
   [2017-10-31T09:13:41+00:00] ERROR: Chef::Exceptions::MultipleFailures
   [2017-10-31T09:13:41+00:00] FATAL: Chef::Exceptions::ChildConvergeError: Chef run process exited unsuccessfully (exit code 1)
   [2017-10-31T09:13:41+00:00] FATAL: Chef::Exceptions::ChildConvergeError: Chef run process exited unsuccessfully (exit code 1)

------Exception-------
Class: Kitchen::ActionFailed
Message: 1 actions failed.
Converge failed on instance .  Please see .kitchen/logs/sensu-server-amazon.log for more details
Please see .kitchen/logs/kitchen.log for more details
Also try running kitchen diagnose --all for configuration

Through chef its really becoming difficult.

Amazon is a different distribution than RHEL-family. They have diverged enough that ohai, which provides Chef's platform detection, has amazon as a separate platform family than RHEL or Fedora.
Further, the rabbitmq cookbook does not list amazon as a specifically supported distribution meaning that testing is not done against it.
Sensu has a list of supported platforms in its cookbook metadata and you'll probably have more success using one of those platforms instead.

As Josh points out the cookbook does not officially support Amazon Linux or Amazon Linux 2. I am open to adding support if you can provide a contribution here and in the upstream rabbitmq cookbook.

Yes can you add support for Amazon Linux.
May I know what are the steps I need to do ?
Regards
Prakash
On Mon, Mar 26, 2018 at 12:29 AM, Ben Abrams<EMAIL_ADDRESS>wrote:

As Josh points out the cookbook does not officially support Amazon Linux
or Amazon Linux 2. I am open to adding support if you can provide a
contribution here and in the upstream rabbitmq cookbook.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
https://github.com/sensu/sensu-chef/issues/585#issuecomment-375994418,
or mute the thread
https://github.com/notifications/unsubscribe-auth/Acx7D9OsDFmFb2sP-5mQ71Tc4nClcCcNks5th-kOgaJpZM4QMPEb
.

May I know what are the steps I need to do ?

I don't run amazon linux so this is not currently a priority for me to do but essentially you need to figure out what is different from rhel families and amazon linux and add it in a case statement for the platform. For the sensu client, api, and server installer this would be here: https://github.com/sensu/sensu-chef/blob/v4.3.0/recipes/_linux.rb#L67-L91. For the rabbitmq cookbook changes it would need to happen either  here or more likely needs to be addressed upstream in the rabbitmq cookbook I would probably start by raising an issue with the rabbitmq cookbook as I'd be willing to bet it will be needed to update the upstream cookbook from my quick review.


[WIP] Add distribution support to spotify100 and the ability to fetch distribution from bigTable.

This PR add distribution support to spotify100 (jsonMetric) and the ability to fetch distribution metric from bigTable.
Spotify100 consumers and ingestion modules should now be able to handle new and old JsonMetric.
For more information please refer to this issue

Hey @ao2017 I think you changed Spotify100.java schema but this is old schema and not used atm. The main schema that is used now is Spotify100Proto.java

We already committed to doing http and protoBuf clients so let's move forward with the PR.
From what I know, ffwd-http and ffwd-json modules  send metric to Heroic in Spotify100 format.
There is no side effect in having distribution support in Spotify100.

@ao2017 Spotify100 schema is not used on Heroic side at all anymore. FFWD does support JSON but it internally converts that to spotify_100.proto when publishes it to PubSub. The changes you've added are never going to be used in Heroic and I don't see the reason to keep that code.

Sergey, Is this dead code ?https://github.com/spotify/ffwd/blob/b5c9837a06abab68e1322ae0848090403a345c9a/modules/http/src/main/java/com/spotify/ffwd/http/HttpClient.java#L59

@ao2017 this is not a dead code. This code would be used by locally configured FFWD agent to sent metrics via HTTP/JSON to metrics-api, which in itself a FFWD instance configured to get HTTP requests and convert them to spotify_100.proto to be published to PubSub. So that code won't send it directly to Heroic. Heroic consumers are the only instances responsible for consumption of spotify_100.proto schema which in itself never will use Spotify100.java code.

Got it, can you point me to the part where the conversion is done.
Anyway, If Spotify100 is not used at all then we should eventually do some clean up and re-write consumers integration tests. Consumers integration tests used spotify100.  For now, I say let's move forward with the PR because it is not just spotify100 consumer.

I gave you some pointers offline w.r.t. code location.
Don't you need to update Spotify100Proto.java to support distributions?
I'm all for cleaning the code at the same time as it is open source project we would need to go through deprecation routine which we probably should.

Spotify100Proto is done. Please let's move forward with the PR.

@ao2017 I responded to some comments

Got it @ao2017. I didn't realize the Spotify100Proto was already addressed in other PR. Thanks for clarifications.

@malish8632  NP,  we have been through this  with every PR I posted except one. May be reading the issue/task related to the PR or asking questions may help . Let's figure out how to make the process smoother next time.


First pass of custom converter

I'm not 100% sure about the null prohibition here. Thoughts welcome on that.
I'll write documentation in a follow-up PR - I expect there may be a bit of back and forth in this one.

Added a commit to address issues spotted in review - PTAL, and then we can discuss the null handling more.


fix(Radio): added cursor pointer above the radio component label

☝Added cursor pointer above the radio component label
🔗 Linked issue
Resolves #1331
❓ Type of change

[ ] 📖 Documentation (updates to the documentation or readme)
[ x ] 🐞 Bug fix (a non-breaking change that fixes an issue)
[ ] 👌 Enhancement (improving an existing functionality)
[ ] ✨ New feature (a non-breaking change that adds functionality)
[ ] 🧹 Chore (updates to the build process or auxiliary tools and libraries)
[ ] ⚠ Breaking change (fix or feature that would cause existing functionality to change)

📚 Description
added cursor pointer above the radio component label

[ ] I have linked an issue or discussion.
[ x ] I have updated the documentation accordingly.

Why would you want to add a pointer on labels by default? It's not standard. You can do it on your side through the app.config.ts already.

Why would you want to add a pointer on labels by default? It's not standard. You can do it on your side through the app.config.ts already.

I think this is correct since the label is also clickable

Not every clickable elements needs to have a pointer. It is usually meant for links.


fix a potential wrong length calculation after log messages were shrunk

Scope & Purpose
Fix a potentially wrong length calculation after log messages were shrunk.
Reproduction: compile with ASan and execute:
scripts/unittest server_parameters --test log-max --cluster true

ASan errors are gone with the fix in place.
New ASan run:
http://<IP_ADDRESS>:8080/job/arangodb-ANY-linux-asan/560/
This is a fix for a yet-unreleased feature, so intentionally no CHANGELOG entry added for it.

[x] :hankey: Bugfix (requires CHANGELOG entry)
[ ] :pizza: New feature (requires CHANGELOG entry, feature documentation and release notes)
[ ] :fire: Performance improvement
[ ] :hammer: Refactoring/simplification
[ ] :book: CHANGELOG entry made

Backports:

[x] No backports required

Testing & Verification

[x] The behavior in this PR was manually tested
[x] This change is already covered by existing tests, such as server_parameters.
[x] I ensured this code runs with ASan / TSan or other static verification tools

Link to Jenkins PR run:
http://<IP_ADDRESS>:8080/view/PR/job/arangodb-matrix-pr/14050/
http://<IP_ADDRESS>:8080/job/arangodb-ANY-linux-asan/560/

Tests blue

ASan blue.


Remove add , edit and delete client for employees

For Employee:

for owner and admin:

Checklist:

[ ] I have manually tested all workflows
[ ] I have performed a self-review of my own code
[ ] I have added automated tests for my code

@ajinkyaa Please remove add project button too if the user is an employee. Also, they shouldn't be able to redirect to the project details page after clicking on the project name.

@apoorv1316 Shruti is adding the remaining functionality for project on her PR. Please test with admin and owner role to ensure that nothing is broken with this PR. If it is working, please merge this PR.

@ajinkyaa Please remove add project button too if the user is an employee. Also, they shouldn't be able to redirect to the project details page after clicking on the project name.

@apoorv1316 Please read the description, the button is showing for Owners and admins only, the first screenshot is for employees.


(NO-OP) Spinner stick to sides of an element

I know this will not get merged in, but just wanted to throw it out there as something you may want to look into adding at some point (being able to pass left:left or left:right ).

After taking a look at this I think I am just going to make those changes in the jquery part of my code as we can stay upto date with the vanilla spin.js


fix docker-cli-to-kubectl.md

The index of docker-cli-to-kubectl.md first item has three dots.
All fourth layer Topics are modified to second layer.

/approve
@cewuandy I think the suggestions by @kbhawkey are reasonable. I'll leave it to the two of you to decide on the final text. Then I'll give this an LGTM.

/lgtm


Use JavaTestUtil for all tck

This PR replaces JavaTestRunner with JavaTestUtil as the tck automation wrapper.
Impact:

Faster Execution: Absence of JavaTestRunner wrapper means we are using on less JVM instance. The JVM running the actual tests via tck harness jar is not run as a sub-process spawned by the JVM running JavaTeatRunner, but executed directly from playlist. This reduces overall time taken to run JCK builds.

Easy maintenance: Having the ability to specify tck harness parameters directly in the playlist makes each tck playlist command line clearer, easier to maintain and update.

Enhanced debug-ability: Absence of JavaTestRunner wrapper means less redirection hence more debug-ability for failures.

Less overhead in running additional services: Since additional services like rmi registry, rmid, etc, will be launched directly, as opposed to via ProcessBuilder in JavaTestRunner, it should also contribute to overall improved performance of tck builds in Jenkins.

Related to backlog/issues/1013

Test with sanity group on OSX: Grinder_JCK/1311.

Was it tested at @smlambert 's end before merging?

Yes, I ran tests at the temurin-compliance server, thanks for checking @Mesbah-Alam - I should have added a note!


Deficient heal after "SWS/BR: Split selected items at stretch markers"

This was reported on the forum some time ago without conclusive response.
https://forum.cockos.com/showpost.php?p=2236384&postcount=2759
https://forum.cockos.com/showpost.php?p=2236675&postcount=2763
I haven't found the issue entry in the tracker and without being able to know on whose side the issue is I repeat the report.
What's not getting healed with the native action "Item: Heal splits in items" is the 1st stretch marker split to the right of the loop divider notch. Splits of any other type get healed regardless of the loop mode.
GIF animation:
https://stash.reaper.fm/38153/Deficient Heal after Split at Stretch Markers.gif
https://stash.reaper.fm/38155/Regular splits heal VS Stretch markers splits heal.gif
Thank you

As nofish observed on the forum (https://forum.cockos.com/showpost.php?p=2236428), this is not a SWS bug. It can be duplicated with the native split actions without SWS being installed. The bug is within REAPER's built-in split or heal feature.

I've done some more testing and confirm that it's REAPER's bug.


Compiler cannot remember that a 'final' field has been checked as not null

Compiler cannot remember that a 'final' field has been checked as not null. Operator '+' cannot be called on 'int?' because it is potentially null
It leads to a necessity to introduce fake intermediate variables everywhere to help the compiler.
Kotlin compiler is smarter in similar cases.
void main() {
  final a = A(4);
  if (a.nullable != null) {
    print (a.nullable + 1);
  }
}

class A {
  final int? nullable;

  A(this.nullable);
}

Dart 2.12.2
Windows

@vadlit, when you say 'compiler' do you see this during static analysis, or when trying to run the program?

Fields are not promoted because that would be unsound. This is explicitly called out in the documentation, see https://dart.dev/null-safety/understanding-null-safety#working-with-nullable-fields
Language team is discussing a number of approaches to this problem (see https://github.com/dart-lang/language/issues?q=is%3Aopen+is%3Aissue+label%3Afield-promotion), but right now you either need to use ! or load field into a local variable and compare that with null instead.

Please be more attentive. I'm talking about final fields only!
But you referred to any fields.
Final fields are guaranteed to be immutable, so there is no problem with "unsoundness". I believe it's a bug

@vadlit, please consider the following situation:
class A {
  final int? i = 42;
  void foo() {
    if (i != null) print((i as dynamic).isEven);
  }
}

class B extends A {
  bool makeItNull = true;
  int? get i {
    makeItNull ^= true;
    return makeItNull ? null : super.i;
  }
}

void main() {
  B().foo();
}

I'm using i as dynamic rather than i in order to allow the null reference error to occur (we'll get a compile-time error if we use i.isEven).

I'm talking about final fields only!

In Dart fields don't work the same way as in most other languages (including Kotlin). They behave more like properties, with implicit overridable getter (and setter).
final simply means that the field only declares a getter but no setter. You can't overwrite the value stored in the field. However you can override the getter itself to make it return whatever you want.
See @eernstg example above that demonstrates this.

It's awful language design then, as for me.
So now I understand why compiler can't help me here. Ok.

By the way, may be it would be nice to introduce a new keyword means 'final final' (overriding is prohibited). Something like 'sealed final'

We are considering a sealing mechanism (which could be applied to a class or an instance member). There are other ways to get the desired property as well (that is: establishing the guarantee that evaluation of a getter multiple times yields the same value each time), e.g., dart-lang/language#1518.

It's awful language design

The main rationale is that properties should encapsulate their implementation, such that clients do not depend on whether a given property x is stored or computed. The lack of encapsulation in this area in languages like Java causes those communities to recommend that you never have public fields, you must always write getters and setters if clients should be allowed to access a field. In Dart you get those getters and setters automatically and consistently.


pkg/bisect: improve success rate

Umbrella bug for collection of suboptimal bisection results and hopefully then figuring out ways how to improve it.

https://syzkaller.appspot.com/bug?extid=fdce8f2a8903f3ba0e6b
https://syzkaller.appspot.com/x/bisect.txt?x=16e68713200000
Bisected to wrong commit.
Root cause: unrelated bug that happen on all tests.
Bisection switches to an unrelated bug "INFO: trying to register non-static key in can_notifier" which seem to happen on all tests. This then leads to a completely random commit.

https://syzkaller.appspot.com/bug?extid=b92e4f1472a54e1c7dec
https://syzkaller.appspot.com/x/bisect.txt?x=1681996f200000
Same as 1.

https://syzkaller.appspot.com/bug?extid=fa11f9da42b46cea3b4a
https://syzkaller.appspot.com/x/bisect.txt?x=155bf5db200000
https://groups.google.com/d/msg/syzkaller-bugs/c6i429YYtqk/eSMAl3hDCQAJ
Bisected correctly, but the bug was fixed several months ago, syzbot wasn't aware.

https://syzkaller.appspot.com/bug?extid=1505c80c74256c6118a5
https://syzkaller.appspot.com/x/bisect.txt?x=13220283200000
A mix of problems: unrelated bug triggered by the same repro ("WARNING: ODEBUG bug in netdev_freemem"); lots of infrastructure failures ("failed to copy test binary to VM"; also the original failure seems to be flaky. All this contributed to pointing to a random commit.
Al Viro points out that the commit only touches comments, so we could mark the end result as suspicious.
Tetsuo points out that if lots (say, 7/8) tests failed with infra problems, then we should retry/skip or something. This zeroes the effect of having multiple independent tests.

https://syzkaller.appspot.com/bug?extid=65788f9af9d54844389e
https://syzkaller.appspot.com/x/bisect.txt?x=121f55db200000
Bisected to wrong commit.
Root cause: it seems that everything went well except for bug being too hard to trigger, so somewhere along the way bisection slightly diverged from the right course.

We could somehow estimate how hard it is to reproduce a bug and increase number of instances and/or testing time for hard to reproduce bugs. Also see #885.

https://groups.google.com/d/msg/syzkaller-bugs/38HP_pUXJ3s/cxDiQRvSDAAJ
2 potential improvements:

(simpler) noting in the bisection log things like disabled configs, cherry-picked fixes, etc.
(harder) try to figure out that the bug actually depends on the disabled config

https://syzkaller.appspot.com/bug?extid=5cd33f0e6abe2bb3e397
https://syzkaller.appspot.com/x/bisect.txt?x=15330437200000
and:
https://syzkaller.appspot.com/bug?extid=c4c4b2bb358bb936ad7e
https://syzkaller.appspot.com/x/bisect.txt?x=10c0298b200000
Crash is reproduced with very low probability (1/10) so bisection diverges.

https://groups.google.com/d/msg/syzkaller-bugs/zgIMBABdi-I/AnNztytDBQAJ
Thomas suggest to revert the guilty commit on top of the bisection start commit (or original crash commit?), and see if a crash still happens. If kernel still crashes, then the bisection result may be marked as "suspicious". But it's unclear what to do in this case.  If this is an infra failure, we need to understand why this happens and try to improve.
Eric also proposed an idea of confidence levels: don't mail results if we have high confidence that an unrelated bug has diverged the process; if we have high confidence that flakiness has diverged the process (or low confidence that it had not diverged the process?); if we bisected to a comment-only change or a merge or a change to another arch.

FTR, the analysis of 118 bisection results:
https://groups.google.com/d/msg/syzkaller/sR8aAXaWEF4/tTWYRgvmAwAJ
https://docs.google.com/spreadsheets/d/1WdBAN54-csaZpD3LgmTcIMR7NDFuQoOZZqPZ-CUqQgA

It sounds to me like a new general purpose tool is called for. Here's a sketch.
The tool is for running git bisect on hard-to-reproduce bugs. It requires fully scripted reproduction steps. It assumes that false negatives are possible (bug did not reproduce even though present) but that false positives are not. The script is given a git commit. (The git commit is provided to the script, rather than giving the script a working tree, so that the script can cache intermediate artifacts.) The script attempts to reproduce the bug at that commit, and generates one of a few outcomes: (1) bug did not reproduce, (2) bug did reproduce, (3) some other permanent failure occurred, such as a syntax error in the code at that commit, (4) some other possibly transient failure occurred, such as a timeout or some other flaky failure.
The runner script runs indefinitely, doing a kind of ratcheting bisection. The result of every run is accumulated into an overall set of stats.
 Do a regular bisection using enough runs that failures are likely (if not guaranteed). That gives you a decent starting place to investigate as a human while the tool continues to narrow the field.
Next, keep track of the first commit in which the bug ever reproduced. Select commits to test using an exponential distribution, such that you're more likely to select commits near your first known bad commit. Over time, you will either (a) move the first known bad commit closer or (b) gather a lot of evidence that that commit really was the first known bad commit.
Make a nice visualization of the number of runs and the outcome distribution of those runs available to the user for inspection and human intelligence. As a bonus, let the user nudge the tool while it runs by providing human annotations about known good/bad commits.
None of this is perfect. For example, the reproduction rate might vary over time due to other changes, and the failure rate might be so low and reproduction time be so high that this brute force approach takes too long to stabilize.
Nevertheless, this should provide a systematic (and generically useful) way to approach the problem, and shift effort from humans to CPUs.

Few notes to make things more interesting ;)

False positives are there and by far the most common source of problems.
The more you test, the higher chances of false positives.
Current bisection with 1 try per commit and optimal logN time can take days. If this takes significantly more than that, the results may not be useful.
Users won't be happy about lots of emails with partial/incorrect results.
Users may not be willing to interact with the system (esp in a way it understands).

Wow. Yeah, that's going to be hard. :)
(I still think the tool I describe might actually be useful in an easier problem domain like regular Go bugs. I currently use stress and manually manage the bisection. cc @mvdan who likes thinking about tools)

I am thinking about increasing number of independent tests per commit. It should help with false negatives and is like 1 line change. A more complex version would be to estimate how flaky the crash is (which we want to do for other reasons too), and then choose number of tests based on that.
I would expect that Go bugs should not have almost any of these problems. There are no tens of thousands of bugs at any point in time, no prolonged broken builds/boots (e.g. runtime bugs), most crashes manifest in the same way. Also doing more independent tests is much simpler (no need to boot unreliable VMs for each test). So I would expect that doing 50 tests per commit and normal scripted bisection should be good enough. There is long tail of corner cases that only humans can deal with anyway.

@josharian thanks for the ping - highly unlikely I'll have time to think about yet another tool this summer, though :)

FTR a case where reproduction rate seems to drop dramatically at some point:
https://syzkaller.appspot.com/bug?extid=f8bb48225fbdb35f81f5
https://syzkaller.appspot.com/bug?extid=14cb52733e7d8c5cc675
The fix says the bug was introduced 9 years ago:
https://patchwork.ozlabs.org/patch/1116484/
Both bisections are incorrect:
https://syzkaller.appspot.com/x/bisect.txt?x=130b1b66a00000
https://syzkaller.appspot.com/x/bisect.txt?x=16b35349a00000
In both cases the crash was reproduced with 90-100% probability for v5.1..v4.7, but then rate seems to drop to few percents at most.

FTR, mini-analysis of memory leak bisections:
https://groups.google.com/forum/#!topic/syzkaller/sR8aAXaWEF4
Short version: too many unrelated leaks and other bugs diverge bisection.


Doesn't handle required attributes on a new user

Required attributes should be passed in auth.completeNewPassword

Fixed by PR


Prohibit T.untyped as a value

Input
→ View on sorbet.run
# typed: true

T.let(T.any(Integer, String), Integer) # errors, as expected

T.let(T.untyped, Integer) # does not error, but should

Observed output
editor.rb:3: Argument does not have asserted type Integer https://srb.help/7007
     3 |T.let(T.any(Integer, String), Integer) # errors, as expected
        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  Got <Type: T.any(Integer, String)> originating from:
    editor.rb:3:
     3 |T.let(T.any(Integer, String), Integer) # errors, as expected
              ^^^^^^^^^^^^^^^^^^^^^^
Errors: 1

Expected behavior

editor.rb:3: Argument does not have asserted type Integer https://srb.help/7007
     3 |T.let(T.any(Integer, String), Integer) # errors, as expected
        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  Got <Type: T.any(Integer, String)> originating from:
    editor.rb:3:
     3 |T.let(T.any(Integer, String), Integer) # errors, as expected
              ^^^^^^^^^^^^^^^^^^^^^^

editor.rb:5: Argument does not have asserted type Integer https://srb.help/7007
     5 |T.let(T.untyped, Integer) # errors, as expected
        ^^^^^^^^^^^^^^^^^^^^^^^^^
  Got <Type: T.untyped> originating from:
    editor.rb:3:
     5 |T.let(T.untyped, Integer) # errors, as expected
              ^^^^^^^^^
Errors: 2

The motivation is that we should have a clearer separation between types and values.
At runtime, T.untyped will construct an instance of T::Types::Untyped, like all other type syntax.
If people want a shorthand for an untyped value, they can T.unsafe(nil).

This is very similar in implementation to #3426


Long Running Service will be supported ?

I Want to run my web server by recode, But It will be supported ?

Hey Hyvi! 👋
I'm not really sure what you mean.
Do you want to be able to have long running processes (i.e. not tied to any terminal) to deploy your app through Recode?
If so, you may also need a fixed public IP address and a way to open port for your instance to be reachable.
Is that right?

Thanks for your reply. Yes, i have static public ip and port,but how I run a long running process (such node server) through recode? Hope your reply

Re,
This feature is not yet implemented in Recode, so you need to find a workaround.
As an example, I've created a file named app.js that contains the following code:
const http = require('http');

const hostname = '<IP_ADDRESS>'; // You need to bind to '<IP_ADDRESS>' not 'localhost' or '<IP_ADDRESS>'
const port = 80;

const server = http.createServer((req, res) => {
  res.statusCode = 200;
  res.setHeader('Content-Type', 'text/plain');
  res.end('Hello World');
});

server.listen(port, hostname, () => {
  console.log(`Server running at http://${hostname}:${port}/`);
});

If you want to run this code as a long-running process, do the following:

First, open a new terminal using VSCode or SSH.

Optionally, if you need to bind to ports < 1024, run:

echo "net.ipv4.ip_unprivileged_port_start=0" | sudo tee /etc/sysctl.conf > /dev/null

and
sudo sysctl --system

Finally, run your app using the following command:

nohup node app.js &

And voilà!

thanks for your detail explanation.

Hey Hyvi!
Hope you're well.
I  built a fork of Recode with built-in ports management, long-running processes and HTTPS, that will probably better suits your needs.
If you want to give it a try, it's here: https://github.com/eleven-sh/cli


Dataset for Schistosoma mansoni motility and their true motility values

Hi，thanks for the nice work! I found some example data for running wrmXpress modules at https://zenodo.org/record/7116648, and ran some of them well. Could you please share the dataset for Schistosoma mansoni motility and their  true motility values too? And also share the true motility values for Motility (96-well plate, individual wells) - Brugia malayi microfilaria: 20210819-p01-NJW_753,
Motility (96-well plate, whole plate) - Brugia pahangi adults: 20220622-p02-KTR,
and Motility (24-well plate, whole plate) - Brugia pahangi adults: 20220527-p02-KTR? Thank you very much!

Could you please explain how the true motility values are obtained?

Hi @lphilomena 👋🏻
Let me find some S. mansoni motility videos and get back to you. At the time of publication they were too large for Zenodo (or my Wifi wasn't good enough - the upload failed every time I tried it), but I'm sure I can find another way to share them.
What exactly do you mean by "true motility values?" The motility is provided in the output CSV, either in raw form (without metadata joined) or tidy form (with metadata joined).

Hi @wheelern,
Thanks very much for your reply! Thanks for sharing S. mansoni motility videos.
In the S2 Fig. ((https://journals.plos.org/plosntds/article/file?type=supplementary&id=10.1371/journal.pntd.0010937.s003)Correlations between diagnostic “flow clouds” and motility measurements.), the third row denotes flow clouds and the fourth row denotes motility measurements. Could you show me how the motility values in the subimage in the fourth row are obtained? "true motility values" I mean there should be a ground truth motility value of S. mansoni video which can represent the real motility of the S. mansoni in that video.
I ran wrmXpress successfully with the example data "20210917-p15-NJW_913" and "20220527-p02-KTR", and got output CSV including "worm_area" and "optical_flow". There is no motility in the output CSV. Do you get the motility by dividing "optical_flow" with "worm_area" ?

Optical flow is what we use as the measure of motility. In some cases, like when there are multiple worms per well, we will divide optical flow by the worm area; this normalizes the gross motility to the number of worms in the video.
I am still working on getting adult S. mansoni videos. Will keep you updated.

@lphilomena - here is a link to a shared folder that includes an AVI of a video of a 96-well plate with S. mansoni adults and a YAML to use for running wrmXpress. Note that this is one video with multiple wells, so wrmXpress will split each well into its own video an analyze it.

Hi，Dr. Wheeler，
Thank you very much for sharing the S.mansoni video data. I tried the data
with the YAML file. The result seems not as supposed. I will run it again.
It's very kind of you to reply.
Best regards
Liu Ping
Nic Wheeler @.***> 于2023年10月7日周六 02:25写道：

@lphilomena https://github.com/lphilomena - here
https://universityofwieauclaire-my.sharepoint.com/:u:/g/personal/wheelenj_uwec_edu/EVhuE8XN_6xDuCcc8WQ5TXUBa2MKt2FB82fkyxmv7Q7osg?e=0GFJFk
is a link to a shared folder that includes an AVI of a video of a 96-well
plate with S. mansoni adults and a YAML to use for running wrmXpress.
Note that this is one video with multiple wells, so wrmXpress will split
each well into its own video an analyze it.
—
Reply to this email directly, view it on GitHub
https://github.com/zamanianlab/wrmXpress/issues/17#issuecomment-1751225175,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AFUX3FHAQE52E36DYHSXXWLX6BEKDAVCNFSM6AAAAAA5G5GNYWVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTONJRGIZDKMJXGU
.
You are receiving this because you were mentioned.Message ID:
@.***>

--
Best Regards!
Liu Ping


fix: revert use HTTPS on $schema urls to avoid mixed content

Reverts asyncapi/spec-json-schemas#115
Tools like ajv (schema validator) are not compatible with https. See https://github.com/ajv-validator/ajv/issues/1104.
Also from a point of view of JSON Schema, this note about Schema ID's is very important:

Even though schemas are identified by URIs, those identifiers are not necessarily network-addressable. They are just identifiers. Generally, implementations don’t make HTTP requests (https://) or read from the file system (file://) to fetch schemas. Instead, they provide a way to load schemas into an internal schema database. When a schema is referenced by it’s URI identifier, the schema is retrieved from the internal schema database.

Meaning it should not matter what protocol the URI has because It should not be treated as network address. However, it seems the Monaco yaml plugin used in Studio fills a request to the schema when the schema is not loaded from start (when it is not provided from the studio).
@magicmatatjahu is working on the fix.

PR on Studio https://github.com/asyncapi/studio/pull/159


Actions

Applied mkpr on .github/workflows/update_package_lock.yml
cat .github/workflows/update_package_lock.yml

Pull Request Test Coverage Report for Build<PHONE_NUMBER>1
Details

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

Totals

Change from base Build<PHONE_NUMBER>7:
0.0%

Covered Lines:
392

Relevant Lines:
411

💛  - Coveralls


[BREAKING CHANGE] Extend Indexer PRC SearchKey for CKB 0.114

Updates:

Extended the enumeration values for Partial in SearchMode
Extended the output_data and output_data_filter_mode fields for the SearchKeyFilter

BREAKING CHANGE: rename ScriptSearchMode -> SearchMode

Extended the enumeration values for Partial in SearchMode
Is this feature specific to version v0.114.0? The latest version of ckb in ckb-sdk-rust's Cargo.toml is v0.111.0.

Extended the enumeration values for Partial in SearchMode

Is this feature specific to version v0.114.0? The latest version of ckb in ckb-sdk-rust's Cargo.toml is v0.111.0.

Yes, this feature is for v0.114.
If the Rust SDK directly upgrades the CKB version to 0.114, it should be fine.


Problem with connecting to Home Assistant cloud

Home Assistant release with the issue:

0.77.3
Last working Home Assistant release (if known):
???
Operating environment (Hass.io/Docker/Windows/etc.):

RPi 3B with Hassbian
Component/platform:

cloud
Description of problem:
After entering cright credentials in Configuration>Home Assistant Cloud, I get an "Unknown error" red message right above "Email" line instead of logging in.
Problem-relevant configuration.yaml entries and (fill out even if it seems unimportant):
cloud:

Traceback (if applicable):
Thu Sep 06 2018 23:50:01 GMT+0200 (Central European Summer Time)

Error handling request
Traceback (most recent call last):
  File "/srv/homeassistant/lib/python3.5/site-packages/aiohttp/web_protocol.py", line 390, in start
    resp = await self._request_handler(request)
  File "/srv/homeassistant/lib/python3.5/site-packages/aiohttp/web_app.py", line 352, in _handle
    resp = await handler(request)
  File "/srv/homeassistant/lib/python3.5/site-packages/aiohttp/web_middlewares.py", line 106, in impl
    return await handler(request)
  File "/srv/homeassistant/lib/python3.5/site-packages/homeassistant/components/http/static.py", line 66, in staticresource_middleware
    return await handler(request)
  File "/srv/homeassistant/lib/python3.5/site-packages/homeassistant/components/http/real_ip.py", line 34, in real_ip_middleware
    return await handler(request)
  File "/srv/homeassistant/lib/python3.5/site-packages/homeassistant/components/http/ban.py", line 67, in ban_middleware
    return await handler(request)
  File "/srv/homeassistant/lib/python3.5/site-packages/homeassistant/components/http/auth.py", line 68, in auth_middleware
    return await handler(request)
  File "/srv/homeassistant/lib/python3.5/site-packages/homeassistant/components/http/real_ip.py", line 34, in real_ip_middleware
    return await handler(request)
  File "/srv/homeassistant/lib/python3.5/site-packages/homeassistant/components/http/ban.py", line 67, in ban_middleware
    return await handler(request)
  File "/srv/homeassistant/lib/python3.5/site-packages/homeassistant/components/http/auth.py", line 68, in auth_middleware
    return await handler(request)
  File "/srv/homeassistant/lib/python3.5/site-packages/homeassistant/components/http/view.py", line 113, in handle
    result = await result
  File "/srv/homeassistant/lib/python3.5/site-packages/homeassistant/components/cloud/http_api.py", line 45, in error_handler
    result = await handler(view, request, *args, **kwargs)
  File "/srv/homeassistant/lib/python3.5/site-packages/homeassistant/components/http/data_validator.py", line 47, in wrapper
    result = await method(view, request, *args, **kwargs)
  File "/srv/homeassistant/lib/python3.5/site-packages/homeassistant/components/cloud/http_api.py", line 102, in post
    data['password'])
  File "/usr/lib/python3.5/asyncio/futures.py", line 380, in __iter__
    yield self  # This tells Task to wait for completion.
  File "/usr/lib/python3.5/asyncio/tasks.py", line 304, in _wakeup
    future.result()
  File "/usr/lib/python3.5/asyncio/futures.py", line 293, in result
    raise self._exception
  File "/usr/lib/python3.5/concurrent/futures/thread.py", line 55, in run
    result = self.fn(*self.args, **self.kwargs)
  File "/srv/homeassistant/lib/python3.5/site-packages/homeassistant/components/cloud/auth_api.py", line 91, in login
    cognito = _authenticate(cloud, email, password)
  File "/srv/homeassistant/lib/python3.5/site-packages/homeassistant/components/cloud/auth_api.py", line 126, in _authenticate
    cognito.authenticate(password=password)
  File "/srv/homeassistant/lib/python3.5/site-packages/warrant/__init__.py", line 383, in authenticate
    self.verify_token(tokens['AuthenticationResult']['IdToken'],'id_token','id')
  File "/srv/homeassistant/lib/python3.5/site-packages/warrant/__init__.py", line 197, in verify_token
    kid = jwt.get_unverified_header(token).get('kid')
AttributeError: module 'jose.jwt' has no attribute 'get_unverified_header'

Additional information:

There are more people with this issue:
https://community.home-assistant.io/t/help-components-cloud-auth-api-py-error/40435
https://community.home-assistant.io/t/issues-while-login-to-cloud/51556

Can you clear your config/deps folder? If that doesn't help, please list the integrations that you use, as one might install incorrect dependency

Please post the output of:
pip3 freeze | grep JWT pip3 freeze | grep jwt

(homeassistant) homeassistant@hassbian:~/.homeassistant $ pip3 freeze | grep JWT
PyJWT==1.6.4
(homeassistant) homeassistant@hassbian:~/.homeassistant $ pip3 freeze | grep jwt
(homeassistant) homeassistant@hassbian:~/.homeassistant $ pip3 freeze | grep jose
python-jose==0.5.6
python-jose-cryptodome==1.3.2

So far, I have tried this, but didnt help:
pip install -U pycrypto pycryptodome  pycryptodomex PyJWT
pip3 uninstall cryptography pycrypto pycryptodome pycryptodomex cffi
(yes to all)
python3 -m pip install --no-cache-dir cryptography
python3 -m pip install --no-cache-dir cffi
python3 -m pip install --no-cache-dir PyJWT
python3 -m pip install --upgrade homeassistant

pip3 freeze
aiohttp==3.4.0
aiohttp-cors==0.7.0
appdirs==1.4.3
asn1crypto==0.24.0
astral==1.6.1
async-timeout==3.0.0
attrs==18.1.0
bcrypt==3.1.4
beautifulsoup4==4.6.3
boto3==1.5.22
botocore==1.8.36
certifi==2018.8.24
cffi==1.11.5
chardet==3.0.4
colorlog==3.1.2
ConfigArgParse==0.11.0
crypto==1.4.1
cryptography==2.3.1
distro==1.3.0
docutils==0.14
ecdsa==0.13
enum-compat==0.0.2
envs==1.2.4
flake8==3.5.0
future==0.16.0
fuzzywuzzy==0.16.0
googlemaps==2.5.1
gTTS-token==1.1.1
hangups==0.4.5
holidays==0.9.6
home-assistant-frontend==20180903.0
homeassistant==0.77.3
http-ece==1.0.5
idna==2.6
idna-ssl==1.0.1
Jinja2==2.10
jmespath==0.9.3
MarkupSafe==1.0
mccabe==0.6.1
MechanicalSoup==0.6.0
multidict==4.1.0
mutagen==1.41.0
Naked==0.1.31
netdisco==2.0.0
netifaces==0.10.6
paho-mqtt==1.3.1
pkg-resources==0.0.0
protobuf==3.1.0.post1
py-vapid==1.4.0
PyChromecast==2.1.0
pycodestyle==2.3.1
pycparser==2.18
PyCRC==1.21
pycrypto==2.6.1
pycryptodome==3.6.6
pycryptodomex==3.6.6
pyelliptic==1.5.8
pyflakes==1.6.0
PyJWT==1.6.4
pyotp==2.2.6
PyQRCode==1.2.1
python-dateutil==2.7.2
python-jose==0.5.6
python-jose-cryptodome==1.3.2
pytz==2018.4
pyunifi==2.13
pywebpush==1.6.0
PyYAML==3.13
readlike==0.1.2
ReParser==1.4.3
requests==2.19.1
s3transfer==0.1.12
samsungctl==0.7.1
shellescape==3.4.1
six==1.11.0
SQLAlchemy==1.2.10
transmissionrpc==0.11
typing==3.6.4
ua-parser==0.7.3
urllib3==1.22
urwid==1.3.1
user-agents==1.1.0
voluptuous==0.11.5
voluptuous-serialize==2.0.0
wakeonlan==1.0.0
warrant==0.6.1
websocket-client==0.47.0
xmltodict==0.11.0
yarl==1.1.1
zeroconf==0.20.0

I triedbto login after uninstalling python-jose, but got same message with following error:
Log Details (ERROR)
Fri Sep 07 2018 20:33:44 GMT+0200 (Central European Summer Time)
Error handling request
Traceback (most recent call last):
File "/srv/homeassistant/lib/python3.5/site-packages/aiohttp/web_protocol.py", line 390, in start
resp = await self._request_handler(request)
File "/srv/homeassistant/lib/python3.5/site-packages/aiohttp/web_app.py", line 352, in _handle
resp = await handler(request)
File "/srv/homeassistant/lib/python3.5/site-packages/aiohttp/web_middlewares.py", line 106, in impl
return await handler(request)
File "/srv/homeassistant/lib/python3.5/site-packages/homeassistant/components/http/static.py", line 66, in staticresource_middleware
return await handler(request)
File "/srv/homeassistant/lib/python3.5/site-packages/homeassistant/components/http/real_ip.py", line 34, in real_ip_middleware
return await handler(request)
File "/srv/homeassistant/lib/python3.5/site-packages/homeassistant/components/http/ban.py", line 67, in ban_middleware
return await handler(request)
File "/srv/homeassistant/lib/python3.5/site-packages/homeassistant/components/http/auth.py", line 68, in auth_middleware
return await handler(request)
File "/srv/homeassistant/lib/python3.5/site-packages/homeassistant/components/http/real_ip.py", line 34, in real_ip_middleware
return await handler(request)
File "/srv/homeassistant/lib/python3.5/site-packages/homeassistant/components/http/ban.py", line 67, in ban_middleware
return await handler(request)
File "/srv/homeassistant/lib/python3.5/site-packages/homeassistant/components/http/auth.py", line 68, in auth_middleware
return await handler(request)
File "/srv/homeassistant/lib/python3.5/site-packages/homeassistant/components/http/view.py", line 113, in handle
result = await result
File "/srv/homeassistant/lib/python3.5/site-packages/homeassistant/components/cloud/http_api.py", line 45, in error_handler
result = await handler(view, request, *args, **kwargs)
File "/srv/homeassistant/lib/python3.5/site-packages/homeassistant/components/http/data_validator.py", line 47, in wrapper
result = await method(view, request, *args, **kwargs)
File "/srv/homeassistant/lib/python3.5/site-packages/homeassistant/components/cloud/http_api.py", line 102, in post
data['password'])
File "/usr/lib/python3.5/asyncio/futures.py", line 380, in iter
yield self  # This tells Task to wait for completion.
File "/usr/lib/python3.5/asyncio/tasks.py", line 304, in _wakeup
future.result()
File "/usr/lib/python3.5/asyncio/futures.py", line 293, in result
raise self._exception
File "/usr/lib/python3.5/concurrent/futures/thread.py", line 55, in run
result = self.fn(*self.args, **self.kwargs)
File "/srv/homeassistant/lib/python3.5/site-packages/homeassistant/components/cloud/auth_api.py", line 91, in login
cognito = _authenticate(cloud, email, password)
File "/srv/homeassistant/lib/python3.5/site-packages/homeassistant/components/cloud/auth_api.py", line 119, in _authenticate
from warrant.exceptions import ForceChangePasswordException
File "/srv/homeassistant/lib/python3.5/site-packages/warrant/init.py", line 8, in
from jose import jwt, JWTError
ImportError: cannot import name 'jwt'

Can you also python-jose-cryptodome ?

Unsure if related but without touching my config I now all of a sudden get below error message:
2018-09-07 21:09:27 WARNING (MainThread) [homeassistant.components.cloud.iot] Unable to connect: Cannot connect to host cloud.hass.io:8000 ssl:None [[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:833)]
2018-09-07 21:09:27 INFO (MainThread) [homeassistant.components.cloud.iot] Connection closed

Wow, after uninstalling of python-jose-cryptodome and warrant i get in Configuration>Home Assistant Cloud this screen:

But also few of these errors appeared:
Unable to connect: Cannot connect to host cloud.hass.io:8000 ssl:None [[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:720)]

Actually these errors are pretty often:
Unable to connect: Cannot connect to host cloud.hass.io:8000 ssl:None [[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:720)]
9:31 PM components/cloud/iot.py (WARNING)
Unable to connect: Cannot connect to host cloud.hass.io:8000 ssl:None [[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:720)]
9:27 PM components/cloud/iot.py (WARNING)
Unable to connect: Cannot connect to host cloud.hass.io:8000 ssl:None [[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:720)]
9:24 PM components/cloud/iot.py (WARNING)
Unable to connect: Cannot connect to host cloud.hass.io:8000 ssl:None [[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:720)]
9:23 PM components/cloud/iot.py (WARNING)
Unable to connect: Cannot connect to host cloud.hass.io:8000 ssl:None [[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:720)]
9:23 PM components/cloud/iot.py (WARNING)
Unable to connect: Cannot connect to host cloud.hass.io:8000 ssl:None [[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:720)]
9:22 PM components/cloud/iot.py (WARNING)
Unable to connect: Cannot connect to host cloud.hass.io:8000 ssl:None [[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:720)]
9:22 PM components/cloud/iot.py (WARNING)
Unable to connect: Cannot connect to host cloud.hass.io:8000 ssl:None [[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:720)]
9:22 PM components/cloud/iot.py (WARNING)
Unable to connect: Cannot connect to host cloud.hass.io:8000 ssl:None [[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:720)]
9:22 PM components/cloud/iot.py (WARNING)
Unable to connect: Cannot connect to host cloud.hass.io:8000 ssl:None [[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:720)]
9:18 PM components/cloud/iot.py (WARNING)
Unable to connect: Cannot connect to host cloud.hass.io:8000 ssl:None [[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:720)]
9:16 PM components/cloud/iot.py (WARNING)
Unable to connect: Cannot connect to host cloud.hass.io:8000 ssl:None [[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:720)]
9:15 PM components/cloud/iot.py (WARNING)
Unable to connect: Cannot connect to host cloud.hass.io:8000 ssl:None [[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:720)]
9:14 PM components/cloud/iot.py (WARNING)
Unable to connect: Cannot connect to host cloud.hass.io:8000 ssl:None [[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:720)]
9:14 PM components/cloud/iot.py (WARNING)
Unable to connect: Cannot connect to host cloud.hass.io:8000 ssl:None [[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:720)]
9:14 PM components/cloud/iot.py (WARNING)
Unable to connect: Cannot connect to host cloud.hass.io:8000 ssl:None [[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:720)]
9:14 PM components/cloud/iot.py (WARNING)
Unable to connect: Cannot connect to host cloud.hass.io:8000 ssl:None [[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:720)]

Time is correct

Time is correct on my end

My time is solid right at my end too

The cloud.hass.io certificate has expired and needs to be renewed.
I suppose someone broke the Let's Encrypt script :)

That explains a lot, I know this much more than I would like to :)
So lets just wait till admin will have a look at certbot

Ended up here for the same certificate failure, seems to be fixed now, Cloud access is working again.
Thanks

Can confirm from my end as well.

I can confirm this
Cloud connection status: Connected
Thank you for your help!


ReoGrid performance Recalculate

!!! Reproduce the bug is important !!!
test.xlsx
Describe the bug
I just load this file 'test.xlsx' and call sheet.Recalculate(), CPU is increased 30%,  and wait... wait...wait...
Expected behavior
can recalculate sheet
Screenshots

Edition
Which edition of ReoGrid do you using?

Windows Form

Environment (please complete the following information):

OS: [e.g. Windows 10]
Language of OS: English

You may want to try https://github.com/datadiode/ReoGrid.
The relevant commits are https://github.com/datadiode/ReoGrid/commit/e226e51 and https://github.com/datadiode/ReoGrid/commit/fa4e9be.

You may want to try https://github.com/datadiode/ReoGrid.
The relevant commits are https://github.com/datadiode/ReoGrid/commit/e226e51 and https://github.com/datadiode/ReoGrid/commit/fa4e9be.

Currently we are phasing issues related to performance which is similar kind. would like to know if is there any solution on this issue

Hi, when downloading the data diode branch files, the project to support winforms is loading, but for WPF it is not able to load. Any workarounds for the same? https://github.com/datadiode


Update Comparative Genomics summary widget and detail view

With the new target ETL pipeline and API response, we can partially remove our dependency on the Ensembl API as the homology data needed to generate the data table is now returned in our API homologues field:
query targetInfo {
  target(ensemblId: "ENSG00000146648") {
    id
    approvedSymbol
    homologues{
      homologyType
      queryPercentageIdentity
      speciesId
      speciesName
      targetGeneId
      targetGeneSymbol
      targetPercentageIdentity
    }
  }
}

Sample query: EGFR
Can we please adjust the summary widget and detail view to use the data returned by our API?
Summary widget
Currently, we call the Ensembl API and use the response to generate the label about the number of orthologues and species. Instead, can we please query our own API and use the target.homologues field data to create the widget content?
Detail view
Homology table

[x] Remove Ensembl API query and replace with query to our API target.homologues field

[x] Update the data table to use the following fields in the target.homologues response array:

Species
Homology type
Homologue
dN/dS
Query %id
Target %id

speciesName
homologyType
targetGeneSymbol
N/A
queryPercentageIdentity
targetPercentageIdentity

Zebrafish
ortholog - one2many
egfra
N/A
29.5868
57.28

Within the "Homology type" column, please parse and format the homologyType response, separating by underscore _.
Within the "Homologue" column, please link the targetGeneSymbol to Ensembl using identifiers.org - https://identifiers.org/ensembl: + targetGeneId.
Note that the "dN/dS" column is currently not queryable — please use "N/A" as a placeholder.

[x] Add "Show more rows" functionality to table

Gene tree

[x] Lazy-load the "Gene tree" tab, only running the Ensembl API query when a user clicks on the "Gene tree" tab

[ ] Please remove thedN/dS column. Ensembl does not provide this information anymore so it has been a legacy column for quite a while.

We are waiting for minor additions to the data and API, so there will be a couple more changes to do. Feel free to wait until they are available to implement this change.

When I next release the API there is going to be a new field called isHighConfidence. Previously we were filtering items which were low confidence (value of 0) in the ETL. You'll find many more records being returned now.

@mirandaio the changes are ready.
Current implementation:

The full list of changes requires is the next:

[ ] remove dN/dS column completely
[ ] update the summary widget text with "X orthologues and X paralogues". Next all homology types and what count they belong to:

>>> target.withColumn("homologues", F.explode("homologues")).select("approvedSymbol", "homologues.*").groupBy("homologyType").count().show(truncate = False)
+----------------------+-------+
|homologyType          |count  |
+----------------------+-------+
|within_species_paralog|44667  | --> paralogues
|gene_split            |7      | --> ignore
|ortholog_one2one      |159201 | --> orthologues
|other_paralog         |1737581| --> paralogues
|ortholog_one2many     |43048  | --> orthologues
|ortholog_many2many    |58696  | --> orthologues
+----------------------+-------+

[ ] in the Homology type column. We want to use the new field isHighConfidence to label the confidence of the orthology inference. The isHighConfidence response can have 3 different values 1, 0 or null. We want to add a star (like the one in ClinVar evidence) before the label (e.g. (star) ortholog one2one), so that all stars and labels align vertically. We can color in primaryColor if isHighConfidence == "1", color in grey if isHighConfidence == "0", and leave a white space when null.
[ ] In the Species column we want to add the species icon from speciesIcons package before the label so that icons and labels look aligned (e.g. (icon) Human). Either speciesId or speciesName can be used to get the mappings. Full lookup next:

+---------+-----------------------+-------+
|speciesId|speciesName            |count  | --> SpeciesIconsId
+---------+-----------------------+-------+
|9598     |Chimpanzee             |25511  | --> chimpanzee
|10116    |Rat                    |23448  | --> rat
|9606     |Human                  |1782255| --> human
|8364     |Tropical clawed frog   |18948  | --> frog
|9615     |Dog                    |21182  | --> dog
|7227     |Drosophila melanogaster|20022  | --> fly
|9986     |Rabbit                 |20216  | --> rabbit
|9544     |Macaque                |23271  | --> macaque
|9823     |Pig                    |20871  | --> pig
|6239     |Caenorhabditis elegans |24521  | --> worm
|7955     |Zebrafish              |22232  | --> zebrafish
|10141    |Guinea Pig             |20633  | --> guinea pig
|10090    |Mouse                  |20090  | --> mouse
+---------+-----------------------+-------+

** Correction: I mentioned the star on isHighConfidence == 0 to be grey. But in fact the alternative style in Clinvar evidence is not grey. Please use a consistent style.


Replace jzlib with maintained library

jzlib library seems to have been abandoned, so we should not compound the problem by using a fork.
IIRC @jtnord suggested dispensing with the org.kohsuke.stapler.compression package. I see it used in e.g. https://github.com/jenkinsci/jenkins/blob/bd7c823c2781d9282eab71a5e2967d386c629344/core/src/main/java/hudson/model/Api.java#L194-L195 and https://github.com/jenkinsci/jenkins/blob/f6378676b11288cc2525852b0a1a441d147e31d3/core/src/main/java/hudson/model/LargeText.java#L214-L219 but I think it is also used for general-purpose page rendering? We could use https://github.com/eclipse/jetty.project/tree/jetty-9.4.x/jetty-server/src/main/java/org/eclipse/jetty/server/handler/gzip instead. Or we could switch to another gzip library, or another encoding altogether. https://en.wikipedia.org/wiki/HTTP_compression#Content-Encoding_tokens suggests that we could use deflate with Java Platform calls alone, or Brotli with whatever library. Or we could just remove compression under the assumption that most clients are collocated with the Jenkins service on a fast network.
Originally posted by @jglick in https://github.com/stapler/stapler/issues/263#issuecomment-899771975

I don't think compression belongs in stapler or an app framework at all, if anything it is the job of the container. (Tomcat specifies this on the connector and jetty uses a handler)
I would suggest we remove it, and enable compression in winstone. (Any other users can configure their app server)
Less code FTW 🚀

remove it, and enable compression in winstone

Certainly sounds attractive in principle. It is longstanding tech debt. Open questions:

Does the transparent compression in Jetty also work when there are error pages, as the Stapler package attempts to deal with (IIUC)?
Are there any significant external references to the Stapler package? Can we deprecate all the classes in it and make them no-ops? https://github.com/jenkinsci/git-server-plugin/blob/8343aa2589d6f35705bc476c680814ec18eacb36/src/main/java/org/jenkinsci/plugins/gitserver/Jenkins2521Workaround.java#L9-L13 looks obsolete. https://github.com/jenkinsci/jenkins/blob/ec6987e7620f24cb79acc3992e8d1fa1c46ba761/core/src/main/java/hudson/init/impl/InstallUncaughtExceptionHandler.java#L35 and https://github.com/jenkinsci/jenkins/blob/0fd55bd6b50fcdf27368c6b771fb3d8363a24f83/war/src/main/webapp/WEB-INF/web.xml#L68-L72 would need to be fixed.
Can we just deprecate getCompressedOutputStream and getCompressedWriter, making them delegate to getOutputStream / getWriter resp., cleaning up usages in core & plugins at our leisure?

Does the transparent compression in Jetty also work when there are error pages, as the Stapler package attempts to deal with (IIUC)?

Can we deprecate all the classes in it and make them no-ops
Can we just deprecate..

Likely as you suggest , possibly we want to introduce a superclass to the compression filter that is a "ExceptionHandlerFilter" to catch errors so we can write diagnostic files, and then switch usage over to that from the ErrorHandler (again at our leisure)
At any case I do not think there is a too many stars we have to align if we wanted to bite the bullet.
If there is a more "modern" way to have an error handler for a webapp, possibly - we just need to have an <error-page> and use a servlet that can then pull information out of the Throwable and store it locally, as well as publish a (nicer?) page.

possibly we want to introduce a superclass to the compression filter that is a "ExceptionHandlerFilter"

My hope is that GzipHandler operates at a more basic level than filters, so we do not need to deal with interactions between compression and errors—the source of a lot of complexity in the current code.

If there is a more "modern" way to have an error handler for a webapp

Likely there is.


usage problem

this is my traffic2badge.yml
when run this action, it throws an error as follow, link

what's the problem, please help.

Oh, I found that you just use the example that .github/workflows/traffic2badge.yaml from traffic-to-badge. This example will test the main branch of traffic-to-badge repo. So in that I use the follow code:
      - name: Get Traffic
        id: traffic
        uses: ./
        with:
          my_token: ${{ secrets.TRAFFIC_TOKEN }}
          #(default) static_list: ${{ github.repository }}
          #(default) traffic_branch: traffic
          #(default) views_color: brightgreen
          #(default) clones_color: brightgreen
          #(default) logo: github

For your personal usage, just follow the README suggestion:
      - name: Get Traffic
        id: traffic
        uses<EMAIL_ADDRESS>        with:
          my_token: ${{ secrets.TRAFFIC_TOKEN }}
          #(default) static_list: ${{ github.repository }}
          #(default) traffic_branch: traffic
          #(default) views_color: brightgreen
          #(default) clones_color: brightgreen
          #(default) logo: github

And if you want to make badges for more repos, I advise for using the template repo.

emm, I modify with workflow file
name: traffic2badge
on:
  push:
    branches:
      - master
  schedule:
    - cron: '1 0 * * *' #UTC

jobs:
  run:
    name: Make GitHub Traffic to Badge
    runs-on: ubuntu-latest
    steps:
      - name: Checkout Code
        uses<EMAIL_ADDRESS>
      - name: Get Traffic
        id: traffic
        uses<EMAIL_ADDRESS>        with:
          my_token: ${{ secrets.TRAFFIC_TOKEN }}
          #(default) static_list: ${{ github.repository }}
          #(default) traffic_branch: traffic
          #(default) views_color: brightgreen
          #(default) clones_color: brightgreen
          #(default) logo: github

      - name: Show Traffic Data
        run: |
          echo ${{ steps.traffic.outputs.traffic_branch }}
          echo ${{ steps.traffic.outputs.traffic_path }}
          cd ${{ steps.traffic.outputs.traffic_path }}
          ls -a

it throw another error there
Init traffic data into .traffic fail!

@MuYunyun
Thanks for the test! I refactored the code, and there was no test for new repository establishing. Now it has been fixed, just upgrade the version to v1.1.5. 😀

:smile: I use it a little later.

@MuYunyun  I find that you just use the action for generate data, maybe you need to add a step for deploying data to your branch.
The deployment step used in this guide. For the action README, I may need to add a guide for deployment.

@MuYunyun I update the readme for the deployment. See Example usage.

@MuYunyun I update the readme for the deployment. See Example usage.

Thanks very much, I run success. This project is awesome.👍


Add bounding box test programs

I ran the application to generate a table, and it took significantly longer to complete on this pull request than on main. The reason is that the model and label binarizer are loaded every time the get_letters function is run. This is not necessary since they are loaded in the get_predictions_function. Could you remove self.__LB = self.file_manager_operative.load_LabelBinarizer() and self.__model = self.file_manager_operative.load_ocr_model() from predict.py?

For testing, the model and labelbinarizer should probably be loaded within the testing files rather than relying on get_letters to load them. Maybe, a separate, duplicate function of get_letters should be used. Then the get_letters function in predict.py can be made private again with two underscores.

Vanilla method
┌───────────┬──────────┐
│ Precision │ 0.959912 │
├───────────┼──────────┤
│ Recall    │ 0.90463  │
├───────────┼──────────┤
│ F1 Score  │ 0.931452 │
└───────────┴──────────┘

Updated connected component method
┌───────────┬──────────┐
│ Precision │ 0.951974 │
├───────────┼──────────┤
│ Recall    │ 0.949781 │
├───────────┼──────────┤
│ F1 Score  │ 0.950876 │
└───────────┴──────────┘

(Liu's) XY split method
┌───────────┬──────────┐
│ Precision │ 0.939639 │
├───────────┼──────────┤
│ Recall    │ 0.935959 │
├───────────┼──────────┤
│ F1 Score  │ 0.937796 │
└───────────┴──────────┘

find ~/Datasets/bboxtestimg/* -type d | xargs -tL1 ./vanilla.py
find ~/Datasets/bboxtestimg/* -type d | xargs -tL1 ./conncomp-btrmorph.py
find ~/Datasets/bboxtestimg/* -type d | xargs -tL1 ./xysplit.py

The above lines finds all subdirs under Datasets/bboxtestimg and pipe it into the programs one line after another by xargs.
-t flag prints the command it expands in the end before executing.
-L1 flag makes sure the lines run one after another sequentially
find ~/Datasets/bboxtestimg -name "Vanilla_*.csv" | xargs ../tools/bboxbenchmark.py
find ~/Datasets/bboxtestimg -name "ConnCompBtrMorph_*.csv" | xargs ../tools/bboxbenchmark.py
find ~/Datasets/bboxtestimg -name "XYsplit_*.csv" | xargs ../tools/bboxbenchmark.py

The above lines recursively finds all files by the patterns, which is obvious by the result.csv naming scheme.
Similarly, the file paths goes into the benchmark program with xargs, except they go all into as N arguments.
The benchmark program by design accepts infinite arguments and include all numbers in its report and therefore -L1 is not used


⚠ Bofrost.be has degraded performance

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

HTTP code: 200
Response time: 2049 ms

Resolved: Bofrost.be performance has improved in 5bb9b77.


📃: Emoji Search App - new project

🔴 Title : Emoji Search App - new project
🔴 Tech stack : HTML, CSS,JS
🔴 Objective : Adding a new project
✅ Details to Include When Taking the Issue:
Name : Shriya Dindi
Participant Role: GSSOC, Hacktoberfest

Happy Contributing! 🚀
Wishing you all the best on your open source journey. Enjoy! 😎

The project already exist, Do not be demotivated and raise a new issue.


Docker 容器架构 The requested image's platform (linux/arm64/v8) does not match the detected host platform (linux/amd64/v2) and no specific platform was requested

xhs-sign

目前镜像已更新
docker run -it -d -p 5005:5005 reajason/xhs-api:latest

签名地址换成了：http://localhost:5005/sign


Multiple interrupt triggers on single button press when running example

I have flashed the gpio-hal-printbuttons example on the microbit-v2. This example should print either Button pressed "A", Button pressed "B" or Button pressed "A + B", as soon as the buttons on the microbit board are pressed.
I noticed that, on occasions, pressing a button once causes the statement to be printed multiple times, which seems to indicate that the interrupt is triggering more than once for a single button press.

Yes, that's what the hardware does: the button often "bounces".
In practice it's often easiest to sample the button state in a timer interrupt instead of using GPIO interrupts.
The "DAL" C++ micro:bit runtime does this using the same 6ms timer as for the display. It goes further than simply sampling and "debounces" the input using a counter, but I don't think that's necessary for the built-in buttons.

I suspected that it may be caused by the hardware, thanks for pointing me to the button bounce.
If I want a function that runs when the button is pressed and I use a timer interrupt to sample the button state, if the button is kept being pressed, the function will continue to run each e.g. 6ms right?
I must also keep track of the previous state so I can call the function when previous state = not pressed and current state = pressed.

Yes, that's the usual thing to do.

Ok, thanks a lot for the explanation, I'll close the issue now.


Add support for ToggleButton

Hi,
I have a UWP application with a ToggleButton.
The following code throws

FlaUI.Core.Exceptions.PatternNotSupportedException: 'The requested pattern 'Invoke [#10000]' is not supported'

var button = mainWindow.FindFirstDescendant("Button1").AsButton();
button.Invoke();

Please post a screenshot showing the button in FlaUInspect.

As you see, it does not support the invoke pattern but the toggle pattern. So you should be able to use the .Toggle method. Alternative you could use the .Click method (but toggle would be better).

Ah ok. Thank you :)

Hmm it seems I still have some problems.
The only way I could call a Toggle on my object is the following:
var button = mainWindow.FindFirstDescendant("Button1").AsCheckBox();
button.Toggle();

This works fine. The ToggleButton toggles its state. But the problem is that the related ICommand wont be executed.
So I decided to use the .Click() method, which seems to work fine the command is executed and the state is toggled. But the problem with that is that: running the test on a build agent doesn't work, I get the following message:

Could not send mouse input. ErrorCode: 5

So what is your advice?

Do you have any idea why this happens? Or do you have a workaround for me? I really want to use your lib but this blocks me.

Using Click is fine. Pitty that the ICommand is not executed on WPFs side.
For UI tests on build agents make sure that you have a correct desktop session. Does it work when you are connected with RDP?

Yes when I am connected via RDP it works fine.
Therfore Click is not a option for me I guess.
Do you have any Idea why the command is not executed? (I am using UWP by the way)

On what event is your ICommand bound? Maybe you can bind it to another event.
Also you can easily setup your build agent to automatically login and therefore have a desktop session. Also make sure that it is not closed when closing the RDP by using tscon 1 /dest:console or similar to disconnect.

I will try it thank you.
I didn't bound the command to a specific event. I just use the command property of the toggle button.
If you want I can make you a small repo solution.
I also tried the same thing with a button and the Invoke(). With this the command will be executed.

Yes a small repo would be good. Maybe we can also redirect this to Microsoft as it is probably a problem there (I'll do some IlSpying to verify this).

Here is the repo solution with a unit test to show the difference between a normal and a toggle button.

Any updates to this?

Not yet. Will look at it when I'm back from vacation.

@Portikus you should be able to use the Toggle pattern to access the Toggle() method for the button. something like:
var button = mainWindow.FindFirstDescendant("Button1").AsButton(); button.Patterns.Toggle.Pattern.Toggle()
You would probably want to check the pattern was supported by the button though using the IsSupported property of the pattern. I ran into the same issue trying to get the ToggleState of a button. I was thinking about adding the pattern to the Button class by default, similar to how buttons in TestStack.White operate.

I had a deeper look at it. I checked the ToggleButtonAutomationPeer and on the Toggle() method, it fires the ToggleButtons OnToggle method which internally only sets the cheched property.
So with the default Toggle it won't be possible. So there are two ways to do this:

Use Click
Create your own ToggleButton class with its own AutomationPeer which either fires the TogleButtons OnClick method (instead the OnToggle) or implement an additional pattern like invoke (see here for an example: https://stackoverflow.com/questions/24762533/togglebuttonautomationpeer-toggle-does-not-execute-command). This would mean you need to exchange all ToggleButtons to your own ToggleButton class.

I just implemented a ToggleButton class which will handle this. Will be in the next release. There is nothing else I can do.

I added a similar class to my branch, but I think the problem in this thread is different then the problem I was facing. I was just wanting a Button with the ToggleState and Toggle methods that could be used for Buttons that support this pattern (which matches the title of the issue). But the original poster seems to be having a deeper issue maybe? I don't know if it is good to wrap the Click() method with a Toggle() method though because if you actually were wanting to test the Toggle Pattern of a button this wouldn't do it. But you wouldn't know that without looking into the source code. It might just be better in this case to write it up in the FAQ that Click() should be used in the case that @Portikus was running into. You can check out what I implemented here:
https://github.com/HyruleWarrior/FlaUI/tree/buttonTogglePattern

@HyruleWarrior Just stumbled uppon this again today. You are probably right.
I just changed the ToggleButton back to use Toggle but added a comment and also an FAQ entry.


Build RST data dictionaries from new metadata

Currently we have a script, datapkg_to_rst that uses the datapackage.json stored under package_data to create nicely formatted data dictionaries for our documentation. These are hugely valuable for users in understanding what data is in the database, and where it came from.
We need to move to generating this RST output based on the new metadata structure that lives in the pudl.metadata subpackage instead. This seems to be the last dependency that we have on the old metadata, and it would be nice to get it taken care of so we don't have to wonder if the two are getting out of sync (spoiler: they are).
For now, simply write a Package.to_rst() function that replicates our existing functionality, and split that into a (renamed) datapkg_to_rst script.
Information that should be made available in the documentation by way of this output:
Tables:

[x] Table names (tables should be sorted by name)
[x] Table descriptions (when they exist)
[ ] Provide links to the tables in Datasette

Fields:

[ ] Field names
[ ] Field data type
[ ] Field descriptions

Doc Build Integration

[ ] Generation of this RST output will need to be integrated into our documentation build, and run automatically whenever we run tox -e docs (which happens during the integration tests).

For now, I would just add a pudl.metadata.classes.Package.to_rst() that replicates what already exists: intro, table name, table description, link to Datasette, and a table of fields with name, type, and description. And integrating this into the documentation build. In fact, because the new Package is identical to the Tabular Data Package schema, the old template (RST_TEMPLATE) can be reused directly.
Only later, in a post-merge future, would I add Resource.to_rst() / Field.to_rst() and make the output more complex.

Okay, I reduced the scope of this issue to just replicating existing functionality and split off enhancements into #1226

Whoops hey @ezwelty I did this work today.

There are some descriptions and some table definitions which currently exist in the old datapackage.json file that don't yet exist in the new metadata and I am in the process of migrating them over.


FIDO test releases fails to authenticate

device: Nitrokey 3C
firmware: v1.7.2-test.20240813
OS: Debian Bookworm
Browsers: Firefox 131.0b8, Chrome 129.0.6668.58
After installing the test firmware, I can no longer authenticate to any website using either Firefox or Chrome. I tried registering the Nitrokey which was successful but still fails to authenticate.
At a site:

Enter user name and password.
Enter pin for Nitrokey.
Prompted to touch Nitrokey. It is blinking.
Authentication fails. A variety of messages but no useful information.

This is a show stopper

hey, thanks for reporting!
Reproducing this was possible for us using firefox - but not chrom(ium).
For me I tried the following combinations using webauthn.io + chromium 129, firefox 131:

firefox register (ok), firefox auth (fail - also with weird pin prompt, even with UV set to discouraged)
firefox register (ok), chromium auth (ok)
chromium register (ok), chromium auth (ok)

So, could you please crosscheck using webauthn.io if this is also true for you?
Why I am asking is because it looks like we've already found and fixed the issue:

https://github.com/Nitrokey/fido-authenticator/issues/98
https://github.com/Nitrokey/fido-authenticator/pull/99

At least this change will make authentication work again for me on firefox, so the question remains whether we see something else (on-top?) here, as you reported that the chrome behavior is identical. We'll include the change into the next test release (likely next week), using that you could then confirm if this fixes it for you.

Here's my results at webauthn.io: These are all on Debian Bookworn.

browser
registration
authentication

Firefox (131.0b8)
Success
Failure "The request is not allowed by the user agent or the platform in the current context, possibly because the user denied permission."

Chrome  (129.0.6668.58)
Success (but initally failed because device already register. I'm not sure how I got past this)
Success got to logged in page.

Chromium (120.0.6099.224)
Success same as chrome
Success got to logged in page.

Edge (129.0.2792.50)
Success
Success

Opera (113.0.5230.86)
Success
Success

However, on real world sites like google.com, gandi.net, ... I'm able to register the key but authentication fails in all browsers.

great, thx for the detailed info - I assume you did not change anything inside the options on webauthn.io ?

Hi Markus, I did fool around the the advanced options when I had registered the Nitrokey but couldn't authenticate in Firefox. This was blocking me from registering the key in other browsers. I thought setting "Use Security Key" since google recently is forcing passkey might make a difference but I didn't see any. I reverted back.
I think the main take points to take away are:

There's an issue with authentication in Firefox in most (all sites).
There's an issue with authentication on some sites in all browsers.

weird - for me chromium works just fine registering + authenticating with gitlab, github and gandi .... but as expected (due to the webauthn.io behaviro) they all don't work with firefox (but they work again with the fix linked above)...
did you see this:

did you do a fido2 reset while running the test-firmware ?

because the next possibility to fully reproduce your behavior would be resetting on a 1.7.2 stable, then update to the test firmware. Or did you by any chance downgrade to 1.7.2 in between ?

Here's the steps I took:

I had upgraded to 1.7.2 stable and used this for a week or two. No issues.
I then updated to v1.7.2-test.20240813 test to enable PIV. This is when the issues started.

I did not do a fido2 reset. I did not see this. I assume this will wipe all my existing credentials which will be very challenging since I cannot get a list of all the sites from the key - a very frustrating factor of the fido protocol.
BTW, another data point. OpenSSH fido based authentication continues to work with the test firmware.

ok, then the only path we didn't go to reproduce is to have fido2 reset being run while on v1.7.2 firmware, then update to the test firmware, then check if authentication after register doesn't work ...
make sure to not downgrade from the test release to the stable release, this particular "downgrade" path will invalidate your fido2 credentials - also please keep in mind that the test version is not intended for production use - be sure to have backup-methods for using your designated services.
Maybe to explain in short what happened here: we implemented ctap2.2 and it looks like firefox is not precisely behaving as the specification suggests (at least how we understand it). So during attestation (authentication) an additional field is returned in the data-map from the nk3 (this is the bug mentioned above which was fixed already and shows correct behavior for me and firefox). Firefox should also ignore this field (according to spec) but doesn't...
but as already implied, there could be another issue, based on your reports - but it's super weird why webauthn.io is behaving so differently for you.
could you maybe do the tests above again with webauthn.io (firefox + chromium is ok), but set all drop downs in "more-options" to "discouraged" ?

Well, this seems is even odder.

browser
registration
authentication

Firefox (131.0b8)
Failure (default options) Success (discouraged)
NA (default) Failure (discouraged)

Chromium (120.0.6099.224)
Success  with default options or with "discouraged"
Success  with default options or with "discouraged"

I use to be able to register with Firefox.

ok, then let's wait on the upcoming test release and redo some tests - thx for your investigations

Hi, We have released v1.7.2-test.20241022. Can you test if it fixes your issue?

On 2024-10-24 08:35, sosthene-nitrokey wrote:

Hi, We have released v1.7.2-test.20241022
https://github.com/Nitrokey/nitrokey-3-firmware/releases/tag/v1.7.2-test.20241022. Can you test if it fixes your issue?
—
Reply to this email directly, view it on GitHub
https://github.com/Nitrokey/nitrokey-3-firmware/issues/537#issuecomment-2435174922, or unsubscribe https://github.com/notifications/unsubscribe-auth/AHYXMUV6J5RFZC7HH5XY4TDZ5DSQLAVCNFSM6AAAAABPGTJVROVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDIMZVGE3TIOJSGI.
You are receiving this because you authored the thread.Message ID:
@.***>

I upgrade to this version from version v1.7.2-test.20240813.
The updated version does work with Firefox (132.0b7) when authenticating
to Google Workspace using FIDO2.
Thank you for the quick fix. You can close this issue.
--
JP