New cmake modules commit breaks android build

Commit: 67e42c8a52ae631ad198f3da20ceb782fbb6f6bf
CMake fails to find the ASIO package when building from android. This may have been a case of the development machine already having the packages installed, such that find_package worked. On a fresh build, the find fails.

-- Looking for stddef.h - found
-- Check size of unsigned short
-- Check size of unsigned short - done
-- Using unsigned short
-- Check if the system is big endian - little endian
-- fastcdr library not found...
CMake Error at /usr/share/cmake-3.7/Modules/FindPackageHandleStandardArgs.cmake:138 (message):
  Could NOT find asio (missing: ASIO_INCLUDE_DIR)
Call Stack (most recent call first):
  /usr/share/cmake-3.7/Modules/FindPackageHandleStandardArgs.cmake:378 (_FPHSA_FAILURE_MESSAGE)
  cmake/modules/Findasio.cmake:7 (find_package_handle_standard_args)
  cmake/dev/eprosima_libraries.cmake:139 (find_package)
  CMakeLists.txt:195 (find_eprosima_thirdparty)

The cmake incantation in the Readme works for Linux, and my above incantation works for commit 5301ef203d45528a083821c3ba582164d782360b.

The following produces a successful build:
git clone https://github.com/eProsima/Fast-RTPS.git
cd Fast-RTPS
git reset --hard 4fcd335865ad426a223494f407736330ef94d365
git submodule update --init --recursive

export CMAKE_EXECUTABLE=$HOME/Android/Sdk/cmake/3.6.3155560/bin/cmake
export TOOLCHAIN_PATH=$HOME/android/android-ndk-r14/build/cmake/android.toolchain.cmake
export NDK_PATH=$HOME/Android/Sdk/ndk-bundle

mkdir build
cd build

${CMAKE_EXECUTABLE} ../ \
-DCMAKE_INSTALL_PREFIX=install \
-DCMAKE_TOOLCHAIN_FILE=${TOOLCHAIN_PATH} \
-DCMAKE_BUILD_TYPE=Release \
-DEPROSIMA_BUILD=ON \
-DANDROID_NDK=${NDK_PATH} \
-DANDROID_TOOLCHAIN_NAME=arm-linux-androideabi-clang \
-DANDROID_ABI=armeabi-v7a \
-DANDROID_NATIVE_API_LEVEL=android-21 \
-DANDROID_PLATFORM=android-21 \
-DANDROID_FUNCTION_LEVEL_LINKING=OFF \
-DANDROID_STL=gnustl_shared \
-DCOMPILE_EXAMPLES=OFF

make -j

Interestingly, fastcdr gets built for the wrong architecture when using the above:
readelf -h ./external/install/lib/libfastcdr.so
ELF Header:
  Magic:   7f 45 4c 46 02 01 01 00 00 00 00 00 00 00 00 00
  Class:                             ELF64
  Data:                              2's complement, little endian
  Version:                           1 (current)
  OS/ABI:                            UNIX - System V
  ABI Version:                       0
  Type:                              DYN (Shared object file)
  Machine:                           Advanced Micro Devices X86-64
  Version:                           0x1
  Entry point address:               0x53a0
  Start of program headers:          64 (bytes into file)
  Start of section headers:          87512 (bytes into file)
  Flags:                             0x0
  Size of this header:               64 (bytes)
  Size of program headers:           56 (bytes)
  Number of program headers:         6
  Size of section headers:           64 (bytes)
  Number of section headers:         30
  Section header string table index: 27

Building fastcdr on its own produces the correct information:
~/buildtest/Fast-RTPS/thirdparty/fastcdr/build$ readelf -h ./src/cpp/libfastcdr.so
ELF Header:
  Magic:   7f 45 4c 46 01 01 01 00 00 00 00 00 00 00 00 00
  Class:                             ELF32
  Data:                              2's complement, little endian
  Version:                           1 (current)
  OS/ABI:                            UNIX - System V
  ABI Version:                       0
  Type:                              DYN (Shared object file)
  Machine:                           ARM
  Version:                           0x1
  Entry point address:               0x0
  Start of program headers:          52 (bytes into file)
  Start of section headers:          676392 (bytes into file)
  Flags:                             0x5000200, Version5 EABI, soft-float ABI
  Size of this header:               52 (bytes)
  Size of program headers:           32 (bytes)
  Number of program headers:         8
  Size of section headers:           40 (bytes)
  Number of section headers:         40
  Section header string table index: 39

eProsima/Fast-RTPS@634f38f51561ad4a0c181d71fd2d5a75f499c103 and eProsima/Fast-RTPS@7c91865448e734355192809e97a94b426148574a should solve your problem. I could compile Fast-RTPS for Android.

Also now when FastRTPS compiles FastCDR, it pass all android options to FastCDR compilation.

Thanks @richiware, those commits sorted it out. I've added PR #81, which adds the rest of the variables listed at https://developer.android.com/ndk/guides/cmake.html, as well as the function level linking option that @esteve specified in his ROS2 Java build instructions. This was mainly to make sure that the ANDROID_STL option made its way through.
Additionally, I have written a short script that builds a distribution of FastRTPS for all of the Android ABIs listed on https://developer.android.com/ndk/guides/abis.html, except armeabi (some kind of build errors there). Do you think something like this might be useful to include somewhere as a guide for helping people get started on Android?
set -xe

git clone --recursive https://github.com/eProsima/Fast-RTPS.git
cd Fast-RTPS

# Set home dir
export DIR=$PWD

# Create dist directories
mkdir -p dist
mkdir -p dist/include
mkdir -p dist/lib

# Set tool paths
SDK_PATH=$HOME/Android/Sdk
NDK_PATH=$SDK_PATH/ndk-bundle
CMAKE_EXECUTABLE=$SDK_PATH/cmake/3.6.3155560/bin/cmake
TOOLCHAIN_PATH=$NDK_PATH/build/cmake/android.toolchain.cmake

# Declare ABIs to build for
declare -a arr=( "armeabi-v7a" "arm64-v8a" "x86" "x86_64" "mips" "mips64" )

for ABI in "${arr[@]}"
do
	# Create ABI specific cmake build dir
	mkdir -p build_${ABI}

	# Create ABI specific output directory
	mkdir -p $DIR/dist/lib/${ABI}/

	# Move into ABI specific build dir
	cd build_${ABI}

	# Build makefile
	${CMAKE_EXECUTABLE} \
	-DCMAKE_INSTALL_PREFIX=install \
	-DCMAKE_TOOLCHAIN_FILE=${TOOLCHAIN_PATH} \
	-DCMAKE_BUILD_TYPE=Release \
	-DANDROID_NDK=${NDK_PATH} \
	-DANDROID_TOOLCHAIN=clang \
	-DANDROID_ABI=${ABI} \
	-DANDROID_NATIVE_API_LEVEL=android-21 \
	-DANDROID_STL=gnustl_shared \
	-DCMAKE_CXX_FLAGS="-frtti -fexceptions" \
	-DTHIRDPARTY=ON \
	-DCOMPILE_EXAMPLES=OFF \
	${DIR}

	# Build and install
	make -j
	make install

	# Copy artifacts to
	cp install/lib/libfastrtps.so $DIR/dist/lib/${ABI}/
	cp external/install/lib/libfastcdr.so $DIR/dist/lib/${ABI}/

	# Move back to main directory
	cd $DIR
done

# Copy include folders
cp -r include/fastrtps dist/include
cp -r thirdparty/fastcdr/include/fastcdr dist/include

# Zip
FASTRTPS_HASH=$(git rev-parse --short HEAD)
zip -r libfastrtps_${FASTRTPS_HASH}.zip dist/*

Fixed in #22.


How to use the -t option?

-t TENX, --tenx TENX  10x links tab separated file, sorted by last columnls

I have 10X genomic data, but I did not know use to use this option. There are no manuals

Actually, SALSA does not use 10x links for scaffolding. It was supposed to be an experimental option. I will update the source to make it clear.
Sorry for the trouble.


IJulia looking for version 0.3 on version 0.4

I am trying to use IJulia on Ubuntu after deleting my .julia directory and installing Julia 0.4. I previously had Julia 0.3 installed. When I start ipython notebook --profile=julia, and begin a notebook, the kernel restarts, and I get the following errors. I have installed and built IJulia in Julia 0.4. From the errors below, it appears that IPython is looking for the old julia kernel, which I've since erased.
[I 15:35:30.121 NotebookApp] Creating new notebook in
/opt/anaconda/lib/python2.7/site-packages/IPython/kernel/manager.py:95: UserWarning: Setting kernel_cmd is deprecated, use kernel_spec to start different kernels.
  warnings.warn("Setting kernel_cmd is deprecated, use kernel_spec to "
[I 15:35:31.141 NotebookApp] Kernel started: c85d0ca0-3e8c-4158-8b90-595bae18f2b8
[W 15:35:31.157 NotebookApp] 404 GET /kernelspecs/julia-0.4/logo-64x64.png (<IP_ADDRESS>) 10.68ms referer=http://localhost:8999/notebooks/Untitled3.ipynb?kernel_name=julia-0.4
ERROR: could not open file /home/user/.julia/v0.3/IJulia/src/kernel.jl
 in include at ./boot.jl:261
 in include_from_node1 at ./loading.jl:304
 in process_options at ./client.jl:280
 in _start at ./client.jl:378
[I 15:35:34.143 NotebookApp] KernelRestarter: restarting kernel (1/5)
ERROR: could not open file /home/user/.julia/v0.3/IJulia/src/kernel.jl
 in include at ./boot.jl:261
 in include_from_node1 at ./loading.jl:304
 in process_options at ./client.jl:280
 in _start at ./client.jl:378
[I 15:35:37.154 NotebookApp] KernelRestarter: restarting kernel (2/5)
ERROR: could not open file /home/user/.julia/v0.3/IJulia/src/kernel.jl
 in include at ./boot.jl:261
 in include_from_node1 at ./loading.jl:304
 in process_options at ./client.jl:280
 in _start at ./client.jl:378
[I 15:35:40.164 NotebookApp] KernelRestarter: restarting kernel (3/5)
ERROR: could not open file /home/user/.julia/v0.3/IJulia/src/kernel.jl
 in include at ./boot.jl:261
 in include_from_node1 at ./loading.jl:304
 in process_options at ./client.jl:280
 in _start at ./client.jl:378
[W 15:35:41.163 NotebookApp] Timeout waiting for kernel_info reply from c85d0ca0-3e8c-4158-8b90-595bae18f2b8
[I 15:35:43.170 NotebookApp] KernelRestarter: restarting kernel (4/5)
WARNING:root:kernel c85d0ca0-3e8c-4158-8b90-595bae18f2b8 restarted
ERROR: could not open file /home/user/.julia/v0.3/IJulia/src/kernel.jl
 in include at ./boot.jl:261
 in include_from_node1 at ./loading.jl:304
 in process_options at ./client.jl:280
 in _start at ./client.jl:378
[W 15:35:46.182 NotebookApp] KernelRestarter: restart failed
[W 15:35:46.183 NotebookApp] Kernel c85d0ca0-3e8c-4158-8b90-595bae18f2b8 died, removing from map.
ERROR:root:kernel c85d0ca0-3e8c-4158-8b90-595bae18f2b8 restarted failed!
[W 15:35:46.202 NotebookApp] Kernel deleted before session
[W 15:35:46.203 NotebookApp] 410 DELETE /api/sessions/8c63f31f-3a3d-42af-829e-8895a6f57358 (<IP_ADDRESS>) 2.48ms referer=http://localhost:8999/notebooks/Untitled3.ipynb?kernel_name=julia-0.4

In the end, it does not find a kernel, as indicated in the errors above.

For the moment, putting a symbolic link from .julia/v0.3/IJulia to .julia/v0.4/IJulia works, but is clearly a terrible solution.

Don't use ipython notebook --profile=julia.   Just run ipython notebook.


redis.exceptions.RedisError: ZADD requires an equal number of values and scores

Hi,
I have started using REDIS recently for one of my applications development, I am stuck with this error from a long time, can someone please help me resolve this error?
I tried following other discussion threads online but none of them had any resolutions for this issue.

Exception in thread Thread-17:
Traceback (most recent call last):
File "/usr/lib/python3.7/threading.py", line 926, in _bootstrap_inner
self.run()
File "/usr/lib/python3.7/threading.py", line 870, in run
self._target(*self._args, **self._kwargs)
File "/usr/local/lib/python3.7/dist-packages/socketio/server.py", line 720, in _handle_event_internal
r = server._trigger_event(data[0], namespace, sid, *data[1:])
File "/usr/local/lib/python3.7/dist-packages/socketio/server.py", line 745, in _trigger_event
return self.handlers[namespace]event
File "/usr/local/lib/python3.7/dist-packages/flask_socketio/init.py", line 283, in _handler
*args)
File "/usr/local/lib/python3.7/dist-packages/flask_socketio/init.py", line 766, in _handle_event
ret = handler(*args)
File "/home/<path_to>/basic-redis-chat-app-demo-python/chat/socketio_signals.py", line 84, in io_on_message
utils.redis_client.zadd(room_key, {message_string: int(message["date"])})
File "/usr/local/lib/python3.7/dist-packages/redis/client.py", line 2315, in zadd
raise RedisError("ZADD requires an equal number of "
redis.exceptions.RedisError: ZADD requires an equal number of values and scores

Awaiting a solution, thanks in advance!

Turns out that I was using an older version of Redis python package hence the above error, on upgrading the Redis package the error is now resolved.


refactor(context): fix context performance

As discovered by @arahansen, in his own words:

Because React's new context API relies on object reference to determine when to re-render children, [gymnast context] would re-render on every render cycle because we were defining a new object value={{ ...context, ...this.state}}. This change moves the object spread outside of the component so that it can be accessed within the component lifecycle hooks.

React caveats

I have no idea what you're talking about @arahansen :wink:

:tada: This PR is included in version 16.0.1 :tada:
The release is available on:

npm package (@latest dist-tag)
GitHub release

Your semantic-release bot :package::rocket:


fix(useListNavigation): incorrect behaviour with RTL grid

Fixes #3115

Hi, thanks. Just looks like rtl needs to be added to CompositeProps

Hi, thanks. Just looks like rtl needs to be added to CompositeProps

I got mixed up and forgot to add the rtl parameter to the getGridNavigatedIndex function of Composite. I am also currently working on #3116, but I was planning to do an other PR for that. I can merge it with this one if you prefer.

I suppose another PR works


Clarify configuration for Caddyfile

It is not immediately obvious that tls is not a valid global directive, so let's clarify that

Thanks, but I think this is the wrong place to explain this. This module has nothing to do with how to use the Caddyfile; that's what the Caddyfile docs are for.

And the Caddyfile docs don't mention that the tls directive must be specified per website.
And tbh expecting everyone to read docs cover to cover (because a simple web page search sure as heck isn't finding me anything) is ridiculous. Hours of reading for 90% of  things you'll never use? Okay
Anyways whatever floats your boat


Really fix rendering CI this time, for real.

Actually fix the rendering CI issue.

Motivation
Turns out, recording the status code for set -e isn't particularly useful.

Current dependencies on/for this PR:

main

PR #51   👈

This comment was auto-generated by Graphite.


Context Menu not show after clone project

Context Menu options not show me after clone project and how to export diagram as image

Those must be custom implementations.

is it possible to send me this dots menu code send me


[#27] Fix background and border of right side Hangouts panel

Solves Issue #27
When you turn on right side Hangouts in the Advanced settings, it has an ugly blue color making the text unreadable (because it's transparent).
I set the background color of the Hangouts container explicitly to match the same as when it's on the left side. I also fixed the background color of a faux left border, previously also blue, a 1px width vertical line.

@boukestam  Rebased on latest master to fix conflicts


Sprite Tools - NRE with attachments when GameObject is destroyed

Describe the bug
In Sprite Tools, a NRE is thrown when the GameObject that the sprite is a component of is destroyed. The error seems to be related to the attachment points no longer existing.
This doesn't seem to cause any issues besides the error thrown.
// In OnAwake
Sprite.OnAnimationComplete += ( name ) =>
{
	if ( name == "death" )
		GameObject.Destroy();
};

void HitObjectOrTarget()
{
	_isDying = true;
	Sprite?.PlayAnimation( "death" );
}

2024/08/06 02:23:11.4613	[GameMenu] Exception when calling OnCollisionStart on Projectile on (Projectile): Object reference not set to an instance of an object.	System.NullReferenceException: Object reference not set to an instance of an object.
   at SpriteTools.SpriteAnimation.GetAttachmentPosition(String attachment, Int32 index) in C:\Users\Cameron\Desktop\Development\2D Platformer\2d_platformer\Libraries\facepunch.spritetools\Code\SpriteResource.cs:line 121
   at SpriteTools.SpriteComponent.GetAttachmentTransform(String attachmentName) in C:\Users\Cameron\Desktop\Development\2D Platformer\2d_platformer\Libraries\facepunch.spritetools\Code\SpriteComponent.cs:line 516
   at SpriteTools.SpriteComponent.UpdateAttachments() in C:\Users\Cameron\Desktop\Development\2D Platformer\2d_platformer\Libraries\facepunch.spritetools\Code\SpriteComponent.cs:line 424
   at SpriteTools.SpriteComponent.ApplyMaterialOffset() in C:\Users\Cameron\Desktop\Development\2D Platformer\2d_platformer\Libraries\facepunch.spritetools\Code\SpriteComponent.cs:line 447
   at SpriteTools.SpriteComponent.PlayAnimation(String animationName, Boolean force) in C:\Users\Cameron\Desktop\Development\2D Platformer\2d_platformer\Libraries\facepunch.spritetools\Code\SpriteComponent.cs:line 556
   at Platformer.Objects.Projectile.HitObjectOrTarget() in C:\Users\Cameron\Desktop\Development\2D Platformer\2d_platformer\Code\Objects\Projectile.cs:line 82
   at Platformer.Objects.Projectile.OnCollisionStart(Collision collision) in C:\Users\Cameron\Desktop\Development\2D Platformer\2d_platformer\Code\Objects\Projectile.cs:line 89
   at Sandbox.CollisionEventSystem.<>c__DisplayClass6_0.<OnPhysicsTouchStart>b__0(ICollisionListener x) in C:\build\_work\sbox\sbox\engine\Sandbox.Game\Scene\Components\Collider\CollisionEventSystem.cs:line 49
   at Sandbox.ComponentList.ForEach[T](String name, Boolean includeDisabled, Action`1 action) in C:\build\_work\sbox\sbox\engine\Sandbox.Game\Scene\GameObject\ComponentList.cs:line 285
2024/08/06 02:23:11.5272	[GameMenu] SpriteAnimationSystem.UpdateSpriteAnimation: One or more errors occurred. (Object reference not set to an instance of an object.)	System.NullReferenceException: Object reference not set to an instance of an object.
   at SpriteTools.SpriteAnimation.GetAttachmentPosition(String attachment, Int32 index) in C:\Users\Cameron\Desktop\Development\2D Platformer\2d_platformer\Libraries\facepunch.spritetools\Code\SpriteResource.cs:line 121
   at SpriteTools.SpriteComponent.GetAttachmentTransform(String attachmentName) in C:\Users\Cameron\Desktop\Development\2D Platformer\2d_platformer\Libraries\facepunch.spritetools\Code\SpriteComponent.cs:line 516
   at SpriteTools.SpriteComponent.UpdateAttachments() in C:\Users\Cameron\Desktop\Development\2D Platformer\2d_platformer\Libraries\facepunch.spritetools\Code\SpriteComponent.cs:line 424
   at SpriteTools.SpriteComponent.ApplyMaterialOffset() in C:\Users\Cameron\Desktop\Development\2D Platformer\2d_platformer\Libraries\facepunch.spritetools\Code\SpriteComponent.cs:line 447
   at SpriteTools.SpriteComponent.set_CurrentFrameIndex(Int32 value) in C:\Users\Cameron\Desktop\Development\2D Platformer\2d_platformer\Libraries\facepunch.spritetools\Code\SpriteComponent.cs:line 257
   at SpriteTools.SpriteComponent.UpdateSceneObject() in C:\Users\Cameron\Desktop\Development\2D Platformer\2d_platformer\Libraries\facepunch.spritetools\Code\SpriteComponent.cs:line 378
   at SpriteTools.SpriteAnimationSystem.<>c.<UpdateSpriteAnimation>b__1_0(SpriteComponent sprite) in C:\Users\Cameron\Desktop\Development\2D Platformer\2d_platformer\Libraries\facepunch.spritetools\Code\SpriteAnimationSystem.cs:line 22
   at System.Threading.Tasks.Parallel.<>c__DisplayClass19_0`1.<ForWorker>b__1(RangeWorker& currentWorker, Int32 timeout, Boolean& replicationDelegateYieldedBeforeCompletion)
--- End of stack trace from previous location ---
   at System.Threading.Tasks.Parallel.<>c__DisplayClass19_0`1.<ForWorker>b__1(RangeWorker& currentWorker, Int32 timeout, Boolean& replicationDelegateYieldedBeforeCompletion)
   at System.Threading.Tasks.TaskReplicator.Replica.Execute()
2024/08/06 02:23:11.5272	[GameMenu] SpriteAnimationSystem.UpdateSpriteAnimation: One or more errors occurred. (Object reference not set to an instance of an object.)	System.NullReferenceException: Object reference not set to an instance of an object.
   at SpriteTools.SpriteAnimation.GetAttachmentPosition(String attachment, Int32 index) in C:\Users\Cameron\Desktop\Development\2D Platformer\2d_platformer\Libraries\facepunch.spritetools\Code\SpriteResource.cs:line 121
   at SpriteTools.SpriteComponent.GetAttachmentTransform(String attachmentName) in C:\Users\Cameron\Desktop\Development\2D Platformer\2d_platformer\Libraries\facepunch.spritetools\Code\SpriteComponent.cs:line 516
   at SpriteTools.SpriteComponent.UpdateAttachments() in C:\Users\Cameron\Desktop\Development\2D Platformer\2d_platformer\Libraries\facepunch.spritetools\Code\SpriteComponent.cs:line 424
   at SpriteTools.SpriteComponent.ApplyMaterialOffset() in C:\Users\Cameron\Desktop\Development\2D Platformer\2d_platformer\Libraries\facepunch.spritetools\Code\SpriteComponent.cs:line 447
   at SpriteTools.SpriteComponent.set_CurrentFrameIndex(Int32 value) in C:\Users\Cameron\Desktop\Development\2D Platformer\2d_platformer\Libraries\facepunch.spritetools\Code\SpriteComponent.cs:line 257
   at SpriteTools.SpriteComponent.UpdateSceneObject() in C:\Users\Cameron\Desktop\Development\2D Platformer\2d_platformer\Libraries\facepunch.spritetools\Code\SpriteComponent.cs:line 378
   at SpriteTools.SpriteAnimationSystem.<>c.<UpdateSpriteAnimation>b__1_0(SpriteComponent sprite) in C:\Users\Cameron\Desktop\Development\2D Platformer\2d_platformer\Libraries\facepunch.spritetools\Code\SpriteAnimationSystem.cs:line 22
   at System.Threading.Tasks.Parallel.<>c__DisplayClass19_0`1.<ForWorker>b__1(RangeWorker& currentWorker, Int32 timeout, Boolean& replicationDelegateYieldedBeforeCompletion)
--- End of stack trace from previous location ---
   at System.Threading.Tasks.Parallel.<>c__DisplayClass19_0`1.<ForWorker>b__1(RangeWorker& currentWorker, Int32 timeout, Boolean& replicationDelegateYieldedBeforeCompletion)
   at System.Threading.Tasks.TaskReplicator.Replica.Execute()

To Reproduce

Create a sprite with attachment points enabled
Destroy the GameObject the sprite is a component of (not sure if relevant but the gameobject is being destroyed when OnAnimationCompleted is called

Expected behavior
Everything exactly the same but no NRE thrown. NRE is not thrown if attachment points are disabled.
Media/Files
No response
Additional context
No response

I believe I've since fixed this. Re-open the issue with a repro if this isn't the case.


[Feature request] Sleep then retry on TimeoutError

Whenever downloading a large version (e.g. x86_64 v4.8.6), I see a handful of timeouts for some files. It may be nice to have the script automatically retry (maybe up to 3 times or some reasonable amount?) whenever a timeout occurs.
('Connection aborted.', TimeoutError(10060, 'A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond', None, 10060, None))

Approximately how many timeouts did you get for this version? I have added the skipping part for this reason in order to re-download any files that timed out previously, but I'd consider retrying on timeout.
Did you notice if the file started downloading and timed out during download, or did the initial request for the file timeout? On the former case we have a big issue and we probably need to figure out a way to checksum the files in order to choose whether we need to re-download or not.

It seems resolved for me when applying this PR: https://github.com/silentbugs/hon-client-scraper/pull/8

Fixed with the merge of PR #8


As an organised SoC professor, I can remove Students from the database if they dropped a FYP that was under me

This is a duplicate issue of #21.


RFC 9018 compliance (cookie secret rollover)

Describe the bug
RFC 9018 further clarifies the DNS cookie feature introduced with RFC 7873. Unbound is capable of responding to downstream requests with a cookie via the answer-cookie and the cookie-secret option introduced with https://github.com/NLnetLabs/unbound/pull/762
There are further options like for the wait-limit (introduced with 1.20) that make use of Unbound's support of DNS cookies.
However, Unbound does not provide any way to perform a three stage rollover for updating the cookie secret as described in RFC 9018 Section 5.
Additional information
NSD provides the option to rotate the cookie secret via nsd-control arguments.
See:

add_cookie_secret
drop_cookie_secret
activate_cookie_secret

Having some configuration option like cookie-secret-staging that one can use to swap the active/staging secret for the 3 stage rollover might work as well.
On a minor notice, neither RFC 9018 nor 7873 are listed on Unbound's RFC compliance list.
Edit: I just noticed that cookie secret rollover was a todo in the PR that introduced its feature. However, after merging the PR about 1 year ago it looks like it was never picked up again. With more features (like wait-limit) introducing options that rely on downstream cookies, it might be worthwhile taking a look at the secret rollover aspect of DNS cookie usage.

The change adds the unbound-control commands, and the cookie-secret-file: "unbound_cookiesecrets.txt" option. It uses code taken from NSD. The merged code should create the functionality that works similar to how it works for NSD.


misc: remove session

Description of change
Remove session management code from auth, gateway and deployer since we do not use it.
How has this been tested? (if applicable)
By running the existing tests

Do we close #1288 due to this?

Do we close #1288 due to this?

Good point, done!


chore(main): release 0.3.3

:robot: I have created a release beep boop
0.3.3 (2023-11-12)
Bug Fixes

apply iframe-embed-fix only for iframe browse and embed (#24) (19b0a2f)

This PR was generated with Release Please. See documentation.

:robot: Release is at https://github.com/Annoto/playkit-plugin/releases/tag/0.3.3 :sunflower:


Feature Request: Limit Host Scheduling

Allow one to specify scheduling filters on the host. For instance, "only schedule containers with label foo=bar".
This could help several use cases:

Exclude hosts from scheduling - #7168 (effectively?)
A single env being across multiple DCs, but wanting affinities of certain services to certain DCs
Keeping services in proper legal jurisdictions
Dedicated hosts in environment (ie: "the DB servers" or whatnot)

As I said in IRC I think separate environments are the correct mechanism to do this.  Besides providing better isolation (different users can be given access, separate overlay network, etc) it already exists and gives you a very explicit separation.  Using labels to exclude or include from both directions will gives you separation you have to squint to find.  It will be very difficult for the user to tell what's going on and very easy to end up in situations where no hosts are eligible because you added a label the special host has but not the right one to let it be scheduled there.
To do multiple environments we basically just need to add functionality to make that setup usable... namely a way to link to a service across environment boundaries And have the container join the other overlay network.

It seems to me that this is the wrong approach. Would it not be better to introduce some other mechanism for better user controls?
An environment is designed to logical group servers together so that you can link services together and load balance services, etc ...
In this context, would it not be best to keep all servers whether it be cross cloud provider or in the same provider in the same Rancher environment?
For example, if I have 3 groupings of servers, application, management, services, but I want and need services across the 3 groupings to talk to each other, but control who can access what, I can't do this unless I follow your recommendation. :(
ITSM by using your recommendation to use environments for permission controls is ANTI Rancher.

Agree with @ekristen affinity labels on hosts level make sense in a lot of situation, for example you need to isolate where balancers (haproxy/traefic/..) need to run. Best approach is to have hosts just for this purpose and you don't want o to run anything else here. Right now you need to set affinity rule on all services to avoid this. Rule on hosts will be definitely better and more secure. How separate environment helps me with this ? If I place balancers to different environment I loose access to events from environment where services running, how balancer can work correctly then ?

+1 on this. I need to exclude a single host and this means updating all my compose files with scheduling labels. Not nice.

We already added this in 1.5 (and as I said it's caused a fair amount of confusion when used).  "Require container label" in edit host.

This is a great feature glad to see it in rancher!
I would argue the confusion is that Rancher does a very poor job of indicating why a service is not getting scheduled.
I recently ran into this while NOT using this feature.  I was in fact using the scheduling feature already built for a service to require a host with a specific label, and I did not have any hosts with that label. Therefore the services just sat there showing unhealthy and no containers. The service logs basically just said "everything was reconciled".

@vincent99 Thanks, missed it. It really does need some examples in docs, though.


add typer cli option

Codecov Report

Merging #16 (e31a92a) into main (4dc0c31) will decrease coverage by 88.89%.
The diff coverage is 0.00%.

:mega: This organization is not using Codecov’s GitHub App Integration. We recommend you install it so Codecov can continue to function properly for your repositories. Learn more
@@             Coverage Diff              @@
##              main      #16       +/-   ##
============================================
- Coverage   100.00%   11.11%   -88.89%
============================================
  Files            1        3        +2
  Lines            2       18       +16
  Branches         0        1        +1
============================================
  Hits             2        2
- Misses           0       16       +16

Flag
Coverage Δ

unittests
11.11% <0.00%> (-88.89%)
:arrow_down:

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

Impacted Files
Coverage Δ

pythontemplate/__main__.py
0.00% <0.00%> (ø)

pythontemplate/cli/main.py
0.00% <0.00%> (ø)

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.


Typo: "presenet" -> "present"

 Thank you for your submission, we really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.:x: forana sign nowYou have signed the CLA already but the status is still pending? Let us recheck it.

Good catch. Thanks for the contribution!


Utilising the "SpecifiedPickupDirectory" in the web.config ELMAH will not save emails to the specified folder

Steps that will reproduce the problem:
1. Add the following section to your web.config in place of any other similar section:
<system.net>
    <mailSettings>
        <smtp deliveryMethod="SpecifiedPickupDirectory"<EMAIL_ADDRESS>            <specifiedPickupDirectory pickupDirectoryLocation="C:\{Path}\App_Data\"/>
        </smtp>
    </mailSettings>
</system.net>

2. Trigger an exception that was previously being emailed by Elmah.
I would expect the email that I would have received to be saved in the location specified in the web.config. Instead, the error is logged but no email is saved. I have tried the App_Data path as well as a new directory in the root of my C:\ drive, both with no success. I have set up a simple email method separate from ELMAH and this does save a copy of the email message to the specified directory.

Originally reported on Google Code with ID 358
Reported by<EMAIL_ADDRESS>on 2014-04-08 08:23:55

It works for me as well


Adding a transaction issue with multiple accounts

When adding a transaction (and probably editing), when adding an extra (> 2) account, then removing it, it still sends null data to the API for that 3rd account that was removed.

insurance-sample.pdf


Gperf fails to compile

Gperf fails to compile with the final system clang [built by stage0 clang] ... g++ is a symlink to clang-15:
g++ -g -O2 -I. -I./../lib -c ./main.cc
g++ -g -O2  -o gperf version.o positions.o options.o keyword.o keyword-list.o input.o bool-array.o hash-table.o search.o output.o main.o ../lib/libgp.a
 -lm
ld: error: undefined symbol: operator new[](unsigned long)
>>> referenced by keyword.cc:81 (./keyword.cc:81)
>>>               keyword.o:(KeywordExt::init_selchars_low(Positions const&, unsigned int const*, unsigned int const*))
>>> referenced by input.cc:595 (./input.cc:595)
>>>               input.o:(Input::read_input())
>>> referenced by input.cc:605 (./input.cc:605)
>>>               input.o:(Input::read_input())
>>> referenced 31 more times

ld: error: undefined symbol: operator delete[](void*)
>>> referenced by keyword.cc:133 (./keyword.cc:133)
>>>               keyword.o:(KeywordExt::delete_selchars())
>>> referenced by input.cc:601 (./input.cc:601)
>>>               input.o:(Input::read_input())
>>> referenced by input.cc:611 (./input.cc:611)
>>>               input.o:(Input::read_input())
>>> referenced 29 more times

ld: error: undefined symbol: __cxa_pure_virtual                                                                                [13/288]
>>> referenced by keyword.cc
>>>               keyword.o:(vtable for Keyword_Factory)

ld: error: undefined symbol: vtable for __cxxabiv1::__class_type_info
>>> referenced by keyword.cc
>>>               keyword.o:(typeinfo for Keyword_Factory)
>>> referenced by output.cc
>>>               output.o:(typeinfo for Output_Constants)
>>> referenced by output.cc
>>>               output.o:(typeinfo for Output_Expr)
>>> referenced 1 more times
>>> the vtable symbol may be undefined because the class is missing its key function (see https://lld.llvm.org/missingkeyfunction)

ld: error: undefined symbol: operator new(unsigned long)
>>> referenced by keyword-list.cc:52 (./keyword-list.cc:52)
>>>               keyword-list.o:(copy_list(Keyword_List*))
>>> referenced by keyword-list.cc:52 (./keyword-list.cc:52)
>>>               keyword-list.o:(copy_list(KeywordExt_List*))
>>> referenced by input.cc:977 (./input.cc:977)
>>>               input.o:(Input::read_input())
>>> referenced 6 more times

ld: error: undefined symbol: operator delete(void*)
>>> referenced by keyword-list.cc:75 (./keyword-list.cc:75)
>>>               keyword-list.o:(delete_list(Keyword_List*))
>>> referenced by input.cc:977 (./input.cc:977)
>>>               input.o:(Input::read_input())
>>> referenced by search.cc:798 (./search.cc:798)
>>>               search.o:(Search::prepare_asso_values())
>>> referenced 17 more times

ld: error: undefined symbol: __gxx_personality_v0
>>> referenced by input.cc
>>>               input.o:(DW.ref.__gxx_personality_v0)

ld: error: undefined symbol: vtable for __cxxabiv1::__si_class_type_info
>>> referenced by output.cc
>>>               output.o:(typeinfo for Output_Defines)
>>> referenced by output.cc
>>>               output.o:(typeinfo for Output_Enum)
>>> referenced by output.cc
>>>               output.o:(typeinfo for Output_Expr1)
>>> referenced 4 more times
>>> the vtable symbol may be undefined because the class is missing its key function (see https://lld.llvm.org/missingkeyfunction)
clang-15: error: linker command failed with exit code 1 (use -v to see invocation)
make[1]: *** [Makefile:74: gperf] Error 1
make[1]: Leaving directory '/sources/gperf-3.1/src'
make: *** [Makefile:34: all] Error 2

But if I use the stage0 clang, no errors. Gperf compile fine

If I set LDFLAGS="-Wl,--verbose" for more output from LLD:
clang++ -lc++ -Wl,--verbose -o gperf version.o positions.o options.o keyword.o keyword-list.o input.o bool-array.o hash-table.o search.o output.o main.
o ../lib/libgp.a -lm
ld: /usr/bin/../lib/Scrt1.o
ld: /usr/bin/../lib/crti.o
ld: /usr/lib/clang/15.0.5/lib/x86_64-pc-linux-musl/clang_rt.crtbegin.o
ld: /usr/bin/../lib/libc++.so
ld: version.o
ld: positions.o
ld: options.o
ld: keyword.o
ld: keyword-list.o
ld: input.o
ld: bool-array.o
ld: hash-table.o
ld: search.o
ld: output.o
ld: main.o
ld: ../lib/libgp.a
ld: /usr/bin/../lib/libm.a
ld: /usr/bin/../lib/libc++.so
ld: /usr/bin/../lib/libm.a
ld: /usr/lib/clang/15.0.5/lib/x86_64-pc-linux-musl/libclang_rt.builtins.a
ld: /usr/bin/../lib/libunwind.so
ld: /usr/bin/../lib/libc.so
ld: /usr/lib/clang/15.0.5/lib/x86_64-pc-linux-musl/libclang_rt.builtins.a
ld: /usr/bin/../lib/libunwind.so
ld: /usr/lib/clang/15.0.5/lib/x86_64-pc-linux-musl/clang_rt.crtend.o
ld: /usr/bin/../lib/crtn.o
ld: error: undefined symbol: __cxa_begin_catch
>>> referenced by options.cc                                                                                [43/85]
>>>               options.o:(__clang_call_terminate)

ld: error: undefined symbol: std::terminate()
>>> referenced by options.cc
>>>               options.o:(__clang_call_terminate)

ld: error: undefined symbol: __gxx_personality_v0
>>> referenced by options.cc
>>>               options.o:(DW.ref.__gxx_personality_v0)

ld: error: undefined symbol: operator new[](unsigned long)
>>> referenced by keyword.cc
>>>               keyword.o:(KeywordExt::init_selchars_low(Positions const&, unsigned int const*, unsigned int const*))
>>> referenced by input.cc
>>>               input.o:(Input::read_input())
>>> referenced by input.cc
>>>               input.o:(Input::read_input())
>>> referenced 26 more times

ld: error: undefined symbol: operator delete[](void*)
>>> referenced by keyword.cc
>>>               keyword.o:(KeywordExt::delete_selchars())
>>> referenced by input.cc
>>>               input.o:(Input::read_input())
>>> referenced by input.cc
>>>               input.o:(Input::read_input())
>>> referenced 29 more times

ld: error: undefined symbol: __cxa_pure_virtual
>>> referenced by keyword.cc
>>>               keyword.o:(vtable for Keyword_Factory)
>>> referenced by output.cc
>>>               output.o:(vtable for Output_Expr)
>>> referenced by output.cc
>>>               output.o:(vtable for Output_Constants)
>>> referenced 3 more times

ld: error: undefined symbol: vtable for __cxxabiv1::__class_type_info
>>> referenced by keyword.cc
>>>               keyword.o:(typeinfo for Keyword_Factory)
>>> referenced by output.cc
>>>               output.o:(typeinfo for Output_Constants)
>>> referenced by output.cc
>>>               output.o:(typeinfo for Output_Expr)
>>> referenced 1 more times
>>> the vtable symbol may be undefined because the class is missing its key function (see https://lld.llvm.org/missingkeyfunction)

ld: error: undefined symbol: operator new(unsigned long)
>>> referenced by keyword-list.cc
>>>               keyword-list.o:(copy_list(Keyword_List*))
>>> referenced by input.cc
>>>               input.o:(Input::read_input())
>>> referenced by search.cc
>>>               search.o:(Search::prepare_asso_values())
>>> referenced 5 more times

ld: error: undefined symbol: operator delete(void*)
>>> referenced by keyword-list.cc
>>>               keyword-list.o:(copy_list(Keyword_List*))
>>> referenced by keyword-list.cc
>>>               keyword-list.o:(delete_list(Keyword_List*))
>>> referenced by input.cc
>>>               input.o:(Input::read_input())
>>> referenced 17 more times

ld: error: undefined symbol: vtable for __cxxabiv1::__si_class_type_info
>>> referenced by output.cc
>>>               output.o:(typeinfo for Output_Defines)
>>> referenced by output.cc
>>>               output.o:(typeinfo for Output_Enum)
>>> referenced by output.cc
>>>               output.o:(typeinfo for Output_Expr1)
>>> referenced 4 more times
>>> the vtable symbol may be undefined because the class is missing its key function (see https://lld.llvm.org/missingkeyfunction)
clang-15: error: linker command failed with exit code 1 (use -v to see invocation)
make[1]: *** [Makefile:74: gperf] Error 1
make[1]: Leaving directory '/sources/gperf-3.1/src'
make: *** [Makefile:34: all] Error 2

Looks like OpenSSL also fails to build with final system clang, but compiles fine with stage0 clang

Looks like OpenSSL also fails to build with final system clang, but compiles fine with stage0 clang

I haven't studied about Clang in years (since 2021, the last time I contributed here), but maybe it's a question of linking?
I mean, by looking at the errors, it seems like that stage0 Clang may links to libraries that aren't available (visible, or in the library path) to final system Clang. Maybe I'm talking no sense, but I would check out the logs. Try to use -Wl,--verbose and -v in Clang and see if we get something more explainable. I'm working in another project here, so I can't test my hypothesis right now.

In any case, we could still be using alternatives that (may) build fine with Clang, such as LibreSSL and samurai.
By the way, talking about "alternatives", what about linking Shadow to OpenPAM (in BMLFS, in the case) instead of Linux-PAM? I didn't found many information about why most distributions link to Linux-PAM instead of OpenPAM (is it just a question of compatibility?), and it would be interesting to have OpenPAM as an alternative. I've tested it at Copacabana Linux, it compiles just fine in musl.

If I set LDFLAGS="-Wl,--verbose" for more output from LLD:
clang++ -lc++ -Wl,--verbose -o gperf version.o positions.o options.o keyword.o keyword-list.o input.o bool-array.o hash-table.o search.o output.o main.
o ../lib/libgp.a -lm
ld: /usr/bin/../lib/Scrt1.o
ld: /usr/bin/../lib/crti.o
ld: /usr/lib/clang/15.0.5/lib/x86_64-pc-linux-musl/clang_rt.crtbegin.o
ld: /usr/bin/../lib/libc++.so
ld: version.o
ld: positions.o
ld: options.o
ld: keyword.o
ld: keyword-list.o
ld: input.o
ld: bool-array.o
ld: hash-table.o
ld: search.o
ld: output.o
ld: main.o
ld: ../lib/libgp.a
ld: /usr/bin/../lib/libm.a
ld: /usr/bin/../lib/libc++.so
ld: /usr/bin/../lib/libm.a
ld: /usr/lib/clang/15.0.5/lib/x86_64-pc-linux-musl/libclang_rt.builtins.a
ld: /usr/bin/../lib/libunwind.so
ld: /usr/bin/../lib/libc.so
ld: /usr/lib/clang/15.0.5/lib/x86_64-pc-linux-musl/libclang_rt.builtins.a
ld: /usr/bin/../lib/libunwind.so
ld: /usr/lib/clang/15.0.5/lib/x86_64-pc-linux-musl/clang_rt.crtend.o
ld: /usr/bin/../lib/crtn.o
ld: error: undefined symbol: __cxa_begin_catch
>>> referenced by options.cc                                                                                [43/85]
>>>               options.o:(__clang_call_terminate)

ld: error: undefined symbol: std::terminate()
>>> referenced by options.cc
>>>               options.o:(__clang_call_terminate)

ld: error: undefined symbol: __gxx_personality_v0
>>> referenced by options.cc
>>>               options.o:(DW.ref.__gxx_personality_v0)

ld: error: undefined symbol: operator new[](unsigned long)
>>> referenced by keyword.cc
>>>               keyword.o:(KeywordExt::init_selchars_low(Positions const&, unsigned int const*, unsigned int const*))
>>> referenced by input.cc
>>>               input.o:(Input::read_input())
>>> referenced by input.cc
>>>               input.o:(Input::read_input())
>>> referenced 26 more times

ld: error: undefined symbol: operator delete[](void*)
>>> referenced by keyword.cc
>>>               keyword.o:(KeywordExt::delete_selchars())
>>> referenced by input.cc
>>>               input.o:(Input::read_input())
>>> referenced by input.cc
>>>               input.o:(Input::read_input())
>>> referenced 29 more times

ld: error: undefined symbol: __cxa_pure_virtual
>>> referenced by keyword.cc
>>>               keyword.o:(vtable for Keyword_Factory)
>>> referenced by output.cc
>>>               output.o:(vtable for Output_Expr)
>>> referenced by output.cc
>>>               output.o:(vtable for Output_Constants)
>>> referenced 3 more times

ld: error: undefined symbol: vtable for __cxxabiv1::__class_type_info
>>> referenced by keyword.cc
>>>               keyword.o:(typeinfo for Keyword_Factory)
>>> referenced by output.cc
>>>               output.o:(typeinfo for Output_Constants)
>>> referenced by output.cc
>>>               output.o:(typeinfo for Output_Expr)
>>> referenced 1 more times
>>> the vtable symbol may be undefined because the class is missing its key function (see https://lld.llvm.org/missingkeyfunction)

ld: error: undefined symbol: operator new(unsigned long)
>>> referenced by keyword-list.cc
>>>               keyword-list.o:(copy_list(Keyword_List*))
>>> referenced by input.cc
>>>               input.o:(Input::read_input())
>>> referenced by search.cc
>>>               search.o:(Search::prepare_asso_values())
>>> referenced 5 more times

ld: error: undefined symbol: operator delete(void*)
>>> referenced by keyword-list.cc
>>>               keyword-list.o:(copy_list(Keyword_List*))
>>> referenced by keyword-list.cc
>>>               keyword-list.o:(delete_list(Keyword_List*))
>>> referenced by input.cc
>>>               input.o:(Input::read_input())
>>> referenced 17 more times

ld: error: undefined symbol: vtable for __cxxabiv1::__si_class_type_info
>>> referenced by output.cc
>>>               output.o:(typeinfo for Output_Defines)
>>> referenced by output.cc
>>>               output.o:(typeinfo for Output_Enum)
>>> referenced by output.cc
>>>               output.o:(typeinfo for Output_Expr1)
>>> referenced 4 more times
>>> the vtable symbol may be undefined because the class is missing its key function (see https://lld.llvm.org/missingkeyfunction)
clang-15: error: linker command failed with exit code 1 (use -v to see invocation)
make[1]: *** [Makefile:74: gperf] Error 1
make[1]: Leaving directory '/sources/gperf-3.1/src'
make: *** [Makefile:34: all] Error 2

Oh, sorry, I didn't read that.

what about linking Shadow to OpenPAM

Yeah, i came across OpenPAM after discovering a blog hating on LinuxPAM. I didn't see why either.
Good to know it compiles on musl... just need to know what software is hard coded to use Linux PAM.
I've also looked into abandoning logind and dbus... For dbus, i think the alternative was dbus-broker and logind -> seatd. I use seatd. There are a few packages that are hardcoded for systemd/logind

Gperf fails to compile with the final system clang [built by stage0 clang] ... g++ is a symlink to clang-15:

I searched the error, and I found this StackOverflow question: https://stackoverflow.com/questions/27390078/gcc-compiling-c-code-undefined-reference-to-operator-newunsigned-long-lon
That gave me a clue that maybe the error is the symlink itself, take a look:

"gcc is the GCC compiler-driver for C programs, g++ is the one for C++ programs.
Both will guess the language on the basis of the file-extension, unless overridden.
But if you use the wrong driver, the default-options will be wrong, like leaving out the C++ standard-library for C++ programs compiled with gcc when linking."

I know this is about GCC, but the same logic applies to Clang: the clang program deals with C language files, clang++ deals with C++ language files. Maybe you need to remake the link from g++ to clang++ instead of clang-15 --- unless clang-15 have a case-switch that treats the argv[0] as an determinant to the compiler payload itself (in case, if argv[0] is equal to {g,clang}++, then compile the code as C++, if argv[0] is equal to {gcc,clang}, compile the code as standard C code, etc).
I hope this helps.

but maybe it's a question of linking?

Actually, I can't get stage1 clang to build stage2 (final system) clang... I had to use stage0 clang. It's like only stage0 clang works good while stage1 & stage2 are broken. If i try to build stage2 with stage1, stage1 cannot compile llvm-tblegen for some silly syntax error.... this issue closed by using a workaround.

Yeah, i came across OpenPAM after discovering a blog hating on LinuxPAM. I didn't see why either.

Good to know it compiles on musl... just need to know what software is hard coded to use Linux PAM.

Possibly the most pre-compiled binaries for musl-based distributions link to Linux-PAM only, so we would need to recompile everything if we wanted to use "software-Χ" that links to PAM on our system.
About code itself? I don't think there's anything Linux-PAM-specific on the API, both OpenPAM and Linux-PAM seem to be compatible in this sense. I think only the configuration files aren't interchangeable. I haven't studied a lot about OpenPAM and Linux-PAM, though.

I've also looked into abandoning logind and dbus... For dbus, i think the alternative was dbus-broker and logind -> seatd. I use seatd. There are a few packages that are hardcoded for systemd/logind

Nice to know! I will take my notes for those.

but maybe it's a question of linking?

Actually, I can't get stage1 clang to build stage2 (final system) clang... I had to use stage0 clang. It's like only stage0 clang works good while stage1 & stage2 are broken. If i try to build stage2 with stage1, stage1 cannot compile llvm-tblegen for some silly syntax error.... this issue closed by using a workaround.

Modern compilers are weird, really.

I know this is about GCC, but the same logic applies to Clang: the clang program deals with C language files,

Actually clang is a link to clang-15 and clang++ is a link to clang-15 ... clang-15 is the real binary. Its annoying as if i create a cfg file (like the spec file in gcc) to configure clang, it applies to BOTH clang & clang++

I know this is about GCC, but the same logic applies to Clang: the clang program deals with C language files,

Actually clang is a link to clang-15 and clang++ is a link to clang-15 ... clang-15 is the real binary. Its annoying as if i create a cfg file (like the spec file in gcc) to configure clang, it applies to BOTH clang & clang++

So my argv[0] hypothesis applies? Cool, I haven't even looked at the code yet.
Unfortunately, it seems like the final system Clang is indeed broken, but we don't seem to know why it is broken yet.

It can't be impossible to build a musl C library-based Linux system with Clang, Chimera Linux does it just fine.
Maybe we could take a look at how its toolchain is built?

it seems like the final system Clang is indeed broken

It really pissed me off when i saw the error. Took me forever to get stage0 clang to compile w/o errors. And even more to build stage1. I know OpenMandriva uses clang as a primary compiler...[or am i reading their git repos wrong?]  Hard to tell as their build recipes are terrible to read.

It can't be impossible to build a musl C library-based Linux system with Clang

I keep searching and it seems no one wants a build a system without GCC. I suppose the excuse is that LLVM's  libc++ is not complete like GNU's libstdc++.
My main reason I decided to design CMLFS was that libc++ had similar goals like of musl: "Correctness as defined by the C++11 standard." ... no shortcuts or hacks like in glibc or libstdc++ or GCC [i.e. gcc extensions]

I might create another branch with a different design for CMLFS: make the system toolchain removeable.
Maybe stage0 should be the system compiler and then it can be mounted/unpacked whenever a package needs to be built. I pretty much do that for my chromebook: My desktop builds packages that i install on my chrombeook as it has less compute power than my desktop. If i need, say, firefox, I have the desktop build it and then i install it to my chromebook. Saves my chromebook from heat and stress  so it can continue to have good battery life.

Chimera Linux does it just fine.
Maybe we could take a look at how its toolchain is built?

Good lead. I'll check that.

@takusuman, have you found an alternative for udisks? I can never figure out why udisksctl segfaults on some system builds and not on others. I use it to safely unplug USB storage devices by powering device off first.

it seems like the final system Clang is indeed broken

It really pissed me off when i saw the error. Took me forever to get stage0 clang to compile w/o errors. And even more to build stage1. I know OpenMandriva uses clang as a primary compiler...[or am i reading their git repos wrong?] Hard to tell as their build recipes are terrible to read.

Doesn't they use .spec-like recipes? I was reading some CentOS ones to fix bugs at Copacabana (although it's two pretty different distributions) and they were pretty readable to me.

I might create another branch with a different design for CMLFS: make the system toolchain removeable.
Maybe stage0 should be the system compiler and then it can be mounted/unpacked whenever a package needs to be built. I pretty much do that for my chromebook: My desktop builds packages that i install on my chrombeook as it has less compute power than my desktop. If i need, say, firefox, I have the desktop build it and then i install it to my chromebook. Saves my chromebook from heat and stress so it can continue to have good battery life.

I was doing something alike on Copacabana using pkgmap.txt files, which are just find . of the installed package itself. I've also separated the system between development and base system "stages", maybe this scheme could help.

@takusuman, have you found an alternative for udisks? I can never figure out why udisksctl segfaults on some system builds and not on others. I use it to safely unplug USB storage devices by powering device off first.

I haven't searched yet, but I'll be doing it.
If I find something promising, I'll come here and tell in an Issue for enhancement. Maybe FreeBSD got an alternative and we could try to port it?

I'll come here and tell in an Issue for enhancement.

Oh, no need to. I've found something called "Udevil", may it works.
https://ignorantguru.github.io/udevil/
I haven't tested it yet, though.

Coreutils [when compiled with stage2/final-system clang]:
make[2]: Entering directory '/sources/coreutils-9.1'
  CCLD     src/chroot
ld: error: undefined symbol: error
>>> referenced by chroot.c:361 (/sources/coreutils-9.1/src/chroot.c:361)
>>>               src/chroot.o:(main)
>>> referenced by chroot.c:430 (/sources/coreutils-9.1/src/chroot.c:430)
>>>               src/chroot.o:(main)
>>> referenced by chroot.c:279 (/sources/coreutils-9.1/src/chroot.c:279)
>>>               src/chroot.o:(main)
>>> referenced 9 more times
>>> did you mean: ferror
>>> defined in: /usr/bin/../lib/libc.so
clang-15: error: linker command failed with exit code 1 (use -v to see invocation)
make[2]: *** [Makefile:10367: src/chroot] Error 1
make[2]: Leaving directory '/sources/coreutils-9.1'
make[1]: *** [Makefile:21011: all-recursive] Error 1
make[1]: Leaving directory '/sources/coreutils-9.1'
make: *** [Makefile:8269: all] Error 2

Coreutils [when compiled with stage2/final-system clang]:
make[2]: Entering directory '/sources/coreutils-9.1'
  CCLD     src/chroot
ld: error: undefined symbol: error
>>> referenced by chroot.c:361 (/sources/coreutils-9.1/src/chroot.c:361)
>>>               src/chroot.o:(main)
>>> referenced by chroot.c:430 (/sources/coreutils-9.1/src/chroot.c:430)
>>>               src/chroot.o:(main)
>>> referenced by chroot.c:279 (/sources/coreutils-9.1/src/chroot.c:279)
>>>               src/chroot.o:(main)
>>> referenced 9 more times
>>> did you mean: ferror
>>> defined in: /usr/bin/../lib/libc.so
clang-15: error: linker command failed with exit code 1 (use -v to see invocation)
make[2]: *** [Makefile:10367: src/chroot] Error 1
make[2]: Leaving directory '/sources/coreutils-9.1'
make[1]: *** [Makefile:21011: all-recursive] Error 1
make[1]: Leaving directory '/sources/coreutils-9.1'
make: *** [Makefile:8269: all] Error 2

Same error with stage0 clang

That's caused because musl doesn't have error() --- and, for some reason, it seems like the error() function provided by Void Linux's compatibility headers is broken. The fix is to use a cache variable, ac_cv_lib_error_at_line defined as "no" when running configure.

That's caused because musl doesn't have error() --- and, for some reason, it seems like the error() function provided by Void Linux's compatibility headers is broken. The fix is to use a cache variable, ac_cv_lib_error_at_line defined as "no" when running configure.

YES! I can cross off coreutils!

YES!
The reaction that I had at first. 😄

If you want to say in the documentation, there is a clever (if I do say so myself) explanation to it:
After you install Void Linux's compatibility headers, you will have, in fact, an error() and error_at_line() function declarations at /usr/include/error.h, so when you run ./configure on any program that uses error() and/or error_at_line(), ./configure will identify that error()/error_at_line() are present on the system, so it will not use Gnulib's. The program itself will compile just fine, because the C preprocessor had found a declaration of these functions, so there's nothing to worry. The error itself will come when linking, because the symbols for those functions don't exist at libc.so.
A way to fix it would be to include these functions directly at musl-libc via a patch, having the declaration of the functions at error.h and the code definition for them on a C file that will be compiled to an object, but that would break the principle of being a "correctness as in POSIX standards C library", since error.h is a GNU C library extension.

After you install Void Linux's compatibility headers

Actually, I took you up on that offer from some time ago...and now i'm using those headers from https://github.com/Projeto-Pindorama/musl-compat ... it'll be easier to track any future changes.  Its also on my to-do list for my other repos

After you install Void Linux's compatibility headers

Actually, I took you up on that offer from some time ago...and now i'm using those headers from https://github.com/Projeto-Pindorama/musl-compat ... it'll be easier to track any future changes. Its also on my to-do list for my other repos

Yeah, but those were derived from Void Linux ones. I have to rework on it, since a Makefile would be a lot more practical than a Korn/GNU Shell script for installing.

Now that I think of it... i only used error.h to build libelf from elfutils.
I would simply copy the error.h to the elfutils source then compile and install libelf. Error.h never got installed.
I suppose installing error.h should be optional

Now that I think of it... i only used error.h to build libelf from elfutils.
I would simply copy the error.h to the elfutils source then compile and install libelf. Error.h never got installed.
I suppose installing error.h should be optional

Yeah, that's a good fix too.

groff fails to configure:
checking that C++ compiler can compile simple program... yes
checking that C++ static constructors and destructors are called... no
configure: error: a working C++ compiler is required

Check the config.log:
configure:18353: checking that C++ static constructors and destructors are called
configure:18385: clang++ -o conftest -g -O2   conftest.cpp  >&5
ld: error: undefined symbol: __cxa_begin_catch
>>> referenced by conftest.cpp
>>>               /tmp/conftest-0962e0.o:(__clang_call_terminate)

ld: error: undefined symbol: std::terminate()
>>> referenced by conftest.cpp
>>>               /tmp/conftest-0962e0.o:(__clang_call_terminate)

ld: error: undefined symbol: __gxx_personality_v0
>>> referenced by conftest.cpp
>>>               /tmp/conftest-0962e0.o:(DW.ref.__gxx_personality_v0)
clang-15: error: linker command failed with exit code 1 (use -v to see invocation)

But stage0 clang configures groff fine.

groff fails to configure:
[...]
But stage0 clang configures groff fine.

That's the same error that happened before, see:
# [...]
ld: error: undefined symbol: __cxa_begin_catch
# [...]
ld: error: undefined symbol: std::terminate()
# [...]
ld: error: undefined symbol: __gxx_personality_v0
# [...]

Indeed, the error is in the compiler and/or (yes, maybe simultaneously) in the C++ standard library, that defines these symbols --- maybe I'm mistaken, but C++ is basically, talking in a superficial manner, C with some symbols and data structures/types more, at least in the original definition.

@dslm4515 Have you seen the path where libraries are installed? I've searched a little bit more today, and I found this question at StackOverflow, the problem described looks like a lot one of the "undefined symbol" errors that you had.
He/she said that the problem was fixed by inserting the path where the C++ standard library was installed --- in the case, since his/her machine was running MacOS, it was /usr/lib, where the default system libraries are installed, like in any UNIX-compatible system --- so the linker could, finally, find the symbol definition.
If I were you, I would try to install LLVM (using a DESTDIR-like definition before gmake install) to a custom directory, and then see where the libraries are in fact installed with the current configuration (find is your best friend, try find . -type f -name "*.so*"). Maybe you've been misconfiguring it (by copying the same configuration that you've used at stage0 LLVM) all this time. That could be the only explanation (I think) of why stage0 LLVM works just fine while stage2 and stage3 struggle.

I also need to develop more tests to confirm the compiler works before finishing half the final system packages to realized its broken.
I can't find any runtime configuration for LLD.... is it because clang configures LLD at runtime?
I  scrapped my build and started over, using Chimera Linux's cports as a guide

I scrapped my build and started over, using Chimera Linux's cports as a guide

Great! I hope it works.
I can't go back to develop CMLFS right now because I'm working at Copacabana's build consolidation, but maybe I'll be moving it to LLVM and then contributing back with patches, like I did in Musl-LFS.

Maybe you've been misconfiguring it

For my current build, i only turned off only options to get the build to go.... i didnt turn off any extra options. Takes more space, but I'll see if stage1 clang is still broken.

So in my latest developmental branch bsd-userland, I used patches from Chimera Linux and changed the clang source to set the dynamic loader at /cgnutools/lib for stage0 clang and then to /llvmtools/lib for the stage1 clang. This removed the need to set the dynamic linker via a clang cfg (it causes static binaries to segfault).
Stage0 & stage1 clangs passed my custom tests ( header search order, atomics, C++ standard support ). Stage0 clang was built to provide libc++, libunwind, and compiler-rt that stage1 clang would build with... as it's assumed host will not have libc++ or libunwind or compiler-rt.  Stage0 and  stage1 clangs outputs binaries with the dynamic loader at /llvmtools/lib.
When building the final system packages, stage1 clang needs to change sysroot from /llvmtools to /usr. This is done with a cfg file:
cat >> /llvmtools/bin/$(uname -m)-pc-linux-musl.cfg << EOF
-nostdinc++
-I/llvmtools/include/c++/v1
-I/usr/include/c++/v1
-I/llvmtools/include
-I/usr/include
EOF

So far system packages are compiling. I get to Python. It wont link the openSSL libraries that I installed at /opt/openssl on the final system:
*** WARNING: renaming "_ssl" since importing it failed: Error relocating /sources/Python-3.11.1/build/lib.linux-x86_64-3.11/_ssl.cpython-311-x86_64-lin
ux-musl.so: OPENSSL_sk_num: symbol not found

The necessary bits to build these optional modules were not found:
_dbm                  _gdbm                 _hashlib
_tkinter              _uuid                 nis
To find the necessary bits, look in setup.py in detect_modules() for the module's name.

The following modules found by detect_modules() in setup.py have not
been built, they are *disabled* by configure:
_sqlite3

Following modules built successfully but were removed because they could not be imported:
_ssl

Could not build the ssl module!
Python requires a OpenSSL 1.1.1 or newer
Custom linker flags may require --with-openssl-rpath=auto

But if I do not use the cfg... just clang/clang++ , the ssl module can be imported.

Fixed it:
echo "-L/opt/openssl/lib" >> /llvmtools/bin/$(uname -m)-pc-linux-musl.cfg

Stage2 clang fails to compile:
builtins # 166 ............. PASS
unwind # 19 ................ PASS
cxxabi # 828 ............... PASS
cxx # 89 ................... PASS
compiler-rt # 14 ........... PASS
llvm-tblgen # 242 .......... PASS
lld # 1824 ................. FAIL

First block of error:
[1705/1824] Linking CXX shared library lib/libLLVM-15.so
ld.lld: error: relocation R_X86_64_PC32 cannot be used against symbol 'vtable for llvm::itanium_demangle::DotSuffix'; recompile with -fPIC
>>> defined in lib/libLLVMDemangle.a(ItaniumDemangle.cpp.o)
>>> referenced by ItaniumDemangle.cpp
>>>               ItaniumDemangle.cpp.o:(llvm::itanium_demangle::AbstractManglingParser<llvm::itanium_demangle::ManglingParser<(anonymous namespace)::D
efaultAllocator>, (anonymous namespace)::DefaultAllocator>::parse()) in archive lib/libLLVMDemangle.a

But to no surprise, CC=clang CXX=clang++ builds LLD without error. Same stage1 clang, just no configuration... using built-in configuration.
Could there be a problem with x86_64-pc-linux-musl.cfg ?

I adjusted the cfg more:
--sysroot=/usr
-nostdinc++
-nostdinc
-I/usr/include/c++/v1
-I/usr/include
-I/llvmtools/include/c++/v1
-I/llvmtools/include
-I/llvmtools/lib/clang/15.0.6/include
-L/usr/lib
-L/llvmtools/lib

and disabled the following compiler-rt options:
-DCOMPILER_RT_BUILD_SANITIZERS=OFF
-DCOMPILER_RT_BUILD_XRAY=OFF
-DCOMPILER_RT_BUILD_LIBFUZZER=OFF

But build still fails:
builtins # 166 ............. PASS
unwind # 19 ................ PASS
cxxabi # 828 ............... PASS
cxx # 89 ................... PASS
compiler-rt # 149 .......... PASS
llvm-tblgen # 242 .......... PASS
lld # 1824 ................. PASS
libclang # 798 ............. PASS
clang # 336 ................ PASS
remaining targets # 693 .... FAIL:

[20/678] Building CXX object tools/sancov/CMakeFiles/sancov.dir/sancov.cpp.o
ninja: job failed: /llvmtools/bin/x86_64-pc-linux-musl-clang++ -DHAVE_POSIX_REGEX -DHAVE_STD_REGEX -DHAVE_STEADY_CLOCK -D__STDC_CONSTANT_MACROS -D__STD
C_FORMAT_MACROS -D__STDC_LIMIT_MACROS -I/sources/llvm-project-15.0.6.src/build/third-party/benchmark/src -I/sources/llvm-project-15.0.6.src/third-party
/benchmark/src -I/sources/llvm-project-15.0.6.src/build/include -I/sources/llvm-project-15.0.6.src/llvm/include -I/sources/llvm-project-15.0.6.src/thir
d-party/benchmark/include -fPIC -stdlib=libc++ -fvisibility-inlines-hidden -Wall -Wextra -Wno-unused-parameter -Wwrite-strings -Wcast-qual -Wmissing-fi
eld-initializers -pedantic -Wno-long-long -Wno-noexcept-type -Wnon-virtual-dtor -Wdelete-non-virtual-dtor -Wsuggest-override -fdiagnostics-color  -std=
c++11  -Wall  -Wextra  -Wshadow  -Wsuggest-override  -pedantic  -pedantic-errors  -Wshorten-64-to-32  -fstrict-aliasing  -Wno-deprecated-declarations
-fno-exceptions  -Wstrict-aliasing  -Wthread-safety -O3 -DNDEBUG -std=c++14 -MD -MT third-party/benchmark/src/CMakeFiles/benchmark.dir/timers.cc.o -MF
third-party/benchmark/src/CMakeFiles/benchmark.dir/timers.cc.o.d -o third-party/benchmark/src/CMakeFiles/benchmark.dir/timers.cc.o -c /sources/llvm-pro
ject-15.0.6.src/third-party/benchmark/src/timers.cc
clang-15: warning: argument unused during compilation: '-stdlib=libc++' [-Wunused-command-line-argument]
In file included from /sources/llvm-project-15.0.6.src/third-party/benchmark/src/timers.cc:25:
/usr/include/fcntl.h:170:16: error: flexible array members are a C99 feature [-Werror,-Wc99-extensions]
        unsigned char f_handle[];
                      ^

Since commit 095f20913b2e0831b476cbba584beb5bed675686 Stage2 clang can now compile gperf with no errors!


On Selection of manual coupon code, Auto Generate Coupon Code section details should be hide.

Issue Reference
#6555

@papnoisanjeev
Not working, If the auto coupon code generates is YES the coupon code section is not visible. please find the screenshot Here

@Sanjaybhattwebkul
We can create or generate an auto coupon only after creating a cart rule (no use of providing a option while creating a cart rule.)  It will show only when you will edit the cart rule after creation.


Web-profiler

Hi,
Not understanding where the error is coming when tring to embed web-profiler.
Here is the error message :
```InvalidArgumentException in Pimple.php line 78: Identifier "security.authentication_providers" is not defined.````
And here is my code :
$app->register(new Silex\Provider\ServiceControllerServiceProvider());
if (isset($app['debug']) && $app['debug']) {
    $app->register(new Silex\Provider\HttpFragmentServiceProvider());
    $app->register(new Silex\Provider\WebProfilerServiceProvider(), array(
        'profiler.cache_dir' => __DIR__.'/../var/cache/profiler'
    ));

issues with the WebProfiler integration should be reported to the repo containing the webprofiler integration: https://github.com/silexphp/Silex-WebProfiler

Ha ok !


Chains is unable to sign images on Docker Hub

Expected Behavior
Chains is able to sign images on Docker Hub.
Actual Behavior
Chains is unable to sign images on Docker Hub while it works fine on GCR.
Steps to Reproduce the Problem
I followed the signed provenance tutorial so these steps are from there:

Install Tekton Chains
Set up authentication for the registry (namespace default) -kubectl create secret docker-registry registry-credentials --docker-server=docker.io --docker-username=$DOCKERHUB_USERNAME --docker-email=$DOCKERHUB_EMAIL --docker-password=$DOCKERHUB_PASSWORD`
kubectl patch serviceaccount default  -p "{\"imagePullSecrets\": [{\"name\": \"registry-credentials\"}]}" -n default

Generate a key paircosign generate-key-pair k8s://tekton-chains/signing-secrets

Configure authentication for the kaniko task:docker login (log in to Docker Hub)
kubectl create secret generic secret-docker-hub --from-file ~/.docker/config.json

Configure Tekton Chainskubectl patch configmap chains-config -n tekton-chains -p='{"data":{"artifacts.taskrun.format": "in-toto"}}'
kubectl patch configmap chains-config -n tekton-chains -p='{"data":{"artifacts.taskrun.storage": "oci"}}'
kubectl patch configmap chains-config -n tekton-chains -p='{"data":{"transparency.enabled": "true"}}'

Apply and start the kaniko taskkubectl apply -f https://raw.githubusercontent.com/tektoncd/chains/main/examples/kaniko/kaniko.yaml
tkn task start --param IMAGE=docker.io/<Docker Hub registry name>/kaniko-chains --use-param-defaults --workspace name=source,emptyDir="" --workspace name=dockerconfig,secret=secret-docker-hub kaniko-chains

Wait for the TaskRun to finish and for it to report that signing has failedkubectl get tr [TASKRUN_NAME] -o json | jq -r .metadata.annotations

Look for, "chains.tekton.dev/signed": "failed" in the annotations

Additional Info

Here is a relevant error from the tekton-chains-controller pod:
{"level":"error","ts":"2022-01-01T13:39:18.427Z","logger":"watcher","caller":"chains/signing.go:210","msg":"POST https://index.docker.io/v2/concaf/kaniko-chains/blobs/uploads/: UNAUTHORIZED: authentication required; [map[Action:pull Class: Name:concaf/kaniko-chains Type:repository] map[Action:push Class: Name:concaf/kaniko-chains Type:repository]]","commit":"0c28d26","knative.dev/controller":"github.com.tektoncd.chains.pkg.reconciler.taskrun.Reconciler","knative.dev/kind":"tekton.dev.TaskRun","knative.dev/traceid":"8b965ddc-4fd9-44db-9763-6ade25dd06c1","knative.dev/key":"default/kaniko-chains-run-k6wlb","stacktrace":"github.com/tektoncd/chains/pkg/chains.(*TaskRunSigner).SignTaskRun\n\tgithub.com/tektoncd/chains/pkg/chains/signing.go:210\ngithub.com/tektoncd/chains/pkg/reconciler/taskrun.(*Reconciler).FinalizeKind\n\tgithub.com/tektoncd/chains/pkg/reconciler/taskrun/taskrun.go:61\ngithub.com/tektoncd/chains/pkg/reconciler/taskrun.(*Reconciler).ReconcileKind\n\tgithub.com/tektoncd/chains/pkg/reconciler/taskrun/taskrun.go:42\ngithub.com/tektoncd/pipeline/pkg/client/injection/reconciler/pipeline/v1beta1/taskrun.(*reconcilerImpl).Reconcile\n\tgithub.com/tektoncd/pipeline@v0.27.1-0.20210830150214-8afd1563782d/pkg/client/injection/reconciler/pipeline/v1beta1/taskrun/reconciler.go:249\nknative.dev/pkg/controller.(*Impl).processNextWorkItem\n\tknative.dev/pkg@v0.0.0-20211123135150-787aec59e70a/controller/controller.go:542\nknative.dev/pkg/controller.(*Impl).RunContext.func3\n\tknative.dev/pkg@v0.0.0-20211123135150-787aec59e70a/controller/controller.go:478"}
I think the code that is failing is here - https://github.com/tektoncd/chains/blob/243e90b3736f2fa4daa013c38c1cefba254cf106/pkg/chains/storage/oci/oci.go#L188-L191
but I was not able to dig deeper since I don't understand it fully.
I suspect this might be related to https://github.com/sigstore/cosign/issues/587
Kubernetes version:

$ kubectl version
Client Version: version.Info{Major:"1", Minor:"23", GitVersion:"v1.23.1", GitCommit:"86ec240af8cbd1b60bcc4c03c20da9b98005b92e", GitTreeState:"clean", BuildDate:"2021-12-16T11:41:01Z", GoVersion:"go1.17.5", Compiler:"gc", Platform:"linux/amd64"}
Server Version: version.Info{Major:"1", Minor:"21", GitVersion:"v1.21.1", GitCommit:"5e58841cce77d4bc13713ad2b91fa0d961e69192", GitTreeState:"clean", BuildDate:"2021-05-21T23:01:33Z", GoVersion:"go1.16.4", Compiler:"gc", Platform:"linux/amd64"}
WARNING: version difference between client (1.23) and server (1.21) exceeds the supported minor version skew of +/-1

Tekton Pipeline version:

$ tkn version
Client version: dev
Pipeline version: v0.31.0

Docker version - 20.10.12

Hey @concaf thanks for opening this issue. It does seem really related to the cosign issue you linked. Just to make sure the config.json has the expected info, could you include what's in it with the sensitive information removed?

@priyawadhwa sure, this is how my ~/.docker/config.json looks like -
{
        "auths": {
                "https://index.docker.io/v1/": {
                        "auth": "redacted"
                }
        }
}

I even tried different variations of this per this comment - https://github.com/sigstore/cosign/issues/587#issuecomment-1003072134
{
        "auths": {
                "docker.io": {
                        "auth": "redacted"
                },
                "https://index.docker.io/v1/": {
                        "auth": "redacted"
                },
                "https://index.docker.io/v2/": {
                        "auth": "redacted"
                }
        }
}

but no luck.

Thanks @concaf for sharing that. I was able to get this to work by following the k8s docs here
to create the dockerconfig secret. It seems like the way suggested in the tutorial doesn't work for DockerHub!
When I used the originally suggested way, the base64 encoded secret actually looked like this:
$ kubectl create secret docker-registry registry-credentials-docker --docker-server=docker.io --docker-username=$DOCKERHUB_USERNAME --docker-email=$DOCKERHUB_EMAIL --docker-password=$DOCKERHUB_PASSWORD`

$ kubectl get secret registry-credentials-docker -o json | jq -r '.data.".dockerconfigjson"' | base64 --decode | jq
{
  "auths": {
    "docker.io": {
      "username": "priyawadhwa",
      "password": [redacted],
      "email":  [redacted],
      "auth":  [redacted]
    }
  }
}

which isn't the expected format.
Creating the secret as suggested in the docs resulted in the expected config.json format:
$ kubectl create secret generic regcred \
    --from-file=.dockerconfigjson=<path/to/.docker/config.json> \
    --type=kubernetes.io/dockerconfigjson

$ kubectl patch serviceaccount default  -p "{\"imagePullSecrets\": [{\"name\": \"regcred\"}]}" -n default

$ kubectl get secret regcred -o json | jq -r '.data.".dockerconfigjson"' | base64 --decode | jq
{
  "auths": {
    "https://index.docker.io/v1/": {
      "auth": "redacted"
    }
}

and I was able to verify the signature was uploaded with cosign! Let me know if that works for you, and if so then we can update the docs :)

Just looked up my stored secret, this is what I used to use, along with patching the relevant sa.
{
        "auths": {
                "https://index.docker.io/v1/": {
                        "auth": "redacted"
                }
        }
}

This doesn't seem to be working for me anymore :(
Went a version back, that works!
https://github.com/tektoncd/chains/issues/320

hey @sbose78 , if you try to create the secret the way I described in https://github.com/tektoncd/chains/issues/314#issuecomment-1005752385, does it still fail for you?

@priyawadhwa , yeah I did that without any success. I'm guessing there's a permission issue 🤔

@priyawadhwa just got some time to try this out and 🎉 yay 🎉, it worked per your comment https://github.com/tektoncd/chains/issues/314#issuecomment-1005752385, thank you! Will send a PR for the fix.
The docs that need to be updated are here, right? - https://github.com/tektoncd/chains/blob/main/docs/authentication.md

@sbose78 judging my the logs, #320 seems a bit different 🤔

Hey @concaf glad it's working! Yup, let's update the docs to in this section to include creating the secret for dockerhub :)

@sbose78 we can try and resolve the bug you opened in #320 since it seems unrelated!

/remove-lifecycle stale
working on this today


Add secret type credential to validation code

Change Overview
Add secret type credential to validation code.
Pull request type
Please check the type of change your PR introduces:

[ ] Work in Progress
[ ] Refactoring (no functional changes, no api changes)
[X] Trivial/Minor
[ ] Bugfix
[X] Feature
[ ] Documentation

Test Plan

[ ] Manual
[X] Unit test
[ ] E2E

Looks good to me @hakanmemisoglu ! Do we have a failure case for crv1alpha1.CredentialTypeKeyPair in TestProfileSchema() ?

@SupriyaKasten Let me add it.

@SupriyaKasten Let me add it.

Thanks 🚀


Error when no ".env" file is present

I get the following error when a .env file is not present, but the variables are still available in the environment:
{ Error: ENOENT: no such file or directory, open '.env'
    at Error (native)
    at Object.fs.openSync (fs.js:640:18)
    at Object.fs.readFileSync (fs.js:508:33)
    at Object.config (/pipeline/source/node_modules/dotenv/lib/main.js:30:37)
    at Object.config (/pipeline/source/node_modules/dotenv-safe/index.js:25:16)
    at Object.<anonymous> (/pipeline/source/webpack.config.js:1:86)
    at Module._compile (module.js:570:32)
    at Object.Module._extensions..js (module.js:579:10)
    at Module.load (module.js:487:32)
    at tryModuleLoad (module.js:446:12) errno: -2, code: 'ENOENT', syscall: &#Hash: 02f39e618514ebe1e2c2

The error does not block the build of the project from proceeding (i.e. fail with exit code != 1), but it is a bit misleading.
Setup:

Node v6.9.0
npm v3.10.8
macOS Sierra v10.12

Hi @devillex, thanks for reporting this. You could argue that this is a bug or not, but it's certainly an unusual situation. Do you have some context about how you ran into this? Usually when you are using dotenv or its variants, the expectation is to always have a .env file somewhere in your project. I can use that information to decide how to go about fixing this. Thanks!

Hi @rolodato. Sure, thanks for the prompt response!
I am using it with a React app that uses Firebase. I use it specifically during the CI (via wercker) build step with webpack to replace env variables in code as part of the bundling process.
Here is my webpack.config.js:
require('dotenv-safe').load(); // eslint-disable-line

const path = require('path');
const webpack = require('webpack');

module.exports = {
	entry: {
		app: [
			'babel-polyfill', // Adds ES6 built-ins like Promise and WeakMap
			'whatwg-fetch', // Adds 'fetch' polyfill
			path.join(__dirname, '/app/entry.js'), // app starts here
		],
	},
	output: {
		path: path.join(__dirname, '/build/js'),
		filename: '[name].bundle.js', // add this to the script tag
		publicPath: '/js/',
	},
	devtool: 'source-map',
	module: {
		loaders: [
			{ // pass js and jsx files through babel
				test: /\.jsx?$/,
				loader: 'babel-loader',
				exclude: /node_modules/,
				query: { presets: ['es2016', 'react', 'stage-0'] },
			},
			{ // import styles from 'styles.css'
				test: /\.css$/,
				loader: 'style!css?modules',
			},
		],
	},
	resolve: {
		root: path.resolve('./app'),
		extensions: ['', '.js', '.jsx'],
	},
	plugins: [
		new webpack.DefinePlugin({
			// this enables us to replace environment variables (see entry.js) in the code. The format is unfortunate,
			// but this is due to the string encoding
			'process.env': {
				// Firebase
				FIREBASE_API_KEY: `"${process.env.FIREBASE_API_KEY}"`,
				FIREBASE_AUTH_DOMAIN: `"${process.env.FIREBASE_AUTH_DOMAIN}"`,
				FIREBASE_DATABASE_URL: `"${process.env.FIREBASE_DATABASE_URL}"`,
				FIREBASE_STORAGE_BUCKET: `"${process.env.FIREBASE_STORAGE_BUCKET}"`,
			},
		}),
	],
};

Thanks, that use case makes sense. It'll be a while before I can make some time to fix this, but if you're up for a PR + tests I can certainly look into that.

I ran into this as well. I think it would be helpful to display an error message about the missing .env file but one that isn't the standard Node ENOENT error. Also I think the errors would be more effective without the noise of the stack traces.

Hi @ericf, for now I'm thinking that a missing .env file should not cause an ENOENT, so the ugly error message shouldn't be an issue. There will still be an error message when .env.example is not found which as of today is still a standard ENOENT, but we can take a look at that later.

When deploying my app, it doesn't contain an .env file, so it ends up logging the ENOENT error when that's actually the expected behavior since all of the environment variables already exist/exposed.
My use case is that .env is used for dev only. I ended up writing this script to help make less noisy error messages: https://github.com/ericf/timebox/blob/master/scripts/check-env but the ENOENT one still get logged and isn't captured by the try/catch.

@rolodato: I've submitted a PR that should resolve this issue. Please have a look when you get a chance.

Fixed and released 3.0.0. Thanks everyone and @devillex for the PR!


add flag for on/off pcmdi metrics

thanks @jservonnat

Just to provide a little bit more information on this issue: the idea is that we want to run custom metrics on given variables, without re-running the standard pcmdi metrics.
The solution is thus to add an attribute in the parameter file to control the calculation of:

the pcmdi metrics only
the custom metrics only
or both

wel lif you don't define custom_metric then it won't compute it, so there's no need to define a flag for this ;)

@doutriaux1 I've worked on this point and found a solution, created a branch and merged it to my master (jservonnat/PCMDI_metrics_IPSL). How do I send you a PR?

@jservonnat does the info available at https://github.com/PCMDI/pcmdi_metrics/wiki/Tip-for-Developers help you out here?

@durack1 Actually it did help for 95% of the procedure but I'm now stucked at the point where I would like to submit a pull request to the PCMDI devel branch. I've checked on my github webpage but didn't find the way to submit the PR to the PCMDI.
So apparently the last step is to "send the PCMDI repo administrator the fork and branch information you would like to merge" :). I guess our very own @doutriaux1 is the one!
Here is my branch:
https://github.com/jservonnat/PCMDI_metrics_IPSL/tree/issue219_flag_control_compute_custom_only
@doutriaux1, let me know if I'm on the good path or not.

@jservonnat did you fork the PCMDI/pcmdi_metrics repo originally? If so they should be linked and you can just select the PCMDI/pcmdi_metrics master to issue the pull request against..
https://github.com/jservonnat/PCMDI_metrics_IPSL/compare
Does that help?

@doutriaux1 forked the PCMDI/wgne_wgcm_metrics repo to set me up. But the PCMDI/pcmdi_metrics master does not appear in the list... Could it be linked with my status? I think I'm just contributer and not developer...

@jservonnat how many files have you changed? Unless @doutriaux1 has a better suggestion, you could just fork the pcmdi_metrics repo again and then add in your changes to that..

it should'nt matter. The fact is yes you cannot merge yourself but you can submit the PR

github "just knows" the repo name changed

@jservonnat can you see this?
https://github.com/PCMDI/pcmdi_metrics/compare/jservonnat:master...master

Guys, I think I get it!
The problem was that I was working from my own version of the sources, called PCMDI_metrics_IPSL (that was my origin). I made an other local repo from jservonnat/pcmdi_metrics and apparently I was able to submit the PR.
If yes, that's a big step :)!


Fullscreen game not focused at start

Godot version:
3.1.stable.official
OS/device including version:
Ubuntu 18.10
Issue description:
When launching a game fullscreen from the editor, it shows up fine, but it isn't in focus. I can click anywhere to bring it in focus. In 3D games this is annoying because you can't move around until you click.
Steps to reproduce:
Create a project using keyboard input, set to launch in full screen. Input is not accepted until the window is clicked.
Minimal reproduction project:
FullscreenTest.zip

This bug is from gnome, not godot, I had this problem too and it affected all the programs.
Gnome was fixed 3 days ago.: https://gitlab.gnome.org/GNOME/mutter/issues/505
Need to wait for Ubuntu to update.
For me it's already fixed, Tested with 5.0.5-arch1-1-ARCH, 40acc3ecdc4ca63040fec3ea30eead21523bade6


Upgraded grafana to 9.5.5

Chart version 6.57.4 installs 9.5.5 while the next higher 6.58.0 installs 10.X, therefore i cannot upgrade to 9.5.15, without major upgrade.
Closes https://github.com/united-manufacturing-hub/MgmtIssues/issues/1550

Given that 9.5.5 was released in 22. Jun 2023 and https://github.com/grafana/grafana/pull/64149#issuecomment-1471808501 was merged onto main in March it is safe to assume that the fix is included.

@Scarjit It might be worth it to trigger the full e2e test so that the grafana test runs, or should we just merge to staging, see what happens and then fix if needed?

@ricci2511 Sadly we have to push this to main and release it to be able to do a e2e on it


make enum values accept strings additionally

when trying to create a Kamelet (and probably in any other case where we have enums in a drop down box) I would like to put in a property placeholder but the drop down prevents that. I have to later on switch to the source view and add it there.

Same for boolean checkbox. Also see https://github.com/KaotoIO/kaoto-next/issues/494
Two options in my mind

Add a tiny button next to and say Use placeholder, once clicked it's turned into a text field
Always use editable dropdown for enum and boolean. Note that in this case boolean field is shown with text, true or false

I personally prefer No.1

Also take password field into account - https://github.com/KaotoIO/kaoto-next/issues/503

is shown with text, true or false
It could actually also be YES and NO. I think that option 2 is probably the more flexible approach.

One another thing is that once #494 is implemented, the enum field could get 2 set of dromdowns, 1 is for enum values and the other is for existing properties. Maybe switch by seeing if {{ is typed or not?


Neo 0.6.1: error in reading .abf file header (same as #302)

Hello,
I'm sorry, but I think I'm having the same issue as a user in a previous thread. I keep getting the following error:
File "/Users/matt/anaconda3/lib/python3.6/site-packages/neo/rawio/axonrawio.py", line 458, in parse_axon_soup
'This file does not contain clampex, axoscope or clampfit in the header'
AssertionError: This file does not contain clampex, axoscope or clampfit in the header
I checked the solution previously stated, however it appears in the latest version I downloaded on Monday (3.26.2018) that that had been fixed, e.g. in the latest version it says:
goodstart = -1
for key in [b'AXENGN', b'clampex', b'Clampex',
b'CLAMPEX', b'axoscope', b'Clampfit']:
goodstart = big_string.lower().find(key)
goodstart = big_string.find(key)
if goodstart != -1:
break
assert goodstart != -1,
'This file does not contain clampex, axoscope or clampfit in the header'
big_string = big_string[goodstart:]
strings = big_string.split(b'\x00')
Here is the .abf in the hopes it can be looked at.
https://drive.google.com/open?id=1CAXLYRNwLsg5vXIH8SABKod1TCrvwJK0
Thank you,
Matthew Clark

Thank you for report.
This is fix in  #513.
Could you try ?
You are unlucky we have just made a release.

looks like fix in #513 solves that issue but then I have error as stated in issue #219 https://github.com/NeuralEnsemble/python-neo/issues/219
A colleague suggested I try using python2.7 and it seems to be working as expected, so I guess I will use this solution for now.

What error do you still have ?
The #219  mention that read_segment do not work.
But it is not the case now.
Could you send message ?


[toast] support this.$error in SSR context

i have installed @nuxtjs/toast (nuxt version - 1.0.0-alpha.5) and i have exception, but only in terminal, on in browser, because ... full code here
export default {
  data () {
    console.log(this.$error) // function in browser console, undefined in terminal
    return {
      loading: 0
    }
  },
  apollo: {
    allCars: {
      query: gql`query {
        projects {
          name
        }
      }`,
      loadingKey: 'loading',
      error (error) {
        console.log(this.loading) // defined everywhere
        console.log(this.$error) // function in browser console, undefined in terminal
        console.log(error)
        // this.$error(error.message) // critical error here, but not in browser
      }
    }
  }
}

This feature request is available on Nuxt.js community (#c55)

Hi. The error section of apollo seems not a part of vue instance. Would you please what is exactly this inside console function?

its VueComponent
this.$error is undefined because ssr: false here
I think it can be handled with something like ... but it's weird
      error (error) {
        if (process.brower) {
          this.$error(error.message)
        } else {
          console.log(error.message)
        }
      }

But toasts are useless for SSR? We could redirect to console as an enhancement but the hard part is it should be removed from SSR bundle.

would like to see
or page can be rendered with toast notification (can it?)

That's a good idea too.We need somehow inject state into window.__NUXT and retrieve it after rehydration.

seems like work for https://github.com/ktsn/vuex-toast

thing is that I dont understand why with this config (with-apollo, old nuxt)
import Vue from 'vue'
import { ApolloClient, createNetworkInterface } from 'apollo-client'
import 'isomorphic-fetch'

// Created with Graphcool - https://www.graph.cool/
const API_ENDPOINT = 'https://api.graph.cool/simple/v1/cj1dqiyvqqnmj0113yuqamkuu'

const apolloClient = new ApolloClient({
  networkInterface: createNetworkInterface({
    uri: API_ENDPOINT,
    transportBatching: true
  })
})

export default apolloClient

application make only one request to api, on server side
and with my config (new nuxt)
import Vue from 'vue'
import VueApollo from 'vue-apollo'
import { ApolloClient, createNetworkInterface } from 'apollo-client'

Vue.use(VueApollo)

function createClient (ctx) {
  const { isDev, isClient } = ctx

  const networkInterface = createNetworkInterface({
    uri: `${process.env.API_URL}/graphql`,
    // uri: 'https://api.graph.cool/simple/v1/cj1dqiyvqqnmj0113yuqamkuu',
    transportBatching: true
  })

  return new ApolloClient({
    networkInterface,
    connectToDevTools: isDev && isClient,
    ssrMode: !isClient
  })
}

export default (ctx) => {
  const { app } = ctx

  if (!app.apolloProvider) {
    app.apolloProvider = new VueApollo({
      defaultClient: createClient(ctx)
    })
  }
}

application makes two requests to api, one - on page rendering on server side, and one in browser
and how to avoid this
P.S. I desperately need vue-apollo example with new nuxt :sob:

@BjornMelgaard We are working with @pi0 on making vue-apollo work with Nuxt 1.0 out of the box :)

I know, and I wish you all the best in your affairs, I love you guys!!!

some problem


KEYS.txt unclear regarding "Export Song" functionality

The key shortcut doesn't appear to produce any behavior. The documentation here is unclear how "export song" works.

Please check KEYS.TXT


Ease building by shipping specific LLVM version

This came up as I'm trying to building ponyc from source on Fedora 23, unfortunately, there are no particularly good packages with LLVM 3.7.1 (latest is 3.7.0, which doesn't build).
LLVM in general doesn't care too much about API and behaviour changes between even minor releases, and some projects just ship with the exact version they need, rather than having it as a general dependency. I know Rust is doing this, and a few other LLVM related projects I've worked with in the past did the same.
Any chance, that a specific LLVM could be incorporated into the build?

@saem how do they handle this across platforms?

@SeanTAllen just to make sure I understand what you're asking, ponyc wants to support a number of platforms (OSX, Linux, FreeBSD, Windows, etc...) and how do other projects (eg. Rust's compiler) support that? Moreover, this isn't referring to cross-compiling.
So taking a cursory look at the readme docs, they do support a number of platforms, and they're doing all the heavy lifting in their build system.
So looking inside the configure in rust, they build the LLVM triple, consisting of the arch, OS, and environment. That along with a number of other flags are put together, and then LLVM gets built. The specific version of LLVM is maintained as a git submodule referring to a fork in their case.
Apologies, if I missed something, it's been a long time, and even then I never dug particularly deeply into various build tools.

Building all of LLVM as a submodule is certainly possible, but building LLVM can take a long time (hours on a 32-bit ARM, for example). The ponyc approach is to support several LLVM versions: currently 3.6, 3.7.0, 3.7.1, with 3.8 support on the way. That way, it is more likely that a given platform has binary packages available.
You can even build ponyc against different LLVM versions if you have multiple ones installed, eg:
make LLVM_CONFIG=llvm-config-3.6
make LLVM_CONFIG=llvm-config-3.7

LLVM API changes are indeed tough to deal with at times, but locking into a specific LLVM commit restricts our ability to move forward and support new LLVM versions rather than making us more flexible.
Since ponyc is not dependent on a specific LLVM commit, forcing users to build LLVM from scratch isn't something we want to do.


⚠ Adacta-fintech.com has degraded performance

In b21b3df, Adacta-fintech.com (https://www.adacta-fintech.com) experienced degraded performance:

HTTP code: 200
Response time: 1319 ms

Resolved: Adacta-fintech.com performance has improved in c6fea6b after 9 minutes.


Add Netease Qiyu live chat plugin in China

Looks good to me! I didn't test manually.
For my own understanding, how are we identified with qiyukf? How does this connect back to us?
Is this js file unique to CodeCombat, so they know how to send the chat to us?
https://qiyukf.com/script/417b0e66819a980076108e0dac606b50.js

True. the .js name  is a specific key generated on that admin page


[Breaking bug] Feature that worked in v10 is broken in master (now with screenshot)

We have had a major oversight somewhere in one of the commits made since this app went open source. I just recently noticed it and decided to see if the problem exists on v10.0.0 and the Original_plus versions, and it does not.

The Affected Feature
The bug affects what how Winfile should respond when a user selects a folder in the directory tree that they don't have the permissions to access
Intended Behavior
This is how it works (and is supposed to work in master) in v<IP_ADDRESS> and original_plus. Selecting a folder from the left directory the without having the permissions to access it displays a message on the right saying that the user doesn't have the correct permission to accress the folder.
Behavior in Master Code
In the latest build compiled from the master branch, selecting a folder without sufficient permission throws an error message "Incorrect Function" that must be closed, after which a generic message appears on the right saying "Error reading directory". No error dialog should pop up and the message on the right should correctly identify the reason for not being able to access the folder rather than being generic.
Solution
We have had dozens of commits since v<IP_ADDRESS>. We need to first identify which commit has caused this issue to appear.
It's probably best to start by looking at commits dealing with the core functionality of the application rather than things like visual styles.
Another approach is to build the application from an earlier snapshot of master to see if the bug exists and continue doing so until we find where this issue was introduced.
This is a braking bug; master not fit for release
We cannot generate a release build of Winfile until this bug is fixed. It would be a wrong thing to release the app with such a feature broken. It breaks work flow. For instance, I cannot scroll down my directory tree with the arrow keys without the error popping up, breaking my work flow.
If anyone finds the commit that caused this, please mention it below. Once we identify it, we can start working to revise that commit to fix the issue.

We should definitely get to the bottom of this.  However, I am not able to repro this yet.  In the common case of "C:\System Volume Information", the master branch shows the expected (left picture above).
What permissions are set for the directory "Delivery Optimizations" in your example?

I checked v10.0, x64 and the bug exists there (i.e., I created it when I added the Wow... stuff).  Thanks @malxau for finding and fixing!