text:
Error in HA log regarding parity history parsing - invalid literal for int() with base 10

Describe the bug
In HA log i can see this error:
Logger: custom_components.unraid.coordinator
Zdroj: custom_components/unraid/coordinator.py:865
integrace: UNRAID (dokumentace, problémy)
První výskyt: 16:58:03 (1409 výskyty)
Naposledy logováno: 17:16:11

Error parsing parity history line '2024 Sep 9 02:23:50|18548|25.9 MB/s|0|0|check P Q|468850520|95023|2|Scheduled Non-Correcting Parity-Check': invalid literal for int() with base 10: '25.9 MB/s'
Error parsing parity history line '2024 Oct 14 02:29:20|18898|25.4 MB/s|0|0|check P Q|468850520|95354|2|Scheduled Non-Correcting Parity-Check': invalid literal for int() with base 10: '25.4 MB/s'
Error parsing parity history line '2024 Oct 28 02:31:54|19032|25.2 MB/s|0|0|check P Q|468850520|95508|2|Scheduled Non-Correcting Parity-Check': invalid literal for int() with base 10: '25.2 MB/s'
Error parsing parity history line '2024 Dec 16 02:38:22|19439|24.7 MB/s|0|0|check P Q|468850520|95895|2|Scheduled Non-Correcting Parity-Check': invalid literal for int() with base 10: '24.7 MB/s'
Error parsing parity history line '2024 Dec 22 17:54:15|18240|26.3 MB/s|0|0|check P Q|468850520|18240|1|Automatic Correcting Parity-Check': invalid literal for int() with base 10: '26.3 MB/s'
Traceback (most recent call last):
  File "/config/custom_components/unraid/coordinator.py", line 865, in _parse_parity_history
    speed_bytes = int(fields[2])
ValueError: invalid literal for int() with base 10: '68.7 MB/s'

Expected behavior
Screenshots
Unraid (please complete the following information):

Versions 6.12.13 and 6.2.14

Home Assistant (please complete the following information):

Version 2024.12.5

Home Assistant installation type (please complete the following information):

[ ] Docker / Container
[ ] Virtual Machine
[x] Raspberry Pi

Priority of Request

[ ] High
[ ] Medium
[x] Low

Additional context

Thanks for the info. Helps a lot.
Code needs some tuning 😃

I made some updates today. Feel free to download latest source code, overwrite your existing unraid integration and restart home assistant.

I just did it, replaced all files by files downloaded from Git, looks like things are moving forward 😊 I just got different error:
Logger: custom_components.unraid.coordinator
Zdroj: custom_components/unraid/coordinator.py:656
integrace: UNRAID (dokumentace, problémy)
První výskyt: 18:39:37 (236 výskyty)
Naposledy logováno: 18:39:58

Error parsing parity history line '2024 Aug 22 07:02:37|39935|100.2 MB/s|0|0|recon D3|3907018532|39935|1|Parity Sync/Data Rebuild': Could not parse speed string '100.2 MB B': Invalid speed format: 100.2 MB B
Error parsing parity history line '2024 Aug 22 16:54:25|34564|115.8 MB/s|0|14698|check P Q|3907018532|34564|1|Manual Correcting Parity-Check': Could not parse speed string '115.8 MB B': Invalid speed format: 115.8 MB B
Error parsing parity history line '2024 Aug 27 03:26:17|35770|111.8 MB/s|0|0|check P Q|3907018532|185170|3|Scheduled Non-Correcting Parity-Check': Could not parse speed string '111.8 MB B': Invalid speed format: 111.8 MB B
Error parsing parity history line '2024 Sep 4 01:19:45|39877|100.3 MB/s|0|0|check P Q|3907018532|263979|4|Scheduled Non-Correcting Parity-Check': Could not parse speed string '100.3 MB B': Invalid speed format: 100.3 MB B
Error parsing parity history line '2024 Dec 23 10:21:40|45753|87.4 MB/s|0|5|check P Q|3907018532|45753|1|Automatic Correcting Parity-Check': Could not parse speed string '87.4 MB B': Invalid speed format: 87.4 MB B
Traceback (most recent call last):
  File "/config/custom_components/unraid/helpers.py", line 626, in parse_speed_string
    raise ValueError(f"Invalid speed format: {speed_str}")
ValueError: Invalid speed format: 68.7 MB B

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/config/custom_components/unraid/coordinator.py", line 656, in _parse_parity_history
    speed_bytes = parse_speed_string(f"{fields[2]} B/s")
  File "/config/custom_components/unraid/helpers.py", line 638, in parse_speed_string
    raise ValueError(f"Could not parse speed string '{speed_str}': {err}")
ValueError: Could not parse speed string '68.7 MB B': Invalid speed format: 68.7 MB B

repo: domalab/ha-unraid


text:
Add .fold_chunks() method to SyntaxText

It's currently got a .try_fold_chunks() method but no .fold_chunks() one

Published as 0.11.0.

source: gharchive/issue

authors: Kixiron domenicquirl

repo: domenicquirl/cstree

license_type: permissive

license_source: github-api


text:
Adding mnemonist to the bench

Just adding the mnemonist library to the benchmark. The library also has a variant relying on ES6 Map that could maybe fare better with issues discussed in #20.
The results I get on a 2013 MacBook Pro:
| name             | set   | get1  | update | get2  | evict |
|------------------|-------|-------|--------|-------|-------|
| lru_cache        | 12763 | 26350 | 6789   | 27473 | 13123 |
| mnemonist-object | 9162  | 90909 | 33333  | 90498 | 9095  |
| simple-lru-cache | 6090  | 29762 | 19608  | 34904 | 6831  |
| lru-cache        | 3883  | 4482  | 4109   | 5648  | 6254  |
| lru-fast         | 4739  | 33501 | 27663  | 27933 | 5472  |
| tiny-lru         | 17361 | 24814 | 25608  | 22883 | 5172  |
| hashlru          | 3537  | 6510  | 4790   | 7660  | 4995  |
| quick-lru        | 4200  | 3580  | 4674   | 2949  | 4485  |
| hyperlru-object  | 2667  | 10035 | 12376  | 13689 | 3913  |
| mnemonist-map    | 3782  | 15083 | 12330  | 16000 | 3507  |
| js-lru           | 1597  | 4839  | 4008   | 5822  | 1946  |
| lru              | 2123  | 4544  | 4006   | 4143  | 1824  |
| secondary-cache  | 2035  | 8074  | 4387   | 8961  | 1588  |
| hyperlru-map     | 1398  | 3804  | 4121   | 4620  | 1539  |
| modern-lru       | 759   | 3317  | 2655   | 3090  | 836   |
| mkc              | 950   | 1711  | 1087   | 1867  | 820   |

LGTM, could you update the README?

very good library 👏

@avoidwork I updated the bench code to output a markdown table containing lib's urls so that it's easier to update results in the future and added my results as you asked.

It would really be nice if someone could review the mnemonist's library code related to LRUCache to ensure I did not mess up something regarding the implementation and that it works correctly.

i'll take a look at it after my lunch 👍

Thanks @avoidwork

@Yomguithereal the Map is used in inspect(), the cache is still a plain Object; love how you used an array with pointers to items... i was tossing that idea around for addressing needless ops in tiny-lru.
Everything looks good to me (haven't ran it, just read the .js file).

Yes a Map is used in inspect because for node <= 9 it was a good trick to display the cache as key-value pairs ordered from MRU to LRU with overridden constructor name. But with the recent inspect modification it seems weird indeed because it looks like the cache is extending a Map which it is not. I am still trying to find alternative.

@avoidwork I will try highly specialized varians of a LRUCache in a near future by implementing a 2-choice hashtable. I want to see whether it's possible to speed up evictions (at the cost of slower gets I surmise).

source: gharchive/pull-request

authors: Kikobeats Yomguithereal avoidwork

repo: dominictarr/bench-lru

license: mit

license_source: bigquery


text:
buneary create --help displays probably wrong description for command binding

Current:
Available Commands:
  binding     Create a new queue <--
  exchange    Create a new exchange
  queue       Create a new queue

Expected:
Available Commands:
  binding     Create a new binding <--
  exchange    Create a new exchange
  queue       Create a new queue

Absolutely! Thanks for opening this issue, I'm going to fix the description in an upcoming PR.

This fix is contained in buneary v0.1.1.

authors: dominikbraun fyradir

repo: dominikbraun/buneary


text:
🛑 Anna Lührmanns Website is down

In 7233c8e, Anna Lührmanns Website (https://anna-luehrmann.de) was down:

HTTP code: 0
Response time: 0 ms

Resolved: Anna Lührmanns Website is back up in dd3ea9a after 7 minutes.

repo: dominiklawetzky/status-page

license: MIT


text:
global variable in browser context is always undefined. I think you meant globalThis

https://github.com/donavon/use-dark-mode/blob/29590271bb3a74f08975181c5ed68bd5a210ef83/src/initialize.js#L15
The global variable will only exist in node during ssr. globalThis === window in browsers and globalThis === global in node

yes, i am facing the same issue. As soon i use the hook, my app crashes with an error use-dark-mode.m.js:1 Uncaught ReferenceError: global is not defined. I am using vite with react 17

facing same problem
now created custom solution using
https://www.thisdot.co/blog/how-to-implement-a-dark-to-light-mode-feature-in-your-react-sass-project
and
https://www.geeksforgeeks.org/how-to-create-dark-mode-using-prefer-color-scheme-media-query/

I solved this by adding window.global = globalThis in the file where I create the entry point to the DOM
Example:
import React from 'react';
import ReactDOM from 'react-dom/client';
import App from './App';
import './index.css';

window.global = globalThis;

ReactDOM.createRoot(document.getElementById('root')).render(
  <React.StrictMode>
    <App />
  </React.StrictMode>
);

This will also work:
import useDarkMode from "use-dark-mode";
import { Switch } from "@nextui-org/react";
import { SVGProps } from "react";

export const ThemeSwitcher = () => {
    const darkMode = useDarkMode(false, {
        classNameDark: "dark",
        classNameLight: "light",
        global: window, // Just pass this as a config option
    });

    return (
        <Switch
            defaultSelected={darkMode.value}
            onValueChange={darkMode.toggle}
            size="lg"
            color="warning"
            startContent={<MoonIcon />}
            endContent={<SunIcon />}
        />
    );
};

repo: donavon/use-dark-mode


text:
Error when generating a plugin

I encountered the following error while starting a new plugin this morning:
Bitovis-MacBook-Pro:Sites Bitovi$ donejs plugin
Initializing new DoneJS application at /Users/Bitovi/Sites
Installing donejs-cli

> spawn-sync@1.0.15 postinstall /Users/Bitovi/Sites/node_modules/donejs-cli/node_modules/yeoman-generator/node_modules/cross-spawn/node_modules/spawn-sync
> node postinstall

donejs-cli@0.7.2 node_modules/donejs-cli
├── q@1.4.1
├── steal-platform@0.0.4
├── commander@2.9.0 (graceful-readlink@1.0.1)
├── debug@2.2.0 (ms@0.7.1)
├── mkdirp@0.5.1 (minimist@0.0.8)
├── cross-spawn-async@2.1.9 (lru-cache@4.0.0, which@1.2.4)
├── yeoman-environment@1.5.2 (escape-string-regexp@1.0.5, log-symbols@1.0.2, grouped-queue@0.3.2, text-table@0.2.0, diff@2.2.2, untildify@2.1.0, chalk@1.1.1, mem-fs@1.1.2, inquirer@0.11.4, globby@4.0.0, lodash@3.10.1)
└── yeoman-generator@0.20.3 (detect-conflict@1.0.0, read-chunk@1.0.1, yeoman-assert@2.1.1, yeoman-welcome@1.0.1, path-exists@1.0.0, path-is-absolute@1.0.0, async@1.5.2, mime@1.3.4, text-table@0.2.0, class-extend@0.1.2, dargs@4.1.0, diff@2.2.2, istextorbinary@1.0.2, user-home@2.0.0, xdg-basedir@2.0.0, nopt@3.0.6, shelljs@0.5.3, cli-table@0.3.1, run-async@0.1.0, chalk@1.1.1, through2@2.0.1, glob@5.0.15, findup-sync@0.2.1, rimraf@2.5.2, mem-fs-editor@2.2.0, cross-spawn@2.1.5, underscore.string@3.3.4, dateformat@1.0.12, github-username@2.1.0, pretty-bytes@2.0.1, gruntfile-editor@1.1.0, html-wiring@1.2.0, lodash@3.10.1, inquirer@0.8.5, download@4.4.3, sinon@1.17.3)
Installing generator-donejs

> spawn-sync@1.0.15 postinstall /Users/Bitovi/Sites/node_modules/generator-donejs/node_modules/yeoman-generator/node_modules/cross-spawn/node_modules/spawn-sync
> node postinstall

generator-donejs@0.7.7 node_modules/generator-donejs
├── q@1.4.1
├── semver@5.1.0
├── lodash@3.10.1
├── validate-npm-package-name@2.2.2 (builtins@0.0.7)
├── lodash.upperfirst@4.1.2 (lodash.tostring@4.1.2)
└── yeoman-generator@0.20.3 (read-chunk@1.0.1, detect-conflict@1.0.0, yeoman-assert@2.1.1, yeoman-welcome@1.0.1, path-exists@1.0.0, path-is-absolute@1.0.0, async@1.5.2, mime@1.3.4, text-table@0.2.0, xdg-basedir@2.0.0, user-home@2.0.0, diff@2.2.2, istextorbinary@1.0.2, class-extend@0.1.2, dargs@4.1.0, debug@2.2.0, nopt@3.0.6, shelljs@0.5.3, cli-table@0.3.1, run-async@0.1.0, mkdirp@0.5.1, chalk@1.1.1, through2@2.0.1, glob@5.0.15, findup-sync@0.2.1, rimraf@2.5.2, mem-fs-editor@2.2.0, yeoman-environment@1.5.2, underscore.string@3.3.4, cross-spawn@2.1.5, github-username@2.1.0, pretty-bytes@2.0.1, dateformat@1.0.12, html-wiring@1.2.0, gruntfile-editor@1.1.0, inquirer@0.8.5, download@4.4.3, sinon@1.17.3)
? Project name mini-calendar
? Project main folder src
? Description A mini calendar component for CanJS.
? Project homepage url https://github.com/icanjs/mini-calendar
? GitHub username or organization icanjs
? Author's Name Marshall Thompson
? Author's Email marshall@creativeideal.net
? Author's Homepage https://github.com/icanjs
? Application keywords canjs,can,component,calendar,dates
? NPM version used 2
Writing package.json v0.7.2
   create package.json
   create build.js
   create .editorconfig
   create .jshintrc
   create .npmignore
   create .travis.yml
   create documentjs.json
   create readme.md
   create .gitignore
   create src/test/test.html
   create src/test/test.js
   create src/mini-calendar_test.js
   create src/mini-calendar.js
   create src/mini-calendar.md
WARN engine testee@0.2.5: wanted: {"node":"~0.10"} (current: {"node":"4.2.6","npm":"2.14.14"})
WARN engine steal-tools@0.14.1: wanted: {"node":"0.10.x - 0.12.x || ^3.0.0"} (current: {"node":"4.2.6","npm":"2.14.14"})
WARN engine miner@0.2.1: wanted: {"node":"~0.10"} (current: {"node":"4.2.6","npm":"2.14.14"})
WARN engine launchpad@0.5.1: wanted: {"node":"^0.12"} (current: {"node":"4.2.6","npm":"2.14.14"})
WARN engine steal-tools@0.13.6: wanted: {"node":"0.10.x - 0.12.x || ^3.0.0"} (current: {"node":"4.2.6","npm":"2.14.14"})

> dtrace-provider@0.6.0 install /Users/Bitovi/Sites/node_modules/testee/node_modules/launchpad/node_modules/restify/node_modules/dtrace-provider
> node scripts/install.js

WARN engine hawk@0.10.2: wanted: {"node":"0.8.x"} (current: {"node":"4.2.6","npm":"2.14.14"})
WARN engine hoek@0.7.6: wanted: {"node":"0.8.x"} (current: {"node":"4.2.6","npm":"2.14.14"})
WARN engine cryptiles@0.1.3: wanted: {"node":"0.8.x"} (current: {"node":"4.2.6","npm":"2.14.14"})
WARN engine boom@0.3.8: wanted: {"node":"0.8.x"} (current: {"node":"4.2.6","npm":"2.14.14"})
WARN engine sntp@0.1.4: wanted: {"node":"0.8.x"} (current: {"node":"4.2.6","npm":"2.14.14"})
WARN engine hawk@0.10.2: wanted: {"node":"0.8.x"} (current: {"node":"4.2.6","npm":"2.14.14"})
WARN engine sntp@0.1.4: wanted: {"node":"0.8.x"} (current: {"node":"4.2.6","npm":"2.14.14"})
WARN engine boom@0.3.8: wanted: {"node":"0.8.x"} (current: {"node":"4.2.6","npm":"2.14.14"})
WARN engine cryptiles@0.1.3: wanted: {"node":"0.8.x"} (current: {"node":"4.2.6","npm":"2.14.14"})
WARN engine hoek@0.7.6: wanted: {"node":"0.8.x"} (current: {"node":"4.2.6","npm":"2.14.14"})

> fsevents@1.0.8 install /Users/Bitovi/Sites/node_modules/documentjs/node_modules/chokidar/node_modules/fsevents
> node-pre-gyp install --fallback-to-build

[fsevents] Success: "/Users/Bitovi/Sites/node_modules/documentjs/node_modules/chokidar/node_modules/fsevents/lib/binding/Release/node-v46-darwin-x64/fse.node" is installed via remote

> fsevents@1.0.8 install /Users/Bitovi/Sites/node_modules/steal-tools/node_modules/chokidar/node_modules/fsevents
> node-pre-gyp install --fallback-to-build

[fsevents] Success: "/Users/Bitovi/Sites/node_modules/steal-tools/node_modules/chokidar/node_modules/fsevents/lib/binding/Release/node-v46-darwin-x64/fse.node" is installed via remote
\
> documentjs@0.4.2 postinstall /Users/Bitovi/Sites/node_modules/documentjs
> install-engine-dependencies

npm ERR! Darwin 15.3.0
npm ERR! argv "/usr/local/bin/node" "/Users/Bitovi/.npm-packages/bin/npm" "--loglevel" "error" "install"
npm ERR! node v4.2.6
npm ERR! npm  v2.14.14
npm ERR! file /Users/Bitovi/.npm/underscore/1.8.3/package/package.json
npm ERR! code EJSONPARSE

npm ERR! Failed to parse json
npm ERR! No data, empty input at 1:1
npm ERR!
npm ERR! ^
npm ERR! File: /Users/Bitovi/.npm/underscore/1.8.3/package/package.json
npm ERR! Failed to parse package.json data.
npm ERR! package.json must be actual JSON, not just JavaScript.
npm ERR!
npm ERR! This is not a bug in npm.
npm ERR! Tell the package author to fix their package.json file. JSON.parse

npm ERR! Please include the following file with any support request:
npm ERR!     /Users/Bitovi/Sites/npm-debug.log
events.js:146
      throw err;
      ^

Error: Uncaught, unspecified "error" event. (1)
    at emit (events.js:144:17)
    at ChildProcess.done (/Users/Bitovi/Sites/node_modules/generator-donejs/node_modules/yeoman-generator/lib/base.js:414:16)
    at emitTwo (events.js:87:13)
    at ChildProcess.emit (events.js:172:7)
    at maybeClose (internal/child_process.js:821:16)
    at Process.ChildProcess._handle.onexit (internal/child_process.js:211:5)
Error: Command `node` did not complete successfully
    at ChildProcess.<anonymous> (/Users/Bitovi/.npm-packages/lib/node_modules/donejs/lib/utils.js:45:23)
    at emitTwo (events.js:87:13)
    at ChildProcess.emit (events.js:172:7)
    at Process.ChildProcess._handle.onexit (internal/child_process.js:200:12)

I missed the plugin name argument, so it generated the plugin directly in my Sites folder.  When I added the plugin name, it worked fine.

repo: donejs/generator-donejs


text:
🛑 Διεθνές Πανεπιστήμιο Ελλάδος (TEIEMT) is down

In a2137d6, Διεθνές Πανεπιστήμιο Ελλάδος (TEIEMT) (https://e-secretariat.teiemt.gr/unistudent/) was down:

HTTP code: 0
Response time: 0 ms

Resolved: Διεθνές Πανεπιστήμιο Ελλάδος (TEIEMT) is back up in 8d759ef.

repo: donfn/unistudents-status


text:
Allow for multiple tags search

Previously when looking for tags, only the last one was taken in account:
self.reporter.finding_templates.list(filter={"tags": ["Web", "Network"]}, **other_args)

The above line will only take the tags Network- for listing vuln.
With this PR, all tags will be used.

Thank you for this pull request!
To filter by multiple tags, you can simply pass all tags as a single comma-separated string:
self.reporter.finding_templates.list(filter={"tags": "Web,Network"}, **other_args)

I think your current proposal is too specific, since it only applies to the tags filter, while there are many more filters that can filter by multiple values. But I do think it is a good idea to add the option of passing multiple values as a list instead of a comma-separated string. I'll be sure to look into this next week.

Oh great, I did not know that it was the way for passing multiple tags, thanks then !

Hum, I am getting a server error when stacking tags with comma, I cannot debug this. Have you this issue too ?
Thanks again !

I tried with this script:

rc = Reporter(
    url=reporter_url,
    api_token=api_token,
    ssl_verify=False,
)

finding_templates = rc.finding_templates.list(filter={"tags": "access,database"})

print([ft.title for ft in finding_templates])

and it printed a list of all finding templates that have either the access or database tag.
Did you undo the changes you made to mixins.py? It did throw an error when I applied the changes you made and ran the script again.

Oh yeah sorry for bothering it works well :D Thank you

@Guilhem7 we just merged #36 in which we made it possible to pass filters, includes, and sorts as arrays instead of comma-separated strings. So the code in your original message will actually work now.
The changes are just in our main branch for now, but will be included in the next release (which should hopefully be soon)

repo: dongit-org/python-reporter


text:
Anomalies in treatment

May I ask what happens if there are abnormal samples in the new treatment set and the abnormal detector classifies them as normal?

This belongs to the shift of abnormality (new anomalies appear in the new set).
As disclaimed in the paper, OWAD mainly focuses on the shift of normality because the anomaly detection model cannot be aware of abnormality during learning. However, if we correctly handle the normality shift, the abnormality shift can ideally also be handled as the abnormality is the opposite of normality. So you could try to handle normality shift first and see the results.
If it doesn't work, maybe you should try other techniques, like unlearning.

So is it not allowed to have abnormal samples in the treatment set？
If not, how does OWAD handle real abnormal samples？

No, treatment set could include anomalies, that's why we involve a step of labeling to filter anomalies. See the motivation example in the paper:

As shown in Fig. 2, we keep the samples with high weights, including xc1, xc2, xc4 and xt4, xt5. xt4, xt5 are manually labeled and filter out anomalies (i.e., not included for the following step, no one is filtered in this example)

I understand. Thanks! A very inspiring study!

repo: dongtsi/OWAD


text:
Import not working

When I use import in a PHP script to import another PHP script it doesn't work locally (it works after building though).
I have index.php:
<?php
    include '/config.php';
    echo $test
?>

and config.php:
<?php
    define("test", "testing");
?>

vite.config.ts:
import usePHP from 'vite-plugin-php';

export default defineConfig({
  plugins: [usePHP({ binary: '/opt/homebrew/bin/php', entry: ['index.php', 'config.php', 'get-access/index.php'],})],
});

When opening the page I get this error:
Warning: include(/config.php): Failed to open stream: No such file or directory in /Users/martinhell/Documents/quantumcode/slaice-website/node_modules/vite-plugin-php/dist/router.php(14) : eval()'d code on line 17

Warning: include(): Failed opening '/config.php' for inclusion (include_path='.:/opt/homebrew/Cellar/php/8.2.12_1/share/php/pear') in /Users/martinhell/Documents/quantumcode/slaice-website/node_modules/vite-plugin-php/dist/router.php(14) : eval()'d code on line 17

This is how PHP works. It is trying to include config.php from the ROOT of your server.
/ is the root directory on a Linux system.
You should be able to include the file without the slash, or you can always use relative imports.

Ok thanks.
This doesn't seem to work even if it works on production:
    <form class="flex center wrap" id="registrationForm" method="post" action="./register.php'?>">

The server is never returning a value it seems.

The most recent version of the plugin has a error catcher build in. Now you should be able to see the error causing the page to be blank.

authors: donnikitos quantumcode-martin

repo: donnikitos/vite-plugin-php


text:
migrate billing to 5.0.0

Upgrade billingclient to 5.0.0

Any updates to bumping billing?


text:
Disable angularjs-dropdown-multiselect based on condition check

Hello,
Is there any way to Enable and Disable angularjs-dropdown-multiselect based on condition check?
Thanks
Varun

@Varunprakas I think we can do it by using $scope.example12settings = {selectionLimit: 1} conditionally. If you want to disable multiselect i.e you need to enable single item selection set this property or else donot set this option to enable multiselect option.

Thank for reply, But I want to make this ready only if I want to display data but not editable mode. Alternative I can do with two element one as text box & this element by ng-show based on condition.
I just thinking same can be done by same element.

@amitchoudhary151417 If I am not wrong, you want an option for single element to behave as both multiselect and single select which will be decided by a directive like 'ng-show'. Can you please make it clear.

@amitchoudhary151417 If I am not wrong, you want an option for single element to behave as both multiselect and single select which will be decided by a directive like 'ng-show. And you want multiselect on index or show page where you show your data. And single select on edit or create form?. Can you please make it clear.

You can set disabled for each option which locks that option in it's current state. (That's the only way we have right now) If you still are interested in a read-only feature could you please comment? else i'm closing this issue in 2 weeks)

Hi !!!!,
I'm having more number of multiselct dropdown, I should hide a select dropdown based on the input of another one, how to achieve this and is there validation to apply dynamically.
Thanks

Hi.. !
You can simply use this

authors: Ashviniv RasaMohamed Varunprakas amitchoudhary151417 kasunwadasinghe pkempenaers


text:
fix: multiple job values in pods view

Pull Request
Required Fields
:mag_right: What kind of change is it?

fix

:dart: What has been changed and why do we need it?

Added the ability to filter using the job label to fix some queries in k8s-views-pods.json for users that have multiple values in the job label.

Optional Fields
:heavy_check_mark: Which issue(s) this PR fixes?

fixes #75

i change the variable to this:
{
        "current": {
          "selected": false,
          "text": "kube-state-metrics",
          "value": "kube-state-metrics"
        },
        "datasource": {
          "type": "prometheus",
          "uid": "${datasource}"
        },
        "definition": "label_values(kube_pod_info,job)",
        "hide": 0,
        "includeAll": false,
        "multi": true,
        "name": "job",
        "options": [],
        "query": {
          "qryType": 1,
          "query": "label_values(kube_pod_info,job)",
          "refId": "PrometheusVariableQueryEditor-VariableQuery"
        },
        "refresh": 1,
        "regex": "",
        "skipUrlSync": false,
        "sort": 1,
        "type": "query"
      }

and it works fine. Values comes from metrics set by kube-state-metrics

Done, thanks!

:tada: This PR is included in version 1.1.0 :tada:
The release is available on GitHub release
Your semantic-release bot :package::rocket:

authors: dotdc nlamirault

repo: dotdc/grafana-dashboards-kubernetes


text:
 is true ensure Proj0200 and Proj0400 do not report

Closes #168

I wouldn't close the attached issue unless a new issue is opened to deal with the 2 issues mentioned in my last comment in the issue

authors: Corniel CptWesley


text:
[feature request] Ignore Directory.Build.props/targets from ancestor directories

Currently, the dotnet restore {path}/script.csproj works with all standard dotnet and Microsoft.NET.Sdk defaults, however it being an implicit restore in a cached directory of which the user folder is often an ancestor can by accident cause import of files like Directory.Build.[props/targets].
I have spent a lot of time debugging lately why was project.assets.json file missing after a successful restore, and it turns out my repo has overridden the BaseIntermediateOutputPath ;)

It's probably easiest to just create Directory.Build.props and .targets with <Project/> content as siblings of script.csproj.

Yes, that makes sense to me.

repo: dotnet-script/dotnet-script


text:
Two App Registrations?

I'm a bit confused as to the overall architecture here. So with Blazor WASM Hosted using AAD for Auth, are we saying that we need to create two different app registrations, one for the server API and one for the client?
I understand the desire not to explain/re-explain an app registration in a Blazor web doc, but I think some explanation of the overview/background behind all of the steps involved here would be helpful.

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

ID: 3039ff79-ee86-20b1-0082-d3899a84c823
Version Independent ID: af4a3a75-ae52-5f6d-2120-737bc2fefb07
Content: Secure an ASP.NET Core Blazor WebAssembly hosted app with Azure Active Directory
Content Source: aspnetcore/blazor/security/webassembly/hosted-with-azure-active-directory.md
Product: aspnet-core
Technology: aspnetcore-blazor
GitHub Login: @guardrex
Microsoft Alias: riande

Even just like an end state set of images showing what is configured in Azure would be helpful (food for thought).

Hello @taylorchasewhite ... These are considered advanced topics for these scenarios, so we do assume (and cross-link in Azure docs) a number of basic concepts. I probably will try to improve the introductions of these topics when I reach this topic for a UE (user experience) pass this ⛄ holiday 🎁 when I have more time on https://github.com/dotnet/AspNetCore.Docs/issues/19286.
WRT the two registrations ... The product unit recommends that the client (one AAD registered app) authenticates the user for the client app, and the user/client is configured to authz for access to the server API (a different AAD registered app). It's a general security best practice notwithstanding any technical barriers to using one registration.
btw ... We avoid images, especially because the portal changes every 7.5 minutes :smile:. We can't keep up.
I'll cross-link this to my tracking issue so that I review your suggestion when I reach these topics. Thanks for commenting.

Sounds good. FWIW, following the steps correctly in .net 5 I had no issue linking everything up. It just surprised me because I didn't remember creating two app registrations the first time around way back when I first created an app. So from an accuracy standpoint, it looks good!
And makes sense on screenshots.
My only critique is that I just wish I knew why I was doing what I was doing, but I suppose that's more of an assessment of my understanding than this Blazor doc :)

They'll say that it's a security best practice. Different apps should always have separate registrations in AAD/B2C.
It also hampers some flexibility in terms of pointing a client app at a different server API and/or making changes to either app's registration ... you can't customize anything by-app if they're sharing a registration.

two app registrations the first time around way back when I first created an app

I'm not saying it wouldn't work ... just that it isn't recommended.

authors: guardrex taylorchasewhite


text:
Please create an SDK for the PushNotifications like the one you had in AppCenter

Help us make content visible

Tell us what search terms you used and how you searched docs.
Tell us what docs you found that didn't address your concern.

Describe the new topic

Explain why this topic is needed.
Suggest a location in the Table of Contents.
Write an abstract. In one short paragraph, describe what this topic will cover.
Create an outline for the new topic. We'll help review the outline and approve it before anyone writes a topic.

This is a repo for ASP.NET Core docs. What type of PushNotifications

authors: Rick-Anderson grammatnMcK


text:
Suggesting to use anonymous delegate event handler leads to poor performance

I've just found out about an issue (https://github.com/dotnet/aspnetcore/issues/17886) which can dramatically affect the performance of a BlazorServer application which has a lot of data displayed on a page.
However, I could not find anywhere that this performance 'gotcha' is documented..and indeed the docs seem to also suffer from the same issue.
https://docs.microsoft.com/en-us/aspnet/core/blazor/components/event-handling?view=aspnetcore-5.0#lambda-expressions
It would be good to get clear documentation about the best way to bind an onclick event handler on a list of objects so as not to have poor performance.

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

ID: aa724f22-3a49-c7f6-1500-ac2d8dde5894
Version Independent ID: 5e8ef502-ccf9-659d-f25a-0f8f3c75f6e0
Content: ASP.NET Core Blazor event handling
Content Source: aspnetcore/blazor/components/event-handling.md
Product: aspnet-core
Technology: aspnetcore-blazor
GitHub Login: @guardrex
Microsoft Alias: riande

Thanks @darraghjones ... I'll get back to you no later than Monday morning on this.

Yes, @darraghjones ... I like your suggestion for covering this. I'll schedule this now, but just FYI on the timing of resolution: I'm working on major topic overhauls that might run all the way to when we start covering 6.0 and then 6.0 will take a while to address. I'm going to place a QUICK 🏃 cross-link to this issue in the topic, but I won't close the issue out ... this link will be temporary and this issue will remain open. I just can't say exactly when it will get worked. The cross-link that I'm about to place will surface this to readers in the meantime.

authors: darraghjones guardrex


text:
This page don't give enough guideance

[Enter feedback here]
Hello when i add headoutlet component to my layout in mvc I get error could you pleas tell me how to add this to my MVC project properly so I don't get error i dont know how to add this with out error and its holding me for a month now so bad so sad i dont get enough information about this matter here
Document Details
⚠ Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.

ID: 329a19ef-fb46-1f6b-a734-fa1c1334b1e5
Version Independent ID: 3fa4318a-3c11-c1d8-bf24-ddc6d8441ca2
Content: Prerender and integrate ASP.NET Core Razor components
Content Source: aspnetcore/blazor/components/prerendering-and-integration.md
Product: aspnet-core
Technology: aspnetcore-blazor
GitHub Login: @guardrex
Microsoft Alias: riande

Hello @saeednoruzi ... Please open for the product unit at ...
https://github.com/dotnet/aspnetcore/issues
**_Please do the following tho, because filing an issue with nothing more than "it doesn't work" is not helpful ...

Indicate the exact app scenario: Are you trying to set the <head> content of a view, or are you using a component in a view with the component setting the head content. What type of <head> content are you trying to set?
State the repro steps that can be followed to get the error.
State the error.
Put up a minimal repo project on GitHub and cross-link it into your issue.

Please add ...
cc: @guardrex https://github.com/dotnet/AspNetCore.Docs/issues/24904

... to the bottom of your opening comment so that I can follow along. I might re-open this for doc work depending on what they say.

Hello @saeednoruzi ... Please open for the product unit at ...
https://github.com/dotnet/aspnetcore/issues
Please do the following tho, because filing an issue with nothing more than "it doesn't work" is not helpful ...

Indicate the exact app scenario: Are you trying to set the <head> content of a view, or are you using a component in a view with the component setting the head content. What type of <head> content are you trying to set?
State the repro steps that can be followed to get the error.
State the error.
Put up a minimal repo project on GitHub and cross-link it into your issue.

Please add ...
cc: @guardrex https://github.com/dotnet/AspNetCore.Docs/issues/24904

... to the bottom of your opening comment so that I can follow along. I might re-open this for doc work depending on what they say.

Hello again as i told i created new mvc application using .net cor 6.1
I was trying to add blazor component to my mvc application
I just did the first step adding base tag and (head outlet ) component to layout just as doc mentioned but i get error the (head outlet) component does not exist in project what should i import to project do i need import something in order to use it in mvc application

You must follow all of the guidance in that section, not just the first step.
Please ask for further general help on a public support forum, as we don't have the staffing to provide general product support on the docs repo. If you identify a doc error or omission, then please do open an issue on it. We recommend the usual product support forums ...

Stack Overflow (tag: blazor)
ASP.NET Core Slack Team
Blazor Gitter

authors: guardrex saeednoruzi


text:
[HOLD] Blazor updates for 3.2 Preview 3

Fixes #17427
Internal Review Topic
We can get the ball roll'in now and see how this is starting to compose.
Let's clarify the VSC scenario ... VSC users, like CLI users, won't be able to install 3.1.300, thus a separate Blazor WebAssembly template install step should remain, correct?

Let's clarify the VSC scenario ... VSC users, like CLI users, won't be able to install 3.1.300, thus a separate Blazor WebAssembly template install step should remain, correct?

That's correct. VS4Mac users will also need to separately install the template, at least for the time being. Only VS 16.6 is carrying the 3.1.300 SDK previews currently.

I'll update the Mac instruction. Currently, the topics states ...

Only the Blazor Server template is available in Visual Studio for Mac at this time.

I'll check the Mac instructions on my Mac tomorrow to confirm the steps are good.
I fixed the VS instructions:

Blazor Server ... VS 16.4 or later
Blazor Server and Blazor WebAssembly ... VS 16.6 Preview 2 or later

... we might still need to touch the wording a hair.

@guardrex VS4Mac has very limited support for Blazor WebAssembly. It doesn't have support for creating Blazor WebAssembly projects, and has trouble building and running Blazor WebAssembly projects, especially standalone projects. For now I think it's fair to say that Blazor WebAssembly isn't really supported yet by VS4Mac. But Blazor Server is fully supported.

It now refers the reader to the CLI instructions for WASM on macOS.

I'll read it all again in the morning and make sure it's all :+1:.
Anything else?


text:
ForwardedHeaders must be called before UseHsts

Fixes #18816
Internal review URLs

Forwarded Headers Middleware order
apache
https://review.docs.microsoft.com/en-us/aspnet/core/host-and-deploy/linux-nginx?view=aspnetcore-2.1&branch=pr-en-us-18821#use-a-reverse-proxy-server

We should probably just go with
Forwarded Headers Middleware should run before other middleware.
and drop
Forwarded Headers Middleware can run after diagnostics and error handling middleware, but it must must be called before UseHsts.

Original :
Any component that depends on the scheme, such as authentication, link generation, redirects, and geolocation, must be placed after invoking the Forwarded Headers Middleware. As a general rule, Forwarded Headers Middleware should run before other middleware except diagnostics and error handling middleware. This ordering ensures that the middleware relying on forwarded headers information can consume the header values for processing.
Invoke the UseForwardedHeaders method at the top of Startup.Configure before calling other middleware. Configure the middleware to forward the X-Forwarded-For and X-Forwarded-Proto headers:
Now:
Any component that depends on the scheme, such as authentication, link generation, redirects, and geolocation, must be placed after invoking the Forwarded Headers Middleware.
Forwarded Headers Middleware should run before other middleware. This ordering ensures that the middleware relying on forwarded headers information can consume the header values for processing. To run Forwarded Headers Middleware after diagnostics and error handling middleware, see Forwarded Headers Middleware order.
Invoke the UseForwardedHeaders method at the top of Startup.Configure before calling other middleware. Configure the middleware to forward the X-Forwarded-For and X-Forwarded-Proto headers:


text:
Add gRPC retries doc

Blocked on https://github.com/grpc/grpc-dotnet/pull/1187 being merged and released.

@JamesNK, do you want me to do a review to get that started?  You labeled it blocked I assume since we all can't get builds to look at yet, but thought I could help move it along in between time anyway until we can see a build.

Yes, review now. The content is done. The block is so it doesn’t get merged.

..Waiting for the build system to come back online, then I will verify the doc in the build and squash and merge.

This shouldn’t be merged until the linked PR is merged and released. That will be in a weeks time.

authors: JamesNK wadepickett


text:
TLS Authentication failsusing Docker.DotNet. Works perfectly using curl or the docker daemon

Output of dotnet --info:
.NET SDK:
 Version:   7.0.102
 Commit:    4bbdd14480

Runtime Environment:
 OS Name:     ubuntu
 OS Version:  20.04
 OS Platform: Linux
 RID:         ubuntu.20.04-x64
 Base Path:   /usr/share/dotnet/sdk/7.0.102/

Host:
  Version:      7.0.2
  Architecture: x64
  Commit:       d037e070eb

.NET SDKs installed:
  5.0.408 [/usr/share/dotnet/sdk]
  6.0.405 [/usr/share/dotnet/sdk]
  7.0.102 [/usr/share/dotnet/sdk]

.NET runtimes installed:
  Microsoft.AspNetCore.App 5.0.17 [/usr/share/dotnet/shared/Microsoft.AspNetCore.App]
  Microsoft.AspNetCore.App 6.0.13 [/usr/share/dotnet/shared/Microsoft.AspNetCore.App]
  Microsoft.AspNetCore.App 7.0.2 [/usr/share/dotnet/shared/Microsoft.AspNetCore.App]
  Microsoft.NETCore.App 5.0.17 [/usr/share/dotnet/shared/Microsoft.NETCore.App]
  Microsoft.NETCore.App 6.0.13 [/usr/share/dotnet/shared/Microsoft.NETCore.App]
  Microsoft.NETCore.App 7.0.2 [/usr/share/dotnet/shared/Microsoft.NETCore.App]

Other architectures found:
  None

Environment variables:
  Not set

global.json file:
  Not found

Learn more:
  https://aka.ms/dotnet/info

Download .NET:
  https://aka.ms/dotnet/download

What version of Docker.DotNet?:
3.125.12

Steps to reproduce the issue:

I'm trying to use Docker.DotNet to connect to a remote docker instance that is protected using TLS and Client Auth
I've tested the setup using both curl and the docker cli and the mutual auth component works correctly.

docker context update --docker "host=tcp://somedomain.com:2376,ca=ca.pem,cert=server.pem,key=server-key.pem" local-https
curl https://somedomain.com:2376/images/json --cert server.pem --key server-key.pem --cacert ca.pem

I packaged my cert into a pfx with this command:

openssl pkcs12 -export -inkey server-key.pem -in server.pem -out key.pfx -certfile ca.pem

What actually happened?:
When running using Docker.Net it fails with SSL Authentication errors:
On the dotnet app:
      System.Security.Authentication.AuthenticationException: Authentication failed, see inner exception.
       ---> Interop+OpenSsl+SslException: SSL Handshake failed with OpenSSL error - SSL_ERROR_SSL.
       ---> Interop+Crypto+OpenSslCryptographicException: error:14094412:SSL routines:ssl3_read_bytes:sslv3 alert bad certificate
         --- End of inner exception stack trace ---
         at Interop.OpenSsl.DoSslHandshake(SafeSslHandle context, ReadOnlySpan`1 input, Byte[]& sendBuf, Int32& sendCount)
         at System.Net.Security.SslStreamPal.HandshakeInternal(SafeDeleteSslContext& context, ReadOnlySpan`1 inputBuffer, Byte[]& outputBuffer, SslAuthenticationOptions sslAuthenticationOptions, SelectClientCertificate clientCertificateSelectionCallback)
         --- End of inner exception stack trace ---
         at System.Net.Security.SslStream.ForceAuthenticationAsync[TIOAdapter](Boolean receiveFirst, Byte[] reAuthenticationData, CancellationToken cancellationToken)
         at Microsoft.Net.Http.Client.ManagedHandler.ProcessRequestAsync(HttpRequestMessage request, CancellationToken cancellationToken)
         at Microsoft.Net.Http.Client.ManagedHandler.SendAsync(HttpRequestMessage request, CancellationToken cancellationToken)
         at System.Net.Http.HttpClient.<SendAsync>g__Core|83_0(HttpRequestMessage request, HttpCompletionOption completionOption, CancellationTokenSource cts, Boolean disposeCts, CancellationTokenSource pendingRequestsCts, CancellationToken originalCancellationToken)
         at Docker.DotNet.DockerClient.PrivateMakeRequestAsync(TimeSpan timeout, HttpCompletionOption completionOption, HttpMethod method, String path, IQueryString queryString, IDictionary`2 headers, IRequestContent data, CancellationToken cancellationToken)
         at Docker.DotNet.DockerClient.MakeRequestAsync(IEnumerable`1 errorHandlers, HttpMethod method, String path, IQueryString queryString, IRequestContent body, IDictionary`2 headers, TimeSpan timeout, CancellationToken token)
         at Docker.DotNet.ContainerOperations.ListContainersAsync(ContainersListParameters parameters, CancellationToken cancellationToken)
...

On the docker host:
15:52:44 http: TLS handshake error from 10.1.0.93:49520: tls: failed to verify client certificate: x509: certificate signed by unknown authority

What did you expect to happen?:
Normal, successful connection
Additional information:

Ok, so after more debugging I figured out the issue. Leaving the information here in case others are facing the same problem.
My certificates are signed by a proper CA authority, this means that the client auth cert is signed by an intermediate authority which is itself signed by the root CA. In these kind of circumstances, the client is expected to send to the server the full certificate chain right until the root CA. So in my case, it would be sending both the ClientCertificate and the Intermediate Certificate. With those two, the server can use the root CA to validate the intermediate and then the client and everything would work correctly.
Dotnet does not do that, instead it sends only the Client certificate to the server, signed by the intermediate. Since the server does not have the intermediate cert, it cannot validate the client and therefore rejects the request. This is a known bug on dotnet and it seems to be getting fixed in 8.0
In the meantime, a workaround is to include the intermediate cert on the ca.pem file installed on the Docker server. This way everything can be validated correctly.


text:
The correct date cannot be read

Describe the bug
I expected the date to be: 2022-06-17 23:59:59, but instead I got 2022-06-17 23:59:58
Screenshots

Steps to reproduce the behavior:
// Open the document as read-only.
using (SpreadsheetDocument spreadsheetDocument =
       SpreadsheetDocument.Open("/Users/zhuangjiaju/Downloads/date2.xlsx", false))
{
    WorkbookPart workbookPart = spreadsheetDocument.WorkbookPart;
    WorksheetPart worksheetPart = workbookPart.WorksheetParts.First();
    SheetData sheetData = worksheetPart.Worksheet.Elements<SheetData>().First();
    string text;
    foreach (Row r in sheetData.Elements<Row>())
    {
        foreach (Cell c in r.Elements<Cell>())
        {
            text = c.CellValue.Text;
            double doubleTime = double.Parse(c.CellValue.InnerXml);
            DateTime dateTime = DateTime.FromOADate(doubleTime);
            Console.WriteLine(dateTime.ToString("yyyy-MM-dd HH:mm:ss") + " ");
        }
    }
}

Observed behavior
A clear and concise description of what you expected to happen.
date2.xlsx
Expected behavior
A clear and concise description of what you expected to happen.
Desktop (please complete the following information):

OS: [e.g. Windows]
Office version [e.g. 16.0.15427.20178]
.NET Target: (e.g. .NET Framework, .NET Core, UWP, Xamarin...)
DocumentFormat.OpenXml Version: (e.g. 2.11.0)

Additional context
Add any other context about the problem here.

@zhuangjiaju If you add the more precise format specifier, you'll see that the underlying double value has more precision and therefore the reason for Excel's rounding to 23:59:59 on the last cell. If you use this code:
Console.WriteLine(dateTime.ToString("yyyy-MM-dd HH:mm:ss.ff") + " ");

you'll see this:
2022-06-15 23:59:59.00
2022-06-16 23:59:59.00
2022-06-17 23:59:58.99

authors: tomjebo zhuangjiaju

repo: dotnet/Open-XML-SDK


text:
Connection pool doesn't work well with access tokens

Describe the bug
The connection pool doesn't work well with explicit access tokens because SqlConnectionPoolKey uses reference equality to compare access tokens. It should use string.Equals instead.
The error is in line https://github.com/dotnet/SqlClient/blob/654933a0811ab30b843a20aff051b8d585238505/src/Microsoft.Data.SqlClient/netfx/src/Microsoft/Data/SqlClient/SqlConnectionPoolKey.cs#L113
To reproduce
Create two strings at1 and at2 which contain the same valid access token.
Open a connection with pooling enabled (which is the default); set SqlConnection.AccessToken to at1 and run a query. Close the connection. Open a second connection with pooling enabled; set SqlConnection.AccessToken to at2 and run a second query. Check the number of open connections on the server; it will be 2.
Repeat the experiment except using at1 both times. There will only be a single open connection on the server.
Expected behavior
Pooled connections using an explicit access token should be shared even if different string objects containing the same value were used to initialize the connection.
Further technical details
N/A

Hi @CurtHagenlocher
I'm using a simple test to verify this behavior with Microsoft.Data.SqlClient (targeting .NET Framework) but I don't see multiple connections getting created, please find my repro app attached below, and let me know if I understood the use-case same way.

I created 6 connections with different objects for access tokens, some global, and some local scope, but below was my result:

App is kept running to keep pooled connection active.
On querying database with sp_who2, I see my application has only 1 active connection.
On querying database with the SPID of the active connection, with query:
select num_reads from sys.dm_exec_connections where session_id = @@SPID,
I get output: 6.

Please help me reproduce the problem. Thanks!
TestAAD.zip

Could it be that compiler optimized all these variables with the same string value and made the all be "reference-equal"?

Could it be that compiler optimized all these variables with the same string value and made the all be "reference-equal"?

@mpanasiuk-apptio
This issue was fixed in https://github.com/dotnet/SqlClient/pull/443

@mpanasiuk-apptio
This issue was fixed in https://github.com/dotnet/SqlClient/pull/443

repo: dotnet/SqlClient


text:
Support specifying the args for running a container

I want to be able to use the redis image, but run the redis-cli  in that container e.g.:
builder.AddContainer("redis-cli", "redis")
    .WithArgs("redis-cli -h redis MONITOR");

@karolz-ms Does DCP support this?

Putting this in preview2 as it's blocking a few scenarios.

@davidfowl Thanks for prioritizing this. I'm using Typesense which requires overriding the command thus I cannot use Aspire at the moment :(

Sure we’ll get it for the next preview.

authors: MeikelLP davidfowl

repo: dotnet/aspire


text:
allow overridding of default annotations

In some cases the default annotation for a resource/container needs to be overridden and this currently requires replacing/rewritting a lot of code, when a simple replacement of one or more of the resource annotations is all that is required.  please consider a way to remove/replace/list annotations attached to a resource builder.

Can you give examples of what you are trying to accomplish?

@davidfowl when using the builder.Add{service}Container() or other extension methods as provided by 3rd party it may not allow the developers to override the repository, image or tag and/or replace default annotation values. It would be great if the values could be changed prior to building of the container via a  delegate or configuration item using a fluent style syntax (extension methods) and or query annotations using linq style methods to make complex code base decisions.
buider.AddRedisContainer(name:"redis",password:"something")
.UsingRepository("localRepository")
.UsingImage("")
.UsingTag("")
.RemoveEndpoint(name: "management")
.RemoveEndpoint(name: "debug", (annotations)=>
{
return annotations.Any(a=>a.TypeOf(EndPointAnnotation) && a.Protocol == Tcp && uriSchema == "https")
})

In preview 4 and 5, there are higher level methods that allow changing the container properties. There are also methods for changing endpoints. If you have more suggestions for methods that we should add I would enumerate them and then we (or others) can iterate on the design of those APIs and then accept PRs.
This issue is a bit broad (more of a discussion) so it's not very actional in its current state.

authors: 3GDXC davidfowl gabriel-systems


text:
Simple parallel publishing target for SDK containers

Pushed this up as a point of discussion.
The usage is dotnet build-t:PublishAllReferencedApplications <whatever other parameters you want the publishing applications to have, like arch/os/configuration>.
Because the PublishContainer target isn't available in the base .NET SDK (remember it's only imported by things that support the Publish SDK) we can't just try to call that target on every ProjectReference that the Aspire host app has - if we do this will fail. So we need some kind of marker to know which ProjectReferences are safe to call. Right now this is just a piece of metadata on the ProjectReference, but this could probably also be derived from the generated manifests in some way?
Once we know the set of projects to publish things are fairly straightforward - we can do that in parallel quite easily. Some things to think about:

Right now we're not returning any outputs from the called targets - would azd tooling need some of the existing outputs from the PublishContainer target after this target is called? If so we can use the TargetOutputs metadata on the MSBuild task to grab that.
The PublishContainer target itself isn't amazingly parallelizable - it does everything related to fetching/constructing the container in one Task. This isn't perfectly safe - we don't have locks over some of the file creation we do (e.g. when downloading container base image manifests or layer tarballs). That flakiness alone may be enough to sink this effort for preview. We have some prior reports of this for the container tooling (e.g. https://github.com/dotnet/sdk-container-builds/issues/344) but since folks weren't broadly publishing multiple projects in parallel we deprioritized fixing this.
when built in this way, the CatalogService sample in eshop fires NETSDK1152 - Found multiple publish output files with the same relative path: D:\code\aspire\samples\eShopLite\CatalogDb\appsettings.Development.json, D:\code\aspire\samples\eShopLite\CatalogService\appsettings.Development.json, D:\code\aspire\samples\eShopLite\CatalogDb\appsettings.json, D:\code\aspire\samples\eShopLite\CatalogService\appsettings.json. I haven't investigated why this is, but why are appsettings from CatalogDb being copied as part of CatalogService?

With advances in this repo, a parallel publishing target has gotten much simpler: https://github.com/baronfel/aspire/compare/main...parallel-container-build-target
The two latter points from the original description still apply:

Container publish has some races that need to be made resilient to multi-process publishing
The Web SDK has some races with parallel Publishing that are broadly unknown/uninvestigated

However, if the layer caches for the container publish already exist, then a target like this just works:
  <Target Name="PublishAllReferencedApplications" DependsOnTargets="_CreateAspireProjectResources">
    <!-- Don't Publish apps in parallel due to blockers in the Web SDK/.NET SDK -->
    <MSBuild
        Projects="@(_AspireProjectResource)"
        Targets="Publish" />
    <!-- But publish containers in parallel -->
    <MSBuild
        Projects="@(_AspireProjectResource)"
        Targets="PublishContainer"
        BuildInParallel="true"
         />
  </Target>

You can see this in action:


text:
added core ref/docs links

Added HREFs to the reference and getting started blue box buttons

Hi @bradygaster, I'm your friendly neighborhood .NET Foundation Pull Request Bot (You can call me DNFBOT). Thanks for your contribution!
You've already signed the contribution license agreement. Thanks!
We will now validate the agreement and then real humans will evaluate your PR.
TTYL, DNFBOT;

let me know when you're done with your changes @bradygaster and I'll merge

@mairaw i'm done. merge away. thanks!

authors: bradygaster dnfclas mairaw

repo: dotnet/core-docs


text:
fixed note style

Changed notes not using the style defined in our guidelines.

Open Publishing Build Service: The pull request content has been published and here are some sample preview links:

Docset 1: core-docs

Looks great.  :shipit:

authors: BillWagner mairaw qinezh


text:
Error on typing dotnet in command prompt

Problem encountered on https://dotnet.microsoft.com/learn/dotnet/hello-world-tutorial/install
Operating System: windows
'dotnet' is not recognized as an internal or external command error

Have you tried opening a new command prompt window? The installer updates your PATH envvar, and command prompts don't see updates without restarting.

Closing out; please feel free to re-open if you're still seeing this issue and can provide more information.

repo: dotnet/core


text:
Single file publish problem. The application to execute does not exist.

After some time Windows can clean previously unpacked app folder i.e.
C:\Users\username\AppData\Local\Temp.net\MyApp\alsn4mer.rpw
And leaves it empty.
Single .exe .net core app only check if folder exists and then tries to start app from MyApp.dll file. Which doesn't exist and app crashes with:
"The application to execute does not exist: ... .dll" error.

@jeffschwMSFT

@swaroop-sridhar

authors: bezxyw jeffschwMSFT scalablecory


text:
can not install .net

My mac is pro13. I installed SDKarm64. it seems completed.but I tried $ dotnet code in new terminal, I receive a zsh: command not found: dotnet error. I tried many times.
pls help. Thank you very much

Did you follow this tutorial? https://dotnet.microsoft.com/en-us/learn/dotnet/hello-world-tutorial/install It says to open a new terminal session after you install the SDK to pick up the changes.

Is your machine a M1 machine?

authors: mairaw rzikm wulufei


text:
Can System.IO.FileSystem.Watcher.Polling be used with .net Full Framework?

Hi!
There's a dependency on FileSystemEnumerator - which seems only be available in .net core. Is there a way to get this on .net full framework to run as well?
Thanks!
Stefan

I don't think is any plan to put up a public Nuget package for FileSystemEnumerator
that would run on .NET Framework. @JeremyKuhne owns it, though.

@StefanKoell you could probably build one yourself though.

authors: StefanKoell danmosemsft

repo: dotnet/corefxlab


text:
Enable JIT testing for Mac

@schellap PTAL

:+1:

repo: dotnet/corert


text:
Doesn't work - crashes with [monodroid-assembly] open_from_bundles: failed to load assembly SQLitePCLRaw.provider.dynamic_cdecl.dll Loaded assembly: System.Runtime.Numerics.dll [External] [monodroid-assembly] open_from_bundles: failed to load assembly SQLitePCLRaw.provider.dynamic_cdecl.dll

[Enter feedback here]

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

ID: 73164f27-28e1-7bf6-64ec-277ade9ac973
Version Independent ID: 73164f27-28e1-7bf6-64ec-277ade9ac973
Content: .NET MAUI local databases - .NET MAUI
Content Source: docs/data-cloud/database-sqlite.md
Product: dotnet-mobile
Technology: dotnet-maui
GitHub Login: @davidbritch
Microsoft Alias: dabritch

Nevermind. Deleting bin and obj folders and rebuilding solved.

repo: dotnet/docs-maui


text:
Add how-to/conversions samples to sample browser

Currently, the how-to/conversions samples for C# and VB are zipped in the zip file is referenced in an article:

This isn't good because changes to made to the sample may be forgotten to be zipped again. That can cause the zip file to be out-of-sync with the actual sample.
It's better to add it the sample browser and delete the zip file.

Hi @Youssef1313,
Could you please provide me with the link to where you're seeing this? I cannot find it. I spent time looking in the Browse code samples but was unsuccessful 😄

@IEvangelist Currently, this sample isn't in the samples browser. This issue is to add it to the samples browser and delete the zip file.
The zip file is linked in this article, in the note under the "parse" heading.

repo: dotnet/docs


text:
Incorrect example for InlineIfLambda in page What's new in F# 6

The example in https://docs.microsoft.com/en-us/dotnet/fsharp/whats-new/fsharp-6#inlineiflambda seems totally wrong:

For example, consider the following iterateTwice function to traverse an array:
let inline iterateTwice ([<InlineIfLambda>] action) (array: 'T[]) =
    for j = 0 to array.Length-1 do
         action array[j]
     for j = 0 to array.Length-1 do
         action array[j]

If the call site is:
let arr = [| 1.. 100 |]
let mutable sum = 0
arr  |> iterateTwice (fun x ->
    sum <- sum + x)

Then after inlining and other optimizations, the code becomes:
let arr = [| 1.. 100 |]
let mutable sum = 0
for j = 0 to array.Length-1 do
    sum <- array[i] + x
for j = 0 to array.Length-1 do
    sum <- array[i] + x

Note the use of array instead of arr, replacing sum instead of x and [i] instead of [j].
This is a fixed version (unless I missed something :P ):
let arr = [| 1.. 100 |]
let mutable sum = 0
for j = 0 to arr.Length-1 do
    sum <- sum + arr[j]
for j = 0 to arr.Length-1 do
    sum <- sum + arr[j]

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

ID: e2dea170-a8f4-90f6-e578-e406fb43fef1
Version Independent ID: 885f9f09-d2ff-112c-6dda-9a31bccc0e8a
Content: What's new in F# 6 - F# Guide
Content Source: docs/fsharp/whats-new/fsharp-6.md
Product: dotnet-fsharp
GitHub Login: @cartermp
Microsoft Alias: dotnetcontent

@KathleenDollard @dsyme

authors: BillWagner MHHenriksen


text:
Compiler Error CS0106 misleading

I'm compiling examples in the draft Ecma V7 C# standard, and got this error from the following code:
> public class C
> {
>     private int[] arr = new int[10];
>
>     public readonly ref int M()     // results in "CS0106: The modifier 'readonly' is not valid for this item"
>     {
>         // element is a reference variable that refers to arr[5]
>         ref int element = ref arr[5];
>         return ref element; // return reference to arr[5];
>     }
> }

The grammar for a method header is as follows:
method_header
    : attributes? method_modifier* 'partial'? ('ref' 'readonly'?)?
      return_type member_name  type_parameter_list?
      '(' formal_parameter_list? ')' type_parameter_constraints_clause*
    ;

and the rule method_modifier does NOT include readonly. Instead, if readonly is applied to the return type (as we want here), it must be hardcoded to follow ref. As such, readonly is NOT actually a modifier in this context.
So, by changing readonly ref to ref readonly the code compiles.
Rex

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

ID: 2662c650-5bb7-3860-f803-42048194f880
Version Independent ID: f3a26a17-4d0b-e6fc-dd54-28d91e4fa5ad
Content: Compiler Error CS0106
Content Source: docs/csharp/language-reference/compiler-messages/cs0106.md
Product: dotnet-csharp
Technology: csharp-diagnostics
GitHub Login: @BillWagner
Microsoft Alias: wiwagn

Thanks for noting this @RexJaeschke

authors: BillWagner RexJaeschke


text:
ML.NET clustering tutorial: simplify data loading step

Fixes #10525
Supported by dotnet/samples#659
@JRAlexander @luisquintanilla please review

Thanks for making the changes @pkulikov . I have approved them and you should be okay to merge now.

@luisquintanilla I cannot merge; could you please merge this and samples one PRs?

Thanks for reviews!

authors: luisquintanilla pkulikov


text:
Clarify which assembly sets up compatibility modes

Fixes #5075

/cc @mjrousos


text:
Cannot access compute error when training for object detection

System Information (please complete the following information):

Model Builder Version: 16.2.2047901
Visual Studio Version: 16.8.0 Preview 3.2

Describe the bug
Receive the error "Cannot access compute. If using a low priority compute it may not currently be available. Try again with a dedicated compute or try again later."
To Reproduce
Steps to reproduce the behavior:
Created a new compute for the Object Detection scenario, added the data set, and clicked to train.
Screenshots
Error:

Selected workspace:

Workspace details:

Additional context
I believe it's similar to #991 but I still get the error when using a dedicated compute instance.

Thanks for reporting! we will look into it.

Hi @jwood803, can you provide the log file to see the issue in more detail?

Sure, @zewditu! I uploaded it here.

Thanks @jwood803 , we will look into it.

@jwood803 unfortunately the logs are missing the inner exception that we'd need to get more information. We'll fix that in a future release.
Does it look like the compute was successfully created in the portal? Are there enough compute cores available to start the compute?

@JakeRadMSFT It was successfully created, but it does show 0 nodes and 0 node count. I'm not sure if it only takes nodes when it does a run or if it needs at least one node for it to work.

@JakeRadMSFT I'm getting the same error.
Full log:
37aeb4a9-72d5-4cac-8622-1551e545b7c5.txt

authors: JakeRadMSFT jwood803 kasthack zewditu

repo: dotnet/machinelearning-modelbuilder


text:
filePath cannot be null or empty

System Information (please complete the following information):

Model Builder Version (available in Manage Extensions dialog): 16.13.1.2210302
Visual Studio Version: 17.2.0 Preview 4.0
Windows 10.0.19.044 Build 19044
RAM: 16 GB
11th Gen Intel(R) Core(TM) i5-1135G7

Describe the bug

Pictures classification
local cpu
data: screenshots
file name is in logic: folder_number (screen)
Trainer: filePath cannot be null or empty

MLModel1-MIJFYW.txt

I dont know whats happend, but i created new project with the same images and everything seems to be ok....sorry.

Try reading the logs again. For image classification model, you need at least two classifier folders (parent/dogs, parent/cats). if you only have one classifier folder, you might see this error.