no-extra-semi: False positive when required between symbols

Validations

[X] Follow our Code of Conduct
[X] Read the Contributing Guide.
[X] Check that there isn't already an issue that reports the same bug to avoid creating a duplicate.

Describe the bug
For example here https://github.com/adamlui/ai-web-extensions/blob/main/chatgpt-infinity/chrome/extension/content.js#L275-L281:
...
    };

    // Add STARS styles
    ['black', 'white'].forEach(color => document.head.append(
        dom.create.elem('link', { rel: 'stylesheet',
            href: `https://assets.aiwebextensions.com/styles/css/${color}-rising-stars.min.css?v=50f457d`
    })))
...

... it is required after the } or else the code is treated like {...}[...] and the script crashes
Reproduction
https://github.com/adamlui/ai-web-extensions/actions/runs/12044843022/job/33582490607
Contributes

[X] I am willing to submit a PR to fix this issue
[X] I am willing to submit a PR with failing tests

It does not seems to be a bug.
I looked at all the failed cases in https://github.com/adamlui/ai-web-extensions/actions/runs/12044843022.
All of them are
if (boolean) {
  // ...some logic
};

['black', 'white'].forEach(() => {
  // ...some logic
})

Even if it doesn't have a semicolon after the if expression, it's still considered an IfStatement and an ExpressionStatement. Adding a semicolon brings an EmptyStatement, so this semicolon is indeed extra, as reported by this rule.

@9romise it doesn't matter if it's an if or expression statement, the point is the semicolon is required or interpreter will read the code wrong and script crashes. Therefore the semicolon is absolutely required and not "extra" (this rule is supposed to safely warn users to remove them, removing here breaks script)

@9romise look again at the code
    if (!tweaksStyle || parseInt(tweaksStyle.getAttribute('last-updated')) < tweaksStyleUpdated) {
        if (!tweaksStyle) { // outright missing, create/id/attr/append it first
            tweaksStyle = dom.create.elem('style',
                { id: 'tweaks-style', 'last-updated': tweaksStyleUpdated.toString() })
            document.head.append(tweaksStyle)
        }
        tweaksStyle.innerText = '* { scrollbar-width: thin }' // make FF scrollbar skinny to not crop toggle
    }; // eslint-disable-line

    // Add STARS styles
    ['black', 'white'].forEach(color => document.head.append(
        dom.create.elem('link', { rel: 'stylesheet',
            href: `https://assets.aiwebextensions.com/styles/rising-stars/css/${color}.min.css?v=891df10`
    })))

Without required semicolon, interpreter reads it like if (condition) { logic }[array].forEach(callback) which is nonsensical, so it is not extra but required (has nothing to do with if/expressionempty statements, semicolons are sometimes required for correct interpretation and this rule must not interfere in those cases

Another example to make you understand the point of linting rules: if programmer wrote alert('hi') ; alert('there') and a plugin warns it is "extra" user expects to remove it and code run fines. But just like in prev example, there will be uncaught error instead, because it is 100% required thus not an "extra" symbol then name of this rule implies what it's truly supposed to catch (i.e. not required ones like in both examples for script to run)

Also the statement's not empty but even if it was, a no-empty warning is supposed to handle that. This rule is called no-extra-semi instead, means warn user don't use unrequired semis, not when it's required like here

TLDR semicolon is required here (i.e. not extra) or else code breaks, so this bug must be patched to correctly account for curly brace at ends of if blocks and follow-up opening square brackets of arrays
(plugin already correctly accounts for other similar cases that do not show false warning like above, for example here:
    update.style.tweaks() ; document.head.append(tweaksStyle);

    // Add STARS styles
    ['black', 'white'].forEach(color => document.head.append(
        dom.create.elem('link', { rel: 'stylesheet',
            href: `https://assets.aiwebextensions.com/styles/rising-stars/css/${color}.min.css?v=891df10`
    })))

@9romise when you close this valid issue you're essentially telling user to work around the bug by doing whatever they're already doing (in this case using eslint-disable-line) which just makes code worse for having noise and making filesize larger, defeating purpose of ESLint

The examples you give https://github.com/eslint-stylistic/eslint-stylistic/issues/622#issuecomment-2542688560 and https://github.com/eslint-stylistic/eslint-stylistic/issues/622#issuecomment-2542688560 don't match the issue, and semicolons are really needed here, but our issue is whether semicolons are needed after if expressions' } and before arrays' [.
Can you give a minimal repro like this?
if (condition) {
  // ...some logic
}
[array].forEach(() => {
  // ...some logic
})

I tried a simple use case but couldn't reproduce it, here are my use cases and results:
Windows Chrome 131.0.6778.140

Windows node.js 22.11.0

@9romise when you close this valid issue you're essentially telling user to work around the bug by doing whatever they're already doing (in this case using eslint-disable-line) which just makes code worse for having noise and making filesize larger, defeating purpose of ESLint

I closed it only because I found out that it was a misjudgment, that it wasn't actually a bug, and that it didn't cause the error to happen (or that the existing information didn't allow me to reproduce it). If it's valid, I'd be happy to reopen it and fix it.

@9romise I think you are right, in my example I tested it is not required! Sorry for my reaction

But in the examples where it's truly required, ESLint doesn't warn user, do you agree it is good idea?

For example paste this in console
console.log('sup')
['adam', 'bob'].forEach(dude => console.log(dude))

... and without semi you get Uncaught TypeError: console.log(...) is undefined

Also here https://github.com/adamlui/ai-web-extensions/blob/1c43a3e6a739ba06f50208968522b62c276e94b6/chatgpt-infinity/chrome/extension/content.js#L138-L148:
...
    // Add LISTENER to auto-disable Infinity Mode
    document.onvisibilitychange = () => {
        if (config.infinityMode) {
            settings.save('infinityMode', false) ; syncConfigToUI({ updatedKey: 'infinityMode' }) }
    }

    // Add STARS styles
    ['black', 'white'].forEach(color => document.head.append(
        dom.create.elem('link', { rel: 'stylesheet',
            href: `https://assets.aiwebextensions.com/styles/rising-stars/css/${color}.min.css?v=891df10`
    })))
...

... if semicolon is inserted there is no no-extra-semi warning when there shuold be

You can try semi.

You can try using semi.

Rule Details
This rule enforces consistent use of semicolons.

But I and most others don't want to consistently use them, so isn't it a good idea to warn users when it's required as a general rule since code will break otherwise? (Not a stylistic warning but in case you have pull in the core project)

I think it’s hard to say whether a semicolon is absolutely necessary since there are cases where it’s intentional.
For me, the semi and the beforeStatementContinuationChars option in stylistic rules are good enough for handling this. Additionally, indent already shows unexpected indentation when a needed semicolon is missing, which works fine for me.
However, others might have better ideas, you could open an issue in the ESLint repo to bring more people into the discussion.

I think it’s hard to say whether a semicolon is absolutely necessary since there are cases where it’s intentional.

I meant this example:
console.log('sup')
['adam', 'bob'].forEach(dude => console.log(dude))

... it is required to not break, so do you agree it is good idea in core ESLint to warn (not use stylistic semi since breaking is not stylistic reason)

For me, the semi and the beforeStatementContinuationChars option in stylistic rules are good enough for handling this. Additionally, indent already shows unexpected indentation when a needed semicolon is missing, which works fine for me.

But not everyone agrees on same styles like some don't want to import those rules at all, then the breaking change as in above example goes undetected

However, others might have better ideas, you could open an issue in the ESLint repo to bring more people into the discussion.

Maybe I will but wanted to know if you agree first it is good idea to warn about missing semis that break code without relying on stylistic rules


Implement sort

Pre-Flight checklist

[x] Screenshots and design review for any changes that affect layout or styling

[x] Desktop screenshots
[x] Mobile width screenshots

[x] Testing

[ ] Code is tested
[x] Changes have been manually tested

What are the relevant tickets?
Fixes https://github.com/mitodl/course-search-utils/issues/21
What's this PR do?
Implements sort for courses. There are two options at the moment: "Relevance" and "MIT course nr"
How should this be manually tested?

Make sure you have the course index updated. If you haven't, you will need to rebuild the docker container on open-discussions to get the latest version of ocw-data-parser, then run ./manage.py recreate_index --course.
Go to /search and click the sort dropdown, then change to "MIT course nr". When you switch to "MIT course nr" you should see a s=coursenum parameter appear in the URL. The search results should appear to sort by course number.
You should be able to switch back and forth between "MIT course nr" and "Relevance" and see expected results. The text and facets should remain when you switch sorting.
If you refresh the browser you should see the same sort items, as well as the same facets and text as before
You should be able to click the back and forward buttons and not see any inconsistencies. The browser history stack should not change as a result of clicking either the back or forward buttons

Screenshots

@noisecapella I ran a yarn install and tried this again and the search page loads properly now, but when I change the sort dropodown I get some more errors in the console and the results don't load:
before changing dropdown:

after changing dropdown:

@gumaerc you will need to rebuild open-discussions to have the latest ocw-data-parser, and then reindex courses on open-discussions

The intention was that they would be side-by-side (at least for desktop). Current implementation, with count:

Sort implementation:

I think you can see how they can fit together (if you ignore my imprecise screenshot skills)

@pdpinch I had this thought as well, but as I noted above this might be problematic for the mobile layout.  As it is, the Sort By dropdown wraps around onto the next line on mobile.  Do we want to punt on that for now until we can come up with a specific mobile design?

@pdpinch Should I just squeeze everything together for desktop and ignore how it looks on mobile?


pip install pygeos with pypy3.7 leads to faillure

Hi team,
I am trying to install pygeoswith pypy3 -m pip install, but it leads to build failure.
PS C:\Users\aniwax\Documents\GitHub\ibrus_new_design> pypy3 -m pip install pygeos                                       Collecting pygeos
  Using cached pygeos-0.10.tar.gz (106 kB)
  Installing build dependencies ... done
  Getting requirements to build wheel ... done
    Preparing wheel metadata ... done
Requirement already satisfied: numpy>=1.13 in c:\users\aniwax\pypy3.7-v7.3.5-win64\pypy3.7-v7.3.5-win64\site-packages (from pygeos) (1.20.2)
Building wheels for collected packages: pygeos
  Building wheel for pygeos (PEP 517) ... error
  ERROR: Command errored out with exit status 1:
   command: 'C:\Users\aniwax\pypy3.7-v7.3.5-win64\pypy3.7-v7.3.5-win64\pypy3.exe' 'C:\Users\aniwax\pypy3.7-v7.3.5-win64\pypy3.7-v7.3.5-win64\site-packages\pip\_vendor\pep517\_in_process.py' build_wheel 'C:\Users\aniwax\AppData\Local\Temp\tmpts3tl1pm'
       cwd: C:\Users\aniwax\AppData\Local\Temp\pip-install-98ehg0ai\pygeos
  Complete output (48 lines):
  Could not find geos-config executable. Either append the path to geos-config to PATH or manually provide the include_dirs, library_dirs, libraries and other link args for compiling against a GEOS version >=3.5.
  running bdist_wheel
  running build
  running build_py
  creating build
  creating build\lib.win-amd64-3.7
  creating build\lib.win-amd64-3.7\pygeos
  copying pygeos\constructive.py -> build\lib.win-amd64-3.7\pygeos
  copying pygeos\coordinates.py -> build\lib.win-amd64-3.7\pygeos
  copying pygeos\creation.py -> build\lib.win-amd64-3.7\pygeos
  copying pygeos\decorators.py -> build\lib.win-amd64-3.7\pygeos
  copying pygeos\enum.py -> build\lib.win-amd64-3.7\pygeos
  copying pygeos\geometry.py -> build\lib.win-amd64-3.7\pygeos
  copying pygeos\io.py -> build\lib.win-amd64-3.7\pygeos
  copying pygeos\linear.py -> build\lib.win-amd64-3.7\pygeos
  copying pygeos\measurement.py -> build\lib.win-amd64-3.7\pygeos
  copying pygeos\predicates.py -> build\lib.win-amd64-3.7\pygeos
  copying pygeos\set_operations.py -> build\lib.win-amd64-3.7\pygeos
  copying pygeos\strtree.py -> build\lib.win-amd64-3.7\pygeos
  copying pygeos\_version.py -> build\lib.win-amd64-3.7\pygeos
  copying pygeos\__init__.py -> build\lib.win-amd64-3.7\pygeos
  running egg_info
  writing pygeos.egg-info\PKG-INFO
  writing dependency_links to pygeos.egg-info\dependency_links.txt
  writing requirements to pygeos.egg-info\requires.txt
  writing top-level names to pygeos.egg-info\top_level.txt
  reading manifest file 'pygeos.egg-info\SOURCES.txt'
  adding license file 'LICENSE'
  writing manifest file 'pygeos.egg-info\SOURCES.txt'
  copying pygeos\_geometry.c -> build\lib.win-amd64-3.7\pygeos
  copying pygeos\_geometry.pyx -> build\lib.win-amd64-3.7\pygeos
  copying pygeos\_geos.c -> build\lib.win-amd64-3.7\pygeos
  copying pygeos\_geos.pxd -> build\lib.win-amd64-3.7\pygeos
  copying pygeos\_geos.pyx -> build\lib.win-amd64-3.7\pygeos
  copying pygeos\_pygeos_api.pxd -> build\lib.win-amd64-3.7\pygeos
  UPDATING build\lib.win-amd64-3.7\pygeos/_version.py
  set build\lib.win-amd64-3.7\pygeos/_version.py to '0.10'
  running build_ext
  building 'pygeos.lib' extension
  creating build\temp.win-amd64-3.7
  creating build\temp.win-amd64-3.7\Release
  creating build\temp.win-amd64-3.7\Release\src
  C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\VC\Tools\MSVC\14.28.29910\bin\HostX86\x64\cl.exe /c /nologo /Ox /W3 /GL /DNDEBUG /MD -IC:\Users\aniwax\pypy3.7-v7.3.5-win64\pypy3.7-v7.3.5-win64\include -IC:\Users\aniwax\AppData\Local\Temp\pip-build-env-5f6wb7j8\overlay\site-packages\numpy\core\include -IC:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\VC\Tools\MSVC\14.28.29910\ATLMFC\include -IC:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\VC\Tools\MSVC\14.28.29910\include -IC:\Program Files (x86)\Windows Kits\10\include\10.0.19041.0\ucrt -IC:\Program Files (x86)\Windows Kits\10\include\10.0.19041.0\shared -IC:\Program Files (x86)\Windows Kits\10\include\10.0.19041.0\um -IC:\Program Files (x86)\Windows Kits\10\include\10.0.19041.0\winrt -IC:\Program Files (x86)\Windows Kits\10\include\10.0.19041.0\cppwinrt /Tcsrc/c_api.c /Fobuild\temp.win-amd64-3.7\Release\src/c_api.obj
  c_api.c
  C:\Users\aniwax\AppData\Local\Temp\pip-install-98ehg0ai\pygeos\src\geos.h(12): warning C4068: unknown pragma 'GCC'
  C:\Users\aniwax\AppData\Local\Temp\pip-install-98ehg0ai\pygeos\src\geos.h(13): warning C4068: unknown pragma 'GCC'
  C:\Users\aniwax\AppData\Local\Temp\pip-install-98ehg0ai\pygeos\src\geos.h(14): fatal error C1083: Cannot open include file: 'geos_c.h': No such file or directory
  error: command 'C:\\Program Files (x86)\\Microsoft Visual Studio\\2019\\Enterprise\\VC\\Tools\\MSVC\\14.28.29910\\bin\\HostX86\\x64\\cl.exe' failed with exit status 2
  ----------------------------------------
  ERROR: Failed building wheel for pygeos
Failed to build pygeos
ERROR: Could not build wheels for pygeos which use PEP 517 and cannot be installed directly

I know in general, you guys suggest to use conda instead of pip, but since all my other dependencies are installed with pip, it's just easier to keep it in the same place.
It would be great if you guys can provide a .whl file for installing pygeos on pypy. Or anything that works with pip on pypy. Thanks a lot!

Operating System: Windows 64, amd
Pypy versions:  [PyPy 7.3.5 with MSC v.1927 64 bit (AMD64)],  [PyPy 7.3.4 with MSC v.1927 64 bit (AMD64)] on win32

Hi @Aniwax,
Compiling from source on windows can be hard, because GEOS is not found automatically. You’ll have to download and install GEOS from https://trac.osgeo.org/osgeo4w/ and then  set GEOS_INCLUDE_PATH and GEOS_LIBRARY_PATH environment variables accordingly.
I am not sure what directories will be used, but you’ll have to make sure that the library path contains the .dll and the include path the .h files.
I hope that works!
And pypy wheels are indeed missing. Let’s keep this issue open and try to arrange that.

Duplicate of #371 - closing. @Aniwax please feel free to reopen if you have questions or updates on building on Pypy.


Gateway theme

Work with Ilya @ HUBzero to customize gateways theme (layout, navigations, colors, images, fonts)

Jack from Hubzero will be doing the implementation of Ilya's theme design for our gateway

theme Q & A @ https://docs.google.com/document/d/1yzBFmHk91PZ1dvDm6837qA0mz7Ym3mqpw4ofKnfcJF0/edit#heading=h.e7ecjkkqd8gv


Added: Longest Common Prefix Program

Issue Resolved

Closes #1804

Algorithm Added
Longest Common Prefix
Description
This program finds the Longest Common Prefix (LCP) among an array of strings. The LCP is the longest sequence of characters shared at the beginning of all strings in the array. The program employs an efficient algorithm to identify the common prefix by comparing the strings character by character.
Example:
Enter the number of strings: 5
Enter the strings:
String 1: prawn
String 2: prajakta
String 3: prince
String 4: probably
String 5: project

Output:
The longest common prefix is: pr

@pankaj-bind Please review the PR at your convinience

Also, after the recent PR, you merged:

PR #1821

The Contributor has again broken the codebase cloning due to improper directory path naming:

The space in the Folder name is failing the cloning process:

@pankaj-bind please do assign the PR to me. I had opened an unmerged PR request as instructed by the Core team.


Bug when using cancelPositionsMulti

Hello, I just found a bug when using cancelPositionsMulti (with Advisory demo account).
I am not sure where exactly the problem is (thats why I am writing this topic) but basically it doesnt work and after using this command the whole API breaks (sending random messages to the API etc..)
Here is the script which you can use to reproduce this bug:
test.js:
const { IBApi, EventName } = require("@stoqey/ib")

const ib = new IBApi({
    clientId: 1,
    host: "<IP_ADDRESS>",
    port: 7497,
})

ib.on(EventName.info, (msg, code) => {
    console.log("INFO", code, msg)
})

ib.on(EventName.error, (err, code, reqId) => {
    console.error("ERROR", reqId, code, err.message)
})

ib.on(EventName.nextValidId, (id) => {
    console.log("nextValidId", id)
})

ib.on(EventName.positionMulti, (reqId, account, modelCode, contract, pos, avgCost) => {
    console.log("positionMulti", reqId, account, modelCode, JSON.stringify(contract), pos)
})

ib.on(EventName.positionMultiEnd, (reqId) => {
    console.log("positionMultiEnd", reqId)

})

ib.connect()

async function delay(ms) {
	const res = await new Promise((resolve, reject) => { setTimeout(() => { return resolve(true) }, ms) })
	return res
}

setTimeout(async() => {
    console.log("reqPositionsMulti 1")
    ib.reqPositionsMulti(1, "DU010", "")

    console.log("Waiting 5 sec...")
    await delay(5000)

    console.log("cancelPositionsMulti 1")
    ib.cancelPositionsMulti(1)

    console.log("reqPositionsMulti 2")
    ib.reqPositionsMulti(2, "DU010", "")

    console.log("Exiting in 5 sec...")
    await delay(5000)
    ib.disconnect()
}, 1000)

test.js output:
nextValidId 1
INFO 2104 Market data farm connection is OK:usfuture
INFO 2104 Market data farm connection is OK:eufarm
INFO 2107 HMDS data farm connection is inactive but should be available upon demand.euhmds
INFO 2158 Sec-def data farm connection is OK:secdefeu
reqPositionsMulti 1
Waiting 5 sec...
positionMulti 1 DU010  {"conId":637533398,"symbol":"MES","secType":"FUT","lastTradeDateOrContractMonth":"20240920","strike":0,"multiplier":5,"exchange":"","currency":"USD","localSymbol":"MESU4","tradingClass":"MES"} 2
positionMultiEnd 1
cancelPositionsMulti 1
reqPositionsMulti 2
Exiting in 5 sec...
ERROR 1 321 Error validating request.-'bj' : cause - Account/Group '74' is incorrect. Valid accounts: ''; 'DF01A'; 'DF01'; 'DU010'; 'DU011'; 'DU012';  Valid groups: ''; 'All'; 'test_group_1';
INFO 320 Error reading request. Unable to parse data. java.lang.NumberFormatException: For input string: "DU010"

The behavior when using the official Python API client is normal, here you can see the script used and the output.
test.py:
import asyncio
from ibapi.client import EClient
from ibapi.wrapper import EWrapper

class IBApiWrapper(EWrapper):
    def __init__(self):
        super().__init__()

class IBApiClient(EClient):
    def __init__(self, wrapper):
        EClient.__init__(self, wrapper)

class IBApiApp(IBApiWrapper, IBApiClient):
    def __init__(self):
        IBApiWrapper.__init__(self)
        IBApiClient.__init__(self, wrapper=self)

    def nextValidId(self, orderId: int):
        super().nextValidId(orderId)
        self.nextOrderId = orderId
        print(f"Next valid order ID: {orderId}")

    def positionMulti(self, reqId, account, modelCode, contract, pos, avgCost):
       print("PositionMulti. reqId:", reqId, "Account:", account, "ModelCode:", modelCode, "Contract:", contract, ",Position:", pos, "AvgCost:", avgCost)

    def positionMultiEnd(self, reqId):
        print("PositionMultiEnd. reqId:", reqId)

async def run_loop(app):
    while True:
        app.run()

async def main():
    app = IBApiApp()
    app.connect('<IP_ADDRESS>', 7497, clientId=1)

    loop = asyncio.get_event_loop()
    loop.run_in_executor(None, app.run)

    await asyncio.sleep(1)

    print("reqPositionsMulti 1")
    app.reqPositionsMulti(1, "DU010", "")

    print("Waiting 5 sec...")
    await asyncio.sleep(5)

    print("cancelPositionsMulti 1")
    app.cancelPositionsMulti(1)

    print("reqPositionsMulti 2")
    app.reqPositionsMulti(2, "DU010", "")

    print("Exiting in 5 sec...")
    await asyncio.sleep(5)
    app.disconnect()

asyncio.run(main())

test.py output:
Next valid order ID: 1
ERROR -1 2104 Market data farm connection is OK:usfuture
ERROR -1 2104 Market data farm connection is OK:eufarm
ERROR -1 2107 HMDS data farm connection is inactive but should be available upon demand.euhmds
ERROR -1 2158 Sec-def data farm connection is OK:secdefeu
reqPositionsMulti 1
Waiting 5 sec...
PositionMulti. reqId: 1 Account: DU010 ModelCode:  Contract: 637533398,MES,FUT,20240920,0,,5,,,USD,MESU4,MES,False,,,,combo: ,Position: 2 AvgCost: 28216.87
PositionMultiEnd. reqId: 1
cancelPositionsMulti 1
reqPositionsMulti 2
Exiting in 5 sec...
PositionMulti. reqId: 2 Account: DU010 ModelCode:  Contract: 637533398,MES,FUT,20240920,0,,5,,,USD,MESU4,MES,False,,,,combo: ,Position: 2 AvgCost: 28216.87
PositionMultiEnd. reqId: 2

Could you please check this issue?
Thank you <3

Hello,
Thanks for your documented bug report.
I've been able to reproduce the problem; but at the moment I don't see any reason for this as those API calls implementation are quite basic.
I will look at this deeper when I have some free time.
Regards

src/tests/unit/api/positions.test.ts
  console.log
    positionMultiEnd 45

      at IBApi.<anonymous> (src/tests/unit/api/positions.test.ts:96:17)
          at Array.forEach (<anonymous>)

  console.log
    cancelPositionsMulti sent 46

      at IBApi.<anonymous> (src/tests/unit/api/positions.test.ts:99:17)
          at Array.forEach (<anonymous>)

  console.log
    reqPositionsMulti sent 47

      at IBApi.<anonymous> (src/tests/unit/api/positions.test.ts:102:17)
          at Array.forEach (<anonymous>)

 FAIL  src/tests/unit/api/positions.test.ts
  IBApi Tests
    ✓ Test reqPositions / cancelPositions (86 ms)
    ✕ Test reqPositionsMulti / cancelPositionsMulti (62 ms)

  ● IBApi Tests › Test reqPositionsMulti / cancelPositionsMulti

    Failed: "[46] Error validating request.-'bj' : cause - Model name '1' is incorrect. Valid model name: ''; 'Core';  (#321)"

I got it! :)
I will publish a fix in the next few days

Fixed in 1.3.26


Can we port the open issues to the Microsoft repo please?

From @garethj-msft on August 9, 2017 1:15
Would you like us to go and open equivalent ones, so the users are right?
Copied from original issue: dgriffen/WhackWhackTerminal#19

I looked into porting the existing issues and there doesn't appear to be a good built in way to do that. If you know of one that would be great.

From @garethj-msft on August 10, 2017 6:44
https://github-issue-mover.appspot.com/


Feature request: add way to get total cores per system

uv_cpu_info is great for getting an idea how to distribute I/O-bound workloads, but CPU-bound workloads tend to not gain much from SMT (and sometimes even lose performance), so I'd like a way to get the total cores instead so I can more effectively balance them.
As an implementation note, most devices only support 1-2 threads per core, but this isn't universal - IBM's Power series chips generally do nowadays with the decade-old POWER7 supporting 4 threads per core and all subsequent iterations supporting 8 threads per core (including the Power10 released last year). So you can't just check if SMT is available and double the core count.

It's not wholly clear to me if you're asking for physical or logical core count. Either has the problem that not all cores may be available to your program.
Libuv has a uv_available_parallelism() function as of v1.44.0, see #3493 for background. Is that perhaps what you're looking for?

@bnoordhuis Specifically physical core count. uv_cpu_info returns only logical cores, and it doesn't include any field for physical core IDs (I could just count uniques with that). A way to get the true number of physical cores available to the program would technically be ideal, of course, but that's beyond my immediate needs.
Of course, I could also just parse /proc/cpuinfo to get this information too (as I also happen to control the OS it runs on), and it's not that hard to loop through. If this is preferred to actually implementing it in libuv, feel free to close this.

Sounds reasonable, I think. I don't plan on working on it myself but if you send a pull request, I'll be happy to review it.

I'll go ahead and close this out but you're still welcome to send a PR.


Would you please export a version for JetBrains IDEs?

I love this theme very much. But due to compatibility reason I cannot use VSCode as main editor in my office dev environment. I've searched solutions but nothing worked. An export would be helpful a lot. And thanks for your hard working!

I dont use any of the jetbrains products so can't really help much there. have you tried something like this? found it after a quick google search: https://github.com/JetBrains/colorSchemeTool

Thank you for you kindly reply! I've already tried this convert tool. It worked all in all but only editor scheme affected, the terminal and IDE main color theme were ignored. And I've tried to check the JSON in this repository to customize one but the working was not very satisfying.
I'm considering to try more customizing to make a better ported version when I have enough spare time.

you can also look at my nvim repo, which I maintain more actively and has ports for different applications. maybe there'll be something there that will help with jetbrains. good luck with your port if you ever get around to it!


Test numeric edge case for repartition with npartitions.

We had an issue with Dask 1.2.0 where repartitioning a certain number of source partitions into a certain number of target partitions led to one partition missing from the result. In the end, we found that this is because of a numeric instability when determining divisions (dividing and multiplying again with the same number might not always yield exactly the original number, but slightly less, which causes a problem here: https://github.com/dask/dask/blob/master/dask/dataframe/core.py#L5516).
Example:
>>> (15/11)*11
14.999999999999998
>>> int((15/11)*11)
14

With Dask >=2, the problem was fixed by introducing this check: https://github.com/dask/dask/commit/c4b677086a20a73977ba5731b0798db0032cbba5#diff-492da7893fa5fa6ad3a6ef6cdef985f2R4821
Nevertheless, it would be safer to preclude any chance of the same bug being introduced again by adding a test, as done by this PR.

[ x ] Tests added / passed
[ x ] Passes black dask / flake8 dask

Thanks for the contribution @amerkel2 .  Adding this test seems reasonable to me :)


Allow CI/CD to fail for external PRs without required permissions

Overview
There are currently two actions in the CI that require write permission to the repository in order to work correctly:

Add Coverage PR Comment: Adds code coverage report to PR.
Deploy if PR: Adds documentation generation to PR.

The issue has been reported in #401 .
Solution
Changing the permissions for external PRs could be a security issue, therefore silent failure was chosen as the preferred method.
This PR adds  continue-on-error  to allow for step failure, and makes the step Add comment if PR dependent on success of Deploy if PR.

@nelimee I hope the actions will work right away. Changes to actions by externals need to be approved each time, not ideal for debugging.

One minor note: you seem to sign your commits with an email that is not recognized as the same account as the one you are using to submit the PRs. This might impact how you appear as a collaborator to the project (I do not know which account will be picked). This is not an issue for the repository, just checking that this is also not an issue for you.

Seems like the issue comes from the fact that the last step of deploy is failing. Maybe just also adding a continue-on-error there would be sufficient?

One minor note: you seem to sign your commits with an email that is not recognized as the same account as the one you are using to submit the PRs. This might impact how you appear as a collaborator to the project (I do not know which account will be picked). This is not an issue for the repository, just checking that this is also not an issue for you.

Thanks for noticing. Fixed my local git config.

@nelimee apparently I have no write access, so I cannot merge. :/

I just looked at it. It would require us to give write permission to anyone wanting to merge a PR. Let's keep the current status-quo for the moment: users outside of the tqec organisation will have to wait for someone in the organisation to merge their PR. Thanks for the contribution!


Upgrade to use fstring

PR Summary:
Relate to https://github.com/mosdef-hub/gmso/issues/344. this PR update all python files with py36+ syntax using pyupgrade
PR Checklist

[ ] Includes appropriate unit test(s)
[ ] Appropriate docstring(s) are added/updated
[ ] Code is (approximately) PEP8 compliant
[ ] Issue(s) raised/addressed?

Just realize this may not be the best time to do this since it may cause too much conflicts with others' activities


Need an API to print to standard error stream

Description:
io:println currently prints to std out stream. But we also need an API where the user can get the std err stream to print any messages. This is specially helpful when printing some log messages that should go to err stream in the cases for error like messages.
For example, jvm_backend prints the compilation time error messages that can come from java interop validation to the console using the io:println which goes to std out stream. But this should ideally go to the std err stream.
Steps to reproduce:
Affected Versions:
OS, DB, other environment details and versions:
Related Issues (optional):

Suggested Labels (optional):

Suggested Assignees (optional):

Related issue - https://github.com/ballerina-platform/ballerina-lang/issues/8952

This seems like a pretty reasonable request. Is there a reason it hasn't been done (asking because I'm new to this language). Looking at the code, it should be fairly simple to add. But given that it has not gained much traction I wonder if it's an undesired feature for the core developers.
If no I'm OK sending a pull request..

In the meantime, I'm workarounding it with:
import ballerina/java;

function main() {
  eprint("This is printed to stderr");
}

function eprint(string message) {
    stdErrPrintln(errStream(), java:fromString(message));
}

function errStream() returns handle = @java:FieldGet {
   name:"err",
   class:"java.lang.System"
} external;

function stdErrPrintln(handle foo, handle bar) = @java:Method {
   name: "println",
   class: "java.io.PrintStream",
   paramTypes: ["java.lang.String"]
} external;

@casidiablo Currently we are going through an API review for all the standard library modules. Definitely we will consider this as well. @daneshk FYI.
And you are always welcome to send PR to any issue.


fix(vue-app): fixPrepatch in-out transition fix (#5797)

Types of changes

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

Description

Resolves: #5797
Problem: fixPrepatch + $data updates after component mounted twice. (in-out transition mode)
Please review and check if has side effect
Checklist:

[ ] My change requires a change to the documentation.
[ ] I have updated the documentation accordingly. (PR: #)
[ ] I have added tests to cover my changes (if not applicable, please state why)
[x] All new and existing tests are passing.

Codecov Report

Merging #5824 into dev will not change coverage.
The diff coverage is n/a.

@@           Coverage Diff           @@
##              dev    #5824   +/-   ##
=======================================
  Coverage   95.68%   95.68%
=======================================
  Files          82       82
  Lines        2687     2687
  Branches      689      689
=======================================
  Hits         2571     2571
  Misses         98       98
  Partials       18       18

Flag
Coverage Δ

#e2e
100% <ø> (ø)
:arrow_up:

#fixtures
50.42% <ø> (ø)
:arrow_up:

#unit
92.66% <ø> (ø)
:arrow_up:

Continue to review full report at Codecov.

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


npm install is failing for 4.0.0-beta1 on linux

When I try to install mocha-phantomjs it is failing because the phantomjs2 dependency is failing, but I'm not sure how phantomjs2 is a dependency because according to package.js it would seem that phantomjs v1.9 is the dependency, not v2: https://github.com/metaskills/mocha-phantomjs/blob/master/package.json#L39
However, here is what I am seeing:
sudo npm install -g mocha-phantomjs
-
><EMAIL_ADDRESS>install /usr/lib/node_modules/mocha-phantomjs/node_modules/phantomjs2
> node install.js

Downloading https://github.com/bprodoehl/phantomjs/releases/download/2.0.0-20141016/phantomjs-2.0.0-20141016-linux-x86_64.zip
Saving to /usr/lib/node_modules/mocha-phantomjs/node_modules/phantomjs2/phantomjs/phantomjs-2.0.0-20141016-linux-x86_64.zip
Receiving...
Install exited unexpectedly

I tried to create a ticket on the phantomjs repo here: https://github.com/ariya/phantomjs/issues/13376 but it seems that project isn't responsible for the npm installer, they redirected me here: https://github.com/bprodoehl/phantomjs but that project doesn't have issues enabled, so I thought I would give it one last try and post here, since you guys could at least address the dependency on the broken project. Or is this project similar to phantomjs and you don't manage the npm installer either?

I just tried this and it worked just fine: npm install -g https://github.com/metaskills/mocha-phantomjs/archive/v3.5.3.tar.gz
So something isn't quite right with whatever is on npm it seems :(

Hmmm doh I put up v4 as an early beta but I thought it should be hidden and not the default... I'll look into that. It's faling as phantomjs2 doesn't have built Linux binaries.
npm install mocha-phantomjs@<4 for now.

Hmm I just did npm install mocha-phantomjs. Do you have some npm config setup to get beta packages? I can only get to it by installing the specific version full package version, which is my intention.
~/temp/test
 9:04AM ᐅ npm install mocha-phantomjs@4
npm ERR! Darwin 14.3.0
npm ERR! argv "node" "/usr/local/bin/npm" "install" "mocha-phantomjs@4"
npm ERR! node v0.12.2
npm ERR! npm  v2.12.1
npm ERR! code ETARGET

npm ERR! notarget No compatible version found<EMAIL_ADDRESS><5.0.0'
npm ERR! notarget Valid install targets:
npm ERR! notarget ["1.0.0","1.0.1","1.1.0","1.1.1","1.1.2","1.1.3","2.0.0","2.0.1","2.0.2","2.0.3","3.0.0","3.1.0","3.1.1","3.1.2","3.1.3","3.1.4","3.1.5","3.1.6","3.2.0","3.3.0","3.3.1","3.3.2","3.4.0","3.4.1","3.5.0","3.5.1","3.5.2","3.5.3","4.0.0-beta1"]
npm ERR! notarget
npm ERR! notarget This is most likely not a problem with npm itself.
npm ERR! notarget In most cases you or one of your dependencies are requesting
npm ERR! notarget a package version that doesn't exist.

npm ERR! Please include the following file with any support request:
npm ERR!     /Users/nblack/temp/test/npm-debug.log

~/temp/test
 9:05AM ᐅ npm install<EMAIL_ADDRESS>|
><EMAIL_ADDRESS>install /Users/nblack/temp/test/node_modules/mocha-phantomjs/node_modules/phantomjs2
> node install.js

Looks like an `npm install -g`; unable to check for already installed version.
Download already available at /var/folders/81/0crqt_td7nj1v7gwscvg9x9c0000gn/T/phantomjs/phantomjs-2.0.0-20141016-macosx.zip
Extracting zip contents
Removing /Users/nblack/temp/test/node_modules/mocha-phantomjs/node_modules/phantomjs2/lib/phantom
Copying extracted folder /var/folders/81/0crqt_td7nj1v7gwscvg9x9c0000gn/T/phantomjs/phantomjs-2.0.0-20141016-macosx.zip-extract-1436025934720/phantomjs-2.0.0-20141016 -> /Users/nblack/temp/test/node_modules/mocha-phantomjs/node_modules/phantomjs2/lib/phantom
Removing /var/folders/81/0crqt_td7nj1v7gwscvg9x9c0000gn/T/phantomjs/phantomjs-2.0.0-20141016-macosx.zip-extract-1436025934720
Writing location.js file
Done. Phantomjs binary available at /Users/nblack/temp/test/node_modules/mocha-phantomjs/node_modules/phantomjs2/lib/phantom/bin/phantomjs
<EMAIL_ADDRESS>node_modules/mocha-phantomjs
├──<EMAIL_ADDRESS><EMAIL_ADDRESS>├──<EMAIL_ADDRESS>└──<EMAIL_ADDRESS><EMAIL_ADDRESS><EMAIL_ADDRESS><EMAIL_ADDRESS><EMAIL_ADDRESS><EMAIL_ADDRESS><EMAIL_ADDRESS><EMAIL_ADDRESS><EMAIL_ADDRESS><EMAIL_ADDRESS><EMAIL_ADDRESS>

Hi there,
I think I ran into some similar issue
$ npm install -g mocha-phantomjs
|
><EMAIL_ADDRESS>install C:\Users\nicolas\AppData\Roaming\npm\node_modules\mocha-phantomjs\node_modules\phant
omjs2
> node install.js

PhantomJS detected, but wrong version 1.9.8 @ c:\Program Files (x86)\PhantomJS\phantomjs.EXE.
Unexpected platform or architecture: win32 x64
npm ERR! Windows_NT 6.1.7601
npm ERR! argv "c:\\Program Files\\nodejs\\node.exe" "c:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli
.js" "install" "-g" "mocha-phantomjs"
npm ERR! node v0.12.4
npm ERR! npm  v2.10.1
npm ERR! code ELIFECYCLE

npm ERR<EMAIL_ADDRESS>install: `node install.js`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the<EMAIL_ADDRESS>install script 'node install.js'.

Even if I have an older version (1.9.8) it still tries to install phantomJS2 and fails.
it worked with npm install -g https://github.com/metaskills/mocha-phantomjs/archive/v3.5.3.tar.gz thanks @socketwiz

Can you guys share your ~/npmrc file ? For some reason your npm is choosing a beta package. Tl;Dr phantomjs2 has no official binaries for Linux so the install is failing.

I don't have one (?)
(windows 7)

I don't have one either, centos v6.6

I tried this on my mac, where I also don't have an ~/npmrc and it works there, but only because it seems the phantomjs2 binary is available for mac.  And you're right, this it is installing 4.0.0-beta1, but why it the broken beta the default, why not make the default a stable release?
Rickys-Mac-Pro.local ➜  bin git:(master) ✗ cat ~/npmrc
cat: /Users/socketwiz/npmrc: No such file or directory
Rickys-Mac-Pro.local ➜  bin git:(master) ✗ npm install -g mocha-phantomjs
-
><EMAIL_ADDRESS>install /usr/local/lib/node_modules/mocha-phantomjs/node_modules/phantomjs2
> node install.js

Downloading https://github.com/bprodoehl/phantomjs/releases/download/2.0.0-20141016/phantomjs-2.0.0-20141016-macosx.zip
Saving to /var/folders/n1/t4bzvjv50cq9zqcdmzx9nv6w0000gn/T/phantomjs/phantomjs-2.0.0-20141016-macosx.zip
Receiving...
  [================================--------] 80% 0.0s
Received 17340K total.
Extracting zip contents
Removing /usr/local/lib/node_modules/mocha-phantomjs/node_modules/phantomjs2/lib/phantom
Copying extracted folder /var/folders/n1/t4bzvjv50cq9zqcdmzx9nv6w0000gn/T/phantomjs/phantomjs-2.0.0-20141016-macosx.zip-extract-1436266136828/phantomjs-2.0.0-20141016 -> /usr/local/lib/node_modules/mocha-phantomjs/node_modules/phantomjs2/lib/phantom
Removing /var/folders/n1/t4bzvjv50cq9zqcdmzx9nv6w0000gn/T/phantomjs/phantomjs-2.0.0-20141016-macosx.zip-extract-1436266136828
Writing location.js file
Done. Phantomjs binary available at /usr/local/lib/node_modules/mocha-phantomjs/node_modules/phantomjs2/lib/phantom/bin/phantomjs
/usr/local/bin/mocha-phantomjs -> /usr/local/lib/node_modules/mocha-phantomjs/bin/mocha-phantomjs
<EMAIL_ADDRESS>/usr/local/lib/node_modules/mocha-phantomjs
├──<EMAIL_ADDRESS><EMAIL_ADDRESS>├──<EMAIL_ADDRESS>└──<EMAIL_ADDRESS><EMAIL_ADDRESS><EMAIL_ADDRESS><EMAIL_ADDRESS><EMAIL_ADDRESS><EMAIL_ADDRESS><EMAIL_ADDRESS><EMAIL_ADDRESS><EMAIL_ADDRESS><EMAIL_ADDRESS><EMAIL_ADDRESS>Rickys-Mac-Pro.local ➜  bin git:(master) ✗ mocha-phantomjs --version
4.0.0-beta1

I've unpublished 4.0.0-beta1. Anyone that was depending on this, please install via the github tag v4.0.0-beta1 or branch v4.


internal/tray: change the text and behavior of the self tray item a bit

This tweaks the text, changes the way it's calculated slightly, and adds the ability to copy the displayed IP address to the clipboard by clicking on it.

CC @slagiewka.

this app always has some handle to a window

It doesn't, unfortunately. I realized yesterday that a.win is nil if the window isn't visible. I need to come up with a way around that problem before I can merge this. I found a way to get a clipboard reference without needing a widget, but attempting to use it fails silently when using it.


Add some option sliders

5 sliders for users to set at will, for scripters to alter script behavior according to activated sliders.
Both the name and the tooltip can be changed through a lua script.
Testing script:
function stateCheck(state)
	for i = 1, 5 do
		if getOption(i) != state then
			return false
		end
	end

	return true
end

names = {"Yo momma", "is so fat", "that her", "blood type", "is type Ragu"}

for i = 1, 5 do
	setOptionName(i, names[i])
	setOptionDescription(i, "This is Option " .. i .. "'s description, set by a script.\nThis is a new line.")
end

if stateCheck(true) then log("Turning all sliders off!")
elseif stateCheck(false) then log("Turning all sliders on!")
else log("Reverting all sliders!")
end

for i = 1, 5 do
	setOption(i, not getOption(i))
end

While this is a good feature, it looks way too confusing as it is.
New users won't understand what these five sliders are doing here.
Maybe we should find a way to only display the sliders required by a script.
Also, I'm sure we can remove all the code duplication in MainWindow.xaml using the sender of the event.

Ask and ye shall receive. Sliders are now hidden by default, or when loading a new script, and are only shown when a property is changed by a lua script.

Squashed and merged in https://github.com/Silv3rPRO/proshine/commit/5cc4f7753ea7006218bfe77b8f5f7f1cea646a9f, thanks!


Build balenaEngine site with Landr

Issue to track JF work for using Landr to build balenaEngine page.

This issue is half obsolete, half done since the the recent work by @vipulgupta2048 to use docusaurus. Closing.


Partition size related problems on some devices .....

Hello,
I have problems with some usb drives. During setting up usb device, drive partitions are being returned like  zero (0). I understand if it is not right file system. However, I test with fat32 file system formatted usb drives.  I call init() method before getting partitions as provided in example code:
**
* Sets the device up and shows the contents of the root directory.
*/
private void setupDevice() {
try {
device.init();
if (device.getPartitions().size() != 0) {
//do your stuff
}
What is the cause of problem where partition size is  0 ?

Hello,
interesting problem, unfortunately I cannot say what is wrong.
Can you maybe prvide an image file for which the problem occurs? How to do that: https://wiki.archlinux.org/index.php/Disk_cloning under "Create disk image".
Maybe you can also debug a bit on yourself and step into the init() method and look what is going on?
Kind regards.

Do you have any updates on this issue, or may I close this?
Thanks

I don't have that problem right now. Yes, maybe you can close this issue.

Thanks, if the problem occurs again, do not hesitate to open the issue again or create a new one.

Thank you also for your effort


Added GnuWin32.Gperf 3.0.1

[ ] Have you signed the Contributor License Agreement?
[x] Have you checked that there aren't other open pull requests for the same manifest update/change?
[x] This PR only modifies one (1) manifest
[x] Have you validated your manifest locally with winget validate --manifest <path>?

[x] Does your manifest conform to the 1.4 schema?

Note: <path> is the name of the directory containing the manifest you're submitting.

Microsoft Reviewers: Open in CodeFlow

Automatic Validation ended with:

##[warning] Validation concluded that this task needs to go to manual review.  (URL Domain validation)

Hi @fujii,
Unfortunately, the SourceForge page isn't linked on any of the Gnu pages. Without that linkback, I can't verify that it's controlled by the ISV.

Unfortunately, the SourceForge page isn't linked on any of the Gnu pages. Without that linkback, I can't verify that it's controlled by the ISV. This package doesn't seem directly available from the ISV in a Windows installable format, only as a .tar.gz file.

It shouldn't be a problem because it is same with other GnuWin32 packages and JernejSimoncic.Wget package.

@wingetbot waivers Add Validation-Unapproved-URL

/azp run


remove result link

this shouldn't have been commited since it it listed in gitignore)

Very observant!


Drop Lambda-js

It had a good run

Pull Request Test Coverage Report for Build 41

0 of 0   changed or added relevant lines in 0 files are covered.
2 unchanged lines in 2 files lost coverage.
Overall coverage decreased (-0.4%) to 87.885%

Files with Coverage Reduction
New Missed Lines
%

lib/transports/shared/tcp.js
1
90.22%

lib/transports/client/childProcess.js
1
82.05%

Totals

Change from base Build 38:
-0.4%

Covered Lines:
517

Relevant Lines:
565

💛  - Coveralls


Fix the style parameter nullable annotation on AnsiConsoleExtensions

The style parameter is actually nullable. Also, the documentation of the style parameter has been made explicit that Style.Plain is used when a null style is passed.

Merged! Thank you for your contribution. Much appreciated! 👍


Target authorization token is missing

I setup the exporter with the local setup process.
I confirmed that the curl command give the following output.
curl -H 'Authorization: Bearer 4b84cabd-***' -X GET 'http://<IP_ADDRESS>:9490/metrics/array?endpoint=bel2-pure1'
# HELP go_gc_duration_seconds A summary of the pause duration of garbage collection cycles.
# TYPE go_gc_duration_seconds summary
go_gc_duration_seconds{quantile="0"} 0
go_gc_duration_seconds{quantile="0.25"} 0
go_gc_duration_seconds{quantile="0.5"} 0
go_gc_duration_seconds{quantile="0.75"} 0
go_gc_duration_seconds{quantile="1"} 0
go_gc_duration_seconds_sum 0
go_gc_duration_seconds_count 0
# HELP go_goroutines Number of goroutines that currently exist.
# TYPE go_goroutines gauge
go_goroutines 17
# HELP go_info Information about the Go environment.
# TYPE go_info gauge
go_info{version="go1.18.1"} 1
# HELP go_memstats_alloc_bytes Number of bytes allocated and still in use.
# TYPE go_memstats_alloc_bytes gauge
go_memstats_alloc_bytes 3.97776e+06
# HELP go_memstats_alloc_bytes_total Total number of bytes allocated, even if freed.
# TYPE go_memstats_alloc_bytes_total counter
go_memstats_alloc_bytes_total 3.97776e+06
# HELP go_memstats_buck_hash_sys_bytes Number of bytes used by the profiling bucket hash table.
# TYPE go_memstats_buck_hash_sys_bytes gauge
go_memstats_buck_hash_sys_bytes 4303
# HELP go_memstats_frees_total Total number of frees.
# TYPE go_memstats_frees_total counter
go_memstats_frees_total 702
....

But referencing the token.yaml with the following command the page only shows "Target authorization token is missing"
/opt/pure-fa-om-exporter/out/bin/pure-fa-om-exporter -t /opt/pure-fa-om-exporter/token.yaml
Here is my token.yaml
array_id1:
  address: 'bel2-pure1'
  api_token: '4b84cabd-***'
array_id2:
  address: '<IP_ADDRESS>'
  api_token: 'b8605f85-***'

From the output of the curl results below I can't determine if any purefa_ metrics were returned.
cURL
The curl command used contains the authorization bearer token and grep for purefa_info as this metric is included in all endpoints.
curl -H 'Authorization: Bearer 4b84cabd-***' -X GET 'http://<IP_ADDRESS>:9490/metrics/array?endpoint=bel2-pure1'  -silent | grep ^purefa_info

Now try the query again without the authorisation token to ensure the token.yaml is being utilised correctly.
curl -X GET 'http://<IP_ADDRESS>:9490/metrics/array?endpoint=bel2-pure1' -silent | grep ^purefa_info

If that works then you should be good to try in the browser.
If it does not then check the yaml is valid (it certainly looks like it is in your example) and the file is specified on launch.
Browser
Be sure to specify the device endpoint as the links in the browser won't know which device you wish to connect.
When you enter the URL into the browser with http://<IP_ADDRESS>:9490/ and get results like this:
Pure Storage FlashArray OpenMetrics Exporter

Type
Endpoint
GET parameters
Description

Full metrics
/metrics
endpoint
All array metrics. Expect slow response time.

Array metrics
/metrics/array
endpoint
Provides only array related metrics.

Volumes metrics
/metrics/volumes
endpoint
Provides only volumes related metrics.

Hosts metrics
/metrics/hosts
endpoint
Provides only hosts related metrics.

Pods metrics
/metrics/pods
endpoint
Provides only pods related metrics.

Directories metrics
/metrics/directories
endpoint
Provides only directories related metrics.

The browser defaults to
http://<IP_ADDRESS>:9490/metrics/array?endpoint=host
Ensure the device endpoint it specified like so:
http://<IP_ADDRESS>:9490/metrics/array?endpoint=bel2-pure1

Sorry, on the close button, kid got click happy.

i am facing the exact same issue. when run with the -t option, get "Target authorization token is missing" error.

Found the problem. It was missing parameter endpoint. Prometheus scape k8s exporter pod. After adding
params:
endpoint: [entry-in-token.yaml]
It works!

i thought the exporter would just scrape all arrays in API token(s) map file. wish it was true.

sorry the fix was in the prometheus.yaml?

yes. we run prometheus in k8s. here is my scrape config
   - job_name: 'psa1_lab_ams'       params:         endpoint: [psa1_lab_ams]       kubernetes_sd_configs:       - role: pod         namespaces:           names:           - prd3028       relabel_configs:       - target_label: env         replacement: AMS       - source_labels: [__meta_kubernetes_pod_name]         action: keep         regex: pure-exporter.*       - source_labels: [job]         regex: (.*)         replacement: $1         target_label: instance
it's kind of cumbersome. have to add these for each array.

figured out how to multiple target. example in README helps.
      relabel_configs:
      - source_labels: [__address__]
        target_label: __param_endpoint
      - source_labels: [__param_endpoint]
        target_label: instance
      - source_labels: [instance]
        regex: (.*)_(.*)_(.*)
        replacement: $3
        target_label: env
      - source_labels: [env]
        action: uppercase
        target_label: env
      - target_label: __address__
        replacement: pure-exporter-probe.prd3028.svc.cluster.local:80
      static_configs:
      - targets:
        - psa1_lab_ams
        - psa2_lab_ams

I'm not using k8s.
My config looks to be trying to scrap the output of the exporter.
  - job_name: "pure-fa-probe"
    honor_timestamps: true
    scrape_interval: 30s
    scrape_timeout: 10s
    metrics_path: /metrics/pods
    scheme: http
    follow_redirects: true
    #enable_http2: true
    relabel_configs:
      - source_labels: [job]
        separator: ;
        regex: (.*)
        target_label: __tmp_prometheus_job_name
        replacement: $1
        action: replace
      - separator: ;
        regex: (.*)
        target_label: job
        replacement: pure-fa-probe
        action: replace
      - source_labels: [__address__]
        separator: ;
        regex: (.*)
        target_label: __param_endpoint
        replacement: $1
        action: replace
      - source_labels: [__param_endpoint]
        separator: ;
        regex: (.*)
        target_label: instance
        replacement: $1
        action: replace
      - separator: ;
        regex: (.*)
        target_label: __address__
        replacement: localhost:9490
        action: replace
    static_configs:
      - targets:
          - <IP_ADDRESS>
          - <IP_ADDRESS>

Since the exporter is not able to scrap the arrays with the token, it's pointless to edit the prometheus.yaml file.

Fixed my issues.
Needed to call out the array id in the token file with a unique name and use the same refence in the Prometheus config.
token.yaml
bel2-pure1:
  address: <IP_ADDRESS>
  api_token: 4b84cabd-********
bel2-pure2:
  address: <IP_ADDRESS>
  api_token: b8605f85-********

prometheus.yaml
  - job_name: "pure-fa-probe"
    honor_timestamps: true
    scrape_interval: 30s
    scrape_timeout: 10s
    metrics_path: /metrics/pods
    scheme: http
    follow_redirects: true
    #enable_http2: true
    relabel_configs:
      - source_labels: [job]
        separator: ;
        regex: (.*)
        target_label: __tmp_prometheus_job_name
        replacement: $1
        action: replace
      - separator: ;
        regex: (.*)
        target_label: job
        replacement: pure-fa-probe
        action: replace
      - source_labels: [__address__]
        separator: ;
        regex: (.*)
        target_label: __param_endpoint
        replacement: $1
        action: replace
      - source_labels: [__param_endpoint]
        separator: ;
        regex: (.*)
        target_label: instance
        replacement: $1
        action: replace
      - separator: ;
        regex: (.*)
        target_label: __address__
        replacement: localhost:9490
        action: replace
    static_configs:
      - targets:
          - bel2-pure1
          - bel2-pure2


Action bridge

@ipa-hsd Would you like to review, and if approved, merge this here, or should I open a new PR to https://github.com/ros2/ros1_bridge

@v-lopez I am currently reviewing it.

Thanks, I just pushed some changes that might have fixed the compilation in foxy.
I was building on rolling and the action client API had changed.

makes sense why I was having build issues and was not generating the interfaces anymore. When I made the PR it was successfully generating the interfaces and the bridge worked well. Thanks for the effort.

No problem.
There's still one more issue there, I just started a foxy docker and will try to fix it. Apologies for the confusion.

Should be ready now, let me know if you have any issues, I was able to build on foxy and rolling.

did you build the bridge against Foxy ? Dirk says it should be the master https://github.com/ros2/ros1_bridge/pull/256#issuecomment-631768990. I am using the lastSuccessfulBuild

rolling are debians made from most recent changes, maybe master from a few days/weeks ago. Did you have any issues?

silly of me. I was just trying to avoid building ROS2 from source and still get the latest version. Will try the master.

I finally had to build it against lastSuccessfulBuild since the master branches have compile errors. Your version of action_bridge compiles successfully now but most of the generated action interfaces are empty.

@ipa-hsd ipa-hsd#1 fixes build issues for me, and I get both ROS1 -> ROS2 and ROS2 -> ROS1 communication.

Which action interface did you test it for?

I tried with the tf msgs and control_msgs.
Which ones are missing?

alright I installed control_msgs for Foxy and now it looks good. Ready to be merged!

@v-lopez not sure if you had to signoff the commit because I am unable to do it from my side. https://github.com/ros2/ros1_bridge/pull/256/checks?check_run_id=1417453709


Added Python calculator solution

Issue Number: #134
This pull request adds a Python solution for a basic calculator that performs addition, subtraction, multiplication, and division operations.

Issue Number: #134
This pull request adds a Python solution for a basic calculator that performs addition, subtraction, multiplication, and division operations.

@Rajeshkumarje this issue is assigned to someone else you can ask for some other issue or can create new issue with DSA problems which is not there already, will assign those to you.


WSS Connection

Hi,
sorry if this is a stupid question, but i was looking around to understand where to get the api key for the wss but i dont think it is needed?
how are you using it ? or it was just a suggestion you made?

For the Solana Mainnet Beta public endpoint you don't need an API key
If you go with a provider there are different methods, e.g. in case of Helius you can authenticate with query params

https://solana.com/docs/core/clusters

i was takling about this one sorry : wss://ws.gmgn.ai/stream?_t=true

Haven't used those streams but it seems that you don't need an API key

There is an ID param but this appears to be a UUID and it can be specified from the clientside, used for unsubs

URL is wss://ws.gmgn.ai/stream

im using it like this :
import asyncio
import websockets
import json
async def connect_to_websocket():
uri = "wss://ws.gmgn.ai/stream"
print(f"Connecting to {uri}")
async with websockets.connect(uri) as websocket:
    print("Connected to the WebSocket server.")

    try:
        while True:
            print("Waiting to receive a message...")
            message = await websocket.recv()
            process_message(message)
    except websockets.ConnectionClosed:
        print("Connection closed.")
    except Exception as e:
        print(f"An error occurred: {e}")

def process_message(message):
try:
data = json.loads(message)
print(f"Received data: {data}")
# Add your logic to process the data here
except json.JSONDecodeError:
print(f"Received non-JSON message: {message}")
if name == "main":
asyncio.get_event_loop().run_until_complete(connect_to_websocket())
i dont get any response

Haven't used those streams but it seems that you don't need an API key

There is an ID param but this appears to be a UUID and it can be specified from the clientside, used for unsubs

See the image I sent, try to go to devtools and see the payload you have to send over and the way connection lifecycle is handled
You are going to need to send a subscribe message, then process the incoming messages and send ping messages every here and there and lastly unsubscribe on program exit
In the code snippet you are just connecting, no surprise there is no response :P

sorry im still a n00b :')

no worries and good luck!


nodejs : Conflicts: npm

Describe the bug
I encounter this problem when running "docker-compose up -d" command first time:
The following packages have unmet dependencies:
 nodejs : Conflicts: npm
 npm : Depends: node-gyp (>= 3.6.2~) but it is not going to be installed
E: Unable to correct problems, you have held broken packages.
ERROR: Service 'radar' failed to build: The command '/bin/sh -c apt-get install -y build-essential nodejs npm' returned a non-zero code: 100

To Reproduce
Run:
docker-compose up -d

Screenshots

Desktop (please complete the following information):

macOS 10.5.3

Hi @ikbear
Thank you for the issue. Sorry for the delay.
We do not have the problem on the latest version on master.
We use doker for Windows. We have to fond a mac un ordre to test.

@bernard-arnaud, I have this error on master now

It is working. Very sorry for the delay!

It is working. Very sorry for the delay!

Thanks. It works. But there is a new error:

The following packages have unmet dependencies:
nodejs : Conflicts: npm
npm : Depends: node-gyp (>= 3.6.2~) but it is not going to be installed
E: Unable to correct problems, you have held broken packages.
ERROR: Service 'radar' failed to build: The command '/bin/sh -c apt-get install -y build-essential nodejs npm' returned a non-zero code: 100

I @ikbear,
I tried on 2 computer and I cannot reproduce the problem.
Do you use the lastest version on master?

npm can be removed from apt-get when installing nodejs. It can be installed with nodejs. I have corrected it with a modified Dockerfile.

File: /src/RadarTechno/Dockerfile:

-RUN apt-get install -y build-essential nodejs npm
+RUN apt-get install -y build-essential nodejs

From npmjs documentation :
The Node installation process installs npm in a directory with local permissions and can cause permissions errors when you run npm packages globally.
I still think we should install nodejs and npm separately.
Closing this issue since we can't reproduce, let us know if the problem persists.


fix: change UserApprovalInput approved field to pointer.

Changes
fix: change UserApprovalInput approved field to pointer.
Submitter Checklist
As the author of this PR, please check off the items in this checklist:

[ ] spec PR link included
[x] Follows the commit message standard
[ ] Meets the contributing guidelines (including
functionality, content, code)
[x] Test cases with documentation and functionality works as expected using current and related github repos (MUST deploy and check)
[x] Release notes block below has been filled in or deleted (only if no user facing changes)

deliver/晋级 使用到的地方需要进行相应的修改。

由于包含breakchange，katanomi-pkg-downstream-test失败了，后续 @l-qing  会在deliveries 进行适配。


Element (re)registration errors when loading polymer.html more than once

I'm updating the site the latest Thanksgiving Odyssey Bowertopia Feast and running into issues with inline s. The recommended way is:
<head>
    <script src="components/platform/platform.js"></script>
    <link rel="import" href="components/polymer/polymer.html">
    <link rel="import" href="components/polymer-ui-menu/polymer-ui-menu.html">
</head>
<body>
  <x-hi></x-hi>
  <polymer-element name="x-hi">
    ...
  </polymer-element>
</body>

In Canary under native stuff, mixing element imports and explicitly loading polymer.html in the main page causes re-registration errors:

The quick fix is for me to move the element into an import, but we should make these two scenarios play well together.

Closing this issue due to age and the release of version 1 of Polymer - please feel free to re-open if this is incorrect.


python3Packages.jax: 0.2.21 -> 0.2.24

Motivation for this change
Update to latest upstream release 0.2.24
Change log: https://github.com/google/jax/releases/tag/jax-v0.2.24
Fix build (https://hydra.nixos.org/build/157336817)
ZHF: #144627
Things done

Built on platform(s)

[x] x86_64-linux
[ ] aarch64-linux
[ ] x86_64-darwin
[ ] aarch64-darwin

[ ] For non-Linux: Is sandbox = true set in nix.conf? (See Nix manual)
[ ] Tested, as applicable:

NixOS test(s) (look inside nixos/tests)
and/or package tests
or, for functions and "core" functionality, tests in lib/tests or pkgs/test
made sure NixOS tests are linked to the relevant packages

[ ] Tested compilation of all packages that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review wip"
[ ] Tested basic functionality of all binary files (usually in ./result/bin/)
21.11 Release Notes (or backporting 21.05 Release notes)

[ ] (Package updates) Added a release notes entry if the change is major or breaking
[ ] (Module updates) Added a release notes entry if the change is significant
[ ] (Module addition) Added a release notes entry if adding a new NixOS module

[x] Fits CONTRIBUTING.md.

Result of nixpkgs-review pr 145197 run on x86_64-linux 1

1 package built:

python39Packages.jax

@fabaff Out of curiosity, are you using the jax package or was this automated?

I'm not using it. Was update as part of ZHF for 21.11.

Ah, gotcha

OOC why don't I receive an email when the build fails for a package I maintain? I had no idea there was a breakage

Hydra does not understand python3Packages. You need to use python38Packages or python39Packages.

I'm not sure I understand... Is this something I can reasonably fix without moving the jax out of python3Packages?


ReferenceError: driver is not defined

Hi,
I am trying to use the mocha-parallel-tests npm package with the following test suite:
https://github.com/diemol/frontend_testing/tree/master/webdriver-examples-js-parallel
The suite works fine when I just use mocha, and of course it runs sequentially.
When I try to use ./node_modules/.bin/mocha-parallel-tests test/, I get the following:
  1) Book hotel and select pay at hotel should leave booking reserved

  2) Register user should leave new user logged in

  0 passing (78ms)
  2 failing

  1)  Book hotel and select pay at hotel should leave booking reserved:
     ReferenceError: driver is not defined
      at Context.<anonymous> (test/hotel.js:15:25)

  2)  Register user should leave new user logged in:
     ReferenceError: driver is not defined
      at Context.<anonymous> (test/user.js:16:9)

So it seems that when mocha is executed, somehow the path location of the test is ignored or replaced by a new one.
I am not a JavaScript expert, but maybe the error could be around here? https://github.com/mmotkina/mocha-parallel-tests/blob/master/lib/watcher.js#L109
Is there a way I can turn on the debug? I tried reading the code but it was not so easy to understand for me.
I appreciate any help, thanks!

I would say that the problem lies somewhere here: https://github.com/diemol/frontend_testing/blob/master/webdriver-examples-js-parallel/test/base.js#L34
You are creating a driver variable without var, let or const. This usually means that the variable is created in the global scope and is considered to be a buggy behaviour, which is why this is prohibited in strict mode.
Anyway if you want driver variable to be accessed inside hotels test, you can create driver with var driver = ... and pass it as the only argument to callback function here. In this case it would be accessible as the first argument of a function here. I guess this should work.

Hi again,
What you said makes a lot of sense, also because the driver variable will be shared by the tests and this leads usually to unexpected behaviour.
I have done the same example in Java, and a ThreadLocal array is used or creating the driver in the test.
The same concept should apply here, I will refactor my examples to reflect it.
I'll close the issue since it is clearly related to the code and not the package.
Thanks for your feedback!

No worries, thanks for using mocha-parallel-tests.


"Send out Invites Button" on Event Page

Sends Email Links to Participants

Is this the same as #20?


Errors trying to use fields from ES7 in the Native Hive Alerter

I am trying to create a hive alert that uses file.name field using {match[file.name]} as the title for the hive alert but I get the error in return.  I am using ES 7.9.1 and don't know what the issue is. I am using the Slack plugin with the same field and those come out fine, just the hivealerter seems to not work.
elastalert_error - {'message': "Uncaught exception running rule 001 : 'file.name'", 'traceback': ['Traceback (most recent call last):', '  File "/usr/local/lib/python3.6/site-packages/elastalert-0.2.4-py3.6.egg/elastalert/elastalert.py", line 1453, in alert', '    return self.send_alert(matches, rule, alert_time=alert_time, retried=retried)', '  File "/usr/local/lib/python3.6/site-packages/elastalert-0.2.4-py3.6.egg/elastalert/elastalert.py", line 1547, in send_alert', '    alert.alert(matches)', '  File "/usr/local/lib/python3.6/site-packages/elastalert-0.2.4-py3.6.egg/elastalert/alerts.py", line 2159, in alert', '    alert_config[alert_config_field] = alert_config_value.format(**context)', "KeyError: 'file.name'"], 'data': {'rule': '001'}}

I don't know what alert rule file I wrote, so I have no idea what caused it.

We also recommend asking questions on the Gitter channel
https://gitter.im/Yelp/elastalert

use match[file][name] instead of match[file.name]

Please close if resolved


graph.getVertices("Customer.name", "Jay") should find indicies based on fields, not name

OrientDB 2.0.12
The documentation about Using Indices doesn't specify that an Index must be named accordingly a specific naming schema, so that it is used by the query.
As an index contains the information, for which fields it is usable, the index should with this information. As such, a not so strict naming must be enforced for indicies.

Fixed in both 2.1.x and 2.2


Hide resource creation logic

Move wrapping base resource into SimpleReporter to corresponding resource-specific functions

This change is

Reviewed 9 of 9 files at r1.
Review status: all files reviewed at latest revision, 1 unresolved discussion.

scheduler/scheduler.go, line 274 at r1 (raw file):

		if r.Pod != nil {
			sr = NewScheduledResourceFor(resources.NewPod(r.Pod, c.Pods()))

I wanted to propose almost the same patch. You was faster :)
One thing - maybe better would be there declare
var resource *interfaces.Resourc

then in each if assign to it only resource, with single call to
sr = NewScheduledResourceFor(resource)

after ifs set?

Comments from Reviewable

Review status: all files reviewed at latest revision, 1 unresolved discussion.

scheduler/scheduler.go, line 274 at r1 (raw file):
Previously, jellonek (Piotr Skamruk) wrote…
I wanted to propose almost the same patch. You was faster :)
One thing - maybe better would be there declare
var resource *interfaces.Resourc

then in each if assign to it only resource, with single call to
sr = NewScheduledResourceFor(resource)

after ifs set?

sounds good. Will do

Comments from Reviewable

Reviewed 1 of 1 files at r2.
Review status: all files reviewed at latest revision, all discussions resolved.

Comments from Reviewable

Reviewed 8 of 9 files at r1, 1 of 1 files at r2.
Review status: all files reviewed at latest revision, all discussions resolved.

Comments from Reviewable


Compress image before uploading

Hello,
Is it possible to compress images client side before upload them into the dedicated server?
If yes, can you say me to do with jqueryuPload?
Thanks

Resizing images (which reduces their filesize) is already built-in with the image processing plugin.
However it's not possible to define parameters like JPEG or PNG compression at the moment.
It's also only supported on Chrome and Firefox so far.
You could also integrate a library like JSZip and then upload the created ZIP instead of the image(s) itself.

Sorry, I don't have any example implementations, never had the need for client-side ZIP compression so far.


vs 2019 integration bug

Visual Studio 2019 is not setting the target architecture correctly. cmake defaults to x86.

Related #6090


crdReplicator finalizer on foreigncluster resources

Description
Each time a foreigncluster.discovery.liqo.io resource is created the crdReplicator creates a dynamic client to the remote api-server. A finalizer is added to the foreigncluster resources in order to close the connection to the remote api-servers when the resource is deleted.
Using two kind clusters:

peering then unpeering and then peering again the cluster.
deleting the foreigcluster resource and checking that the crdReplicator removes the connection and then recreates the client to the remote api-server once the foreigncluster resource is recreated.

/rebase

/rebase

/rebase

/rebase

/merge

/merge


workerman client listener EventHandler

i try to create a client listener,  is it any EventHandler / function that is called when a message is nothing received from the server ? for example in 5 second.
or do you have a any suggestion, thanks in advance

<?php
use Workerman\Worker;
use Workerman\Connection\AsyncTcpConnection;
use Workerman\MySQL;
use Workerman\Timer;

require_once __DIR__ . '/../vendor/autoload.php';
$worker = new Worker();
// $worker->count = 2;

$worker->onWorkerStart = function () {
    // Websocket protocol for client.
    $ws_connection = new AsyncTcpConnection('ws://theserver.com:7890/price');
    $ws_connection->transport = 'ssl';
    $ws_connection->onConnect = function ($connection) {
    };
    $ws_connection->onMessage = function ($connection, $data) {
        //detect if 5 second not receive $data from server
        //do something

        $results = json_decode($data, true);
        $price = $results['price'];

        $db = new MySQL\Connection("localhost", "3306", "username", "password", "dbname");
        $db->query("INSERT INTO `websocket_price` ( `price`) VALUES ($price)");

    };
    $ws_connection->onError = function ($connection, $code, $msg) {
        echo "Error: $msg\n";
    };
    $ws_connection->onClose = function ($connection) {
        echo "Connection closed\n";
    };
    $ws_connection->connect();
};

Worker::$logFile = '/home/theserver/public_html/daemon/start.log';
Worker::runAll();

The codes may like this.
$worker->onWorkerStart = function () {
    // Websocket protocol for client.
    $ws_connection = new AsyncTcpConnection('ws://theserver.com:7890/price');
    $ws_connection->transport = 'ssl';
    $ws_connection->onConnect = function ($connection) {
    };
    $ws_connection->onMessage = function ($connection, $data) {

        // Here
        Timer::del($connection->timer);

        $results = json_decode($data, true);
        $price = $results['price'];

        $db = new MySQL\Connection("localhost", "3306", "username", "password", "dbname");
        $db->query("INSERT INTO `websocket_price` ( `price`) VALUES ($price)");

    };
    $ws_connection->onError = function ($connection, $code, $msg) {
        echo "Error: $msg\n";
    };
    $ws_connection->onClose = function ($connection) {
        echo "Connection closed\n";
    };
    $ws_connection->connect();

    // Here
    $ws_connection->timer = Timer::add(5, function() use ($ws_connection) {
        // do something
    }, null, false);
};

many thanks for your work, response and attention,
I will try to use it.

<?php
use Workerman\Worker;
use Workerman\Connection\AsyncTcpConnection;
use Workerman\MySQL;
use Workerman\Timer;

require_once __DIR__ . '/../vendor/autoload.php';
$worker = new Worker();
// $worker->count = 2;

$worker->onWorkerStart = function () {
    // Websocket protocol for client.
    $ws_connection = new AsyncTcpConnection('ws://theserver.com:7890/price');
    $ws_connection->transport = 'ssl';
    $ws_connection->onConnect = function ($connection) {
    };
    $ws_connection->onMessage = function ($connection, $data) {
        // Here
        Timer::del($connection->timer);

        $results = json_decode($data, true);
        $price = $results['price'];

        $db = new MySQL\Connection("localhost", "3306", "username", "password", "dbname");
        $db->query("INSERT INTO `websocket_price` ( `price`) VALUES ($price)");
    };
    $ws_connection->onError = function ($connection, $code, $msg) {
        echo "Error: $msg\n";
    };
    $ws_connection->onClose = function ($connection) {
        echo "Connection closed\n";
    };
    $ws_connection->connect();

    // Here
    $ws_connection->timer = Timer::add(5, function() use ($ws_connection) {
        // do something
        $db = new MySQL\Connection("localhost", "3306", "username", "password", "dbname");
        $db->query("INSERT INTO `wss_status` ( `status`, `pid`) VALUES ( 0, ". posix_getppid() .")");

    }, null, false);
};

Worker::$logFile = '/home/theserver/public_html/daemon/start.log';
Worker::runAll();

emmm.. it doesn't seem to be working properly, because the last ws client status is running fine just like what I see in the log, but the data in the onMessage stop because there is no new data in the table, the timer condition is also not there / empty, but the ws server is also running fine.

/** @var null|int|false Last time the message was received */
$last = null;

$ws_connection->onMessage(function () use (&$last) {
    $last = time();
});

// Once per second
Timer::add(1, function() use ($last) {
    // No message received for more than 5 seconds
    if ($last !== false && time() - $last >=5) {
        // Prevent duplicate processing

        // #1 Continue processing in five seconds
        $last = time();

        // #2 Pause subsequent processing
        $last = false;

        //  TODO: ...
    }
});

@tianyiw2013 try it, worked like a charm.. xie xie


Support FUSE_INTERRUPT

I think FUSE_INTERRUPT could work really well with an async API runner.  It would look something like:
let in_flight = HashMap<RequestId, JoinHandle<()>>::new();
let future_cancellations = Set<RequestId>::new();
for req in requests {
    if future_cancellations.contains(req.request_id()) {
        future_cancellations.pop(req.request_id());
        continue;
    }
    match req.operation() {
        Interrupt(x) => in_flight.pop(req.request_id()).abort()
    }
    in_flight[req.request_id()] = tokio::spawn(|| {
        handler(req);
        in_flight.pop(req.request_id());
    });
}

So interrupted pending tasks would be aborted, and their futures dropped in response to FUSE_INTERRUPT messages.  It fits naturally with the async API.

Ya, agreed! I'd love to see an async implementation :)

Note to self, for the future: I looked into implementing this in the current API, and it doesn't make sense. FUSE_INTERRUPT is for interrupting code that's hung in userspace. However, the current Filesystem interface takes &mut self so concurrent calls aren't possible. Revisit it after async is implemented


Release v0.0.11

🤖 New release

yolk_dots: 0.0.10 -> 0.0.11

Changelog

0.0.11 - 2024-12-13
Added

add a few hex color utility functions

Fixed

Improve parser error message for missing end tag

Other

Use different font for docs headings to make @druskus20 happy
he animated now
Try to fix theme
Setup matching mdbook theme
(release) build man page as part of release process

This PR was generated with release-plz.

@druskus20 declares that @druskus20 is not happy with this release

The font is still ugly

@druskus20 is a bit happier as of #8d65c1aae339996599e58f896a1610f4c002d340


feat: support creation of a full changelog

closes #82

Codecov Report

Merging #84 (75c8354) into main (49908f3) will decrease coverage by 0.99%.
The diff coverage is 69.60%.

@@            Coverage Diff             @@
##             main      #84      +/-   ##
==========================================
- Coverage   81.77%   80.77%   -1.00%
==========================================
  Files          24       24
  Lines        1092     1155      +63
==========================================
+ Hits          893      933      +40
- Misses        162      179      +17
- Partials       37       43       +6

Impacted Files
Coverage Δ

internal/task/changelog/changelog.go
64.10% <67.70%> (-1.53%)
:arrow_down:

cmd/uplift/changelog.go
80.24% <100.00%> (+0.50%)
:arrow_up:

internal/git/utils.go
74.01% <100.00%> (+0.14%)
:arrow_up:

Continue to review full report at Codecov.

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


Chapter: add-which-command

add-which-command
I think it will be a good idea to include which to the list [...] -->

@bobbyiliev, which command is missing, Can i add this one ?


[WIP] Wwp add local users

From issue: #xx
High level changes:

Add a function to generate a webmaster user with a random password. Possibility to give the CSV of a previous run to reuse same passwords for already deployed sites.

Low level changes:

Add a function to generate a webmaster user with a random password. Possibility to give the CSV of a previous run to reuse same passwords for already deployed sites.

Targetted version: x.x.x

On a plus besoin de générer les mots => ferme la PR


openresty: make compatible with nixos nginx module

Motivation for this change
Openresty currently fails to start when provided to services.nginx, as it can't load fastcgi.conf.
This PR resolves that, and adds a test to ensure that all nginx variants in nixpkgs (or at least the ones I'm aware of...) can start and serve a simple request.
Things done

[x] Tested using sandboxing (nix.useSandbox on NixOS, or option sandbox in nix.conf on non-NixOS linux)
Built on platform(s)

[ ] NixOS
[ ] macOS
[x] other Linux distributions

[x] Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
[ ] Tested compilation of all pkgs that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review wip"
[ ] Tested execution of all binary files (usually in ./result/bin/)
[ ] Determined the impact on package closure size (by running nix path-info -S before and after)
[ ] Ensured that relevant documentation is up to date
[ ] Fits CONTRIBUTING.md.

@ofborg test nginx-variants

Please add to this test check with tengine.

@ofborg test nginx-variants
@Izorkin done :+1:

/marvin opt-in

/status needs_review


exit code 0 on failure (specifically getMultiCapabilities failure)

In my team's setup, we managed more than once to miss out on protractor not actually running, although we do follow proper exit codes.
Yet protractor does not.
Our latest mishap was a failure in our getMultiCapabilities function. Protractor does not reject/catch, meaning errors get silenced and protractor fails to run any test, but exits with 0, and our CI trusts that.

Hi there,
Thanks for bringing this up, I think it makes a lot of sense; could you please include information from the Issue Template in your issue? It would be particularly helpful to include a small example reproducing your issue.
Thanks!

I am on a small screen at the moment, and can't access specific
information, but the gist of a replica is to have a conf.js with
getMultiCapabilities: function() {
 return new Promise(function(resolve) {
   this.foo.bar = 1; // will fail because this.foo is undefined
   resolve({...});
 });
}

On Thu, Dec 22, 2016 at 3:23 PM, Nick Tomlin<EMAIL_ADDRESS>wrote:

Hi there,
Thanks for bringing this up, I think it makes a lot of sense; could you
please include information from the Issue Template
https://github.com/angular/protractor/blob/master/.github/ISSUE_TEMPLATE
in your issue? It would be particularly helpful to include a small example
reproducing your issue.
Thanks!
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
https://github.com/angular/protractor/issues/3875#issuecomment-268809192,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AArOQRpb8tt-1GvMtyviI36wVrjBxnDtks5rKofRgaJpZM4LT5YJ
.

--
andreineculau.com http://www.andreineculau.com

assigning to @cnishina because you're the exit code man

Note to self: this looks like the place I need to fix. https://github.com/angular/protractor/blob/989759a45a8ef481eeaa0102982676cb51630f9b/lib/launcher.ts#L126


Fixed eclipse project generation using cmake

Added headers to cmake's library files to obtain proper projects with proper headers when creating an eclipse project.
Without this patch, when creating an eclipse project using cmake (e.g. cmake -G "Eclipse CDT4 - MinGW Makefiles"), the header files don't appear in the target's headers, which makes indexing not working properly, and finding them a bit harder.

Closed?

I reopened in a different PR because I though that the PR was linked to the commit, not the branch, and have messed up things with something that will go on another PR when it's finished...


Add GWhnfNoUnexpectedThunks V1 instance

I haven't immersed myself in this code as deeply as I would like to. But this seems like the right change.
What do you think, @mrBliss, is my logic (see comment) sound here? I noticed this instance is missing when I opened input-output-hk/cardano-ledger-specs#1306 and input-output-hk/cardano-ledger-specs#1307 earlier today.

CI is failing because of the use of error. I think Cardano.Prelude wants you to use panic instead.

bors r+


Add the library to project

hi,
after extracting the library and building it, what changes should I make to my project's cmakelists.txt file so that the import RoniaKit command is recognizable in my main.qml file, thank you

please check our example project

examples/simple

thank you for responding,
after building the library; when I run it, the example project runs successfully but when I build the example project separately it has a build error and won't run.
and my problem is how to add the library to a separate project (I've putted the library folder into the project directory but I don't know what commands should I add to the project's cmakelists.txt )

thank you for responding, after building the library; when I run it, the example project runs successfully but when I build the example project separately it has a build error and won't run. and my problem is how to add the library to a separate project (I've putted the library folder into the project directory but I don't know what commands should I add to the project's cmakelists.txt )

@Tayebe79 Please check this as well !

@ghost
You have numerous options, two of which are as follows:
Option #1: Add the directory, into which you've installed the RoniaKit project, to the "QML_IMPORT_PATH" CMake list variable of your project or simply assign the RoniaKit project's installation path to the "QT_QML_OUTPUT_DIRECTORY" CMake variable in "CMakeLists.txt" file of your project via "set" command, in case you go for adding your project as a sub-project of the RoniaKit project via the CMake's "add_subdirectory" command.
Option #2:
e.g. in the main.cpp of your application project call "addImportPath" method on the "QQmlEngine" or "QQmlApplicationEngine " object you've just instantiated in you main.cpp and pass the path, into which you've installed RoniaKit project.

@ghost
You have numerous options, two of which are as follows:
Option #1: Append the directory path, into which you've installed the RoniaKit project, to the "QML_IMPORT_PATH" CMake list variable of your project or simply assign the RoniaKit project's installation path to the "QT_QML_OUTPUT_DIRECTORY" CMake variable in "CMakeLists.txt" file of your project via "set" command, in case you go for adding your project as a sub-project of the RoniaKit project via the CMake's "add_subdirectory" command.
Option #2:
If your project is an application project, e.g. in the main.cpp of your application project call "addImportPath" method on the "QQmlEngine" or "QQmlApplicationEngine " object you've just instantiated in you main.cpp and pass the path, into which you've installed RoniaKit project as the sole argument.
Optionally you can link your project against the linktarget for RoniaKit project installation, mentioned in the generated "qmldir" file for the RoniaKit project via CMake's "target_link_libraries" command, but I don't think it's necessary; I personally don't and everything works just fine.

@ghost
You have numerous options, two of which are as follows:
Option #1: Append the directory path, into which you've installed the RoniaKit project, to the "QML_IMPORT_PATH" CMake list variable of your project or simply assign the RoniaKit project's installation path to the "QT_QML_OUTPUT_DIRECTORY" CMake variable in "CMakeLists.txt" file of your project via "set" command, in case you go for adding your project as a sub-project of the RoniaKit project via the CMake's "add_subdirectory" command.
Option #2:
If your project is an application project, e.g. in the main.cpp of your application project call "addImportPath" method on the "QQmlEngine" or "QQmlApplicationEngine " object you've just instantiated in you main.cpp and pass the path, into which you've installed RoniaKit project as the sole argument.
Optionally you can additionally link your project against the linktarget for RoniaKit project installation, mentioned in the generated "qmldir" file for the RoniaKit project via CMake's "target_link_libraries" command, explicitly, but I don't think it's necessary; I personally don't and everything works just fine.


chore: mergify backport config for v12

Closes: #XXX
What is the purpose of the change
We decided to switch the branch name to only v12.x.
This updates the backport configuration for the branch.
Testing and Verifying
This change is a trivial rework / code cleanup without any test coverage.
Documentation and Release Note

Does this pull request introduce a new feature or user-facing behavior changes? no
Is a relevant changelog entry added to the Unreleased section in CHANGELOG.md? no
How is the feature or change documented? not applicable

@ValarDragon just a ping about branch updates discussed earlier. Please recut branches when you have time. I don't have permissions


Playlist response is broken

I have not waited hours, but i have waited some time. I keep getting the 'playlist response is broken' error message
Thank you

Update: It has now been hours and the problem is still there so maybe YT changed something, I would not know.
Thank you

Duplicate #181

hope we get a fix soon :=)

still no luck

08.03 - still not working 🦡

21.03 - still not working :l

Just ran into this issue as well.. hopefully a fix will be available soon.
Love this app!

It works if you type in the url, but it downloads the video and not just the audio which is all i want.


Addon Manager entry is broken due to a typo

... does this bug belong to you guys or to the FreeCAD addon repository? I can't tell.
Anyway the problem is that FreeCAD's addon manager can't fetch this plugin, because the link has a typo. The listing is visible, but when you go to view the details or install it, it 404s.
Correct: https://github.com/dprojects/Woodworking
Current: https://github.com/dprojects/Woodworking.git

I am seeing this issue as well.

I made a workaround to get it installed.

Open FreeCAD
Open the AddOnManager
Click Refresh local cache and wait for it to completely download a new cache
Open File Explorer and navigate to: c:\Users*YOURUSERACCOUNT*\AppData\Local\Temp\FreeCAD\Cache\AddonManager\PackageMetadata\woodworking
Open the 'package.xml' file with Notepad
Edit the 'https://github.com/dprojects/Woodworking**.git**' line by removing the .git so it looks like this 'https://github.com/dprojects/Woodworking'
Save the package.xml file
Close the Addon Manager
Open the Addon Manager again and wait for it to finish reading the cache
Search for Woodworking
Try the install again

check if there is still problem with last master branch


UserData is required. Readding field that was removed from previous P…

…R# 10 pull request.

@elmiko @JoelSpeed


Crash when using debounce (100%)

Hi, in a very simple use case debounce seems to crash, but it might just be me using the cx proxy wrong?
This code crashes with EXC_BAD_INSTRUCTION:
 let pub = PassthroughSubject<Int, Never>()

        pub
            .debounce(for: 2.0, scheduler: DispatchQueue.global().cx)
            .sink(receiveValue: {
                print($0)
            })
            .store(in: &subscribers)

        (0...10).forEach(pub.send) //Crashes here: Thread 1: EXC_BAD_INSTRUCTION

Fixed. The problem is actually caused by DispatchQueue, not Debounce

@luoxiu The problematic code was not tested. We should introducing code coverage analysis.

Thank you! Quick dispatch, so to speak :)


criterion: 2.3.3 -> 2.4.1, used prebuilt packge

The criterion package was suffering of bad includes but that is
now fixed using the tarball that is build on the Release page on
Github. This commit also bumps the version from 2.3.3 to 2.4.1.
Description of changes
Changed the version and the package is now not built from the sources anymore.
Things done

Built on platform(s)

[X] x86_64-linux
[x] aarch64-linux
[ ] x86_64-darwin (Cannot work on Darwin)
[ ] aarch64-darwin (Cannot work on Darwin)

[ ] For non-Linux: Is sandbox = true set in nix.conf? (See Nix manual)
[ ] Tested, as applicable:

NixOS test(s) (look inside nixos/tests)
and/or package tests
or, for functions and "core" functionality, tests in lib/tests or pkgs/test
made sure NixOS tests are linked to the relevant packages

[ ] Tested compilation of all packages that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD". Note: all changes have to be committed, also see nixpkgs-review usage
[X] Tested basic functionality of all binary files (usually in ./result/bin/)
22.11 Release Notes (or backporting 22.05 Release notes)

[ ] (Package updates) Added a release notes entry if the change is major or breaking
[ ] (Module updates) Added a release notes entry if the change is significant
[ ] (Module addition) Added a release notes entry if adding a new NixOS module
[ ] (Release notes changes) Ran nixos/doc/manual/md-to-db.sh to update generated release notes

[X] Fits CONTRIBUTING.md.

What does it mean and why not fix that instead?
The include directory of the library could not be found by a C compiler. Using prebuilt library and headers fixes that issue and updates the software.
Also, this breaks non-Linux systems which were supported before. (but doesn't change the supported list)
My mistake here, there is no reason that it would break non Linux systems.

What does it mean and why not fix that instead?

The include directory of the library could not be found by a C compiler. Using prebuilt library and headers fixes that issue and updates the software.

Also, this breaks non-Linux systems which were supported before. (but doesn't change the supported list)

My mistake here, there is no reason that it would break non Linux systems.

That's a pretty poor fix. Have you considered adding a patch to the build files instead? Binary releases can lead to many more issues than they fix.

That's a pretty poor fix. Have you considered adding a patch to the build files instead? Binary releases can lead to many more issues than they fix.

I've looked into a fix already but the new build system that they are using (meson) makes building from the source really hard without having to download external dependencies during the build process, which is explicitly disabled in the packaging code for Meson. I couldn't fix it myself but maybe you could give it a try?

All of the Meson dependencies mentioned are available in Nixpkgs. I'm almost building from source. If it's okay with you, I'll close this PR once I submit the source-based update.

Superseded by #181821

Re-reading a bit, you mentioned "bad includes", could you clarify?
The headers are not in the default output (out), but in dev. Make sure to have both in your dev environment


Fix: added messageId field in unpinChatMessage

[x] All tests pass
[x] I have run npm run doc

Description

Added messageId field in unpinChatMessage to unpin a particular chat message.
References
TelegramBot.unpinChatMessage

@yagop please take a look at this PR. It's quite important feature to me.

@HeySreelal in pinMessage disable_notification field is also missed. Could I please ask you to implement this in a new PR? 🙏
https://core.telegram.org/bots/api#pinchatmessage

@arman-oganesyan, thanks for the reply!
The disable_notification can be passed directly into the form object, right? So, should I really change anything there? Please let me know, I'll be happy to contribute!

@HeySreelal thank you for your reply. I have not noticed that this can be passed to form object, as I am a bit new to JavaScript.
Thank you.

Perfect! Thanks for confirming @arman-oganesyan. 🚀
Looking forward to contributing more!
Have a great time.

message_id is an optional parameter. It can already be used. All optional parameters can be passed as an object to any method in this library.


Testing on i03: Round 4

We need to test:

Proper fixes from https://github.com/DiamondLightSource/python-artemis/issues/58
https://github.com/DiamondLightSource/python-artemis/pull/52

This went quite successfully, main issue it through up was that in https://github.com/DiamondLightSource/python-artemis/issues/59#issuecomment-1106624240.
Closing as I was the only one there to confirm


Bundles not in feed

Hello,
We found out that bundles are not exported to the channable feed. If we look in the JSON or preview output the bundle id's are missing from the feed. After a peek in the code it looks like it is missing from the filters: Source.php @ Line 351 Is this a know issue?

Hi Geoffrey, thanks for the notice and fixes. Bundle parents are now exported with min_price, price and max_price (v1.0.5: https://github.com/magmodules/magento2-channable/releases/tag/1.0.5)


fix(automerge): Fix stacks

copilot:all

Current dependencies on/for this PR:

main

PR #5020   👈

This stack of pull requests is managed by Graphite.


✨ Binary artifact exception for gradle-wrapper.jar when using validation action

What kind of change does this PR introduce?
Feature

[x] PR title follows the guidelines defined in our pull request documentation

What is the current behavior?
Scorecard considers gradle-wrapper.jar files to be harmful binary artifacts even when they are verified by the gradle/wrapper-validation-action action.
What is the new behavior (if this is a feature change)?**
gradle-wrapper.jar files will no longer be flagged by the binary artifacts check iff all conditions are met:

There is a workflow using the gradle/wrapper-validation-action action in a step in a job

That workflow passed for the latest commit on default branch

[x] Tests for the changes have been added (for bug fixes/features)

Which issue(s) this PR fixes
Fixes #1815
Special notes for your reviewer
Does this PR introduce a user-facing change?
For user-facing changes, please add a concise, human-readable release note to
the release-note
(In particular, describe what changes users might need to make in their
application as a result of this pull request.)

gradle-wrapper.jar files are no longer flagged by the Binary Artifacts check if the Gradle Wrapper Validation Action is enabled as part of a passing workflow.

Let us know when you need a review.