text:
[FP]: False Positive on grpc-netty / grpc-netty-shaded : 1.50.2.jar

Package URl
pkg:maven/io.grpc/grpc-netty-shaded@1.50.2
CPE
cpe:2.3:a:netty:netty:1.50.2:*:*:*:*:*:*:*
CVE
CVE-2019-20444
ODC Integration
None
ODC Version
7.4.1
Description
False positive on library grpc-netty-shaded-1.50.2.jar
Find below the vulnerabilities reported by the dependency check tool:
CVE-2019-20444
CVE-2019-20445
CVE-2015-2156
CVE-2019-16869
CVE-2021-37136
CVE-2021-37137
CVE-2022-41881
CVE-2021-43797
CVE-2022-41915
CVE-2021-21295
CVE-2021-21409
CVE-2021-21290
CVE-2022-24823
CVE-2014-3488
I have gone through all these CVEs and could not find anything related to grpc-netty-shaded
The issues shown are related to other netty libraries.

@keerthanavenky Can you share more info on how you run it? The FP is expected to not happen for any of the 7.x versions. I tried reprocuction with both Maven-plugin and CLI and fail to get the FP CPE match you mention.

@aikebah we are leveraging the gradle plugin

@aikebah we are leveraging the gradle plugin

Could not reproduce with the following build.gradle.kts
plugins {
    kotlin("jvm") version "1.8.0"
    id("org.owasp.dependencycheck") version "7.4.1"
}

group = "com.example"
version = "1.0-SNAPSHOT"

repositories {
    mavenCentral()
}

dependencies {
    implementation("io.grpc", "grpc-netty-shaded", "1.50.2")
}

I was able to reproduce the finding with the CLI scanning the jar directly, I did have to run the scan twice, after the second run CVE-2019-20444 showed in the report
Steps:

Download the jar from https://mvnrepository.com/artifact/io.grpc/grpc-netty-shaded/1.50.2
CLI Command dependency-check --scan grpc-netty-shaded-1.50.2.jar --disableCentral

Understood, we don't run with --disableCentral, I only used the flag due to the issues lately with Maven Central. Thanks for the reply I think this answers why we are seeing the CVE
References:
https://github.com/jeremylong/DependencyCheck/issues/5342
https://github.com/jeremylong/DependencyCheck/issues/5341

I was able to reproduce the issue by setting up a structure similar to how our scan is performed.
Steps to Reproduce:

Create a new folder and a libs folder nested inside (ex: my-plugin/libs)
Download the https://mvnrepository.com/artifact/io.grpc/grpc-netty-shaded/1.50.2 jar and place the grpc-netty-shaded-1.50.2.jar inside the libs folder
From the top level folder, bundle the folder as a jar jar cvf plugin.jar  .
Install the plugin to your local .m2 repository apache-maven-3.8.7/bin/mvn install:install-file -Dfile=plugin.jar -DgroupId=com.example -DartifactId=my-plugin -Dversion=0.0.1 -Dpackaging=jar
build.gradle configuration (Note: this finding occurs on version 8.1.0 as well)

plugins {
    id 'java'
    id("org.owasp.dependencycheck") version "7.4.1"
}
repositories {
    mavenLocal()
}

dependencies {
    implementation 'com.example:my-plugin:0.0.1'
}

Run ./gradlew dependencyCheckAnalyze

I bundled the plugin jar with some additional libraries. What I noticed is the "package" field is discovered on some libraries but not all. I'm wondering if this is something on the DependencyCheck end or on the central search end, if it's on central search we can close this issue out.

@kevin-doyle Thanks for the detailed reproduction. Hope to get a detailed look into it over the weekend. I'd say that as the jar is downloaded from central it should've been matched in central search, so I'll try and see whether I can reproduce what you observed and can find out why it doesn't match.

It appears as if documentation is not in line with actual implementation. I can reproduce your case because with the defaults in the gradle plugin the central analyzer appears to not be enabled.
Can reproduce the FP and fix it by configuring centralAnalyzer to enabled in build.gradle
dependencyCheck {
    analyzers {
        centralEnabled = true
    }
}

Check the code-base and it's been disabled by default since v3.2.1 so the documentation is lacking an update on that.

@aikebah Thanks for all the help! I was able to resolve this on our end.

authors: abdullahkmunawar aikebah keerthanavenky kevin-doyle


text:
Rubygems analyzer

This analyzer utilizes some custom regular expressions to parse Ruby Gem specifications out of .gemspec and Rakefile files. The specifications are Ruby code, and so could vary from the format I'm parsing. However, I've found in practice that .gemspec files downloaded from https://rubygems.org/ code the values directly using string and list literals in the specification block.

Dale,
For Ruby - bundler-audit would be the tool of choice. Why would we want to include a Ruby analyzer in dependency-check?
--Jeremy

With jruby gem files can become first class dependencies (just like jar files) eg. this maven plugin depends on and bundles gem files. I'm not sure the way this is implemented would catch a use-case like that, but it would be nice.

source: gharchive/pull-request

authors: dwvisser jeremylong mprins

repo: jeremylong/DependencyCheck

license_type: permissive

license_source: github-api


text:
Bring back "Responsiveness" (side by side graphs)

Before v6.0.0 there was a toggle to set graphs in "side-by-side" or "responsive" mode for big/huge monitors. In v6.0.0 the feature got slashed because:

A. It was bugging out after Chart.js upgrades and blocking the v6 progress;
B. I thought no one would be using it because it wasn't very useful;

I was wrong on count B, because folks on Reddit prompted me on this removal.
So: let's bring the feature back for 2023 edition! See #79.

Just fixed, will release an update a bit later.

source: gharchive/issue

repo: jeroenheijmans/advent-of-code-charts

license: MIT


text:
Automatically reset at 00:00 is not working

Automatically reset at 00:00 is checked and it was working pretty good.
Unfortunately, the reset of the value at 0:00 has not been working properly for some time.
Box is checked.

The low value between 0 and 6 am is probably due to the fact that the WLAN is deactivated at 0.15 am. However, this has always been the case and the reset at 0.00 a.m. also worked.

which HA version are you on? is there anything in the logs?

Please excuse the late reply. The tip about the HA version was good. I
updated to the latest version and it works fine again. Thank you very much.
Am Sa., 6. Juli 2024 um 23:43 Uhr schrieb Jeroen ter Heerdt <
@.***>:

which HA version are you on? is there anything in the logs?
—
Reply to this email directly, view it on GitHub
https://github.com/jeroenterheerdt/HADailySensor/issues/61#issuecomment-2211977988,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/BE562J7FC2DVUXJO5SEUMQTZLBQJVAVCNFSM6AAAAABKG64FSOVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDEMJRHE3TOOJYHA
.
You are receiving this because you authored the thread.Message ID:
@.***>

authors: ErikOberle jeroenterheerdt

repo: jeroenterheerdt/HADailySensor


text:
Update inst_history to be per core in uvm env

A reminder to self to do this.  For now, to get things working with a single core solution it was not done on a per-core basis.

Hi Jerralph,
My name is Muneeb and I am from India. I am a Tech Lead with more than 4 years of experience in Front-end verification having expertise in SystemVerilog and UVM. Also, I have good knowledge of computer architecture.
I came across your project on VIP for RISC-V and its sounds amazing. I think with my knowledge I can contribute to this great project.
I would like to talk to you with this regard. Please do contact me on my email id:
muneeb.mirafra@gmail.com.
I'll be looking forward to your humble response.
Regards,
Muneeb

Hi Muneeb,
Thanks for reaching out.  I will email you directly to continue the conversation.
Cheers,
Jeremy

Many thanks for your reply, Jeremy.
I am super excited to collaborate with you on this project.
Regards,
Muneeb
On Wed, Oct 31, 2018 at 11:02 PM Jeremy Ralph notifications@github.com
wrote:

Hi Muneeb,
Thanks for reaching out. I will email you directly to continue the
conversation.
Cheers,
Jeremy
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
https://github.com/jerralph/riscv-vip/issues/12#issuecomment-434774396,
or mute the thread
https://github.com/notifications/unsubscribe-auth/APL1T0tI7CqnRm6ntpx8jpeg-VpH8hy1ks5uqd6VgaJpZM4XKohu
.

--
Regards
Muneeb Ulla Shariff
muneebullashariff@gmail.com

authors: jerralph muneebullashariff

repo: jerralph/riscv-vip


text:
Fix build warning in jerry-ext/arg on tizenrt-artik05x

tizenrt-arttik05x treats warning as error for uninitialized use.
This patch fixes the error in jerry-ext/arg by initializing to zero.
JerryScript-DCO-1.0-Signed-off-by: Sanggyu Lee sg5.lee@samsung.com

Here is error log.
/home/brian/iotjs/jerry-tizenrt/jerryscript/jerry-ext/arg/arg-transform-functions.c: In function 'jerryx_arg_transform_uint8_strict':
/home/brian/iotjs/jerry-tizenrt/jerryscript/jerry-ext/arg/arg-transform-functions.c:151:41: error: 'tmp' may be used uninitialized in this function [-Werror=maybe-uninitialized]
     *d = (*d >= 0.0) ? floor (*d + 0.5) : ceil (*d - 0.5);
                                         ^
/home/brian/iotjs/jerry-tizenrt/jerryscript/jerry-ext/arg/arg-transform-functions.c:172:12: note: 'tmp' was declared here
     double tmp; \
            ^
/home/brian/iotjs/jerry-tizenrt/jerryscript/jerry-ext/arg/arg-transform-functions.c:190:3: note: in expansion of macro 'JERRYX_ARG_TRANSFORM_FUNC_FOR_INT_TEMPLATE'
   JERRYX_ARG_TRANSFORM_FUNC_FOR_INT_TEMPLATE (type, _strict, min, max) \
   ^
/home/brian/iotjs/jerry-tizenrt/jerryscript/jerry-ext/arg/arg-transform-functions.c:193:1: note: in expansion of macro 'JERRYX_ARG_TRANSFORM_FUNC_FOR_INT'
 JERRYX_ARG_TRANSFORM_FUNC_FOR_INT (uint8, 0, UINT8_MAX)

repo: jerryscript-project/jerryscript

license_source: bigquery


text:
Card not rendered when using paste

When I paste a card number into the form and use only the mouse (no keyboard events) the card is not rendered correctly. No numbers appear on the card graphic however formatting is done to the pasted value.

Hi all, thanks for your input!
This issue doesn't appear in Chrome, but I'm guessing it may be related to #165. I'm closing in favor of that issue — if it's something different, please re-open with more information!

@jessepollak this is a different issue. Please reopen.
There are several ways to reproduce this one:

Right-click on any field and select Paste.
Fill one any field (with the keyboard), then select it (using the mouse), right-click and choose Cut (or Delete).
Select some text somewhere and click-drag the selection onto any field.
On Linux (maybe on Mac too), select some text somewhere and then middle-click onto any field (this is an alternative way of pasting text).

Again, please consider using the oninput event. It is supported in all browsers, even in IE9. After adding the oninput event, feel free to remove any keyboard-related event handler, as they are not needed anymore.

I tried this small patch, but it didn't fix the issue completely because of payment.coffee, which still has several keyboard-related handlers. The fix to this issue #37 and also to the other issue #165 depends on changing/updating/fixing jessepollak/payment as well.
--- a/src/coffee/card.coffee
+++ b/src/coffee/card.coffee
@@ -162,10 +162,10 @@ class Card
       el = this["$#{name}"]
       if QJ.val(el)
         # if the input has a value, we want to trigger a refresh
-        QJ.trigger el, 'paste'
+        QJ.trigger el, 'input'
         # set a timeout because `jquery.payment` does the reset of the val
         # in a timeout
-        setTimeout -> QJ.trigger el, 'keyup'
+        setTimeout -> QJ.trigger el, 'input'

   handle: (fn) ->
     (e) =>
@@ -226,7 +226,7 @@ class Card
     QJ.on el, 'blur', ->
       QJ.removeClass el, 'jp-card-focused'

-    QJ.on el, 'keyup change paste', (e) ->
+    QJ.on el, 'input', (e) ->
       val = (QJ.val(elem) for elem in el)

       join = opts.join(val)

authors: denilsonsa jessepollak kaptk2

repo: jessepollak/card

license: mit


text:
Upon first run app shows first two lessons completed, selecting lesson throws error

What version of node are you running?

v5.0.0

#27 should fix this issue.

authors: SomeoneWeird c-ro martinheidegger

repo: jesstelford/scope-chains-closures

license: isc


text:
Compatibility with React 0.13

I can't use any react-semantify components with React 0.13. My app breaks when using any component with the warnings:

Column(...): No render method found on the returned component instance: you may have forgotten to define render in your component or you may have accidentally tried to render an element whose type is a function that isn't a React component.
Warning: Don't set the props property of the component. Mutate the existing props object instead.

And breaks with the message: Can't add property context, object is not extensible. I think this may happen because props can no longer be mutated?
Trace
ReactCompositeComponentMixin.mountComponent  ReactCompositeComponent.js?:153
ReactPerf.measure.wrapper                                        ReactPerf.js?70
ReactReconciler.mountComponent                             ReactReconciler.js?38

@FoxxMD I release react-semantify 0.3.0 with React v0.13.x. Could you help to check whether it solves this problem? Thanks a lot.

Yes I will test this tomorrow, thank you!

This fixed it :+1:  thank you


text:
Feature Request: support for older version of PHPs

The older versions of PHPs is not supported by nix(see https://github.com/NixOS/nixpkgs/blob/master/pkgs/top-level/aliases.nix) , so when I use devbox add php73, it promts Error: Package php73 not found..
However there are some workarounds, for example fossar/nix-phps . Is it possible for devbox to support such kind of workarounds?

We'll look into this! We're evaluating how to let users configure alternative Nix repositories and package sources for Devbox.

As of 0.4.7, we've released support for Nix Flakes in your package list.  This means you can now install PHP versions from the fossar/nix-phps repo by adding the following to your packages list:
{
    "packages" : [
        "github:fossar/nix-phps#php73"
    ]
}

For more details, see https://www.jetpack.io/devbox/docs/guides/using_flakes/

authors: Lagoja LeslieLeung

repo: jetpack-io/devbox


text:
debug failing tests

Summary
How was it tested?

Current dependencies on/for this PR:

main

PR #875

PR #874

PR #869

PR #880   👈

This comment was auto-generated by Graphite.


text:
Using this in 2020

Is anyone using this in production? Specifically in coordination with https://github.com/jaydenseric/apollo-upload-client
If so, it would be awesome if someone could share an example!
The best 2 posts I have found covering this are:

https://medium.com/@karensgrigorjancs/effortless-file-uploads-with-activestorage-apollo-and-react-7a50929c40ca (out of date now I think)
https://rowant.co.uk/uploading-content-react-graphql-rails-and-active-storage/ (just does not work)

My current issue is: I can get the file to attach when I write the query in Insomnia, but in the browser I can an error: Error: GraphQL error: Variable $file of type Upload! was provided invalid value. Happy to provide more context on this specific bug if someone thinks that would be helpful!
If there is a fix, also happy to help submit it back as a PR (assuming I can figure this out)

Raising this exception was added here https://github.com/jetruby/apollo_upload_server-ruby/pull/32. It would be great if you inspect type of the incoming value, maybe previous version will help you.
There is also related discussion here https://github.com/jetruby/apollo_upload_server-ruby/issues/33, but I think this is not what you're looking for

I was able to get it working with the 2nd article (https://rowant.co.uk/uploading-content-react-graphql-rails-and-active-storage/). Make sure that you're using createUploadLink and using it as a terminating link (https://www.apollographql.com/docs/link/overview/#terminating-links). If you post some code, I'd be happy to take a look

I went with a direct uploading strategy instead where my server simply returns POST instructions via Shine. Closing this to keep down the clutter. I do appreciate the responses! Direct just ended up being best for my use case.

authors: fuelen jeffchuber sguha00


text:
Remove helm & tiller references from the static manifests installation

Installing a brand-new 1.15 cluster (using kops) and deploying cert-manager 0.12 using static manifests.
The manifests are littered with Helm & Tiller labels, such as:
metadata:
  name: cert-manager-cainjector
  labels:
    app: cainjector
    app.kubernetes.io/name: cainjector
    app.kubernetes.io/instance: cert-manager
    app.kubernetes.io/managed-by: Tiller
    helm.sh/chart: cert-manager-v0.12.0

These are interfering with a separate Helm playground on the same cluster.  I understand they're generated from the Helm charts, but if one is installing from static manifests, surely the intention is to have no Helm references, either as cruft or interference.
REQUEST: Can the Helm & Tiller references please be removed from the generated manifests?  Think kustomize should work for this as part of the build process?
/kind bug

/remove-kind bug
/kind cleanup
/help-wanted
/priority backlog
/area deploy

/remove-lifecycle stale

Would adding a value like helmLabels to the values.yml and then adding that to all templates a bad solution? I cant think of a different solution since everything is currently rendered out of the helm files

We'd prefer not to add values to the chart that are not meant for users to touch.
We already do something similar with our CRDs with the filter-crd tool, might be worth reusing that logic in a step in Bazel.

authors: fionera mariusmarais meyskens munnerz

repo: jetstack/cert-manager


text:
Manage etcd, apiserver, controller-manager, scheduler, proxy, kubelet certificates

Is your feature request related to a problem? Please describe.
Using cert-manager I can't auto rotate the certificates for k8s control plane components such as etcd, apiserver, controller-manager, scheduler, proxy, kubelet.
Describe the solution you'd like
Provide a way to manage those certificates by reading and writing certificate files on the master nodes' disk.
Describe alternatives you've considered
The only solutions I know are kubeadm or similar cert management tool that live outside of the cluster. It'd be great if those certs can be managed from within the cluster.
Additional context
Extended goal would be an ability to sync the certificates across the master nodes such that they're using identical set of certificates.
/kind feature

/remove-lifecycle stale

/remove-lifecycle stale


text:
Document configuring nodeSelector for webhook and cainjector

Signed-off-by: Michael Tsang michael.tsang@jetstack.io

What this PR does / why we need it:
Documents how to set the nodeSelector to the webhook and cainjector, to disambiguate the current single nodeSelector parameter.
Which issue this PR fixes (optional, in fixes #<issue number>(, fixes #<issue_number>, ...) format, will close that issue when PR gets merged): fixes #1673
Release note:

NONE

/retest

/lgtm
/approve

authors: cheukwing munnerz


text:
Support overprovisioning

Which issue this PR fixes (optional, in fixes #<issue number>(, fixes #<issue_number>, ...) format, will close that issue when PR gets merged): fixes #308
Support cluster autoscaler overprovisioning

/assign @simonswine

/retest

/retest

/unassign
/assign @simonswine

/test puppet-tarmak-acceptance-centos v1.6

/retest

/retest

/test puppet-kubernetes-acceptance

authors: dippynark simonswine

repo: jetstack/tarmak


text:
Equality is still off due to floating point math

irb(main):003:0> 'yellow'.paint.send(:rgb)
=> #<Chroma::ColorModes::Rgb:0x007fa088e1f1d8 @r=255, @g=255, @b=0, @a=1.0>
irb(main):004:0> 'red'.paint.spin(60).send(:rgb)
=> #<Chroma::ColorModes::Rgb:0x007fa088e25330 @r=254.99999999999994, @g=255.0, @b=0, @a=1>
irb(main):005:0> 'yellow'.paint == 'red'.paint.spin(60)
=> false

Fixed in first-release branch.

repo: jfairbank/chroma


text:
Does v4.xx still support Gracenote metadata?

Will the Gracenote metadata source continue to be available on version 4?
Because some albums don't have metadata in MusicBrainz, while Gracenote has instead.

Thank you for your answer.

repo: jfchapman/VUPlayer


text:
Way to enforce the standalone package name

If a module is named like peaks.js, where the . has a decorative value and not a namespace value, /standalone/peaks.js is equivalent to the --standalone peaks.js browserify command.
The issue is the exported module is exported as window.peaks.js, js becoming a property of the namespace peaks.
It does not seem to be doable in substack/node-browserify#818: what could be a proper way to define the standalone module name for browserify-cdn?
I would definitely map /standalone/peaks.js as --standalone peaks, to match the library examples and so on.
Thanks for your insights :-)

The same for modules with a - in the name.
f.e. 1-liners would become window.1-liners but this breaks before it even builds. see https://wzrd.in/standalone/1-liners@0.3.5
refs 1-liners/1-liners/issues/128

I think the best solution would be to add a possibility for defining the standalone-variable f.e. https://wzrd.in/standalone/oneLiners/1-liners@latest

authors: oncletom stoeffel

repo: jfhbrook/browserify-cdn


text:
JFXTabPane-Arrows: Visibility bug?

I think there's a bug with the visibility of the JFXTabPane-Arrows. The arrows are not completely visible, when i change the window size before i load/show the view/fxml for the first time. After that, i have to resize (width or height) the window again and then the arrows are completely visible.
steps to reproduce:

resize the window, that its not fullscreen

show the view (in my example with a click on an button)-> arrows aren't completely visible

resize the window again -> arrows are completely visible

Is there a way to solve this problem?

Which JFoenix version are you using?
as this is a known issue and it's fixed in the latest version of JFoenix.

I updated the version and now it works. Thank you for your help!

repo: jfoenixadmin/JFoenix


text:
Correcting Cvess score data types

[x] All tests passed. If this feature is not already covered by the tests, I added new tests.
[x] This pull request is on the dev branch.
[x] I used gofmt for formatting the code before submitting the pull request.

@eyalbe4

Just an FYI @romelusw -  https://github.com/jfrog/jfrog-client-go/pull/473
I believe that with the new PR we're all good.

@romelusw -
We now see that following your change from string to float64, the following "TestXrayReport/reportAll" test fails.
Since we may need to release jfrog-client-go today, we may have revert the commit of this PR.
Please let us know what you think.
=== RUN   TestXrayReport/reportAll
[Debug] Sending HTTP POST request to: http://localhost:49725//api/v1/reports/vulnerabilities
[Debug] HTTP redirecting to  http://localhost:49725/api/v1/reports/vulnerabilities
[Debug] Sending HTTP POST request to: http://localhost:49725/api/v1/reports/vulnerabilities
[Debug] Sending HTTP GET request to: http://localhost:49725//api/v1/reports/777
[Debug] Sending HTTP POST request to: http://localhost:49725//api/v1/reports/vulnerabilities/777?direction=asc&page_num=0&num_of_rows=7&order_by=severity
[Debug] HTTP redirecting to  http://localhost:49725/api/v1/reports/vulnerabilities/777?direction=asc&page_num=0&num_of_rows=7&order_by=severity
[Debug] Sending HTTP POST request to: http://localhost:49725/api/v1/reports/vulnerabilities/777?direction=asc&page_num=0&num_of_rows=7&order_by=severity
    xrayreport_test.go:67:
        	Error Trace:	xrayreport_test.go:67
        	Error:      	Received unexpected error:
        	            	json: cannot unmarshal string into Go struct field ReportCve.rows.cves.cvss_v2_score of type float64
        	Test:       	TestXrayReport/reportAll
    xrayreport_test.go:92:
        	Error Trace:	xrayreport_test.go:92
        	            				xrayreport_test.go:68
        	Error:      	Not equal:
        	            	expected: 3131
        	            	actual  : 3043
        	Test:       	TestXrayReport/reportAll
[Debug] Sending HTTP DELETE request to: http://localhost:49725//api/v1/reports/777
--- FAIL: TestXrayReport (0.01s)
    --- FAIL: TestXrayReport/reportAll (0.01s)

Hi @romelusw ,
We reverted this commit for the time being to avoid stalling the release planned for today.
We'll be happy to merge this again after the issue with the tests will be resolved.
Thanks

@eyalbe4 the failure had to do with the test data also being as strings rather than floats. I have corrected that here: https://github.com/jfrog/jfrog-client-go/pull/476

authors: RobiNino eyalbe4 romelusw

repo: jfrog/jfrog-client-go


text:
Fix README to point to correct build gradle file

Because I actually clicked the link and ended up in a 404 "this is not the page you are looking for".

thanks

authors: McFoggy nunocastromartins

repo: jgitver/gradle-jgitver-plugin


text:
Walkable element lists

Add Walkable instances for lists of Inlines and lists of Blocks.  This is a prerequisite for jgm/pandoc#3926.

No tests have been added yet, as the default way to test instances (p_walk) seems to return incorrect results for lists. Running
main :: IO ()
main = toJSONFilter (walk inlinesTrans :: Pandoc -> Pandoc)

inlinesTrans :: [Inline] -> [Inline]
inlinesTrans xs | all whitespaceInline xs = []
  where whitespaceInline Space = True
        whitespaceInline LineBreak = True
        whitespaceInline SoftBreak = True
        whitespaceInline (Str "") = True
        whitespaceInline (Span _ []) = True
        whitespaceInline _ = False
inlinesTrans x = x

on
Pandoc (Meta {unMeta = []}) [Para [Str "a", Str ""]]

gives
Pandoc (Meta {unMeta = []}) [Para "a"]

where walk instead of bottomUp leaves the document unchanged.
I'm not sure what's the best way to test these new instances.

+++ Albert Krewinkel [Sep 19 17 15:24 ]:

No tests have been added yet, as the default way to test instances
(p_walk) seems to return incorrect results for lists. Running

Could you say more about how?
Note that bottomUp (as used, definitionally expanded, in
p_walk) gets applied to every sublist of a list:
Prelude Text.Pandoc.Generic Text.Pandoc.Definition> let f (xs :: [Inline]) = [Emph xs]
Prelude Text.Pandoc.Generic Text.Pandoc.Definition> bottomUp f $ [Para [Str "hi", Space, Str "there", Space, Str "friend"]]
[Para [Emph [Str "hi",Emph [Space,Emph [Str "there",Emph [Space,Emph [Str "friend",Emph []]]]]]]]

I don't know if your walk instance is designed to work like
that, or differently?

See https://stackoverflow.com/questions/2428161/lists-searches-in-syb-or-uniplate-haskell
for the basic issue.  The solution there uses uniplate.  Perhaps something similar could be done with syb?

Some thoughts:
(1) One way to remove duplicate code would be to factor out walkBlockM and walkInlineM to the top level, then use these to define walkM instances for both a -> a and [a] -> [a] forms:
instance Walkable Inline Inline where
  walkM f = walkInlineM >>= f

instance OVERLAPS
         Walkable [Inline] [Inline] where
  walkM f = traverse walkInlineM >=> f

I haven't checked this completely, but at first glance it looks like this would work.  That would fix the code duplication problem.
(2) There is a travis failure for ghc 7.8, which will require some extra imports (possibly protected by CPP so we don't get warnings for other versions).
(3) I'm wondering whether we really need this feature, and the complexities it brings.  I see from the associated lua filter changes that we'd be, essentially, lifting a function Inline -> [Inline] to a function [Inline] -> [Inline] by using map and mconcat.  That means that every filter will incur the overhead of concatenating a list of lists (generally, one element lists).  I don't know if you've measured the performance impact of this, but I expect it would be significant.
We could keep things simple and have lua filters define Inline -> Inline or Block -> Block.  To delete an element, convert it to a Null block or Str "".  To insert a list of elements, insert a span.  (In most formats, this will be no different from splicing a list, if the span has no attributes; in HTML, you'll get a span tag, but that's harmless.)
On the other hand, there are some uses for filters that operate on [Inline] -> [Inline]; in pandoc-citeproc, I have to resort to bottomUp for the function to move punctuation marks (mvPunct in Text.CSL.Pandoc); this Walk instance might be faster.  Not sure that justifies all the additional complexity, though.

(1) This was my approach as well, but didn't work the way I expected. The type signature for walkInlineM would have to be along the lines of
walkInlineM :: (…) => (t Inline -> m (t Inline)) -> (t Inline) -> m (t Inline)

where t would be specialized to [] or Identity.  However, this requires to change the Walkable [Inline] [Inline] to Walkable (t Inline) [Inline], which I either found to require InconsitentInstances or just couldn't do (I don't remember).
(3) I checked the performance impact beforehand, and (contrary to my own assumptions) using the Walkable [Inline] Pandoc instance does not significantly affect performance.
I don't have a clear opinion on whether it's worth the additional complexity. I currently have a slight preference for adding those instances but remain sceptical.

I used the assumption
everywhere (mkT f) d == walk (foldr g []) d
  where g x ys = f (x:ys)

to test the implementations for walkM and did find some issues here and there.
There seems to be no such law which would make it possible to fully test query, so I'm currently only testing that the function given to query gets to see the correct amount of elements.

I wonder if it would make more sense to have the [Inline] -> [Inline] instance work the way bottomUp does (operating on each sublist of a list)?  Then we would match the behavior of Text.Pandoc.Generics (least surprise) and could test with that.  We could also sub out some existing uses of bottomUp without worrying about different semantics.
Would it be difficult to change the code to do this?  Would it make a difference for the application to lua filters? (Presumably not since you're always passing in a one-element list.) Would it affect performance?
Example of how this works in practice:
Prelude Text.Pandoc.Definition Text.Pandoc.Generic> let f [Str "."] = []; f xs = xs
Prelude Text.Pandoc.Definition Text.Pandoc.Generic> bottomUp f [Str "hi", Str ".", Str "there", Str "."]
[Str "hi",Str ".",Str "there"]

I merged this (though I may still want to revert of modify it).
What do you think of the alternative above?
I also added a commit that removes ALL the code duplication.
Let me know if there's something bad about this that I've missed!

I pushed another commit that makes walkM and query match behavior of bottomUp and queryWith for [Inline] -> [Inline] and [Block] -> [Block].  Let me know if this is a bad idea!

Oh wow. This is great (and I'm feeling very stupid now)!

Performance wise, having walkM match bottomUp is very costly. It turns an O(n) operation into an O(n²) operation, which is very noticable with lua filters. Furthermore, counting elements with lua filters is no longer possible, as the number of times a function is called with a given element is dependent on its context.

There is also the mathematical argument, that the Walkable [a] [a] implementations for walkM are the only ones which require the functor m to be a monad. All other instances could be expressed with m being Applicative. Weakening the constraint for walkM would bring its type closer to that of a lens Traversal', which might become useful at some point.

nm my previous comment. I should step away from the computer for a while.

Performance wise, having walkM match bottomUp is very costly. It turns an O(n) operation into an O(n²) operation, which is very noticable with lua filters.

I was thinking this wouldn't matter for the particular application, since n = 1 (you're passing in singleton lists).

. Furthermore, counting elements with lua filters is no longer possible, as the number of times a function is called with a given element is dependent on the element's context.

Yes, I see the concern there.

OK, I reverted that last change.

authors: jgm tarleb

repo: jgm/pandoc-types


text:
load global stylesheet with config initializer

Hey @kitop,
This is still WIP. Tests need to be added.
I didn't manage to set it up via application.rb so I went with an initializer. Feel free to change it if it's easy to do it the other way.
One cool and unplanned feature is that anyone can load a stylesheet and overwrite MountainView's styles and customize it to fit their look & feel :smiley:

Looks really good!!!
The configuration file looks good, we can try to move it to Rails config later, if it seems worth it.

1 to tests and hound comments.

We can also use this configuration object for styleguide specific stylesheets in the future :)

@kitop Thanks for the comments.
I've added a couple of tests. Let me know if they look good.
Cheers!

Looks good!! :+1:
Only one thing: what do you think of testing MountainView.configure instead of directly the configuration class? Would it make sense?
Something like
MountainView.configure do |config|
  config.included_stylesheets << "foo"
end

assert_equal ["foo"], MountainView.configuration.included_stylesheets

@kitop
If test directly MountainView.configure and do it like you say, I get this Error:

Error:
MountainViewTest#test_shows_styleguide:
ActionView::Template::Error: couldn't find file 'foo'

It seems that file foo.css should be present in the dummy app. I would leave this test like it is as we also test it this the dummy app in the integration test:
  test "global stylesheets are properly served" do
    get "/assets/mountain_view.css"

    assert_response :success
    assert_match(/Global Stylesheet Beginning/, response.body)
  end

What do you say?

Agh, right, because it actually configures MountainView for the demo app :/
Yeah, leaving it as is seems good then!
:shipit:

authors: jgnatch kitop


text:
Overlapping click spots make program too fiddly

[x] I agree to follow the Code of Conduct that this project adheres to.
[x] I have searched the issue tracker for a feature request that matches the one I want to file, without success.

This program is lovely and has a huge potential.
It is still extremely fiddly though, especially when working on tiny things.
One significant way to improve this would be
to avoid overlapping click spots.
I wanna grab a handle and extend an element to the left,
there is the arrow again. I think this is one of the most
annoying things of this wonderful program.

The arrow should be moved away from those size handles in this case. How did you get this to overlap?

I hover over the handle I want to grap.

Now I see: Found the option to hide the connections and arrow click-spots! Makes things so much easier.

authors: alderg oMrSmith

repo: jgraph/drawio


text:
Import tables from Excel, Google Sheets, SQL and ect.

Hi, I need to import pairwise tables. Since it's big tables (in most cases) i need to be able to import tables either by copy paste or through the menu. Also it would be imported thought SQL commands. For example, here https://sqlizer.io/#/ it is possible to convert excel table to SQL commands. Thanks!

There is this https://drawio-app.com/blog/sql-plugin/
and also you can import SQL and CSV - plus a config section to define how the CSV rows and columns would be turned into DrawIO nodes.  This is available under the "Arrange" menu > Insert > Advanced > SQL... or CSV...
The SQL example that pops up creates some tables, with a little tweaking you can probably get it to make the kind of tables you are looking for.

@125401qwerty I have a pr #4122 with improvements to the sql plugin that you have to install yourself manually (one file change) for sql import into uml draw io diagram

authors: 125401qwerty Peeeet lastlink


text:
Need reworking on code, poor image quality on output and missing source code

This library is potentially cool but now quite outdated and need a reworking on many parts; many parts of code use deprecated functions; has issues when running on new Android versions due to permissions; the maximum image resolution on output is always 1024 x 768 and cannot be increased.
Finally the sources of two libraries that are provided pre-compiled are missing; why? I think that the issues are there!
To all people: PLEASE help me to find a replacement solution or the sources of the precompiled libraries. Thanks!

I'm using the following library and it is working for me.
AndroidDocumentScanner

Only issue that i'm facing with https://github.com/mayuce/AndroidDocumentScanner library is app size increases by 30 MB.
Is it the same 30 MB app size increase with the library you are using ?

Talking about only the pre-compiled opencv and (I think) the image processing libraries that jansireddy provide pre-compiled, for all platform the folder last about 74Mb that must be uploaded on the Android Store. Then I have all my application.
Taking a look at the mayuce lib you suggested me, we have the strong value that is 100% open with no pre-compiled parts and the full arm64 compiled version is just 11.2Mb!

authors: fpiraneo pradeep-orbi

repo: jhansireddy/AndroidScannerDemo


text:
Read local game info

Read data from main.lua, main3.lua, gamename.idf.

It has been added in 3.1.0 version.


text:
ci: use java 23 version instead of 22 for at least one build

22 is now obsolete, let's use 23

I agreed!  I am looking for Java 23 to use the newest features of java 23 and newst Spring boot 😃😃😃👏

authors: murdos renanfranca

repo: jhipster/jhipster-lite


text:
added toString to better understand debugging sessions

I'm leaning to contribute to jhipster-lite
This PR contains toString() improvements to see what values are in variables when debugging and trying to learn how the system works.
I know that this is a very small thing. I just like to see the relevant data when I'm debugging

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

Thanks for your contribution @anderskristian
But I think you won't pass the CI because of missing unit tests :-)

Okay I will try to make unit tests on the to string methods

Thanks for your contribution @anderskristian But I think you won't pass the CI because of missing unit tests :-)

I have added unit tests

I can see that I still have a problem in the test.
I should use a test with ..hasToString ...
I have never thought about using hasToString ( I did not know it existed 😳)
I find that check so amazing. It is great.
So thanks a lot to the team  🥰. This weekend I learned quite a lot ... even about toString() 🫠

Congratz for your contribution :)

authors: CLAassistant DamnClin anderskristian pascalgrimaud


text:
Sonar: %n should be used in place of \n to produce the platform-specific line separator.

Fix https://sonarcloud.io/project/issues?resolved=false&types=CODE_SMELL&id=jhipster_jhipster-lite&open=AY32YPdwSjlKq-G0oiu5&tab=code

@murdos \\n are really necessary in the regex because tests are ✅ without?

@murdos \\n are really necessary in the regex because tests are ✅ without?

@qmonmert : Good point. I was not aware until now, but \s match return line \n, so line separator is indeed not necessary.
I've pushed to your branch a modification of an existing test using a dependency with multiple exclusions, to be sure that this case is covered.
So +1 for removing the line separator :-)

@murdos seems good

Thanks @qmonmert ! 🙂

@murdos @pascalgrimaud ✅
https://sonarcloud.io/summary/overall?id=jhipster_jhipster-lite

authors: murdos qmonmert


text:
Upgrade Couchmove to 2.0

Add Full Text Search Option (see https://github.com/jhipster/generator-jhipster/pull/11421)

@tchlyah Maybe you can review couchbase-client version?

This seems to cause a compilation failure in couchbase + elasticsearch + oauth: https://github.com/jhipster/generator-jhipster/pull/11623/checks?check_run_id=618427010#step:14:53

Might be related: org.apache.commons.codec.binary.Base64 is no longer available. https://github.com/jhipster/generator-jhipster/pull/11623/checks?check_run_id=618427114#step:14:185

I've confirmed that changing the webflux-couchbase project to use v1.1 fixes compilation:
<dependency>
    <groupId>com.github.differentway</groupId>
    <artifactId>couchmove</artifactId>
    <version>1.1</version>
</dependency>

Therefore, I'm reverting this change.

sorry @mraible I didn't saw your message soon enough. This update is meant for the Couchbase Full Text Search option, and https://github.com/jhipster/generator-jhipster/pull/11421 fixes the issue.
I don't think that reverting this is a good solution since we are using here a transitive dependency and we shouldn't rely on it, it's better to add directly the dependency as we do for cassandra. This what I did here https://github.com/jhipster/generator-jhipster/pull/11421/commits/a730bd20dbe58f3f2367612309faf66fa9d4c929.
I can separate the fix from the FTS PR if you don't want to wait for its review.

I can separate the fix from the FTS PR if you don't want to wait for its review.

Yes, please do so, because currently master is broken.

Done in https://github.com/jhipster/generator-jhipster/pull/11640, it should be ok

@tchlyah Maybe you can review couchbase-client version?

Done in https://github.com/jhipster/jhipster/pull/680

authors: DanielFran mraible murdos tchlyah

repo: jhipster/jhipster


text:
T2T translate "Something went wrong Connection errored out."

colab 환경에서 해당 레포 clone 후 진행했습니다.
Youtube 탭에서 srt 자막파일 생성은 정상적으로 작동했습니다.
T2T translate 탭에서 자막파일 업로드 후 실행시 위 사진처럼 나오면서 실패합니다. 에러 메시지도 안뱉어서 뭐가 문제인지를 모르겠어요.. ㅜ

안녕하세요 @fullyanthorney 님. 방금 코랩에서 에러를 재생산하려고 해봤습니다.
코랩 무료버전 (GPU 가 아닌 CPU 버전) 에서 발생하는 문제 같습니다.
무료버전을 사용할 때, nllb 모델이 제대로 다운로드 되지 않습니다.
GPU (A100) 런타임에서 테스트 했을 때, 정상적으로 작동하는 것을 확인하였습니다.

감사합니다!!


text:
Webcamjs undefined

Hi,
I used webcamjs with version 1.0.16 with angular 1.5.9  and everything was fine.
After the update to 1.0.18 the minified & uglified js is broken.
Has anyone an idea how to fix this issue?
A Downgrade  to 1.0.16 or excluding it from the minification process is unacceptable for my employer.
Thank you  in advance

Can you please elaborate?  What do you mean by "broken"?
I tested the 1.0.18 minified version with a variety of web browsers, and webcams, including with and without Flash.  It is working fine for me in all cases.  Please provide more details about the problem you are having, including which browsers and OS versions are affected.
Please provide a test page which shows the bug.

I updated all the live demos to use the minified version of the library (v1.0.18), and I still cannot reproduce any errors in any of them.

Demo Link
Description

Basic Demo
Demonstrates a basic 320x240 image capture.

Large Demo
Demonstrates capturing a large 640x480 image, but showing a live preview at 320x240.

Crop Demo
Demonstrates cropping a 240x240 square out of the center of a 320x240 webcam image.

Large Crop Demo
Demonstrates a large 480x480 square crop, from a 640x480 image capture, with a 240x240 live preview.

HD Demo
Demonstrates a 720p HD (1280x720) image capture (only supported by some webcams).

SFX Demo
Demonstrates a camera shutter sound effect at capture time.

Flash Demo
Demonstrates forcing Adobe Flash fallback mode.

Freeze Demo
Demonstrates freezing / previewing a snapshot before saving it.

Mirror Demo
Demonstrates flipping the image horizontally (mirror mode).

Continuous Demo
Demonstrates continuously capturing images.

Full Combo Demo
A full combination demo showcasing all features.

In order for me to research this issue further, I will need specifics, like the exact error message you are receiving, which OS and browser versions are affected, and a test page that reproduces it.

I just released v1.0.19 using the latest version of UglifyJS (v2.7.5) to minify the library.  Not that it should matter, but just trying it to see.  Let me know if the problem persists.

Hi,
Sounds like I'm having the same problem.  Here is the console error:
ReferenceError: Webcam is not defined
    at webcam (webcam.directive.js:14)
    at Object.invoke (angular.js:4718)
    at angular.js:7778
    at forEach (angular.js:321)
    at Object.<anonymous> (angular.js:7776)
    at Object.invoke (angular.js:4718)
    at Object.enforcedReturnValue [as $get] (angular.js:4557)
    at Object.invoke (angular.js:4718)
    at angular.js:4517
    at Object.getService [as get] (angular.js:4664)
    at addDirective (angular.js:9494)
    at collectDirectives (angular.js:8677)
    at compileNodes (angular.js:8539)
    at compileNodes (angular.js:8555)
    at compile (angular.js:8442)
    at lazyCompilation (angular.js:8838)

Apparently Webcam is no longer a global variable.  I quickly looked through the minified version of the file but can't see why this would be happening.  I'm not using AMD or RequireJS in this project so my code is expecting Webcam on the window.
Thanks!

Thank you @tracyIcebreaker.  Can you also confirm that webcam.js works fine, and only webcam.min.js has the undefined problem?
I've never used Angular, so I don't know how it loads JS libraries.  Are you using a require() style statement to load it, or is it a plain <SCRIPT> tag in your HTML?
Thanks.

Angular should be unrelated in this case - we're using gulp to inject files from bower as script tags into index.html.

Okay, understood @tracyIcebreaker.  I will stop focusing on Angular.  Would it be possible for you to confirm if webcam.js is working in your application?  Is the problem isolated to webcam.min.js?  I am just trying to see if I can isolate the problem to a minification issue, or something in the code itself.  Thanks again for your help.

I'm testing it now.  I copied the contents of webcam.js and replaced the min contents as the most expedient test and I'm having the same problem.  I'll test it by linking the file directly too just to be sure.

The module wrapper code isn't crazy complex. You could simply remove it.
if (typeof define === 'function' && define.amd) {
	define( function() { return Webcam; } );
}
else if (typeof module === 'object' && module.exports) {
	module.exports = Webcam;
}
else {
	window.Webcam = Webcam;
}

I'm not sure how your script injection works, but is it possible that something in your site is defining define or module? This would prevent it from assigning to the window.

Thank you @positlabs, and that is a good point.  I was working off the assumption that WebcamJS v1.0.16 is working fine for everyone (which has the same module wrapper code), but v1.0.18 is somehow broken.  That is what I gleaned from @tom94zoe's initial issue report.

I used webcamjs with version 1.0.16 with angular 1.5.9 and everything was fine.
After the update to 1.0.18 the minified & uglified js is broken.

Perhaps @tracyIcebreaker has a different issue altogether.

@jhuckaby @positlabs apologies, it looks like it's a different issue altogether.  For some reason webcam.min.js is not being injected into my index.html page.  All the other bower scripts are being injected as per normal, and if I roll back to an earlier version of webcamjs it is injected correctly.  The older version I'd been testing against earlier today was 1.0.6, but I'll test and see which version stops getting injected correctly by my gulp script.

Did you say you were using bower @tracyIcebreaker?  Uh oh... at some point I removed the bower.json file from the repository, as I honestly thought no one was using it anymore.  I wonder if that is the problem...
https://github.com/jhuckaby/webcamjs/commit/e32f26dcf5e366e722766d7b3d9b5271518b7d15
Committed January 3, 2017 -- released in v1.0.17.
Oops.

That's probably what did it @jhuckaby.  This project has some legacy stuff that should all be converted over to npm but haven't had the time so far.  And ouch, if that's the assumption I better make it a priority.

Yikes!  Okay then.  I wonder if @tom94zoe is using bower too.  He is using Angular, so maybe bower comes with that by default?  Let me bring back that file and release v1.0.20 right away.

No not by default, probably just something built a while back when bower was still a thing.  If you decide to stop supporting it in the future it may be best to remove it from the bower repository altogether.

Oops, didn't realize that commit would auto-close the issue.  Re-opening.

Okay, I released v1.0.20 which brings back the bower.json file.  @tracyIcebreaker and @tom94zoe could you try your apps again, with this new version?
Thanks, and so sorry about this.

@jhuckaby that's fixed it for me, thanks!

Now let me go change all this old stuff over to npm...

I also use bower.
It looks like the new version solves the issue.
Thank you

Awesome, thanks @tom94zoe!  And sorry about that.

No problem, sorry for belated answer and thank you for your help.
fyi & angular users: ng-camera uses bower to manage their dependencies. One of them is webcamjs.

authors: jhuckaby positlabs tom94zoe tracyIcebreaker

repo: jhuckaby/webcamjs


text:
It can‘t compatible with Chinese

I mean the line break doesn't work good when using Chinese characters

@wjling this library is not meant to support other languages, but if you want to submit a PR to add Chinese support i'd be happy to review and merge it!

If I have time I may work on it. Thank you for your response.😄

authors: jhurray wjling

repo: jhurray/SelectableTextView


text:
Jsoup 1.14.3 : self closing tag with and without slash "/>" at the end. It looks like self closing tags could have children, that's wrong.

At Open Source Society Cameroon, we are trying to build a library converting html to js using Jsoup 1.14.3 but I'm facing an issue. In order to reproduce the error, just run this code.
After converting this html code
String selfClosingTagsNotWorking = "<input type=\"text\">\r\n" + "";,
we get the following js code
var img = document.createElement("img");
img.setAttribute("src", "#URL");
img.setAttribute("alt", "image");

var input = document.createElement("input");
input.setAttribute("type", "text");
input.appendChild(img);

The image tag is considered as a child of input tag but it's false. input.appendChild(img)
Let's consider another html code String selfClosingTagsWorking = "<input type=\"text\"/>\r\n" + ""; then the result is
var input = document.createElement("input");
input.setAttribute("type", "text");

var img = document.createElement("img");
img.setAttribute("src", "#URL");
img.setAttribute("alt", "image");

The image tag is NOT considered as a child of input tag, it's correct.
This first example uses a self closing tag input without slash and the second uses the input with slash.
My goal is to get the same result even if the self closing tag doesn't have a slash but it looks like Jsoup 1.14.3 lets self closing tag without slash to have children.

UPDATE
Issue : https://github.com/osscameroon/js-generator/issues/41
It is very important  to understand that there is a bug related to self closing tag in Jsoup library. It looks like self closing tags could have children, that's wrong.
Let's take 2 examples :
<input type="text">
<input type="text"/>
Jsoup considers  <input> and <input/> as self closing tags. Consequently, they should not have children.
But there is something weird with Jsoup, <input> could have children if there is another html tag close to its position, this behavior is incorrect. <input/> could not, this is correct.
In the first example, Jsoup considers  as a child of <input>, this is false.  In the second example, Jsoup doesn't  consider  as a child of <input/>, this is true.
How could you verify that ? Just run the tests and look the logs.
Here is the previous  code with self closing tag issue : https://github.com/osscameroon/js-generator/blob/self-closing-tag-issue/src/main/java/com/osscameroon/jsgenerator/service/ConvertServiceImpl.java
	private String appendChild(JsElement jsElement) {
		StringBuilder generatedCode = new StringBuilder();

		if (jsElement.getElement().children().size() > 0) {
			for (Element child : jsElement.getElement().children()) {
				generatedCode.append(jsElement.getElement().tagName()).append(".appendChild(").append(child.tagName())
						.append(");\n");
			}
		}

		return generatedCode.toString();
	}

In order to correct that, we created a condition to test if the tag is self closing then we do nothing. If it is not self closing and if there are children, only then we append children. Before this change, the only condition was if the element has children as you can see below.
This is why we had self closing tag with the possibility of having children, that's completely wrong.
	private String appendChild(JsElement jsElement) {

		StringBuilder generatedCode = new StringBuilder();

		/*
		 * Please, think twice before deleting this log, it helps to understand what is going on under the hood.
		 * It is really helpful to understand that there is a bug in Jsoup library.
		 *
		 * Let's take an example,
		 *
		 *
		 * <input type="text">
		 *
		 * ------------------------------------------------------
		 *
		 * <input type="text"/>
		 *
		 * Jsoup considers  <input> and <input/> as self closing tags.
		 *
		 * Consequently, they should not have children.
		 *
		 * But there is something weird with Jsoup, <input> could have children if there is another html tag close to its position, this behavior is incorrect.
		 * <input/> could not, this is correct.
		 *
		 * How could you verify that ? Just run the tests and look the logs.
		 *
		 * Here is the previous  code with self closing tag issue : https://github.com/osscameroon/js-generator/tree/self-closing-tag-issue
		 *
		 * In order to correct that, we created a condition to test if the tag is self closing then we do nothing.
		 * If it is not self closing and if there are children, only then we append children.
		 *
		 *  Before this change, the only condition was if the element has children.
		     This is why we had self closing tag with the possibility of having children, that's completely wrong.

		 *  Useful links:
		 *
		 *  https://www.educba.com/types-of-tags-in-html/

		    https://www.tutorialstonight.com/self-closing-tags-in-html.php#:~:text=HTML%20Self%20Closing%20Tag,%2C%20etc.

		 * */

		logger.log(Level.FINEST, " **** Analyze jsElement :"+jsElement.getElement().tag().getName()
				+" -> isEmpty : "+ jsElement.getElement().tag().isEmpty()
				+" -> isSelfClosing : "+ jsElement.getElement().tag().isSelfClosing()
				+" -> isKnown : "+ jsElement.getElement().tag().isKnownTag()
				+ " -> hasChild : "+ jsElement.getElement().childrenSize()+ " **** ");

		if(jsElement.getElement().tag().isSelfClosing()) {

		}else {

			if (jsElement.getElement().children().size() > 0) {

				for (Element child : jsElement.getElement().children()) {

					generatedCode.append(jsElement.getElement().tagName()).append(".appendChild(").append(child.tagName())
							.append(");\n");
				}
			}

		}

		return generatedCode.toString();
	}

Useful links:
https://www.educba.com/types-of-tags-in-html/
https://www.tutorialstonight.com/self-closing-tags-in-html.php#:~:text=HTML Self Closing Tag,%2C etc.

I reopened the issue because I solved that on my side but there is still a problem related to how Jsoup deals with self closing tag with and without slash.

I can't follow this issue. HTML5 does not require a trailing / to make an empty tag. If you think there is an issue in the parser, please provide a simple example on https://try.jsoup.org/ . The examples using generated code make this more complex.

Hi @jhy ,
Thanks for reviewing this issue.
Sorry, I changed the title because it was confusing.
Yes, HTML5 does not require a trailing / to make an empty tag.
I was trying to explain the problem we faced with Jsoup API.
Our goal is not to parse HTML to get a parsed HTML as output  as it is done here https://try.jsoup.org/ but we are using Jsoup to turn HTML elements into Java Objects (  Node, Element and TextNode from Jsoup ) then our app turns these Java Objects  into JavaScript variables.
While working, we noticed that if there are 2 self closing tags following each other then the 2nd one is considered as the child of the 1st one. To be more precise, we also noticed that when the 1st one has slash at the end then everything is correct but when the 1st one doesn't have slash, we got this issue. It is impossible to see that here https://try.jsoup.org/ . The only way to see that is to deeply analyze the code to get a better idea on how things work under the hood.
I will provide a better way to reproduce this issue asap

authors: FanJups jhy

repo: jhy/jsoup


text:
finish GenerateKGroups

Others

APIs

Finish GenerateKGroups

Already merged in local environment


text:
could stable-ts  support returning plain text content？

could stable-ts  support returning plain text content, while i don't need the time info like this "00:00:01,500 --> 00:00:01,620".
thank you!!!

In python, after exporting the result in srt with result.to_srt_vtt('audio.srt'), you can use a simple function using pysrt:
pip install pysrt
import pysrt

def get_text_from_srt(srt_path):
    subs = pysrt.open(srt_path)
    plain_text = ' '.join(sub.text for sub in subs)
    return plain_text

and use it like this:
plain_text = get_text_from_srt('audio.srt')
print(plain_text)

You can use .to_txt() that was added in 900797a90a35b09fef9fe13574e963dc6a58aa56.

repo: jianfch/stable-ts


text:
Why is there a blank value for all nodes?

Check it out. Also, the ValueID is weird. Looks like a Group value...

will reopen if this issue reappears

repo: jimjibone/goopenzwave


text:
Flow canvas errors on open

Describe the bug

After going straight to the Flow Canvas I was presented with the 'Cannot read property 'flowChart' of undefined' error.
The error does not go away after refreshing the page.
Have you solved it? If so, let us know how!

Environment

Screenshots and logs

Contents of the Local storage, user Flows object
{
"5ytzJSuTgRF7wA_nTXcXs": {
"isConnected": false,
"name": "Custom Flow 3",
"type": "user-generated",
"flowChart": {
"with": {
"read_only": true,
"rest_api": true,
"port_expose": "$JINA_PORT",
"board": {
"canvas": {
"gateway": {
"x": 250,
"y": 150
},
"chunk_seg": {
"x": 250,
"y": 268
},
"tf_encode": {
"x": 250,
"y": 420
},
"chunk_idx": {
"x": 250,
"y": 600
},
"ranker": {
"x": 250,
"y": 836
},
"doc_idx": {
"x": 249,
"y": 985
}
}
}
},
"elements": [
{
"id": "gateway",
"type": "gateway",
"data": {
"label": "gateway",
"depth": 0
},
"position": {
"x": 250,
"y": 187
}
},
{
"id": "chunk_seg",
"type": "pod",
"data": {
"uses": "pods/craft.yml",
"parallel": "$PARALLEL",
"needs": [
"gateway"
],
"label": "chunk_seg",
"depth": 1
},
"position": {
"x": 250,
"y": 289
}
},
{
"id": "tf_encode",
"type": "pod",
"data": {
"uses": "pods/encode.yml",
"parallel": "$PARALLEL",
"timeout_ready": 600000,
"needs": [
"chunk_seg"
],
"label": "tf_encode",
"depth": 2
},
"position": {
"x": 250,
"y": 383
}
},
{
"id": "chunk_idx",
"type": "pod",
"data": {
"uses": "pods/chunk.yml",
"separated_workspace": true,
"polling": "all",
"uses_reducing": "_merge_all",
"timeout_ready": 100000,
"needs": [
"tf_encode"
],
"label": "chunk_idx",
"depth": 3
},
"position": {
"x": 250,
"y": 492
}
},
{
"id": "ranker",
"type": "pod",
"data": {
"uses": "BiMatchRanker",
"needs": [
"chunk_idx"
],
"label": "ranker",
"depth": 4
},
"position": {
"x": 250,
"y": 583
}
},
{
"id": "doc_idx",
"type": "pod",
"data": {
"uses": "pods/doc.yml",
"needs": [
"ranker"
],
"label": "doc_idx",
"depth": 5
},
"position": {
"x": 250,
"y": 685
}
},
{
"id": "e-gateway-to-chunk_seg",
"source": "gateway",
"target": "chunk_seg",
"type": "step"
},
{
"id": "e-chunk_seg-to-tf_encode",
"source": "chunk_seg",
"target": "tf_encode",
"type": "step"
},
{
"id": "e-tf_encode-to-chunk_idx",
"source": "tf_encode",
"target": "chunk_idx",
"type": "step"
},
{
"id": "e-chunk_idx-to-ranker",
"source": "chunk_idx",
"target": "ranker",
"type": "step"
},
{
"id": "e-ranker-to-doc_idx",
"source": "ranker",
"target": "doc_idx",
"type": "step"
},
{
"id": "e-chunk_seg-to-gateway",
"source": "chunk_seg",
"target": "gateway",
"type": "step"
},
{
"id": "e-chunk_seg-to-gateway",
"source": "chunk_seg",
"target": "gateway",
"type": "step"
},
{
"id": "e-chunk_seg-to-gateway",
"source": "chunk_seg",
"target": "gateway",
"type": "step"
},
{
"id": "e-chunk_seg-to-gateway",
"source": "chunk_seg",
"target": "gateway",
"type": "step"
},
{
"id": "e-tf_encode-to-chunk_seg",
"source": "tf_encode",
"target": "chunk_seg",
"type": "step"
}
]
}
}
}

repo: jina-ai/dashboard


text:
Calculate the uptime and display on the status page

[ ] calculate the uptime and store in $DATA_PATH
[ ] display uptime on the page

Reference
https://docs.google.com/drawings/d/1C4B4DOAvG2YTFW5TUOjhlnSEGv-ZNWtlsMXKnCZFXaY/edit

@@ -28,7 +28,9 @@ class Project:
     repo: str
     name: str
     host: str
+    uptime: int = 0
     status: Status = Status.AVAILABLE
+    ctime: datetime = datetime.now()
     last_utime: datetime = datetime.now()  # last health check time
     last_dtime: Optional[datetime] = None  # last down time
     history: List[HealthCheckEvent] = field(default_factory=lambda: [])
@@ -112,6 +114,8 @@ async def _health_check(project, session):
             if matches is None:
                 print(f'{project.host} empty matches: {json_body}')
             project.status = Status.AVAILABLE if matches else Status.UNAVAILABLE
+            if project.status == Status.AVAILABLE:
+                project.uptime += 1
             project.history.append(HealthCheckEvent(ctime=datetime.now(), status=project.status))
             return project
     except ClientConnectorError as e:
@@ -149,7 +153,8 @@ def write_to_markdown(projects):
             p.repo,
             '✅' if p.status == Status.AVAILABLE else '⛔',
             p.last_utime.isoformat(),
-            p.last_dtime.isoformat() if p.last_dtime is not None else 'None'
+            p.last_dtime.isoformat() if p.last_dtime is not None else 'None',
+            f'{calculate_uptime(p)} (since {p.ctime})'
         ])

     table_header = 'DocsQA Status'

repo: jina-ai/docsQA-status


text:
[(LIVE.FREE)] Matias vs Ramirez Live stream Free in Puerto Rico: How to Watch the Boxing Card Online

Matias vs Ramirez results, start time, live stream, main event, undercard
Subriel Matias vs Roberto Ramirez live results from Coliseo Ruben Rodriguez in Bayamon, Puerto Rico
Subriel Matias and Roberto Ramirez at the press conference ahead of their bout at Coliseo Ruben Rodriguez in Bayamon, Puerto Rico | X/PPV_com
This post may contain affiliate links. We earn a commission, with no extra cost to you, if you use those links to make a purchase.
Subriel Matias faces Roberto Ramirez live on PPV from Coliseo Ruben Rodriguez in Bayamon, Puerto Rico on November 9. The pair squares off in the scheduled for 10 rounds main event at super lightweight.
Puerto Rico’s former world champion Matias (20-2, 20 KOs) looks to get back in the win column, after he lost his IBF 140 lbs title by unanimous decision against Liam Paro in June. San Diego-based Mexican Ramirez (26-3-1, 19 KOs) defeated Rodolfo Flores Moreno via seventh-round TKO last December and secured his third straight victory.
Among the Matias vs Ramirez undercard bouts, Alfredo Santiago (15-2, 6 KOs) of the Dominican Republic defends his NABO super lightweight title in a 10-rounder against Pedro Campa (36-3-1, 24 KOs) of Mexico. As well, Jeyvier Cintron (12-1, 6 KOs) of Puerto Rico and Rashib Martinez Valadez (23-3-1, 11 KOs) of Mexico battle it out for the vacant WBO International bantamweight strap.
Plus, Obimael Ortiz (10-1-1, 5 KOs) of Puerto Rico and Mexico’s Kevin Gonzalez (27-1-1, 14 KOs) go head-to-head in a 10-rounder at super bantamweight. In another 10-round Puerto Rico vs Mexico showdown, Luis J Rodriguez (13-0, 11 KOs) and Marcos Vazquez Rodriguez (20-1-1, 10 KOs) clash at super middleweight.
Watch on PPV.com
Subriel Matias vs Roberto Ramirez results
Get Subriel Matias vs Roberto Ramirez full fight card and stay tuned for live results below.
(6 pm ET / 3 pm PT)
Subriel Matias vs. Roberto Ramirez
Abimael Ortiz vs. Kevin Gonzalez
Jeyvier Cintron vs. Rashib Martinez Valadez
Alfredo Santiago vs. Pedro Campa
Luis J Rodriguez vs. Marcos Vazquez Rodriguez

gfht

repo: jina-ai/reader


text:
Support cloudsqlpostgres dialect

This is needed for proper cloud sql proxy.
see https://github.com/GoogleCloudPlatform/cloudsql-proxy and https://github.com/GoogleCloudPlatform/cloudsql-proxy/blob/master/proxy/dialers/postgres/hook_test.go for details.
With this patch the gorm dialect of cloudsqlpostgres is recognised as postgres.
Make sure these boxes checked before submitting your pull request.

[X] Do only one thing
[X] No API-breaking changes
[X] New code/logic commented & tested
Does not look like a unit testable commit.
[X] Write good commit message, try to squash your commits into a single one
[] Run ./build.sh in gh-pages branch for document changes

For significant changes like big bug fixes, new features, please open an issue to make a agreement on an implementation design/plan first before starting it.
Thank you.
What did this pull request do?

thank you for your PR

After I add the driver I get the following error
dbConn, err = gorm.Open("cloudsqlpostgres", connectionString)

unknown driver "cloudsqlpostgres" (forgotten import?)
Any idea?

@eikebartels have you imported the CloudSQL dialer?
_ "github.com/GoogleCloudPlatform/cloudsql-proxy/proxy/dialers/postgres"

authors: anurag cgestes eikebartels jinzhu

repo: jinzhu/gorm


text:
🛑 Bodensee is down

In 5553423, Bodensee ($BODENSEE_URL) was down:

HTTP code: 0
Response time: 0 ms

Resolved: Bodensee is back up in a5bd106.

repo: jiong-zhu/upptime


text:
Issues with service IPs on loopback interfaces

Hi,
we tried to set up Jitsi on boxes which are connected to an IP Fabric and therefore have their system / service IP configured on the loopback interfaces. It turns out for some reason there are explicit checks in the code to ignore IPs configured on the loopback interfaces so the following configuration does not work:
auto lo
iface lo inet loopback
    address 192.0.2.23/32
    address 2001:db8::2342/128

Digging through the code it seems you are check for the usual loopback interface where 127/8 + ::1/128 lives. So it turns out the following config does work (when announcing the IPs into the fabric as well):
auto lo
iface lo inet loopback

auto yolo
iface yolo
    link-type dummy
    #
    address 192.0.2.23/32
    address 2001:db8::2342/128

Is there any reason to not allow IPs configured on the loopback interface? Why does the library care about the network config on the host?
Best
Max

I think the code was meant to avoid needlessly listening on and advertising loopback addresses. We've just never used it in a situation where a loopback interface has useful addresses. A patch to allow use of loopback interfaces would be welcome, just put it behind a property and preserve the current behavior as default.

authors: BarbarossaTM bgrozev


text:
Don't crash when the audited model doesn't have an admin page

Currently, auditlog tries to generate links to the referenced instance sections in the admin, but sometimes the instances aren't enabled in the admin. auditlog should probably catch that exception and not generate a link.

Good catch. Are you willing to write a fix and submit a PR for that?
I'll hold back the next bugfix release just a few days in case you decide to submit a PR soon, otherwise this will have to be included in the next release.

I'll see if I can do that quickly, thank you.

Submitted, let me know!

If the user model is not enabled in admin, the user_url function will fail similarly. I think the same try-catch fix should be applied to that function too.

authors: amiraliakbari jjkester skorokithakis

repo: jjkester/django-auditlog


text:
Need an update for Nim V2

Hello world. This lib is not working on Nim Version 2. I've managed to make it work, but since I'm not the author, I'm not sure if my patches are good enough for a PR.

Hi, are you able to submit a PR for it anyway for reference? Personally I haven't been able to get it working on Nim 2...


text:
Update database structure

The database structure is not perfect in current state. There is a lot of improvements to be done. Below list is a few:

Collect number of games played
Collect other data that I havn't though of (date and time when played) location? etc. etc.
Fix google id bug. Sometimes when submitted score from different platforms the database creates two users

Fixed in #30

repo: jkkronk/Roadtrip-Riddle-Web


text:
Private name mappings (Imports)

The proposal currently lists a secondary imports field. This hasn't been implemented anywhere afaik. We should decide what the solution for that use case is.

The suggestions I'm aware of are:

Don't do anything. Packages that want to remap individual files can use self-reference and public entries in their exports fields.
Implement a new field (imports), roughly with the spec in the current README.
Introduce a new sigil in exports that can only be used in self-reference.
Introduce a new condition that only applies in self-reference.

My personal preference is to build on top of self-reference and conditionals and use a new condition to express this.
Imports
"name": "pkg",
"imports": { "#fetch": "./lib/fetch" }

import '#fetch'; // only visible to code within the package boundary

Exports Sigil
"name": "pkg",
"exports": { "#fetch": "./lib/fetch" }

import 'pkg#fetch'; // only visible to code when using self-reference imports

Exports Condition
"name": "pkg",
"exports": { "./fetch": { "internal": "./lib/fetch" } }

import 'pkg/fetch'; // only visible to code when using self-reference imports

If you look at the example posted in https://github.com/uuidjs/uuid/pull/462#issuecomment-637854269 the first thing one notices is that "exports" is already more verbose than the browser field (and obviously because it carries the ability to hold more information than just browser mappings).
If we use an internal condition name I would be concerned with the level of verbosity in that case, since the internal mapping would then need to additionally compose with the browser mapping and any other mappings, leading to quite deep nesting.
I think it would be beneficial to try and ship something here especially given the resistance @sokra indicated to wanting to implement private mappings on the public API.
I would like to suggest that a variation on the sigil to use a ./# syntax:
{
  "name": "uuid",
  "exports": {
    "./#dist/md5.js": {
      "browser": "./dist/md5-browser.js",
      "default": "./dist/md5.js"
    },
    "./#dist/rng.js": {
      "browser": "./dist/rng-browser.js",
      "default": "./dist/rng.js"
    },
    "./#dist/sha1.js": {
      "browser": "./dist/sha1-browser.js",
      "default": "./dist/sha1.js
    }
  }
}

By retaining the leading ./ we make it clear these are still subpath mappings leaving room for other types of "internal bare specifier" mappings in future as we have so carefully reserved to date as well.
Usage would be via import 'pkg/#internal' so remains fully symmetric with standard exports behaviour.
Note: this variation of the feature is fully valid under current exports - you can ship it now and it will work in Node.js.
That is, the # doesn't change anything else semantically apart from just the private restriction for non internal importers!

Updated the sigil bit to include the ./. The exports sigil would definitely be my 2nd choice and those specifiers are "ugly" enough that they're pretty obviously not an official (public) API.

The nice thing is that private names are well-enough adopted now for the meaning to be obvious to JS users.

Using # is not a good idea in my opinion. They have a special meaning in URLs (which these requests are): fragments. We would probably run into problems when trying to translate the exports field into an importMap.

Something like that would also be possible:
"name": "pkg",
"exports": { "#/fetch": "./lib/fetch.mjs" }
"exports": { "#./fetch": "./lib/fetch.mjs" }

import 'pkg/fetch'; // only visible to code when using self-reference imports

So to summarize my wishlist would be:

clearly visible in import that it's private
different name than exports as it's not the public api
not using #, ?, + or % as thats reserved in urls
support for conditions like exports
key in mappings object is equal to request in `import "..."
similar syntax as exports
not colliding with absolute paths
not colliding with possible npm package names
support directory mappings like exports

It's only a wishlist, I'm also fine if not everything works.
Here are some options that would fullfill that:

import "@/fetch"
import "_/fetch"
import "[fetch]" and other brackets <>, {}, ()
import "$/fetch"
import "$fetch"
import "*fetch"
~import "*/fetch"~ (could be confused with globs)
import ":fetch"
import "|fetch"
~import "~/fetch"~ (often used as reference to app directory)
~import "~fetch"~ (often used as reference to app directory)
import "^fetch"
import "^/fetch"

They have a special meaning in URLs (which these requests are): fragments. We would probably run into problems when trying to translate the exports field into an importMap.

A clarification here: The bare specifiers in import maps aren't URLs and # should be valid in bare specifiers unless import maps chooses to disallow them in the future. So far the direction of import maps has been to not put any restrictions on bare specifiers.
The # would be an issue on the right side (the mapping to a URL) but on the left side I don't expect problems with import maps as things stand.

Yes I can confirm that # works in Node.js and browsers today with the current import maps and exports field implementations. That actually in many ways makes it a preferable option since it means it is definitely not a URL and hence can only exist in the "virtual space" of the LHS side of the export map.
I also really like the backwards compatibility approach to implementation that came up here.

If that's the case that's great and I'll take back my critique on that. In this case I prefer the "imports" field.

My preference is for the "Exports Sigil" where exports uses LHS ./#fetch and code uses import 'pkg/#fetch'.  My complaint with import '#fetch' is that it could create difficulty if using minimatch on specifiers since a string starting with # is treated as a comment.  I agree with @guybedford about the internal condition, I think it would be best to avoid adding more nesting to the exports structure.
Can we specifically mention that deep private exports work?  For example "./#/": "./" and import 'pkg/#/private/file.js'.
One detail this "Exports Sigil" works today but is not restricted to self-reference.
{
  "name": "pkg",
  "version": "0.1.0",
  "exports": {
    "./#/": "./",
    "./#package.json": "./package.json"
  }
}

This package.json allows the following from inside or outside pkg:
console.log('via "./#/" export', require('pkg/#/package.json'));
console.log('via "./#package.json" export', require('pkg/#package.json'));

This is a good and bad thing.  Technically making "./#/": "./" a private export is breaking, but on the other hand it would allow use of internal self-reference from any versions of node.js with self-reference.

I've put together a PR here in https://github.com/nodejs/node/pull/33780. Feedback welcome.

authors: coreyfarrell guybedford jkrems sokra

repo: jkrems/proposal-pkg-exports


text:
Add supports for lang parameter

This allow to initialize the Document class with a lang that will be passed to tesseract.
(Giving tesseract a language sometimes greatly improve text extraction quality).
On ubuntu this requires to install the package tesseract-ocr-$lang$ where $lang$ is the 3 letter code for the language. On other OS, lang data for tesseract can be found at https://github.com/tesseract-ocr/langdata

@jlsutherland Sorry, my branch also include my commit for #17 ... The only relevant commit here is 5d9b0a8

This is a nice feature add. Thanks @rcatajar!

authors: jlsutherland rcatajar


text:
Service Cloud Alerts

As a Service Cloud rep,
Given an at danger, warning or info scenario,
I want to associate an Alert to Contact and/or Account
So that I can see important system notifications when I am working a Contact or Account.

Alerts by Type { Danger, Warning, Info }
Red, Orange, Blue respectively.
Display in Accordion by type. Accordion Section Headers colored by type { Red, Orange, Blue }

All Danger Alerts in a Danger Accordion section
All Warning Alerts in a Warning Accordion section
All Info Alerts in an Info Accordion section

Alerts within a given section are a Tile List
Tiles display Alert Title and Message
Clicking a Tile opens the Alert
https://developer.salesforce.com/docs/component-library/bundle/lightning-tile/example
If any Alerts of any types exist, fire a toast that matches in color to the highest priority Alert on the record.
On Contact, if any Alerts are associated to their parent Account, display those Alerts as well.


text:
Language features not working?

I have installed this config as stated, and all seems to work except for the LSP features and other language features such as definitions, types, etc. When I try to run manually the language features it says there are no supported language servers, but they are all correctly installed. Any idea?

Forget it. My computer is too slow and I have no time to learn Lua.

repo: jmbuhr/quarto-nvim-kickstarter


text:
Adding custom claims to JWTAuthenticator?

First, thanks for building this library.
I'm using a JWTAuthenticator and it works great.  I want to add custom claims object to pass some information client side.  Since AuthenticatorService.create is implementation agnostic the best option I can think of is to make some sort of method which constructs JWT's a la https://jmcardon.github.io/tsec/docs/jwt-mac.html and avoid using JWTAuthenticator.create.  Is this your take as well?
The docs could use a blurb on this, you open to contributors?

Hi, thanks for opening an issue! Yes, we welcome any and all contributors to this project.
Re: custom claims, I believe could be related to #59 (I think that issue means claims and not headers).
As far as this issue: this is open to discussion. Passing information inside an authentication token raises a flag in my head. I mean, tokens are sent along with every request, so sending arbitrary info in the claims will increase the network load and make token creation/verification slower based upon how much data you want to put in there.
In tsec, the philosophy tends to be along the lines of "prevent people from shooting themselves in the foot". This opens users up to doing something they really shouldn't be doing unless they have a good reason to.
So I'm lukewarm on this. I'd like to hear your reasoning behind it (i.e maybe you're doing your own verification of the JWT on the client). If it's something that is a common enough, then I'll incline to agree. Alternatively, you can open a PR anyway and we can review the use case :+1:
Pinging @hrhino for a second opinion here.

oh and re: the docs, there I 100% agree, maybe we could be more informative that we're a tad opinionated on how we create tokens.

The use case I'm wanting to support is to include encoding role information into the jwt, and create authorization middleware that can get role information from a jwt.  As far as I understand, use cases like this are the raison d'etre for custom claims.

Is there any particular reason you cannot get the role information from the user object in the backing store? Authorization in tsec is appled after authentication, so you don't need to extract it from the jwt at all if your authorization info is attached to your user model. It would be redundant information (unless you want to have the user role information authenticated).
All authenticators currently have to go through a user store. This is the main thing that makes it redundant. I do think custom claims in the JWT need to be added, but I'm unsure whether this is common enough use case to be a standard.
That said I'm open to a PR to see what you have in mind. Im unsure how to alter the abstraction for your use case currently.

Is there any particular reason you cannot get the role information from the user object in the backing store? Authorization in tsec is appled after authentication, so you don't need to extract it from the jwt at all if your authorization info is attached to your user model. It would be redundant information (unless you want to have the user role information authenticated).

That's a fair point.  For my use case the JWT already contains the state I care about: the sub claim and potentially a role-like claim.  The service consuming the jwt doesnt have access to the real user store. In some ways JWTAuthenticator.stateless is a  bit misleading since it does require an impl of BackingStore.get.
Feel free to close this!

Oh I guess. Feel free to submit a docs change if you feel it is appropriate.
In a sense, what i meant to say is the token itself is stateless. Stateful token would imply the token itself has a backingstore, not just the user.
If you want custom behavior, in a sense, the only way to extract the user would be by encoding the information into the claim itself. Im not against adding a purely stateless implementation at all.
What do you think? I'm for it, but it seems like more of a custom use case

authors: jmcardon parsnips

repo: jmcardon/tsec


text:
Unable to generate bindings/reflection data

EDIT: Ok the second part seems to be some sort of a regression in current Nim-Devel writeFile. The file does get written out even with the index not in range exception. :) So just the first part of this issue is relevant.

Two issues I've found (current devel):

IsRunningCommandlet as defined in this commit

is always false, so genBindingsEntryPoint() doesn't do anything. I've changed it to
proc isRunningCommandlet*() : bool {.importcpp:"IsRunningCommandlet" .}

and all the relevant call sites and seems to work as expected.

generateProject() fails with the following error:

[2023.07.06-08.48.21:196][  1]NimForUEBindings: [genreflectiondatav2.nim:596]: All module names@["NimTemplate", "NimForUE", "NimForUEBindings", "NimForUETest", "NimForUEEditor", "ModelingToolsEditorMode", "Engine/Exporters", "Engine/EdGraph", "Engine/Atmosphere", "Engine/Sound", "Engine/AI", "Engine/Kismet", "Engine/Camera", "Engine/GameFramework", "Engine/Components", "Engine/Animation", "Engine/VT", "Engine/Elements", "Engine/Slate", "Engine/Instances", "Engine/ISMPartition", "Engine/SparseVolumeTexture", "Engine/Engine", "Engine/Materials", "Engine/Net", "Engine/Enums", "Engine/DataDrivenCVars", "Engine/Particles", "Engine/PhysicsEngine", "Engine/Haptics", "Engine/ActorPartition", "Engine/Delegates", "Engine/Commandlets", "Engine/PhysicalMaterials", "Engine/Lightmass", "Engine/EditorFramework", "Engine/Physics", "Engine/Distributions", "Engine/Curves", "Engine/WorldPartition", "Engine/VectorField", "Slate", "SlateCore", "PhysicsCore", "Chaos", "InputCore", "UMG/Slate", "UMG/FieldNotification", "UMG/UMG", "UMG/Components", "UMG/Animation", "UMG/Delegates", "UMG/Enums", "UMG/Blueprint", "GameplayAbilities/GameplayAbilities", "GameplayAbilities/Serialization", "GameplayAbilities/Abilities", "GameplayAbilities/Delegates", "GameplayAbilities/Enums", "GameplayAbilities/Sequencer", "EnhancedInput", "AssetRegistry", "Engine/Common"]
[2023.07.06-08.48.21:442][  1]NimForUEBindings: Error: [ffinimforue.nim:66]: Error in genBindingsEntryPoint: index -1 not in 0 .. 88
[2023.07.06-08.48.24:449][  1]LogCore: Engine exit requested (reason: Commandlet GenerateBindingsCommandlet_0 finished execution (result 0))
[2023.07.06-08.48.24:450][  1]LogInit: Display:
[2023.07.06-08.48.24:450][  1]LogInit: Display: Warning/Error Summary (Unique only)
[2023.07.06-08.48.24:450][  1]LogInit: Display: -----------------------------------
[2023.07.06-08.48.24:450][  1]LogInit: Display: NimForUEBindings: Error: [genreflectiondatav2.nim:473]: CodeGenOnlyUEImportRule(affectedTypes: @["AActor", "AInfo", "UReflectionHelpers", "UObject", "UEngine", "APawn", "UField", "UStruct", "UScriptStruct", "UPackage", "UPackageMap", "UClass", "UFunction", "UDelegateFunction", "UEnum", "AVolume", "UInterface", "UActorComponent", "AController", "AGameMode", "AGameModeBase", "UBlueprint", "UBlueprintGeneratedClass", "APlayerController", "UAnimBlueprintGeneratedClass", "UEngineSubsystem", "USubsystem", "UDynamicSubsystem", "UWorldSubsystem", "USceneComponent", "UPrimitiveComponent", "UWorld", "UInputComponent", "UEnhancedInputComponent", "UInputAction", "UPlayerInput", "UEnhancedPlayerInput", "UPhysicalMaterial", "UTickableWorldSubsystem", "UGameViewportClient", "UNavigationSystemConfig", "UNavigationSystemModuleConfig", "UFunctionCaller", "FNativeFuncPtr", "UNimScriptStruct", "UNimScriptStructPtr", "UNimEnum", "UNimEnumPtr", "UNimFunction", "UNimFunctionPtr", "UReflectionHelpers", "UReflectionHelpersPtr", "FNimTestBase", "FNimHotReload", "FNimHotReloadPtr", "FField", "FFieldPtr", "FProperty", "FPropertyPtr", "FFieldClass", "FFieldClassPtr", "FFieldPath", "UObject", "UObjectPtr", "UField", "UFieldPtr", "UEnum", "UEnumPtr", "UStruct", "UStructPtr", "FObjectInitializer", "FReferenceCollector", "UClassConstructor", "VTableConstructor", "FOutParmRec", "FFrame", "UClassAddReferencedObjectsType", "UFunctionNativeSignature", "FImplementedInterface", "FUObjectCppClassStaticFunctions", "UClass", "UClassPtr", "UInterface", "UInterfacePtr", "UScriptStruct", "UScriptStructPtr", "ICppStructOps", "ICppStructOpsPtr", "UFunction", "UFunctionPtr", "UDelegateFunction", "UDelegateFunctionPtr", "TObjectPtr", "TLazyObjectPtr", "TEnumAsByte", "TWeakObjectPtr", "TScriptInterface", "UWorld", "UWorldPtr", "ConstructorHelpers", "FObjectFinder", "FClassFinder", "TSubclassOf", "TFieldPath", "FVTableHelper", "FPropertyChangedEvent", "FPropertyChangedChainEvent", "FObjectPostSaveRootContext", "FScriptArray", "FScriptArrayHelper", "FScriptMap", "FScriptMapHelper", "FScriptMapLayout", "FFieldVariant", "DelegateProp", "ERenameFlag", "TFieldIterator", "FRawObjectIterator", "ScriptContainer", "FAssetBundleData", "FAssetBundleEntry", "FSoftObjectPath", "FAssetData", "FAutomationEvent", "FGuid", "EAutomationEventType", "FAutomationExecutionEntry", "FDateTime", "FBox", "FBox2D", "FVector2D", "FBox2f", "FVector2f", "FBox3d", "FVector3d", "FBox3f", "FVector3f", "FBoxSphereBounds", "FBoxSphereBounds3d", "FBoxSphereBounds3f", "FColor", "FDirectoryPath", "FFallbackStruct", "FFilePath", "FFloatInterval", "FFloatRange", "FFloatRangeBound", "ERangeBoundTypes", "FFrameNumber", "FFrameNumberRange", "FFrameNumberRangeBound", "FFrameRate", "FFrameTime", "FInt32Interval", "FInt32Range", "FInt32RangeBound", "FInterpCurveFloat", "FInterpCurvePointFloat", "EInterpCurveMode", "FInterpCurveLinearColor", "FInterpCurvePointLinearColor", "FLinearColor", "FInterpCurvePointQuat", "FQuat", "FInterpCurvePointTwoVectors", "FTwoVectors", "FInterpCurvePointVector", "FInterpCurvePointVector2D", "FInterpCurveQuat", "FInterpCurveTwoVectors", "FInterpCurveVector", "FInterpCurveVector2D", "FIntPoint", "FIntVector", "FMatrix", "FPlane", "FMatrix44d", "FPlane4d", "FMatrix44f", "FPlane4f", "FOrientedBox", "FPackedNormal", "FPackedRGB10A2N", "FPackedRGBA16N", "FPolyglotTextData", "ELocalizedTextSourceCategory", "FPrimaryAssetId", "FPrimaryAssetType", "FQualifiedFrameTime", "FQuat4d", "FQuat4f", "FRandomStream", "FRotator", "FRotator3d", "FRotator3f", "FSoftClassPath", "FTestUninitializedScriptStructMembersTest", "FTimecode", "FTimespan", "FTransform", "FTransform3d", "FTransform3f", "FVector4", "FVector4d", "FVector4f", "ELifetimeCondition", "ELifetimeRepNotifyCondition", "ESearchCase", "ESearchDir", "ELogTimes", "EAxis", "EPixelFormat", "EMouseCursor", "EUnit", "EPropertyAccessChangeNotifyMode", "EAppReturnType", "EAppMsgType", "EDataValidationResult", "UPackage", "UPackagePtr", "TSoftObjectPtr", "TSoftClassPtr", "FName", "EName", "FMulticastScriptDelegate", "FScriptDelegate", "FStaticConstructObjectParameters", "UMetadata", "UMetadataPtr", "TChar", "FString", "TArray", "TPair", "TMap", "TSet", "ELogVerbosity", "FVector", "FVector_NetQuantize", "FVector_NetQuantizeNormal", "FVector_NetQuantize100", "FVector_NetQuantize10", "FText", "FWeakObjectPtr", "FDelegateHandle", "FDelegateHandlePtr", "TMulticastDelegateOneParam", "TDelegateRetOneParam", "IAssetRegistry", "UEngine", "UEnginePtr", "USubsystem", "USubsystemPtr", "UDynamicSubsystem", "UDynamicSubsystemPtr", "UEngineSubsystem", "UEngineSubsystemPtr", "FTickFunction", "FActorTickFunction", "AActor", "AActorPtr", "AController", "AControllerPtr", "APlayerController", "APlayerControllerPtr", "APawn", "APawnPtr", "AInfo", "AInfoPtr", "AGameModeBase", "AGameModeBasePtr", "AGameMode", "AGameModePtr", "UActorComponent", "UActorComponentPtr", "USceneComponent", "USceneComponentPtr", "UPrimitiveComponent", "UPrimitiveComponentPtr", "UBlueprint", "UBlueprintPtr", "UBlueprintGeneratedClass", "UBlueprintGeneratedClassPtr", "UAnimBlueprintGeneratedClass", "UAnimBlueprintGeneratedClassPtr", "UAsyncActionLoadPrimaryAssetBase", "UAsyncActionLoadPrimaryAssetBasePtr", "ASceneCapture", "ASceneCapturePtr", "AVolume", "AVolumePtr", "UWorldSubsystem", "UWorldSubsystemPtr", "UTickableWorldSubsystem", "UTickableWorldSubsystemPtr", "FWorldContext", "FWorldContextPtr", "FHitResult", "FLifetimeProperty", "FGameplayTag", "UPackageMap", "UPackageMapPtr", "FKey", "FPlatformUserId", "FTopLevelAssetPath", "FARFilter", "EInputDeviceConnectionState", "FTableRowBase", "FObjectPreSaveContext", "FViewport", "FViewportPtr", "UGameViewportClient", "UGameViewportClientPtr", "FActorInstanceHandle", "UPhysicalMaterial", "UPhysicalMaterialPtr", "UMaterialInterface", "UMaterialInterfacePtr", "UUserDefinedStruct", "UUserDefinedStructPtr", "UNavigationSystemModuleConfig", "UNavigationSystemModuleConfigPtr", "UNavigationSystemConfig", "UNavigationSystemConfigPtr", "FSlateBrush", "EGetWorldErrorMode", "ETriggerEvent", "UInputComponent", "UInputComponentPtr", "UEnhancedInputComponent", "UEnhancedInputComponentPtr", "UInputAction", "UInputActionPtr", "UPlayerInput", "UPlayerInputPtr", "UEnhancedPlayerInput", "UEnhancedPlayerInputPtr", "FEnhancedInputActionEventBinding", "FInputActionValue", "FKeyEvent", "FkeyEventPtr", "FInputKeyEventArgs", "FInputKeyEventArgsPtr", "FInputDeviceId", "EInputEvent", "FOnInputKeySignature", "OnInputKeyEventPressedNimSignature", "OnKeyPressedNimSignature", "EAxisList", "ECollisionChannel", "EObjectTypeQuery", "ETraceTypeQuery", "FActorSpawnParameters", "Criteria", "SomePointer", "SomeTable", "EPropertyFlags", "EObjectFlagsVal", "EObjectFlags", "EFunctionFlags", "EClassFlags", "EClassCastFlags", "EStructFlags", "EFieldIterationFlags"], target: uertType.UERuleTarget, rule: uerCodeGenOnlyFields)
[2023.07.06-08.48.24:450][  1]LogInit: Display: NimForUEBindings: Error: [ffinimforue.nim:66]: Error in genBindingsEntryPoint: index -1 not in 0 .. 88

I've added a bunch of logging to pinpoint the error and it seems to be this piece of code:
writeFile(config.reflectionDataFilePath, codeTemplate % [ueProjectAsStr])

or, rather, more specifically, the string interpolation part: codeTemplate % [ueProjectAsStr].
I could paste the contents of ueProjectAsStr (in a Gist since it is huge) if that would be helpful.
Additional info:
Unreal Engine 5.2.1

@gushromp thanks. This was a regression that I introduced yesterday. Will try to stabilize the template so newcomers can start there and dont suffer that many regressions. Next time send a PR :)

authors: gushromp jmgomez

repo: jmgomez/NimForUE


text:
misc cleanup

Here is a bunch of cleanup I did yesterday while looking at the repo. I didn't have enough time to split the commits up, so I'll try to summarise here the main strokes:

Bumped to dune lang 3.0. Before it was 2.9 which meant that cram tests needed to be manually enabled (the fact that they still partially worked was a bug). In 3.0 cram tests are always enabled so the directory cram tests should work the way you expect.
Many of the tests were a bit nonsense with random files included, so I cleaned those up.
Renabled formatting for dune files, this is something that is useful to have since you don't need to think about it again. Do dune fmt every now and then or stick that in CI.
Generate opam file using Dune package info. All the fields inside the opam file have an equivalent in the dune-project file (which btw you only need one of in this project). The files are generated when you run dune build or specifically dune build @install.
Consolidated the scripts used in the test-suite and added them as dependencies of the cram tests in a single dune file rather than having multiple dune files dotted around. Only issue is that the paths to the scripts had to be adjusted.
Added promoted .exe files to .gitignore

Sorry if I've missed anything.
I tried my best to make sure all the tests looked good, but I think it would be best for you to check it over in case I missed anything.

Great, thanks!
I can see ocaml-ci's (lint-fmt) check is now failing with ocamlformat enabled but no .ocamlformat file!
https://ocaml.ci.dev/github/jmid/mutaml/commit/6741e3335152a4be713780676d7d5c508c7e5ed1/variant/(lint-fmt)
If I remember correctly I think I disabled formatting precisely to silence this error and turn that light green as part of #7:
https://github.com/jmid/mutaml/pull/7/commits/11ea1840bf2aeb333cb9be99aaffd13f7842bc0d
Do you know if it is possible to enable auto-formatting of dune files and still silence the error?
I don't use ocamlformat to format ocaml code, and would prefer to keep it that way for now.

Yes! I'll push such a change. Sorry about that.

Looks good, thanks! Just wanted to let the CI finish :+1:

authors: Alizter jmid

repo: jmid/mutaml