text:
How to downgrade swarm version within docker-machine?

I am blocked by the private registry image problems (#2217), and need to downgrade from swarm 1.2.2 to swarm 1.2.0.  However, I did not install swarm manually, I am using docker-machine to create my cluster within AWS.  How does docker-machine/docker choose which version of swarm to use? How can I change it?
Here are the relevant versions
$ docker version
Client:
 Version:      1.11.1
 API version:  1.23
 Go version:   go1.5.4
 Git commit:   5604cbe
 Built:        Tue Apr 26 23:30:23 2016
 OS/Arch:      linux/amd64

Server:
 Version:      swarm/1.2.2
 API version:  1.22
 Go version:   go1.5.4
 Git commit:   34e3da3
 Built:        Mon May  9 17:03:22 UTC 2016
 OS/Arch:      linux/amd64

$ docker-machine version
docker-machine version 0.6.0, build e27fb87

$ docker-compose version
docker-compose version 1.7.0, build 0d7bf73
docker-py version: 1.8.0
CPython version: 2.7.9
OpenSSL version: OpenSSL 1.0.1e 11 Feb 2013

I installed docker, docker-compose, and docker-machine by running the following commands
sudo apt-get update
sudo apt-get -y install linux-image-extra-$(uname -r) apparmor apt-transport-https ca-certificates unzip

sudo su -
echo "deb https://apt.dockerproject.org/repo ubuntu-trusty main" > /etc/apt/sources.list.d/docker.list
exit
sudo apt-key adv --keyserver hkp://p80.pool.sks-keyservers.net:80 --recv-keys 58118E89F3A912897C070ADBF76221572C52609D
sudo apt-get update
sudo apt-get -y install docker-engine

sudo su -
curl -L https://github.com/docker/machine/releases/download/v0.6.0/docker-machine-`uname -s`-`uname -m` > /usr/local/bin/docker-machine && chmod +x /usr/local/bin/docker-machine
curl -L https://github.com/docker/compose/releases/download/1.7.0/docker-compose-`uname -s`-`uname -m` > /usr/local/bin/docker-compose && chmod +x /usr/local/bin/docker-compose
exit

@rmelick #2272 should fix your issue. If you can try 1.2.3-rc1, your pulls will work. If you wish, you can also wait for the 1.2.3 stable release tomorrow that will contain the fix.

Also to answer your question, machine will use the latest stable release (in this case 1.2.2) unless you specify which version to use. Do you run Swarm as a container?

Thanks @nishanttotla.  I do not run swarm as a container.  I don't actually invoke swarm directly.  I create my cluster by running several docker-machine create --driver amazonec2 --swarm commands, then I use docker-compose to deploy to the cluster.

@rmelick is this still an issue for you?

@nishanttotla the release of 1.2.3 has fixed it, but I still would like to know what command line flag to use to specify a specific version, in case I need to downgrade again in the future.

authors: nishanttotla rmelick


text:
fail task when it cannot be resolved

As @stevvooe pointed out in https://github.com/docker/docker/issues/30327, an error is leak when worker restarts and fails to resolve a task. I think if a Running task fails to resolve, we should move it to Failed so manager can restart/reschedule it.
Ping @stevvooe @thaJeztah @aaronlehmann.
Signed-off-by: Dong Chen dongluo.chen@docker.com

SGTM, @stevvooe WDYT?

I would say this looks like a reasonable change. It looks like the error isn't set on the message when encountered and that is why we aren't seeing it propagated.
This needs to be followed up with:

Ensure the exec.Resolve does the right thing when failing at the call sites. There is only one place.
Address the validation issues described in https://github.com/docker/docker/issues/30327#issuecomment-274631754.

The "real" fix needs to happen in docker. The problem is that an error is leaking. Controllers should never fail to resolve unless something is very wrong or the task type is unsupported. When I say an error is "leaking", I mean that it is leaking from the Executor. We had this early on in the networking subsystem and fixed it by ensuring we didn't leak unnecessary errors there.

LGTM

source: gharchive/pull-request

authors: aaronlehmann aluzzardi dongluochen stevvooe

repo: docker/swarmkit

license_type: permissive

license_source: github-api


text:
allocator: Avoid assigning duplicate IPs during initialization

When the allocator starts up, there is a pass that "allocates" the
existing tasks/nodes/services in the store. In fact, existing tasks are
typically already allocated, and this is mostly populating local state
to reflect which IPs are taken. However, if there are any tasks in the
store which are brand new, or previously failed to allocated, these will
actually receive new allocations.
The problem is that allocation of new IPs is interspersed with updating
local state with existing IPs. If a task, node, or service that needs an
IP is processed before one that claims a specific IP, the IP claimed by
the latter task be assigned.
This change makes the allocator do two passes on initialization. First
it handles objects that claim a specific IP, then it handles all other
objects.
cc @abhinandanpb @mavenugo @sanimej @ijc

One open question: Do we need to do something similar for networks? I notice we store a DriverState field on networks, but I'm not sure if this includes IP addresses.

LGTM
Unrelated to this PR, but the complexity of this part is frightening, had a hard time understanding the implications :/

I 100% agree WRT the complexity.
In this case although the diff looks pretty large and confusing the bulk of it is just factoring out allocateTasks and allocateServices and then arranging to call those and allocateNodes twice. IMO the refactoring is a good thing in its own right since that function is pretty big and tricky to follow.
So, LGTM. (I'm a little worried about the apparent non-determinism in the test case, implied by the looping 100 times, but I guess that is unavoidable for an issue like this).

I didn't observe any non-determinism, but wanted to make sure the test case is aggressive enough to catch regressions. The problem triggers much more quickly when creating tasks in reverse numerical order, which is why the test does this. If I remember correctly, it only takes 3 tasks to trigger the problem. But in forward numerical order, it took about 52 tasks (since the allocator iterates over tasks in lexical order, which I suppose is close to numerical order). To avoid encoding assumptions about the iteration order, I decided to do 100 iterations. The test case runs instantly so I don't think there's any downside.
We could consider randomizing the task IDs, but I generally prefer to avoid nondeterminism in tests.

Thanks @aaronlehmann @aluzzardi @ijc am not super familiar with this area of the code.  But it does feel complicated.
BTW, should this be back ported to 17.03 as well ? I have seen multiple reports of duplicate IP usage in swarm-mode.

BTW, should this be back ported to 17.03 as well ?

Yes, if there are plans for another 17.03 release, I think it should be. There are also other high-priority fixes that would make sense to backport. Please let me know if I should work on these backports.

LGTM

authors: aaronlehmann abhinandanpb aluzzardi ijc mavenugo


text:
QEMU harddisk fail

windows  | ❯ Extracting Windows 10 bootdisk...
windows  | ❯ Extracting Windows 10 environment...
windows  | ❯ Extracting Windows 10 setup...
windows  | ❯ Extracting Windows 10 image...
windows  | ❯ Adding XML file for automatic installation...
windows  | ❯ Building Windows 10 image...
windows  | ❯ Creating a 64G growable disk image in raw format...
windows  | ❯ Booting Windows using QEMU emulator version 8.2.1 ...
windows  |
BdsDxe: failed to load Boot0002 "UEFI QEMU QEMU HARDDISK " from PciRoot(0x0)/Pci(0xA,0x0)/Scsi(0x0,0x0): Not Found
windows  | BdsDxe: loading Boot0001 "UEFI QEMU QEMU CD-ROM " from PciRoot(0x0)/Pci(0x5,0x0)/Scsi(0x0,0x0)
windows  | BdsDxe: starting Boot0001 "UEFI QEMU QEMU CD-ROM " from PciRoot(0x0)/Pci(0x5,0x0)/Scsi(0x0,0x0)
windows  | ❯ ERROR: Forcefully terminating Windows, reason: 0...
windows  |
❯ Shutdown completed!
Trying to start the container on M1, this is my YAML:
version: "3"
services:
windows:
image: dockurr/windows
container_name: windows
cap_add:
- NET_ADMIN
ports:
- 8006:8006
- 3389:3389/tcp
- 3389:3389/udp
stop_grace_period: 2m
restart: on-failure
environment:
VERSION: "win10"

@kroese sorry, was trying to respond between meetings.  I am running on an x86 chip with Ubuntu running on a VM.  I did set up the storage on an external volume (which could be the problem), so I'll try running without that before commenting more.

The new release fixed it!!!!!!!  Thank you!!!!

source: gharchive/issue

authors: TheHippiez roadkingvrod

repo: dockur/windows

license: MIT


text:
is final needed?

https://github.com/doctrine/couchdb-odm/blob/master/lib/Doctrine/ODM/CouchDB/DocumentRepository.php#L102

The entire class should probably be final, but only the refresh method got added as final due to its out-of-interface signature, and the late addition. Due to BC compliance, it is no longer possible to make the class itself final.
If you aren't aware of the reasons, see:

http://ocramius.github.io/blog/when-to-declare-classes-final/#comment-3400988766
https://slamdunk.github.io/blog/when-to-declare-methods-final/

authors: Ocramius juliangut

repo: doctrine/couchdb-odm

license: mit

license_source: bigquery


text:
[Documentation] Documentation of Types Mapping Matrix does not have footnotes

Q
A

Version
2.8

Support Question
See:
https://www.doctrine-project.org/projects/doctrine-dbal/en/2.8/reference/types.html#mapping-matrix

Please also notice the mapping specific footnotes for additional information.

There aren't any

Thanks for spotting this - it's a duplicate of already known https://github.com/doctrine/doctrine-website/issues/47 since we migrated to a new website.

For now, you can view the page on GitHub directly, it'll render footnotes as well: https://github.com/doctrine/dbal/blob/master/docs/en/reference/types.rst#mapping-matrix


text:
Fix index duplication for unique association join columns

Complementary fix for recent DBAL change: https://github.com/doctrine/dbal/commit/fc8beca08600b44e46f7b82998adbcc6d52c31f1#commitcomment-9201441
Avoids index duplication for association mappings using unique join columns. Unique constraints to be created for the join columns are now added before adding the foreign key constraint, so that adding the fk doesn't trigger an implicit index creation.
I did not add any further tests as the current failure already reveals the issue.

@deeky666 merged, thanks!


text:
Practical checklist for deploying page embeds

This will probably become a tracking ticket, as some of these will require their own robust discussions on their own tickets.

[x] Mock up pre-progressive-enhancement markup (effectively noscript)
[x] Mock up post-enhancement direct embed code
[x] Implement mockups
[ ] Add page embed composition to wizard
[ ] Add page embed links around workspace -- in all languages
[ ] Documentation

[ ] Push app to staging; get screen grab of menu.
[ ] Write English and Spanish help section at /help/publishing#embed-page
[ ] Merge docs-page-embed branch with master

[ ] Marketing/communication

[x] Write newsletter text
[x] Write blog post
[ ] Upon deployment, publish blog post, send newsletter and tweet

* [ ] Fallback for old browsers (#12)
* [ ] Create page endpoint for displaying single pages as a resource and **providing oEmbed endpoint**
* [ ] Maximize reusability of embed assets (CSS/JS) between versions
* [x] CDN
* [ ] Mock up post-enhancement iframe code and ensure compatibility with Pym (#18)

"Mockup" meaning write the embed codes we want to be issuing, and then make them work.

:+1: agreed on where the line is drawn for MVP!
ROCK IT :rocket:

Cool!

Added documentation and communications tasks to the checklist.

@anthonydb Might be a good idea to merge docs-page-embed into page-embed (which I published last night) so we can have it all in one place before going to master.

Yes, please do that :) :+1:

Updated the checklist to note that page embed links in the workspace need to be supported in the multiple workspace languages we support.

As in will need string translations? Yupppp. I have [need2i18n] sprinkled everywhere so I can quickly find places that need internationalization.

Tomorrow's tasks (putting here for myself):
[ ] Bundle the page embed JS into the platform and deploy to CDN
[ ] Update generated embed code to reference proper JS
[ ] Add translation support (will be just English for now) and ping translators
[ ] Begin live embed preview

[ ] Add note count to page selector on wizard

authors: anthonydb knowtheory reefdog

repo: documentcloud/documentcloud-pages


text:
18+ F𝚛ee po𝚛n Se𝚡 Viral Video Telegram Channel Link (December 2024)

stgbr ghb5erfbnrth

dsasd

.

.
### 𝖶𝖺𝗍𝖼𝗁 🟢 ➤ ➤ ➤ 🌐 𝖢𝗅𝗂𝖼𝗄 𝖧𝖾𝗋𝖾 𝖳𝗈 𝗅𝗂𝗇𝗄 (𝖥𝗎𝗅 𝗅 𝖵𝗂𝗋𝖺𝗅 𝖵𝗂𝖽𝖾𝗈 𝖫𝗂𝗇𝗄)
.
.
.
### 🔴 ➤► 𝖣𝖮𝖶𝖭𝖫𝖮𝖠𝖣👉👉 (𝖥𝗎𝗅𝗅 𝖵𝗂𝗋𝖺𝗅 𝖵𝗂𝖽𝖾𝗈 𝖫𝗂𝗇 𝗄)
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
### 𝖶𝖺𝗍𝖼𝗁 🟢 ➤ ➤ ➤ 🌐 𝖢𝗅𝗂𝖼𝗄 𝖧𝖾𝗋𝖾 𝖳𝗈 𝗅𝗂𝗇𝗄 (𝖥𝗎𝗅 𝗅 𝖵𝗂𝗋𝖺𝗅 𝖵𝗂𝖽𝖾𝗈 𝖫𝗂𝗇𝗄)
.
.
.
### 🔴 ➤► 𝖣𝖮𝖶𝖭𝖫𝖮𝖠𝖣👉👉 (𝖥𝗎𝗅𝗅 𝖵𝗂𝗋𝖺𝗅 𝖵𝗂𝖽𝖾𝗈 𝖫𝗂𝗇 𝗄)
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
### 𝖶𝖺𝗍𝖼𝗁 🟢 ➤ ➤ ➤ 🌐 𝖢𝗅𝗂𝖼𝗄 𝖧𝖾𝗋𝖾 𝖳𝗈 𝗅𝗂𝗇𝗄 (𝖥𝗎𝗅 𝗅 𝖵𝗂𝗋𝖺𝗅 𝖵𝗂𝖽𝖾𝗈 𝖫𝗂𝗇𝗄)
.
.
.
### 🔴 ➤► 𝖣𝖮𝖶𝖭𝖫𝖮𝖠𝖣👉👉 (𝖥𝗎𝗅𝗅 𝖵𝗂𝗋𝖺𝗅 𝖵𝗂𝖽𝖾𝗈 𝖫𝗂𝗇 𝗄)
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
### 𝖶𝖺𝗍𝖼𝗁 🟢 ➤ ➤ ➤ 🌐 𝖢𝗅𝗂𝖼𝗄 𝖧𝖾𝗋𝖾 𝖳𝗈 𝗅𝗂𝗇𝗄 (𝖥𝗎𝗅 𝗅 𝖵𝗂𝗋𝖺𝗅 𝖵𝗂𝖽𝖾𝗈 𝖫𝗂𝗇𝗄)
.
.
.
### 🔴 ➤► 𝖣𝖮𝖶𝖭𝖫𝖮𝖠𝖣👉👉 (𝖥𝗎𝗅𝗅 𝖵𝗂𝗋𝖺𝗅 𝖵𝗂𝖽𝖾𝗈 𝖫𝗂𝗇 𝗄)
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
### 𝖶𝖺𝗍𝖼𝗁 🟢 ➤ ➤ ➤ 🌐 𝖢𝗅𝗂𝖼𝗄 𝖧𝖾𝗋𝖾 𝖳𝗈 𝗅𝗂𝗇𝗄 (𝖥𝗎𝗅 𝗅 𝖵𝗂𝗋𝖺𝗅 𝖵𝗂𝖽𝖾𝗈 𝖫𝗂𝗇𝗄)
.
.
.
### 🔴 ➤► 𝖣𝖮𝖶𝖭𝖫𝖮𝖠𝖣👉👉 (𝖥𝗎𝗅𝗅 𝖵𝗂𝗋𝖺𝗅 𝖵𝗂𝖽𝖾𝗈 𝖫𝗂𝗇 𝗄)
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
### 𝖶𝖺𝗍𝖼𝗁 🟢 ➤ ➤ ➤ 🌐 𝖢𝗅𝗂𝖼𝗄 𝖧𝖾𝗋𝖾 𝖳𝗈 𝗅𝗂𝗇𝗄 (𝖥𝗎𝗅 𝗅 𝖵𝗂𝗋𝖺𝗅 𝖵𝗂𝖽𝖾𝗈 𝖫𝗂𝗇𝗄)
.
.
.
### 🔴 ➤► 𝖣𝖮𝖶𝖭𝖫𝖮𝖠𝖣👉👉 (𝖥𝗎𝗅𝗅 𝖵𝗂𝗋𝖺𝗅 𝖵𝗂𝖽𝖾𝗈 𝖫𝗂𝗇 𝗄)
.

.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.

.
### 𝖶𝖺𝗍𝖼𝗁 🟢 ➤ ➤ ➤ 🌐 𝖢𝗅𝗂𝖼𝗄 𝖧𝖾𝗋𝖾 𝖳𝗈 𝗅𝗂𝗇𝗄 (𝖥𝗎𝗅 𝗅 𝖵𝗂𝗋𝖺𝗅 𝖵𝗂𝖽𝖾𝗈 𝖫𝗂𝗇𝗄)
.
.
.
### 🔴 ➤► 𝖣𝖮𝖶𝖭𝖫𝖮𝖠𝖣👉👉 (𝖥𝗎𝗅𝗅 𝖵𝗂𝗋𝖺𝗅 𝖵𝗂𝖽𝖾𝗈 𝖫𝗂𝗇 𝗄)
.

.
.
.
.
.

authors: Timothee-dcn amiraufasf gbloodcaitl

repo: doczjs/docz


text:
fix(docz-core): add gatsby dev host arg

Description
fix #1187

Hey @ejuo,
Thanks for catching and fixing this issue (and others) 👍
PS : Please feel free to join the docz contributors' slack workspace here : https://join.slack.com/t/docz-workspace/shared_invite/enQtNzc4ODc2ODA3NzUxLWI0ZmYwY2NhNjhkNDFjN2UzYzlmMDcwZjQyZGY4MWQ1NmQwZDVlZDE4MmE3N2I4MWRjZTAxZjY4ODk4NGMzZjg
Cheers !

authors: ejuo rakannimer


text:
cython missing?

I tried to install in windows python 3.10 conda env and encountered error below. After "pip install cython" the error went away. Maybe update installation instructions, or add to requirements.txt? But then the pip install audioowl failed with error below
Thanks!
    F:\tobi\envs\CartPoleSimulation3\include\cpython/pystate.h(60): note: see declaration of '_ts'
      madmom/ml/nn/layers.c(18881): error C2039: 'exc_traceback': is not a member of '_ts'
      F:\tobi\envs\CartPoleSimulation3\include\cpython/pystate.h(60): note: see declaration of '_ts'
      madmom/ml/nn/layers.c(19872): warning C4244: 'initializing': conversion from 'double' to 'float', possible loss of data
      madmom/ml/nn/layers.c(19878): warning C4244: 'initializing': conversion from 'double' to 'float', possible loss of data
      error: command 'C:\\Program Files (x86)\\Microsoft Visual Studio\\2019\\Community\\VC\\Tools\\MSVC\\14.27.29110\\bin\\HostX86\\x64\\cl.exe' failed with exit code 2
      [end of output]

  note: This error originates from a subprocess, and is likely not a problem with pip.
error: legacy-install-failure

× Encountered error while trying to install package.
╰─> madmom

I am getting the same problem, did you manage to solve it?

You can simply install it:
pip install Cython numpy

Packet maintainer has to add this to the list of required packages

But then I get compilation errors for madmom with Python 3.11

So if I try python3.10 Cython is missing and I can't install it as a (python) package.

This is a viable option for use AudioOwl on windows without wsl.
The first thing is that madmom has poor compatibility with MSBuild, so it may be can compiled with mingw64 as a compiler
Tested in py3.6, it should work in 37, but 38 is not clear, and 39 and above will fail (we'll describe why at the end).
1. Prepare the compilation environment
Go to Google and find the mingw32-w64 build, download it and throw it on your hard disk, then add {path to mingw32-w64}/bin to the path of your system environment variable.
Then open a new powershell/cmd and type gcc --verison to make sure the environment variable is working.
Then update your setuptools and wheel, and make sure you have cython installation
pip install --upgrade setuptools wheel cython
2. Building madmom
build preparation
According to https://github.com/CPJKU/madmom:
git clone https://github.com/CPJKU/madmom
cd madmom
git submodule update --init --remote

Then do a version switch
git checkout v0.15.1
build & package
python setup.py build -c mingw32 # -c is responsible for specifying mingw32 as the compiler, setuptools will automatically look for the appropriate gcc
python setup.py bdist_wheel

install
pip install dist/madmom-0.15.1-cp36-cp36m-win_amd64.whl

Different python versions will have different names, just copy the filename.
2. The next step is to build and install audioOwl, which is a similar process.
git clone https://github.com/dodiku/AudioOwl
cd AudioOwl
python setup.py build -c mingw32
python setup.py bdist_wheel
pip install dist/audioowl-0.0.14-py3-none-any.whl

And you're good to go.
For an analysis of why higher versions of python fail
I've spent a lot of time testing the high version of python and it fails.
The reason should be that madmom's code is old and not suitable for high version python and numpy which can be applied to high version.
I managed to compile it in two ways, but without exception, it compiled successful and reported errors during execution.
The first way is to use mingw in linux to cross-compile for Windows X64.
The second way is to use mingw to compile on Windows as described above.
Of course, it should not be a problem with the compilation method, but the code is not suitable for the higher version, after all, one was updated 2 years ago and the other 5 years ago, when installing directly to the higher version of python in Linux, the compilation is pip itself successful, but obviously there are problems in the use of it.

authors: DuskXi inktrap tobidelbruck yongcongluo-informed

repo: dodiku/AudioOwl


text:
🛑 Dogchef is down

In 6cacf9e, Dogchef (https://www.dogchef.com?$BF) was down:

HTTP code: 0
Response time: 0 ms

Resolved: Dogchef is back up in 2a46621 after 18 minutes.

repo: dogchef-be/uptime-monitor


text:
Request

Can anybody test Quake Champions with FakeStreamOutSupport option enabled?
I have problems with compiling dxvk.

I have managed to compile dxvk. Still crashes.

repo: doitsujin/dxvk

license: Zlib


text:
[Dojo] Refactor authorization system into the world directly

Current Behavior
We are using components and systems to set authorization roles and check if systems are authorized to modify entities' components. For example, we have the following systems in systems.cairo

IsAccountAdmin: checks if the caller account has Admin role
IsAuthorized: checks if an execution role has been set, if not, default scoped role is used and finally this role is checked if it's authorized/Admin or not

Here's an example illustration of the flow

Reason
The current method of authorization verification is complex, resulting in a cumbersome process and a less-than-optimal developer experience. The world has to call the executor which then does a library call to these declared components and systems. This results in more execution steps and gas costs. It also makes it hard to debug and reason about.
Proposed Solution
To address these issues, it would be good to simplify the authorization checking by incorporating it directly into the world. This would mean the roles would have to be stored in the contract, as well as exposing public interfaces to set/remove roles. There has been work on the execution context in this pr which could serve as a starting point.

closing as this is complete

authors: ftupas ponderingdemocritus

repo: dojoengine/dojo


text:
Template name has incorrect alignment

template name aligned:

authors: betefaber fernandoMessias

repo: dojot/dojot


text:
Нет анимации исчезновения шапки

Если мы почти доскролили до верха страницы, то шапка просто пропадает, без анимации.
https://user-images.githubusercontent.com/21996065/145658089-c879d261-7d77-4395-9244-af534b6d84bc.mp4

Любопытно, что на локалке этой проблемы нет, и вот action который это фиксит. Возможно на продуктовом сервере не актуальная версия или это проблема из этой темы

authors: cergmin devcustrom

repo: doka-guide/platform


text:
No merge - Migrate to VS2017

#137

Maybe you already know it, but In case you need to troubleshoot the AppVeyor-Build, you can enable RDP.

@Liryna
I'm getting happy with it now. I have not yet been able to test netstandard1.3, MStest lacks functionality for DataRow when running under .NET Core 1.X. Perhaps we can fix this in a separate PR.
Can you please review what I have done. When everything is ready for merge, I'll clean up all the commits.

@magol thank you for all the changes !
I am just wondering since I do not have vs 2017 for now, what happened to all the csprojet, assembly info and such ? Looks like everything has been removed and see nothing new that replace them ? What about nuget package nuspec also removed ?
As my understanding, Dotnet core 1.x do not provide everything by your comments. Do you think we should request the missing features ?
Otherwise this seems to be alright for me ! I will just try to get vs 2017 soon.

The best change in vs2017 is that csproj has become really simplified. All redundant and unnecessary information is deleted, and the management of the nugget is now native in the csproj file.
Even that was previously found in AssemblyInfo is now in the csproj file.
As i have understod it, most of the missing parts of .NET core will come back in version 2.0. In that case, we may add the missing tests when it is launched in the fall.

Ok that makes clearer 👍 Is there already a date for version 2.0 ?

@Liryna From the roadmap

Milestone
Release Date

.NET Core 2.0 Preview
Q2 2017

.NET Standard 2.0 Preview
Q2 2017

.NET Core 2.0
Q3 2017

.NET Standard 2.0
Q3 2017

Hi @magol ,
I just tried to build the solution with vs 2017 and have an error:
AppData\Local\Temp\.NETStandard,Version=v1.3.AssemblyAttributes.cs(4,20,4,26): error CS0400: The type or namespace name 'System' could not be found in the global namespace (are you missing an assembly reference?)

Am I missing something ?
Otherwise, how can I build for framework 4 ?

I've got too this error a few times. I think VS2017 is a bit buggy when it comes to this.
Start the command prompt, go to the project folder and run the following command to fix it:
dotnet restore
Since I use <TargetFrameworks> netstandard1.3; net4.6; net4.0 </ TargetFrameworks>, VS compiles all this targets simultaneously when compiling. To select which version of Mirror you want to run, select in the list as shown below:

If you only want to build for only one target, change to <TargetFramework>net4.0</TargetFramework> in the project file (note that I removed the 's' to make it singular).

Build work perfectly for me ! That’s really a great work 👍
(it is even the first time I am impressed by vs2017 😮 )
Does dotnet restoreneed to be run for each project clone on it is system first launch ?

Great :-D
I don't know if dotnet restore have to be run each time you clone it to a new system. But my experience is that you have to for netstandard applications. The command is used to restore all NuGet packages, strange that VS can not do it for you :-(

@magol Thanks a lot !
Do you think vs2017 / PR is ready to be merged ?

Yes, I think it's ready to merge :-)
I do not know if you have already realized this, but I would still like to give you some tips and other notes:

You can now easily edit the project file from within Visual Studio without having to unload the project. Just right-click on the project and choose Edit DokanNet.csproj. This must be done when editing version numbers and information about NuGet.

Speaking of NuGet, A nupkg file is now automatically created every time you compile and is placed in bin\Release. This is due to <GeneratePackageOnBuild>True</GeneratePackageOnBuild>

I have add some tags to the NuGet. That was missing before, but I think it is important to make it easier to find on nuget.org. Some that you think are missing (or are unnecessary)? It's hard to find good search words.
<PackageTags>dokan file files disk directory storage filesystem io filestore FAT NTFS FUSE</PackageTags>

Alright 👍 let’s do this !
So the version cannot still be updated from interface directly ? Or even taken from a define/macro of the code ?
Create nuget package by default is alright for me and the tags list you made is also correct 👍
Thanks a lot again @magol it is really a great contribution !

@Liryna
Of course, you can also update the version number from the Properties :-)
But I'm considering maybe improving the version number management so that we only needed to updating it in one place. Now, the sample programs do not get a version number and I like to fix it.
My idea is to have a version.props that all csproj files imports. In that way, it is enough to change only that file, and all assemblies get the same version number. Maybe even make a script that updates the Doxygen file?

Yes 👍 having the version only in one place would be the best

No need to update the Doxyfile, you can set the number on command line. Maybe one can even invoke doxygen from msbuild?
Btw I have started to do something similar for the main Dokan project. Not really finished, but I can push my current progress.
There the challenge was that there are many places that hard code the version number in one way or the other. Also making cmake (used for Cygwin and MinGW FUSE build) parse the MSBuild-XML file is not really a viable approach so I opted for a simple file with just the version that can be read easily by MSBuild, CMake, PowerShell, you name it.

You right, to set the doxygen version from the command line is much beter :-)
To invoke doxygen from msbuild was clever. In that way, you can review the documentation before push it to GitHub. But then you have to download doxygen.exe to the developing machine, manual or automatic. I don't know if that is possible (or easy) to do it automatic from MsBuild. That is something to investigate.
It is valuable to have the same approaches for both Dokany and Dokan-dotnet. I'm very interested in how you've done it (even if it's not ready), where do I find it.
Having a simple text file with the version number is probably the best way as you say. Then you are more free to handle it as you want.

I am by no means a MSBuild expert and I have no intention of becoming one. So, take the following with a pinch of salt. Can you make the Doxygen-build optional in some way? Like a separate build target or so. I mean it's not like the Doxygen invocation will be different among .NET versions, Debug/Release config etc. I do not use Visual Studio, so I may not really know what I am talking about...
About dependencies: I also considered writing some wizard-like script, that guides the developer in installing all dependencies of Dokan (Dokan has quite a few if you want to build everything), which makes dependencies like Doxygen more bearable.
This is my current progress: https://github.com/Rondom/dokany/tree/no_hardcode_version
I decided on using Property-Expressions for reading the file, because I could not get a build-step to set a preprocessor-define (You need to include your file at the end of the project to hook into the vcxproj build-process to do something BeforeBuild. At this point the variables in PreprocessorDefinitions are already evaluated it seems). As I said, I have never done anything with MSBuild so the above may be wrong.
About the current state of my branch here:

MSBuild uses the version for resource-files and INF-files
cmake uses the version for dokan_fuse resource-files
everything else (Doxygen, Installer, AppVeyor, some consistency checks) is not done yet (see commit message)
I rebased recently without having a machine to test the building, so the current state could be broken. I do not have the time to test and polish it atm, Sorry.

authors: Liryna Rondom magol

repo: dokan-dev/dokan-dotnet


text:
Request for Toggle to Enable/Disable File Icons

I'm always frustrated when I enjoy the theme's color scheme but don't want to use the included file icons.
I would like an option in the settings to toggle the theme's file icons on or off.
I've considered manually replacing the icons, but this isn't efficient or user-friendly.

Another issue: I noticed today that even when not using the themes from DOKI, the icons from other themes are still affected. This is evident in the icons for expanding files.

repo: doki-theme/doki-theme-jetbrains


text:
remove mention of the Ubuntu ppa

remove mention of the  Ubuntu ppa  due to the fact it no longer exists anymore . Since it no longer exist theirs no reason  to link it

@JosJuice  i think what you mention  is in #137 but i think ill need to be re-based  :)

Finally got around to digging through my old PRs - it's been rebased

repo: dolphin-emu/www


text:
[auto-bump] dependency by zachmu

:coffee: An Automated Dependency Version Bump PR :crown:
Initial Changes
The initial changes contained in this PR were produced by go geting the dependency.
$ cd ./go
$ go get github.com/dolthub/<dependency>/go@<commit>
$ go mod tidy

Before Merging
This PR must have passing CI and a review before merging.
After Merging
An automatic PR will be opened against the LD repo that bumps the bounties version there.

This PR has been superseded by https://github.com/dolthub/bounties/pull/390

repo: dolthub/bounties


text:
Problem: Don't know how other developers have written interpreters in the past

Solution: Review a list of open source interpreters
SuccessCriteria: A list of feedback from reviewing these projects, with notes on how it can be applied to what we're doing.
Before we can do this, we need to compile a list of open source interpreter projects. Will create an issue and link it to this one.

List of open sources interpreter projects to review
These are open source projects that have a large interpreter element. Sadly most of them are written in C.
MySQL
A relational, SQL database
Language: C
https://github.com/mysql/mysql-server
Postgres:
A relational, SQL database
Language: C
https://github.com/postgres/postgres
PHP
The PHP scripting language
Language: C
https://github.com/php/php-src
V8
Javascript interpreter
Language: C++
https://github.com/v8/v8
Here is a link to a doc explaining how it works, could be useful
https://docs.google.com/document/d/11T2CRex9hXxoJwbYqVQ32yIPMh0uouUZLdyrtmMoL44/edit?pli=1#heading=h.6jz9dj3bnr8t
Jasic interpreter
Basic derivative, no concepts of scope or functions
Language: Java
https://github.com/munificent/jasic/blob/master/com/stuffwithstuff/Jasic.java

V8 is looking the most promising. It's written in C++, an OOP language. It also has a doc explaining how it works. It interprets to machine code, so it may be more complex than we need right now, but of the bunch it will guide us the best.

Swift is also another promising source of inspiration, as it's written in C++.

V8 investigation notes
Interpretation:
They use the visitor pattern to read the AST (visiting each node) and turn each statement into Bytecode.
https://github.com/v8/v8/blob/master/src/interpreter/bytecode-generator.cc
After this stage they run an optimiser, which is not required for our project at the moment.
For testing, they interpret each statement type, and then compare the results to a series of expected bytecode mappings.
So it just makes sure that it translates it correctly.
Test file: https://github.com/v8/v8/blob/master/test/cctest/interpreter/test-bytecode-generator.cc
Expected bytecode mappings: https://github.com/v8/v8/blob/master/test/cctest/interpreter/bytecode_expectations/CountOperators.golden
Context is a tricky issue in V8, but that is due to the complexity of Javascript scoping abilities. We should not face the same problems.
Suggestions:

Write our tests the same way, except it try to interpret the code and get a result, rather than compare bytecode
Research the visitor pattern more, specifically how it applies to interpreters and ASTs

Swift investigation notes
Swift research was not fruitful. Looking at the git repo it was hard to figure out what was going on.
There are a couple of test folders, one marked "interpreter" spiked my interest.
https://github.com/apple/swift/tree/master/test/Interpreter
It seems that they've mixed testing into these files via comments, this means that they must be interpreted, otherwise there would be no way to run this with the added behaviour.
I believe it is evaluating the code, then checking it against the "CHECK" values in the comments. This is very close to the test implementation suggestion made in the V8 analysis.
There is a folder that seems to contain all the AST class type definitions.
https://github.com/apple/swift/tree/master/lib/AST
Hard to tell what's going on, I think they're creating objects that wrap the base data and ensure that it's valid. There are a lot of responsibilities mixed into the files, so it's hard to parse.
Suggestions:

Spend a lot more time reading the swift source code
Ask a question online to see if anyone is willing to explain it
Leave it as is, we know enough to get started

I think the Jasic interpreter is out next best bet.
https://github.com/munificent/jasic/blob/master/com/stuffwithstuff/Jasic.java
Once that's been reviewed, I suggest that we compile our suggestions into a single message, and close this issue.

Jasic investigation notes
Pretty simple, but it follows the same patterns we've seen in the other parsers/interpreters, albeit a little more condensed.
Tokenising/Lexing and Parsing are not baked together, they're two distinct steps. Tokenising just turns the code into a single array of tokens. Then the parser reads the tokens and creates the AST.
The interpreter execute functions directly within the AST objects, which is not standard practice.
Suggestions:

Don't need to split tokeniser and lexer just yet, PEG is handling this pretty well
Keep the AST and executor of the AST separate. Perhaps the visitor pattern.

Overall suggestions:

Model the ASTs explicitly
Create classes for each AST
Write tests for each interpreted AST. AST in, interpreted result out.
Try the visitor pattern, see how it works out

Closing issue

repo: domain-query-language/dql-server


text:
Ignore 3rd party libraries with a Filter

Hi,
I already asked this question on Stackoverflow  but didn't get an appropriate answer.
My solutions uses 3rd party components that are exposing Web API endpoints. I have no control about this library so my question is how to set up a filter to ignore this library. I don't want to include this in any doc.
Currently the following exception is thrown:
NotSupportedException: Ambiguous HTTP method for action - DevExpress.AspNetCore.Reporting.QueryBuilder.QueryBuilderController.Invoke (DevExpress.AspNetCore.Reporting.v18.2). Actions require an explicit HttpMethod binding for Swagger 2.0
Edit: I already tried to use an OperationFilter but was unsuccessful because Apply doesn't get called for the 3rd party lib.
Thanks
Sven

You can configure a custom “DocInclusionPredicate” (see readme) to filter out ApiDescriptions for actions in a given namespace

Thank you,
I got it working.
Regards
Sven


text:
[Bug]: Authentication problem with 6.6.2

Describe the bug
Upgrading from 6.50 to 6.6.2 caused our authentication system to stop working. We have a separate identity server using client credentials and with 6.6.2 we are always getting the error:

Reverting just Swashbuckle.AspNetCore back to 6.5.0 resolves the issue.
Our .AddSwaggerGen code:
                c.AddSecurityDefinition("Bearer", new OpenApiSecurityScheme
                {
                    Type = SecuritySchemeType.OAuth2,
                    Flows = new OpenApiOAuthFlows
                    {
                        ClientCredentials = new OpenApiOAuthFlow
                        {
                            TokenUrl = new Uri(Configuration["Identity:Authority"] + "/connect/token"),
                            Scopes = new Dictionary<string, string>
                            {
                                { "***.User", "" },
                                { "***.Admin", "" }
                            },
                            AuthorizationUrl = new Uri(Configuration["Identity:Authority"] + "/oauth2/authorize"),
                        }
                    }
                });
                c.AddSecurityRequirement(new OpenApiSecurityRequirement
                {
                    {
                        new OpenApiSecurityScheme
                        {
                            Reference = new OpenApiReference
                            {
                                Id = "Bearer",
                                Type = ReferenceType.SecurityScheme
                            }
                        },
                        new List<string>()
                    }
                });

            services.AddAuthentication(JwtBearerDefaults.AuthenticationScheme)
                .AddJwtBearer(o =>
                {
                    o.Authority = Configuration["Identity:Authority"];
                    o.RequireHttpsMetadata = bool.Parse(Configuration["Identity:RequireHttpsMetadata"]);
                    o.Audience = Configuration["Identity:Audience"];
                    o.TokenValidationParameters = new TokenValidationParameters { ValidateAudience = bool.Parse(Configuration["Identity:ValidateAudience"]) };
                });

            services.AddAuthorization(options =>
            {
                options.AddPolicy("***", policy => policy.RequireClaim("client_Role", "***", "***"));
                options.AddPolicy("***", policy => policy.RequireClaim("client_Role", "***"));
            });

In our UseSwaggerUI:
                C.UseRequestInterceptor("" +
                    "(req) => { if (req.url.endsWith('connect/token') && req.body)" +
                    " req.body += '&client_id=' + client_id.value + '&client_secret=' + client_secret.value; return req; }");

Expected behavior
No response
Actual behavior
No response
Steps to reproduce
No response
Exception(s) (if any)
No response
Swashbuckle.AspNetCore version
6.6.2
.NET Version
NET8
Anything else?
If there's any other information you need please let me know.

Is it possible for you to share what the rendered JavaScript in the HTML page looks like please?

Thank you hugely for helping. Here it is:
<script>
        /* Source: https://gist.github.com/lamberta/3768814
         * Parse a string function definition and return a function object. Does not use eval.
         * @param {string} str
         * @return {function}
         *
         * Example:
         *  var f = function (x, y) { return x * y; };
         *  var g = parseFunction(f.toString());
         *  g(33, 3); //=> 99
         */
        function parseFunction(str) {
            if (!str) return void (0);

            var fn_body_idx = str.indexOf('{'),
                fn_body = str.substring(fn_body_idx + 1, str.lastIndexOf('}')),
                fn_declare = str.substring(0, fn_body_idx),
                fn_params = fn_declare.substring(fn_declare.indexOf('(') + 1, fn_declare.lastIndexOf(')')),
                args = fn_params.split(',');

            args.push(fn_body);

            function Fn() {
                return Function.apply(this, args);
            }
            Fn.prototype = Function.prototype;

            return new Fn();
        }

        window.onload = function () {
            var configObject = JSON.parse('{"urls":[{"url":"/swagger/v1/swagger.json","name":"ICOM API v1"}],"deepLinking":false,"persistAuthorization":false,"displayOperationId":false,"defaultModelsExpandDepth":1,"defaultModelExpandDepth":1,"defaultModelRendering":"example","displayRequestDuration":false,"docExpansion":"list","showExtensions":false,"showCommonExtensions":false,"supportedSubmitMethods":["get","put","post","delete","options","head","patch","trace"],"tryItOutEnabled":false}');
            var oauthConfigObject = JSON.parse('{"scopeSeparator":" ","scopes":[],"useBasicAuthenticationWithAccessCodeGrant":false,"usePkceWithAuthorizationCodeGrant":false}');

            // Workaround for https://github.com/swagger-api/swagger-ui/issues/5945
            configObject.urls.forEach(function (item) {
                if (item.url.startsWith("http") || item.url.startsWith("/")) return;
                item.url = window.location.href.replace("index.html", item.url).split('#')[0];
            });

            // If validatorUrl is not explicitly provided, disable the feature by setting to null
            if (!configObject.hasOwnProperty("validatorUrl"))
                configObject.validatorUrl = null

            // If oauth2RedirectUrl isn't specified, use the built-in default
            if (!configObject.hasOwnProperty("oauth2RedirectUrl"))
                configObject.oauth2RedirectUrl = (new URL("oauth2-redirect.html", window.location.href)).href;

            // Apply mandatory parameters
            configObject.dom_id = "#swagger-ui";
            configObject.presets = [SwaggerUIBundle.presets.apis, SwaggerUIStandalonePreset];
            configObject.layout = "StandaloneLayout";

            // Parse and add interceptor functions
            var interceptors = JSON.parse('{"RequestInterceptorFunction":"(req) =\u003E { if (req.url.endsWith(\u0027connect/token\u0027) \u0026\u0026 req.body) req.body \u002B= \u0027\u0026client_id=\u0027 \u002B client_id.value \u002B \u0027\u0026client_secret=\u0027 \u002B client_secret.value; return req; }"}');
            if (interceptors.RequestInterceptorFunction)
                configObject.requestInterceptor = parseFunction(interceptors.RequestInterceptorFunction);
            if (interceptors.ResponseInterceptorFunction)
                configObject.responseInterceptor = parseFunction(interceptors.ResponseInterceptorFunction);

            // Begin Swagger UI call region

            const ui = SwaggerUIBundle(configObject);

            ui.initOAuth(oauthConfigObject);

            // End Swagger UI call region

            window.ui = ui
        }
    </script>

Thanks - it looks like the changes I made to use System.Text.Json to support native AoT have broken the rendering here:
var interceptors = JSON.parse('{"RequestInterceptorFunction":"(req) =\u003E { if (req.url.endsWith(\u0027connect/token\u0027) \u0026\u0026 req.body) req.body \u002B= \u0027\u0026client_id=\u0027 \u002B client_id.value \u002B \u0027\u0026client_secret=\u0027 \u002B client_secret.value; return req; }"}');

Really appreciate you for looking into it, than you. We'll stay on 6.5.0 as it's not problem to do so, I was just keeping our versions up to date.

I notice we don't seem to have any test coverage for this area, so that's something we'll also need to sort out when this is fixed.
To help validate my hunch on what the issue is, if you explicitly set the following as the value of SwaggerUIOptions.JsonSerializerOptions does your code work as expected again?
app.UseSwaggerUI(c =>
{
    // Your configuration, then:
    c.JsonSerializerOptions = new()
    {
        Converters = { new JsonStringEnumConverter(JsonNamingPolicy.CamelCase, false) },
        Encoder = JavaScriptEncoder.UnsafeRelaxedJsonEscaping,
        DefaultIgnoreCondition = JsonIgnoreCondition.WhenWritingNull,
        PropertyNamingPolicy = JsonNamingPolicy.CamelCase,
    };
});

I've found the reason for this issue and it both is and isn't our fault 😄
In swagger-ui-dist@v4.15.5, which is included with v6.5.0, the name of the HTML element highlighted in red below has an client_id, which is in the scope of the closure were the interceptor function runs:

<input id="client_id" type="text" data-name="clientId">

In swagger-ui-dist@5.17.10, which is included with v6.6.2, the element has a different ID of client_id_authorizationCode:
<input id="client_id_authorizationCode" type="text" data-name="clientId">

client_secret was similarly renamed to client_secret_authorizationCode.
If I change your interceptor function like below to use client_id_authorizationCode, then things work as expected:
c.UseRequestInterceptor(
    "" +
    "(req) => {" +
    "  if (req.url.endsWith('connect/token') && req.body) {" +
    "    req.body += '&client_id=' + client_id_authorizationCode.value + '&client_secret=' + client_secret_authorizationCode.value;" +
    "    return req;" +
    "  }" +
    "}");

So this is our fault in one way because we updated swagger-ui-dist to v5, but it also has two other contributing factors.
The first is that swagger-ui did some UI refactoring and renamed the page element. I don't know if this is considered part of their public API surface area or not, but at face value it looks like an implementation detail to me that isn't intended to be something that's relied on. If it is part of their public surface area and covered by the v5 breaking changes, this feels quite out of scope of the sort of things we should be expected to find/detect/react-to within the library.
We did test that there was nothing obviously breaking with the update from v4 to v5 and didn't find anything, which is why it seemed safe to include in v6.6 (rather than needing it be part of a v7 as it was a major update).
If it isn't part of their public API surface area, then in that case the second issue is that you depended on an implementation detail of Swagger UI to get the client ID in your interceptor function.
From looking at req in the Chrome Developer Tools, the JSON equivalent of the value appears to be something like this:
{
  "url":"/auth-server/connect/token",
  "method":"post",
  "headers":{"Accept":"application/json, text/plain, */*","Content-Type":"application/x-www-form-urlencoded","X-Requested-With":"XMLHttpRequest"},
"body":"grant_type=authorization_code&code=Skg5ZRCelpGhVkzSao1QGsdZno78PONgZikGhSt0KbA&client_id=test-id&client_secret=test-secret&redirect_uri=https%3A%2F%2Flocalhost%3A5001%2Fresource-server%2Fswagger%2Foauth2-redirect.html&code_verifier=xPn7nrFvaxiTu2Z2K1JcMtHNkWY3JW5KrJtaO3Toz3c"
}

The client ID and client secret appear to be already set, so I'm not sure why you need to set it.
I'm going to leave this issue open for now as I found a few things to tweak while investigating this, but for the original issue you need to either remove your interceptor (because the client ID and secret appear to be set anyway), or to use the new input values to access their values.

See #2942 for the changes I mentioned, otherwise I think this is now resolved from our perspective.

authors: kenwonders martincostello


text:
Emit same metrics that standard HTTP client emits

Hey! Thanks for a great extension. It looks very promising and I love that it give people an option to create multiple HTTP clients - for instance per vu. This unlock a way to test API protected by mTLS (each client has different cert).
When I gave this extension a try, I noticed that standard request metrics (http_req*) are not collected. For instance, when I run a sample k6 test with classic k6 HTTP client, I can see following output:

...while with the extension, you get only:

Would it be possible to collect those as well? As it is critical visibility piece for majority of perf test. Thanks!

Hi @mprokopjc
Thanks for your feedback. You should get a few more metrics if you run more than 1 req i.e:
./k6 run -u 250 -d 10s -q ./file-stream-upload.js

     ✓ check status is 200

     checks...............: 100.00% ✓ 117129       ✗ 0
     data_received........: 0 B     0 B/s
     data_sent............: 0 B     0 B/s
     http_req_duration....: avg=20.44ms min=223.18µs med=12.93ms max=1.38s p(90)=41.39ms p(95)=55.58ms
     http_reqs............: 116879  11671.351065/s
     iteration_duration...: avg=21.17ms min=311.78µs med=13.5ms  max=1.38s p(90)=43.01ms p(95)=57.71ms
     iterations...........: 117129  11696.315668/s
     vus..................: 250     min=250        max=250
     vus_max..............: 250     min=250        max=250

But indeed we are missing a lot of metrics, this is mentioned on the README and is due to a restriction on the fasthttp package which doesn't allow us to record these metrics.
I will try to work on this when I get some time, thanks!

authors: domsolutions mprokopjc


text:
Added NSCoding to OAuthSwiftCredential for easy storage in the Keychain.

SwiftKeychainWrapper, and other such keychain wrappers, allow for easily storing an retrieving NSCoding-compatible objects in the keychain. OAuthSwiftCredential could benefit from some NSCoding love.

Hi @harlanhaskins
I tried with the following code
NSKeyedArchiver.archiveRootObject(credential, toFile: path)

Thank you!

authors: dongri harlanhaskins

repo: dongri/OAuthSwift


text:
Added .tsx to use TypeScript icon for react.

In react/typescript projects using .tsx file extension, it does not use the TypeScript icon. A one line change fixes this. Love the atom package. It's one of my favs aside from this one little thing.

Hey thanks for doing this @lvstross! I don't use Atom any more so this package has kind of fallen to the side. Would you mind resolving the conflicts and I'll get it merged

Hey @donovanhiland , Thanks for getting back to this. Better late than never. 😄 I fixed the conflict. We should be good to go now.

Perfect, thanks!

authors: donovanhiland lvstross

repo: donovanhiland/atom-file-icons


text:
Update documentation for [Checkbox]

Description
Add source codes of checkbox samples and edited 'Props' to fit with the checkbox interface.
Images below are some screenshots of the edited storybook.
One thing I ask for you is to check if the type of onPress is correct.
I referred to the interface, but I'm not that familiar to typescript so I'm afraid that I've wrote wrong thing 😅

Related Issues
#57
Tests
No test
Checklist
Before you create this PR confirms that it meets all requirements listed below by checking the relevant checkboxes ([x]). This will ensure a smooth and quick review process.

[x] I read the Contributor Guide and followed the process outlined there for submitting PRs.
[x] Run yarn test or yarn test -u if you need to update snapshot.
[x] Run yarn lint
[x] I am willing to follow-up on review comments in a timely manner.

@2unbini
For your question, currently it is onPress but I think we should change this props to onCheck and deprecate the onPress. Good point!

Oh I missed that part! Thank you for letting me know :)

repo: dooboolab/dooboo-ui


text:
fix: add primitive ptr for method of Runtime.toValue

Problem
We use goja as script engine in our project, and there are many primitive-ptr data we need to handle, some behaviors in goja are unexpected, for example new(bool) should mean false, but actually it will be truth because of pointer is not zero.
Solution
I raise this PR, trying to resolve this situation, see the snippets below:
package main

import (
	"encoding/json"
	"fmt"
	"strings"

	"github.com/dop251/goja"
)

type UserInfo struct {
	ID    int64  `json:"id"`
	Name  string `json:"name"`
	Adult *bool  `json:"adult,omitempty"` // optional property, and it's a bool ptr
}

func main() {
	var userinfo UserInfo
	// set property 'adult' as false
	_ = json.NewDecoder(strings.NewReader(`{"id":1234,"name":"foobar","adult":false}`)).Decode(&userinfo)

	vm := goja.New()
	vm.SetFieldNameMapper(goja.UncapFieldNameMapper())
	vm.Set("session", map[string]interface{}{
		"user": &userinfo,
	})

	ret, _ := vm.RunString(`session.user.adult ? 'user is adult' : 'user is not adult'`)

	fmt.Println("result:", ret.Export())
	// BEFORE PR:
	// result: user is adult

	// AFTER PR:
	// result: user is not adult
}

Thanks for figuring out any problem in the PR. We like goja very much, it helps us a lot. 😀

Please see my comment here: https://github.com/dop251/goja/issues/392#issuecomment-1141051331
Basically, what you have here is similar to new Boolean(false) which is also a truthy value. You can convert it to a primitive value by using valueOf(), in your case session.user.adult.valueOf().

Please see my comment here: #392 (comment)
Basically, what you have here is similar to new Boolean(false) which is also a truthy value. You can convert it to a primitive value by using valueOf(), in your case session.user.adult.valueOf().

I tried session.user.adult.valueOf() ? 'user is adult' : 'user is not adult', it seems doesn't work. 😭

The following test passes for me:
func TestBoolPtr(t *testing.T) {
	type UserInfo struct {
		ID    int64  `json:"id"`
		Name  string `json:"name"`
		Adult *bool  `json:"adult,omitempty"` // optional property, and it's a bool ptr
	}

	var userinfo UserInfo
	// set property 'adult' as false
	_ = json.NewDecoder(strings.NewReader(`{"id":1234,"name":"foobar","adult":false}`)).Decode(&userinfo)

	vm := New()
	vm.SetFieldNameMapper(UncapFieldNameMapper())
	vm.Set("session", map[string]interface{}{
		"user": &userinfo,
	})

	ret, err := vm.RunString(`session.user.adult.valueOf() ? 'user is adult' : 'user is not adult'`)
	if err != nil {
		t.Fatal(err)
	}
	if exp := ret.Export(); exp != "user is not adult" {
		t.Fatal(ret)
	}
}

Please make sure you're using the latest version and if you are, provide a test case that fails.


text:
素材管理可否分为临时素材和永久素材

例如在upload_media 和 download_media 方法新增一个参数，以判断是临时素材还是永久素材，并根据此参数决定所请求的url

将会在近几日更新 :)

any update on this one?
also:
https://github.com/doraemonext/wechat-python-sdk/blob/develop/wechat_sdk/basic.py#L391
you check the extension by lower them, however at the end you call the ext dictionary without the action, this will cause KeyError
to be consistent, might move ext up and check by ' not in ext.keys()'

authors: DeoLeung KururuSouchou doraemonext

repo: doraemonext/wechat-python-sdk


text:
Unable to access email inside accessToken

I am unable to access email using accessToken
Steps I have done:

Set 'Add email to access token' rule from Auth0 dashboard:

function addEmailToAccessToken(user, context, callback) {
    var namespace = 'namespace';
    context.accessToken[namespace + 'email'] = user.email;
    return callback(null, user, context);
}

Set 'openid profile email' permission for API
Set environment variable to matching namespace:

os.environ["AUTH0_RULE_NAMESPACE"] = "namespace"

Sign out and sign back in from SPA frontend to renew accessToken

I have also tried adding  passing 'openid profile email' to route and Auth0 scopes to see if makes any difference at all. It didn't
auth.get_user still returns email=None
What am I doing wrong? Thanks in advance.

Auth0 does not allow arbitrary strings for the namespace, it expects a URL starting with http:// or https://.
This is a best practice enforced by auth0 servers, though not well documented.
That is the reason the library default is the url of this repo ;)
And btw, do not forget that namespace and "email" should be separated by "/" in the javascript function.

Thanks, got it. Let me try that.
Also i want to include user_metadata in the accessToken as well. I have created a rule already. Where should i start tweaking your package? I would be so glad if you can direct me a bit. Thanks in advance.

You do not need to tweak the package, as custom user models are supprted since PR https://github.com/dorinclisu/fastapi-auth0/pull/3
Assuming the metadata is just a string, this is how you would do it:
class CustomAuth0User(Auth0User):
    meta: Optional[str] = Field(None, alias='https://your_namespace/user_metadata')

auth = Auth0(domain=..., api_audience=..., auth0user_model=CustomAuth0User)

@app.get('/secure')
async def get_secure(user: CustomAuth0User = Security(auth.get_user)):
    ...

If it's a json, you should define a sub-model for the metadata accordingly.

Got it, thanks again. I have successfully included both email and the user metadata in accessToken.

authors: Alperen-Ozturk dorinclisu


text:
Scale UI elements up to better suit most uses

People often stand some distance away from the screen when they use the RFID app, and the text should be scaled up so that it can easily be viewed from a minor distance.

Seeing as the people are pleased with the current solution, and the newer option received absolutely no comments to indicate otherwise, this issue is a non-issue.

repo: dotkom/regme


text:
Running the help option from a command

Currently the tool supports running the help command like so:
dotnet run -- -?
However, I'd like the command itself to be able to invoke that help text so the following would have the same effect:
dotnet run --
This would mimic the nuget functionality:
dotnet nuget
dotnet nuget -?

Added ShowHelp, IsEmptyCommand and ShowValues extension methods to InvocationContext. You can now manually show
help in command class Run or RunAsync method, for example if a sub-command represents a group and not an action,
you can show help. If Run or RunAsync method is missing in command class, then by default it will show help
(analyzer warning DMCLI24 is disabled). ShowValues is useful for testing a command, it shows parsed values for
current command and its arguments and options.
See below example, root command does not have a handler method so it will always show help
and sub-command will show help if command is specified without any arguments or option,
and it will show (dump) values if not:
[CliCommand(Description = "A root cli command")]
public class HelpCliCommand
{
    [CliOption(Description = "Description for Option1")]
    public string Option1 { get; set; } = "DefaultForOption1";

    [CliArgument(Description = "Description for Argument1")]
    public string Argument1 { get; set; } = "DefaultForArgument1";

    [CliCommand(Description = "A sub cli command")]
    public class SubCliCommand
    {
        [CliArgument(Description = "Description for Argument2")]
        public string Argument2 { get; set; } = "DefaultForArgument2";

        public void Run(InvocationContext context)
        {
            if (context.IsEmptyCommand())
                context.ShowHelp();
            else
                context.ShowValues();
        }
    }
}

This works perfectly. Thanks!

authors: calacayir mikecole

repo: dotmake-build/command-line


text:
share gcloud image centrally for CI

Currently we are copying:

Dockerfile.gcloud
scripts/gcloud_auth_wrapper.sh
into each of the repos that need access to gcloud and kubectl

We should re-factor this into a separate repo (perhaps ci-tools) and share this in the form of a container pushed to quay...
The scripts/gcloud_docker.sh can be copied because it just saved some docker run voodoo

this is done and the gcloud image is part of the ops repo

repo: dotmesh-io/dotmesh


text:
For preview7 need to update RCL static asset path

RCL are changed in preview7 https://github.com/aspnet/AspNetCore.Docs/pull/13501/files need to update index.html
    <script src="_content/Blazingpizza.ComponentsLibrary/localStorage.js"></script>     <script src="_content/Blazingpizza.ComponentsLibrary/deliveryMap.js"></script>     <script src="_content/Blazingpizza.ComponentsLibrary/leaflet/leaflet.js"></script>

@kaanlab Thanks! I was trying to figure out what went wrong.

Thanks for bringing this to our attention! The latest version of the workshop has these changes.

authors: EdCharbeneau danroth27 kaanlab

repo: dotnet-presentations/blazor-workshop


text:
IOptionsChangeTokenSource and IChangeToken

hi, I'm implement my own changable options, and I'm confusing about the IChangeToken now.
This questions is also related to  the IOptionsChangeTokenSource<T>,
The  IOptionsChangeTokenSource<T>.GetChangeToken()  return a IChangeToken ,  but it seems not all IChangeToken can fire event
https://github.com/aspnet/Extensions/blob/06dcb43bfb372585d3801cfc333a2d9ee9c189ea/src/Primitives/src/IChangeToken.cs#L18-L22
that said
 /// <summary>
 /// Indicates if this token will pro-actively raise callbacks. If <c>false</c>, the token consumer must
 /// poll <see cref="HasChanged" /> to detect changes.
 /// </summary>

 bool ActiveChangeCallbacks { get; }

and I read all the source code, but I can not find any method that handle ActiveChangeCallbacks=false  ,  so does that mean if my changetoken can not fire event, the IOptionMonitor<T> can not fire event too ?

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

ID: ed39cb0e-aa85-8bba-ffb4-859b56a60723
Version Independent ID: dc7e3449-650b-d117-5eac-69e5ccb250cb
Content: Options pattern in ASP.NET Core
Content Source: aspnetcore/fundamentals/configuration/options.md
Product: aspnet-core
Technology: aspnetcore-fundamentals
GitHub Login: @guardrex
Microsoft Alias: riande

Hello @John0King ... Fair question. We added "change notifications" only to the extent that they exist (and imply that they work for the scenarios covered by the topic when the framework needs to track changes in Options). Thus far, it's been considered an advanced scenario, and your question is the first of this nature since the topic was written.
I'd like to see about adding content and an example to cover this question. I don't know what that will look like at this time, and I can't answer your question simply because I haven't dug into the source or worked with Options beyond what we currently show.
Although I don't think that this will take very long to address, I don't think that January will be possible ... I'm 🏃😅 for at least January. February is possible. I recommend in the meantime that you ask on a support forum, such as Stack Overflow, and seek out examples on the Net for this scenario.
Leave this issue open. When I come up with something for this, I'll float it to engineering here. You'll get the ping on the discussion about it.

@John0King ... Unfortunately (as you can see :point_up:), I'm not finding the time to get to this issue. I'm 🏃😅 on priority Blazor issues as far as the :eye: can see.
@Rick-Anderson Does this one fall into the 'advanced scenarios' bucket for the community to discuss and dig into (e.g., blog about)? If so, then we can close. If you want it worked, it will need to go to someone on the docs team or one of the engineers for content.

This is out of the scope of the document.

authors: John0King Rick-Anderson guardrex


text:
DLL Not Found on Ubuntu (libClang is installed)

libClang is installed. both in version 14 and 15
gidcheen@Laptop:~$ ClangSharpPInvokeGenerator --version
ClangSharp P/Invoke Binding Generator version 15.0.0
Ubuntu clang version 15.0.6
Failed to resolve libClang or libClangSharp.
If you are running as a dotnet tool, you may need to manually copy the appropriate DLLs from NuGet due to limitations in the dotnet tool support.
Unhandled exception: System.DllNotFoundException: Unable to load shared library 'libClangSharp' or one of its dependencies. In order to help diagnose loading problems, consider setting the LD_DEBUG environment variable: liblibClangSharp: cannot open shared object file: No such file or directory
at ClangSharp.Interop.clangsharp.getVersion()
at ClangSharp.Program.Run(InvocationContext context) in /_/sources/ClangSharpPInvokeGenerator/Program.cs:line 269
at System.CommandLine.Handler.<>c__DisplayClass1_0`1.b__0(InvocationContext context)
at System.CommandLine.Invocation.AnonymousCommandHandler.<>c__DisplayClass2_0.<.ctor>g__Handle|0(InvocationContext context)
at System.CommandLine.Invocation.AnonymousCommandHandler.InvokeAsync(InvocationContext context)
at System.CommandLine.Invocation.InvocationPipeline.<>c__DisplayClass4_0.<b__0>d.MoveNext()
--- End of stack trace from previous location ---
at System.CommandLine.Builder.CommandLineBuilderExtensions.<>c__DisplayClass18_0.<b__0>d.MoveNext()
--- End of stack trace from previous location ---
at System.CommandLine.Builder.CommandLineBuilderExtensions.<>c__DisplayClass13_0.<b__0>d.MoveNext()
--- End of stack trace from previous location ---
at System.CommandLine.Builder.CommandLineBuilderExtensions.<>c__DisplayClass20_0.<b__0>d.MoveNext()
--- End of stack trace from previous location ---
at System.CommandLine.Builder.CommandLineBuilderExtensions.<>c.<b__19_0>d.MoveNext()
--- End of stack trace from previous location ---
at System.CommandLine.Builder.CommandLineBuilderExtensions.<>c__DisplayClass17_0.<b__0>d.MoveNext()
--- End of stack trace from previous location ---
at System.CommandLine.Builder.CommandLineBuilderExtensions.<>c.<b__6_0>d.MoveNext()
--- End of stack trace from previous location ---
at System.CommandLine.Builder.CommandLineBuilderExtensions.<>c__DisplayClass9_0.<b__0>d.MoveNext()

As covered in your other issue https://github.com/dotnet/ClangSharp/issues/422#issuecomment-1451854900
The error message explicitly states what's going on and provides a suggestion on how to resolve this
Specifically, it states:

"Failed to resolve libClang or libClangSharp."
"If you are running as a dotnet tool, you may need to manually copy the appropriate DLLs from NuGet due to limitations in the dotnet tool support."
"Unable to load shared library 'libClangSharp' or one of its dependencies. In order to help diagnose loading problems, consider setting the LD_DEBUG environment variable: liblibClangSharp: cannot open shared object file: No such file or directory"

This tells you, respectively:

There are two possible dependencies that may have failed
The most common source of the failure and how to fix it
Exactly which of the two dependencies caused this specific failure and suggests a way to get more diagnostic information

If there is a way to make this clearer, then suggestions and contributions are welcome. However, as is the error information does state all the required information, particularly when taken in coordination with the repo's README which gives explicit links to the relevant NuGet packages by name.

Im sorry but this is a stack trace. Your question of can it be made clearer is a quite obvious yes.

that should not happen after following the documented installation instructions
Copying dlls from some nuget is not a valid path to fix this on the user side. Its wild to me that trial and error copying of dlls to places is viewed as an appropriate step to resolve this.
Im not debugging issues on the applications side as a installation step. maybe to file a bug report but this cant be an expected user experience.

Im sorry but this is a stack trace

Only part of the output is a stack trace. The first 5 lines are regular tool output that exist specifically to surface the error, call out the most common source of the failure, and to list the possible fix.
The remaining lines are the stack trace which exists for diagnostic purposes. As a developer oriented and open source tool, listing the stack trace ensures that people can further diagnose the issue on their own if necessary and/or provide additional information to the maintainers if its something that they need assistance with.
A stack trace existing, particularly in a developer oriented tool, shouldn't be a reason for a user to completely ignore the output.

that should not happen after following the documented installation instructions

The issue here is on the end of the general dotnet tool support and there being a lack of functionality. There is not really anything that ClangSharp can do to improve this experience given that a NuGet package cannot be correctly packaged to provide only the required binaries for a given platform and that providing everything in a single package is untenable due to the package size being over the NuGet upload limits and unpacking to something that is over a gigabyte in size.
Notably the README could additionally call out the same note that the command line already does. Which is that on some platforms you may need to explicitly copy libClang and/or libClangSharp to a path where they can be resolved and to likewise refer to NuGet as a place where such binaries can be retrieved. PRs are welcome ;)

Copying dlls from some nuget is not a valid path to fix this on the user side. Its wild to me that trial and error copying of dlls to places is viewed as an appropriate step to resolve this.

There is no trial and error. It tells you exactly which dependency you need and which major version you need.
If you're on Ubuntu 20.04 you use https://www.nuget.org/packages/libClangSharp.runtime.ubuntu.20.04-x64. If you're on 22.04, you use https://www.nuget.org/packages/libClangSharp.runtime.ubuntu.22.04-x64
If you're on MacOS Arm64: https://www.nuget.org/packages/libClangSharp.runtime.osx-arm64
etc.

Im not debugging issues on the applications side as a installation step. maybe to file a bug report but this cant be an expected user experience.

You will see similar with many Linux based tools that aren't installed via the distro specific package manager and even then you may see some there as well due to conflicting dependencies or other issues.
An application should not go and download files from the internet itself without explicit user action. It could offer to do so, and require the user to consent via the command line, but many users have indicated that is a "worse experience" in the past and that they would prefer to explicitly control what native binaries are available on their box.
While it is indeed not ideal that the dependencies cannot be implicitly provided SxS, it is not entirely an application side issue. It is just as much a machine configuration issue due to it missing a required dependency.
It is not perfect and the process of interoperating between two languages, let alone parsing one language and generating compatible bindings for another, is incredibly error prone and complex. Using such a tool requires some level of effort on the consumer to minimally understand both C/C++ and C#, and to provide the necessary information for the tool to run correctly and generate the relevant bindings.
There is no magic "easy" button that will do it for you, because no two C headers work the same way. Resolving native dependencies, especially when very explicit instructions are given, should not be considered an insurmountable task.

This is an open source tool is being maintained by an single developer, in their free time. They do not get paid to work on it, it is not being sponsored by any companies, etc.
As such a free and open source tool, contributions are more than welcome to improve the experience as are suggestions if you find something lacking. However, such contributions and/or suggestions must be made in good faith and in a constructive manner.
Making statements along the lines of "this isn't good enough" is not constructive.
Opting to not read the console output that states the error and gives a possible solution is not constructive.
Not listening to maintainer guidance when the issue is explained in more detail including why it is the way it is today, particularly when they have explicitly stated that it is indeed non-ideal but that they don't have a good solution, is not constructive.

Command line output has been updated to make the callout on missing dependency more visible and to link to the GitHub repo.
README has been updated to further callout and elaborate on the dependency resolution issue and how users can pick the right package

authors: GideonUng tannergooding

repo: dotnet/ClangSharp


text:
Wrong version number in latest release? Starts with "3"

The releases page is a bit confusing https://github.com/dotnet/SqlClient/releases

Probably because it's  a .NET Framework version... Closing this issue.

@alex-jitbit we addressed a minor tagging issue. Thanks for bringing this up.  Can you check if you concern is addressed?

authors: JRahnama alex-jitbit

repo: dotnet/SqlClient


text:
Restrict custom messages only to when server is started.

By adding capability checks we now wont fire off custom messages to language servers that don't support them. Meaning, if our language server is in the midst of shutting down or spinning up no messages will go to it because there wont be a server with the corresponding capbilities yet.
We have to use the experimental capabilities bucket here because not all platforms maintain custom capabilities. For instance in Visual Studio scenarios it will deserialize serve capabilties into what it believes is "valid" and then will re-pass said server capabilities to our client side code having lost the information of the custom. To avoid this we use the experimental bag since it's part of the official LSP spec. This approach enables us to work with any client.

Fixes dotnet/aspnetcore#33193

Looks like you need to update some mocks.

Test failures were due to our flaky test. Got out a fix for it: https://github.com/dotnet/aspnetcore-tooling/pull/3703

authors: NTaylorMullen ryanbrandenburg

repo: dotnet/aspnetcore-tooling


text:
Peroblem

Problem encountered on https://dotnet.microsoft.com/learn/dotnet/hello-world-tutorial/install
Operating System: windows
Provide details about the problem you're experiencing. Include your operating system version, exact error message, code sample, and anything else that is relevant.

Please provide the requested information so we can understand the problem that you're having.

repo: dotnet/core


text:
User Story: Package authors can multi-target between runtime identifiers (RID)

Spec TBD

Currently multitargeting is supported via TargetFrameworks but not really for multiple RID's. In our own build, we have to do custom build gymnastics to achieve this.

The libraries team part here is representing our needs as we'd like to move over to this supported mechanism once it exists.

I think that adding a new first class concept to MSBuild, that of arbitrary build dimensions, would solve these 'we want to add yet another dimension' types of issues once and for all. A build dimension could be defined as a key value map: {foo:"bar", zoo:"roo"} {TargetFramework:"net472", RuntimeId:"win", Configuration="Debug", Architecture="x64"}. In MSBuild they could be expressed via regular items, or we could introduce new MSBuild expressions with well defined semantics. The engine could know about them to make it easier to specify multitargeting and whatnot. We could also borrow BuildXL's design of build dimensions

We should get an engineering owner assigned to this, like every P0 story. It can always change later. Is that you @marcpopMSFT or someone on your team?

My understanding is that the largest set of the work for this would be from NuGet so @aortiz-msft would probably be the M1 owner.

@aortiz-msft thoughts?

I think for this a decent amount of work needs to be done by MSBuild, NuGet and the SDK.

Yes, we discussed this in our Monday meeting last week, and this is not something we think we can deliver in NET 6.0. However, let's understand the customer feedback around this and start validating the problem and solution hypotheses.

As a head's up, the Extras supports this for the inner compile loop and building nuget packages:
https://github.com/novotnyllc/MSBuildSdkExtras#creating-per-runtimeidentifier-packages
It doesn't likely handle P2P references in an intelligent way.

I'm looking for a way to have multitargeting for different RIDs from a single class library project - including using the RID as a compile-time condition in the .csproj to reference RID-specific dependencies, like it is possible with TFMs now. This would not only enable building the correct binaries, but it would also allow for using the correct code at compile-time using #if rather than using runtime-checks like OperatingSystem.IsLinux().
My usecase would be to create a single NuGet package (class library) that has a windows-specific and a linux-specific implementation, which could be referenced through a common API surface in a consuming head project (abstracting away the platform differences). Depending on the publishing RID of the consuming head project, the nuget package for windows or linux would be restored. By using the RID as a condition in the .csproj file, additional platform-specific dependencies could be added.
Since there is no linux-specific TFM, I cannot multitarget a project in the usual way now.
See also https://github.com/dotnet/sdk/issues/27061
@terrajobst is this still targeted for the 7.x timeframe?

CC @baronfel for visibility. This is not in plans for a 7.0 release. A feature being discussed that might help here is TFM aliasing which would allow aliases to include the RID but that isn't officially planned yet.

Bulk closing .NET 6 epics and user stories. If you think this issue was closed in error, please reopen the issue and update it accordingly.

Please reopen this

Is this in the plan? This situation make me crazy.

@marcpopMSFT @baronfel @terrajobst please check if this should be reopened and if so, what release are we targeting this?

This should not be reopened as we are not planning on adding direct support for multi-targeting of RIDs. However, the nuget team is exploring TFM aliasing which would enable a form of this. The idea would be to enable the existing TFM multi-targeting to allow for RID information. It's still in design but potentially it'll end up with customers being able to multi-target "net8.0/win-x64;net8.0/win-arm64" (or something like that). We'd likely need some known aliases built into the SDK that set the RID when used but nuget would recognize those as two targets and allow restoring each separately. Customers could expand the aliasing beyond what's built in to support other scenarios we haven't thought of.
https://github.com/NuGet/Home/pull/12124

authors: ViktorHofer aortiz-msft cdmihai clairernovotny danmosemsft hansmbakker mairaw marcpopMSFT s1495k043 terrajobst


text:
Complete V7 admin status

The admin status file for V7 doesn't reflect the fact that we've finished V7.
We should update that. Ideally on the V7 standard branch, so that it matches the actual standard.

Fixed in #951

The table at https://www.ecma-international.org/task-groups/tc49-tg2/ currently shows "V7.0" under "Microsoft Visual C# Version". Will that be changed to "V7.3"? The "standard.docx" from #949 (comment) just says "C# Language Specification Version 7" without minor versions.

We'll need to take this up at the committee.  Pinging @jskeet to make sure it's on our agenda next meeting.

repo: dotnet/csharpstandard


text:
Self Contained Executable

We could use an example on running one of these examples as a self contained console app on linux.

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

ID: 9fa0c79e-1729-15f7-52e4-0c9afff43ec9
Version Independent ID: 1c3c5d30-9690-8c4a-4e2c-2ce5f4386898
Content: Get started with .NET Core using the CLI - .NET Core
Content Source: docs/core/tutorials/using-with-xplat-cli.md
Product: dotnet-core
Technology: dotnet-cli
GitHub Login: @cartermp
Microsoft Alias: mairaw

Sure. I think we can add the commands to the end of the tutorial to publish a self-contained deployment and a framework-dependent deployment (which is the new default for core 3.0)

As an interim, I've included publishing descriptions for the modes supported by .NET Core 2.1 which this article was written for. I'm going to file a new issue to track updating this article to 3.0 which would then include the self-contained executable publishing info.

authors: CodeSwimBikeRunner Thraka

repo: dotnet/docs


text:
[Samples:] C# source code contains multiple entry points

[Samples:] C# source code contains multiple entry points
In an (unspecified) number of case, legacy C# source code files contain multiple entry points. As a result, the source fails to compile. In each case, files are unnecessarily large and contain a large number of smaller examples.
One such example is https://github.com/dotnet/samples/blob/master/snippets/csharp/VS_Snippets_VBCSharp/csProgGuideDelegates/CS/Delegates.cs, although there are many others.
Optimally, these monolithic files should be divided into a number of smaller, standalone files with single entry points.
//cc @BillWagner @Thraka

Hi @rpetrusha / @mairaw
Just seen this up-for-grabs labeled work item, and kind of like it. Is there something I could do to help on the subject?
Meaning, I'd like your inputs on how-to proceed with it.
Do I just proceed with scanning the repositories and try to split large examples?

@rpetrusha has since retired.
But adding @Thraka and @BillWagner here who have been thinking about the CI aspect of our samples repo and how projects should be structured to best guide you.

@cillroy @rloutlaw This issue is a good example of how we need some good tooling around snippets/samples. It's hard to plan the impact of updating a large file like this, which has multiple snippets, and could be used by anything in the docs repo.

@nemrism Sorry for the long delay.... We did end up redesigning the samples/snippets repos. We moved them into this repo directly and in the newer https://github.com/dotnet/docs-desktop repo. If you're interested in the future at cleaning up and moving snippets around (they're still located in the root folder samples) you can follow the guidance in the contributor guide that details where they would be moved to: https://docs.microsoft.com/en-us/contribute/dotnet/dotnet-contribute#example-folder-structure

Thanks @adegeo
I'll have a look to this and will try to participate to the migration effort.
Have a great weekend

@adegeo could you help me understand how you refer to the new repo samples in the files of this one?

We don't use the samples repo anymore. All snippets being hosted in that repo were migrated into this repo under the samples/snippets folder. I just noticed the original post to the this thread listed the snippets file from the samples repo, I just edited it and pointed to where that file is located in this repo.
When updating them, you'll need to figure out what articles are referencing these, something like this powershell would do it:
Get-ChildItem *.md -r | Select-String "VS_Snippets_VBCSharp/csProgGuideDelegates/CS/Delegates.cs" -SimpleMatch | Select-Object Path -Unique

I get this output:
.\docs\csharp\programming-guide\delegates\delegates-with-named-vs-anonymous-methods.md
.\docs\csharp\programming-guide\delegates\how-to-combine-delegates-multicast-delegates.md
.\docs\csharp\programming-guide\delegates\how-to-declare-instantiate-and-use-a-delegate.…
.\docs\csharp\programming-guide\delegates\index.md
.\docs\csharp\programming-guide\delegates\using-delegates.md

These articles are in the same folder: .\docs\csharp\programming-guide\delegates\. From there you would:

Create a subfolder (if it didn't exist) named snippets
Create a subfolder named after each article for each article referencing the snippet, such as:
.\docs\csharp\programming-guide\delegates\delegates-with-named-vs-anonymous-methods\
.\docs\csharp\programming-guide\delegates\using-delegates\
and so on
You would normally create another subfolder named csharp in these individual article folders, but since these articles are related to the csharp programming-guide, and there aren't any other languages used, like VB.NET or F#; it's not required in this case.
Create a new csharp code project in the individual article folders, port the code for that article, make sure it compiles.
Update the references in the article from the old snippet to the new snippet you created/ported.
Once this is complete and no articles are referencing the the old samples/snippets/... code folder anymore, that old folder with the old code can be deleted.

Let's try with this 1st one.
Could you have a look @adegeo?

@adegeo my last one include CPP files, what kind of project file do you generate for these samples?

authors: Thraka adegeo mairaw nemrism rpetrusha


text:
Broken links

While trying to fix broken links (https://github.com/dotnet/docs/pull/1814), I encountered several that I couldn't fix. Either their targets should be fixed, or the links should be removed.

Additional Resources for Visual Basic Programmers links to http://msdn.microsoft.com/practices/default.aspx, which redirects to http://pnp.azurewebsites.net/, which errors out with "The specified CGI application encountered an error and the server terminated the process."

Two articles contain links to articles in https://docs.microsoft.com/visualstudio/data-tools/, which were deleted in https://github.com/Microsoft/visualstudio-docs/commit/c2afa3e2f52109eb01e47f1731a19f9f74810c6d. It seems these articles only exist in old versions of MSDN docs, but don't have any current version. Specifically:

Accessing data in Visual Basic applications links to:

creating-data-applications
overview-of-data-applications-in-visual-studio
connecting-to-data-in-visual-studio
fetching-data-into-your-application
editing-data-in-your-application

Nullable Value Types (Visual Basic) links to tableadapter-overview

COM Interoperability in .NET Framework Applications (Visual Basic) links to https://docs.microsoft.com/cpp/misc/com-interop-wrapper-error, which was deleted in https://github.com/Microsoft/cpp-docs/commit/3fa92896d (the article before deletion).

How to: Call a Web Service Asynchronously (Visual Basic) links to http://www.xmethods.net/, which seems to be down.

Side Note: I never got around to it over in the ASP.NET Core docs, but there were quite a few 301 redirects over there (e.g., http://twitter.com should be https://twitter.com). I haven't done the analysis over here for redirects. It's a separate issue perhaps, but I was just wondering if when you did your broken link analysis if you witnessed a lot of 301's as well?

@GuardRex Looking at it now, there seems to be a lot of 301s, starting with 23 of them just on the main page. And the vast majority of those are due to a missing trailing slash (e.g. https://docs.microsoft.com/en-us/dotnet/articles/core is 301 pointing to https://docs.microsoft.com/en-us/dotnet/articles/core/). Personally I don't think those are worth fixing.
Though I guess other redirects, like https://azure.microsoft.com/documentation/services/storage/, which is 301 pointing to https://docs.microsoft.com/en-us/azure/storage/ (with a 302 detour to https://azure.microsoft.com/en-us/documentation/services/storage/) might be worth it.
I haven't looked at redirects any further though.
In case you're interested, the code I used is here.

Personally I don't think those are worth fixing.

Roundtrips suck! lol :grinning: I'd fix all of them. I'm a bit of speed freak, so I don't like anything that slows anything down.

DotnetCoreDocsWalker

Ah ... that's very interesting. I use Xanu ... must be their :alien: influences :smile:, but I look forward to taking a closer look at your DotnetCoreDocsWalker.
@mairaw If you'd like an issue to fix 301's, let me know and I'll open one for it.

@GuardRex can't we use this issue for that? I personally prefer going straight to the topic avoiding 301 redirects, if possible.
@mikeblome are you guys deleting content without establishing 301 redirects for them in the VS docs?

Sure. I just didn't know if it was something you wanted to table for a later date.
Yes, indeed on 301's ... eee ... yuck! :grinning: ... and they have quite a few over in ASP.NET Core docs IIRC. I'll check both sets of docs and talk to Tom about the ones over there and report back here what I find out.

Yes, it could go to the backlog. I recently had to add all the pages where we missed the 301 redirects in our repo. They do run reports and open bugs for those internally and also on 404's (although I haven't seen a recent version of a 404 report).

I'm not aware of any deletions. +Mike and Kemp
Sent from Outlookhttp://aka.ms/weboutlook

From: Luke Latham notifications@github.com
Sent: Tuesday, March 28, 2017 2:32:31 PM
To: dotnet/docs
Cc: Michael Blome; Mention
Subject: Re: [dotnet/docs] Broken links (#1815)
Sure. I just didn't know if it was something you wanted to table for a later date.
Yes, indeed on 301's ... eee ... yuck! 😀 ... and they have quite a few over in ASP.NET Core docs IIRC. I'll check both sets of docs and talk to Tom about the ones over there and report back here what I find out.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHubhttps://github.com/dotnet/docs/issues/1815#issuecomment-289911414, or mute the threadhttps://github.com/notifications/unsubscribe-auth/AKFAb_CEo_0--phKMugTfxrM8-dlAXp7ks5rqXxvgaJpZM4Mr-fA.

@mikeblome this is the commit that @svick pointed to in the VS repo: https://github.com/Microsoft/visualstudio-docs/commit/c2afa3e2f52109eb01e47f1731a19f9f74810c6d
This broken a bunch of our links to the VS docs.

ah ok. darn. These topics were removed in CAPS last year, but we stashed them in NOT in TOC rather than Retired Contents as a hack to get around some CAPS issue. So they got migrated to docs. I'll create redirects.
Sent from Outlookhttp://aka.ms/weboutlook

From: Maira Wenzel notifications@github.com
Sent: Tuesday, March 28, 2017 2:39:11 PM
To: dotnet/docs
Cc: Michael Blome; Mention
Subject: Re: [dotnet/docs] Broken links (#1815)
@mikeblomehttps://github.com/mikeblome this is the commit that @svickhttps://github.com/svick pointed to in the VS repo: Microsoft/visualstudio-docs@c2afa3ehttps://github.com/Microsoft/visualstudio-docs/commit/c2afa3e2f52109eb01e47f1731a19f9f74810c6d
This broken a bunch of our links to the VS docs.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHubhttps://github.com/dotnet/docs/issues/1815#issuecomment-289913055, or mute the threadhttps://github.com/notifications/unsubscribe-auth/AKFAb_ySE5ZLrMDdItanL8hk_BvQHmMmks5rqX3_gaJpZM4Mr-fA.

Took a look. I see a bunch. To get an accurate count, I'd need to factor out the 301's for localization. However, a bunch jump right out (this is just a sample) ...
https://docs.microsoft.com/en-us/dotnet/articles/core/
http://asp.net/ :point_right: https://asp.net/
https://docs.microsoft.com/en-us/dotnet/articles/core/macos-prerequisites
http://brew.sh/ :point_right: https://brew.sh/
https://docs.microsoft.com/en-us/dotnet/articles/core/
http://creativecommons.org/licenses/by/4.0/ :point_right: https://creativecommons.org/licenses/by/4.0/
https://docs.microsoft.com/en-us/dotnet/articles/core/
http://dotnetfoundation.org/ :point_right: https://dotnetfoundation.org/
http://www.dotnetfoundation.org/blog/tsg-welcome
http://dotnetfoundation.org/blog/tsg-welcome :point_right: https://dotnetfoundation.org/blog/tsg-welcome
https://docs.microsoft.com/en-us/dotnet/articles/core/tutorials/using-on-macos
http://nuget.org/ :point_right: http://www.nuget.org/
Here's one in an author byline for Mr. Nate ...
https://docs.microsoft.com/en-us/dotnet/articles/core/tools/project-json-to-csproj
http://github.com/natemcmaster :point_right: https://github.com/natemcmaster
These look systemically broken ...
https://docs.microsoft.com/en-us/dotnet/articles/core/packages
http://docs.microsoft.com/dotnet/core/api/System.Reflection.Assembly :point_right: https://docs.microsoft.com/dotnet/core/api/System.Reflection.Assembly
... and it looks like there are dozens of those redirecting to the secure endpoint for the API docs.

I've opened PR #14192 to fix the redirections on the homepage.
I think most of the other redirections and broken links were already fixed throughout the years.
The only exception I found is the last bullet:

How to: Call a Web Service Asynchronously (Visual Basic) links to http://www.xmethods.net/, which seems to be down.

But I'd prefer if we open a separate issue for that alone so that we can decide what to do with that article. It requires an update rather than a simple link fix.
Sounds good @svick?

@mairaw Sounds good to me.

Ok, thanks @svick! Closing this one then and opened #14467 to take care of the remaining issue.

authors: GuardRex mairaw mikeblome svick


text:
Syntax highlighting for VB.Net

Could anyone fix syntax highlighting for VB.Net? It apparently handles comments (with ' symbol) incorrectly.

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

ID: 2beec841-2fc0-e46f-b3da-9c921b22d427
Version Independent ID: 988848ea-f798-3bec-aba0-a33e656ace82
Content: Collections - Visual Basic
Content Source: docs/visual-basic/programming-guide/concepts/collections.md
Product: dotnet-visualbasic
GitHub Login: @KathleenDollard
Microsoft Alias: kdollard

Pinging @DuncanmaMSFT

Hi 👋 @Finemechanic
Thank you so much for posting this issue. We really appreciate it. I'll work on getting this addressed.

@IEvangelist fwiw, I believe this is fixed in the upstream highlightjs library.

@IEvangelist David Pine FTE fwiw, I believe this is fixed in the upstream highlightjs library.

I'm well aware, thank you @Youssef1313.

@BillWagner @IEvangelist @gewarren This can be closed now. The highlighting was fixed.

authors: Finemechanic IEvangelist Youssef1313


text:
Page said to be updated for .NET 7, but shows same content as of .NET 6.

Hi.
The wiki page says it, together with the Microservices Architecture eBook, have been updated to reflect v7.0 of .NET. However, in the changelogs there is only v6.0. Also, when downloading the e-book, it's the same as previous version.

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

ID: 031b20ec-7583-8277-f7a6-69ff3beffeac
Version Independent ID: 58c0d74e-2a5d-297e-4770-e8e44878b683
Content: .NET Microservices. Architecture for Containerized .NET Applications
Content Source: docs/architecture/microservices/index.md
Product: dotnet-architecture
Technology: microservices
GitHub Login: @nishanil
Microsoft Alias: nanil

Interesting. I wonder if one of my commits got missed. I'll check it out ASAP.

@ardalis the changelog page is also not updated :)
https://github.com/dotnet-architecture/eShopOnContainers/wiki/Microservices-Architecture-eBook-changelog

authors: ardalis luizen


text:
Manifest file additions

It is written that you need to add the following:

Should "urn:schemas-microsoft.comn:compatibility.v1" not be "urn:schemas-microsoft.com:compatibility.v1"? Notice comn -> com.

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

ID: bd152f5c-fb08-0400-5aa5-d46afe1d0473
Version Independent ID: fe01fb3e-73bc-f90a-8862-719a440aa128
Content: High DPI support in Windows Forms
Content Source: docs/framework/winforms/high-dpi-support-in-windows-forms.md
Service: unspecified
Product: dotnet-framework
GitHub Login: @rpetrusha
Microsoft Alias: ronpet

For anyone reading this, note that the text of the above post contains XML that is hidden by GitHub formatting. It should read:

It is written that you need to add the following:
<compatibility xmlns="urn:schemas-microsoft.comn:compatibility.v1">
  <application>
    <!-- Windows 10 compatibility -->
    <supportedOS Id="{8e0f7a12-bfb3-4fe8-b9a5-48fd50a15a9a}" />
  </application>
</compatibility>

Should "urn:schemas-microsoft.comn:compatibility.v1" not be "urn:schemas-microsoft.com:compatibility.v1"? Notice comn -> com.

Thanks for pointing this out, @fvanheeswijk, and for responding with the formatted XML, @svick. "comn" is indeed incorrect. It's also an easy fix, so I'll open a PR to address this issue momentarily.

authors: fvanheeswijk rpetrusha svick


text:
Updated publishing getting started

Updated publishing getting started
Summary
The publishing feature was not implement in Visual Studio 2017 RC. The updates document it for Visual Studio 2017.
Fixes #1425
Suggested Reviewers
@mairaw @stevehoag @BillWagner

LGTM @rpetrusha

authors: BillWagner rpetrusha


text:
Add .NET Core app preprocessor symbols to the list

Adding the NETCOREAPPX_Y ones to the list.

Do we also support 2.0 values already?

@mairaw Yes :+1: I tested that. It works. I just held off because 2.0 hasn't shipped.

Do u want to go ahead and add that now? ..... one less thing to think about later?

@rpetrusha btw -- this can go anytime. It isn't tied to 2.0, and the topics where used are currently incorrect until this gets merged.

Thanks Ron ... I'll put up a 2.0 PR for this file shortly to add the new ones for 2.0.

authors: GuardRex mairaw


text:
Minor corrections on resilience page

Summary

Removed the circuit breaker from the example

Added options to make the retry timeout-aware
Updated the key accordingly

Added AddConcurrencyLimiter next to AddRateLimiter
Corrected AddHedging description

The original description described the parallel mode, but it can work in latency and fallback modes as well.

Corrected the number of attempts in case of retry
Replaced await ValueTask.CompletedTask to return default

Internal previews

📄 File
🔗 Preview link

docs/core/resilience/index.md
Introduction to resilient app development

@IEvangelist Hy Dave, can you please review it?

Shall I push a commit to change the csproj file?

Yes, please - thank you.

@IEvangelist Done :)

Hey @peter-csala - I'll monitor this one and update it next week when .NET 8.0 ships, that way we can just use the stable release.

Hey @peter-csala - I'll monitor this one and update it next week when .NET 8.0 ships, that way we can just use the stable release.

Thank you Sir ;)

authors: IEvangelist peter-csala


text:
Replaced fwlinks in csharp\programming-guide\concepts\async folder

Replaced fwlinks in csharp\programming-guide\concepts\async folder.
Remarks:

The handling-reentrancy-in-async-apps.md file has contained a crazy amount of the same link to msdn.microsoft.com/library/... All those were replaced with internal in-page links.
Please review index.md file more carefully: did I insert the links to uwp and previous-versions correctly? Or should I replace them with full links?

Related to #3424
General question on async intro page: what should be mentioned: 'Windows Runtime' or 'UWP'? Why do the columns with 'Windows Runtime' link to UWP API? At the same time the link to quickstart points to the page for  Windows 8.x developers. Definitely the questions are out of scope of this PR. However, if those questions make sense and there is inconsistency in the article, I'll create an issue to address it.
Suggested Reviewers
@mairaw please review

@mairaw does successful build mean that xref links work with uwp links? If yes, then I'll replace others.

@pkulikov nope the build had warnings which included the link I just changed, They told me I need to change some configuration in order for this to work. Let me try it.

I've opened #4393 to test the config needed.

@pkulikov I merged the change that enables the xref service for uwp apis. So now we can link to those with regular API links (xref links). Let me know if you wanna change those or if I should. Thanks!

@mairaw I've replaced /uwp/api links with corresponding xref links. Please review.

authors: mairaw pkulikov