Eslint errors

Do you want to request a feature or report a bug?
Bug
What is the current behavior?
Multiple eslint errors. (excerpt below)
What is the expected behavior?
No eslint errors.
Below are the errors that need to be fixed-
/Users/bsrin2/Documents/CodeBase/XT-Fusion/pages/_document.js
  24:16  warning  Dangerous property 'dangerouslySetInnerHTML' found  react/no-danger

/Users/bsrin2/Documents/CodeBase/XT-Fusion/pages/chart-components.js
  11:1  error  Line 11 exceeds the maximum line length of 100  max-len

/Users/bsrin2/Documents/CodeBase/XT-Fusion/pages/components/Layout.js
  31:19  error  'children' is missing in props validation  react/prop-types

/Users/bsrin2/Documents/CodeBase/XT-Fusion/pages/kitchen-sink.js
  259:36  warning  Unexpected console statement  no-console

/Users/bsrin2/Documents/CodeBase/XT-Fusion/fusion/Alert.js
  11:18  error  'children' is missing in props validation          react/prop-types
  18:9   error  'type' PropType is defined but prop is never used  react/no-unused-prop-types

/Users/bsrin2/Documents/CodeBase/XT-Fusion/fusion/Avatar.js
  10:19  error  'src' is missing in props validation  react/prop-types
  10:24  error  'alt' is missing in props validation  react/prop-types

/Users/bsrin2/Documents/CodeBase/XT-Fusion/fusion/BackgroundImage.js
  3:8  error  'React' is defined but never used  no-unused-vars

/Users/bsrin2/Documents/CodeBase/XT-Fusion/fusion/Badge.js
   3:8   error  'React' is defined but never used                no-unused-vars
   5:7   error  'badgeStyle' is assigned a value but never used  no-unused-vars
  19:1   error  'Badge' is not defined                           no-undef
  31:1   error  'Badge' is not defined                           no-undef
  36:16  error  'Badge' is not defined                           no-undef

/Users/bsrin2/Documents/CodeBase/XT-Fusion/fusion/Banner.js
  18:19  error  'src' is missing in props validation                 react/prop-types
  18:24  error  'alt' is missing in props validation                 react/prop-types
  25:11  error  'picUrl' PropType is defined but prop is never used  react/no-unused-prop-types

/Users/bsrin2/Documents/CodeBase/XT-Fusion/fusion/Blockquote.js
  3:8  error  'React' is defined but never used  no-unused-vars

/Users/bsrin2/Documents/CodeBase/XT-Fusion/fusion/Bounce.js
   6:10  error  'theme' is defined but never used     no-unused-vars
  39:54  error  'alt' is missing in props validation  react/prop-types

/Users/bsrin2/Documents/CodeBase/XT-Fusion/fusion/Button.js
  30:3  error  propType "onClick" is not required, but has no corresponding defaultProp declaration   react/require-default-props
  34:3  error  propType "children" is not required, but has no corresponding defaultProp declaration  react/require-default-props

/Users/bsrin2/Documents/CodeBase/XT-Fusion/fusion/Card.js
  29:41  error  Do not use Array index in keys                                                              react/no-array-index-key
  31:11  error  Do not pass children as props. Instead, nest children between the opening and closing tags  react/no-children-prop
  45:3   error  propType "cardData" is not required, but has no corresponding defaultProp declaration       react/require-default-props

/Users/bsrin2/Documents/CodeBase/XT-Fusion/fusion/Column.js
  13:24  error  'Column' is not defined  react/jsx-no-undef

/Users/bsrin2/Documents/CodeBase/XT-Fusion/fusion/CountdownTimer.js
  19:3   error  timer should be placed after componentDidMount       react/sort-comp
  20:5   error  Split 'const' declarations into multiple statements  one-var
  23:35  error  Unexpected mix of '%' and '/'                        no-mixed-operators
  23:59  error  Unexpected mix of '%' and '/'                        no-mixed-operators
  24:37  error  Unexpected mix of '%' and '/'                        no-mixed-operators
  24:56  error  Unexpected mix of '%' and '/'                        no-mixed-operators
  25:37  error  Unexpected mix of '%' and '/'                        no-mixed-operators
  25:51  error  Unexpected mix of '%' and '/'                        no-mixed-operators
  41:5   error  Do not use setState in componentDidMount             react/no-did-mount-set-state

/Users/bsrin2/Documents/CodeBase/XT-Fusion/fusion/Dialog.js
   72:13  error  Static HTML elements with event handlers require a role                            jsx-a11y/no-static-element-interactions
  101:10  error  'width' PropType is defined but prop is never used                                 react/no-unused-prop-types
  105:11  error  'height' PropType is defined but prop is never used                                react/no-unused-prop-types
  109:7   error  'bg' PropType is defined but prop is never used                                    react/no-unused-prop-types
  113:10  error  'title' PropType is defined but prop is never used                                 react/no-unused-prop-types
  121:3   error  propType "open" is not required, but has no corresponding defaultProp declaration  react/require-default-props
  121:9   error  'open' PropType is defined but prop is never used                                  react/no-unused-prop-types

/Users/bsrin2/Documents/CodeBase/XT-Fusion/fusion/Dropdown.js
   76:3   error  render should be placed after onClick                                              react/sort-comp
   80:1   error  Line 80 exceeds the maximum line length of 100                                     max-len
   80:7   error  Static HTML elements with event handlers require a role                            jsx-a11y/no-static-element-interactions
   86:50  error  'j' is defined but never used                                                      no-unused-vars
  106:10  error  'width' PropType is defined but prop is never used                                 react/no-unused-prop-types
  110:7   error  'bg' PropType is defined but prop is never used                                    react/no-unused-prop-types
  114:10  error  'title' PropType is defined but prop is never used                                 react/no-unused-prop-types
  118:3   error  propType "open" is not required, but has no corresponding defaultProp declaration  react/require-default-props
  118:9   error  'open' PropType is defined but prop is never used                                  react/no-unused-prop-types
  122:3   error  Prop type `array` is forbidden                                                     react/forbid-prop-types

/Users/bsrin2/Documents/CodeBase/XT-Fusion/fusion/Heading.js
  36:7  error  'H4' is assigned a value but never used           no-unused-vars
  43:7  error  'H5' is assigned a value but never used           no-unused-vars
  50:7  error  'H6' is assigned a value but never used           no-unused-vars
  57:7  error  'heading' is assigned a value but never used      no-unused-vars
  81:8  error  'tag' PropType is defined but prop is never used  react/no-unused-prop-types

/Users/bsrin2/Documents/CodeBase/XT-Fusion/fusion/HorizontalBarChart.js
  4:10  error  'theme' is defined but never used  no-unused-vars

/Users/bsrin2/Documents/CodeBase/XT-Fusion/fusion/Link 2.js
  3:14  error  'styled' is not defined  no-undef

/Users/bsrin2/Documents/CodeBase/XT-Fusion/fusion/Link.js
  12:40  error  'React' must be in scope when using JSX  react/react-in-jsx-scope

/Users/bsrin2/Documents/CodeBase/XT-Fusion/fusion/LiveEdit.js
   5:1   error  'react-live' should be listed in the project's dependencies, not devDependencies  import/no-extraneous-dependencies
  54:21  error  'noInline' is missing in props validation                                         react/prop-types
  54:31  error  'code' is missing in props validation                                             react/prop-types

/Users/bsrin2/Documents/CodeBase/XT-Fusion/fusion/Logo.js
  10:1   error  Line 10 exceeds the maximum line length of 100  max-len
  10:43  error  'React' must be in scope when using JSX         react/react-in-jsx-scope

/Users/bsrin2/Documents/CodeBase/XT-Fusion/fusion/Navbar.js
   69:19  error  'NavList' is defined but never used                 no-unused-vars
   74:9   error  Nested block is redundant                           no-lone-blocks
   93:23  error  'link' is missing in props validation               react/prop-types
   93:29  error  'navName' is missing in props validation            react/prop-types
   93:38  error  'keys' is missing in props validation               react/prop-types
  103:2   error  Unexpected tab character                            no-tabs
  104:2   error  Unexpected tab character                            no-tabs
  105:10  error  'width' PropType is defined but prop is never used  react/no-unused-prop-types
  107:2   error  Unexpected tab character                            no-tabs
  108:2   error  Unexpected tab character                            no-tabs
  109:7   error  'bg' PropType is defined but prop is never used     react/no-unused-prop-types
  111:2   error  Unexpected tab character                            no-tabs
  112:2   error  Unexpected tab character                            no-tabs
  113:10  error  'title' PropType is defined but prop is never used  react/no-unused-prop-types
  115:2   error  Unexpected tab character                            no-tabs
  116:2   error  Unexpected tab character                            no-tabs
  117:3   error  Prop type `array` is forbidden                      react/forbid-prop-types

/Users/bsrin2/Documents/CodeBase/XT-Fusion/fusion/Navigation.js
   5:44  error  'type' is missing in props validation                                               react/prop-types
  30:3   error  propType "links" is not required, but has no corresponding defaultProp declaration  react/require-default-props

/Users/bsrin2/Documents/CodeBase/XT-Fusion/fusion/Pagination.js
  60:9  error  Parsing error: Unexpected token =

/Users/bsrin2/Documents/CodeBase/XT-Fusion/fusion/Panel.js
  6:11  error  'className' is missing in props validation  react/prop-types
  6:22  error  'children' is missing in props validation   react/prop-types

/Users/bsrin2/Documents/CodeBase/XT-Fusion/fusion/Panel2.js
  14:18  error  'children' is missing in props validation  react/prop-types

/Users/bsrin2/Documents/CodeBase/XT-Fusion/fusion/ProgressBar.js
  43:12  error  Unexpected mix of '/' and '*'  no-mixed-operators
  43:16  error  Unexpected mix of '/' and '*'  no-mixed-operators

/Users/bsrin2/Documents/CodeBase/XT-Fusion/fusion/ProgressCircle.js
  38:12  error  Unexpected mix of '/' and '*'  no-mixed-operators
  38:16  error  Unexpected mix of '/' and '*'  no-mixed-operators

/Users/bsrin2/Documents/CodeBase/XT-Fusion/fusion/Rating.js
  64:3  error  propType "onClick" is not required, but has no corresponding defaultProp declaration  react/require-default-props

/Users/bsrin2/Documents/CodeBase/XT-Fusion/fusion/Ripples.js
  5:10  error  'theme' is defined but never used  no-unused-vars

/Users/bsrin2/Documents/CodeBase/XT-Fusion/fusion/Row.js
  9:20  error  'React' must be in scope when using JSX  react/react-in-jsx-scope

/Users/bsrin2/Documents/CodeBase/XT-Fusion/fusion/SelectRating.js
  33:5   error  Split 'let' declarations into multiple statements                                            one-var
  33:9   error  'stars' is never reassigned. Use 'const' instead                                            prefer-const
  36:5   error  iterators/generators require regenerator-runtime, which is too heavyweight for this guide to allow them. Separately, loops should be avoided in favor of array iterations  no-restricted-syntax
  38:1   error  Line 38 exceeds the maximum line length of 100                                            max-len
  38:31  error  Script URL is a form of eval                                            no-script-url
  38:53  error  JSX props should not use .bind()                                            react/jsx-no-bind
  38:62  error  JSX props should not use .bind()                                            react/jsx-no-bind
  47:3   error  propType "value" is not required, but has no corresponding defaultProp declaration                                            react/require-default-props

/Users/bsrin2/Documents/CodeBase/XT-Fusion/fusion/Stepper.js
  46:3   error  propType "cardData" is not required, but has no corresponding defaultProp declaration  react/require-default-props
  46:13  error  'cardData' PropType is defined but prop is never used                                  react/no-unused-prop-types
  46:31  error  'cardData.*' PropType is defined but prop is never used                                react/no-unused-prop-types

/Users/bsrin2/Documents/CodeBase/XT-Fusion/fusion/StepperControl.js
    4:10  error  'theme' is defined but never used                                                 no-unused-vars
   79:7   error  Do not use setState in componentWillUpdate                                        react/no-will-update-set-state
   83:17  error  Expected 'this' to be used by class method 'getStepContent'                       class-methods-use-this
  114:11  error  Links must not point to "#". Use a more descriptive href or use a button instead  jsx-a11y/href-no-hash
  122:2   error  Unexpected tab character                                                          no-tabs
  122:2   error  Mixed spaces and tabs                                                             no-mixed-spaces-and-tabs
  147:1   error  Line 147 exceeds the maximum line length of 100                                   max-len
  148:23  error  Style prop value must be an object                                                react/style-prop-object

/Users/bsrin2/Documents/CodeBase/XT-Fusion/fusion/Steps.js
   5:10  error  'theme' is defined but never used                                                   no-unused-vars
  42:17  error  Do not use Array index in keys                                                      react/no-array-index-key
  62:3   error  propType "steps" is not required, but has no corresponding defaultProp declaration  react/require-default-props

/Users/bsrin2/Documents/CodeBase/XT-Fusion/fusion/Tabs.js
   6:17  error  'tabData' is missing in props validation  react/prop-types
   6:26  error  'onClick' is missing in props validation  react/prop-types
   6:35  error  'theme' is missing in props validation    react/prop-types
  68:22  error  Do not use Array index in keys            react/no-array-index-key
  69:23  error  Do not use Array index in keys            react/no-array-index-key
  78:21  error  Do not use Array index in keys            react/no-array-index-key

/Users/bsrin2/Documents/CodeBase/XT-Fusion/fusion/ToggleButton.js
   3:10  error  'theme' is defined but never used        no-unused-vars
  81:7   error  Form label must have associated control  jsx-a11y/label-has-for
  85:11  error  JSX props should not use .bind()         react/jsx-no-bind
  85:21  error  JSX props should not use .bind()         react/jsx-no-bind

/Users/bsrin2/Documents/CodeBase/XT-Fusion/fusion/Typing.js
   5:10  error  'theme' is defined but never used                      no-unused-vars
  22:31  error  'React' must be in scope when using JSX                react/react-in-jsx-scope
  33:10  error  'color' PropType is defined but prop is never used     react/no-unused-prop-types
  37:13  error  'fontSize' PropType is defined but prop is never used  react/no-unused-prop-types

✖ 131 problems (129 errors, 2 warnings)

After quick analysis, Current status of master:
443 errors, 2 warnings
155 errors fixable with the  eslint --fix option

121 Unexpected tab character issues
51 Mixed spaces and tabs
19 missing in props validation
19 no-unused-vars
17 indent issues
and so on.
An easy, yet tedious task. I am currently unable to pick this up, but if no one picks it up, I will in coming days.
Also, my prior experience makes me believe enforcing git hooks through a tool like husky would eliminate badly linted code getting inside master.

@sbmadhav @areai51 can we close this issue as #66  is merged?

@vinaymavi  - I still see eslint errors in development branch. Were all error resolved?

yes @sbmadhav i have fixed all eslint errors manually. please checkout development branch at commit hash b3583860ff1f10e558fab622175d76c79a843787 and try npm run lint this should display only single warning over here.
It looks like some thing went wrong with repository that we need to investigate.


API not return connection closure reasons.

When an AMQP server forces an early closure of a connection ,the AMQP message close will contain the reason, for example maximum connections exceeded. However the caller of the Node API only receives
message: NetworkError: CONNECTION ERROR: The remote computer refused the network connection.
and not the reason.

This was already fixed by https://github.com/mqlight/nodejs-mqlight/commit/c7e772806f86309494366280cc066bd1207e53aa / #1


Type restriction of String#rindex

I have fixed this issue (#10956), then another issue crops up, text.rindex want to return a Int32 but the number given to it was explicitly Int64. you can see the patch https://github.com/iv-org/invidious/pull/2263/files#diff-c7fb42237f52a2684edf3d22d5f0b36f7f0ac8940f71c53886fe4a294ef73357L135
I wonder why isn't these issues showing up before. did something changed in the type inferencer? or it's simply a bug got fixed.
Originally posted by @tleydxdy in https://github.com/crystal-lang/crystal/issues/10965#issuecomment-882938121

The return type restriction to String#rindex was added in #10583 and it appears that this change was not correct. The return type actually depends on the type of the offset parameter and that's unrestricted. So if you passed in Int64 as an argument, the return type would be Int64 as well.
We should revert this return type restriction. It's a breaking change and a regression in 1.1.0.

This is a very common pattern, by the way: offset or similar parameters without a type restriction or with a wide restriction to Int that influence the return type of the method (or input type of a block parameter). Usually, only Int32 makes sense as a type because that's the type of collection sizes and indices. There's no real benefit from allowing a wide variety of types.
I think we should deprecate such unrestricted or broadly restricted parameters and move towards explicit Int32 restrictions.

I think so too.
Ideally, we would have an Int type that's used everywhere, so these issues would be much less common. Unfortunately we didn't go that route and now users have to juggle between many int types... 😢
I wonder if there would still be a way to change that for 1.x...

/cc #8111


[ETFE-3675] - Added CaM submission request/response audit event

Raising as draft whilst I check some more scenarios

I've spoken to CIP / TxM and they said they'd get back to me on the above. As Matt has said, if they do require us to explicitly write out field values (in human-friendly format) then this will be done separately.


Use customer_address id as reference on address instead of address id

Description
This Feature will unify the use of reference attribute to track the customer address used between mfe-my-account and mfe-checkout.

:tada: This issue has been resolved in version 4.6.1 :tada:
The release is available on GitHub release
Your semantic-release bot :package::rocket:


[dev] disallow localhost as host

for now it rick rolls you so we should limit that behavior until we solve #901

This nearly gave me a heart attack 🤣 I thought at first I had been hacked.

next release of the workers runtime will no longer rick roll and will provide a meaningful error message, so this issue should no longer be relevant 😄  #901 is still a good idea though i think

@jayphelps Sorry! My fault. I put in that code three years ago to catch people testing SSRF attacks on cloudflareworkers.com (trying to talk to "localhost" on our server, maybe hoping to find an unprotected internal service), but I guess with wrangler dev it's now much easier to hit it by accident.

Totally. No worries on my end at all. 👍


FR: Introduce FallbackUrlRule for UrlManager

What steps will reproduce the problem?
Right now UrlManager have some fallbacks if none of rules match current request/route:
Creating URL:
https://github.com/yiisoft/yii2/blob/0199325c813526afaed464248f9d0785781f90b5/framework/web/UrlManager.php#L412-L420
Parsing request:
https://github.com/yiisoft/yii2/blob/0199325c813526afaed464248f9d0785781f90b5/framework/web/UrlManager.php#L283-L323
This not only breaks SRP and creates weird bugs for such fallbacks (#10739), but also may decrease performance: such fallback can never be cached by per-request cache (UrlManager::getUrlFromCache()) - UrlManager needs to iterate trough all rules before creating URL in format "/module/controller/action";
Solution
Introduce FallbackUrlRule which will handle these fallbacks. It will be always appended to rules array, so it results of URL creation can be cached. This will make UrlManager simpler and performance of createUrl() should be improved.

Sounds interesting to me. Worth trying.

Won't be implemented in 2.0.


[Bug]Get-DbaDbSpace -AutoGrowth reports wrong numeric value in case is_percent_growth = 1

Environmental information
<!--
🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨
PowerShell Version        : 5.1.14409.1018
dbatools latest installed : 1.0.112
Culture of OS             : en-US

#### SQL Server:

Microsoft SQL Server 2017 (RTM-CU20) (KB4541283) - 14.0.3294.2 (X64)   Mar 13 2020 14:53:45   Copyright (C) 2017 Microsoft Corporation  Enterprise Edition (64-bit) on Windows Server 2012 R2 Datacenter 6.3 <X64> (Build 9600: ) (Hypervisor)

us_english

### Report

The property "AutoGrowth" of function Get-DbaDbSpace gives wrong numeric value in case is_percent_growt = 1.
The problem is caused by the following T-SQL code:
,CAST((f.growth/128.0) AS FLOAT) AS [GrowthMB]  (line 99)

It should be replaced by something like this:
IIF(f.is_percent_growth = 1, CAST(f.growth AS VARCHAR(10)) +' %', CAST((f.growth/128) AS VARCHAR(10))+ ' MB' ) AS my_growth

You will understand this when reading Microsoft´s documentation about column growth of sys.database_files view:
https://docs.microsoft.com/en-us/sql/relational-databases/system-catalog-views/sys-database-files-transact-sql?view=sql-server-ver15

#### Host used

- [X ] powershell.exe
- [X ] ISE
- [ ] VS Code
- [ ] Other (please specify)

If anything other than powershell.exe was used, please confirm that you can duplicate the issue with powershell.exe

- [ ] Still buggy in powershell.exe

#### Errors Received

If you have a db file with default auto-growth 10 %, Get-DbaDbSpace should provide 10 %.

#### Steps to Reproduce

See above.

#### Expected Behavior

If you have a db file with default auto-growth 10 %, Get-DbaDbSpace should provide 10 %

#### Actual Behavior

If you have a db file with default auto-growth 10 %, Get-DbaDbSpace provides 80.00 KB as result.

All my environmental informations I entered carefully are gone, therefore close this issue. Site drives me crazy!

You have to remove the comment notations. This is the open comment syntax <!-- and then the closing one is -->


N26 Bic missing

I have found an new bank that the BIC is not generated
The IBAN starts with ES38 1563, and the bank is N26 Bank Gmbh, Sucursal En Espana
Probably all the Neobanks are not included (N26, Revolut, Rebellion, ....)

The banks are currently read from here and N26 is missing there, but we can add a manual overwrite for the missing banks by adding them to schwifty/bank_registry/manual_es.json.

This was fixed in release 2022.02.0


Enable ethernet in simulation for SUT and Tester. Update SUT bootloader.

This PR includes commits from https://github.com/IObundle/iob-soc-sut/pull/58. That one should be merged first.
Enable ethernet during simulation in Tester and SUT firmware/bootloader.
Update SUT bootloader for consistency with opencryptolinux.

Closing this PR because changes are already included in PR https://github.com/IObundle/iob-soc-sut/pull/58


fix testng assertEquals parameter order

Motivation
When change from Junit to TestNG, the assertEquals method's parameter order has changed. However in our current test, the assertEquals are misorder.
Modifications

Change the order of TestNG#assertEquals parameter.

Cherry-picking to branch-2.8 to simplify conflict resolution.


Vertical align slides

Is there a possibility to vertical align the image slides ?

same problem here. the solution from css-tricks.com doesn't work in my case. maybe due to the images overflowing my actual slider-size. However, I'm a beginner to wedesign and coding...
Could anyone solve the issue so far?

Hello,
The technique from css-tricks.com works for me adding a fixed height to the container:
.slick-track {
height: 200px;
}

@peschee, thanks that worked really well!

peschee, thanks for great solution!

That trick is useful to center when the child and parent are unknown.
Since you add explicit height to slick-track, that is no longer the case, and you can center using a simpler techniques, like this one:
.slick-track {
height: 200px;
}

.slick-slide {
  top: 50%;
  transform: translateY(-50%);
}

That works because top percentage is relative to the parent, while transform percentage is relative to the element itself. So we push it 50% of the parent down, then pull it back up 50% of its own height.

Hi,
using: display: flex; align-items:center on .slick-slide works for me in most browsers.

thanks @peschee - works perfectly! :ok_hand:

@peschee's solution only seems to work when I also use @tomasguemes's modification

It's totally hopeless trying to vertical align content within the slider that has an unknown height? I've struggling with this like a maniac.

When slider is in vertical mode, image in center is actually last image on start and that bug keeps happening while scrolling. Any idea how to fix this?

Here's the simplest solution I've found:
.slick-initialized .slick-slide {
    float: none;
    display: inline-block;
    vertical-align: middle;
}

@jpotterm Thanks, it working indeed.
BTW Great timing, Your reply appeared 5 minutes before I've visited this issue:)

@jpotterm - Thank you for the solution. As an alternative, I was having an issue with titles above the image being too long, which pushed the slide down. I wanted all the images to line up and the titles to "grow" upwards. Using "vertical-align: baseline;" allows for this to happen. I just wanted to leave my experience to help out anyone else who is having any issues with a similar problem.

@jpotterm Thanks))

@jpotterm Thanks - that is an elegant solution.

@zibot I tried every solution here, and I don't know why, but your solution was the only one that worked for me!

I love flexbox, thanks @zibot for this solution!

    .slick-initialized .slick-slide {
           float: inherit;
           display: inline-block !important;
           vertical-align: middle;
    }

Thanks.


Improve documentation about Spaces Upgrades pricing

@christophe-rannou would you be able to take this one?

Sure thing, what kind of information you're expecting ? Mainly during which stage a space is actually billed ?
Should I have this under the Other -> Billing section or under Spaces -> Spaces GPU Upgrades ?

Yes, documenting that we bill for stages X and Y, bill for minute running, etc. How to turn off might be good as well
I think this could live somewhere near https://huggingface.co/docs/hub/spaces-gpus, maybe as a separate page or as a subsection of the page

nice!


Create sum-strings.html

#29

Updated the PR, check it out!

Yes! This is great! Can you update the <title> tag and <h1> tags with the name of the problem and then I think it will be good to go!

Can't believe I missed those, sorry!

No problem! It might be good to add that to the guide that we have on our README (you're not the only one to make that mistake). If you want to create an issue for it, that would be amazing! Otherwise, thank you so much for your contribution!


support if statement

I'm submitting a ...  (check one with "x")
[] bug report => search github for a similar issue or PR before submitting
[*] enhancement request
[] feature request
[] support request
[] general question

Current behavior (how does the issue manifest):
Today we only support ternary expression for one level if else case, it has the limitation and it does not support nested ternary expression.
Expected behavior:
We should come up with an if statement expression which supports nested if else. such as:
 if true {
  "yes"
 }else {
   "no"
}

if string.equals("FLOGO", "FLOGO") {
     if string.equals("if", "if") {
             "Hello FLOGO IF expression"
     }
}else {
    if string.equals("TIBCO", "TIBCO") {
            "Hello TIBCO"
    }
}

The if statement gives the user more flexibility to achieve more complex use cases
Minimal steps to reproduce the problem (not required if feature enhancement):
What is the motivation / use case for changing the behavior?
Please tell us about your environment (Operating system, docker version, browser & verison if webui, etc):
Flogo version (CLI & contrib/lib. If unknown, leave empty or state unknown): 0.X.X
Additional information you deem important (e.g. issue happens only occasionally):

There is a use case that query salesforce approval object and return the status of the record with description.
Here is the status and expect return messages:
Submitted  ->  Your request has been submitted.
Pending	->  Your request staus still pending.
Approved  -> Your request has been approved.
Rejected	-> Your request has been rejected
REassgined  -> Your request has been submitted for approval but assigned to a different approver.
Recalled	->  You request has been recalled.

Possible solution

User want to have only one return so branching not work.(we don't have branch merge today)
Ternary expression,  we  don‘t support nested ternary expression so far.  it might hard to read if we support nested.  such as:

$activity[query].output.Approval == ”Submitted“ ? ”Your request has been submitted“ : ($activity[query].output.Approval == ”Pending“ ? "Your request staus still pending" : ($activity[query].output.Approval == "Approved" ? "Your request has been approved": ($activity[query].output.Approval == "Rejected" ? "Your request has been Rejected": ($activity[query].output.Approval == "Reassgined" ? "Your request has been reassigned":($activity[query].output.Approval == "Recalled" ? "Your request has been Recalled":"Unknow staus"))))）

If statment

	if $activity[query].output.Approval == ”Submitted“  {
			”Your request have been submitted“
	}else if $activity[query].output.Approval == "Pending" {
			"Your request staus still pending."
	}else if $activity[query].output.Approval == "Approved" {
			"Your request has been approved."
	}else if $activity[query].output.Approval == "Rejected" {
			"Your request has been rejected"
	}else if $activity[query].output.Approval == "Reassgined" {
			"Your request  has been submitted for approval but assigned to a different approver"
	}else if $activity[query].output.Approval == "Recalled" {
			"You request has been recalled."
	}else {
			"Unknow staus"
	}

We can see the if/else statement much simple and clear for this kind of usecase.
@mellistibco @fm-tibco Please let me know your thougts? or possible others resolution?

@mellistibco @fm-tibco please add your comments and suggestions.

thanks @lixingwang ... I just still think I'd rather have a scripting activity that would support something like this rather than supporting it via the expression syntax. I really think expressions should be lightweight expressions and should not begin to morph into a scripting language...

Thanks, @mellistibco, it makes sense.  I thinking about to add an activity to support this. BTW, I created #263 to support nested ternary expression.


Is it possible to find observed_data containing certain objects using filter?

Hello.
I want to find observed_data contains ipv4-addr objects with value "<IP_ADDRESS>".
    {
        "type": "observed-data",
        "id": "observed-data--bd0b4ea1-b608-4ce5-a6b0-81a3feec5fe6",
        "created": "2018-06-27T01:09:00.749Z",
        "modified": "2018-06-27T01:09:00.749Z",
        "first_observed": "2018-06-27T01:09:00.748465Z",
        "last_observed": "2018-06-27T01:09:00.748472Z",
        "number_observed": 1,
        "objects": {
            "0": {
                "type": "ipv4-addr",
                "value": "<IP_ADDRESS>"
            },
            "1": {
                "type": "ipv4-addr",
                "value": "<IP_ADDRESS>"
            },
            "2": {
                "type": "network-traffic",
                "src_ref": "0",
                "dst_ref": "1",
                "src_port": 13513,
                "dst_port": 80,
                "protocols": [
                    "tcp"
                ]
            }
        }

So I created query containing sub queries. like this
fs = FileSystemStore("test_data/stix2_store")

query = [Filter("type", "=", "observed-data")]
query.append(Filter("objects", "in", "0"))
query.append(Filter("type", "=", "ipv4-addr"))
query.append(Filter("value", "=", "<IP_ADDRESS>"))
object_find = fs.query(query)

But it won't work.
Is there any way to find observed-data containg certain object??

Hi @KimSangpil, thank you for your question. Currently you can do something like the following, if that was the only object in the observed-data:
query = [Filter("objects", "=", {"0": {"type": "ipv4-addr", "value": "<IP_ADDRESS>"}})]
I've created a Pull Request to add the functionality you're looking for, but in the meantime you may want to look at the pattern matcher, which determines if an observable matches a STIX pattern.

Thanks, @KimSangpil . I just merged @clenk's merge request. As he said, you can also use the pattern matcher to look for observables that may contain more just the property you're looking for. At this point, we're unlikely to add much more complexity to filters ("contains" made a lot of sense) because at that point we're basically re-implementing the STIX patterning language.


Type system 🪶

For a single and high-quality display of a font system, it is necessary to develop a single system that would allow the use of a single font in any system and any browser. Systems such as Bootstrap, Ant design, Element UI use fonts taken from various operating systems. In the case of Wuki, I decided to use a single font - Urbanist. This font family is open to the community and is free to use, thanks to @coreyhu.
Tasks:

[ ] Using Urbanist it is necessary to build a system for flexible use in the future in the system

[x] Prepare h1-h6
[x] Prepare accompanying HTML tags
[x] Prepare classes

[x] Check usage support across browsers
[ ] Check support for use on different operating systems
[ ] Customize font usage in library using Google Fonts

At the moment, I must report that during the development, the originally chosen Urbanist font had to be replaced with Manrope. Manrope - more suitable in terms of design and convenience, the Cyrillic support was also a big plus.
Mikhail Sharanda, спасибо за такой потрясающий шрифт! ✌🏻

The current font family needs to be revisited.


error SSL_read: unexpected eof while reading while running backup

Hello, thank you for helping me with the previous issue. I let the process run to completion. Towards the end, however, I receive this error that I have not seen mentioned in issues yet. I can't tell if it's a particular email that is an issue, or if it's due to downloading such a large number of emails. Since I have delay_metadata enabled, nothing was saved so I would have to restart the entire process again. I have had this happen once before, but that was without verbose mode and I thought it was a one-time issue. Do you have any suggestions what I can try? Thank you.
D, [2024-12-06T04:26:36.128174 #1] DEBUG -- : [% ] uid: 9512 (7688/8732) - 32713 bytes
D, [2024-12-06T04:26:36.499710 #1] DEBUG -- : [% ] Pre-fetch unseen messages:
D, [2024-12-06T04:26:37.186179 #1] DEBUG -- : [% ] Post-fetch unseen messages:
D, [2024-12-06T04:26:37.186248 #1] DEBUG -- : [% ] uid: 9513 (7689/8732) - 31484 bytes
D, [2024-12-06T04:26:37.776337 #1] DEBUG -- : [% ] Pre-fetch unseen messages: 9514
D, [2024-12-06T04:26:38.761211 #1] DEBUG -- : [% ] Post-fetch unseen messages: 9514
D, [2024-12-06T04:26:38.761288 #1] DEBUG -- : [% ] uid: 9514 (7690/8732) - 92152 bytes
E, [2024-12-06T04:26:39.445933 #1] ERROR -- : Backup for account<EMAIL_ADDRESS>failed with error SSL_read: unexpected eof while reading
/usr/local/lib/ruby/3.2.0/openssl/buffering.rb:80:in `sysread'
/usr/local/lib/ruby/3.2.0/openssl/buffering.rb:80:in `fill_rbuff'
/usr/local/lib/ruby/3.2.0/openssl/buffering.rb:239:in `gets'
/usr/local/bundle/gems/net-imap-0.4.12/lib/net/imap.rb:2720:in `get_response'
/usr/local/bundle/gems/net-imap-0.4.12/lib/net/imap.rb:2629:in `receive_responses'
/usr/local/bundle/gems/net-imap-0.4.12/lib/net/imap.rb:2606:in `block in start_receiver_thread'

{
  "version": "2.2",
  "accounts": [
    {
      "username"<EMAIL_ADDRESS>      "password": "zzzzzz",
      "local_path": "/data/email_folder",
      "folders": [
        "% ",
        "% 2",
        "% 2/Junk"
      ],
      "server": "imap.gmail.com",
      "multi_fetch_size": 1,
      "reset_seen_flags_after_fetch": true
    }
  ],
  "download_strategy": "delay_metadata"
}

docker run --volume ./config:/config --volume ./data:/data --dns <IP_ADDRESS> ghcr.io/joeyates/imap-backup:v15.0.2 imap-backup backup --verbose --config /config/imap-backup-v2.json

contents of .imap file
{"version":3,"uid_validity":104,"messages":[]}

I also had this issue with my Gmail account... Following :)


Fix third example

Third condition matches

actually the example is correct, in your change tail would be [2] instead []


Cursor position outside buffer

Use lsp_signature with cmp will cause this:
Error executing vim.schedule lua callback: ...vim/lazy/lsp_signature.nvim/lua/lsp_signature/helper.lua:676: Cursor position outside buffer
stack traceback:
	[C]: in function 'nvim_win_set_cursor'
	...vim/lazy/lsp_signature.nvim/lua/lsp_signature/helper.lua:676: in function 'highlight_parameter'
	.../nvim/lazy/lsp_signature.nvim/lua/lsp_signature/init.lua:618: in function 'handler'
	/usr/share/nvim/runtime/lua/vim/lsp.lua:1517: in function ''
	vim/_editor.lua: in function <vim/_editor.lua:0>

And my configuration for lsp_signature is:
{
  log_path = vim.fn.stdpath "cache" .. "/lsp_signature.log",
  debug = true,
  hint_enable = false,
  handler_opts = { border = "rounded" },
  max_width = 80,
  noice = true,
}

It seems that neovim API returns this error. My neovim version is (nightly):
NVIM v0.10.0-dev-1573+gd92dd2a0c05
Build type: RelWithDebInfo
LuaJIT 2.1.1700008891
Run "nvim -V1 -v" for more info

Here is the debug log, I've cleaned the previous contents:
lsp_signature.log

I assume you are using latest version  of lsp_signature.
Could you send a rust code snippet i can reproduce the issue? I checked your logs but unfortunately, I  am not familiar with rust and did not find anything useful yet.

Yes, I use the latest version  of lsp_signature. A simple clean code should help:
fn test_function(a: i32, b:i32) -> i32 {
  0
}

fn main() {
  test_function(1, 2)
}

Looks good to me

I am using same version: NVIM v0.10.0-dev-1573+gd92dd2a0c-Homebrew
Could you set noice = false, I does not use noice and it might be they changed something

OK, after set noice = false, it does not happen. So I think your guess is correct.

I may run some test and deprecate noice setting


⚠ Bofrost.de has degraded performance

In 9d77060, Bofrost.de (https://www.bofrost.de) experienced degraded performance:

HTTP code: 200
Response time: 2038 ms

Resolved: Bofrost.de performance has improved in 8cc3206 after 15 minutes.


Need "ANSI" encoding enumeration value to support "ANSI"-code-page-encoded files (e.g., Windows 1252)

As discussed in #6550:
While you can pass OEM to filesystem cmdlets to support the legacy system locale's OEM code page on Windows, its "ANSI" counterpart (such as Windows 1252 on US-English systems) is currently missing.
(In Windows PowerShell, the Default value fulfills that role, but in PowerShell Core Default now refers to the new default, (BOM-less) UTF-8.)
Therefore, an ANSI encoding value should be introduced to complement the OEM value.
With ANSI available, the current workaround:
Get-Content -Encoding ([System.Text.Encoding]::GetEncoding([cultureinfo]::CurrentCulture.TextInfo.ANSICodePage)) file.txt

would simply become:
Get-Content -Encoding Ansi file.txt   # Wishful thinking.

Note: Given that OEM already is available even when running on Unix-like platforms, it sounds like we shouldn't restrict ANSI's availability to Windows. ([System.Text.Encoding]::GetEncoding([cultureinfo]::CurrentCulture.TextInfo.ANSICodePage)seemingly does return a locale-appropriate value on Unix-like platforms as well.)
Environment data
Written as of:
PowerShell Core v6.0.2

@iSazonov: Yes, it should be a new issue, but I was suggesting that @chuanjiao10 create it (I only suggested a possible syntax).
Interesting about the short list of Unix - hadn't noticed that - perhaps yet another issue.

@iSazonov: Just as a quick pointer regarding the "short list":
[System.Text.Encoding]::GetEncodings() only ever reflects the encodings available by default in .NET Core, even if additional ones were registered registered via [System.Text.Encoding]::RegisterProvider() later; sadly, [System.Text.CodePagesEncodingProvider]::Instance has NO equivalent method for enumerating the encodings it implements.

New issue for [System.Text.Encoding]::GetEncodings() discussion #6580.

New issue for "to allow numerical values" discussion  #6581

I appreciate it, @iSazonov.

I would like to echo the concerns above.  The current list of encodings is too limiting.  I am dealing with text encoded SHIFT_JIS (cp932) on OEM-US (cp437) and need to get the text to Unicode.  Currently working around it with a Get-EncodedContent function that takes all of the named Encodings as a result of [system.text.encoding]::GetEncodings() and then using [system.io.file]::ReadAllLines($Path,$Encoding) as a workaround.  Even using encoding RAW would destroy the SHIFT_JIS text on my system.
This is a work in progress but should help others work around the issue in the meantime:
`function Get-EncodedContent {
[CmdletBinding()]
param (
$Path
)
DynamicParam {
$ParamName = 'CodePage'
$attributes = new-object System.Management.Automation.ParameterAttribute
$attributes.ParameterSetName = '__AllParameterSets'
$attributes.Mandatory = $false
$attributeCollection = new-object -Type System.Collections.ObjectModel.Collection[System.Attribute]
$attributeCollection.Add($attributes)
$_Values = ([System.Text.Encoding]::GetEncodings()).codepage
$ValidateSet = new-object System.Management.Automation.ValidateSetAttribute($_Values)
$attributeCollection.Add($ValidateSet)
$dynParam1 = new-object -Type System.Management.Automation.RuntimeDefinedParameter($ParamName, [String], $attributeCollection)
$paramDictionary = new-object -Type System.Management.Automation.RuntimeDefinedParameterDictionary
$paramDictionary.Add($ParamName, $dynParam1)
return $paramDictionary
}
begin {
    $CodePage = [int]($PSBoundParameters.CodePage)
    $TextEncoding = [system.text.encoding]::GetEncoding($CodePage)

}

process {
    [System.IO.File]::ReadAllLines((get-item $Path), $TextEncoding)
}

end {
}

}`

 #6581 is good idea .I hope it can be realized soon.

The above code can only replace get-content and cannot replace other commands, such as select-string -encoding

Thanks for the snippet. That's better than my current way to work around this issue in my scripts:
    $iswinps = ($null, 'Desktop') -contains $PSVersionTable.PSEdition
    if (!$iswinps)
    {
        $encoding = [System.Text.Encoding]::GetEncoding(1252)
    }
    else
    {
        $encoding = [System.Text.Encoding]::Default
    }

    Get-Content -Encoding $enconding ...


fixing bug in make file where it would nest directories in themselves

Fixed a little bug in the make file, without this fix the docs folder was being copied into the conent/en/docs folder if it already existed and making some weird nested stuff.

@banker @itamarhaber


Undo support for pipeline editor relayout

It would be nice to have undo ("Ctrl+Z") support for the pipeline editor relayout.
Is your feature request related to a problem? Please describe.
The automatic layout is really nice, however in some cases you might want a particular layout for a specific reason. If one hits the relayout button, there's no easy way to go back to the previous configuration.

Might as well be undo support for the entire pipeline editor. But that might be a too big increase of scope, we can definitely start with just the "relayout" feature.

Pretty sure @franceme would also like this feature due to the big (~50 steps) pipelines that he has :wink:


📃: Addition of Rock, Paper , Scissors Game

🔴 Title :Rock Paper Scissors Game
🔴 Tech stack :HTML, CSS, JavaScript
🔴 Objective :Create a simple, interactive Rock Paper Scissors game that allows users to play against the computer in a web browser.
🔴 Summary :Develop a web-based Rock Paper Scissors game where players can choose their move (rock, paper, or scissors) by clicking on buttons or images. The computer will randomly select its move, and the game will determine the winner based on the classic Rock Paper Scissors rules. The game should keep track of the score and display the result of each round.

✅ Details to Include When Taking the Issue:
Name : pratheekv39 (V Pratheek)
Participant Role : GSSOC and Hacktoberfest participant

Happy Contributing! 🚀
Wishing you all the best on your open source journey. Enjoy! 😎
@iamrahulmahato  Can you please assign me this issue. I would love to work on it

Sorry, someone is already working on this. Do not be demotivated and raise a new issue.


fix: quick open do not hide on electron

Types

[x] 🐛 Bug Fixes

Background or solution
Changelog
QuickOpen do not hide when blur on electron

/publish

/publish


resolves #725 and #850

Upon #859, this will resolve #725 and #850.  The reproducers in each of those examples now compile, please let me know if any modifications are required.

Integration task tracked by nvbug 2004663.

Needs a test, too.

@andrewcorrigan or @jaredhoberock, does one of you two want to volunteer to write a test for this?


ECS resources are not nuked

Resources like ECSCluster, Tasks, Services should all be nuked.

@brikis98 would love to implement this one. Won't commit until I have the time for it, though :)

@sarkis, go for it! 👍

Just tested #36 and it works perfect. ECS Cluster deletion issue is a non-issue in terms of cloud-nuke and documented - marking this issue as closed. Thanks @yorinasub17!


⚠ Bofrost.hr has degraded performance

In a3b88aa, Bofrost.hr (https://www.bofrost.hr) experienced degraded performance:

HTTP code: 200
Response time: 3223 ms

Resolved: Bofrost.hr performance has improved in 337466d.


10.0.22000.2777

termsrv.zip

https://github.com/sebaxakerhtc/rdpwrap.ini/commit/5e441a96ce1632e57785a17d5ae85d54477259b2

Hi there, thanks for the support. I'm running Windows 11 with this termsrv version and, although with that new ini it says is fully supported, it still allows only one RDP connection to the machine.
Uninstalling and reinstalling didn't make any difference.
Any suggestions?

@Guisardo
If you haven’t tried reinstalling this way, check:
Try:

Download RDP Wrapper 1.6.2 and extract this to any directory.
Place rdpwrap.ini in the same directory.
Open CMD as administrator
Execute this commands

cd C:\path\to\directory\
rdpwinst -u -k
rdpwinst -i

Enjoy!

Original message: https://t.me/rdpwrap/49131

@Guisardo
If you haven’t tried reinstalling this way, check:
Try:

Download RDP Wrapper 1.6.2 and extract this to any directory.
Place rdpwrap.ini in the same directory.
Open CMD as administrator
Execute this commands

cd C:\path\to\directory\
rdpwinst -u -k
rdpwinst -i

Enjoy!

Original message: https://t.me/rdpwrap/49131

Thanks @sashaqwert ! that was very useful, but I'd to change the steps a little.
1.- Download RDP Wrapper
2.- Run rdpwinst -u -k
3.- Place rdpwrap.ini
4.- Run rdpwinst -i
5.- Enjoying!!


Disable exceptions when built with -fno-exceptions

ParlayLib now removes all exception code when compiled with -fno-exceptions. You can also explicitly disable exceptions just inside ParlayLib with -DPARLAY_NO_EXCEPTIONS.

Codecov Report

Merging #59 (f02b9a8) into master (4579f39) will increase coverage by 0.24%.
The diff coverage is 93.75%.

:exclamation: Your organization needs to install the Codecov GitHub app to enable full functionality.
@@            Coverage Diff             @@
##           master      #59      +/-   ##
==========================================
+ Coverage   96.78%   97.02%   +0.24%
==========================================
  Files          55       56       +1
  Lines        3699     3701       +2
==========================================
+ Hits         3580     3591      +11
+ Misses        119      110       -9

Files Changed
Coverage Δ

include/parlay/alloc.h
96.77% <ø> (ø)

include/parlay/internal/counting_sort.h
98.62% <ø> (ø)

include/parlay/internal/file_map.h
100.00% <ø> (ø)

include/parlay/internal/pool_allocator.h
100.00% <ø> (ø)

include/parlay/internal/sample_sort.h
95.65% <ø> (ø)

include/parlay/internal/uninitialized_sequence.h
100.00% <ø> (ø)

include/parlay/internal/work_stealing_deque.h
94.73% <0.00%> (ø)

include/parlay/scheduler.h
100.00% <ø> (ø)

include/parlay/delayed_sequence.h
100.00% <100.00%> (+4.28%)
:arrow_up:

include/parlay/internal/bucket_sort.h
100.00% <100.00%> (ø)

... and 4 more

... and 1 file with indirect coverage changes


[] build failure

Host Environment

OS: [e.g. Windows/Linux etc...] Windows
Compiler: revision

To Reproduce
Steps to reproduce the behavior:
./vcpkg install xxxx
Failure logs
-Cut and past the appropriate build messages from the console output.
-Please attach any additional failure logs mentioned in the console output.
Additional context
I am using Visual Studio 2017 and setup to use Opengl and Freeglut.
I am getting the following error. Please help. Please tell me what I am missing.
Severity	Code	Description	Project	File	Line	Suppression State
Error	LNK1104	cannot open file 'freeglut.obj'	Keyboard	c:\Users\Josep\source\repos\MainKeyboard\Keyboard\LINK	1
This is the setup I have done so far:
I have the following files under the noted directories
C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.16.27023\include\GL
freeglut.h, freeglut_ext.h, freeglut_std.h, freeglut_ext.h, freeglut_ucall.h, glut.h
C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.16.27023\lib\x64
freeglut.lib
C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.16.27023\lib\x86
I did not put anything under this directory. There was only one freeglut.lib file
C:\Windows\System32
freeglut.dll
C:\Windows\SysWOW64
freeglut.dll

@stemuser027, could you provide more information? like the repro steps and repro code.
Do you install the freeglut by vcpkg and copy everything to msvc toolset forlder?

Thank you so much for you response. I got the information from
http://freeglut.sourceforge.net/index.php#download
under the section for "Stable Re;ease", I selected:
freeglut 3.2.1 [Released: 29 September 2019]
If this the correct location, or do you have a recommended repo for me go get the inormation

@stemuser027, let me know if you have any questions about installing freeglut via vcpkg.

@stemuser027, vcpkg provide a very easy and simple solution for setting up the freeglut port in your project. please reopen this issue if you still have any issue for freeglut that installing by vcpkg.


Feature/device search

Completed requested rebase @chaoran-chen

That's not a rebase.. The aim is to have a clean and meaningful git history.

I mean, why do we now have commits belonging to an entirely other issue in this pull request?


Run ci_check instead of individual cargo commands

Brings GitHub actions CI closer to what Travis does right now.
Overview

Checklist

[ ] Updated the documentation (code documentation, command help, ...)
[ ] Tested the change (unit or integration tests)
[ ] Amended the changelog in release.nix (see release.nix for instructions)

@Profpatsch any idea what is going on here? https://github.com/target/lorri/pull/430/checks?check_run_id=800250471#step:7:7
If that doesn't ring a bell, I'll investigate tomorrow.

Some ? blows up.
We should add a flag that makes lorri go into “don’t be user-friendly” mode and just print the crash log.

@Profpatsch tests passed -- is this good to go?


MONITORED_DISTRICTS is set static to 83

Is there an option to change the monitored districts to populate dynamically based on the contents of either an environment variable or a file?
Additionally where are the logs stored for the queries?
I want to help with the creation of docker image so log rotation would be mandatory so as to not fill up the disk space.
I 've no experience with rust so pardon any noobish questions.

populate dynamically based

It should be a simple case of reading either a .env file or some other dynamic storage. The reason I didn't go for that is to force the constant memory to be allocated to the stack and not the heap.

Additionally where are the logs stored for the queries?

Logs are currently only outputted to stdout but it's trivial to configure env_logger to also output to a .log file.

creation of docker image

A docker image would be great, wherein all the required tokens TELOXIDE, CHANNEL and OWNER can just be read from the .env file. A simple alpine-linux image should work fine considering we don't need to install any dependencies. Running just the binary should be fine.

Would love to get your inputs on reading the MONITORED_DISTRICTS constant from an environment file.

I am running an instance for specific districts and just edited 'MONITORED_DISTRICTS' to the districts count.
Adding a note/step in the README file regarding this should suffice.


Please provide examples for some use cases of the library

i'm a beginner in the rust ecosystem and i would love if you could provide some assistance in the form of working examples for some use cases such as downloading a file

This is certainly something we could do, but most of the examples would be similar to the offical curl examples since this library is mostly a 1-to-1 wrapper around that. The syntax might differ here and there but the concepts should be exactly the same.


refactor func createSecret() to BuildSecret()

fix
// TODO(wattli): move the two functions below as a util function to share with secret_test.go
fix the name of some var (as @incfly pointed out, naming of cACertID, cAPrivateKeyID, etc. are out of convention)

/assign @wattli @myidpt

[APPROVALNOTIFIER] This PR is NOT APPROVED
This pull-request has been approved by:
To fully approve this pull request, please assign additional approvers.
We suggest the following additional approver: wattli
If they are not already assigned, you can assign the PR to them by writing /assign @wattli in a comment when ready.
The full list of commands accepted by this bot can be found here.
The pull request process is described here

Needs approval from an approver in each of these files:

security/OWNERS

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

Hi @islinwb. Thanks for your PR.
I'm waiting for a istio member to verify that this patch is reasonable to test. If it is, they should reply with /ok-to-test on its own line. Until that is done, I will not automatically test new commits in this PR, but the usual testing commands by org members will still work. Regular contributors should join the org to skip this step.
I understand the commands that are listed here.

Instructions for interacting with me using PR comments are available here.  If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

[APPROVALNOTIFIER] This PR is NOT APPROVED
This pull-request has been approved by:
To fully approve this pull request, please assign additional approvers.
We suggest the following additional approver: myidpt
If they are not already assigned, you can assign the PR to them by writing /assign @myidpt in a comment when ready.
The full list of commands accepted by this bot can be found here.
The pull request process is described here

Needs approval from an approver in each of these files:

security/OWNERS

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@islinwb: The following test failed, say /retest to rerun them all:

Test name
Commit
Details
Rerun command

prow/e2e-mixer-no_auth.sh
559c13dda86228a5772e8e1c18687fb08e4f0b15
link
/test e2e-mixer-no_auth

Instructions for interacting with me using PR comments are available here.  If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here.

@hzxuzhonghu Could you help add an "ok-to-test"? Thanks!

/retest

@islinwb: Cannot trigger testing until a trusted user reviews the PR and leaves an /ok-to-test message.

In response to this:

/retest

Instructions for interacting with me using PR comments are available here.  If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@lichuqiang Can you help add an "ok-to-test"? Thanks!

/ok-to-test

@islinwb: The following tests failed, say /retest to rerun them all:

Test name
Commit
Details
Rerun command

prow/e2e-mixer-no_auth.sh
559c13dda86228a5772e8e1c18687fb08e4f0b15
link
/test e2e-mixer-no_auth

prow/e2e-dashboard.sh
d110f1f2bad4db1d2f88a25c3a15d9687349c0e7
link
/test e2e-dashboard

Instructions for interacting with me using PR comments are available here.  If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here.

@islinwb: The following tests failed, say /retest to rerun them all:

Test name
Commit
Details
Rerun command

prow/e2e-mixer-no_auth.sh
559c13dda86228a5772e8e1c18687fb08e4f0b15
link
/test e2e-mixer-no_auth

prow/e2e-dashboard.sh
d110f1f2bad4db1d2f88a25c3a15d9687349c0e7
link
/test e2e-dashboard

prow/e2e-bookInfoTests-v1alpha3.sh
d110f1f2bad4db1d2f88a25c3a15d9687349c0e7
link
/test e2e-bookInfo-envoyv2-v1alpha3

Instructions for interacting with me using PR comments are available here.  If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here.

@islinwb: The following tests failed, say /retest to rerun them all:

Test name
Commit
Details
Rerun command

prow/e2e-dashboard.sh
d110f1f2bad4db1d2f88a25c3a15d9687349c0e7
link
/test e2e-dashboard

prow/e2e-bookInfoTests-v1alpha3.sh
d110f1f2bad4db1d2f88a25c3a15d9687349c0e7
link
/test e2e-bookInfo-envoyv2-v1alpha3

prow/e2e-mixer-no_auth.sh
d110f1f2bad4db1d2f88a25c3a15d9687349c0e7
link
/test e2e-mixer-no_auth

Instructions for interacting with me using PR comments are available here.  If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here.

@islinwb: The following tests failed, say /retest to rerun them all:

Test name
Commit
Details
Rerun command

prow/e2e-dashboard.sh
d110f1f2bad4db1d2f88a25c3a15d9687349c0e7
link
/test e2e-dashboard

prow/e2e-bookInfoTests-v1alpha3.sh
d110f1f2bad4db1d2f88a25c3a15d9687349c0e7
link
/test e2e-bookInfo-envoyv2-v1alpha3

prow/e2e-mixer-no_auth.sh
d110f1f2bad4db1d2f88a25c3a15d9687349c0e7
link
/test e2e-mixer-no_auth

prow/istio-pilot-e2e-envoyv2-v1alpha3.sh
d110f1f2bad4db1d2f88a25c3a15d9687349c0e7
link
/test istio-pilot-e2e-envoyv2-v1alpha3

Instructions for interacting with me using PR comments are available here.  If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here.

@islinwb: The following tests failed, say /retest to rerun them all:

Test name
Commit
Details
Rerun command

prow/e2e-dashboard.sh
d110f1f2bad4db1d2f88a25c3a15d9687349c0e7
link
/test e2e-dashboard

prow/e2e-bookInfoTests-v1alpha3.sh
d110f1f2bad4db1d2f88a25c3a15d9687349c0e7
link
/test e2e-bookInfo-envoyv2-v1alpha3

prow/e2e-mixer-no_auth.sh
d110f1f2bad4db1d2f88a25c3a15d9687349c0e7
link
/test e2e-mixer-no_auth

prow/istio-pilot-e2e-envoyv2-v1alpha3.sh
d110f1f2bad4db1d2f88a25c3a15d9687349c0e7
link
/test istio-pilot-e2e-envoyv2-v1alpha3

prow/istio-pilot-multicluster-e2e.sh
d110f1f2bad4db1d2f88a25c3a15d9687349c0e7
link
/test istio-pilot-multicluster-e2e

Instructions for interacting with me using PR comments are available here.  If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here.

@islinwb: The following tests failed, say /retest to rerun them all:

Test name
Commit
Details
Rerun command

prow/e2e-dashboard.sh
d110f1f2bad4db1d2f88a25c3a15d9687349c0e7
link
/test e2e-dashboard

prow/e2e-bookInfoTests-v1alpha3.sh
d110f1f2bad4db1d2f88a25c3a15d9687349c0e7
link
/test e2e-bookInfo-envoyv2-v1alpha3

prow/e2e-mixer-no_auth.sh
d110f1f2bad4db1d2f88a25c3a15d9687349c0e7
link
/test e2e-mixer-no_auth

prow/istio-pilot-e2e-envoyv2-v1alpha3.sh
d110f1f2bad4db1d2f88a25c3a15d9687349c0e7
link
/test istio-pilot-e2e-envoyv2-v1alpha3

prow/istio-pilot-multicluster-e2e.sh
d110f1f2bad4db1d2f88a25c3a15d9687349c0e7
link
/test istio-pilot-multicluster-e2e

prow/e2e-simpleTests.sh
d110f1f2bad4db1d2f88a25c3a15d9687349c0e7
link
/test e2e-simple

Instructions for interacting with me using PR comments are available here.  If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here.

@islinwb: The following tests failed, say /retest to rerun them all:

Test name
Commit
Details
Rerun command

prow/e2e-dashboard.sh
d110f1f2bad4db1d2f88a25c3a15d9687349c0e7
link
/test e2e-dashboard

prow/e2e-bookInfoTests-v1alpha3.sh
d110f1f2bad4db1d2f88a25c3a15d9687349c0e7
link
/test e2e-bookInfo-envoyv2-v1alpha3

prow/e2e-mixer-no_auth.sh
d110f1f2bad4db1d2f88a25c3a15d9687349c0e7
link
/test e2e-mixer-no_auth

prow/istio-pilot-e2e-envoyv2-v1alpha3.sh
d110f1f2bad4db1d2f88a25c3a15d9687349c0e7
link
/test istio-pilot-e2e-envoyv2-v1alpha3

prow/e2e-simpleTests.sh
d110f1f2bad4db1d2f88a25c3a15d9687349c0e7
link
/test e2e-simple

prow/istio-pilot-multicluster-e2e.sh
d110f1f2bad4db1d2f88a25c3a15d9687349c0e7
link
/test istio-pilot-multicluster-e2e

Instructions for interacting with me using PR comments are available here.  If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here.

Thanks @myidpt @incfly !


Investigate efficiency of harmonisation pipeline for WGS studies

We would like to verify whether there is a significant difference in efficiency of the hm pipeline for seq GWAS.

Calculate the average % of dropped and unable to harmonise variants among a representative sample of array-based summary statistics.
Calculate the average % of dropped and unable to harmonise variants

If possible it could be useful to analyse separately for GWAS-SSF and pre-GWAS-SSF formats

Genome-wide sequencing:

GWAS_id
Techniques
harmonised
Raw_rows
Harmonised_rows
hm_14
hm_15
hm_16
Drop_ration
hm_15(%)

1
GCST90010173
Genome-wide sequencing
yes
24181159
18290576
0
0
0
24.36%
0.00%

2
GCST90093113
Genome-wide sequencing
yes
7173861
7164907
0
47998
0
0.12%
0.67%

3
GCST90001390
Genome-wide sequencing
yes
7843596
7654311
0
45969
2
2.41%
0.59%

4
GCST90014052
Genome-wide sequencing
yes
5056041
5056029
0
11168
2
0.00%
0.22%

5
GCST90161593
Genome-wide sequencing
yes
10004360
9450643
0
0
0
5.53%
0.00%

V.S.
Genome-wide genotyping array:

PMID
GCST_id
genotyping array
harmonised
Raw_rows
Harmonised_rows
hm_14
hm_15
hm_16
Drop_ration
hm_15(%)

33589840
GCST90012878
Genome-wide genotyping array
yes
25643629
25367157
0
292056
67
1.08%
1.14%

28887542
GCST005069
Genome-wide genotyping array
yes
25290284
25186082
19
179244
2
0.41%
0.71%

33782385
GCST012278
Genome-wide genotyping array
yes
7216416
7180648
1
35317
0
0.50%
0.49%

33143745
GCST90093334
Genome-wide genotyping array
yes
8034880
7982170
0
131524
18
0.66%
1.64%

30053915
GCST006353
Genome-wide genotyping array
yes
5694112
5692296
7
24756
0
0.03%
0.43%

Next to do:

GCST90010173, and GCST90161593:  explore the reason why ~20% variants are dropped in the harmonised file.
Run harmonisation against the new ensemble version as well.
Priority to harmonise data for 33937362, 35381062, 36124557, 36206743, 36327219, 36349687.

Reason why variants are dropped

GCST90010173: contains lots of variants that reference allele=alternative allele ~ 10.5%; ~14% variants cannot find VCF records
GCST90161593: 5% variants cannot find VCF records

Run harmonisation against the new ensemble version as well.

V_95 (2018)
V_105 (2021)
V_111 (2023)
Total variants
2% variants

GCST90010173
75.64%
75.76%
78.39%
24181159
483623.18

GCST90179391
79.04%
74.38%
77.75%
30566328
611326.56

For variants that can be harmonised by V_95 but not V_111, it happens to two conditions:

Some indels: variants representation in V_95 and V_111 are 1-base shift. These VCF records cannot be retrieved from the V_111 correctly and their indels representations are different from the input file.
Some snps: multiple records can be retrieved from V_111, our pipeline does not know which is the correct one.

Ben suggested reserving a whole node to run the pipeline. Need to contact TSC if it is allowed to do
Yue will compare running speeds on 400 studies on:

Running job on slurm
Running job using the spotbot account
Using the nextflow tower to profile.

@ljwh2 Can we close this ticket?
After our investigation:

There were only 5 whole genome sequencing data.
The rate of harmonization among these five studies varies widely, ranging from 75% to 100%.
Compared to Genome-wide genotyping array data, which harmonisation rate varied from 98.02% to 99.97%, 4. There is no strong conclusion that the harmonization rate is significantly lower among the WGS.

We also tried to investigate if the updated reference VCF file improved the harmonisation rate among the WGS data, we tested on 8 studies, and 3 studies increased the rate and the other 5 decreased. Therefore, new reference VCF does not necessarily improve the harmonisation rate.
Our collaborator mentioned that they cannot use the variants that cannot be harmonised.


WIP: Search Work Items by Type

Fixes #474
Adds a "type:" special search parameter tag to the full text search like the "id:" tag. Multiple type tags, can be passed. The search will return work items that match any of the types. Work Items of subtypes will be returned, also.

Current coverage is 65.20% (diff: 80.95%)

Merging #486 into master will decrease coverage by 0.65%

@@             master       #486   diff @@
==========================================
  Files            46         48     +2
  Lines          2252       2345    +93
  Methods           0          0
  Messages          0          0
  Branches          0          0
==========================================
+ Hits           1483       1529    +46
- Misses          614        654    +40
- Partials        155        162     +7

Powered by Codecov. Last update fc34e51...79730a4


Recommended approach for disabling all interactions in a MRTK enabled UI Canvas

Describe the issue
Let's say we have a couple of pages swiping from left to right. The PressableButton together with the RectTransformColliderFitter will nicely shorten the box collider as a page transitions across the "screen" and outside the "UI Mask", meaning you can't click buttons that are off screen. Great!
However, how does one disable the buttons while they are transitioning? We want to block users from accidentally pressing buttons that are going off or coming onto the screen.
There's no clear way to do this.
In native unity UI you would just disable the Graphics Raycaster or put an invisible component over the screen to block raycasts, but there's no way to do this in MRTK.
What we've tried so far:

Turn off the colliders on the buttons, but there seems to be a single physics update frame where the buttons are still active (so you can quickly click two buttons (navigate left and navigate right) on the same screen even though both button colliders are disabled as soon as one of the OnClick events are fired).
Turn off the button. This kinda works, but for some reason MRTK has decided that component.enabled = button.interactable, so not only does the visual appearance of the buttons change, but now we also have to manually save and restore the "previous" interactable state of the button, which quickly becomes a nightmare.

So main question: How should one turn off a whole "canvas" of MRTK UI?
Feature area
MRTK Canvas UI

@TheXRMonk can you please describe the end user impact of this issue?  What issue are you hitting "while buttons are transitioning"?

A few tricks that could be useful for situations like this:

Adjust the raycast mask for the XRRayInteractor while you would like to disable input, e.g. to remove a particular layer and then re-add it afterwards
Add a temporary large collider to capture raycasts before they hit a particular panel (this may not work well if the user would be very close to the panel)
Switch the layers of the interactables in question so they are temporarily not targetable by the interactor raycasts.

It would be great to understand more about your use case -- why are users attempting to click while a view is paging? Did their interaction cause the transition or is it happening automatically or on a timer?

A few tricks that could be useful for situations like this:

Adjust the raycast mask for the XRRayInteractor while you would like to disable input, e.g. to remove a particular layer and then re-add it afterwards
Add a temporary large collider to capture raycasts before they hit a particular panel (this may not work well if the user would be very close to the panel)
Switch the layers of the interactables in question so they are temporarily not targetable by the interactor raycasts.

We're only using near interactions - no rays. Not sure point 3 will solve it, but that might be possible,

It would be great to understand more about your use case -- why are users attempting to click while a view is paging? Did their interaction cause the transition or is it happening automatically or on a timer?

Basically when a user clicks "next" the page transitions a whole page. While this is happening the user's finger might be accidentally clicking buttons that are "transitioning" across the screen, leading to the UI reacting to for instance going back again to the previous page, or fast forwarding to the next one before being able.

I'm sorry we haven't had the time to look into this yet. We'll probably have to go with the raycast layering approach though, since we also now have "pop-up dialogs" in the UI that requires buttons behind to be disabled, so in that case disabling the whole poke/ray will not work since we still need it for clicking the pop-up dialog.


Allow absolute redirect URIs

Currently, when you configure a redirect_uri that is an absolute URI, it has its path extracted and appended to the request domain to create the actual redirect_uri sent to Github. So, for example, if you have a redirect_uri of test1.example.com/callback but your app runs on test2.example.com, the redirect_uri sent to Github will be test2.example.com/callback. In most cases, this is the intended behavior, since Github doesn't allow redirect URIs that aren't extensions of the callback URI.
This patch allows redirect_uris that are specified as absolute URIs to retain their domains, which allows, for example, OAuth schemes where a single app is the "OAuth broker" for several other apps. See http://stackoverflow.com/a/13841857 for an example. Using this patch, I was able to set up a single OAuth broker for many apps as described in the example.
A little background to motivate why you would ever want to do this: we have a simple database admin app that takes, as configuration, a single connection url. For any database, say, db1, we expose this admin app on its own subdomain, e.g.,  db1.example.com. We have dozens of these admin apps and don't want to create a Github OAuth config for each individual one, so instead we set up a single db.example.com app as the "broker". When a request comes in to db1.example.com that needs authorization, it hits the Github OAuth endpoint with a redirect_uri of db.example.com/auth/github/callback/db1.example.com. When db.example.com gets the call back from Github on that path, it just fowards it (along with the code and state) back to db1.example.com/auth/github/callback, which checks the state and finishes the OAuth flow.

No.

Sorry for the blunt reply. I have no intention of supporting this type of approach. If you have multiple unique hostnames serving frontend traffic I'd suggest you setup separate applications or put them behind a load balancer.


[MySql/MariaDb] Insert an boolean type has invalid result (Always insert true in a bit column)

Hi,
With the following code, i have 2 different behaviours when the column's type is bit or tiny(1).
var items = new List<ConsoleApp1.BooleanBulkInsertDbContext.TestClass>()
{
    new()
    {
        Name = "Is active is true",
        IsActive = true,
    },
    new()
    {
        Name = "Is active is false",
        IsActive = false,
    }
};

DbContext context = GetDbContext();

context.BulkInsert(items);

When the column's type is tinyint(1), the inserted result is :

When the column's type is bit, the inserted result is :

Closing this for now, if you manage to make it reproducible, write it here and will reopen.

Open this back up please. This is reproduceable.
MySQL: 8.0.25
EFCore.BulkExtensions: 8.1.0
EFCore: 8.0.8
DTO:
public class DailyOption
{
	public int DailyOptionId { get; set; }
	public DateOnly Time { get; set; }
	public bool IsCall { get; set; }
}

Database Table:
CREATE TABLE `DailyOption` (
  `DailyOptionId` int NOT NULL AUTO_INCREMENT,
  `Time` date NOT NULL,
  `IsCall` bit(1) NOT NULL,
  PRIMARY KEY (`DailyOptionId`),
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;


Add message time to live in RabbitMQ, Azure Service Bus/Storage Queue bindings

Description
Add time to live when writing to RabbitMQ, Azure Service Bus and Azure Storage Queue bindings. Time to live is defined in seconds. It can be defined in two places:

binding definition, setting the ttl  property (in RabbitMQ and Service Bus sets the default time to live in the queue definition)
when writing to the binding, setting the property ttl in the request metadata (overrides the binding definition if one was set)

I have added integration tests for RabbitMQ and Service Bus. They are skipped unless specific environment variables are set. It would be great to enable them at some point. Please let me know if I can assist some how.
Issue reference
#126 (Sub-item "As a publisher I want to define message TTL in order to expire stale content")
Checklist
Please make sure you've completed the relevant tasks for this PR, out of the following list:

[x] Code compiles correctly
[x] Created/updated tests
[ ] Extended the documentation

Thanks for the contribution @fbeltrao , we will review it soon.

Thansk for the contribution @fbeltrao , I have added few comments. Also please open a issue in docs repo to update the docs to show usage of ttl in binding metadata in request metadata as well.
eg. for rabbit mq it would be in:
https://github.com/dapr/docs/blob/master/reference/specs/bindings/rabbitmq.md

Docs issue: https://github.com/dapr/docs/issues/515


Add all items counter on the homepage

In this pull request I've created a counter function following the next rules:

Each counter should be implemented as a separate module.
A counter function should look for specific DOM elements (e.g. for the comments counter it should look for comments) and make the counting based on what is actually displayed on the page.
A counter function should cover all the edge cases you can think about.

You did great Dani! Go on and merge into the dev branch. Congratulations and happy coding🎉🎉🎉


Fix aws user role to work with Ansible 2.2

The complex module parameters member no longer exists. Instead,
loop over the creation results in parallel with the input params
that includes the generated password.

:+1:  works for me.

:+1:
Sounds like things changed in 2.2


How to use voxelsdk without cmake?

Can I use voxelsdk with makefile only? Because I am wrapping voxelsdk into another sdk, which didn't use cmake system. Thank you !

Yes, you can, though you'll have to take care of some things. I would
suggest you to build Voxel SDK as is using cmake and then copy necessary
headers and libraries as explained below.

Build SDK and install it into a folder /path/to/folder as follows in
build folder inside Voxel SDK.
---- For Linux ---
cmake -DCMAKE_INSTALL_PREFIX=/path/to/folder ..
sudo make install
---- For Windows ---
cmake -DCMAKE_INSTALL_PREFIX=/path/to/folder ..
cmake --target INSTALL --config Release --build .

Copy /path/to/folder to your new SDK, and then in your custom make
system, set the following
-- Add include path -- /path/to/folder/include/voxel-x.y.z/
-- Link main program to -- /path/to/folder/lib/libvoxel.so (in Linux),
/path/to/folder/lib/voxel.dll (in Windows)

To run your program, please set environment variables as explained in
https://github.com/3dtof/voxelsdk/wiki/Build-from-source-on-Linux#running-from-source
for Linux and
https://github.com/3dtof/voxelsdk/wiki/Build-from-source-on-Windows#running-sdk-programs
for Windows.

Hope this helps.
On 9 December 2015 at 15:42, JoeyZhu<EMAIL_ADDRESS>wrote:

Can I use voxelsdk with makefile only? Because I am wrapping voxelsdk into
another sdk, which didn't use cmake system. Thank you !
—
Reply to this email directly or view it on GitHub
https://github.com/3dtof/voxelsdk/issues/46.

--
~ Prasad Bhat

hlproasu, Thank you for your detail instruction, I successed to compile my DepthCapture_demo.cpp with g++ DepthCapture_demo.cpp -I /usr/include/voxel/ -L/usr/lib/voxel/ -lvoxel -std=c++11


ImportError: libcuda.so.1: cannot open shared object file: No such file or directory

System Info
OS version: Ubuntu 22.04.3 LTS
Model: codellama/CodeLlama-13b-Instruct-hf
nvidia-smi output:
+---------------------------------------------------------------------------------------+
| NVIDIA-SMI 545.23.08              Driver Version: 545.23.08    CUDA Version: 12.3     |
|-----------------------------------------+----------------------+----------------------+
| GPU  Name                 Persistence-M | Bus-Id        Disp.A | Volatile Uncorr. ECC |
| Fan  Temp   Perf          Pwr:Usage/Cap |         Memory-Usage | GPU-Util  Compute M. |
|                                         |                      |               MIG M. |
|=========================================+======================+======================|
|   0  NVIDIA GeForce RTX 4090        On  | 00000000:21:00.0 Off |                  Off |
|  0%   24C    P8              13W / 450W |     16MiB / 24564MiB |      0%      Default |
|                                         |                      |                  N/A |
+-----------------------------------------+----------------------+----------------------+
|   1  NVIDIA GeForce RTX 4090        On  | 00000000:41:00.0 Off |                  Off |
|  0%   19C    P8               4W / 450W |    562MiB / 24564MiB |      0%      Default |
|                                         |                      |                  N/A |
+-----------------------------------------+----------------------+----------------------+

Information

[X] Docker
[ ] The CLI directly

Tasks

[X] An officially supported command
[ ] My own modifications

Reproduction
model=codellama/CodeLlama-13b-Instruct-hf
volume=$PWD/data

docker run --shm-size 1g -p 8080:80 -v $volume:/data ghcr.io/huggingface/text-generation-inference:2.0 --model-id $model --quantize eetq

Expected behavior
The TGI should run. Because I am just copying official script and running it.
Logs
2024-06-14T10:50:09.534843Z  INFO hf_hub: Token file not found "/root/.cache/huggingface/token"
2024-06-14T10:50:11.548549Z  INFO text_generation_launcher: Model supports up to 16384 but tgi will now set its default to 4096 instead. This is to save VRAM by refusing large prompts in order to allow more users on the same hardware. You can increase that size using --max-batch-prefill-tokens=16434 --max-total-tokens=16384 --max-input-tokens=16383.
2024-06-14T10:50:11.548570Z  INFO text_generation_launcher: Default max_input_tokens to 4095
2024-06-14T10:50:11.548575Z  INFO text_generation_launcher: Default max_total_tokens to 4096
2024-06-14T10:50:11.548579Z  INFO text_generation_launcher: Default max_batch_prefill_tokens to 4145
2024-06-14T10:50:11.548582Z  INFO text_generation_launcher: Using default cuda graphs [1, 2, 4, 8, 16, 32]
2024-06-14T10:50:11.548733Z  INFO download: text_generation_launcher: Starting download process.
2024-06-14T10:50:14.670106Z  INFO text_generation_launcher: Files are already present on the host. Skipping download.
2024-06-14T10:50:15.057638Z  INFO download: text_generation_launcher: Successfully downloaded weights.
2024-06-14T10:50:15.058027Z  INFO shard-manager: text_generation_launcher: Starting shard rank=0
2024-06-14T10:50:17.213782Z  WARN text_generation_launcher: Could not import Flash Attention enabled models: cannot import name 'FastLayerNorm' from 'text_generation_server.layers.layernorm' (/opt/conda/lib/python3.10/site-packages/text_generation_server/layers/layernorm.py)
2024-06-14T10:50:17.861867Z ERROR shard-manager: text_generation_launcher: Shard complete standard error output:
The installed version of bitsandbytes was compiled without GPU support. 8-bit optimizers, 8-bit multiplication, and GPU quantization are unavailable.
Traceback (most recent call last):
File "/opt/conda/lib/python3.10/site-packages/text_generation_server/utils/paged_attention.py", line 10, in
from vllm._C import cache_ops
ImportError: libcuda.so.1: cannot open shared object file: No such file or directory
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/opt/conda/bin/text-generation-server", line 8, in
sys.exit(app())
File "/opt/conda/lib/python3.10/site-packages/text_generation_server/cli.py", line 71, in serve
from text_generation_server import server
File "/opt/conda/lib/python3.10/site-packages/text_generation_server/server.py", line 17, in
from text_generation_server.models.pali_gemma import PaliGemmaBatch
File "/opt/conda/lib/python3.10/site-packages/text_generation_server/models/pali_gemma.py", line 5, in
from text_generation_server.models.vlm_causal_lm import (
File "/opt/conda/lib/python3.10/site-packages/text_generation_server/models/vlm_causal_lm.py", line 14, in
from text_generation_server.models.flash_mistral import (
File "/opt/conda/lib/python3.10/site-packages/text_generation_server/models/flash_mistral.py", line 18, in
from text_generation_server.models.custom_modeling.flash_mistral_modeling import (
File "/opt/conda/lib/python3.10/site-packages/text_generation_server/models/custom_modeling/flash_mistral_modeling.py", line 30, in
from text_generation_server.utils import paged_attention, flash_attn
File "/opt/conda/lib/python3.10/site-packages/text_generation_server/utils/paged_attention.py", line 13, in
raise ImportError(
ImportError: Could not import vllm paged attention. Make sure your installation is correct. Complete error: libcuda.so.1: cannot open shared object file: No such file or directory
rank=0
Error: ShardCannotStart
2024-06-14T10:50:17.960026Z ERROR text_generation_launcher: Shard 0 failed to start
2024-06-14T10:50:17.960047Z  INFO text_generation_launcher: Shutting down shards

Hey @muhammadbaqir1327, thanks for your report! Do you get the issue even with the newest container?
It would change your code as such:
model=codellama/CodeLlama-13b-Instruct-hf
volume=$PWD/data

- docker run --shm-size 1g -p 8080:80 -v $volume:/data ghcr.io/huggingface/text-generation-inference:2.0 --model-id $model --quantize eetq
+ docker run --shm-size 1g -p 8080:80 -v $volume:/data ghcr.io/huggingface/text-generation-inference:2.0.4 --model-id $model --quantize eetq

Yes, I have already tried it
@LysandreJik

Ok, thanks! Let's try to see what's going on. This seems like a setup/CUDA issue, and I don't see you passing the GPUs to the docker image. Could you try by having a --gpus all additional flag?
So this command:
docker run --gpus all --shm-size 1g -p 8080:80 -v $volume:/data ghcr.io/huggingface/text-generation-inference:2.0.4 --model-id $model --quantize eetq

Yes, I have also tried that command. It also not worked for me.
I also think it is related to CUDA installation. I tried to run nvcc --version. But it said that command is not available.
You can check similar type issue on this link: https://forums.developer.nvidia.com/t/nvcc-command-not-found-and-unable-to-install-nvidia-cuda-toolkit-in-the-jetpack-6/275486

If nvcc --version doesn't work I'm not sure the problem lies in TGI unfortunately, it seems to be linked to an issue with your setup :confused:

Ok, thanks! Let's try to see what's going on. This seems like a setup/CUDA issue, and I don't see you passing the GPUs to the docker image. Could you try by having a --gpus all additional flag?
So this command:
docker run --gpus all --shm-size 1g -p 8080:80 -v $volume:/data ghcr.io/huggingface/text-generation-inference:2.0.4 --model-id $model --quantize eetq

By running this command. It produced following logs:
2024-06-14T15:27:13.274448Z  INFO text_generation_launcher: Args {
    model_id: "codellama/CodeLlama-13b-Instruct-hf",
    revision: None,
    validation_workers: 2,
    sharded: None,
    num_shard: None,
    quantize: Some(
        Eetq,
    ),
    speculate: None,
    dtype: None,
    trust_remote_code: false,
    max_concurrent_requests: 128,
    max_best_of: 2,
    max_stop_sequences: 4,
    max_top_n_tokens: 5,
    max_input_tokens: None,
    max_input_length: None,
    max_total_tokens: None,
    waiting_served_ratio: 0.3,
    max_batch_prefill_tokens: None,
    max_batch_total_tokens: None,
    max_waiting_tokens: 20,
    max_batch_size: None,
    cuda_graphs: None,
    hostname: "c9facdfbc83e",
    port: 80,
    shard_uds_path: "/tmp/text-generation-server",
    master_addr: "localhost",
    master_port: 29500,
    huggingface_hub_cache: Some(
        "/data",
    ),
    weights_cache_override: None,
    disable_custom_kernels: false,
    cuda_memory_fraction: 1.0,
    rope_scaling: None,
    rope_factor: None,
    json_output: false,
    otlp_endpoint: None,
    cors_allow_origin: [],
    watermark_gamma: None,
    watermark_delta: None,
    ngrok: false,
    ngrok_authtoken: None,
    ngrok_edge: None,
    tokenizer_config_path: None,
    disable_grammar_support: false,
    env: false,
    max_client_batch_size: 4,
}
2024-06-14T15:27:13.274521Z  INFO hf_hub: Token file not found "/root/.cache/huggingface/token"
2024-06-14T15:27:14.789216Z  INFO text_generation_launcher: Model supports up to 16384 but tgi will now set its default to 4096 instead. This is to save VRAM by refusing large prompts in order to allow more users on the same hardware. You can increase that size using `--max-batch-prefill-tokens=16434 --max-total-tokens=16384 --max-input-tokens=16383`.
2024-06-14T15:27:14.789235Z  INFO text_generation_launcher: Default `max_input_tokens` to 4095
2024-06-14T15:27:14.789240Z  INFO text_generation_launcher: Default `max_total_tokens` to 4096
2024-06-14T15:27:14.789244Z  INFO text_generation_launcher: Default `max_batch_prefill_tokens` to 4145
2024-06-14T15:27:14.789248Z  INFO text_generation_launcher: Using default cuda graphs [1, 2, 4, 8, 16, 32]
2024-06-14T15:27:14.789408Z  INFO download: text_generation_launcher: Starting download process.
2024-06-14T15:27:17.653212Z  INFO text_generation_launcher: Files are already present on the host. Skipping download.

2024-06-14T15:27:18.095517Z  INFO download: text_generation_launcher: Successfully downloaded weights.
2024-06-14T15:27:18.095844Z  INFO shard-manager: text_generation_launcher: Starting shard rank=0
2024-06-14T15:27:23.081981Z ERROR text_generation_launcher: Error when initializing model
Traceback (most recent call last):
  File "/opt/conda/bin/text-generation-server", line 8, in <module>
    sys.exit(app())
  File "/opt/conda/lib/python3.10/site-packages/typer/main.py", line 311, in __call__
    return get_command(self)(*args, **kwargs)
  File "/opt/conda/lib/python3.10/site-packages/click/core.py", line 1157, in __call__
    return self.main(*args, **kwargs)
  File "/opt/conda/lib/python3.10/site-packages/typer/core.py", line 778, in main
    return _main(
  File "/opt/conda/lib/python3.10/site-packages/typer/core.py", line 216, in _main
    rv = self.invoke(ctx)
  File "/opt/conda/lib/python3.10/site-packages/click/core.py", line 1688, in invoke
    return _process_result(sub_ctx.command.invoke(sub_ctx))
  File "/opt/conda/lib/python3.10/site-packages/click/core.py", line 1434, in invoke
    return ctx.invoke(self.callback, **ctx.params)
  File "/opt/conda/lib/python3.10/site-packages/click/core.py", line 783, in invoke
    return __callback(*args, **kwargs)
  File "/opt/conda/lib/python3.10/site-packages/typer/main.py", line 683, in wrapper
    return callback(**use_params)  # type: ignore
  File "/opt/conda/lib/python3.10/site-packages/text_generation_server/cli.py", line 90, in serve
    server.serve(
  File "/opt/conda/lib/python3.10/site-packages/text_generation_server/server.py", line 257, in serve
    asyncio.run(
  File "/opt/conda/lib/python3.10/asyncio/runners.py", line 44, in run
    return loop.run_until_complete(main)
  File "/opt/conda/lib/python3.10/asyncio/base_events.py", line 636, in run_until_complete
    self.run_forever()
  File "/opt/conda/lib/python3.10/asyncio/base_events.py", line 603, in run_forever
    self._run_once()
  File "/opt/conda/lib/python3.10/asyncio/base_events.py", line 1909, in _run_once
    handle._run()
  File "/opt/conda/lib/python3.10/asyncio/events.py", line 80, in _run
    self._context.run(self._callback, *self._args)
> File "/opt/conda/lib/python3.10/site-packages/text_generation_server/server.py", line 220, in serve_inner
    model = get_model(
  File "/opt/conda/lib/python3.10/site-packages/text_generation_server/models/__init__.py", line 560, in get_model
    return FlashLlama(
  File "/opt/conda/lib/python3.10/site-packages/text_generation_server/models/flash_llama.py", line 79, in __init__
    weights = Weights(filenames, device, dtype, process_group=self.process_group)
  File "/opt/conda/lib/python3.10/site-packages/text_generation_server/utils/weights.py", line 24, in __init__
    with safe_open(filename, framework="pytorch") as f:
safetensors_rust.SafetensorError: Error while deserializing header: InvalidHeaderDeserialization

2024-06-14T15:27:23.607129Z ERROR shard-manager: text_generation_launcher: Shard complete standard error output:

/opt/conda/lib/python3.10/site-packages/huggingface_hub/file_download.py:1132: FutureWarning: `resume_download` is deprecated and will be removed in version 1.0.0. Downloads always resume when possible. If you want to force a new download, use `force_download=True`.
  warnings.warn(
The tokenizer class you load from this checkpoint is not the same type as the class this function is called from. It may result in unexpected tokenization.
The tokenizer class you load from this checkpoint is 'CodeLlamaTokenizer'.
The class this function is called from is 'LlamaTokenizer'.
You are using the default legacy behaviour of the <class 'transformers.models.llama.tokenization_llama.LlamaTokenizer'>. This is expected, and simply means that the `legacy` (previous) behavior will be used so nothing changes for you. If you want to use the new behaviour, set `legacy=False`. This should only be set if you understand what it means, and thoroughly read the reason why this was added as explained in https://github.com/huggingface/transformers/pull/24565
/opt/conda/lib/python3.10/site-packages/torch/distributed/distributed_c10d.py:658: UserWarning: You are using a Backend <class 'text_generation_server.utils.dist.FakeGroup'> as a ProcessGroup. This usage is deprecated since PyTorch 2.0. Please use a public API of PyTorch Distributed instead.
  warnings.warn(
Traceback (most recent call last):

  File "/opt/conda/bin/text-generation-server", line 8, in <module>
    sys.exit(app())

  File "/opt/conda/lib/python3.10/site-packages/text_generation_server/cli.py", line 90, in serve
    server.serve(

  File "/opt/conda/lib/python3.10/site-packages/text_generation_server/server.py", line 257, in serve
    asyncio.run(

  File "/opt/conda/lib/python3.10/asyncio/runners.py", line 44, in run
    return loop.run_until_complete(main)

  File "/opt/conda/lib/python3.10/asyncio/base_events.py", line 649, in run_until_complete
    return future.result()

  File "/opt/conda/lib/python3.10/site-packages/text_generation_server/server.py", line 220, in serve_inner
    model = get_model(

  File "/opt/conda/lib/python3.10/site-packages/text_generation_server/models/__init__.py", line 560, in get_model
    return FlashLlama(

  File "/opt/conda/lib/python3.10/site-packages/text_generation_server/models/flash_llama.py", line 79, in __init__
    weights = Weights(filenames, device, dtype, process_group=self.process_group)

  File "/opt/conda/lib/python3.10/site-packages/text_generation_server/utils/weights.py", line 24, in __init__
    with safe_open(filename, framework="pytorch") as f:

safetensors_rust.SafetensorError: Error while deserializing header: InvalidHeaderDeserialization
 rank=0
2024-06-14T15:27:23.706513Z ERROR text_generation_launcher: Shard 0 failed to start
2024-06-14T15:27:23.706536Z  INFO text_generation_launcher: Shutting down shards

One point I forget to mention while running docker run, I was getting hf_transfer error. So by searching some solutions, I fixed it by adding HF_HUB_ENABLE_HF_TRANSFER=0 variable in the command, like this:
docker run --env --env HF_HUB_ENABLE_HF_TRANSFER=0 ...

@LysandreJik

Hmmm these are different problems. The safetensors_rust.SafetensorError: Error while deserializing header: InvalidHeaderDeserialization points to an error with the model you have loaded.
Is it possible for you to load it in Python directly using the safetensors library?
from safetensors import safe_open
import torch

model = hf_hub_download(repo_id=model_id, filename="model.safetensors")

tensors = {}
with safe_open(model, framework="pt", device="cpu") as f:
   for key in f.keys():
       tensors[key] = f.get_tensor(key)

Can you please share with me code snippet, how can I load model weights. As TGI has downloaded weights in /data directory.
By listing it gives following output:
user:~/data/models--codellama--CodeLlama-13b-Instruct-hf$ ls
blobs  refs  snapshots

How can I load these weights? @LysandreJik

Hmmm these are different problems. The safetensors_rust.SafetensorError: Error while deserializing header: InvalidHeaderDeserialization points to an error with the model you have loaded.
Is it possible for you to load it in Python directly using the safetensors library?
from safetensors import safe_open
import torch

model = hf_hub_download(repo_id=model_id, filename="model.safetensors")

tensors = {}
with safe_open(model, framework="pt", device="cpu") as f:
   for key in f.keys():
       tensors[key] = f.get_tensor(key)

I tried to load model weights using this script.
device = torch.device("cuda" if torch.cuda.is_available() else "cpu")

model = snapshot_download(
    repo_id="codellama/CodeLlama-13b-Instruct-hf",
    cache_dir=cache_dir,
    local_files_only=True,
)

tensors = {}
with safe_open(model, framework="pt", device=device) as f:
   for key in f.keys():
       tensors[key] = f.get_tensor(key)

It is showing this error:
Traceback (most recent call last):
  File "test.py", line 17, in <module>
    with safe_open(model, framework="pt", device=device) as f:
         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
safetensors_rust.SafetensorError: device cuda is invalid

Using device="cpu". It is producing following error:
with safe_open(model, framework="pt", device="cpu") as f:
         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
OSError: No such device (os error 19)

This issue
ImportError: libcuda.so.1: cannot open shared object file: No such file or directory
was due to not passing --gpus flag in docker command.
As discussed here: https://stackoverflow.com/questions/54249577/importerror-libcuda-so-1-cannot-open-shared-object-file#comment136144707_68587460
@LysandreJik

Glad you could get it resolved!