Change /{db}/_design/{ddoc}/_view/{viewname} semantics for views with defined reduces

Expected Behavior
View queries should always default to responding with a map if no value for the reduce parameter is supplied.
Current Behavior

scenario
query
reduce function defined
result

1
http://couch-instance/db-name/_design/ddoc_name/_view/view_name
no
map

2
http://couch-instance/db-name/_design/ddoc_name/_view/view_name
yes
reduce

3
http://couch-instance/db-name/_design/ddoc_name/_view/view_name?reduce=false
no
map

4
http://couch-instance/db-name/_design/ddoc_name/_view/view_name?reduce=false
yes
map

5
http://couch-instance/db-name/_design/ddoc_name/_view/view_name?reduce=true
no
error

6
http://couch-instance/db-name/_design/ddoc_name/_view/view_name?reduce=true
yes
reduce

IMO scenario number 2 is surprising and unhelpful.
Adding a reduce to an existing ddoc that is used in application code will break all existing calls to a view which do not define reduce=false.  It's not possible to define a view which has a reduce function but not a map function, so the inverse does not apply.
Possible Solution
Change the default for reduce to false.
This change would affect a lot of existing users, so would need to be well documented and coincide with a major release version.
A couple of alternatives to this change might be:

Instead of defaulting, reject view queries which do not specify the reduce parameter

Update the docs at http://docs.couchdb.org/en/2.0.0/api/ddoc/views.html

Currently they read:

reduce (boolean) – Use the reduction function. Default is true

But might be clearer if they read:

reduce (boolean) – Use the reduction function. Default is true if a reduce function is defined, or false otherwise.

ref https://github.com/pouchdb/pouchdb/issues/7127

I also found this very confusing. I think because (at least for me) the vast majority of view usage is without a corresponding reduce, it's not something that you come across much, and it's a pretty radical change that is only passively documented in the query param list.
I think it might be worth modifying the documentation to pull this effect[1] into a warning documentation block to highlight it, and include an explanation to get everyone on the same page.
Something like:

Warning
By default, querying a view runs its reduce function if it has one. This can be confusing if you are used to just using map functions, and are adding a reduce function to an existing view. This happens because

[1] That all view queries automatically become reduce queries when you add a reduce

This is a backwards-compatibility breaking change and can not be introduced easily. The earliest such a change can be considered is 3.0.0.

@wohali Any opinion on the documentation update suggestions?

I would say it's better to mention this in the gentle intro to views here. If I had to guess at a reason, it might be because views are CouchDB's implementation of MapReduce, which suggests if both are defined, you want both.
I don't think it warrants a call-out box in the API reference section, we already say:

reduce (boolean) – Use the reduction function. Default is true when a reduce function is defined.

With the increasing focus on Mango (and reduce coming soon to Mango) it might be best to ensure the user interface for Mango does something friendly and compatible here. /cc @tonysun83 @nickva

reduce (boolean) – Use the reduction function. Default is true when a reduce function is defined.

This isn't quite what I see at http://docs.couchdb.org/en/2.1.1/api/ddoc/views.html - definitely an improvement.

Compare with http://docs.couchdb.org/en/latest/api/ddoc/views.html
Looks like @flimzy is ahead of you: https://github.com/apache/couchdb-documentation/commit/bdfa864b3a6d449f0f7e382628c2ab8350679d13
I'll leave this open as an enhancement request, and edit the title to match.

Personally, I agree, and I expect most of the rest of the core developers would agree as well.
We can always re-open this; going to close for now as wontfix.


Format MAC address in Wifi report

We need to use the mac address, but the format is not great. Change formatting like this:
el.BSSID.split(':').map((hex) => zpad(hex)).join(':') + '',
We have a feature here, but it changed places a few times. Maybe it's better to add straight to your code.
https://github.com/timotoots/iphonebackuptools/commit/a0bdc46d080f1465d555dff8d7e9224f5dd2b783

That's a good idea, It may make sense to place this as a in a separate module in he util directory, and require() it as needed to avoid duplicating functionality as it may be needed elsewhere in the future.

Ok, will do.

Implemented in #17


include iban in doc

Forgot to do this, sorry. And thanks for the release!

No worries, thanks for the PR! :tractor:


User Request: Self-signed certificates generated through Helm

Is your feature request related to a problem? Please describe.
Internally we don't have the cert-manager installed in certain clusters which required us to configure the admission hook.
There are many ways to generate certificates but it'd be nice to provide a solution that works out-of-the-box for both cases in the charts; when the cert-manager is installed and when it is not.
Describe the solution you'd like
I added some logic to our internal charts to support that by setting a property certManager.enabled in the values.yaml. When the cert-manager is not installed we use Helm template functions to generate the certificates. This is very similar to the kubefed webhook implementation.
Would you be open to a PR for that? The only problem I can think of is that this is Helm-specific.

I don't see any issue for this to be helm specific. The chart we provide is an All-in-One chart that can be used to deploy the controller but it can be totally customized when needed. To be honest, we are not using it internally and we have our own chart for the exact same reasons as you (we do not use cert-manager).
We are totally open to a PR that would make this a bit more generic. We chose cert-manager because it is the one used in the examples of the kubebuilder documentation.

Cool. I'm not sure if there is a way to assign this issue to me but I'll raise a PR by next week.

Closing this as the changes have been merged.


KAFKA-16465: Fix consumer sys test revocation validation

This fixes a consumer system test that was failing for the new protocol. The failure was because the test was expecting the eager behaviour of partitions being revoked on every rebalance, and it was wrongfully applying it to the runs with the new protocol too.
This same situation was previously identified and fixed in other parts of the sys test with https://github.com/apache/kafka/pull/15661.

Hey @lucasbru , could you take a look when you have a chance? Similar issue to the one on https://github.com/apache/kafka/pull/15661.
With this I get successful runs of the test (some flaky combinations, mostly around failures already filed/in-flight like failures removing unexpected assignment from list, timeout shutting down)
SESSION REPORT (ALL TESTS)
ducktape version: 0.11.4
session_id:       2024-04-22--006
run time:         66 minutes 30.269 seconds
tests run:        16
passed:           14
flaky:            2
failed:           0
ignored:          0
Thanks!


Add logging summary for card's features and verification status

Current Behaviour
The Tasjael use case does not display the usual GUI flow of smartscanner-core where a complete information of a card in terms of features and verification status are displayed.
Expected Behaviour
In use cases where the GUI is not used, we need to log a summary of a card's features and verification statuses. These will provide an equivalent information that is shown in the GUI here
Steps to Reproduce the Problem

Use the Tasjael application to scan a unified ID
Observe that we have no additional information of the card's features and verification statuses

Context
To be able to log a card's summary features and verification statuses displayed in a GUI like in here is a useful information in terms of a card's level of eMRTD features and on which part are verified and not verified.

Version:

Suggested the following diff to log a summary of a card's features and verification statuses.


create_subprocess with set_event_loop(None) can't interact with child process producing zombies

Don't know how legit is that to set_event_loop(None). Discovered this issue making testing suite, where I create new_event_loop for each test. This thing is unobvious.
import asyncio
command = ('ls', '-l')

@asyncio.coroutine
def run_process(loop):
    proc = yield from asyncio.create_subprocess_exec(
        *command,
        loop=loop
    )
    yield from proc.wait()
    print(proc.returncode)

@asyncio.coroutine
def main(loop):
    yield from run_process(loop)

loop = asyncio.new_event_loop()
asyncio.set_event_loop(None)  # makes wait() infinite, returncode always None
# asyncio.set_event_loop(loop)  # this fixes
try:
    loop.run_until_complete(main(loop))
finally:
    loop.close()

Oh, the "child watcher" part of subprocesses is nearly not documented in asyncio :-/ With your example, the child watcher never runs. You have to configure it explicitly with:
asyncio.get_child_watcher().attach_loop(loop)

The doc is probably restricted to short sentence mentionning vaguely child watchers...
https://docs.python.org/dev/library/asyncio-subprocess.html#asyncio-subprocess-threads
We need to document better the implementation. The problem is that child watchers are specific to UNIX (not available on Windows).

Shouldn't create_subprocess_exec() and other related functions ensure that the ChildWatcher is working for the loop used during process creation (the one given in parameter or the default one)?
It seems that ChildWatcher is not supposed to be exposed to users.

Unfortunately you have to manage the child watcher when you choose to create multiple event loops that spawn subprocesses. There's definitely some unfinished business here that I'd like to see fixed before 3.6 rolls around. Some help would be appreciated!


The keyboard focus cannot be changed

Is there an existing issue for this?

[X] I have searched the existing issues
[X] I have read the guide to filing a bug

Steps to reproduce
Create a list with selectable items e.g. InkWell use the keyboard to select an item and navigate to a different screen. The last selected item will keep have the keyboard focus which is fine so far, but I find no way to override the selection.
The problem is clear when you check my sample. You see at first the home page. When you press the button you see a master/detail page which shows the first item. When you now change the selected item with the keyboard with the arrow keys and press space then you will navigate to that page and see the "details page".
The issue is now when you navigated e.g. to entry 10 and pressed space and then click on entry 3, the keyboard focus is still on entry 10, which makes no sense from the UX perspective. I found no way to select entry 3. This is IMHO a bug or might be a missing feature.
Expected results
I expect that I can control the keyboard focus e.g. with a focus view, but that does not work.
Actual results
Actual magically the focused item is kept in memory which makes sense as long you can override it.
Code sample
Code sample
import 'package:flutter/material.dart';
import 'package:go_router/go_router.dart';

void main() => runApp(const MyApp());

final GoRouter _router = GoRouter(
  routes: <RouteBase>[
    GoRoute(
      path: '/',
      builder: (BuildContext context, GoRouterState state) {
        return const HomeScreen();
      },
      routes: <RouteBase>[
        GoRoute(
          path: 'master',
          builder: (BuildContext context, GoRouterState state) {
            return const DetailScreen(id: '1');
          },
          routes: [
            GoRoute(
              path: ':id',
              builder: (context, state) => DetailScreen(
                id: state.pathParameters['id']!,
              ),
            ),
          ],
        ),
      ],
    ),
  ],
);

class MyApp extends StatelessWidget {
  const MyApp({super.key});

  @override
  Widget build(BuildContext context) {
    return MaterialApp.router(
      routerConfig: _router,
    );
  }
}

class HomeScreen extends StatelessWidget {
  const HomeScreen({super.key});

  @override
  Widget build(BuildContext context) {
    return Scaffold(
      appBar: AppBar(title: const Text('Home Screen')),
      body: Center(
        child: Column(
          mainAxisSize: MainAxisSize.min,
          children: [
            const Padding(
              padding: EdgeInsets.all(32),
              child: Text('This page is basically a placeholder. Use the button below.'),
            ),
            ElevatedButton(
              onPressed: () => context.go('/master/1'),
              child: const Text('Go to the next screen'),
            ),
          ],
        ),
      ),
    );
  }
}

class DetailScreen extends StatelessWidget {
  final String id;

  const DetailScreen({required this.id, super.key});

  @override
  Widget build(BuildContext context) {
    return Scaffold(
      appBar: AppBar(title: Text('Screen - $id')),
      body: Row(
        children: [
          SizedBox(
            width: 200,
            child: ListView.separated(
              itemCount: 30,
              itemBuilder: (context, index) => InkWell(
                child: Padding(
                  padding: const EdgeInsets.all(16),
                  child: Text('Entry ${index + 1}'),
                ),
                onTap: () => context.go('/master/${index + 1}'),
              ),
              separatorBuilder: (BuildContext context, int index) => const Divider(height: 0),
            ),
          ),
          Expanded(
              child: Center(
            child: Text('All the details about "$id"'),
          )),
        ],
      ),
    );
  }
}

Screenshots or Video

Screenshots / Video demonstration
Sorry cannot record it right now.

Logs
Logs
Launching lib\main.dart on Windows in debug mode...
Building Windows application...
√  Built build\windows\runner\Debug\keyboard_focus.exe.
Debug service listening on ws://<IP_ADDRESS>:36792/sym3PkTng2E=/ws
Syncing files to device Windows...

Flutter Doctor output
Doctor output
Doctor summary (to see all details, run flutter doctor -v):
[√] Flutter (Channel stable, 3.13.5, on Microsoft Windows [Version 10.0.19045.3448], locale de-DE)
[√] Windows Version (Installed version of Windows is version 10 or higher)
[√] Android toolchain - develop for Android devices (Android SDK version 33.0.1)
[√] Chrome - develop for the web
[√] Visual Studio - develop Windows apps (Visual Studio Community 2022 17.7.2)
[√] Android Studio (version 2022.3)
[√] VS Code, 64-bit edition (version 1.81.1)
[√] Connected device (3 available)
[√] Network resources

• No issues found!

FYI: This also happens on MacOS.

I read that @gspencergoog has the most knowledge in this area. Can you help?

I can reproduce this issue on Web and macOS platforms.

Demo issue
https://github.com/flutter/flutter/assets/104349824/c347f237-d787-49bb-98f0-7992775d168e

flutter doctor -v (stable and master)
[✓] Flutter (Channel stable, 3.13.6, on macOS 14.0 23A344 darwin-x64, locale en-VN)
    • Flutter version 3.13.6 on channel stable at /Users/huynq/Documents/GitHub/flutter
    • Upstream repository https://github.com/flutter/flutter.git
    • Framework revision ead455963c (5 days ago), 2023-09-26 18:28:17 -0700
    • Engine revision a794cf2681
    • Dart version 3.1.3
    • DevTools version 2.25.0

[✓] Android toolchain - develop for Android devices (Android SDK version 32.0.0)
    • Android SDK at /Users/huynq/Library/Android/sdk
    • Platform android-34, build-tools 32.0.0
    • ANDROID_HOME = /Users/huynq/Library/Android/sdk
    • Java binary at: /Applications/Android Studio Giraffe.app/Contents/jbr/Contents/Home/bin/java
    • Java version OpenJDK Runtime Environment (build 17.0.6+0-17.0.6b829.9-10027231)
    • All Android licenses accepted.

[✓] Xcode - develop for iOS and macOS (Xcode 15.0)
    • Xcode at /Applications/Xcode.app/Contents/Developer
    • Build 15A240d
    • CocoaPods version 1.11.3

[✓] Chrome - develop for the web
    • Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome

[✓] Android Studio (version 2022.3)
    • Android Studio at /Applications/Android Studio Giraffe.app/Contents
    • Flutter plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/9212-flutter
    • Dart plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/6351-dart
    • Java version OpenJDK Runtime Environment (build 17.0.6+0-17.0.6b829.9-10027231)

[✓] Android Studio (version 2022.2)
    • Android Studio at /Applications/Android Studio.app/Contents
    • Flutter plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/9212-flutter
    • Dart plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/6351-dart
    • Java version OpenJDK Runtime Environment (build 17.0.6+0-17.0.6b802.4-9586694)

[✓] VS Code (version 1.82.2)
    • VS Code at /Applications/Visual Studio Code.app/Contents
    • Flutter extension version 3.72.0

[✓] Connected device (2 available)
    • macOS (desktop) • macos  • darwin-x64     • macOS 14.0 23A344 darwin-x64
    • Chrome (web)    • chrome • web-javascript • Google Chrome 117.0.5938.132

[✓] Network resources
    • All expected network resources are available.

• No issues found!

[!] Flutter (Channel master, 3.15.0-13.0.pre.40, on macOS 14.0 23A344 darwin-x64, locale en-VN)
    • Flutter version 3.15.0-13.0.pre.40 on channel master at /Users/huynq/Documents/GitHub/flutter_master
    ! Warning: `flutter` on your path resolves to /Users/huynq/Documents/GitHub/flutter/bin/flutter, which is not inside your current Flutter SDK checkout at /Users/huynq/Documents/GitHub/flutter_master. Consider adding /Users/huynq/Documents/GitHub/flutter_master/bin to the front of your path.
    ! Warning: `dart` on your path resolves to /Users/huynq/Documents/GitHub/flutter/bin/dart, which is not inside your current Flutter SDK checkout at /Users/huynq/Documents/GitHub/flutter_master. Consider adding /Users/huynq/Documents/GitHub/flutter_master/bin to the front of your path.
    • Upstream repository https://github.com/flutter/flutter.git
    • Framework revision 71acf24201 (3 hours ago), 2023-10-02 01:45:02 +0200
    • Engine revision 10b930ad1a
    • Dart version 3.2.0 (build 3.2.0-220.0.dev)
    • DevTools version 2.28.1
    • If those were intentional, you can disregard the above warnings; however it is recommended to use "git" directly to perform update checks and upgrades.

[✓] Android toolchain - develop for Android devices (Android SDK version 32.0.0)
    • Android SDK at /Users/huynq/Library/Android/sdk
    • Platform android-34, build-tools 32.0.0
    • ANDROID_HOME = /Users/huynq/Library/Android/sdk
    • Java binary at: /Applications/Android Studio Giraffe.app/Contents/jbr/Contents/Home/bin/java
    • Java version OpenJDK Runtime Environment (build 17.0.6+0-17.0.6b829.9-10027231)
    • All Android licenses accepted.

[✓] Xcode - develop for iOS and macOS (Xcode 15.0)
    • Xcode at /Applications/Xcode.app/Contents/Developer
    • Build 15A240d
    • CocoaPods version 1.11.3

[✓] Chrome - develop for the web
    • Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome

[✓] Android Studio (version 2022.3)
    • Android Studio at /Applications/Android Studio Giraffe.app/Contents
    • Flutter plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/9212-flutter
    • Dart plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/6351-dart
    • Java version OpenJDK Runtime Environment (build 17.0.6+0-17.0.6b829.9-10027231)

[✓] Android Studio (version 2022.2)
    • Android Studio at /Applications/Android Studio.app/Contents
    • Flutter plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/9212-flutter
    • Dart plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/6351-dart
    • Java version OpenJDK Runtime Environment (build 17.0.6+0-17.0.6b802.4-9586694)

[✓] VS Code (version 1.82.2)
    • VS Code at /Applications/Visual Studio Code.app/Contents
    • Flutter extension version 3.72.0

[✓] Connected device (2 available)
    • macOS (desktop) • macos  • darwin-x64     • macOS 14.0 23A344 darwin-x64
    • Chrome (web)    • chrome • web-javascript • Google Chrome 117.0.5938.132

[✓] Network resources
    • All expected network resources are available.

! Doctor found issues in 1 category.

Feasible workaround
There is a workaround although I'm not sure if it goes against one of Best practices.
The idea is to focus on the root widget (outermost) and re-focus the clicking item. The disadvantage is that we need to create a number of FocusNodes corresponding to the number of items in the list.

Sample code for workaround
import 'package:flutter/material.dart';
import 'package:go_router/go_router.dart';

void main() => runApp(const MyApp());

final GoRouter _router = GoRouter(
  routes: <RouteBase>[
    GoRoute(
      path: '/',
      builder: (BuildContext context, GoRouterState state) {
        return const HomeScreen();
      },
      routes: <RouteBase>[
        GoRoute(
          path: 'master',
          builder: (BuildContext context, GoRouterState state) {
            return const DetailScreen(id: '1');
          },
          routes: [
            GoRoute(
              path: ':id',
              builder: (context, state) => DetailScreen(
                id: state.pathParameters['id']!,
              ),
            ),
          ],
        ),
      ],
    ),
  ],
);

class MyApp extends StatelessWidget {
  const MyApp({super.key});

  @override
  Widget build(BuildContext context) {
    return MaterialApp.router(
      routerConfig: _router,
    );
  }
}

class HomeScreen extends StatelessWidget {
  const HomeScreen({super.key});

  @override
  Widget build(BuildContext context) {
    return Scaffold(
      appBar: AppBar(title: const Text('Home Screen')),
      body: Center(
        child: Column(
          mainAxisSize: MainAxisSize.min,
          children: [
            const Padding(
              padding: EdgeInsets.all(32),
              child: Text('This page is basically a placeholder. Use the button below.'),
            ),
            ElevatedButton(
              onPressed: () => context.go('/master/1'),
              child: const Text('Go to the next screen'),
            ),
          ],
        ),
      ),
    );
  }
}

class DetailScreen extends StatefulWidget {
  final String id;

  const DetailScreen({required this.id, super.key});

  @override
  State<DetailScreen> createState() => _DetailScreenState();
}

class _DetailScreenState extends State<DetailScreen> {
  final focusNodeBackground = FocusNode();
  final focusNodeItems = <FocusNode>[];

  @override
  void initState() {
    super.initState();
    for (var i = 0; i < 30; i++) {
      focusNodeItems.add(FocusNode());
    }
  }

  @override
  void dispose() {
    super.dispose();
    focusNodeBackground.dispose();
		for (var i = 0; i < 30; i++) {
			focusNodeItems[i].dispose();
		}
  }

  @override
  Widget build(BuildContext context) {
    return Scaffold(
      appBar: AppBar(title: Text('Screen - ${widget.id}')),
      body: Focus(
        focusNode: focusNodeBackground,
        child: Row(
          children: [
            SizedBox(
              width: 200,
              child: ListView.separated(
                itemCount: 30,
                itemBuilder: (context, index) => InkWell(
                  focusNode: focusNodeItems[index],
                  child: Padding(
                    padding: const EdgeInsets.all(16),
                    child: Text('Entry ${index + 1}'),
                  ),
                  onTap: () {
                    context.go('/master/${index + 1}');
                    focusNodeBackground.requestFocus();
                    focusNodeItems[index].requestFocus();
                  },
                ),
                separatorBuilder: (BuildContext context, int index) => const Divider(height: 0),
              ),
            ),
            Expanded(
                child: Center(
              child: Text('All the details about "${widget.id}"'),
            )),
          ],
        ),
      ),
    );
  }
}

Demo workaround
https://github.com/flutter/flutter/assets/104349824/dc0d0b48-7e9c-4c74-a6dd-963cdd632424

Labeling the issue for other's input.

This is "as designed".  Buttons do not request focus when they are clicked on (even native ones).  Only text fields request focus when they are clicked on, which explains why the focus stays where you put it when you moved it with the keyboard. If you want to focus the button when it is clicked on, you'll need to assign a focus node to each one, and call requestFocus on the node in the onTap handler.


"Calling function 'RecaptchaLoaderService', function calls are not supp..." when build -prod

When I apply new language, it works fine in development environment

ng serve

But when I try to build prod, I get error

ng build -prod

ERROR in Error encountered resolving symbol values statically. Calling function 'RecaptchaLoaderService', function calls are not supp
replacing the function or lambda with a reference to an exported function, resolving symbol AppComponent in /Users/
src/app/app.component.ts, resolving symbol AppComponent in /Users/ang/src/app/app.compone
ERROR in ./src/main.ts
Module not found: Error: Can't resolve './$$_gendir/app/app.module.ngfactory' in '/Users/ang/src
@ ./src/main.ts 4:0-74
@ multi ./src/main.ts

Then I have to remove RecaptchaLoaderService.

I suppose you're having trouble with this piece of code:
@NgModule({
  providers: [
    {
      provide: RecaptchaLoaderService,
      useValue: new RecaptchaLoaderService("fr"), // use French language
    },
  ],
}) export class MyModule { }

The compiler is telling you that it cannot parse a construction like this. What you should do instead is either this:
export const FrenchRecaptchaLoaderService = new RecaptchaLoaderService("fr");

@NgModule({
  providers: [
    {
      provide: RecaptchaLoaderService,
      useValue: FrenchRecaptchaLoaderService,
    },
  ],
}) export class MyModule { }

or this (the preferred approach):
import { RECAPTCHA_LANGUAGE } from 'ng2-recaptcha';

@NgModule({
  providers: [
    {
      provide: RECAPTCHA_LANGUAGE,
      useValue: 'fr', // or whatever other language you need
    },
  ],
}) export class MyModule { }

I tried the 2nd way. It works like a charm.
Thank you.


Some valid Hex colors are not parsed into RGB

Hi!
So, I noticed while using the ColorUtils.HexToRgb() function that often I am getting back a NULL color, when the value is a valid (HTML-displaying) Hex color (https://www.colorhexa.com/a58d42).  Stepping through the source code, for one such color, I see that the failure is happening in a RegEx function - it doesn't match any of the three possible RegEx expressions:

There were several colors I was using which were returning NULL (including #ECF1F4 and #A9B3BA)
My skill with Regex is mediocre, and I'm not entirely sure what the strategy is with your RegEx, so I looked for a solution to how others might convert HEX colors, and came across this: https://stackoverflow.com/a/74679005/3841490
When I added a final conversion attempt to the code:
...
    if (RegexPatterns.Hex3.IsMatch(input, out r, out g, out b, out byte alpha)) {
        result = new RgbColor(r, g, b, alpha / 255d);
        return true;
    }

    //Else try this
    try {
        int rgbInt = Convert.ToInt32(input, 16);
        byte red = (byte)((rgbInt >> 16) & 255);
        byte green= (byte)((rgbInt >> 8) & 255);
        byte blue = (byte)(rgbInt & 255);
        result = new RgbColor(red, green, blue);
        return true;

    } catch (Exception e) {
       //skip
    }

    return false;
}

All of the colors were returning an RgbColor.
If you want me to put in a PR I can, or feel free to integrate a fall-back like this yourself, or perhaps you know why those colors weren't matching a RegEx?

Hi @hfloyd and thanks for reporting this 👍
I haven't really been using this package a lot in the few last years, which must be why I haven't encountered this my self. The problem is a bit silly to be honest (from my part).
The REGEX patterns for the HEX codes only check for a-f, but not A-F. This would be fine if I had added the IgnoreCase flag, but as you can see from the screenshot below, I've missed that part 🤦♂

I think if the IgnoreCase flag is added, it should work fine. I will try to test this a bit 😉
The reason for the three HEX patterns is that there is the normal six digit format, but then there is also the three digit shorthand (eg. #fff) as well as the eight digit format including the alpha level.

Yep, that fixes it! I'll put in a PR for you.

I've now merged #6, so a I'll have a new release out soon 😉
I had a few minutes before heading home from work, so I worked a bit on improving my unit tests. It turns out  that the ColorUtils.TryParse method has worked fine since it calls ToLower() before continuing with the parsing, while ColorUtils.HexToRgb doesn't hence your experience null values.
With the REGEX flags updated, I should be able to remove the ToLower() as it should now be redundant. I'll play bit more around with this and updating the unit tests, and then push a new release.
Thanks for your help again 👍

My pleasure! Have a great evening!

@hfloyd you too 😉
A new release is now out with the fix: https://github.com/abjerner/Skybrud.Colors/releases/tag/v1.1.1
Not that there is a lot of documentation yet, but you can now find a bit of documentation for Skybrud.Colors on our new documentation site: https://packages.limbo.works/skybrud.colors/docs/


Missing Pyrra internal metrics after v0.5.x

I noticed the internal metrics for Pyrra disappeared after upgrading to v0.5.x.
If i check the metrics endpoint /metrics then all I can find is Golang-metrics. Before the upgrade Pyrra exposed metrics like these:
http_requests_duration_second_sum{route="GetMultiBurnrateAlerts"}
http_requests_total{code="200",route="GetMultiBurnrateAlerts"}

Was this removed intentionally? I checked the updated docs introduced with v0.5.x and there's some new metrics named here. However, I can't seem to find those either.

In version v0.5.0 Pyrra moved from using OpenAPI to using connect-go.
Currently there are no interceptors available for Prometheus in connect-go to create equal metrics. However, I've started such a package locally.
For now, sadly, we don't have equal metrics available. In the next releases we should get similar ones back.

Ah, that explains it. The reason I noticed this was because we use the example SLOs that use the internal Pyrra-metrics.

Kind of ironic that we currently don't have metrics for Pyrra SLOs itself. :joy:
Again, I hope to get something working soon, maybe only requests_total and without histograms. That should be quicker to do, really.


[5.9] Change version dependency on swift-argument-parser to from upToNextMinor to upToNextMajor

This will make SourceKit-LSP more tolerant with regard to which swift-argument-parser version it needs, resulting in fewer version conflicts for people who depend on SourceKit-LSP as a package dependency.

@swift-ci Please test


Language request: PHP

PHP has standardized on composer as it's package manager, would be great to support it here.

It would be useful to have a composer translator and php builder, perhaps taking inspiration from https://github.com/svanderburg/composer2nix
I see the composer.lock file format does have a shasum field, but it seems to be left empty for the composer.lock files that I've seen so far, not sure what's going on there. Some more discussion on the hash input at https://github.com/composer/composer/issues/2540 .

I sometimes have to touch PHP and I see that there's often a composer dump-autoload step that seems to add extra php files.
Also, some PHP modules seem to use relative imports to get configuration from the main project, or is that rare? So if the vendor dir were a symlink to the nix store, those modules wouldn't work.
Basically, I'm wondering how the vendor dir would best be built.

Some frameworks also have  composer plugins which add their own php files.
Case in point Symfony flex

So, two modes, one just symlinks a vendor dir (when all components behave), and the other mode copies the entire thing?

It would be cool if we test this packaging solution against demo repos of popular frameworks like symfony demo:
https://github.com/symfony/demo
Having demo apps working out of the box would be a great DX for nix usage in php ecosystem

It is also a good way to document how to build php apps which depend on nodejs/webpack for their front-end using dream2nix since it supports building packages for multiple ecosystems.

[ ] add meta to packages

like #294

[ ] php versions

right now it's just php 8.1 from nixpkgs or abort if incompatible
get a php version from https://github.com/fossar/nix-phps

[ ] override package version

usually packages don't have version field in composer.json resulting in package names like name-unknown
add a subsystem attribute to allow setting the version field


MemberAttributeMacro arguments have parents with SyntaxProtocol.expand() but not via compiler plugin

Description
// Macro definition
public struct WrapPropertiesWithParents: MemberAttributeMacro {
    public static func expansion(
        of node: AttributeSyntax,
        attachedTo declaration: some DeclGroupSyntax,
        providingAttributesFor member: some DeclSyntaxProtocol,
        in context: some MacroExpansionContext
    ) throws -> [AttributeSyntax] {
        guard member.is(VariableDeclSyntax.self) && member.hasParent else {
            return []
        }
        return [
            AttributeSyntax(attributeName: SimpleTypeIdentifierSyntax(name: .identifier("Wrapper")))
        ]
    }
}

@main
struct reproPlugin: CompilerPlugin {
    let providingMacros: [Macro.Type] = [
        WrapPropertiesWithParents.self,
    ]
}

// Test case
final class reproTests: XCTestCase {
    func testMacro() {
        assertMacroExpansion(
            """
            @WrapPropertiesWithParents
            class Foo {
                var bar: Int = 0
            }
            """,
            expandedSource: """

            class Foo {
                @Wrapper
                    var bar: Int = 0
            }
            """,
            macros:  [
                "WrapPropertiesWithParents": WrapPropertiesWithParents.self,
            ]
        )
    }
}

// Non-test usage
@WrapPropertiesWithParents
class Foo {
    var bar: Int = 0
}

This macro attaches the @Wrapper attribute to member variables if the decl passed to the macro has a parent. assertMacroExpansion does set the parent on the decl, so the test passes. The actual macro expansion when invoked by the compiler does not, so the attribute is not added and compilation succeeds (the @Wrapper attribute doesn't exist, so compilation would fail if it was added).
I don't know which of these behaviors is the intended one, but presumably they should be the same?
Steps to Reproduce
No response

Repro code as a complete project

Tracked in Apple’s issue tracker as rdar://110752745


[Feature Request]: Limit time unit choices in Date Range Picker

Description
We are using the cloudscape date range picker with a relative range value. When users are selecting a custom range they have the following under selection of time "seconds", "minutes", "hours", "weeks", "months", "years". We would like to limit the selection to exclude possibly seconds and years? is this possible? I didn't see anything in the documentation about limiting what is available under the selection of time. Below is the link to the component page.
https://cloudscape.design/components/date-range-picker/?tabId=playground&example=with-relative-range-value

Code of Conduct

[X] I agree to follow this project's Code of Conduct
[X] I checked the current issues for duplicate requests

This is something that we deliberately didn't make configurable, as it would still be possible to input e.g. 24 months even if the 'year' option was removed - we would recommend making any constraints here via validation rather than configuration.

It makes sense that validation is still needed. However, I would suggest that there is still value in being able to limit down to sensible choices for users. We can look at the AWS X-Ray console as an example where this would be helpful. The maximum time range when querying is 6 hours. The presets they have all cover that, but it's still possible to select days/weeks/months as options. It's especially annoying because the validation only happens after the user fills in the time and hits apply. They're able to go through multiple clicks and keystrokes before the range limitation is surfaced.
I recognize that their console isn't using the current version of Cloudscape, but the problem is the same.

I agree that validation is crucial and plays a vital role, but it shouldn't be our only line of defense against user errors. Following UX best practices, preventing errors from occurring in the first place often leads to a smoother and more intuitive user experience.
To highlight a specific scenario for our use case: If a user selects a duration in 'months', and they choose 1 month, we're good to go. But, if they opt for 'years' and input any duration, it will always be incorrect given our constraints. Just like bilalq's example with AWS X-Ray, allowing users to pick an option that will inevitably result in an error can be frustrating. Instead of knowingly letting them proceed with an invalid choice and then redirecting them, why not streamline the process and narrow down their choices upfront?

@gethinwebster , is there a way to at least set the default units in selection for custom relative range options? The control currently defaults to minutes and our use case doesn't allow for minutes/seconds duration granularity, and providing seconds and minutes options the list suggests otherwise, and relying on validation adds friction to the UX. Having the unit default to hours will help mitigate. Thank you.

We recently release a new feature to allow these units to be specified 🎉
You can use the customRelativeRangeUnits property (e.g. customRelativeRangeUnits={['hour', 'day']}) to limit the units that you want to allow for selection.


Create library for Python

I guess we can close this one now: https://github.com/soundcloud/periskop-python


valgrind fails

What version of Go are you using (go version)?

$ go version
go version go1.15.15 linux/amd64

Does this issue reproduce with the latest release?
Probably
What operating system and processor architecture are you using (go env)?
go env Output
$ go env
v
GO111MODULE=""
GOARCH="amd64"
GOBIN=""
GOCACHE="/home/erez/.cache/go-build"
GOENV="/home/erez/.config/go/env"
GOEXE=""
GOFLAGS=""
GOHOSTARCH="amd64"
GOHOSTOS="linux"
GOINSECURE=""
GOMODCACHE="/home/erez/go/pkg/mod"
GONOPROXY=""
GONOSUMDB=""
GOOS="linux"
GOPATH="/home/erez/go"
GOPRIVATE=""
GOPROXY="https://proxy.golang.org,direct"
GOROOT="/usr/lib/go-1.15"
GOSUMDB="sum.golang.org"
GOTMPDIR=""
GOTOOLDIR="/usr/lib/go-1.15/pkg/tool/linux_amd64"
GCCGO="gccgo"
AR="ar"
CC="gcc"
CXX="g++"
CGO_ENABLED="1"
GOMOD=""
CGO_CFLAGS="-g -O2"
CGO_CPPFLAGS=""
CGO_CXXFLAGS="-g -O2"
CGO_FFLAGS="-g -O2"
CGO_LDFLAGS="-g -O2"
PKG_CONFIG="pkg-config"
GOGCCFLAGS="-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build273804324=/tmp/go-build -gno-record-gcc-switches"

What did you do?
Use valgrind
What did you expect to see?
To pass
What did you see instead?
Errors.
Why is that a problem?
I saw this comment about valgrind:
Valgrind is really a tool for C programs.
It assumes it can replace malloc with its own copy, it assumes
the standard C stack model, I'm sure it assumes other things
specific to that world too.
This is perfectly right.
But I do not run valgrind to check the go application.
I run valgrind to check C/C++ libraries that are linked with my go application!
And as they are libraries, they are linked differently with my go application.
So running valgrind with a different language, would not provide the same result.
Python provide the PYTHONMALLOC=malloc.
I would except something similar with Go language.
See: https://docs.python.org/3/c-api/memory.html
And: https://docs.python.org/3/using/cmdline.html#envvar-PYTHONMALLOC

Go doesn't support valgrind, but does support asan and msan, which work with clang, and perhaps gcc.

Go doesn't support valgrind, but does support asan, msan, and tsan, which work with clang, and perhaps gcc.

Yes, I notice. That is why I open the ticket.
GCC support AddressSanitizer.
As go itself does not need memory checker, it does not matters.
The AddressSanitizer is a good tool.
But it does have a downside. It require compilation.
Yes, valgrind is slow, but it use the same production binary.
So no compilation 'errors' due to different compilations flags or optimisation can skip.
And yes, C/C++ compilers are good, and yet there are corners for the developers.

  I would expect it to check the memory behavior of the C code.

Thanks.  This will need attention from somebody familiar with valgrind.  The memory is initialized, but valgrind doesn't seem to know that.  I don't know why.

I don't know if this will help but I've used valgrind a few times with Go on ppc64le, and I usually have to build the Go binary with external linking to get it to work. I'm not sure why, maybe valgrind depends on something in __libc_start_main. Since you are seeing runtime.rt0_go I believe that means it was built with the internal linker.

I don't know if this will help but I've used valgrind a few times with Go on ppc64le, and I usually have to build the Go binary with external linking to get it to work. I'm not sure why, maybe valgrind depends on something in __libc_start_main. Since you are seeing runtime.rt0_go I believe that means it was built with the internal linker.

That might be that, then perhaps go should provide instructions?
I did not found the 2 stages, I use go build for both compilation and linking.

I do understand your point.
The valgrind error comes from go code, not from my C++ code.
And as far as I understand , we can use extern in both directions.
C can call go functions and go can all C.
We only need proper external, translate the types between C and go, and finally build.
Anyhow, there should be a proper instructions with simple example for using valgrind .
For using go with C code and valgrind.

Ian's point is that my suggestion won't help.

I have no idea what additional information you need.
If you wish to close the ticket, you should be more explicit for why.

Reopening.  But as we said before, this is going to require attention from somebody familiar with valgrind.

Sure, but please explain, what do you need?
Adding tags is nice. But I think you should explain.
We can ask for help from Valgrid. Or try a write a small test, that demonstrate the problem and can be easily reproduced.
How do you want to proceed?

We need someone familiar with valgrind who is willing to work on this issue.
A step-by-step reproducer would definitely help that person.

@randall77 @erezgeva
Hello,
I am a golang engineer and interested in performance engineering. I am currently studing how valgrind works and i am willing to conduct a research on this details and give more details about how this can be solve if given the go ahead.
Thanks. Looking forward to you response.

A step-by-step reproducer would definitely help that person.

This is probably the place to start.
Then we need to understand why valgrind is reporting errors on Go code. Then we need to figure out how to either fix or suppress those errors.

Oh yes.
I am going to start with trying to reproduce the errors as you said.
Thanks @randall77

Hello @randall77
I started investigating this issue by trying to reproduce the error as you said. I tried running a couple of simple programs that involved cgo. I noticed a consistent result in the valgrind report
LEAK SUMMARY: ==11520==    definitely lost: 0 bytes in 0 blocks ==11520==    indirectly lost: 0 bytes in 0 blocks ==11520==      possibly lost: 1,440 bytes in 5 blocks ==11520==    still reachable: 0 bytes in 0 blocks ==11520==         suppressed: 0 bytes in 0 blocks
The number of possibly lost bytes seems consistent across the basic programs  i ran. Also, i want to note that valgrind does not report errors on pure go code without call to the cgo library. The possibly error leak starts out at the call of the C library.

Running Valgrind with a Go program is very relevant for my use case, where my Go program does multiple cgo calls for alloc/free, and I want to ensure that these calls are correct, i.e. no memory leaks and no double frees.

@arg0d
Interesting. What were your results when you ran valgrind on your Go program.

Running valgrind go test on linux
==55396== Memcheck, a memory error detector
==55396== Copyright (C) 2002-2017, and GNU GPL'd, by Julian Seward et al.
==55396== Using Valgrind-3.18.1 and LibVEX; rerun with -h for copyright info
==55396== Command: go test -v
==55396==
==55396== Warning: set address range perms: large range [0x9160000, 0x29160000) (noaccess)
==55396== Warning: set address range perms: large range [0x29160000, 0x49160000) (noaccess)
==55396== Warning: ignored attempt to set SIGRT32 handler in sigaction();
==55396==          the SIGRT32 signal is used internally by Valgrind
==55396== Warning: client switching stacks?  SP change: 0x1ffefffc28 --> 0xc00007a7d8
==55396==          to suppress, use: --max-stackframe=687212047280 or greater
==55396== Warning: client switching stacks?  SP change: 0xc00007a730 --> 0x1ffefffcb8
==55396==          to suppress, use: --max-stackframe=687212046968 or greater
==55396== Thread 3:
==55396== Invalid read of size 8
==55396==    at 0x46D005: runtime.systemstack.abi0 (in /usr/local/go/bin/go)
==55396==  Address 0xc00007b6b0 is in a rw- anonymous segment
==55396==
==55396== Invalid read of size 8
==55396==    at 0x40900E: runtime.send.goready.func1 (in /usr/local/go/bin/go)
==55396==    by 0x46D009: runtime.systemstack.abi0 (in /usr/local/go/bin/go)
==55396==  Address 0xc00007b6b8 is in a rw- anonymous segment
==55396==
==55396== Invalid read of size 8
==55396==    at 0x409012: runtime.send.goready.func1 (in /usr/local/go/bin/go)
==55396==    by 0x46D009: runtime.systemstack.abi0 (in /usr/local/go/bin/go)
==55396==  Address 0xc00007b6c0 is in a rw- anonymous segment
==55396==
==55396== Use of uninitialised value of size 8
==55396==    at 0x46D040: runtime.systemstack.abi0 (in /usr/local/go/bin/go)
==55396==    by 0x408D99: runtime.chansend (in /usr/local/go/bin/go)
==55396==    by 0x408896: runtime.chansend1 (in /usr/local/go/bin/go)
==55396==    by 0x428710: runtime.bgsweep (in /usr/local/go/bin/go)
==55396==    by 0x41D8E4: runtime.gcenable.func1 (in /usr/local/go/bin/go)
==55396==    by 0x46EE00: runtime.goexit.abi0 (in /usr/local/go/bin/go)
==55396==
==55396== Use of uninitialised value of size 8
==55396==    at 0x408FA5: runtime.send (in /usr/local/go/bin/go)
==55396==    by 0x408896: runtime.chansend1 (in /usr/local/go/bin/go)
==55396==    by 0x428710: runtime.bgsweep (in /usr/local/go/bin/go)
==55396==    by 0x41D8E4: runtime.gcenable.func1 (in /usr/local/go/bin/go)
==55396==    by 0x46EE00: runtime.goexit.abi0 (in /usr/local/go/bin/go)
...
a bunch more errors
...
==55396== More than 1000 different errors detected.  I'm not reporting any more.
==55396== Final error counts will be inaccurate.    Note
==55396== that errors may occur in your program without prior warning from
==55396== Valgrind, because errors are no longer being displayed.


Update UG

Add documentation for Adding Assignment Task in User guide
closes #187

Codecov Report

Merging #193 (cb44def) into master (16151b0) will not change coverage.
The diff coverage is n/a.

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


sassc error Not enough space in rake assets precompile

Dear All,
while trying to precompile assets in my app, after adding metronics styles, I get this error:
rake aborted!
SassC::SyntaxError: Internal Error: Not enough space
/home/spanogi/.rbenv/versions/2.4.3/bin/bundle:23:in load' /home/spanogi/.rbenv/versions/2.4.3/bin/bundle:23:in '
Tasks: TOP => assets:precompile
I cannot understand to what "not enough space" refers. Memory is ok, disk space also. Could you please help me to track this error?
Best regards,
Giuseppe

Hi, I managed to get it work.
I discovered that "Not enough space" means "No UTF-8 encoded file"... I think it would be REALLY USEFUL to correct this error message, it took two days for me to understand the origin of the problem, also because I've lost one day looking for resources ("Not enough space" means to me lack of resources).

@giuseppespano do you able to fixed the issue

Hello.
I have exactly the same error.
"SassC::SyntaxError: Internal Error: Not enough space"
Really. How to fix this problem step by step?


COMMS-299: Truncate the select dropdown labels when they're really long

https://helpscout.atlassian.net/browse/COMMS-299
Before:

After:

Pull Request Test Coverage Report for Build 2651

0 of 0   changed or added relevant lines in 0 files are covered.
No unchanged relevant lines lost coverage.
Overall coverage remained the same at 100.0%

Totals

Change from base Build 2646:
0.0%

Covered Lines:
21

Relevant Lines:
21

💛  - Coveralls

@tompedals is this on develop? I still see it not fixed on proxy pack http://c.hlp.sc/9db753d951bd


watsonx.governance fails to install due to invalid CR

Describe the bug
When installing watsonx.governance, the CR that is generated by the apply-cr preview script is incorrect.
At installation time, the following error is thrown:
TASK [cp4d-cartridge-install : Fail if there was an error waiting for the cartridge(s) to be installed] ***
Monday 27 May 2024  23:26:11 +0000 (0:00:00.062)       0:43:29.395 ************
fatal: [localhost]: FAILED! => changed=false
  msg:
    attempts: 1
    changed: true
    exception: |-
      NoneType: None
    failed: false
    failed_when_result: false
    msg: non-zero return code
    rc: 3
    stderr: |-
      Error from server (NotFound): watsonxgovernance.watsonxgovernance.cpd.ibm.com "watsonxgovernance-cr" not found
    stderr_lines:
    - 'Error from server (NotFound): watsonxgovernance.watsonxgovernance.cpd.ibm.com "watsonxgovernance-cr" not found'
    stdout: |-
      [2024-05-27 23:26:09] ----------
      [2024-05-27 23:26:09] Info: Checking access to project watsonx
      NAME      DISPLAY NAME   STATUS
      watsonx                  Active
      [2024-05-27 23:26:09] Checking installation completion of cartridge watsonx-governance
      [2024-05-27 23:26:10] Info: Status of ZenService object lite-cr is Completed
      [2024-05-27 23:26:10] Error: Watsonxgovernance object watsonxgovernance-cr does not exist in project watsonx
      [2024-05-27 23:26:10] Log status of pods in project watsonx to file /Data/cpd-status/log/watsonx-pods.out
      [2024-05-27 23:26:11] Exiting because of error.
    stdout_lines:
    - '[2024-05-27 23:26:09] ----------'
    - '[2024-05-27 23:26:09] Info: Checking access to project watsonx'
    - NAME      DISPLAY NAME   STATUS
    - watsonx                  Active
    - '[2024-05-27 23:26:09] Checking installation completion of cartridge watsonx-governance'
    - '[2024-05-27 23:26:10] Info: Status of ZenService object lite-cr is Completed'
    - '[2024-05-27 23:26:10] Error: Watsonxgovernance object watsonxgovernance-cr does not exist in project watsonx'
    - '[2024-05-27 23:26:10] Log status of pods in project watsonx to file /Data/cpd-status/log/watsonx-pods.out'
    - '[2024-05-27 23:26:11] Exiting because of error.'

PLAY RECAP *********************************************************************
localhost                  : ok=1918 changed=281  unreachable=0    failed=1    skipped=878  rescued=0    ignored=0

Monday 27 May 2024  23:26:11 +0000 (0:00:00.059)       0:43:29.455 ************
===============================================================================

CR getting generated:
cat <<EOF |oc apply -f -
apiVersion: watsonxgovernance.cpd.ibm.com/v1beta1
kind:  Watsonxgovernance
metadata:
  name: watsonxgovernance-cr
  namespace: watsonx
spec:
  license:
    accept: true
    license: Enterprise
  fileStorageClass: ocs-storagecluster-cephfs
  blockStorageClass: ocs-storagecluster-ceph-rbd
  version: 1.1.5
  installType: all
  enableFactsheet: installed
  enableOpenpages: installed
  enableOpenscale: installed

EOF

The enableFactsheets and the 2 other properties should either be true or false.
Resolution
Use a script to patch the 3 values.

This is a configuration issue. installed should be replaced by true in the configuraiton yaml.


Worked on Feature endpoint

@oluwafemioluwatuyi I have similar comments here same with @The-CodeINN 's PR. Add a service layer to do you data fetching and manipulation instead of doing all that within your controller

There are lots of commented out code. I’m guessing you’ll clean these up later on

Yea. I pushed the code to work on the other system.


EXC_GUARD Exceptions (Crash)

I get these crashes on startup or when clicking on a song or profile ... usually 2-3 times in succession before the app will actually load and be stable.
Here is a Gist of the dump: https://gist.github.com/jordanandree/4924576c930de8c45bb7

Thanks for the dump, had a quick look but I have no idea why this is happening.. Will try reproducing on Yosemite.

Should not happen anymore in 1.0.0.


Update dependencies, and github-actions

Updated dependencies
Added github-actions to dependabot
Removed deprecated go-versions from test suite

Fixes #170 #172 #166

@ansrivas This PR should take care of all the other open PR's and the failing tests.

@gaby Thank you very much for your contribution.

@gaby Thank you very much for your contribution.

Thanks for merging it, looking forward to the next release :-)


trivial news fragments aren't getting added to the CHANGELOG.rst

trivial news fragments aren't getting added to the CHANGELOG.rst when generating a release.   I noticed this a few times now; finally ticketing it.

If you are spending time on this, can I open another can of worms?
Our man page is 3000 lines, and 90% is the changelog.
Can we only include the last N versions?
N could be anywhere between 3-10 ?

Our man page is 3000 lines, and 90% is the changelog.

Whoa that's kind of wild -- I wonder why include the changelog at all in the man pages?

Old Unix convention is to declare significant changes in the manpage.


The Page for submitting pull requests is outdated

Here
http://docs.orchardproject.net/Documentation/Contributing-patches
It still refer to codeplex
"Once this is done, your changes are on CodePlex, but not yet in the project's official repository. To get it there, you'll need to ask us to pull the changes in. In order to do that, send us a pull request from the fork management screen under the source control tab on CodePlex:"
The global process seems Ok, but is it really O with Github. May be conventions on referencing issues are outdated ?

FYI I am currently working on this


Error handling for questionnaire rendering

Is your feature request related to a problem? Please describe.
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]
Describe the solution you'd like
A clear and concise description of what you want to happen.
Describe alternatives you've considered
A clear and concise description of any alternative solutions or features you've considered.
Additional context
Add any other context or screenshots about the feature request here.
Would you like to work on the issue?
Please state if this issue should be assigned to you or who you think could help to solve this issue.

@jingtang10 would you be able to add more context on this issue please?

@Tarun-Bhardwaj @jingtang10
Can you please provide more details.

@joiskash @maimoonak fyi


feat: new dust limit, fees from mAPI, updated tests connected with fees

New dust limit, fees from mAPI
Satoshis and fees in tests were also recalculated according to new default fee unit.

Codecov Report

Merging #325 (76386fe) into master (493afac) will decrease coverage by 0.26%.
The diff coverage is 13.33%.

:exclamation: Your organization is not using the GitHub App Integration. As a result you may experience degraded service beginning May 15th. Please install the Github App Integration for your organization. Read more.
Additional details and impacted files

@@            Coverage Diff             @@
##           master     #325      +/-   ##
==========================================
- Coverage   52.33%   52.07%   -0.26%
==========================================
  Files          87       87
  Lines        9906     9941      +35
==========================================
- Hits         5184     5177       -7
- Misses       4308     4348      +40
- Partials      414      416       +2

Flag
Coverage Δ

unittests
52.07% <13.33%> (-0.26%)
:arrow_down:

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

Impacted Files
Coverage Δ

client_options.go
76.85% <0.00%> (-0.72%)
:arrow_down:

chainstate/client.go
41.02% <5.12%> (-15.68%)
:arrow_down:

chainstate/client_options.go
87.23% <20.00%> (-2.48%)
:arrow_down:

chainstate/client_internal.go
52.11% <25.00%> (-2.30%)
:arrow_down:

model_draft_transactions.go
73.95% <50.00%> (-0.49%)
:arrow_down:

Continue to review full report in Codecov by Sentry.

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


LSP inlay hints

We could use inlay hints from LSP v3.17 for:

showing the inferred capabilities in a principled way ([{io}] def ...)
showing the inferred return types and effects of functions (def bar(x: Int) [: Int / Log] = ...)
showing the inferred types of bindings (val foo [: Int] = ...)
showing the expected & actual type of a typed hole ("answer is: " ++ <{ 42 [: Int] }> [: String])
showing the inferred boxes/unboxes?
showing the chosen overloads?
showing the argument names for functions with many arguments of the same type bank.transfer([from =] person1, [to =] person2)

(where [...] means an inlay hint)
Note that these would probably need to be highly configurable so that the code is still somewhat navigable. :)
As far as I can tell, we're already doing 1. in a somewhat ad-hoc way:
https://github.com/effekt-lang/effekt/blob/7b7629c942e2809cab08b0122e244ba3bcbb9410/effekt/js/src/main/scala/effekt/LanguageServer.scala#L138-L143
but it would be nice to use the LSP protocol instead.
There are also a lot of other quality of life related features like "if we already have an inlay, we can just double-click it to apply" like in rust-analyzer (see first video there for a demo).

How to start with this PR:

bump LSP4J in Kiama:

https://github.com/effekt-lang/kiama/blob/ab6aef78fc4ce99a9ad2db8555718d00b03f7b8a/build.sbt#L11

catch the textDocument/inlayHint event

https://github.com/effekt-lang/kiama/blob/ab6aef78fc4ce99a9ad2db8555718d00b03f7b8a/jvm/src/main/scala/kiama/util/Server.scala#L518-L519


Properly wrap and handle exceptions thrown by processCommand in the javadsl

In the javasdl for AggregateCommandModel specifically exceptions thrown by processCommand were not being correctly wrapped in a failed future.

Codecov Report

Merging #38 (b81449f) into main (065fd44) will increase coverage by 0.03%.
The diff coverage is 100.00%.

@@            Coverage Diff             @@
##             main      #38      +/-   ##
==========================================
+ Coverage   77.24%   77.27%   +0.03%
==========================================
  Files         162      162
  Lines        2896     2896
  Branches       71       70       -1
==========================================
+ Hits         2237     2238       +1
+ Misses        659      658       -1

Impacted Files
Coverage Δ

...in/scala/surge/javadsl/command/CommandModels.scala
20.00% <100.00%> (+20.00%)
:arrow_up:

...health/windows/actor/HealthSignalWindowActor.scala
91.11% <0.00%> (-1.12%)
:arrow_down:

Continue to review full report at Codecov.

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


Wrong type for build_absolute_uri function

The # type of build_absolute_uri function is outdated
def build_absolute_uri(location):
    # type: (str, bool, saleor.site.models.SiteSettings) -> str  # - problem there
    host = Site.objects.get_current().domain
    protocol = 'https' if settings.ENABLE_SSL else 'http'
    current_uri = '%s://%s' % (protocol, host)
    location = urljoin(current_uri, location)
    return iri_to_uri(location)

@mmmcorpsvit or @Pacu2 Could you edit the description to make it clear what needs to be fixed?

@maarcingebala done

comment there are doc-string, and have bad format
please see:
https://docs.python.org/3/library/typing.html
or
https://www.python.org/dev/peps/pep-0257/

i think must be
 # type: (str) -> str

Closed via #2929


Trust wallet integration

[ ] get client detection working

let's merge fixes into this PR/branch https://github.com/cosmology-tech/cosmos-kit/pull/93


KEM._nsecret Question

a short Question in Regards to the _nsecretAttribute. Is that attribute the Nsk from the RFC?
if yes then shouldn't it be

56 for KEMId.DHKEM_X448_HKDF_SHA512 instead of 64
66 for KEMId.DHKEM_P521_HKDF_SHA512 instead of 64

?
(according to https://www.rfc-editor.org/rfc/rfc9180.html#name-key-encapsulation-mechanism)
with best regards
Aurvandill

_nsecret is the Nsecret from the RFC.
Is there any problem?

I need the Nsk for the derive Key Pair function. an i misused the _nsecret. i will add the Nsk as _nsk Attribute in my PR if thats fine :)


Hello, some devices or instruments send merged DICOM files, which cannot be displayed in OHIF. Is there a solution to this

What feature or change would you like to see made?
Hello, some devices or instruments send merged DICOM files, which cannot be displayed in OHIF. Is there a solution to this

Why should we prioritize this feature?
Hello, some devices or instruments send merged DICOM files, which cannot be displayed in OHIF. Is there a solution to this

Could you kindly provide the data if it has been anonymized and you can confirm that there is no patient health information present in any of the headers or embedded within the pixel data?


Performance benchmarking

[ ] Reference docs on workload and the characteristics and use cases for each included load generator.
[ ] Tutorials on benchmarking cockroach with our load generators.

@arjunravinarayan, @bdarnell, does this seem doable as a 2.1 docs project. I'm assuming we'll leverage Arjun's whitepaper and other existing resources.

From @robert-s-lee: Our guidance needs to include graphing concurrency/throughput and resource/consumption for the each workload.

Run this workload.
Graph it.

Resources:

https://www.cockroachlabs.com/guides/cockroachdb-performance/
https://www.cockroachlabs.com/blog/2-dot-0-perf-strides/
https://www.cockroachlabs.com/blog/performance-part-two/
https://apple.github.io/foundationdb/performance.html

@arjunravinarayan's whitepaper has the core of what we need.

Core features and performance 2.1 okrs focus on:

tpcc
ycsb

Do we want to limit our docs to these?

our manual deployment docs now have a step, “Run a sample workload”, that shows how to get the workload binary and then use it to run tpcc against a cluster: https://www.cockroachlabs.com/docs/dev/deploy-cockroachdb-on-digital-ocean.html#step-9-run-a-sample-workload.
jesse put a callout in there linking readers to the performance white paper for benchmarking guidance, but once we have performance benchmarking docs, we can update that reference.


Add various spaceranger reports from the 10x website

Follow up of #256.
This adds various spaceranger reports from the 10x examples website, representing different software versions and protocol variants (FFPE vs. fresh frozen etc).

Perfect, this is what I was hoping would be available. Thanks!


Use CDN id instead of name to query

Errata Tool API doesn't work correctly with CDN names. Switching to querying with CDN ids.
Requesting lgtm and approve

/approve

Looks like errata tool API endpoint is working differently which caused this to break. We might need to roll this back once they have fixed it from their end, since other parts of the feature require us to get the cdn repo name. So in short, this is a temporary fix.


Sortable Column for those non-DataColumn?

In Yii1 if the column is not specified in DataProvider, there will not be any filter and we could not sort the table based on this column as well.
example. we have a column called Subtotal in Quotation_Item gridview.
it may looks like this
array(
            'header'=>'Subtotal',
            'value'=>'$data->getSubtotal()',
            'footer'=>'Total: '.$model->total,
        ),

But how about we add some variable like compare and filter
E.g.
array(
            'header'=>'Subtotal',
            'filter'=>'number',
            'compare' => 'number'
            'value'=>'$data->getSubtotal()',
            'footer'=>'Total: '.$model->total,
        ),

I post it here, so that i think that may be a sweet improvement in Yii2. Feel free to correct me, if i said anything wrong. Or we can implement a similar outcome by make some modification in Model instead of View?
I am apologized for my poor English.

for reference: http://www.yiiframework.com/wiki/653/displaying-sorting-and-filtering-model-relations-on-a-gridview/

docs are quite clear about this.


Make SSR's fetch send the referrer header when the destination is an endpoint

Is your feature request related to a problem? Please describe.
The referrer header can be really useful for some apps, but currently, when fetching an endpoint, only the client's fetch calls set the referrer header, not SSR's.
Describe the solution you'd like
Make SSR's fetch also set referrer header when the destination is an internal URL.
Svelte kit has almost everything it needs to construct the referrer url, lacking only the protocol.
The need for knowing the protocol also exists within svelte kit itself.
https://github.com/sveltejs/kit/blob/b4a851e4af1102de53ad6b09dee52438f2e7f330/packages/kit/src/runtime/server/page/load_node.js#L126-L130
Describe alternatives you've considered
Ask users to manually set this header themselves, but it's quite cumbersome once the header is needed in lots of places.
How important is this feature to you?
Not very, since there is a workaround, but I do have to pass the protocol in from an environment variable.
Additional context

As of #3631, load()'s fetch forwards most headers from the client.


Text min/max validator - count multi-byte character as one

I have this input for my field that has "max length" and it throws an error:

{
  "errorMessage": "comment: Must be less than 280 character(s)."
}

so, is this a known issue or there won't be configurations for these cases?

Hm, this is side-effect of Go's len() applied on non-ascii characters (in Go a single character could be 1-4 bytes).
I'll submit a fix later this weekend to cast the text value to []rune to properly count the multibyte characters.

I've submitted a small fix in master. It will be available with the next minor v0.19.4 release sometime later this weekend.


Datapipe Benchmarks

Modulus Pull Request
Related to issue here https://github.com/NVIDIA/modulus-launch/issues/117
Description
Implement datapipe benchmarks as an example that is easy for users to run. This will both allow us to show new users a compelling reason to use modulus while also allowing us to iterate on datapipe ideas such as zarr stores.
Checklist

[x] I am familiar with the Contributing Guidelines.
[x] New or existing tests cover these changes.
[x] The documentation is up to date with these changes.
[x] The CHANGELOG.md is
up to date with these changes.

/blossom-ci

/blossom-ci

/blossom-ci

Closing since PR should move to core repo.


Trap in canister_pre_upgrade when callback count is non-zero

Fixes #2676
Although this appears to do the right thing for the replica (drun), it seems superfluous for ic-ref.
@nomeata does ic-ref already wait for the call back queue to drain before doing an upgrade?

This PR does not affect the produced WebAssembly code.

Hmm, I wonder if the test might be flaky, because its output depends on the interleaving of repeat and upgrade....

@rossberg PTAL

Luc Mercier once voiced strong reservation against trapping in the pre_upgrade hook. I'll try to find the message (Slack?).

Luc Mercier once voiced strong reservation against trapping in the pre_upgrade hook. I'll try to find the message (https://dfinity.atlassian.net/browse/NNS1-318). The context is different, but worth some analysis. The Slack thread is added for completeness.

I think you have a point here. If have leak in the closure table, we won't be able to upgrade.
However, I think we still want to avoid the possibility of corruption, so  I suggest we trap only if the canister isn't stopped and has pending callbacks. That means stopping the canister first will always prevent this trap.
This should be our friend for that check:
https://sdk.dfinity.org/docs/interface-spec/index.html#system-api-canister-status

@ggreif PTAL. I've modified the code to avoid trapping when the canister is stopped, so that should make it less likely that we paint ourselves into a corner with a leaking closure table.


Miniquests not auto-updating quest list

Enter the Abyss quest did not get removed from the list upon completion.
There is no quest completion screen for the miniquest & as such requires the plugin the refresh to update the quest list.
Will likely just add an right click option to refresh the quest list upon right clicking the Optimal Quest Guide header to account for this unless I can come up with something else.

I believe this issue is solved with and closed with commit 928206f71ecbf7769d0d301852ef376413e76ca3


"x" can delete end of line

if i use CMD+Left to reach the end of the line instead of "$" the cursor gets past the last character up to the EOL character. At this point hitting "x" deletes the '\n' and the next line is sucked up in the current one.
This may not be strictly vim-mode related

As stated in the README, this package is no longer maintained and is deprecated. We recommend that people use the vim-mode-plus package instead. Because of this, we are archiving this repository and closing all issues and pull requests. Thanks very much for your support and contributions!


[TACHYON-515] Tachyon Worker Improvement

https://tachyon.atlassian.net/browse/TACHYON-515
This is a rebased version of the worker_wip branch.

Should WorkerStorageIntegrationTest.java and BlockHandlerLocalIntegrationTest.java be deleted, because they are not relevant any more?

I noticed that the block store events are handled synchronously. If more event listeners are added or if a listener handles the events slowly, this would impact the performance. I think we can implement an async one. The event producer simply posts the event messages to a pool. A background thread infinitely picks a message and posts it to the listeners. This would minimize the performance impact of the listeners like metrics reporter to the whole system.

Since evictor will not allocate space for blocks to be evicted, so it is not necessary to have list of toEvict and toRemove blockIds.
it is better to just let the caller to decide whether the blocks needs to be removed or to move to other location.

and the logic in freeSpaceInternal in TieredBlockStore is not right under current implementation.

@carsonwang
This is a good point, the downside is the listeners will all be required to be best effort, since there is no longer any guarantee that the callback will be executed when the event actually occurs (ie. onRemoveBlock may be called much later than when the block is actually removed, for an evictor, this could cause it to incorrectly report which blocks to evict).
Another solution may be to include two different listener types, synchronous and asynchronous?
@uronce-cc Do you think the LRUEvictor would be much more complicated if it was using an async listener?

Jenkins, test this please.

@shimingfei , could you be more specific about the incorrect part?
Also I don't quite understand the comment "since evictor will not allocate space for blocks to be evicted, so it is not necessary to have both toEvict and toRemove blockIds."  Our hypothesis is that where to move an evicted block is a part of eviction heuristic and if we hardcode this in TieredBlockStore (which actually is relatively easy), it leaves less room for different eviction policies.

@shimingfei , freeSpaceInternal does a have problem that we are not executing block movement in the order from bottom tier to upper tier---we will fix this. Is this what you are concerning?

@apc999
yes, It is what I am concerning, it seems only toEvict is used in Evictors. and the logic in freeSpaceInternal doesn't think so.

@shimingfei, I think you raised a very good point that "there should be different strategies to put the evicted blocks". Currently GreedyEvictor is a simple and almost naive way to do it. And our expectation of this particular evictor is that people can learn how to implement Evictor. Especially, asynchronous evictor will be very important and extremely useful, though it is probably out of scope of this PR.
Let's definitely work on enabling more practical and interesting ways of evicting blocks later on, either improve the current ones, or create new ones.

+1 LGTM

LGTM
Thanks to everyone who worked on this!

+1 LGTM

servers/src/main/java/tachyon/worker/SpaceCounter.java is no longer used but still in the code base.

Thanks for everyone working on this!


Updated dockerfile for Raspian

Updated the dockerfile for Raspian builds to eliminate dependence of non public available dev-image.

It may be a good idea to use different root filesystems on a raspberry pi with different dependencies. Cancelling the pull request.


Allow to keep working directory between runs instead of deleting

Currently we delete the working directory betweens all run, we could keep it and re-use what didn't change.

We will need to cache some kind of Mapping from the list of jars to the list of package names to be able to know what's already there and what's not.

https://github.com/mvnpm/esbuild-java/pull/76


Provide Linux tc scripts for delay-based location spoofing

I've been in a traffic analysis rabbit hole lately, and also have been pondering latency characteristics of a much faster Tor. As Tor's congestion decreases due to optimizations and utilization drops due to more capacity, circuit latency may begin to reflect actual Internet topology latency due to distances alone. After a few entry guard rotations, this feels like it will leak geographic information of the endpoint.
asn also pointed out that if we're going to try to conceal the use of onionbalance, we are also going to need to deal with timing characteristics of RP circuits built by contacting different intropoints, especially for cases with different vanguards.
I think this means we should add a pair of Linux tc scripts/components to the repo.
One script/component should allow you to add latency characteristics similar to your server's non-Tor distance from an arbitrary other site (by accumulating ping times to a site of your choice and using that data to set tc delay distrubtions).
The second script/component should let you use the delta in average latency over RP circuits to a onion site hit from specific intropoints to add delay to whichever of your onionbalance instances happen to have lower latency than the others, on average.
The first script is far easier to write, and likely far more useful. So let's focus on that for now, and see if we still want the second one.
This Linux tc summary is the best quick overview I've found so far:
https://stackoverflow.com/questions/614795/simulate-delayed-and-dropped-packets-on-linux
With multiple guards, we may even want to specify different latency distributions to be added to each guard IP. This is also possible:
https://serverfault.com/questions/389290/using-tc-to-delay-packets-to-only-a-single-ip-address

I have used tc many many years ago for prioritizing Tor Relay traffic below other traffic on my machine, and for other network diagnostics. It is capable of doing the things I described above, but I have not yet begun work on this specific ticket.

Note to self: There's an interesting version of this where the client or relay decides to add a per-circuit delay according to a probability distribution, such as one from the circpad probdists.
Let the record show that I am against adding delay at relays, because this causes queuing memory overhead: https://github.com/torproject/tor/blob/main/doc/HACKING/CircuitPaddingDevelopment.md#14-other-deployment-constraints
If congestion control brings queue lengths down, maybe there will suddenly be some more room for that queuing memory at relays, and maybe the oomkiller and congestion control can minimize this overhead. However, because bandwidth is still increasing exponentially, and the speed of light is fixed, I think the best thing for relays to do is add traffic, not delay packets.
Instead, a delay could be decided locally per-circuit or per-identity by the client, and thus not require relays to queue data at all. The client would just use this delay to spoof circuit latency, to conceal its geographic location.
Related ideas: https://www.freehaven.net/doc/alpha-mixing/alpha-mixing.pdf
Credit for this tip goes to "online discussion". Thanks, time traveler.


Proximity scan doesn't handle more than 5 devices well

When 6 or more badges appear in the scan, badge sends incorrect packages to the hub, casing an error. It seems that the first package (20 bytes) is correct - 4 bytes for each of the first 5 devices. The next package is 5 bytes long, where the first 4 appears to contain a valid scan data, and the 5th byte is an error.
Looking at the badge debug logs, it seems that the problem is in storing:
SCANNER: Saving scan results. 6 devices seen
C:8
bdg ID#0000, rssi -98, count 34
bdg ID#DFE4, rssi -63, count 7
bdg ID#5F7D, rssi -65, count 6
bdg ID#2EB6, rssi -76, count 5
bdg ID#2660, rssi -88, count 3
bdg ID#A7F9, rssi -72, count 6
SCANNER: Done saving results.  used 1ADV: advertising paused, src 0.
STORER: writing SCAN chunk 8 to EXT chunk 616
The storer should have allocated the 6th device to a second chunk. Instead, it appears to add it to the first chunk. The log shows that only one chunk is being stored.
It seems to be a memory leak of some kind. If you compare the log to a 5 badges log,  you can see that the SCANNER:Done line gets cut off:
SCANNER: Saving scan results. 5 devices seen
C:7
bdg ID#0000, rssi -96, count 35
bdg ID#5F7D, rssi -66, count 6
bdg ID#2660, rssi -96, count 2
bdg ID#DFE4, rssi -62, count 7
bdg ID#2EB6, rssi -71, count 5
SCANNER: Done saving results.  used 1 chunks.
ADV: advertising paused, src 0.
STORER: writing SCAN chunk 7 to EXT chunk 625

Correction - each chunk can hold 29 devices. But there's still something funny going on there.

The printouts don't seem to indicate a problem - they seem to just get messy if we write too many logs, or if the bluetooth stack kicks in in the wrong time. Closer inspection shows that the problem seems to be in the sending code (and not the storing code). When printing the size of the buffer the badge sends, we see that the size of the first data buffer sent (after the 9 bytes header) is 5, instead of 20:
SENDER: sending scans since: s:P c:887
SENDER: sending buffer size: 9
SENDER: sending buffer size: 5
SENDER: sending buffer size: 5
SENDER: sending buffer size: 20
SENDER: sending buffer size: 20

Wrong calculation for buffer size when the number of stored scan results was more than 5. Fixed in merge #59


Update CONTRIBUTING.md

Fix typo in their

Ok don't 🤷♀

Maybe I did something wrong. I hadn't finished reading CONTRIBUTING.md after all.


Bulk index to AWS elasticsearch with gzip enabled returns error

Looks like AWS does not support gzip request body in the _bulk API? However gzip response in the _search API is supported. Anyone facing the same issue?
ES version used:  5.3
{
    "root_cause": [
        {
            "type": "json_parse_exception",
            "reason": "Illegal character ((CTRL-CHAR, code 31)): only regular white space (\\r, \\n, \\t) is allowed between tokens\n at [Source: org.elasticsearch.common.bytes.BytesReference$MarkSupportingStreamInputWrapper@208f7d36; line: 1, column: 2]"
        }
    ],
    "type": "json_parse_exception",
    "reason": "Illegal character ((CTRL-CHAR, code 31)): only regular white space (\\r, \\n, \\t) is allowed between tokens\n at [Source: org.elasticsearch.common.bytes.BytesReference$MarkSupportingStreamInputWrapper@208f7d36; line: 1, column: 2]"
}

Are you sure that gzip is supported by AWS Elasticsearch Service on any api? My understanding is this is a cluster configuration setting that AWS hides behind their service implementation, and is not accessible. I did see a thread on the AWS forums where people are still requesting the ability to use gzip on their hosted clusters (https://forums.aws.amazon.com/thread.jspa?threadID=223784). It may be that gzip from AWS ES Service is not supported at all, since it's a cluster setting and not a domain (or index) setting.

From what I read in the AWS forums, this is actually not supported by AWS yet. Not an issue of the Jest lib for sure.


Font: Add support for Konsole

Adds support for konsele font detection. Needs get_ppid() from 315ae5209a55a5b9b3e7ba0d11f3fe6a5afbea5a

LGTM :+1:
I'll do some more testing of #562 before I merge it. Once that's done I'll merge this.
Thanks!

Thanks again!


[Feature] Support for conventional changelog

Conventional changelog is a commit convention from angular. I think it is really nice and also very readable for everyone.
There is a node dependency called commitizen where you use git cz instead of git commit, git cz works same like git commit but you go through a command line tool which supports you with writing a conventional commit.
I think it would be very nice to have support for this :)
Greetz

@KapuzenSohn you can use the changelogCommand property in .release-it.json.

Oh yeah, you are right. I forgot that there was a command for that.

I will close this issue for now

If I'm not wrong, release-it executes changelogCommand before bumping version in package.json
conventional-changelog expects having the version bumped before the execution of the command, resulting in conventional-changelog to not identify the new version correctly.
Is there any chance to generate the changelog just after bumping?

@jmendiara you could put it in e.g. src. beforeStageCommand.

yeah, but is it possible by using the CLI?

@jmendiara It should be (I think e.g. src.beforeStageCommand="my cmd" should work). You can also put it in a local .release.json file.


Metallb Network Load balancer

This looks great. I'm just curious whether you considered metallb for load balancing?
https://github.com/google/metallb
This would mean zero changes required to yaml when moving from say GKE to hetzner, unless I'm missing something.

@EamonKeane when I investigate MetalLB project some time ago it need to have control of router (ad need to have a router speaking GDB protocol inside the network).
Hetzner do not offer this kind of infrastructure (as far I know), to you have time to investigate if it can be used or have some suggestion about MetalLB usage?

Thanks @mavimo . Metallb also has a layer 2 mode which assigns node IPs to your reverse proxy (e.g. nginx-ingress). I have it working on a (one node) cluster using the VM IP that Hetzner assigned. For whatever reason, using a second Floating IP assigned to the same VM doesn't work.

@EamonKeane interesting! Can you share some more detail (if possible) of your current configuration? Config files, how do you setup it & c should be really useful information to investigate it :)

@mavimo sure. Steps to reproduce what I have are:

Create a one node hetzner cluster (I use 8 core/32 gb ram)
Install kubeadm (I used 1.12.1 and weavenet but not sure that matters)
Change the assigned VM IP on this line:
https://github.com/EamonKeane/k8s-cluster-services/blob/master/cluster-svc/values.yaml#L19
Helm install the cluster chart (you only need to have metallb and nginx-ingress set to enabled)
https://github.com/EamonKeane/k8s-cluster-services/tree/master/cluster-svc
Go to $VM_IP and you should see the default backend of nginx-ingress

I am trying to set this up. having an external LoadBalancer is absolutely essential for me. Anyone has successful set up with a two node cluster ? @EamonKeane

https://community.hetzner.com/tutorials/install-kubernetes-cluster/
A tutorial with metallb/kuberbetes on hetzner cloud maybe helpful


Update version and make pip installable

I wanted to use the new version of JupyterLite, but couldn't get the install to work without updating this package as well. Along the way I made some changes to make it easier to install with pip/poetry, and wanted to share those back with you. These changes are modeled after the kernels I saw in the Jupyter org repos (like jupyterlite/xeus-python-kernel). Here's a summary:

Upgrade WebR  to v0.2.x
Upgrade JupyterLite to v0.2.x
Upgrade JupyterLab to >=4, <5
Replace setup.py with a pyproject.toml + Hatch --- now you can just pip install this repo (README.md updated to reflect this)

The last one deserves a bit more explanation, which I gave in the commit:

This commit re-structures the repository's build and environment to work more like the other JupyterLite kernels, where you can just install them like other JupyterLab extensions.
The build system now uses Hatch, but still pulls relevant info from package.json to keep the metadata DRY. Because it now uses Hatch, the setup.py's contents are replaced with a pyproject.toml, jupyter-packaging is replaced by the hatch-jupyter-builder, and the manifest is no longer needed.
For convenvience, an environment.yml is included to help setup a conda/mamba/micromamba/etc. environment for developers.

Oh good idea --- I'll add and test that out without conda

Okay -- I added JupyterLite as a dependency and JupyterLab as a dev dependencies and tested out both installs in a clean venv


javascript-file: Don't strip extension from file names

fixes https://github.com/OctoLinker/browser-extension/issues/271
This allows paths like ./modules/es6.symbol to correctly resolve to
./modules/es6.symbol.js
For example: https://github.com/zloirock/core-js/blob/0bb657cfc7834d03fd68c48a1cba70f2ccab20c0/shim.js#L1
EDIT:
Removing the fileExt code didn't break any tests, but I'm not sure if it breaks any functionality in practice. @stefanbuck, do you know why it was there?

Not from top of my head. I'll have a look later today

An issue occurs when the path contains a file extension. Before ./modules/es6.symbol.js was resolved to
{BASE_URL}modules/es6.symbol.js
{BASE_URL}modules/es6.symbol/index.js
{BASE_URL}modules/es6.symbol.jsx
{BASE_URL}modules/es6.symbol/index.jsx
{BASE_URL}modules/es6.symbol.ts
{BASE_URL}modules/es6.symbol/index.ts
{BASE_URL}modules/es6.symbol.tsx
{BASE_URL}modules/es6.symbol/index.tsx
{BASE_URL}modules/es6.symbol.json
{BASE_URL}modules/es6.symbol/index.json
{BASE_URL}modules/es6.symbol

Every line is invalid here, except the fist one. Now it's the opposite, only the last line is valid. This results in many unnecessary requests which leads to loading delays.
{BASE_URL}modules/es6.symbol.js.js
{BASE_URL}modules/es6.symbol.js/index.js
{BASE_URL}modules/es6.symbol.js.jsx
{BASE_URL}modules/es6.symbol.js/index.jsx
{BASE_URL}modules/es6.symbol.js.ts
{BASE_URL}modules/es6.symbol.js/index.ts
{BASE_URL}modules/es6.symbol.js.tsx
{BASE_URL}modules/es6.symbol.js/index.tsx
{BASE_URL}modules/es6.symbol.js.json
{BASE_URL}modules/es6.symbol.js/index.json
{BASE_URL}modules/es6.symbol.js

Hmm, I see what you're saying. That is a bit tricky... What if we assume that paths ending in a js/ts/json extension are paths to files, rather than paths to folders? Of course, a reference to a folder named ./modules/es6.symbol.js would still fail to be correctly resolved to {BASE_URL}modules/es6.symbol.js/index.js, but this seems like a much smaller edge case. I think people are less likely to end folder names with .js (or similar extensions) than they are to put a dot in a filename.
I'll push up a couple of commits that implement this approach. Let me know what you think.

I agree with you, that it's less likely to end folder names with file extensions, but there is another issue. A folder could also contain a dot as a delimiter like config.dev. Since path.extname() doesn't know if the last portion  is a "real" file extension or just a string this wouldn't work.

The path.extname() method returns the extension of the path, from the last occurrence of the . (period) character to end of string in the last portion of the path.

https://nodejs.org/api/path.html#path_path_extname_path
The behaviour after your refactoring was correct. Just the fact that the most common case was at the end of the array was worrying me.

Since path.extname() doesn't know if the last portion is a "real" file extension or just a string this wouldn't work.

The current changes make it so that only the ['.js', '.jsx', '.ts', '.tsx', '.json'] extensions are considered to be "real" file extensions, so I don't think this is a big problem: https://github.com/OctoLinker/browser-extension/pull/273/commits/e19c030cf89d5b46b222d9c56462ca175adb649b#diff-e822edbd04f428360d5ab5038457a35fR10

Alternatively, I could revert the two WIP commits to go back to the initial refactoring, but then add a condition that tries the "extension-less" path first if the path already ends in a  ['.js', '.jsx', '.ts', '.tsx', '.json'] extension. What do you think?

I haven't seen the new commits, because they didn't appeared after you comment 😊 Anyway, that looks pretty good now 👍

Oops, I didn't consider that! In the future, I'll try to push changes before making comments. Thanks for the merge!
P.S. If you'd like to get emails when commits are added in a pull request, you can use the Pull Request pushes checkbox here: https://github.com/settings/notifications

No worries, it was my fault. Next time I'll look twice.


Early Stopping Criterion for Mert

Since often the tuning stage (MERT) is too expensive in terms of time wrt the benefits in terms of final translation quality, it would be worty to investigate on early stopping criteria, for example by checking the trend of the BLEU score on the development set instead of looking only at the changes of weight values or of the BLEU score got by rescoring the n-best lists.

Quick update
I added to mert-moses.perl an early stopping criterion based on the comparison between the BLEU score on the development set at the current iteration and the mean of the scores in a window of previous iterations. By setting properly the score difference threshold and the history window size, on 14 IWSLT 2017 tasks (language pairs) I observed the following behaviour wrt the previous version without the new criterion:

number of MERT iterations: (mean=6.1, min=3, max=10) vs. (mean=9.9, min=3, max=20)
average loss in BLEU score on test sets: absolute(0.02, min=-0.20, max=+0.16), percentage(0.10%, min=-1.24%, max=+0.63%)
Of course, it is possible to save even more iterations, at the cost of higher losses.
Likely, this novel additional stopping criterion deserves to be committed. Before doing it, I'm going to further assess it on more problematic IWSLT pairs for MERT (like Japanese-English and Chinese-English) and other benchmarks.

Two setups of the early stopping criterion have been devised, the default and the fast (more aggressive). The experiments on 26 IWSLT 2017 language pairs say that wrt the MERT without such an additional criterion:

default setup:
-- average number of MERT iterations: from 9.5 to 5.4 (-43%)
-- range of number of MERT iterations: from [3,25] to [3,10]
-- absolute BLEU score loss: average=0.03, max=0.88 (on one Japanese-English test set)

fast setup:
-- average number of MERT iterations: from 9.5 to 3.9 (-59%)
-- range of number of MERT iterations: from [3,25] to [3,7]
-- absolute BLEU score loss: average=0.15, max=0.88 (as above)

Note that the most problematic pair is the Japanese-English, for which the saving of 15 MERT iterations (from 22 to 7) in both setups is paid with an absolute BLEU degradation of 0.88 and 0.60 on the two test sets.

Hi @cettolo
given the fact that the max loss in BLEU is exactly the same in both cases I'm wondering if the best option could be to have a default behaviour that acts like your suggested "fast setup", while adding a flag --best-performance that completely disable such criterion and give us the old best-quality long-time consuming MERT process.
What do yo think?

Even if the max is the same, the fast setup is definitely less safe; here, the top 10 losses in the two cases:
-- fast: 0.88 0.80 0.71 0.60 0.59 0.55 0.48 0.47 0.46 0.45
-- default:      0.88 0.60 0.60 0.27 0.17 0.15 0.15 0.11 0.10 0.10
If you accept by default a loss of 0.3 BLEU points in half of the cases, go on with the switch between the two setups, otherwise keep the safer setup as the default

@cettolo
I have just pushed your work on the master branch. Now mmt tune supports the --accuracy option, possible values are:

default: it's your "default" setup, best trade-off
best: old-plain MERT process for best performances but slowest process
fast: it's your "fast" setup, super-fast MERT, not optimized for translation quality

Thanks!


Wrath of Jǫrmungandr inconsistence font

We'll be adding new font options in 3.2.0. You'll be able to pick and chose which one renders better for the language and items you use the most. It's very hard to find fonts that have proper support for everything, considering the game now has items with foreign characters.

Fixed by #194


OpenSSL::X509::StoreError: setting default path failed: Detect premature EOF

I'm getting the following error when trying to run the logstash container on RHEL 7.1:
OpenSSL::X509::StoreError: setting default path failed: Detect premature EOF
  set_default_paths at org/jruby/ext/openssl/X509Store.java:185
             (root) at /usr/share/logstash/vendor/jruby/lib/ruby/shared/jopenssl/load.rb:26
            require at org/jruby/RubyKernel.java:1040
             (root) at /usr/share/logstash/vendor/jruby/lib/ruby/shared/openssl.rb:1
            require at org/jruby/RubyKernel.java:1040
             (root) at /usr/share/logstash/vendor/jruby/lib/ruby/shared/openssl.rb:1
            require at org/jruby/RubyKernel.java:1040
             (root) at /usr/share/logstash/logstash-core/lib/logstash/patches/stronger_openssl_defaults.rb:1
            require at org/jruby/RubyKernel.java:1040
             (root) at /usr/share/logstash/logstash-core/lib/logstash/patches/stronger_openssl_defaults.rb:2
            require at org/jruby/RubyKernel.java:1040
             (root) at /usr/share/logstash/logstash-core/lib/logstash/patches.rb:1
            require at org/jruby/RubyKernel.java:1040
             (root) at /usr/share/logstash/lib/bootstrap/environment.rb:67

Image created with the same Dockerfile works on Mac OS X developer machines.
[root@phorsma]# docker --version
Docker version 1.8.2-el7, build a01dc02/1.8.2
[root@phorsma]# uname -r
3.10.0-229.14.1.el7.x86_64
[root@phorsma]#

My Dockerfile:
FROM logstash:5

MAINTAINER  Panu Horsmalahti<EMAIL_ADDRESS>
# Copy Oracle JDBC Driver
COPY lib/ojdbc6.jar /opt/ojdbc6.jar

COPY logstash.conf /config-dir/

CMD ["-f", "/config-dir/logstash.conf"]

I'm using Kontena to deploy the container (shouldn't matter I think).
Running inside container:
root@88e758eedb19:/usr/share/logstash# apt-get install ruby
root@88e758eedb19:/usr/share/logstash# ruby -v -ropenssl -rfiddle -e 'puts Fiddle::Function.new(Fiddle.dlopen(nil)["SSLeay_version"], [Fiddle::TYPE_INT], Fiddle::TYPE_VOIDP).call(0)'
ruby 2.1.5p273 (2014-11-13) [x86_64-linux-gnu]
OpenSSL 1.0.1t  3 May 2016

I get the same error from logstash:2.1.3-1. The same server works with logstash:1.5.5.
A wild guess is that the error is related to https://github.com/elastic/logstash/issues/3955

I can replicate the issue like this:
docker run -ti logstash:5 /bin/bash
root@3639bf9d2fd3:/# logstash

If I delete java folder froms certs:
root@3639bf9d2fd3:/# rm -rf /etc/ssl/certs/java

I can now run logstash fine inside the container.

My workaround is as follows:
Create starth.sh:
#!/bin/bash
rm -rf /etc/ssl/certs/java
logstash -f /config-dir/logstash.conf

And then in Dockerfile:
COPY start.sh /start.sh
CMD /start.sh

An alternative is simply having this in Dockerfile:
RUN rm -rf /etc/ssl/certs/java

Any idea what's causing the failure?  The image itself should be isolated from the host environment pretty well by Docker.
Can you run docker inspect on a container which reproduces the problem and paste the output here?

This image is officially deprecated in favor of upstream's images (see https://www.elastic.co/guide/en/logstash/current/docker.html).
For more information, please see https://github.com/docker-library/elasticsearch/pull/160, https://github.com/docker-library/docs/pull/842, and https://github.com/docker-library/docs/pull/945.

This image has been deprecated in favor of the official logstash image provided and maintained by elastic.co. The upstream images are available to pull via docker.elastic.co/logstash/logstash:[version] like 5.4.2. The images found here will receive no further updates once the 5.6.0 release is available upstream. Please adjust your usage accordingly.
Elastic provides open-source support for Logstash via the elastic/logstash GitHub repository and the Docker image via the elastic/logstash-docker GitHub repository, as well as community support via its forums.

Thanks!