Cannot find module 'setupDevtools' from 'setup.js'

Summary
I use a react-native project with typescript and jest.
When I tried to install stryker and run it, I have the following message :
Cannot find module 'setupDevtools' from 'setup.js'

      at Resolver.resolveModule (../../node_modules/jest-resolve/build/index.js:169:17)
      at Object.<anonymous> (../../node_modules/react-native/jest/setup.js:30:1)

          ● Test suite failed to run

But when I use jest, I don't have any error.
Is something wrong with my config or is it a real issue ?
Stryker config
Stryker
module.exports = (config) => {
  config.set({
    // Test runners
    testRunner: 'jest',
    jest: {
      config: require('./jest.config.js'),
    },

    // Transpilers
    transpilers: ['typescript', 'babel'],
    tsconfigFile: 'tsconfig.json',
    babelrcFile: '.babelrc',

    // Reporters
    reporter: ['clear-text', 'progress'],
    coverageAnalysis: 'off',

    // Files
    files: [
      'src/**/*',
      'jest/**/*',
      '__mocks__/**/*',
    ],

    // Mutations
    mutator: 'typescript',
    // mutate: ['src/**/*.ts?(x)', '!src/**/*.container.ts', '!src/**/*.d.ts', '!**/index.ts'],
  });
};

Jest
module.exports = {
  preset: 'react-native',
  moduleFileExtensions: ['ts', 'tsx', 'js', 'jsx'],
  transform: {
    '\\.(js|jsx)$': '<rootDir>/node_modules/babel-jest',
    '\\.(ts|tsx)$': '<rootDir>/node_modules/ts-jest/preprocessor.js',
    '\\.(gql|graphql)$': '<rootDir>/node_modules/jest-transform-graphql',
  },
  transformIgnorePatterns: [
    'node_modules/(?!(jest-)?react-native|react-clone-referenced-element|@bam.tech/react-native-(root-siblings|modalbox)|static-container|react-navigation)',
  ],
  testRegex: '(/__tests__/.*|\\.(test|spec))\\.(ts|tsx|js|jsx)$',
  testPathIgnorePatterns: ['\\.snap$', '<rootDir>/node_modules/', '<rootDir>/stryker-tmp/'],
  cacheDirectory: '.jest/cache',
  moduleNameMapper: {
    '^[./a-zA-Z0-9$_-]+\\.(jpg|png|gif|eot|svg|ttf|woff|woff2|mp4|webm)$':
      '<rootDir>/jest/FileStub.js',
  },
  collectCoverageFrom: [
    'src/**/*.{js|ts|tsx|jsx}',
    '!src/**/*.container.ts',
    '!src/**/*.d.ts',
    '!**/index.ts',
  ],
  setupTestFrameworkScriptFile: '<rootDir>/jest/setupTests.js',
};

Babel
{
  "presets": ["react-native", "react-native-stage-0/decorator-support"]
}

Stryker environment
"stryker": "^0.22.4",
"stryker-api": "^0.16.1",
"stryker-babel-transpiler": "^0.4.2",
"stryker-jest-runner": "^0.6.0",
"stryker-typescript": "^0.10.2",

But also
"babel-core": "^6.26.0",
"babel-jest": "22.4.1",
"babel-preset-react-native": "4.0.0",
"babel-preset-react-native-stage-0": "^1.0.1",
"jest": "22.4.2",
"ts-jest": "^22.4.1",
"typescript": "^2.7.2"

Your Environment

software
version(s)

node
9.5.0

npm
5.6.0

Operating System
macOS High Sierra

Thanks for opening this issue!
Where is the setup.js file located?
What happens when you remove the files property from your Stryker config?

@simondel
Same error without the files property.
setup.js is located in node_modules/react-native/jest. First lines of this files are
const mockComponent = require.requireActual('./mockComponent');

require.requireActual('../Libraries/polyfills/babelHelpers.js');
require.requireActual('../Libraries/polyfills/Object.es7.js');
require.requireActual('../Libraries/polyfills/error-guard');

global.__DEV__ = true;

global.Promise = require.requireActual('promise');
global.regeneratorRuntime = require.requireActual('regenerator-runtime/runtime');

global.requestAnimationFrame = function(callback) {
  return setTimeout(callback, 0);
};
global.cancelAnimationFrame = function(id) {
  clearTimeout(id);
};

jest
  .mock('setupDevtools')
  .mock('npmlog');

// there's a __mock__ for it.
jest.setMock('ErrorUtils', require('ErrorUtils'));

jest
  .mock('InitializeCore', () => {})
  .mock('Image', () => mockComponent('Image'))
  .mock('Text', () => mockComponent('Text'))
  .mock('TextInput', () => mockComponent('TextInput'))
  .mock('Modal', () => mockComponent('Modal'))
  .mock('View', () => mockComponent('View'))
  .mock('RefreshControl', () => require.requireMock('RefreshControlMock'))
  .mock('ScrollView', () => require.requireMock('ScrollViewMock'))

If I remove .mock('setupDevtools), I have the same error for InitializeCore, then for Image, ...
If I comment all this file, I have the following error
Couldn't find preset "es2015" relative to directory "/Users/vincentl/Theodo/foodi/node_modules/request/node_modules/hawk"

But in this case jest doesn't work either.
It seems to be an older issue with jest and react-native (https://www.google.fr/search?q=setupdevtools+from+setup.js)

https://github.com/facebook/jest/issues/3822
https://github.com/facebook/jest/issues/1840

Awesome thanks! I'll try it out tomorrow :)

I'm having some issues reproducing this. When I run your repo on my machine (node 8, npm 5, Windows 10) I get the following message from Stryker:
    Couldn't find preset "es2015" relative to directory "C:\\dev\\tryouts\\StrykerTest\\node_modules\\hawk"

      at ../../node_modules/babel-core/lib/transformation/file/options/option-manager.js:293:19
          at Array.map (<anonymous>)
      at OptionManager.resolvePresets (../../node_modules/babel-core/lib/transformation/file/options/option-manager.js:275:20)
      at OptionManager.mergePresets (../../node_modules/babel-core/lib/transformation/file/options/option-manager.js:264:10)
      at OptionManager.mergeOptions (../../node_modules/babel-core/lib/transformation/file/options/option-manager.js:249:14)
      at OptionManager.init (../../node_modules/babel-core/lib/transformation/file/options/option-manager.js:368:12)
      at File.initOptions (../../node_modules/babel-core/lib/transformation/file/index.js:212:65)
      at new File (../../node_modules/babel-core/lib/transformation/file/index.js:135:24)
      at Pipeline.transform (../../node_modules/babel-core/lib/transformation/pipeline.js:46:16)

This got me wondering, why does your project use babel? Can't you use the typescript compiler to transform your js files?
In the case of Stryker the config transpilers: ['typescript', 'babel'] will feed all your files to the TypeScript transpiler and then hand all files to the Babel transpiler. This is probably not what you want.
After I removed babel from the project, I did get an error that relates to the error you have:
    Cannot find module '../transforms/transform-dynamic-import' (While processing preset: "C:\\dev\\tryouts\\StrykerTest\\node_modules\\babel-preset-react-native\\index.js")

      at getPreset (../../node_modules/babel-preset-react-native/configs/main.js:77:18)
      at Object.<anonymous> (../../node_modules/babel-preset-react-native/configs/main.js:91:14)

I'll investigate this further.

@simondel Thanks for the time you takes
I don't really know and can't explain why we need babel. We are starting using typescript on our project and still having some js files. For example, index.js, setupTest.js, ...,  and running yarn test:unit without babel will return
/home/vincentl/Perso/StrykerTest/jest/setupTests.js:1
    ({"Object.<anonymous>":function(module,exports,require,__dirname,__filename,global,jest){import Enzyme from 'enzyme';
                                                                                ^^^^^^

    SyntaxError: Unexpected token import

How did you remove babel from the project ?
And I'm not sure because I could only try tomorrow, but I think my real react-native project won't correctly run and build on IOS and Android without babel. For information, we're using this package. I'll check tomorrow.
But I'm surprised the provided repository does not produce error about setupDevtools on your computer.
I tried on Mac / Node 9.5 and Linux / Node 8.4 and I got it every time.
I need to comment the  node_modules/react-native/jest/setup.js from line 29 to the EOF to get the error you had
Couldn't find preset "es2015" relative to directory "/home/vincentl/Perso/StrykerTest/node_modules/request/node_modules/hawk"

In this case, if I remove setupTestFrameworkScriptFile from the jest config and use the test
expect(true).toBe(true);

It works !!!
But then, I removed
transpilers: ['typescript', 'babel'],
tsconfigFile: 'tsconfig.json',
babelrcFile: '.babelrc',

Still works ! Why ? It makes me confused.
Ok, if I go back and look at the preset error.
I found out the issue came from the following lines of setupTest.js
const mockDocumentForEnzymeMount = () => {
  const jsdom = require('jsdom');

  const { JSDOM } = jsdom;

  const { document } = new JSDOM('').window;
  global.document = document;
};
mockDocumentForEnzymeMount();

But then, if i run yarn add babel-preset-es2015, I have the error
/home/vincentl/Perso/StrykerTest/node_modules/jsdom/lib/jsdom/living/xmlhttprequest.js: missing super() call in constructor
         95 |
         96 |   class XMLHttpRequest extends XMLHttpRequestEventTarget.interface {
      >  97 |     constructor() { // eslint-disable-line constructor-super
            |     ^
         98 |       const theThis = Object.create(new.target.prototype);
         99 |       XMLHttpRequestEventTarget.setup(theThis);
        100 |       theThis.upload = XMLHttpRequestUpload.create();

I'll will keep investiguate tomorrow or this week-end.
During this time, yarn test:unit does not work with the error
Invariant Violation: __fbBatchedBridgeConfig is not set, cannot invoke native modules

And if I don't comment the  node_modules/react-native/jest/setup.js from line 29 to the EOF, tests pass but Stryker ask me for setupDevtools...

Ok, seems like I don't need babel for running application, but I need it for using jest, https://github.com/kulshekhar/ts-jest#react-native

I have the same error with:
Stryker config:
module.exports = config => {
    config.set({
        packageManager: 'yarn',
        testRunner: 'jest',
        jest: {
            projectType: 'react-ts',
            config: require('./configuration/jest.config.js')
        },
        mutator: 'typescript',
        tsconfigFile: 'tsconfig.json',
        transpilers: [],
        reporters: [
            'html',
            'clear-text',
            'progress',
            'dashboard'
        ],
        coverageAnalysis: 'off',
        mutate: [
            'src/**/*.ts'
        ]
    })
}

And Jest config:
module.exports = {
    preset: 'react-native',
    rootDir: '..',
    setupFiles: [
        '<rootDir>/configuration/jest.setup.js'
    ],
    snapshotSerializers: [
        'enzyme-to-json/serializer'
    ],
    moduleFileExtensions: [
        'ts',
        'tsx',
        'js'
    ],
    transform: {
        '^.+\\.js$': '<rootDir>/node_modules/react-native/jest/preprocessor.js',
        '\\.(ts|tsx)$': 'ts-jest'
    },
    testMatch: [
        '<rootDir>/__tests__/**/?(*.)+(spec|test).ts?(x)'
    ],
    testPathIgnorePatterns: [
        '\\.snap$',
        '<rootDir>/node_modules/'
    ],
    collectCoverageFrom: [
        '<rootDir>/src/**/*.{ts,tsx}'
    ],
    coveragePathIgnorePatterns: [
        '<rootDir>/__tests__/'
    ],
    coverageDirectory: '<rootDir>/jest/coverage',
    coverageReporters: [
        'html',
        'text',
        'text-summary'
    ]
}

Package
Version

Node
8.11 & 10.9

React Native
0.56

TS
3.0.3

Jest
23.5.0

Stryker
0.29.1

@oferRounds No sorry

I will try to figure out what's wrong before this year is done. Thanks for your patience

I've spent a couple of hours trying to reproduce this issue, but couldn't. I'm not experienced with Jest or React.
Can anyone create a public repo that reproduces this issue? Any help will be much appreciated. We really want these kind of use cases to work before we publish version 1. Thanks in advance ❤

I had this old repo https://github.com/VincentLanglet/StrykerTest
But now it give the error :
/Users/vincentl/Perso/StrykerTest/node_modules/react-native/jest/setup.js: babel-plugin-jest-hoist: The module factory of `jest.mock()` is not allowed to reference any out-of-scope variables.
    Invalid variable access: console

Yeah, I get that error as well, with regular tests. Any other reproduction repo? Or can you update it to work again? Sorry, but really can't do much without reproduction steps.

@nicojs I have this very light repo: https://github.com/mickaelw/test-stryker
Sorry in advance for iOS and Android folders

@mickaelw I've cloned the repo, but yarn test isn't working for me:
$ yarn test
yarn run v1.12.3
$ jest --config configuration/jest.config.js
 FAIL  __tests__/test.spec.tsx
  ● Test suite failed to run

    TypeScript diagnostics (customize using `[jest-config].globals.ts-jest.diagnostics` option):
    __tests__/test.spec.tsx:14:29 - error TS2605: JSX element type 'App' is not a constructor function for JSX elements.
      Property 'context' is missing in type 'App' but required in type 'ElementClass'.

    14         const app = shallow(<App/>)
                                   ~~~~~~

      node_modules/@types/enzyme/node_modules/@types/react/index.d.ts:315:9
        315         context: any;
                    ~~~~~~~
        'context' is declared here.

 PASS  __tests__/test2.spec.ts

Test Suites: 1 failed, 1 passed, 2 total
Tests:       1 passed, 1 total
Snapshots:   0 total
Time:        14.972s
Ran all test suites.
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.

Any ideas?

@nicojs yes, I think it's rxjs-tslint dependency. You can remove all ^ in the package.json and re install all package with the good version
Let me know if it's better ;)

@mickaelw It's an issue with type in your dependencies.
You ask for types/react 16.7.3 but enzyme is still using types/react 16.4.13 in you yarn.lock.
I made a PR, it's not the best fix but it's enough.
https://github.com/mickaelw/test-stryker/pull/1
@nicojs In this PR, yarn test works for me, but not yarn stryker

I've been able to reproduce the error without Stryker, just plain jest + react-native. I've opened up an issue at react-native. Hopefully there is a solution. https://github.com/facebook/react-native/issues/22823

@nicojs Great job ! Thanks

Cool! Do you have a workaround?

They closed the issue and redirect us to :
https://github.com/facebook/jest/issues/1477
https://github.com/facebook/jest/issues/5356
https://github.com/facebook/jest/pull/7549
It seems to be a jest issue. But if it is, why does this happen with react-native and not react or other libraries @nicojs ?

Any updates on this issue? Or any workaround?
Using<EMAIL_ADDRESS>

I'm afraid the workaround that I specified is the only one for now. The issue in Jest is being tracked here:
https://github.com/facebook/jest/issues/5356

In hindsight, setting symlinkNodeModules to files might be enough to fix the issue see #1564.

I set the symlinkNodeModules to false (not to files ;) but I get another error:
ERROR InitialTestExecutor One or more tests resulted in an error:
	Test runner crashed. Tried twice to restart it without any luck. Last time the error message was: Error: : ● Validation Error:

  Module <rootDir>/node_modules/react-native/jest/preprocessor.js in the transform option was not found.
         <rootDir> is: /Users/rang/Documents/Workspace/ReactNativeWorkspace/react-native-skeleton/.stryker-tmp/sandbox4155167

  Configuration Documentation:
  https://jestjs.io/docs/configuration.html

● Validation Error:

  Module <rootDir>/node_modules/react-native/jest/preprocessor.js in the transform option was not found.
         <rootDir> is: /Users/rang/Documents/Workspace/ReactNativeWorkspace/react-native-skeleton/.stryker-tmp/sandbox4155167

  Configuration Documentation:
  https://jestjs.io/docs/configuration.html

Error: : ● Validation Error:

  Module <rootDir>/node_modules/react-native/jest/preprocessor.js in the transform option was not found.
         <rootDir> is: /Users/rang/Documents/Workspace/ReactNativeWorkspace/react-native-skeleton/.stryker-tmp/sandbox4155167

  Configuration Documentation:
  https://jestjs.io/docs/configuration.html

● Validation Error:

  Module <rootDir>/node_modules/react-native/jest/preprocessor.js in the transform option was not found.
         <rootDir> is: /Users/rang/Documents/Workspace/ReactNativeWorkspace/react-native-skeleton/.stryker-tmp/sandbox4155167

  Configuration Documentation:
  https://jestjs.io/docs/configuration.html

    at ChildProcess.worker.on (/Users/rang/Documents/Workspace/ReactNativeWorkspace/react-native-skeleton/node_modules/@stryker-mutator/core/src/child-proxy/ChildProcessProxy.js:100:68)
    at emitTwo (events.js:126:13)
    at ChildProcess.emit (events.js:214:7)
    at emit (internal/child_process.js:772:12)
    at _combinedTickCallback (internal/process/next_tick.js:141:11)
    at process._tickCallback (internal/process/next_tick.js:180:9)
15:14:53 (28469) ERROR StrykerCli an error occurred Error: Something went wrong in the initial test run
    at InitialTestExecutor.validateResult (/Users/rang/Documents/Workspace/ReactNativeWorkspace/react-native-skeleton/node_modules/@stryker-mutator/core/src/process/InitialTestExecutor.js:85:15)
    at InitialTestExecutor.run (/Users/rang/Documents/Workspace/ReactNativeWorkspace/react-native-skeleton/node_modules/@stryker-mutator/core/src/process/InitialTestExecutor.js:40:14)
    at <anonymous>
    at process._tickCallback (internal/process/next_tick.js:188:7)

Any idea how to make it work?

Although marked as stale and closed, this bug is still present. Luckily #2706 solves this. It will be released in v4.4 🎉

Although marked as stale and closed, this bug is still present. Luckily #2706 solves this. It will be released in v4.4 🎉

It just got released. See docs here: https://stryker-mutator.io/docs/stryker/configuration/#inplace-boolean

It just got released. See docs here: https://stryker-mutator.io/docs/stryker/configuration/#inplace-boolean


What to do about entries that have their stem set as CHECK

There are a few entries that have their stem set as "CHECK":
<e>
   <lg>
      <l pos="N">ahpinêkinowas</l>
      <lc>NI-5</lc>
      <stem>CHECK</stem>
   </lg>
   <mg>
   <tg xml:lang="eng">
      <t pos="N" sources="CW">parchment bag</t>
   </tg>
 </mg>
</e>

@aarppe — what is the correct thing to do here? Note: itwêwina still does not import them (see #235), however this will become an issue.

Those cases are marked with CHECK so that the linguists would sort out their stem, as well as other matters. So if they're not included, that is the correct (and conservative) decision.
The ideal solution is that these would be captured when uploading new CW (or MD) content to our DDB (whether that will be the same as directly used by itwêwina remains to be seen), and then flagged there as items to be checked. Then, depending on what we decide, such cases (now marked as CHECK) would either be included in part in itwêwina, or not at all.


[KYUUBI #6688] Fix kyuubi batch state abnormal state

:mag: Description
Issue References 🔗

This pull request fixes #6688
Describe Your Solution 🔧

when failed to kill the batch, check the current application info
if the application state is UNKNOWN(less than submit timeout) or NOT_FOUND, mark the batch state to CANCELED
If the k8s pod added after the batch marked as CANCELED, delete the pod

Types of changes :bookmark:

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

Test Plan 🧪
Behavior Without This Pull Request :coffin:
Behavior With This Pull Request :tada:
Related Unit Tests

Checklist 📝

[ ] This patch was not authored or co-authored using Generative Tooling

Be nice. Be informative.

cc @pan3793 @ulysses-you @zwangsheng

Codecov Report
Attention: Patch coverage is 0% with 42 lines in your changes missing coverage. Please review.

Project coverage is 0.00%. Comparing base (dff40e8) to head (695bb80).
Report is 6 commits behind head on master.

Files with missing lines
Patch %
Lines

...kyuubi/engine/KubernetesApplicationOperation.scala
0.00%
28 Missing :warning:

...g/apache/kyuubi/operation/BatchJobSubmission.scala
0.00%
14 Missing :warning:

Additional details and impacted files
@@          Coverage Diff           @@
##           master   #6670   +/-   ##
======================================
  Coverage    0.00%   0.00%
======================================
  Files         683     683
  Lines       42205   42242   +37
  Branches     5756    5763    +7
======================================
- Misses      42205   42242   +37

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

thanks, merged to 1.10.0/1.9.3


Deployment Release Notes for 5 October

Hi @MarkvanMents  in content/developerportal/deploy/studio-deployment-settings.md
the Build Only works for studio pro, so if Build Only is selected you would see no target selected error when try to publish from Studio
I think same need to be adjusted in the release notes to mention that Build Only works for only studio pro.

The release is done @MarkvanMents . Please go ahead to publish the release notes. Kindly check Madhu's comment above.

Made updates requested and publishing.


synchronize JS and Py version requirements for IDOM

The IDOM client and core libraries now have synchronized versions. To ensure they work correctly together we need to ensure the version requirements we use both are the same.

Are we going to configure an automated method of updating the JS and Py versions, or will it have to manually be bumped on each django-idom version release?

For now I've just been manually bumping the version for django-idom, idom-jupyter, etc.
Figuring out an automated way to do that would be nice though. Ideally, we could just have a chron job in GitHub actions that checks to see if there's a new version of IDOM available and then automatically creates a PR with the relevant changes if there is.

Actually it might be easier to generate an issue for each downstream repo when a new release of IDOM is published. Not quite as automated, but it's also less infra to maintain.

@rmorshea
Since current pypi installs can be potentially out of sync due to unpinned versions, I think it's a good idea to push out a pypi update to resolve this.

I can't tonight, but I'll create a quick PR tomorrow to bump the version and then make a release.


Error when running iotedgectl setup

I got an error on running iotedgectl setup more details at:
https://github.com/Azure/iot-edge/issues/585
Workaround Uninstall and reinstall idna and pyopenssl.
sudo pip uninstall idna pyopenssl -y
sudo pip install idna pyopenssl

Document Details
⚠ Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.

ID: dd1c71ba-2815-82c5-90b8-26f674b3ff25
Version Independent ID: a6d86244-d2ff-6aec-2024-957833b1c823
Content: Simulate Azure IoT Edge on Linux
Content Source: articles/iot-edge/tutorial-simulate-device-linux.md
Service: iot-edge
GitHub Login: @kgremban
Microsoft Alias: kgremban

@nzigel Thanks for the feedback! I have assigned the issue to the content author to evaluate and update as appropriate.

Reference GitHub #585
https://github.com/Azure/iot-edge/issues/585

Hi @nzigel, thanks for bringing up this issue. I read through the IoT Edge product issue that you linked to, and see that some of the contributors there made recommendations for how this error could be resolved with a product fix. I'm not sure about the best way to incorporate this into the documentation. I don't want to include it in this tutorial because it can be confusing to include too many edge case workarounds when new users are trying to get started. Perhaps I could add this information to the troubleshooting article. What do you think? How easy was it for you to find the other github issue that helped unblock you?

@kgremban it was easy for me to find to unblock but I think if we could have the workaround visible in comments or troubleshooting that would help. I worry that people may stop at the error if they don't understand what may be happening as error isn't very descriptive.

@kgremban Its not really that much of an edge case. Anyone following the instructions will get blocked by this error on Raspbian and ubuntu, two pretty core use cases.

I just encountered the problem but the work around did not do it for me:

sudo pip uninstall idna pyopenssl -y
sudo pip install idna pyopenssl
was followed by:

I have tried it on Ubuntu1604/1804 + Debian (latest).
Is there any other Linux I can try out or is there any fix?

Also tried it on Fedora (latest) and it failed in exactly the same way.

Hi @JensNordenbro, please try pip install idna==2.6

@kgremban ; works on Ubuntu1604; not on Fedora, but at least I can continue! Thanks!

Hi @nzigel. I wanted to let you know that a new version of the IoT Edge runtime was released today, and it no longer uses pip to install dependencies.
@Mike-Ubezzi-MSFT would you #please-close this issue as the product has been updated?

We will now close this issue. If there are further questions regarding this matter, please reopen it and we will gladly continue the discussion.

@kgremban ; I can only see https://github.com/Azure/iot-edge-v1, not v2 repo.
Where is it located?

The repo is at https://github.com/azure/azure-iotedge but the v2 code hasn't been released there yet. The doco has been updated with the GA version and setup process which quite different to the preview version
https://docs.microsoft.com/en-us/azure/iot-edge/quickstart-linux

Hi @toddwhitehead ;

I notice that you are bundling a docker (Moby) package of your own. I am trying to understand why, since for example Raspberrian has Docker, Yocto can build Docker and ResinOS does this in the form of Balena ?!
What are the dependencies of the kernel/userland for this work? (cgroup ?)


Import dry-logic predicates as macros

The idea: import most dry-logic predicates as macros
PoC
require 'dry/validation'

class ApplicationContract < Dry::Validation::Contract
end

predicates = Dry::Logic::Predicates.public_methods.grep(/\?\Z/).sort - Object.public_methods - Module.public_methods
registry = Dry::Schema::PredicateRegistry.new(Dry::Logic::Predicates)

predicates.each do |name|
  arg_list = registry.arg_list(name).map(&:first)

  ApplicationContract.register_macro(name) do |macro:|
    args = [*macro.args, value]
    result = Dry::Logic::Predicates.public_send(name, *args)

    return if result

    message_opts = arg_list.zip(args).to_h

    key.failure(name, message_opts)
  end
end

class MyContract < ApplicationContract
  params do
    required(:age).filled(:integer)
  end

  rule(:age).validate(gteq?: 18)
end

contract = MyContract.new

puts contract.(age: 17).errors.to_h.inspect

# {:age=>["must be greater than or equal to 18"]}

Requirements

This should exclude some predicates, like type-checks and maybe some more
This should be an extension, so that users can load it on demand via Dry::Validation.load_extensions(:predicate_macros)
The extension should add a contract class method that will load macros, we don't want to define them as global macros after all

@solnic could I take this one?

@waiting-for-dev sure, thank you. I just sent you an invite to the repo. Please assign to yourself when it's accepted so that others can see you're working on it.


Update default-permissions-user-rights.md

updated some verbiage for WS2016 // IIS 10, and updated User Rights Assignments with current names

@mahamr : Thanks for your contribution! The author(s) have been notified to review your proposed change.

@mahamr Could you help sign off the PR if it's ready for review? Thanks.

@mahamr Could you help sign off the PR if it's ready for review? Thanks.

I feel this is ready for review. Thanks!

@sevend2 : Thanks for your contribution! The author(s) have been notified to review your proposed change.

@mahamr Thanks for your contribution! Will merge the PR.


No welcome message in react despite userID set

Is it an issue related to Adaptive Cards?
No
Is this an accessibility issue?
No
What version of Web Chat are you using?
Latest production
Which distribution are you using Web Chat from?
NPM
Which hosting environment does this issue primarily affect?
Web apps
Which browsers and platforms do the issue happened?
Browser: Chrome (latest), Browser: Safari (latest)
Which area does this issue affect?
Chat history
Which theme pack does this issue affect?
I did not test it on other theme packs
What is the public URL for the website?
No response
Please describe the bug
I have what I believe to be the simplest possible react setup to get the chatbot window open and running (via secret for now, not token). As far as I can tell from the docs this should trigger a welcome message, but doesn't.
I've confirmed a random user ID is set in the payload POSTed to https://directline.botframework.com/v3/directline/conversations . I've tried using and omitting the userID prop (docs seemed to suggest whether it was omitted or prefixed with dl_ , a random one would be generated regardless?)
import React, { useMemo } from "react";
import ReactWebChat, { createDirectLine } from "botframework-webchat";

function ChatBot() {
  const directLine = useMemo(
    () =>
      createDirectLine({
        token:
          "SECRET_HERE",
      }),
    []
  );

  return (
      <ReactWebChat directLine={directLine} userID="dl_throwaway" />
  );
}

export default ChatBot;

(On a side note, I've found the docs & API quite difficult to explore & understand while getting started with a react setup)
Do you see any errors in console log?
many instances of "Support for defaultProps will be removed from function components in a future major release. Use JavaScript default parameters instead." which I'm taking to be an unrelated issue

How to reproduce the issue?

Create react project
Paste component above into project and add to root

What do you expect?
Set welcome flow to appear, as per iframe embed.
What actually happened?
No messages received
Do you have any screenshots or recordings to repro the issue?
No response
Adaptive Card JSON
No response
Additional context
No response

@benferns - Thank you for your patience. Are you still experiencing an issue with this? If so, can you tell me

Which version of Web Chat you are using?

Which version of NPM you are using?

Which version of React you are using?

Are you able to provide minimum reproducible code for your Web Chat instance? If not, can you provide more code showing how the ChatBot() function is being used, including any parent components, if relevant?

Closing due to inactivity. Please feel free to reopen if the issue persists or you have new details to share.


Broken pip install cadquery-ocp dependency for Apple silicon platform

I'm unable to get cadquery/ocp working with build123d.

I've tried straightforward pip install as below, which hangs up on finding a version of cadquery-ocp:

ERROR: Could not find a version that satisfies the requirement cadquery-ocp>=7.7.0 (from build123d) (from versions: none)
ERROR: No matching distribution found for cadquery-ocp>=7.7.0

Reviewing that package's instructions, I've tried installing via conda install -c conda-forge -c cadquery ocp which is successful, but does not satisfy the pip dependencies of build123d

However, disabling build123d's dependencies on cadquery-ocp and ocpsvg (via editing pyproject.toml) allow installation of build123d to proceed, as in my case I have ocpsvg==0.2.1 already installed.
Can a workaround/accommodation for installation on Apple silicon be included in the install process, even if it's specific manual instructions in the readme, so that Apple silicon users don't have to hack their way to this?

Whoops, this is well known and tracked here

Whoops, well known and tracked here.

saw that you closed already, but FYI we also have a workaround in the docs https://build123d.readthedocs.io/en/latest/installation.html#special-notes-on-apple-silicon-installs

Thanks! I had been limping along on having installed ocp and cadquery but not cadquery-ocp but I was still getting some inline Jupyter rendering with a horrible limited UI. After following those directions, everything is broken: most unit tests fail in my local development branch of build123d, and in VS Code Jupyter notebooks I get a vtk error message and blank canvass when it tries to render.
I think I'm going to try Docker.


⚠ Bofrost.lu has degraded performance

In a55f503, Bofrost.lu (https://www.bofrost.lu) experienced degraded performance:

HTTP code: 200
Response time: 829 ms

Resolved: Bofrost.lu performance has improved in cdd22b1 after 14 minutes.


Bug when orientation is changed

Steps to reproduce:

Select any album
Select any image(s)
Change orientation from portrait to landscape or vice versa
Press ADD

A new instance of AlbumSelectActivity opens. This is one of a few ways of reproducing this bug. It occurs only when there is an orientation change on using the library. Log reads:
Duplicate finish request for ActivityRecord{1579d8c u0 com.darsh.example.sample/com.darsh.multipleimageselect.activities.AlbumSelectActivity t1162 f}

Bug occured in commit 09bf41c on altering permission request logic.
Temporary fix: Use any of the released versions of library or any commit on or before commit 088585b.

The bug was due to the fact that on orientation change, the MainActivity of the sample was recreated. In it's onCreate method, AlbumSelectActivity is started and hence it would restart. This was verified by preventing MainActivity of the sample recreation by overriding configuration changes - the library worked as expected.


Godot ENetConnection.service() doesn't work with multiplayer.multiplayer_peer.host

Tested versions

Reproducible in 4.2.stable

System information
MacOS 12.5 - Godot v4.2.stable.official
Issue description
The service() function should return an EVENT_CONNECT when a new player connects. This works if I simply create an ENetMultiplayerPeer and create_server or create_client, however, as soon as I set the multiplayer.multiplayer_peer variable to this newly created ENetMultiplayerPeer, the service() function no longer returns any non-zero events.
Steps to reproduce
Open the MRP. Set the project to open two instances (Debug -> Run Multiple Instances -> Run 2 Instances). Run the project. Click the host button on one instance and then join on the other. You would expect some prints (two since there's two connections), but nothing happens.
I also have some commented lines to show that it does work as long as I don't set the multiplayer.multiplayer_peer variable. Uncomment line 12. Comment lines 13, 22, and 30. Again, run project and click host and join. You should see some printouts from the non-zero event (print on line 16).
Minimal reproduction project (MRP)
demo.zip

Bump

@maticstric please don't bump issues without adding more information.
Opening issues in random maintainers repositories is also very impolite.

This is mostly a documentation issue (we could add some extra checks in code to throw an error).
The ENetConnection.service function should not be called when using the ENetMultiplayerPeer, since that is used internally by ENetMultiplayerPeer.poll() and calling it manually will prevent the multiplayer peer from working correctly.

My bad.
The documentation for using Godot multiplayer without its "High-level multiplayer" features is pretty much non-existent, so I felt I didn't have a good way forward. Had to spend a few days looking at source code to figure out what I'm supposed to do. Still not sure if I totally get it, but ENetConnection seems to be the important class. It would be nice to mention this somewhere or maybe have a simple example project. There don't even seem to be random online (blog, youtube, etc.) tutorials for this.
For a beginner to Godot multiplayer it's very hard to keep track of the differences between the many ENet/Multiplayer classes in Godot (MultiplayerAPI, ENetMultiplayerPeer, MultiplayerPeer, PacketPeer, ENetConnection, ENetPacketPeer, etc.).
Thanks for the help!


Not able to export few reports

Hi Team,
I am not able to export few reports.
Got below error log. Can someone please advise.
Version 1.3.1
It has multiple datasets
Traceback (most recent call last):
File "/layers/google.python.pip/pip/lib/python3.7/site-packages/flask_appbuilder/api/init.py", line 85, in wraps
return f(self, *args, **kwargs)
File "/workspace/superset/views/base_api.py", line 85, in wraps
raise ex
File "/workspace/superset/views/base_api.py", line 82, in wraps
duration, response = time_function(f, self, *args, **kwargs)
File "/workspace/superset/utils/core.py", line 1429, in time_function
response = func(*args, **kwargs)
File "/layers/google.python.pip/pip/lib/python3.7/site-packages/flask_appbuilder/api/init.py", line 155, in wraps
return f(self, *args, **kwargs)
File "/workspace/superset/utils/log.py", line 241, in wrapper
value = f(*args, **kwargs)
File "/workspace/superset/dashboards/api.py", line 718, in export
requested_ids
File "/workspace/superset/commands/export.py", line 61, in run
for file_name, file_content in self._export(model):
File "/workspace/superset/dashboards/commands/export.py", line 140, in _export
target["datasetUuid"] = str(dataset.uuid)
AttributeError: 'NoneType' object has no attribute 'uuid'
Regards,
Naren

What format were you importing the reports in? Did you check if it has a uuid column?

Importing with YAML zip file. We do not have any column called 'uuid'

@AAfghahi @Narendra678 is anyone able to confirm that this is still an issue in Superset 2.0.1, or shall we close it since it's been inactive for upward of a year?


Organization Approval Flow Completed

Fixes #307
Description

Set default values for approved and declined to false in Schema
Parameter of Model.findById changed to string
Do not allow change value of approved and declined with update org api

@jhasuraj01 Please do one thing, if in some places of code camel casing is not used, then change the variable name to make sure it uses the camel casing. In some places orgid is used, let's use orgId. Similarly in all other places.

in orgController you have used delete keyboard. It will work here. But in some other parts of code, we have simply make the property on the object undfined. I think we should maintain consistency in code style. So use req.body.approved = undefined and req.body.declined = undefined

I used delete keyword to avoid accidental overwrite of those fields, does settings it to undefined behave same?

in orgController you have used delete keyboard. It will work here. But in some other parts of code, we have simply make the property on the object undfined. I think we should maintain consistency in code style. So use req.body.approved = undefined and req.body.declined = undefined

I used delete keyword to avoid accidental overwrite of those fields, does setting it to undefined behave same?

@gauravdas014 please have a look

@gauravdas014 you can merge #310 and #313. I will push all the necessary changes here.

in orgController you have used delete keyboard. It will work here. But in some other parts of code, we have simply make the property on the object undfined. I think we should maintain consistency in code style. So use req.body.approved = undefined and req.body.declined = undefined

I used delete keyword to avoid accidental overwrite of those fields, does setting it to undefined behave same?

@gauravdas014 please have a look

Seems it's better to leave as delete. Don't change, keep it delete only

@gauravdas014 I have made all the necessary changes please review

@jhasuraj01 Great work with the API docs!
Would you like to work on
(i) Writing tests for API
(ii) Integrate backend API to the React App
These are the major tasks left.

@jhasuraj01 Great work with the API docs!
Would you like to work on
(i) Writing tests for API
(ii) Integrate backend API to the React App
These are the major tasks left.

I would have to learn unit testing and basics of react before starting with the issue, I will update you soon

@jhasuraj01 Great work with the API docs!
Would you like to work on
(i) Writing tests for API
(ii) Integrate backend API to the React App
These are the major tasks left.

I would have to learn unit testing and basics of react before starting with those issues, I will update you soon

Feel free to dm me in discord, if you need any help in learning

@gauravdas014 Thanks in advance 😄


Windows Extended Protection support

Is your feature request related to a problem? Please describe.
When using the library together the sample code provided to create a "Negotiate" header and then using that header with httpClient to make a request to a website, it fails if the receiving IIS has Windows Extended Protection set to required.
Describe the solution you'd like
It would be great if there was a way to add channel binding information when the apReq (i think) is created.

Yeah, good feature. In theory this could be built out by an application directly by filling in the DelegationInfo object during AP-REQ creation, but that's certainly a pain.

I'm just eyeballing this so I haven’t looked at the Windows side, but I believe you’re missing the MD5 hash and/or MIC to bind the data to the session.
https://www.rfc-editor.org/rfc/rfc6542.html#section-3.1
https://www.rfc-editor.org/rfc/rfc4121#section-<IP_ADDRESS>

From: Mika @.>
Sent: Thursday, March 14, 2024 7:00:31 AM
To: dotnet/Kerberos.NET @.>
Cc: Comment @.>; Subscribed @.>
Subject: Re: [dotnet/Kerberos.NET] Windows Extended Protection support (Issue #366)
First of all, thanks for taking the time to answer and to point me in the right direction.
I did give it a go (well, a lot of go's actually) but unfortunately I wasn't able to get it working. While this is not a support channel perhaps you can easily see where i went wrong.
By your direction I made the changes to DelegationInfo.cs
I started with declaring:
public const int ChannelBindingLength = 0x10;
public readonly byte[] cbt_zeros = new byte[] {
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
};
public readonly byte[] tls_server_end_point = new byte[] {
0x74, 0x6c, 0x73, 0x2d, 0x73, 0x65, 0x72, 0x76, 0x65, 0x72, 0x2d, 0x65, 0x6e, 0x64, 0x2d, 0x70, 0x6f, 0x69, 0x6e, 0x74, 0x3a
};
And then I attempted to change the Encode method like below but when i add "Negotiate " + Convert.ToBase64String(ticket.EncodeGssApi().ToArray()) to the Authorization: header of a http request the binding fails.
public ReadOnlyMemory Encode()
{
using (var stream = new MemoryStream())
using (var writer = new BinaryWriter(stream))
{
X509Certificate cert = new X509Certificate("C:\Temp\cert\test\publicKey.cer");
            using (var hasher = SHA256.Create())
            {
                var hash = hasher.ComputeHash(cert.GetRawCertData());
                int cbtLength = cbt_zeros.Length + tls_server_end_point.Length + hash.Length + 4;
                var cbt = new byte[cbtLength];

                int pos = 0;
                //first 16 bytes zeros
                Array.Copy(cbt_zeros, 0, cbt, pos, cbt_zeros.Length);

                //add 4 bytes of app data length (tls prefix + cert hash)
                byte[] dataLength = new byte[] { (byte)(tls_server_end_point.Length + hash.Length), 0, 0, 0 };
                pos += cbt_zeros.Length;
                Array.Copy(dataLength, 0, cbt, pos, 4);

                //add tls prefix
                pos += 4;
                Array.Copy(tls_server_end_point, 0, cbt, pos, tls_server_end_point.Length);

                //add cert hash
                pos += tls_server_end_point.Length;
                Array.Copy(hash, 0, cbt, pos, hash.Length);

                this.ChannelBinding = cbt;
            }

            if (this.ChannelBinding.Length == 0)
            {
                this.ChannelBinding = new byte[ChannelBindingLength];
            }

            writer.Write(this.ChannelBinding.Length);
            writer.Write(this.ChannelBinding.ToArray());

            if (this.DelegationTicket != null)
            {
                this.Flags |= GssContextEstablishmentFlag.GSS_C_DELEG_FLAG;
            }

            writer.Write((int)this.Flags);

            if (this.DelegationTicket != null)
            {
                writer.Write((short)this.DelegationOption);

                var deleg = this.DelegationTicket.EncodeApplication();

                writer.Write((short)deleg.Length);

                writer.Write(deleg.ToArray());
            }

            return stream.ToArray();
        }
    }

—
Reply to this email directly, view it on GitHubhttps://github.com/dotnet/Kerberos.NET/issues/366#issuecomment-1997528881 or unsubscribehttps://github.com/notifications/unsubscribe-auth/AAJHTYI5RCJVKATAFXVFBNDYYGUQBBFKMF2HI4TJMJ2XIZLTSSBKK5TBNR2WLJDUOJ2WLJDOMFWWLO3UNBZGKYLEL5YGC4TUNFRWS4DBNZ2F6YLDORUXM2LUPGBKK5TBNR2WLJDUOJ2WLJDOMFWWLLTXMF2GG2C7MFRXI2LWNF2HTAVFOZQWY5LFUVUXG43VMWSG4YLNMWVXI2DSMVQWIX3UPFYGLAVFOZQWY5LFVE2TMNBSG4ZDGNJXURXGC3LFVFUGC427NRQWEZLMVRZXKYTKMVRXIX3UPFYGLLCJONZXKZKDN5WW2ZLOOSTHI33QNFRXHE4CUR2HS4DFVJZGK4DPONUXI33SPGSXMYLMOVS2QOBVGQ4DSMJTHCBKI5DZOBS2K2LTON2WLJLWMFWHKZNKGIYTQMRRGU2TMMZRQKSHI6LQMWSWYYLCMVWKK5TBNR2WLKJVGY2DENZSGM2TPJ3UOJUWOZ3FOKTGG4TFMF2GK.
You are receiving this email because you commented on the thread.
Triage notifications on the go with GitHub Mobile for iOShttps://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Androidhttps://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.

Hi, you were absolutely right about the MD5 hash. For some reason I thought that part was only for NTLM. Thanks a ton for taking the time to help out. Hopefully this helps someone else.


use target_compile_definitions for TINYOBJLOADER_USE_DOUBLE

This is the solution mentioned by @noma at https://github.com/syoyo/tinyobjloader/issues/231#issuecomment-551854950. I tested it and it is working as intended. Now the downstream user can avoid having to add target_compile_definitions(${PROJECT_NAME} PUBLIC TINYOBJLOADER_USE_DOUBLE) in their downstream CMakeLists.

awesome! merged!

@syoyo thanks for the quick turnaround, would it be possible for you to bump up the release? It would be awesome if vcpkg can get the latest update.

ok, tagged  recent master as v2.0.0-rc2 https://github.com/syoyo/tinyobjloader/releases/tag/v2.0.0-rc2


Add data source stats by type

Description

Add data_counts_by_connector_type metric into the plugins, exposed via /stats API

BUILD SUCCESSFUL in 19m 37s
172 actionable tasks: 115 executed, 57 up-to-date

Usage:

Empty state

curl localhost:9200/_plugins/_ppl/stats
{"active_data_sources_count":{} ... }

Create several data sources

curl --request POST \
  --url localhost:9200/_plugins/_query/_datasources \
  --header 'content-type: application/x-ndjson' \
  --data '{"name": "mys5","description": "","connector": "SPARK","allowedRoles": [],"properties": {"glue.auth.type": "iam_role","glue.auth.role_arn": "arn:aws:iam::123456:role/flint-opensearch-role","glue.indexstore.opensearch.uri": "http://localhost:9200","glue.indexstore.opensearch.auth": "noauth"}}'

Run stats API again

curl localhost:9200/_plugins/_ppl/stats
{"active_data_sources_count":{"OPENSEARCH":1,"S3GLUE":4}

Issues Resolved
[List any issues this PR will resolve]
Check List

[x] New functionality includes testing.

[x] All tests pass, including unit test, integration test and doctest

[x] New functionality has been documented.

[x] New functionality has javadoc added
[x] New functionality has user manual doc added

[x] Commits are signed per the DCO using --signoff

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.

Python compatible issue on MacOS. Not related to the change.
> Task :doctest:doctest FAILED
======================================================================
ERROR: test_docs (unittest.loader._FailedTest.test_docs)
----------------------------------------------------------------------
ImportError: Failed to import test module: test_docs
Traceback (most recent call last):
  File "/Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/unittest/loader.py", line 137, in loadTestsFromName
    module = __import__(module_name)
             ^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/runner/work/sql/sql/doctest/test_docs.py", line 16, in <module>
    from opensearch_sql_cli.opensearch_connection import OpenSearchConnection
  File "/Users/runner/work/sql/sql/doctest/sql-cli/src/opensearch_sql_cli/opensearch_connection.py", line 6, in <module>
    import boto3
  File "/Users/runner/work/sql/sql/doctest/.venv/lib/python3.12/site-packages/boto3/__init__.py", line 16, in <module>
    from boto3.session import Session
  File "/Users/runner/work/sql/sql/doctest/.venv/lib/python3.12/site-packages/boto3/session.py", line 17, in <module>
    import botocore.session
  File "/Users/runner/work/sql/sql/doctest/.venv/lib/python3.12/site-packages/botocore/session.py", line 29, in <module>
    import botocore.configloader
  File "/Users/runner/work/sql/sql/doctest/.venv/lib/python3.12/site-packages/botocore/configloader.py", line 19, in <module>
    from botocore.compat import six
  File "/Users/runner/work/sql/sql/doctest/.venv/lib/python3.12/site-packages/botocore/compat.py", line 33, in <module>
    from botocore.vendored.six.moves import http_client
ModuleNotFoundError: No module named 'botocore.vendored.six.moves'

Discussed with @vamsi-amazon offline, there is an opportunity to rework all the schedulers that scan the index.


Sotw add limitador reconcile

Introduces the reconcile function for the limitador resource.

@KevFan Yes, I can do that bit of the rename. The point about the removing the logic from the kuadrant controller being part of this PR is not need. There is no updating of the resources only creating. If both methods are in place, one will get the update first while the other will get a version out of date error. Which they both can handle. The PR for removing the work is already opened, #888. Once this would be merged that can be merged, (would require a rebase to pass test)


German Translation Says 1st of October Rather Than 1st of September

This sentence:
[quote]
Seit dem 1. Oktober 2019 werden neue alle Office 365-Kunden in Microsoft Teams integriert und erhalten keinen Zugriff auf Skype for Business Online.
[/quote]
Should probably say "Ab dem 1. September 2019...." -- all other languages I checked (EN-US and FR-FR) say 1st of September, not October.
Thanks.

@teodordeaconescu Hello, we strongly appreciate your feedback. Could you please link the document you are reffering to? Thanks!

@scanum - here's the article in German that appears to be incorrect:
https://docs.microsoft.com/de-de/microsoftteams/faq-journey
here's the article in English, where the information is correct:
https://docs.microsoft.com/en-us/microsoftteams/faq-journey
Thanks,
Teodor

@samanthaw @OfficeGlobal

@OfficeGlobal Could you please assist in this issue? Thanks!

@teodordeaconescu , @scanum the date was updated. Thank you

@teodordeaconescu Thank you for submitting feedback. We understand that this issue has been resolved.
Please feel free to re-open this issue if there is a specific area of the docs that we can improve or make better. Thank you.


include priority ?

Would you be interested in including priority in tasks (JMS also has this)? I have created a preliminary branch for this that seems to do what I need: https://github.com/kennywest/db-queue/tree/add_priority
Thanks for considering.

I think its not a good idea because in some cases low priority tasks wont be processed at all. Did you consider storing high priority tasks in another queue?
Could you provide your use case?

I am also interested in having a priority-based scheduler for db-queue (willing to make a PR if the idea is accepted). However, definitely the sorting approach can cause bottle-neck for lower priority jobs if higher priority tasks continuously are added to the queue.
I think the solution here is a quota based scheduler. Imagine the following queues:

High priority: 10
Medium priority: 5
Low priority: 1

Now, assuming that we have infinite number of tasks in each queue, in each cycle 16 will be picked, 10 high priority, 5 medium, and 1 low priority. To make it more efficient, If it tried to pick a high priority and there were none, instead of trying 9 more times, it can just jump to medium priority.
Obviously, a simpler implementation of this is to start 10 threads for high, 5 threads for Medium, and 1 thread for low priority. However, I prefer the scheduler approach.
But why?
Not sure about @kennywest's case but we have few background tasks that have to be processed as soon as possible, a majority of tasks with medium priority, and relatively small number of low priority tasks. In theory, we could start three processes (or containers, VMs, ...) to handle the incoming tasks and potentially, scale them up and down depending on how many tasks we have for each queue. However, as you can guess, most of the time the high priority and low priority processes will not do anything. Yet, we can not turn them off because of the possibility of incoming task. Hence, it makes more sense to have one process that can execute the tasks from different queues but based on the priority that is provided.
Of course, not to mention that scaling up/down will be a lot easier as it only depends on the total number of unprocessed tasks (instead of the per queue number).

I like your idea of the quota-based scheduler, so I will implement scheduler functionality. It will be included in the next major release. I have plans to release it at the end of October. Thank you for contribution.

Thanks @f0y. I am not sure if you want to plug it into execution pool somehow or you have a better idea but I would like to contribute if you tell me what you have in mind. I don't wanna make something that is unacceptable to you.
If you still want to implement it yourself, at least I need to thank you guys for the great work on the library.

@f0y thank you for considering this. @everplays reasoning is correct and it could lead to a service only processing high prio messages and the number of low prio messages not being processed will only grow. So implementing a quota based scheduler makes sense.

@f0y as you've been busy, I can happily implement this feature if we discuss the implementation before hand (I really don't wanna spend my time on something that's not gonna be merged).
So far, we have managed the priorities as such:

scaling the high, medium, and low queues differently via containers.
added cli arguments to start the worker process with number of necessary threads. For example: worker -q high -q high -q high -q medium -q medium -q low would start 6 threads (3 high, 2 medium, and 1 low). To achieve this, we created a QueueService instance per queue so we could change the number of threads independently from other queues.

I've tried to figure out how to do that and I have no idea. Do you have one?
The idea to change thread count is not a bad one.
Is your current solution unacceptable for some reason?

I really don't wanna spend my time on something that's not gonna be merged

You can implement POC without tests, documentation, successful build and etc.

The two solutions that we are using at the moment work fine with low number of workers. So maybe I am just trying to optimize something that doesn't need optimization. However, gonna give it a go in the weekend and see what I can come up with.

Just to inform anyone who's potentially waiting for me to implement this: for our usecase, we've concluded that we've enough flexibility with thread based and container based scaling options that having a priority based scheduler has little to no benefit for us.
However, If anyone's interested in implementing this, from what I gathered, it can be implemented with:

QueueLoop
LoopPolicy

when the "core" functionality is ready, modifying QueueExecutionPool and QueueService would be in order to somehow allow users of the library to create a PriorityQueueLoop (or a better name if you have one).
Finally, if you want to be able to control how many threads are executed per queue, this is what we did:
public class Worker implements AutoCloseable {

	private static final Logger LOGGER = LoggerFactory.getLogger(Worker.class);

	private boolean started = false;

	private JobQueueProducer jobQueueProducer;
	private QueueCoreElements queueCoreElements;
	private Map<String, Long> queuesToRun;

	private Map<String, QueueService> queueToService = new HashMap<>();

	@Inject
	public Worker(
		QueueCoreElements queueCoreElements,
		JobQueueProducer jobQueueProducer
	) {
		this.queueCoreElements = queueCoreElements;
		this.jobQueueProducer = jobQueueProducer;
	}

	public void start(List<String> suggestedQueuesToRun) {
		this.setQueuesToRun(suggestedQueuesToRun);
		this.queuesToRun.forEach((queue, numberOfThreads) -> this.getQueueService(queue).start());
		this.started = true;
	}

	public void shutdown() {
		if (this.started) {
			this.queuesToRun.forEach((queue, numberOfThreads) -> this.getQueueService(queue).shutdown());
		}
	}

	@Override
	public void close() throws Exception {
		this.shutdown();
	}

	private QueueService getQueueService(String queue) {
		if (this.queueToService.containsKey(queue)) {
			return this.queueToService.get(queue);
		}

		QueueService queueService = new QueueService(
			List.of(this.getQueueShard(queue)),
			new ThreadListener(),
			new TaskListener()
		);
		this.registerQueueToService(queue, queueService);
		this.queueToService.put(queue, queueService);

		return queueService;
	}

	private void setQueuesToRun(List<String> suggestedQueuesToRun) {
		if (this.queuesToRun != null) {
			return;
		}
		if (suggestedQueuesToRun.size() == 0) {
			suggestedQueuesToRun = List.of("high", "medium");
		}
		this.queuesToRun = suggestedQueuesToRun.stream().collect(Collectors.groupingBy(e -> e, Collectors.counting()));
	}

	private QueueShard getQueueShard(String queue) {
		QueueShard queueShardTemplate = this.queueCoreElements.getQueueShard();
		return new QueueShard(
			queueShardTemplate.getDatabaseDialect(),
			queueShardTemplate.getQueueTableSchema(),
			new QueueShardId(queue),
			queueShardTemplate.getJdbcTemplate(),
			queueShardTemplate.getTransactionTemplate()
		);
	}

	private void registerQueueToService(String queue, QueueService queueService) {
		QueueConsumer<JsonNode> queueConsumer = new RunnableQueueConsumer(
			new QueueConfig(
				this.queueCoreElements.getQueueLocationBuilder().withQueueId(new QueueId(queue)).build(),
				this.queueCoreElements.getQueueSettingsBuilder().withThreadCount(this.queuesToRun.get(queue).intValue()).build()
			),
			jobQueueProducer
		);
		queueService.registerQueue(queueConsumer);
	}

}

Then, if the suggestedQueuesToRun parameter is set to "high", "high", "high", "medium", "medium", "low", you'll have six threads: 3 high, 2 medium, 1 low.


upgrade to tokio 1.0

This requires other dependencies to upgrade first:

[x] hyper v0.14 https://github.com/hyperium/hyper/issues/2302
[x] hyper v0.14 https://github.com/hyperium/hyper/milestone/6
[x] reqwest ? https://github.com/seanmonstar/reqwest/issues/1060

reqwest just released with support for tokio 1.0 https://github.com/seanmonstar/reqwest/releases/tag/v0.11.0

reqwest just released with support for tokio 1.0 https://github.com/seanmonstar/reqwest/releases/tag/v0.11.0

It builds on top of top of hyper 0.14 which came out a couple of weeks ago. https://github.com/hyperium/hyper/releases

It builds on top of top of hyper 0.14 which came out a couple of weeks ago. https://github.com/hyperium/hyper/releases

This is fixed in the SDK crates and needs to only be updated in the services crates now.

This is fixed in the SDK crates and needs to only be updated in the services crates now.

Seems I cannot use storage controlplane(mgmt) SDK(tokio 0.2)  dataplane(tokio 1.0) in same function now:
When runtime is 1.0:
panicked at 'not currently running on the Tokio runtime.', \.cargo\registry\src\github.com-1ecc6299db9ec823\tokio-1.0.1\src\runtime\blocking\pool.rs:84:33

When runtime is 0.2, it will complain from 0.2 code.

Seems I cannot use storage controlplane(mgmt) SDK(tokio 0.2)  dataplane(tokio 1.0) in same function now:
When runtime is 1.0:
panicked at 'not currently running on the Tokio runtime.', \.cargo\registry\src\github.com-1ecc6299db9ec823\tokio-1.0.1\src\runtime\blocking\pool.rs:84:33

When runtime is 0.2, it will complain from 0.2 code.

@karataliu, apologies. Working on the upgrade.

@karataliu, apologies. Working on the upgrade.

I'm just waiting on #143 to be merged first. The fix in just updating these dependencies:

I'm just waiting on #143 to be merged first. The fix in just updating these dependencies:


syntax enhancement for pg core

You need to escape following characters in md files
{ } Curly braces.       as    \{ \}
[ ] Square brackets. as    \[ \]
( ) Parentheses         as    \( \)
and
>          as  \>


sched/tls: Shouldn't get tls info directly from sp in kernel space

Summary
since the stack may switch to the kernel or interrupt stack. Report here: https://github.com/apache/incubator-nuttx/pull/6337.
Impact
find to get the tls info in case of CONFIG_TLS_ALIGNED = y
Testing
rv-virt:knsh64

@xiaoxiang781216
I tried this PR with rv-virt:knsh64, but it failed.
The issue also happened with sabre-6quad:knsh.
$ qemu-system-riscv64 -semihosting -nographic -cpu rv64 -smp 8 -M virt -bios none -kernel ./nuttx
ABC[    0.000000] up_assert: Assertion failed at file:init/nx_bringup.c line: 297 task: Idle Task
[    0.000000] up_assert: Assertion failed at file:common/riscv_swint.c line: 189 task: Idle Task
[    0.000000] riscv_registerdump: EPC:<PHONE_NUMBER>007202
[    0.000000] riscv_registerdump: A0:<PHONE_NUMBER>000000 A1:<PHONE_NUMBER>000000 A2:<PHONE_NUMBER>000000 A3:<PHONE_NUMBER>000001
[    0.000000] riscv_registerdump: A4:<PHONE_NUMBER>000001 A5:<PHONE_NUMBER>000000 A6:<PHONE_NUMBER>000074 A7:<PHONE_NUMBER>00006a
[    0.000000] riscv_registerdump: T0:<PHONE_NUMBER>0001ff T1:<PHONE_NUMBER>00006c T2:<PHONE_NUMBER>00002d T3:<PHONE_NUMBER>000068
[    0.000000] riscv_registerdump: T4:<PHONE_NUMBER>000009 T5:<PHONE_NUMBER>00002a T6:<PHONE_NUMBER>00002e
[    0.000000] riscv_registerdump: S0:<PHONE_NUMBER>200928 S1:<PHONE_NUMBER>206b30 S2:<PHONE_NUMBER>200928 S3:<PHONE_NUMBER>200918
[    0.000000] riscv_registerdump: S4:<PHONE_NUMBER>201050 S5:<PHONE_NUMBER>000000 S6:<PHONE_NUMBER>000000 S7:<PHONE_NUMBER>000000
[    0.000000] riscv_registerdump: S8:<PHONE_NUMBER>000000 S9:<PHONE_NUMBER>000000 S10:<PHONE_NUMBER>000000 S11:<PHONE_NUMBER>000000
[    0.000000] riscv_registerdump: SP:<PHONE_NUMBER>206b20 FP:<PHONE_NUMBER>200928 TP:<PHONE_NUMBER>000000 RA:<PHONE_NUMBER>007202
[    0.000000] riscv_dumpstate: sp:<PHONE_NUMBER>200850
[    0.000000] riscv_dumpstate: IRQ stack:
[    0.000000] riscv_dumpstate:   base:<PHONE_NUMBER>2000f0
[    0.000000] riscv_dumpstate:   size:<PHONE_NUMBER>000800
[    0.000000] riscv_stackdump:<PHONE_NUMBER>200840: 802000f0 00000000 80006ce0 00000000 000000bd 00000000 80015160 00000000
[    0.000000] riscv_stackdump:<PHONE_NUMBER>200860: deadbeef deadbeef 00000000 00000000 80201050 00000000 80200918 00000000
[    0.000000] riscv_stackdump:<PHONE_NUMBER>200880: 80201050 00000000 80206a18 00000000 80206a18 00000000 800043ac 00000000
[    0.000000] riscv_stackdump:<PHONE_NUMBER>2008a0: deadbeef deadbeef 800015f6 00000000 80200928 00000000 80201050 00000000
[    0.000000] riscv_stackdump:<PHONE_NUMBER>2008c0: 80206a18 00000000 80001812 00000000 deadbeef deadbeef 00000100 00000000
[    0.000000] riscv_dumpstate: sp:<PHONE_NUMBER>206b20
[    0.000000] riscv_dumpstate: User stack:
[    0.000000] riscv_dumpstate:   base:<PHONE_NUMBER>206030
[    0.000000] riscv_dumpstate:   size:<PHONE_NUMBER>000bd0
[    0.000000] riscv_dumpstate: User Stack
[    0.000000] riscv_stackdump:<PHONE_NUMBER>206b20: 00000000 00000000 80006e74 00000000 00000129 00000000 800152a8 00000000
[    0.000000] riscv_stackdump:<PHONE_NUMBER>206b40: 00000000 00000000 00000000 00000000 00000000 00000000 80200918 00000000
[    0.000000] riscv_stackdump:<PHONE_NUMBER>206b60: 80201064 00000000 80201068 00000000 80200928 00000000 800043ac 00000000
[    0.000000] riscv_stackdump:<PHONE_NUMBER>206b80: 80200928 00000000 80001b48 00000000 80200928 00000000 80016400 00000000
[    0.000000] riscv_stackdump:<PHONE_NUMBER>206ba0: 80200928 00000000 80001a94 00000000 80400000 00000000 00400000 00000000
[    0.000000] riscv_stackdump:<PHONE_NUMBER>206bc0: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
[    0.000000] riscv_stackdump:<PHONE_NUMBER>206be0: 00000000 00000000 80000d72 00000000 00000000 00000000 80000046 00000000
[    0.000000] riscv_showtasks:    PID    PRI      USED     STACK   FILLED    COMMAND
[    0.000000] riscv_showtasks:   ----   ----       744      2048    36.3%    irq
[    0.000000] riscv_dump_task:      0      0      1328      3024    43.9%    Idle Task

If I enable debug messages, it seems that the symbol tls_get_info was not found.
[    0.000000] elf_symvalue: SHN_UNDEF: Exported symbol "tls_get_info" not found
[    0.000000] elf_relocateadd: Section 2 reloc 4815: Failed to get value of symbol[38794]: -2
[    0.000000] elf_loadbinary: Failed to bind symbols program binary: -2
[    0.000000] exec_spawn: ERROR: Failed to load program '/system/bin/init': -2
[    0.000000] up_assert: Assertion failed at file:init/nx_bringup.c line: 297 task: Idle Task
[    0.000000] up_assert: Assertion failed at file:common/riscv_swint.c line: 189 task: Idle Task

Sorry, @masayuki2009 I just rebuild the kernel not hello elf, so the error isn't catch locally.

@xiaoxiang781216
I confirmed that this PR fixes the issue.


Enable more BERT models

I changed some things that were hard coded before that can be retrieved from config.json to enable more models with the BertForMaskedLM architecture. I tested it with some other models, e.g.

python convert.py --bert-model "unitary/toxic-bert" --mlx-model weights/toxic-bert.npz
python test.py --bert-model "unitary/toxic-bert" --mlx-model "weights/toxic-bert.npz" --text "Hello World!"

Tests pass :)

It should in theory also work with RoBERTa models, but I haven't quite gotten it to run yet.

Really nice! When you say RoBERTA is not working is it giving bad output or just crashing?

Bad output.

Upon reviewing the BERT and RoBERTa architectures it seems like we do need to tweak the model file a bit.
BERT

RoBERTa


I think this is a bug help me!!

Checklist

[ ] I'm reporting a broken site support issue
[ ] I've verified that I'm running youtube-dl version 2021.12.17
[ ] I've checked that all provided URLs are alive and playable in a browser
[ ] I've checked that all URLs and arguments with special characters are properly quoted or escaped
[ ] I've searched the bugtracker for similar bug reports including closed ones
[ ] I've read bugs section in FAQ

Verbose log

PASTE VERBOSE LOG HERE

ERROR: Unable to extract uploader id; please report this issue on https://yt-dl.org/bug . Make sure you are using the latest version; see  https://yt-dl.org/update  on how to update. Be sure to call youtube-dl with the --verbose flag and include its complete output.2023-06-16 13:14:15 ERROR    discord.client Ignoring exception in on_message
Traceback (most recent call last):
File "C:\Program Files\Python38\lib\site-packages\youtube_dl\YoutubeDL.py", line 815, in wrapper
return func(self, *args, **kwargs)
File "C:\Program Files\Python38\lib\site-packages\youtube_dl\YoutubeDL.py", line 836, in __extract_info
ie_result = ie.extract(url)
File "C:\Program Files\Python38\lib\site-packages\youtube_dl\extractor\common.py", line 534, in extract
ie_result = self._real_extract(url)
File "C:\Program Files\Python38\lib\site-packages\youtube_dl\extractor\youtube.py", line 1794, in _real_extract
'uploader_id': self._search_regex(r'/(?:channel|user)/([^/?&#]+)', owner_profile_url, 'uploader id') if owner_profile_url else None,
File "C:\Program Files\Python38\lib\site-packages\youtube_dl\extractor\common.py", line 1012, in _search_regex
raise RegexNotFoundError('Unable to extract %s' % _name)
youtube_dl.utils.RegexNotFoundError: Unable to extract uploader id; please report this issue on https://yt-dl.org/bug . Make sure you are using the latest version; see  https://yt-dl.org/update  on how to update. Be sure to call youtube-dl with the --verbose flag and include its complete output.
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "C:\Users\H1405\AppData\Roaming\Python\Python38\site-packages\discord\client.py", line 441, in _run_event
await coro(*args, **kwargs)
File "c:/Users/H1405/Desktop/안아줘요 PJ/안아줘요3.py", line 29, in on_message
info = ydl.extract_info(f"ytsearch:{music_name}", download=False)
File "C:\Program Files\Python38\lib\site-packages\youtube_dl\YoutubeDL.py", line 808, in extract_info
return self.__extract_info(url, ie, download, extra_info, process)
File "C:\Program Files\Python38\lib\site-packages\youtube_dl\YoutubeDL.py", line 815, in wrapper
return func(self, *args, **kwargs)
File "C:\Program Files\Python38\lib\site-packages\youtube_dl\YoutubeDL.py", line 847, in __extract_info
return self.process_ie_result(ie_result, download, extra_info)
File "C:\Program Files\Python38\lib\site-packages\youtube_dl\YoutubeDL.py", line 933, in process_ie_result
return self.__process_playlist(ie_result, download)
File "C:\Program Files\Python38\lib\site-packages\youtube_dl\YoutubeDL.py", line 1067, in __process_playlist
entry_result = self.__process_iterable_entry(entry, download, extra)
File "C:\Program Files\Python38\lib\site-packages\youtube_dl\YoutubeDL.py", line 815, in wrapper
return func(self, *args, **kwargs)
File "C:\Program Files\Python38\lib\site-packages\youtube_dl\YoutubeDL.py", line 1076, in __process_iterable_entry
return self.process_ie_result(
File "C:\Program Files\Python38\lib\site-packages\youtube_dl\YoutubeDL.py", line 885, in process_ie_result
return self.extract_info(ie_result['url'],
File "C:\Program Files\Python38\lib\site-packages\youtube_dl\YoutubeDL.py", line 808, in extract_info
return self.__extract_info(url, ie, download, extra_info, process)
File "C:\Program Files\Python38\lib\site-packages\youtube_dl\YoutubeDL.py", line 824, in wrapper
self.report_error(compat_str(e), e.format_traceback())
File "C:\Program Files\Python38\lib\site-packages\youtube_dl\YoutubeDL.py", line 628, in report_error
self.trouble(error_message, tb)
File "C:\Program Files\Python38\lib\site-packages\youtube_dl\YoutubeDL.py", line 598, in trouble
raise DownloadError(message, exc_info)
youtube_dl.utils.DownloadError: ERROR: Unable to extract uploader id; please report this issue on https://yt-dl.org/bug . Make sure you are using the latest version; see  https://yt-dl.org/update  on how to update. Be sure to call youtube-dl with the --verbose flag
and include its complete output.
Description

WRITE DESCRIPTION HERE

Help yourself by reading and following #30839 and by completing the checklist before (if necessary) creating a new issue.


new game added path finder puzzle

PR Description 📜
Please include summary related to the issue you have fixed and describe your PR in brief over here by specifying the issue number on which you were working below
Fixes #124
I have added a new game called "Path Finder Puzzle" to the GameZone website. This game challenges players to find the shortest path from the start to the goal on a grid. Players can navigate through the grid while avoiding obstacles, making strategic decisions to reach the end point efficiently.

Mark the task you have completed ✅

[x] I follow CONTRIBUTING GUIDELINE & CODE OF CONDUCT of this project.
[x] I have performed a self-review of my own code or work.
[x] I have commented my code, particularly in hard-to-understand areas.
[x] My changes generates no new warnings.
[x] I have followed proper naming convention showed in CONTRIBUTING GUIDELINE
[x] I have added screenshot for website preview in assets/images
[x] I have added entries for my game in main README.md
[x] I have added README.md in my folder
[ ] I have added working video of the game in README.md (optional)
[x] I have specified the respective issue number for which I have requested the new game.

Add your screenshots(Optional) 📸

Thank you so much for contributing to our repository 💗

Thank you @Harleen-786 ,for creating the PR and contributing to our GameZone 💗
Review team will review the PR and will reach out to you soon! 😇
Make sure that you have marked all the tasks that you are done with ✅.
Thank you for your patience! 😀

Hey @Harleen-786,
You can't work on a closed issue 👀!
Follow the proper guideline and make a new PR again 😀.
Happy Hacking 💗

Thank you  @Harleen-786 , for your valuable time and contribution in our GameZone 💗.
It’s our GameZone, so Let’s build this GameZone altogether !!🤝
Hoping to see you soon with another PR again 😇
Wishing you all the best for your journey into Open Source🚀


Disable note sound checkbox in EditorRuntimeSettings.asset lead to stop the game from launching

If you check the box "disable not sound" in EditorRuntimeSettings.asset, the game will not load to the song selection menu. It'll stay stuck on the second screenshot screen.

Issue on user-side: my hard disk was lagging like hell and probably lead to the issue.


p5 Website Env.setADSR() issue

From @Siggi005 on January 3, 2018 19:11

Nature of issue?

[x] Found a bug
[x] Existing feature enhancement

Most appropriate sub-area of p5.js?

[x] Website of p5

Which platform were you using when you encountered this?

[x] Desktop/Laptop

Details about the bug:
css styles on the website https://p5js.org/reference/#/p5.Env/set cause troubles: The example and the description are overlapping.

.example-content .edit_space,
.example-content pre {
    position: absolute !important;
    top: 0.5em !important;
    left: 120px !important;
    padding-top: 0 !important;
    border: none !important;
}

Feature enhancement details:
Delete position: absolute !important;
Copied from original issue: processing/p5.js#2489

I believe I have resolved this issue by updating the code in the p5.js repo (pull request: processing/p5.js#2660 ).

thanks!


Timestamp paramater is not used

You added a parameter -s but it is not used in your code

I'm working on it and proxy support, and I will submit a Pull Request in a few days


Add returntype enum to squirrel native functions

This PR should only be merged by @BobTheBob9
It adds a return type enum to the registration of native functions in squirrel. This is required for to return types like asset without needing to expect cast the return value first.
It will set the enum value depinding on the string return type and will keep the 32 value set before when the enum type is unknown

Manually running strcmp on every single possiblity gang ✊

Consider using a map instead of manually using strcmp on every combination.
Example:
int getReturnTypeEnumFromString(const char* name) {
	using SQReturnTypeEnum;

	static std::map<std::string, SQReturnTypeEnum> sqEnumStrMap = {
		{"bool",	SqBoolean },
		{"float",	SqFloat },
		{"vector",	SqVector },
		{"int",		SqInteger },
		{"entity",	SqEntity },
		{"string",	SqString },
		{"array",	SqArrays },
		{"asset",	SqAsset },
		{"table",	SqTable }
	};

	if (sqEnumStrMap.count(name)) {
		return sqEnumStrMap[name];
	} else {
		return SqStringOrNull;
	}
}

Also, Northstar doesn't seem to use camelCase for function names... Let me guess, Java programmer? Doesn't matter a ton tho, I just hate Java lol
Also remember to run clang-format before making PRs so you can get that epic 2/2 checks passed victory royale!11! Easy commands for this at the end of: https://github.com/R2Northstar/NorthstarLauncher/blob/main/README.md

Im using the full enum name because otherwise the names are very similar to other names. I should rename them.
Also this pr fails clang because the refactor branch fails in general its not my code thats doing it.


Does this train from scratch or uses pre-trained weights?

I saw the weights flag in the code to specify pre-trained weights, but I don't see that argument being utilized anywhere in the training code. So is it currently training from scratch always?

Hi @Y-T-G ,
It will NOT train from scrach.
weights flag is for giving pre-trained weight. by default its coco,
So it will train on coco weight
checkout https://github.com/naseemap47/YOLO-NAS/blob/master/train.py#L129
I think this will help you to understand.
If you  have any questions, please let me know.

@naseemap47 I see. What do I do if I want to train from scratch?

Hi @Y-T-G ,
I didn't find any option for that.
Checkout super-gradients repo: https://github.com/Deci-AI/super-gradients
If you find any, please let me know.

@naseemap47 I think for that you just don't pass an argument to the pretrained_weights as it says in the comment here .

Hi @Y-T-G ,
Thank you for sharing. I will look into it, and I will update this ASAP.
Thank you.

Hi @Y-T-G ,
I think pretrained_weights="cityscapes"  option is removed for detection.
When I tried its showing unable to get cityscapes model.
Did you face any issue ?

@naseemap47 Not sure about that. What I meant was you can remove that argument altogether from the function call, i.e. just don't pass pretrained_weights and it should train from scratch. You can verify that from the starting mAP which will be close to 0 because it's training from scratch.

https://github.com/Y-T-G/YOLO-NAS/commit/ed597f270994471fe5aec12fd5a38809d1f35e13
This should work too. To train from scratch simply use --weights="".

Hi @Y-T-G ,
Thank you for finding this.
I will let you know after checking this.


fix(server): improve logging for deleted file

Description

Motivation and Context

How Has This Been Tested?

Changelog Entry

Types of Changes

[ ] Bug fix (non-breaking change which fixes an issue)
[ ] New feature (non-breaking change which adds functionality)
[ ] Breaking change (fix or feature that would cause existing functionality to change)
[ ] Documentation (no code change)
[ ] Refactor (refactoring production code)
[ ] Other

Checklist:

[ ] My code follows the code style of this project.
[ ] I have updated the documentation accordingly.
[ ] I have formatted the code with rustfmt.
[ ] I checked the lints with clippy.
[ ] I have added tests to cover my changes.
[ ] All new and existing tests passed.

Codecov Report
All modified and coverable lines are covered by tests :white_check_mark:

Comparison is base (8de2450) 70.11% compared to head (40559f7) 70.11%.

:exclamation: Your organization needs to install the Codecov GitHub app to enable full functionality.
Additional details and impacted files
@@           Coverage Diff           @@
##           master     #235   +/-   ##
=======================================
  Coverage   70.11%   70.11%
=======================================
  Files          11       11
  Lines         609      609
=======================================
  Hits          427      427
  Misses        182      182

Flag
Coverage Δ

unit-tests
70.11% <100.00%> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.


setOpacity doesn't affect some layer visually

Describe the bug
I have a couple layers displayed on my map, most react well to setOpacity and I have a reluctant one that doesn't change its transparency when setOpacity is applied
To Reproduce
https://s.geo.admin.ch/820917c58e and try to change opacity on both visible layers, the one with buildings and dwellings doesn't work when the other does (same code and same layer type ol/layer/Tile)
That's something new with OL6 betas as it's working fine on 5.3 (see https://s.geo.admin.ch/82092c7fd6)
I don't really know where to look for clues, we are using setOpacity() to set this property in our code.
layer creation here https://github.com/geoadmin/mf-geoadmin3/blob/845b8d131b909fa34116504c9cfcf2387303724b/src/components/map/LayersService.js#L540-L549
opacity set here https://github.com/geoadmin/mf-geoadmin3/blob/845b8d131b909fa34116504c9cfcf2387303724b/src/components/map/DefinePropertiesForLayerService.js#L50-L57
Expected behavior
Same behaviour when changing opacity.

Good thing opening issue is that people start to get interested, I had a talk with some colleagues and I'm not 100% sure we are not the one to blame here.
It seems to be related to one way we build layer called aggregate. It's a WMTS layer to a certain zoom level and then it switches to a WMS for latest up to date data.
I'll look into our code if we aren't by any chance using some kind of direct mutator (layer.opacity = ... instead of layer.setOpacity(...)) or other issues for this specific use case (there might me some ol/layer/Group involved)

yes, the opacity if broken with the Layer Groups, patch to come


Issue #24173 Custom checkboxes radios correct color

Hi I took a look at this issue and I made the suggested changes to:
Custom Checkboxes/Radios Do Not Display Correct Color on :focus For Validation
Is this what you meant? Is there something else that needs to be done for this issue?
I welcome and look forward to your feedback.
Fixes #24173

Pulled this down, made a few more commits to address some opacities, and also fixed the file input focus state.

Thank you @mdo. I learned a few things from this one.

Note for custom-file inputs, the focus styling will not work in Firefox, due to how Firefox treats what is "focused" in the native file input.  Firefox focuses the button inside the file input and not the file input as a whole, so the sibling selector will not work in the Firefox case.
See https://stackoverflow.com/a/20104275 and http://jsfiddle.net/Yh8re/2/ (use Firefox to test) and http://jsfiddle.net/Yh8re/23/
Firefox treats the file button and the filename label as two nested elements.  Clicking the filename will cause a focus sibling selector to work, but clicking the browse button will not.


Issues in installing Bootstrap 4 to project

I have been following wiki [https://github.com/AngularClass/angular2-webpack-starter/wiki/How-to-use-Bootstrap-4-and-Sass-(and-jQuery) to install bootstrap 4 to project but getting this error:
 ERROR in ./~/bootstrap-loader/lib/bootstrap.loader.js!./~/bootstrap-loader/no-op.js
 Module build failed: Error: Could not resolve module 'bootstrap-sass' which must be installed when
 bootstrap version is   configured to v3.
 You must install 'bootstrap' for bootstrap v4 or 'bootstrap-sass' for bootstrap v3.
 You can also specify the location manually by specifying 'bootstrapPath' in bootstrap-loader's query
 string.
 See https://github.com/shakacode/bootstrap-loader/blob/master/README.md#usage.
 at Object.module.exports.pitch (C:\Users\SYED KAMRAN HUSSAIN\Documents\GitHub\angular2-crud-app\node_modules\bootstrap-loader\lib\bootstrap.loader.js:147:11)
  @ ./~/bootstrap-loader/loader.js 2:17-61
  @ multi (webpack)-dev-server/client?http://localhost:3000 bootstrap-loader

   ERROR in ./src/styles/styles.scss
   Module build failed:
    /* this file will be extracted to main dist folder and is imported in index.html */
    ^
   Invalid CSS after "...load the styles": expected 1 selector or at-rule, was "var content = requi"
   in C:\Users\SYED KAMRAN HUSSAIN\Documents\GitHub\angular2-crud-app\src\styles\styles.scss (line 1, column 1)
   @ ./src/app/app.module.ts 21:0-31
   @ ./src/app/index.ts
   @ ./src/main.browser.ts
   @ multi (webpack)-dev-server/client?http://localhost:3000 ./src/main.browser.ts

    ERROR in ./~/css-loader!./~/raw-loader!./src/app/app.component.css
     Module build failed: Unknown word (1:1)

      > 1 | module.exports = "html, body{\r\n  height: 100%;\r\n  font-family: Arial, Helvetica, sans-serif\r\n}\r\n\r\na.active {\r\n  background-color: gray;\r\n}\r\n"
       | ^

       @ ./src/app/app.component.css 2:21-131
       @ ./src/app/app.component.ts
       @ ./src/app/app.module.ts
       @ ./src/app/index.ts
       @ ./src/main.browser.ts
       @ multi (webpack)-dev-server/client?http://localhost:3000 ./src/main.browser.ts

       ERROR in ./~/css-loader!./~/raw-loader!./src/app/home/home.component.css
       Module build failed: Unknown word (1:1)

      > 1 | module.exports = "/*styles for home content only*/"
      | ^

      @ ./src/app/home/home.component.css 2:21-138
      @ ./src/app/home/home.component.ts
      @ ./src/app/home/index.ts
      @ ./src/app/app.module.ts
      @ ./src/app/index.ts
      @ ./src/main.browser.ts
      @ multi (webpack)-dev-server/client?http://localhost:3000 ./src/main.browser.ts

Please help me what is wrong here? I am newbie to angular2 and trying to create a simple dashboard and a CRUD application. Your help and suggestions will be highly appreciated.
Thank you.

@aishabadar If you're still having issues with Bootstrap 4 installation please let me know I can help you

Yes, I am still having issues. I tried all possible things but its giving error on css loader. I committed css loader and tried without it but the scss or css file I imported in app.module.ts is not showing the stylings on specific page. If you need more information, please let me know. Thank you.

@aishabadar what do you mean by

not showing the stylings on specific page

The resource https://github.com/AngularClass/angular-starter/wiki/How-to-use-Bootstrap-4-and-Sass-(and-jQuery) was not working for me neither, so I tried my way and it worked, but instead of jQuery I used ng-bootstrap for a better integration with Angular 2/4

Ok I got it. I am also thinking to go for it. I tried bootstrap integration with angular/cli and its working great. I should go with ng-bootstrap. I will give it a try and get back to you if I face any issues. Thank you for the response.

Here is the only SCSS related line in my webpack.common.js:
/*
 * to string and sass loader support for *.scss files (from Angular components)
 * Returns compiled css content as string
 *
 */
{
  test: /\.scss$/,
  use: ['to-string-loader', 'css-loader', 'sass-loader'],
  exclude: [helpers.root('src', 'styles')]
},

and then I placed my Bootstrap 4 scss lib in a src/bootstrap folder, and I include it on app.module.ts like this:
import '../styles/bootstrap/bootstrap.scss' // Bootstrap entry point
import '../styles/styles.scss' // Custom styles

ng-bootstrap don't handle the style part, only the jQuery based operations

You can take a look on my repo (https://github.com/SherlockStd/ME4N-Starter/tree/master/src) for more details (the src folder is based on this repo), and for ng-bootstrap see my bootstrap demo component

Let me know if you have any more problem

Thanks for such detailed response. It will definitely help. I am going to try it soon and get back to you. Thanks again.


Regression LAMMPS test in dev fail

On ubuntu it cannot find the executable name "lammps" as it is looking for "lmp". So no test starts

Can you provide more of a description? Which pull request are you having trouble with?

@JensWehner I think the reason the tests were failing is because the pull request in csg-tutorials was never merged.
https://github.com/votca/csg-tutorials/pull/49
well at least it passes on travis.

Good point I still want to check if why the realtime example gave such strange results.

for https://github.com/votca/votca/pull/175

I reactived the lammps test in https://github.com/votca/csg-tutorials/commit/80bc6581471a744b85a5ae108e9585386a01398b and fixed the units in https://github.com/votca/csg-tutorials/commit/d861b41da7044b63823605353580b9622b78f0cf, but the re_lammps still have unclear units to me.

csg_reupdate reads kBT in https://github.com/votca/csg/blob/master/src/tools/csg_reupdate.cc#L180, so energy scale should be right and length scale is already.
@symashayak do I miss anything here?

okay it works

@JensWehner @JoshuaSBrown was the realtime example now working?

Thanks!


Az image copy doesn't copy data disks

Extension name (the extension in question)
Az image copy
Description of issue (in as much detail as possible)
Az image copy doesn't copy data disks,  gives a warning that it's not doing it.  It would be nice if it did.

image copy

@yonzhan @qwordy - is this issue being tracked and any further updates on when we can have a fix for this....

@qwordy please help with this.

It is a known issue. Currently I don't have a concrete plan. You could try shared image gallery before this feature is supported.
https://docs.microsoft.com/en-us/azure/virtual-machines/windows/shared-image-galleries

@qwordy - I tried with SIG and it works pretty much fine even with image having data disks. But, was looking for an update on the az image copy as well

Same behavior here .

@DaveB93 @Xat59 Apologies for the late reply. We are looking into this issue. We will update this thread once we have an update.
@zhoxing-ms @qwordy Could you please provide an update on this issue once you get a chance ? Awaiting your reply.

I was a former member of this repository. It is technically feasible.

@navba-MSFT At present, we have a more powerful feature Azure Compute Gallery to support similar needs, and it is also a project that the service team @kangsun-ctrl is actively promoting.
Since az image copy needs much effort to support data disks and there are alternative products for it, so I put it in the backlog first. When more users feed back this demand, we will raise its priority

@DaveB93 Please look at the above comments from @zhoxing-ms. Could you please try to leverage the Azure Compute Gallery and check if that serves your requirement ? Awaiting your reply.

@DaveB93 Thanks for getting back. @zhoxing-ms has mentioned in the above comment that this ask is in the backlog.

Since az image copy needs much effort to support data disks and there are alternative products for it, so I put it in the backlog first. When more users feed back this demand, we will raise its priority

Also the feature request label has been added to this thread.
Adding @zhoxing-ms for visibility.


Close service when prepared query can't be parsed

This fixes an issue wherein the service isn't closed when the parse
phase of a prepared statement fails.  This causes that connection to
hang.  Instead, the parse failure should cause the service to be closed
(just as the successful completion of the query closes the service, and
the failure at any other point during the process does the same).

Coverage remained the same at 16.348% when pulling 1d45eda49ae1ab57dd2d95122bce87c5e6af52b6 on jeremyrsmith:fix-parse-error-issue into ca5eb03845dbe2d20c9062a860704864e7aab465 on finagle:master.

Coverage remained the same at 16.058% when pulling b4932daf04bcbcae8a19862720ee3d79308e3a4a on jeremyrsmith:fix-parse-error-issue into ca5eb03845dbe2d20c9062a860704864e7aab465 on finagle:master.


New datastore

Assignment 2

@EulPi Please sign the Contributor License Agreement!
Click here to manually synchronize the status of this Pull Request.
See the FAQ for frequently asked questions.


The useNavbarContext hook does not work as expected

Describe the bug
Using the useNavbarContext hook does not work even in child components.
To Reproduce
Render a Navbar and try to use the useNavbarContext hook in a child component to get and set the state.
Expected behavior
Setting the state works as expected.
Screenshots
Since the provider is in the Navbar itself, child components should be able to use it but this is thrown instead:

System information:
N / A
Project information:

Tailwind: 3.2.7
Flowbite: 1.6.4
Flowbite React: 0.4.2
Type: NextJS 13 App

Additional context
Add any other context about the problem here.

Note: I also tried using state to set the value but it also does not work:
export function Navigation() {
  const [open, setOpen] = useState(false);

  return (
    <Navbar fluid menuOpen={open}>
      <Navbar.Brand href="/">
        <Image src="/logo.svg" alt="Logo" priority width={64} height={64} />
      </Navbar.Brand>
      <div className="flex md:order-2 gap-2">
        <Link
          href="/"
          className="bg-black text-white px-4 py-2 rounded-xl"
        >
          Link text
        </Link>
        <NavbarToggle open={open} onToggle={() => setOpen((open) => !open)} />
      </div>
      <Navbar.Collapse>
        <NavbarLinks onLinkClick={() => setOpen(() => false)} />
      </Navbar.Collapse>
    </Navbar>
  );
}

Also note that NavbarToggle just wraps Navbar.Toggle and likewise NavbarLinks just wraps a list of Navbar.Link elements. When state is set, the nabber component does not react at all and just stays collapsed when toggled since the toggle does not accept an on click handler being passed in and thus never changes the state when one is provided...

You say that you are trying to use useNavbarContext explicitly to change things, but I don't see that in your code snippet. Are you just encountering this error by accident, or are you actually trying to call that context?
You aren't supposed to do that, which is the reason it's not documented anywhere that you can, and also the reason why I added the error message.
I guess I'm just confused. You are correctly stating that Navbar.Toggle doesn't accept an event handler, but attempt to use it as if it does anyway, and are not understanding why that isn't working? It feels like I'm missing something here.

The hook is used in the NavbarToggle and NavbarLinks components. Apologies if that was unclear.
I need to programmatically close or open the navbar, this is exactly what such contexts are for in React and thus I aimed to use it.
It's also useful because the open state is available via the context for conditional styling or analytics calls to be sent.
The prop on the Navbar component itself to mark the nav as open doesn't work when the Boolean is toggled either. Plus, even if it did, manually reimplementing the logic the context already provides is underwhelming to say the least.
I expect any prop provided works and the context actually reacts otherwise neither should be in the public API.
Is that clearer? ☺

Thank you for reporting this issue. However, we regret to inform you that we won't be able to address it for the following reasons:

The reported issue refers to an unsupported old version of our project.
Our team was unable to reproduce the problem with the information provided.
Insufficient information was provided to conduct a thorough investigation.

We recommend upgrading to the latest version and submitting a new issue if the problem persists. Thank you for your understanding.

@jamesrweb were you able to solve this issue?

I gave up on it and implemented a different UI library in the end due to this issue and some other issues with typography, etc.

@rluders there is a Navbar, perhaps it helps, we are talking about next.js, the most important framework of react, the official recommended framework, in which the Link from next/link is the most important navigation feature, it prefetches pages etc.
Now... I can't close the navbar if I use as={Link} where Link is from next/link.

Privacy Policy
if I try to use the navbarcontext to do something like:
const { isOpen, setIsOpen } = useNavbarContext();
setIsOpen(true)>
I receive the same error reported. In which context is useNavbarContext valid or used? google gives 2 results.

@rluders in summary, there is no way to manually toggle the navbar collapse outside of Navbar.Toggle, which kind of sucks, and feels like a limitation.
there are multiple use cases where one might need to toggle the collapse (close), without direct interaction with the Navbar.Toggle    component


EGA login failure with snakemake.remote.EGA function

Not sure if this is a bug or mistake on my end, so crossposting from SE-Bioinformatics:
The remote data retrieval from EGA fails for me with snakemake. I have defined all required environment variables, but an error comes up stating
{"error":"invalid_client","error_description":"Bad client credentials"}

I guess the error is in the definition of the EGA_CLIENT_ID variable, since I can successfully log in using the login credentials represented by the EGA_USERNAME, EGA_PASSWORD, and EGA_CLIENT_SECRET variables contained in my CREDENTIALS_FILE when attempting a download by invoking the pyega3 command (both directly from the command line and from a Snakemake script).
I am using Snakemake 5.14 and Python 3.7.2. Thanks a lot in advance for your advice.
Code:
import snakemake.remote.EGA as EGA

ega = EGA.RemoteProvider()
os.environ["EGA_USERNAME"] = "XXX"
os.environ["EGA_PASSWORD"] = "XXX"
os.environ["EGA_CLIENT_SECRET"] = "XXX"
os.environ["EGA_CLIENT_ID"] = "pyega3"

rule a:
  input:
      ega.remote("ega/EGAD00001002142/COLO_829_EPleasance_TGENPipe.bam.bai")
  output:
      "data/COLO_829BL_BCGSC_IlluminaPipe.bam.bai"
  shell:
      "cp {input} {output}"

Crossposting my answer from SE-Bioinformatics - I believe this is indeed a bug.
The reason was the EGA_CLIENT_ID variable. In the pyega3.py script, there is a definition for the client_id for pyega3 v3.0.44 ("f20cd2d3-682a-4568-a53e-4262ef54c8f4"). After setting the EGA_CLIENT_ID to this value login was successful.
os.environ["EGA_CLIENT_ID"] = "f20cd2d3-682a-4568-a53e-4262ef54c8f4"

The official documentation just requires definition of the EGA_USERNAME and EGA_PASSWORD variables, and while definition of EGA_CLIENT_SECRET will probably need to be done by the user, the client ID should be pulled automatically from the pyega3 version installed locally.
Of note, after successful login, the example download from the documentation failed with the following:
Missing input files for rule a:
ega/EGAD00001002142/COLO_829_EPleasance_TGENPipe.bam.bai

However, downloading files that I have access to worked, indicating that the paths to the files from the documentation are wrong or are access-protected.
So overall I think the following require fixing:

the documentation should state the requirement to define EGA_CLIENT_SECRET
the documentation should use a different download example
the EGA_CLIENT_ID variable should not need to be defined by the user, but instead the client_id should be pulled from the version of pyega3 active in the environment
as a suggestion for improvement, it may be more elegant to have the option to just supply the path to the CREDENTIALS_FILE downloadable from EGA rather than making its contents environment variables


Fix order detail layout

fix layout on mobile (horizontal scroll and top navbar)
align delivery and shipping to  the other amounts
split grid classes from other css classes to avoid unexpected behaviour

mobile
before:

after:

desktop
before:

after:

Current coverage is 58.75% (diff: 100%)

Merging #836 into master will increase coverage by 0.01%

@@             master       #836   diff @@
==========================================
  Files           112        112
  Lines          5882       5882
  Methods           0          0
  Messages          0          0
  Branches        720        720
==========================================
+ Hits           3455       3456     +1
  Misses         2287       2287
+ Partials        140        139     -1

Powered by Codecov. Last update 99311c7...7798e8f