 The stats one deserves a look from a subject matter expert IMO, I'm not comfortable assessing if the sample sizes can just change or a more invasive change is needed to keep the example sensible.

Uhm, sorry, to clarify: I think the multiscale_graphcorr could/should be looked at by a subject matter expert, so there's no need to lump it together with lsq_linear of this PR. So this PR is ready to go in, IMO.

Thanks, the change makes sense.
The example output should be updated to reflect the change in size.  It looks like this causes the typical number of iterations to be lower, and the typical costs differ by an order of magnitude compared to the larger case.  The numbers will vary, but they should probably continue to reflect a "typical" result from the input sizes used in the example.

Thanks for the catch Warren. Updated to match the return message locally.

I don't recall the scope of # may vary.  It looks like the occurrence of # may vary in an output section applies to all lines in that output, and not just the one line where is occurs.  Is that correct?

Yes, # may vary should apply to the whole output, multiline or not. Dropping a breakpoint at https://github.com/scipy/scipy_doctest/blob/main/scipy_doctest/impl.py#L285 gives:
(Pdb) p want
'# may vary\nThe relative change of the cost function is less than `tol`.\nNumber of iterations 16, initial cost 1.5039e+04, final cost 1.1112e+04,\nfirst-order optimality 4.66e-08.\n'
(Pdb) p got
'The relative change of the cost function is less than `tol`.\nNumber of iterations 16, initial cost 1.4910e+04, final cost 1.1015e+04, first-order optimality 6.95e-08.\n'

(this is on main not this PR for a random reason)

thanks both!


Can’t find API spec

It looks like the API spec link is giving a 404.
https://github.com/GoogleCloudPlatform/spark-on-k8s-operator/blob/master/docs/api.md
I’m trying to figure out how to add an argument to the main class that I would like to run.

The API spec doc has been moved to https://github.com/GoogleCloudPlatform/spark-on-k8s-operator/blob/master/docs/api-docs.md.

Which link directed you to https://github.com/GoogleCloudPlatform/spark-on-k8s-operator/blob/master/docs/api.md? Looks like some existing links need to be fixed.

https://github.com/GoogleCloudPlatform/spark-on-k8s-operator/blob/master/docs/user-guide.md
The first mention of api spec is a broken link. Thanks!

The broken link has been fixed.


Unexpected keyword argument when using keywords with '__'

When using osidb-bindings and querying "params={'reported_dt__date__lte': "2022-07-26", 'component': "kernel", "include_fields": "cve_id,title,impact,type"}" I get the following error:
Traceback (most recent call last):
  File "/Users/redhat/srt/vdanen/scripts/osidb/osidb-client.py", line 52, in <module>
    resp = session.flaws.retrieve_list(**params)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/opt/homebrew/lib/python3.11/site-packages/osidb_bindings/session.py", line 279, in retrieve_list
    sync_fn(*args, client=self.client(), **kwargs), *args, **kwargs
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
TypeError: sync() got an unexpected keyword argument 'reported_dt__date__lte'

But using the same with curl directly works:
$ curl 'https://HOST/osidb/api/v1/flaws?reported_dt__date__gte=2022-07-26&include_fields=cve_id,reported_dt' | jq

unsure - the binding might expect a datetime value in python ... you might try that ...

@xquery is right about the need of the python datetime value, currently the string is not supported (it is definitely doable, it just wasn't requested yet), however the problem here is something else. Package openapi-python-client handles double underscore params in a weird way and internally it expects reported_dt_date_lte instead of reported_dt__date__lte and it only uses the double underscores when making the request.
We've already had to workaround this in griffon too (https://github.com/RedHatProductSecurity/griffon/pull/181/commits/a46258b3f5df0e435241e0585a864784602320dc)
We've never had any double underscore query params in OSIDB until now so it wasn't an issue before. Current workaround is to use single underscores instead of double underscores but I will try to tamper with the bindings templates to force the double underscores names.


Bug | zmath: segfault on returning an anonymous struct directly

OS: MacOS
System: Intel i7 (Macbook Pro 2019)
Zig Version: 0.9.1
EXC_BAD_ACCESS (code=EXC_I386_GPFLT)
I am not sure if this is a library issue:
// causes a segfault on accesing sc[1] (address is supposedly 0x0?)
pub fn rotationZ(angle: f32) Mat {
    const sc = sincos(angle);
    return .{
        f32x4(sc[1], sc[0], 0.0, 0.0),
        f32x4(-sc[0], sc[1], 0.0, 0.0),
        f32x4(0.0, 0.0, 1.0, 0.0),
        f32x4(0.0, 0.0, 0.0, 1.0),
    };
}
// this 'fixed' version works fine
pub fn rotationZ(angle: f32) Mat {
    const sc = sincos(angle);
    const result = .{
        f32x4(sc[1], sc[0], 0.0, 0.0),
        f32x4(-sc[0], sc[1], 0.0, 0.0),
        f32x4(0.0, 0.0, 1.0, 0.0),
        f32x4(0.0, 0.0, 0.0, 1.0),
    };

    return result;
}

What compiler version do you use?

@skrax Can you also run zig build test in the project root directory? There are some tests for rotationZ and they work fine on my machine (Windows, Linux, x86_64).

@michal-z the tests run fine on 0.9.1
I will try checking out 0.10 later

I see, thanks. Test uses rotationZ like this:
    {
        const m0 = matFromAxisAngle(f32x4(0.0, 0.0, 1.0, 0.0), math.pi * 0.333);
        const m1 = rotationZ(math.pi * 0.333);
        try expect(approxEqAbs(m0[0], m1[0], 0.001));
        try expect(approxEqAbs(m0[1], m1[1], 0.001));
        try expect(approxEqAbs(m0[2], m1[2], 0.001));
        try expect(approxEqAbs(m0[3], m1[3], 0.001));
    }

Hello Michal and skrax,
I am getting the error below when trying to run the tests on my M1 Mac mini (Big Sur) with zig master branch built today (0.10.0-dev.1860+7b090df66):
 wilsonk  ~  zig-gamedev   main  zig build test -Drelease-fast -Ddawn-from-source=true
All 9 tests passed.
All 4 tests passed.
LLVM Emit Object... error(link): undefined reference to symbol '_sincosf'
error(link):   first referenced in '/Users/wilsonk/zig-gamedev/zig-cache/o/bede7d83f1692d97996a78a4dce04395/test.o'
thread 2335881 panic: attempt to unwrap error: UndefinedSymbolReference
/Users/wilsonk/Downloads/zig/src/link/tapi/yaml.zig:59:28: 0x10337fa83 in link.tapi.yaml.Value.asList (zig1)
        if (self != .list) return error.TypeMismatch;
.
.
.

I get the error with or without -Dtarget=aarch64-macos-gnu and in Debug or Release. This does seem to be a problem with zig/macos though, as per this thread: https://github.com/ziglang/zig/issues/10318
Perhaps this is related to the issue here? Not sure.
Would you like me to open a separate issue for this failing test on macos?

Hi and thanks for the report.
@wilsonk I think that this is a different issue than reported by @skrax .
zmath itself does not use sincos provided by Zig - only tests do (zmath has it's own simple implementation of scalar sincos).
Tests run fine for @skrax so I think he is hitting an compiler bug specific to his use case.
I think that you are indeed hitting ziglang/zig#10318. Yes, please open a separate issue.

@skrax Can you share more context? How do you call rotationZ?

@michal-z I just built zig master and it seems to be working great so far. It is in fact a compiler issue, as we have suspected. It seems like SIMD structures are an issue on Apple as of version 0.9.1.


insertion.cpp

I want to add this code. @AdarshAddee

I would like to add my code. Please assign.


docs/governance/2023-agm-minutes: Add brief summary of talking points

[x] Have you followed the guidelines in our Contributing document?
[x] Have you checked to ensure there aren't other open Pull Requests for the same change?
[x] Have you added an explanation of what your changes do and why you'd like us to include them?
[ ] Have you written new tests for your changes? Here's an example.
[ ] Have you successfully run brew style with your changes locally?
[ ] Have you successfully run brew typecheck with your changes locally?
[ ] Have you successfully run brew tests with your changes locally?

We held the 2023 AGM in February. Let's document the high-level talking points in a public place like we did for previous years.

Thanks @issyl0!


Can't resolve '@redux-saga/core' in latest version

Steps to reproduce
on package.json:
...
"redux-saga": "^1.1.3"
...
npm i
Description of the bug/issue
[webpack-cli] ModuleNotFoundError: Module not found: Error: Can't resolve '@redux-saga/core' in '/app/node_modules/redux-saga/dist'
    at /app/node_modules/webpack/lib/Compilation.js:925:10
    at /app/node_modules/webpack/lib/NormalModuleFactory.js:401:22
    at /app/node_modules/webpack/lib/NormalModuleFactory.js:130:21
    at /app/node_modules/webpack/lib/NormalModuleFactory.js:224:22
    at /app/node_modules/neo-async/async.js:2830:7
    at /app/node_modules/neo-async/async.js:6877:13
    at /app/node_modules/webpack/lib/NormalModuleFactory.js:214:25
    at /app/node_modules/webpack/node_modules/enhanced-resolve/lib/Resolver.js:213:14
    at /app/node_modules/webpack/node_modules/enhanced-resolve/lib/Resolver.js:285:5
    at eval (eval at create (/app/node_modules/webpack/node_modules/tapable/lib/HookCodeFactory.js:33:10), <anonymous>:15:1)
    at /app/node_modules/webpack/node_modules/enhanced-resolve/lib/UnsafeCachePlugin.js:44:7
    at /app/node_modules/webpack/node_modules/enhanced-resolve/lib/Resolver.js:285:5
    at eval (eval at create (/app/node_modules/webpack/node_modules/tapable/lib/HookCodeFactory.js:33:10), <anonymous>:15:1)
    at /app/node_modules/webpack/node_modules/enhanced-resolve/lib/Resolver.js:285:5
    at eval (eval at create (/app/node_modules/webpack/node_modules/tapable/lib/HookCodeFactory.js:33:10), <anonymous>:27:1)
    at /app/node_modules/webpack/node_modules/enhanced-resolve/lib/DescriptionFilePlugin.js:67:43
resolve '@redux-saga/core' in '/app/node_modules/redux-saga/dist'
  Parsed request is a module
  using description file: /app/node_modules/redux-saga/package.json (relative path: ./dist)
    Field 'browser' doesn't contain a valid alias configuration
    resolve as module
      looking for modules in /app/src/app
        using description file: /app/package.json (relative path: ./src/app)
          Field 'browser' doesn't contain a valid alias configuration
          using description file: /app/package.json (relative path: ./src/app/@redux-saga/core)
            no extension
              Field 'browser' doesn't contain a valid alias configuration
              /app/src/app/@redux-saga/core doesn't exist
            .js
              Field 'browser' doesn't contain a valid alias configuration
<EMAIL_ADDRESS>doesn't exist
            .jsx
              Field 'browser' doesn't contain a valid alias configuration
<EMAIL_ADDRESS>doesn't exist
            .json
              Field 'browser' doesn't contain a valid alias configuration
<EMAIL_ADDRESS>doesn't exist
            as directory
              /app/src/app/@redux-saga/core doesn't exist
      looking for modules in /app/node_modules
        using description file: /app/package.json (relative path: ./node_modules)
          Field 'browser' doesn't contain a valid alias configuration
          using description file: /app/package.json (relative path: ./node_modules/@redux-saga/core)
            no extension
              Field 'browser' doesn't contain a valid alias configuration
              /app/node_modules/@redux-saga/core doesn't exist
            .js
              Field 'browser' doesn't contain a valid alias configuration
<EMAIL_ADDRESS>doesn't exist
            .jsx
              Field 'browser' doesn't contain a valid alias configuration
<EMAIL_ADDRESS>doesn't exist
            .json
              Field 'browser' doesn't contain a valid alias configuration
<EMAIL_ADDRESS>doesn't exist
            as directory
              /app/node_modules/@redux-saga/core doesn't exist
      /app/node_modules/redux-saga/dist/node_modules doesn't exist or is not a directory
      /app/node_modules/redux-saga/node_modules doesn't exist or is not a directory
      /app/node_modules/node_modules doesn't exist or is not a directory
      /node_modules doesn't exist or is not a directory
      looking for modules in /app/node_modules
        using description file: /app/package.json (relative path: ./node_modules)
          Field 'browser' doesn't contain a valid alias configuration
          using description file: /app/package.json (relative path: ./node_modules/@redux-saga/core)
            no extension
              Field 'browser' doesn't contain a valid alias configuration
              /app/node_modules/@redux-saga/core doesn't exist
            .js
              Field 'browser' doesn't contain a valid alias configuration
<EMAIL_ADDRESS>doesn't exist
            .jsx
              Field 'browser' doesn't contain a valid alias configuration
<EMAIL_ADDRESS>doesn't exist
            .json
              Field 'browser' doesn't contain a valid alias configuration
<EMAIL_ADDRESS>doesn't exist
            as directory
              /app/node_modules/@redux-saga/core doesn't exist

Steps to reproduce the bug/issue

try to install the redux-saga dep with "^1.1.3"
...

I have fixed it setting the version to: 1.1.3 (no higher)

Please always try to share a repro case in a runnable form - either by providing a git repository to clone or a codesandbox. OSS maintainers usually can't afford the time to set up the repro, even if exact steps are given.

Closing this issue due to inactivity.  Please feel free to reply here and I can reopen to help debug.  Thanks!


Kemono chapter images not opening error Fields [id, service, user, title, added, file] are required for type with serial name 'eu.kanade.tac...

Source information
Kemono
Source language
Multi
Steps to reproduce

Open any chapter of any entry in kemono extension
Got this error: Fields [id, service, user, title, added, file] are required for type with serial name 'eu.kanade.tac...

Expected behavior
It should be open normally
Actual behavior
Getting this error
Fields [id, service, user, title, added, file] are required for type with serial name 'eu.kanade.tac...
Mihon/Tachiyomi version
Tashiyomisy stable 1.11.0
Android version
12
Other details

Acknowledgements

[X] I have searched the existing issues and this is a new ticket, NOT a duplicate or related to another open or closed issue.
[X] I have written a short but informative title.
[X] I have updated the app to version 0.15.3.
[X] I have updated all installed extensions.
[X] I have tried the troubleshooting guide.
[X] If this is an issue with the app itself, I should be opening an issue in the app repository.
[X] I will fill out all of the requested information in this form.

Add a :+1: reaction to issues you find important.

Duplicate of #5883


Default versions should be changed to the latest release

Our policy is changed to use the latest stable release instead of the latest snapshot.

:tada: This issue has been resolved in version 3.1.1 :tada:
The release is available on:

npm package (@latest dist-tag)
GitHub release

Your semantic-release bot :package::rocket:


Add version info to binary at compile time

Prints the version info on startup and passes the version string to csi-lib.

/approve

/retest


Some bookmarklets not shown in list

I am so happy I found this extension! Thank you so much!
It works very well, however, much to my surprise, my own (simple, I thought) bookmarklets are not shown in the list of bookmarklets. I can't see why. All other bookmarklets (it seems) are shown.
For example, the simplest of my bookmarklets opens a popup and offers the title + URL of the page to copy or edit in a textarea:
javascript:
Q=document.selection?document.selection.createRange().text:document.getSelection();
L=location.href;
T=document.title;
D=new%20Date();
W=open('','w'+D.getTime(),'width=600,height=300');
with(W.document){
  write('<form>');
  write('<textarea%20name=%22noteit%22%20style=%22width:100%;height:100%;%20overflow:visible%22%20wrap>'+T+'\n'+L+'\n'+'\n\n'+Q+'</textarea>');
  write('</form>');
  void(close());
}

I am on Firefox 57 on Ubuntu 16.04 x64 using Bookmarklets context menu <IP_ADDRESS>.
Edit 2017-11-19 16:06: For reference + copy/paste, my bookmarklets are published at https://fam.tuwien.ac.at/~schamane/sysadmin/bookmarklets.php

The extension is verifying the bookmarklets by means of decodeURIComponent() which failed on my ones due to the fact that some % were not encoded (e.g. in above example as in '...100%;...'). Changing them to %25 makes decodeURIComponent happy and consequently lists the bookmarklets in the context menu.


Feature request: Share target

As an Android user, I sometimes encounter something I'd like to send directly to silverbullet; a URL of a page I'm seeing, comment contents somewhere, etc. Android has a Share button that allows sending this to various apps - e.g. Obsidian supports adding this to the Daily note.
This appears to be possible for PWA.
As an immediate use case, I'm thinking of sending things into a new "Quick Note". Future customization might be interesting as well.

I thought there was already an issue for this, but I couldn't find it. The practical issue is that this indeed seems feasible with PWAs, but I have no devices to test this on. I can install an Android simulator I suppose, but... priorities.
Would be very happy to take a PR though.

@lutzky were you able to add SilverBullet to your home screen as PWA on Android? If so, with which browser?
For me it works on MacOS, but not on Android (tried Edge and Chrome).

Well there's certainly a link to it in my homescreen that opens it in chrome without qn address bar. 🤔

Ok, turns out my launcher (Olauncher, a very simplistic one) doesn't support adding PWA apps.
I switched to Nova Launcher and now I can add it.

First tracer-bullet implementation here:
https://github.com/silverbulletmd/silverbullet/pull/1158


fetcher is called on every flutter build()

Since 4.2.5, the fecther is called on every flutter build(), which is not desired. It should only be called on initState, pull-to-refresh or if controller.fetch() is manually called.
Maybe it's because of the fix of #4.
To reproduce using your example, you can add an action button to the CachedBuildDemo's scaffold's appbar :
actions: <Widget>[
          IconButton(
            icon: Icon(Icons.add),
            onPressed: () => Navigator.of(context).push(MaterialPageRoute(
              builder: (_) => Scaffold(
                body: Text('nothing'),
              ),
            )),
          )
        ],

When you tap on it, it will open a new page, flutter will call CachedBuildDemo's build(), and fetcher will be called (not desired).

Ooo, you're right. We should probably only call it the first time. I'll have a look at it later today.
Actually, the current behavior is somewhat intended as a temporary behavior. In the long term, I was thinking about implementing multiple caching strategies that you can choose from (for example, only fetching the first time or fetching only if the last fetch is some amount in the past)

Implementing multiple caching strategies as you said is a great idea, but still, in anycase it should NOT be called on rebuild.
As Flutter's documentation say :

A general guideline is to assume that every build method could get called every frame.

So maybe before you add this multiple caching strategies implementation, you could just fix this ?
Thanks :)

Yes, I'll fix it later today 😊

Got fixed with version 4.2.6, which is already live on pub.dev.

It fixes the build issue, but now I can't pull-to-refresh anymore, is that normal ?

I tested pull-to-refresh on my device and it worked…

You're right : it's another issue.


Updated Auto Scaling group code examples

Issue #, if available:
It's "Amazon EC2 Auto Scaling group" on first use, "Auto Scaling group" thereafter.
Description of changes:

Follow latest code guidelines
Use proper service naming

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

The changes look good to me. Could you update the SDK changelog?

Done


Aborted (core dumped) in tf.raw_ops.BatchFunction

Issue type
Bug
Have you reproduced the bug with TensorFlow Nightly?
Yes
Source
source
TensorFlow version
tf 2.16
Custom code
Yes
OS platform and distribution
Linux Ubuntu 22.04.3 LTS (x86_64)
Mobile device
No response
Python version
3.9.13
Bazel version
No response
GCC/compiler version
No response
CUDA/cuDNN version
No response
GPU model and memory
No response
Current behavior?
When num_batch_threads is too large, tf.raw_ops.BatchFunction triggers crash.

Standalone code to reproduce the issue
import tensorflow as tf

@tf.function
def simple_fn(x, y):
    return x + y

input_tensor = tf.constant([1.0, 2.0, 3.0], dtype=tf.float32)
captured_tensor = tf.constant([4.0], dtype=tf.float32)

def wrapped_fn(in_tensors, captured_tensors):
    return simple_fn(in_tensors[0], captured_tensors[0])

defun_func = tf.function(wrapped_fn).get_concrete_function([input_tensor], [captured_tensor])

result = tf.raw_ops.BatchFunction(
    in_tensors=[input_tensor],
    captured_tensors=[captured_tensor],
    f=defun_func,
    num_batch_threads=tf.constant(93389718, dtype=tf.int32),
    max_batch_size=10,
    batch_timeout_micros=1000,
    Tout=[tf.float32],
    max_enqueued_batches=10,
    allowed_batch_sizes=[5, 10],
    container='',
    shared_name='',
    batching_queue='',
    low_priority_max_batch_size=0,
    low_priority_batch_timeout_micros=0,
    low_priority_allowed_batch_sizes=[],
    low_priority_max_enqueued_batches=0,
    enable_large_batch_splitting=False,
    name=None
)

print(result)

Relevant log output
2024-06-13 14:42:13.314670: I tensorflow/core/platform/cpu_feature_guard.cc:210] This TensorFlow binary is optimized to use available CPU instructions in performance-critical operations.
To enable the following instructions: AVX2 FMA, in other operations, rebuild TensorFlow with the appropriate compiler flags.
2024-06-13 14:42:19.076124: F external/local_tsl/tsl/platform/default/env.cc:74] Check failed: ret == 0 (11 vs. 0)Thread batch_threads_ creation via pthread_create() failed.
Aborted (core dumped)

@x0w3n I was able to replicate the issue reported here. One workaround could be to use tf.raw_ops.BatchFunction that offers low-level control, a simpler approach for batching a function might be using tf.data.Dataset.map with vectorization?
Could you please let us know if it helps?
Thank you!


Unexpected query for psql.F() and As()

I'm not sure if this is intentional but the generated query was not what I expected.
Reproduction:
psql.Select(
  sm.Columns(psql.F("min", "some_col").As("renamed"))
  sm.From("some_table"))

Result:
SELECT
min(some_col)renamed
FROM some_table

Expected:
SELECT
min(some_col) AS renamed
FROM some_table

What's the reason that no "AS" is being added?

I'll have to investigate this. Thanks for reporting


Use sentryClientName instead of sdk.identifier

:scroll: Description

Use sentryClientName instead of sdk.identifier in HttpTransport header.
:bulb: Motivation and Context

Closes #584
:green_heart: How did you test it?
Added test.
:pencil: Checklist

[x] I reviewed submitted code
[x] I added tests to verify changes
[ ] I updated the docs if needed
[x] All tests passing
[ ] No breaking changes

Codecov Report
Base: 90.09% // Head: 95.55% // Increases project coverage by +5.45% :tada:

Coverage data is based on head (1ec6324) compared to base (48e79fd).
 Consider uploading reports for the commit 2b3b479 to get more accurate results

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1133      +/-   ##
==========================================
+ Coverage   90.09%   95.55%   +5.45%
==========================================
  Files         117        2     -115
  Lines        3605       45    -3560
==========================================
- Hits         3248       43    -3205
+ Misses        357        2     -355

Impacted Files
Coverage Δ

dart/lib/src/protocol/sdk_version.dart

dart/lib/src/sentry_options.dart

dart/lib/src/transport/http_transport.dart

dart/lib/src/sentry.dart

dart/lib/src/protocol/sentry_request.dart

dart/lib/src/protocol/sentry_thread.dart

...art/lib/src/enricher/enricher_event_processor.dart

dart/lib/src/transport/rate_limit.dart

dart/lib/src/transport/rate_limiter.dart

dio/lib/src/breadcrumb_client_adapter.dart

... and 105 more

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

:umbrella: View full report at Codecov.
:loudspeaker: Do you have feedback about the report comment? Let us know in this issue.

Closed in favour of #1135, which points against the correct branch.


WIP: [Swift+WASM] initial support for compiling Swift to WebAssembly

What's in this pull request?
This pull request adds initial support for compiling Swift code to WebAssembly.
"Hello world" works, and a large subset of the stdlib already works on WebAssembly.
You can try this yourself with our cloud-hosted toolchain incorporating this port:
https://swiftwasm.org
This patch uses the WASI SDK, so WebAssembly executables generated by this port will work both in browsers and in standalone WebAssembly runtimes such as Wasmtime or Fastly's Lucet.
Links to issues
See SR-9307 for some background and the existing Swift+WASM changes in Swift that this patch depends on.
Also see emscripten#2427 for discussion and previous attempts on porting Swift to WebAssembly, which this port draws heavily upon.
Thanks
Thank you to everyone who helped make this possible:

Authors of patches included in, or used by, this port: @zhuowei, @MaxDesiatov, @ddunbar, and @patcheng
Answering our questions about Swift internals: @jrose-apple
Helping us understand the WebAssembly backend in LLVM: @sbc100
getting Lucet to run Swift binaries (to allow me to use lldb to debug): @m4b, @philipc, @jedisct1, @pchickey
and many other people. (sorry if I missed anyone!)

If you would like to help, you can join us at https://github.com/swiftwasm.
Status of the port
This port is not ready for merging. The biggest blocking issues currently are:

Tests are disabled
Crash when passing non-throwing closure to function taking throwing closure

We're opening this pull request now to get advance feedback and advice, so we can fix these remaining issues and start cleaning up our patches.
Per Swift's contributing guidelines, we're planning to split each change into a separate pull request.
We've already created pull requests for some minor changes:

https://github.com/apple/swift/pull/24054
https://github.com/apple/swift/pull/24119
https://github.com/apple/swift/pull/24133
https://github.com/apple/swift/pull/24181
https://github.com/apple/swift/pull/24182

We welcome advice on how best to submit these changes for review.
Note that this port also requires changes to Clang and LLVM: the corresponding pull requests are:

https://github.com/apple/swift-clang/pull/316
https://github.com/apple/swift-llvm/pull/155

Here's a more detailed explanation of the changes included in this pull request, and on what still needs to be done.
How WebAssembly differs from other platforms
WebAssembly is a new platform, with unique attributes that pose issues to Swift's runtime.

Functions have strict argument checking

Swift often calls functions with extra arguments
couldn't find a way to fix this
so eg Optional.Map crashes because tries to call non-throwing closure with an extra error pointer

Limited relocation support in linker: can't take difference between two symbols

Metadata relies on this. Solution: switch to absolute pointers
Not the first port that required this

@compnerd also did this in 2016 for Windows ARM32 port
changes couldn't be merged, so ARM32 port was abandoned

We would like to find a way to merge absolute metadata support
or find a different workaround
eg only emitting Bitcode for LTO, avoiding intermediate .wasm files

What's done
Swift changes

Cmake and utils/build-script changes to compile Stdlib for WebAssembly

A lot of this overlaps with ddunbar's changes (https://github.com/apple/swift/pull/20684)
We should probably try to unify our changes with that PR.

Metadata: switch to absolute pointers

as mentioned above, the intermediate .wasm object format doesn't support relative pointers used on other ports
https://github.com/swiftwasm/swift/commit/a506ca60f37c26084977a066edd80aa6aaf584a0
https://github.com/swiftwasm/swift/commit/7e42e33fff3244cde7532a5c1c69c9d15e8e0e6d
https://github.com/swiftwasm/swift/commit/26e162dc0a59c7f5b835ffde9754ac289a60f309
https://github.com/swiftwasm/swift/commit/c471b0c2aacdfe99efbc1b0f67c06ccf225f7931
https://github.com/swiftwasm/swift/commit/3ee0e41d35dd55733ac90896fcc027f2db1ff1b6

Load the metadata at runtime

https://github.com/swiftwasm/swift/commit/bc15cbaed5594aed93c233b255fe6f18ff49199c
https://github.com/swiftwasm/swift/commit/885cd056eea457f8561a56663342eedcf22b0806
https://github.com/swiftwasm/swift/commit/20577977c19e3bcb8dc53bace807c065209972f6
Metadata read code is shared with ELF with one change
linker doesn't export section start and end pointer symbols, unlike ELF
COFF also has this problem, but COFF sections are sorted alphabetically

so Windows port adds dummy sections with names that would sort before/after each metadata section, and uses them as start/end symbols

Wasm doesn't do this. So have to link swift_start and swift_end objects at start and end of linker invocation, like older versions of Swift on Linux

Disable atomics and -glldb

https://github.com/apple/swift/pull/24119

Disable COMDATs for reflection metadta

metadata of each type is emitted in same section
COMDAT support on WebAssembly requires each piece of metadata emitted in separate section
https://github.com/apple/swift/pull/24133
thanks to comments, will rework this to actually emit each metadata in its own section

Various stdlib changes to fix method signatures

https://github.com/apple/swift/pull/24054
https://github.com/apple/swift/pull/24181
https://github.com/apple/swift/pull/24182
swift_once calls are hard to fix, since calls are compiler generated
hacked around by duplicating swift_once to swift_once_shim
https://github.com/swiftwasm/swift/commit/4184451d288b563f814c9b9478d4c2ffe9314c5c
https://github.com/swiftwasm/swift/commit/bd86ee92345ae3e319b51e6c66212040e4e4825a
tried to fix it properly; didn't work because I don't know how to generate SIL

LLVM changes

LLVM changes to compile stdlib

I wrote up a short description of LLVM changes here: https://github.com/emscripten-core/emscripten/issues/2427#issuecomment-483428752

enable swift calling convention for webassembly

https://github.com/swiftwasm/swift-llvm/commit/a9310d5724f8a6318fab23a261e7ea5826675627
ddunbar got the swift calling convention into upstream llvm, but it was disabled there, probably because there's no tests yet

Support -gmodules in clang for WebAssembly

https://github.com/swiftwasm/swift-llvm/commit/1450846ea98ae7ed6f477ce986c91cb4d846373d
https://github.com/swiftwasm/swift-llvm/commit/0a6b8cfedc0085c526fded76b578ff89c17b597e

Support alias symbols with offsets

https://github.com/swiftwasm/swift-llvm/commit/5ecc83a98fc766b90b5e6d2c653ec9149a28c710

https://github.com/swiftwasm/swift-llvm/commit/057f008f6cd53c078dca24c7a1f9a362c4a63866

Swift metadata have this layout:

0x0 -> value witness table pointer
0x4 -> metadata entry
... etc

https://github.com/apple/swift/blob/master/docs/ABI/TypeMetadata.rst
So to access the metadata entry at 0x4 bytes past the table pointer, a symbol is exported using LLVM's alias directive, pointing 4 bytes past the value witness table pointer
Other metadata use similar aliases, again to export a symbol with an offset inside another symbol
Clang doesn't emit alias directives with offset, so this wasn't already implemented by LLVM's Wasm backend. This change adds it.

cherry-pick wasm linking info v2 patch from LLVM master:

https://github.com/swiftwasm/swift-llvm/commit/5486b101ef9fcc036a673f119c18fc09cda62ef9
This is just to support linking Swift objects with LLD 8.0

Clang changes

enable swift calling convention in clang as well

https://github.com/swiftwasm/swift-clang/commit/55d88867ebaad95282cbd72390edad7af78a6933
Again, @ddunbar got the support into upstream LLVM, so this just enables it here

two hacks to disable exceptions by default and define __wasi__

https://github.com/swiftwasm/swift-clang/commit/9387080a90d30cd47917e887179ba398c8fd9920
https://github.com/swiftwasm/swift-clang/commit/d3e5eb136d824cfc804ade586d0b670f5f4e8ea0
Upstream llvm already has native support for __wasi__, so this is just temporary

What still needs to be done
Most important: fix swift calling convention and extra arguments
WebAssembly has strict function signature checking, so this crashes:
struct Test {
    var a:Int
}
print(Test(a: 1))

inside Optional.Map.
Why? Optional.Map takes a throwing closure, but is passed a non-throwing closure.
A throwing closure is compiled down to a signature similar to this:
void closure(void* arg1, void* arg2, void* swiftSelf, error** swiftError)

A non-throwing closure has signature like this:
void closure(void* arg1, void* arg2, void* swiftSelf)

without an end error pointer.
Swift assumes passing extra parameters to a function pointer is ignored, so it doesn't generate a thunk if a non-throwing closure is called as a throwing closure, or if a thin function is called as a thick function.
lib/IRGen/GenFunc has a comment that explains this further.
This assumption is valid on all platforms that Swift currently supports, but doesn't work on WebAssembly thanks to the strict signature checking.
Unfortunately, I have no idea how to fix this.
Modifying the Swift compiler to generate the thunks might be difficult. Currently, thunks are only generated when calling to a function with different calling conventions, not between functions with the same calling convention but different number of arguments. SIL's SILFunctionType doesn't even track if a function throws.
I've never worked with Swift compiler internals, so I don't even know where to start modifying IRGen.
I asked @jrose-apple, who suggested that one short-term alternative is to standardize all swiftcall functions to take only one extra parameter:
void closure(void* arg1, void* arg2, void** extraArgs)

extraArgs would point to an area on the stack, containing swiftself, swifterror, and any other extra parameters.
This way, thin, thick, and throwable thick functions would have the same number of arguments.
I'm guessing this would require either Clang+Swift changes or an LLVM pass.
I found an example in Chrome PNaCL that transforms function arguments https://chromium.googlesource.com/native_client/pnacl-llvm/+/mseaborn/merge-34-squashed/lib/Transforms/NaCl/ExpandVarArgs.cpp#170, so the LLVM pass might not be too complicated.
We would really appreciate help and advice on how best to approach this.
Reenable and run tests

Tests are completely disabled right now.

Upstream the LLVM patches

Currently, the LLVM/Clang patches are based on Swift's stable branches
Our goal is to get the LLVM changes into LLVM upstream, so they'll be pulled into swift's upstream-with-swift branches
I've never worked with LLVM before, so I would appreciate advice on how best to structure patches for upstreaming.

Support building Swift stdlib for Wasm using a macOS host

It seems that a macOS host can only cross compile for Darwin platforms, as compiling stdlib for Wasm fails on macOS. (It works on Linux.)
Is the existing Android cross-compile support also affected by this?
@MaxDesiatov is working on getting the stdlib on Wasm building on macOS.

Split this PR into small, reviewable chunks

We started to do this with the simpler stdlib signature changes already

Longer-term goals
Get Swift's other libraries working

We have not tried building Foundation or any other Swift libraries.
Would these libraries/tools even work in WebAssembly, which, as of now, only supports single threaded execution?

Support link-time optimization

@ddunbar discussed the importance of link-time optimizations for Swift on WebAssembly in SR-9307.
This would reduce executable size (currently, a Swift Hello world compiles to a 7.8 MB .wasm)

Emscripten heavily depends on LTO to keep binary sizes down when compiling C/C++ to WebAssembly, so it's probably worth supporting

it can also help us avoid the relative/absolute metadata issue since relative relocations can be represented in LLVM bitcode.

Work on ways to interop with JavaScript from Swift

Something similar to Rust's wasm-bindgen or the gowebapi project's webidl-bind

I asked @jrose-apple, who suggested that one short-term alternative is to standardize all swiftcall functions to take only one extra parameter:
void closure(void* arg1, void* arg2, void** extraArgs)
extraArgs would point to an area on the stack, containing swiftself, swifterror, and any other extra parameters.
This way, thin, thick, and throwable thick functions would have the same number of arguments.
I'm guessing this would require either Clang+Swift changes or an LLVM pass.

Rather than spill to the stack, it should be sufficient to make the two swiftself and swifterror arguments always be provided, and leave them undef when they aren't needed. Those are the only two extra arguments that you should need to worry about. Since there's already a distinct swiftcc convention at the LLVM level, it seems natural to me to introduce these arguments, if they don't exist in the LLVM signature, into the wasm-level signature in the backend.
Note that swifterror isn't a real pointer-to-pointer argument for the x86 or arm backends, but really represents an in-out register. If it's possible to model it that way in wasm too, it'd probably lead to better native code size and quality when lowered to native code.

Metadata relies on this. Solution: switch to absolute pointers

Given the newness of WASM, it would be nice to instead see if support for this can be added to WASM; the feature is useful and could eventually benefit other things.

@jckarter That was one of the alternatives that @jrose-apple suggested. However, this may not work for all methods: According to GenFunc.cpp there could be extra "witness_method generic parameters" after the error parameter, so just adding two parameters might not be enough.
Also, re swiftcc calling convention: Wasm doesn't have registers: it is a stack machine, similar to the Java virtual machine.

@zhouwei For witness table entry points, there is still a consistent calling convention that all witnesses use. That logic duct tapes over some representation issues in SIL; they should end up ultimately lowering to compatible LLVM level signatures.
If wasm is a stack machine, then it may still be worth considering the intent of the swiftcc special arguments in designing how it lowers to the stack machine representation. The self argument is intended to be mapped to a stable, callee-preserved register, so that (a) context-free functions are ABI compatible with closures that have captures, and (b) in a series of method calls on the same object, the caller can save code size by not having to constantly reload the self argument register. In a stack machine, you could get a similar effect by always pushing the self argument first, and maybe having the callee leave it on the stack after the call (though for a stack machine that's not an obvious win; it has a tradeoff in code size for calls to methods on different objects, since the caller will then have to pop more).
The error argument is similarly intended to be mapped to a fixed, normally callee-preserved register, which the caller sets to zero, and the callee sets to nonzero on error. This is so that nonthrowing functions are ABI compatible when used as throwing functions, and so that propagating errors through multiple stack frames can be done with minimal code size cost for the test and early return. For a stack machine, it seems like we don't really gain anything from passing a value in to the callee, since it's always zero or undef, but you could push the error value after the primary return value when the callee returns, so that the caller can easily test it and either pop or return to propagate the error upward.

Given the newness of WASM, it would be nice to instead see if support for this can be added to WASM; the feature is useful and could eventually benefit other things.

@ddunbar Swift's intended use is to reduce load time for memory mapped native code binaries. Since wasm AIUI generally goes through another compilation stage on the client, it seems to me like the  cost of relocating wouldn't be that big a part of the load time cost. Hopefully the wasm binary format already has a reasonably efficient way of representing references to local symbols...

@jckarter Wasm call instructions seem to consume the arguments from the stack: https://godbolt.org/z/NjLc0f so it might not matter whether self is pushed first or last, from a code density or performance point of view.
I have no experience working on compilers, though, so that's just my guess. for what it's worth, Java's JVM, which has a similar stack machine and call semantics, pushes the self pointer first, but I'm not sure why they do that.

Swift's intended use [for relative indirections] to reduce load time for memory mapped native code binaries. Since wasm AIUI generally goes through another compilation stage on the client, it seems to me like the cost of relocating wouldn't be that big a part of the load time cost.

Some of them do reduce in-memory static data size too, but maybe that's not worth pushing a whole feature through WASM.

Can one of the admins verify this patch?

This PR has accumulated too many conflicts and no longer reflect the actual difference. Most if not all relevant changes were split into separate PRs. I'm closing this one as unused.


Adding support for server rendered import map. Resolves #13.

See #13. This is similar to what Canopy used to do for import map overrides.

I talked about this at length with Anthony Frehner in slack - we think this is important for supporting overrides on the server side where the server needs to call a local server instead of deployed server to make the override take full effect.


Support for version 10.4 and 10.5

Hi,
Is there an ETA for supporting MariaDB version 10.4 and 10.5?
Regards,
Balint

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

ID: 2f5e4798-d1ea-e82b-0459-2e268387152d
Version Independent ID: 1bb7d77d-0b97-3190-ea91-9a10a014eefc
Content: Supported versions - Azure Database for MariaDB
Content Source: articles/mariadb/concepts-supported-versions.md
Service: mariadb
GitHub Login: @ajlam
Microsoft Alias: andrela

@balintbako We are checking this with our Doc author.
@ajlam Please confirm the timeline or plan for the support.

Hi @balintbako - Could you please send an email to Ask Azure DB for MariaDB<EMAIL_ADDRESS>I would love to talk to you and learn more about your use cases for MariaDB 10.4 and 10.5

@NavtejSaini-MSFT - You can close this as @balintbako reached out to us on email and I am following up with him on email to address his question.

Thank you @savjani for the help. If you have any insights regarding the question from @balintbako that you can share here, please do share.


nm ovs: Remove the workaround of OVS port name and xfail of test caes

With NetworkManager 1.22.8, it has removed the restriction on interface
name length on OVS port name.
Remove the need of creating hash string for OVS port.
Also include new patch to remove the xfail in OVS test cases as OVS in NM 1.22.8 is stable now.
Resolves: #805

If NM 1.22.8 release with restriction on NM OVS name, we need this patch to fix the regression.

Coverage decreased (-0.0003%) to 62.42% when pulling 4e7fe14d4f4e1ea1fc10aef65a0f92bba8785e3d on cathay4t:fix_ovs_iface_name into 0895c0f611e3aee160abfd4d27bb18382756ec79 on nmstate:master.

Coverage decreased (-0.0003%) to 62.42% when pulling 4e7fe14d4f4e1ea1fc10aef65a0f92bba8785e3d on cathay4t:fix_ovs_iface_name into 0895c0f611e3aee160abfd4d27bb18382756ec79 on nmstate:master.

The workaround does not seem to be needed for NetworkManager-1.22.6-2.el8.x86_64 or the tests are not covering the original problem. This PR already succeeds in the CI... @EdDev any ideas?

@tyll This is a preparation on nm-1.22 branch. That's why I add the work other response tag.

@tyll This is a preparation on nm-1.22 branch. That's why I add the work other response tag.

Yes, I understand but then the CI should fail now but it does not.

I will put this PR on hold as our CI does not have fixes for https://github.com/nmstate/nmstate/issues/809

Since we branched and change the CI to use 1.22-git, this should unblocked now.

Thanks for the remind.
Rebased and ready for review.

And it seems that this PR is also dependent on the NM version that runs.
So do we need to specify this in the spec or should we just log a warning once that mentions this?

IMHO it is more a soft dependency because the newer version is not strictly required like when we are using settings that were newly introduced but it the OVS features becomes more stable with it. Therefore logging a warning sounds the correct approach to me. Maybe we can also have a recommends for the newer NM version (> 1.22.8) in the spec. @cathay4t what do you think?

And it seems that this PR is also dependent on the NM version that runs.
So do we need to specify this in the spec or should we just log a warning once that mentions this?

IMHO it is more a soft dependency because the newer version is not strictly required like when we are using settings that were newly introduced but it the OVS features becomes more stable with it. Therefore logging a warning sounds the correct approach to me.

I don't see any existing code to log a warning about unsupport NM.

Maybe we can also have a recommends for the newer NM version (> 1.22.8) in the spec. @cathay4t what do you think?

I have changed the rpm spec from >= 1.22.8 to >1.22.8

I have changed the rpm back to >= 1.22.8 as unit test still using the released rpm of NM.
Changing .travis.yml is too much for this PR.

Wait NetworkManager to tag a new release.

New patch uploaded.
Changed the minimum support NM version to 1.22.10.
Depending on PR #961

Dependent PR merged.
Ready for review.

Got constant failure in CI once removed the xfail on test_create_and_remove_ovs_bridge_with_internal_port_static_ip_and_mac. Investigating.

Got constant failure in CI once removed the xfail on test_create_and_remove_ovs_bridge_with_internal_port_static_ip_and_mac. Investigating.

This issue is fixed in https://github.com/nmstate/nmstate/pull/968


Write propagation status to reconciled federated resources

This PR ensures that propagation status is written for federated resources.   The PR looks large but the bulk of it is actually generated crd yaml.
TODO

[x] Update the user documentation
[x] Add checks for status to the crudtester
[x]  Truncate lastProbeTime and lastTransitionTime to the second

Fixes #740
Fixes #588

Ok, ready for review.  This is a big one, but largely mechanical (helm chart update, collecting status everywhere).

Test issue should be fixed.  Still need to cleanup the timestamp handling.

TODO items are complete.  Now for the review comments...

Rebased

@shashidharatd Thanks for the review, updated.

/lgtm
Thanks

Rebased to account for the klog PR.

/lgtm

Got held up in some personal stuff today, hence delayed on this. For whatever it might be worth now, I did too have a look at this PR and it all looked good.
Awsome work @marun


Cannot set shift and slope for heating curve

Through the adapter it is currently not possible to set the heating curve.
This is due to the code line (and following)  const param = idState.common.param; as this allows only a single argument.
The setValue for the heating curve requires two arguments. shift and slope, the adapter only sends slope (and requires a number). So the viessmann api responds with:
error {"viErrorId":"req-yyyyyy","statusCode":422,"errorType":"VALIDATION_ERROR","message":"VALIDATION_ERROR","validationErrors":[],"extendedPayload":{"code":"400","reason":"VALIDATION_ERROR","details":"The parameter shift not provided"}}

If you try to input a JSON object instead like {"slope": x, "shift": y} it does also not work
{"viErrorId":"req-xxxxxx","statusCode":422,"errorType":"VALIDATION_ERROR","message":"VALIDATION_ERROR","validationErrors":[],"extendedPayload":{"code":"400","reason":"VALIDATION_ERROR","details":"The parameter slope="{\"shift\":1,\"slope\":0.3}" does not meet the constraints {"type":"number","min":0,"max":3.5,"stepping":0.1}: Value '{"shift":1,"slope":0.3}' should be a number."}}

In the extractKeys library the problem is
if (element.params && Object.keys(element.params).length > 0) {
                            param = Object.keys(element.params)[0];

So only the first param is stored and processed later on.

For information purpose the screenshot


Unable to access k8s server using kubectl commands form macOS

Hello,
I am installing MicroK8s using the following procedure as detailed on:
https://microk8s.io/docs/install-alternatives#heading--macos
brew install ubuntu/microk8s/microk8s

microk8s install
microk8s status --wait-ready

microk8s enable dns registry

microk8s kubectl config view --flatten > ~/.kube/microk8s-config && \
KUBECONFIG=~/.kube/microk8s-config:~/.kube/config kubectl config view --flatten > ~/.kube/temp-config && \
mv ~/.kube/temp-config ~/.kube/config && \
kubectl config use-context microk8s

However, when I run any command from my macOS with kubectl I keep getting the following error:
The connection to the server <IP_ADDRESS>:16443 was refused - did you specify the right host or port?

Here is my ~/.kube/config

Attached is my microk8s inspect output:
inspection-report-20200602_023458.tar.gz

Hi @munjalpatel
could you get the kubeconfig with microk8s config?
MicroK8s on mac and windows creates a linux VM. In your kubeconfig you should point to the IP of that VM and not your localhost (<IP_ADDRESS>).

That was it! Thanks @ktsakalozos


How do you use this?

Hello,
Sorry if this isn't the right place to ask this, if there's somewhere else, please let me know.
I like the t3-stack, and want to try having a monorepo for an expo app, website, and server.
How do you use this repo? There are a few things I'm confused about.

According to the blog post (https://www.jumr.dev/blog/t3-turbo), you don't run it like create-t3-app.
On tRPC's website, there is a t3-turbo example project (https://trpc.io/docs/example-apps#create-t3-turbo---t3-stack-with-expo-and-turborepo), and it says to use clone
I thought that most people using this would be using it for their own projects rather than contributing back to this one. Wouldn't we want to fork instead in that case? However, there are 1.2k stars, and <100 forks, so it seems like that's not what we should do either.

What am I missing?

This repo is a template. You can just clone it delete the git repository, configure it and then initialize your own git repository.

There is a "use this template" button you can use to create your own repo from it

Thanks a lot! I completely missed that button


Update requirements.txt for pytorch-lightning

Because pytorch_lightning.metrics is deprecated from v1.3 and will be removed in v1.5. (https://pytorch-lightning.readthedocs.io/en/stable/extensions/metrics.html)
To be able to load fastface the version of pytorch_lightning is fixed to 1.3.8.

Hey @nguyenhoan1988 , thank you for pointing it out! But instead of fixing the version, I would prefer to add torchmetrics as a dependency and use torchmetrics.Metric base class to replace it. Please let me know if you are up for it.


Create or update baselines to match 2.0

Assigning @pranavkm because it's not clear who has context on this repo.

@javiercn and @Eilon looks like we might have had actual breaking changes in this repo?

AFAIK, the package in this repo is an alpha version. We shouldn't have baselines for it.

@pranavkm is correct. This repo shouldn't have any baselines.


Do not hardcode "amd64" on LCOW and Windows-related files

Fixes #3281.
Signed-off-by: Kazuyoshi Kato<EMAIL_ADDRESS>

I'm not a maintainer, but LGTM

@jterry75 Can you take a look?

LGTM


[1.hello-world] The port value of the app should be mutable

Describe the proposal
In the document, it seems the port of the app can be changed by user. For example, change it to 3001,
dapr run --app-id mynode --app-port 3001 --port 3500 node app.js

But in the code as below shows, the value of the port seems can't be changed, so user may be confused when run this scenario.
const port = 3000;
app.listen(port, () => console.log(`Node App listening on port ${port}!`));

fixed in #99

I think in the cli, it should use the port of the app using, so the example is quite clear that we will use port 3000.
In real world, I think it should be configurable which both cli & the app will use the same configuration (e.g. via Environment variable), but in the scope of the example I think that's acceptable.

The reason the sample uses const instead of let or var is because the port the app runs on is not expected to change once the app is running. As with any sample code, developers are free to change the port to whichever port they like.
Given that this lacked clarity though, I PRed a quick clarification into the README: #104


Baseline USDM Version 3 Rules

We need an initial set of rules specifications for version 3 of the USDM.
The Information required for each rule is:

Identifier (single identifier)
Textual statement of rule
Class(es) to which the rule applies
Attribute(s) within the class(es) to which the rule applies
Warning or Error

Delivery should be via an Excel workbook (single sheet for the rules, maybe a second sheet for a readme / column explanation) placed into a new directory "RULES" within the "Deliverables" directory of the DDF-RA github repo.
May wish to consider the form of the rules text statements such that similar rules have a similar text structure/syntax.

I made corresponding columns green in our working spreadsheet RulwRequirements_v4.xlsm
To discuss:

Will the identifier be the final core rule ID as is expected in the Harmonized Rules Catalog?


Re-check case update balance and staking on mobile app

Describe the task
Re-check case update balance and staking on mobile app

[ ] Show incorrect balance after withdrawing successfully
[ ] Do not show staking item although have stake and balance shows correct

Same as https://github.com/Koniverse/SubWallet-Mobile/issues/1269


[CR] Two Files API-related fixes

The attached patches fix two separate issues with the files API.
1.) d181651 updates NodeFilesList to handle the new JSON-API conformant WaterButler responses.  Relevant: [#OSF-4667]
2.) d65c61d fixes a permissions bug for file checkouts.  It wasn't checking whether or not the request was safe and ergo declining all non-osfstorage files.  Relevant: [#OSF-4674]
The Jira ticket for this task is https://openscience.atlassian.net/browse/OSF-4674

By and large, looks good. I expect that the map/lambda/set-comprehension is going to have to be re-written into something more readable. I didn't try to run it, so I'll let future code reviewers do that, but I wanted to at least give it a once-over.

Cool, thanks!   I'll update the test and repush.

Sorry it took so long @felliott, got distracted by multithreaded django servers. You know how it is.
It looks fine to me. I double-checked that the real permissions stuff gets called after checkin/checkout just to familiarize myself and make sure we were just letting people in.
I agree with @brianjgeiger about the list comp with the splat being a little brain melting but it looks good now.
Ran the tests. Hit the endpoints. Everything makes sense to me.


Added new ASR prefix to the Disks query

Thank you very much for your PRs.
I updated the queries as your suggestion.


Possible inconsistencies between C# & GO nodes

Hello, would like to share something that looks like a bug to me or maybe I'm missing something.
I was looking at this block https://explorer.onegate.space/blockinfo/0x537c5a46efa4db0a17d13fde248739ff026ee3016e87c2564fda34361213efc8 and couldn't understand why the last tx 0x60... failed as for me It should have been the first executed on the block and the failing one should have been the 2nd one  0xfa....
So I had a look and realized this block was validated by NeoSPCC. I started to think maybe It was due to NeoGO implementation vs C# one and indeed seems implementation are different :o
C# txs execution -> deterministic https://github.com/neo-project/neo/blob/master/src/Neo/Ledger/PoolItem.cs#L46
1. Prio Attribute
2. Fee Per Byte
3. Network Fee
4. Hash

GO txs execution -> non-deterministic https://github.com/nspcc-dev/neo-go/blob/973ed8c1f6398119e65b33a41be38435960d8e49/pkg/core/mempool/mem_pool.go#L91
1. Prio Attribute
2. Fee Per Byte
3. Network Fee
4. Fist Come First Serve

That feel really strange for me that we can't predict execution and looks like C# implementation should be the one prioritize.

Transaction ordering (aside from high priority attribute) is not and should not be guaranteed. Especially if we're talking about hash-dependent ordering. Not a bug to me.

So It means that a concensus node can run It's own custom code and It's not verified by others validators? Any concensus node can decide from one day to change his tx ordering? 🤔

I'd say so. And you can't verify a lot even if you'd like to. Starting from the basics, a transaction may get into the block, or may not, depending on network conditions. This already breaks any ordering assumptions.
Well-behaving nodes must include high-priority transactions, but even that can't be checked, maybe the node doesn't have it in the mempool (yet). Then nodes are incentivized to get the most value for themselves from a block, so they pick highest-paying transactions (by network fee), but technically they can do anything else as well. And even when they pick highest-paying transactions they're not obliged to order them in this way. I'd happily shuffle them, but it's just a bit less efficient, so the simplest implementation is the behavior you get.
See neo-project/neo#2504 (general MEV discussion) and neo-project/neo#408 (where the C# hash sorting originates from) also.


improve delete rows in testset

In view/edit testset we want to:

disable the "Delete row" per default and make it enabled only when we click on at least 1 row
Make name change to the plural form when we select more than 1 row. (Delete rows)

@aakrem i would fix this.

Hi @witehound thanks for the PRs. Please do!


Resize doesn't work

Check that this is really a bug

[X] I confirm

Reproduction link
https://codesandbox.io/s/react-big-calendar-example-forked-dc74c6?from-embed
Bug description
Resize prop doesn't work in Calendar. Here is my setup
      `<section style={{ height: '100vh' }}>
         <DnDCalendar localizer={localizer}
                events={pickerEvents}
                draggableAccessor={() => true}
                onSelectSlot={handleOnSelectSlot}
                onSelectEvent={handleOnSelectEvent}
                onEventDrop={handleOnEventDrop}
                onEventResize={handleOnResize}
                resizableAccessor={() => true}
                selectable
                popup
                resizable
                showMultiDayTimes={true}
                step={15}
            />
      </section>`

Expected Behavior
resizeable should work
Actual Behavior
in react 18 and higher version is not working.
react-big-calendar version
1.8.1
React version
18.2.0
Platform/Target and Browser Versions
Chrome
Validations

[X] Read the docs.
[X] Check that there isn't already an issue that request the same feature to avoid creating a duplicate.
[X] Make sure this is a react-big-calendar issue and not an implementation issue

Would you like to open a PR for this bug?

[ ] I'm willing to open a PR

You forgot to add the DnD stylesheet. See the DnD Example Codesandbox


? and ! included as keywords makes optional type names not searchable easily

ftplugin/swift.vim includes ? and ! as keywords:
setlocal iskeyword+=?,!,@-@,#
which makes optional types different from the non-optional version. So if I place the cursor over UICollectionView in the line for v1 and hit keys like gd, or *, it doesn't match the lines for v2 and v3. Vice versa.
var v1: UICollectionView
var v2: UICollectionView?
var v3: UICollectionView!

Seems better to set keywords like so:
setlocal iskeyword+=@-@,#
Any reason why ! and ? are included?

These were included because when doing things like diw, I would expect all of UICollectionView? to be deleted. I'm not sure which I would like to prioritize here. I can see issues with both cases.

I see. I have the habit of using df? or d$ for these cases, but it definitely makes sense. Thanks for clearing it up.

I agree with @hboon here. As I said in #4, I would expect diw to just delete the keyword, and not the optional operator. You can always use diW, same number of keystrokes if you really do want to delete the optional operator too.
Then again, I remove ?,! from iskeyword in .vim/after/syntax/swift.vim so it's easy to override this. I just think that should be the default, as there are more cons with the default way. :smile:

Conceding this https://github.com/Keithbsmiley/swift.vim/commit/fc63fb31f8c5df51eff137dad8463f0ede692518

I left @ and # for now but we may want to remove those in the future too.

Thanks for this! :+1:


Add option to disable locked screen

Hello, I would love to handle on my own failed attempts, could you add property to disable locked screen? (But still need failed attempts to be counted and passed to onFail method)

Hi,
Added a disableLockScreen property in the new version :).
Cheers,
Jeremy


Update managed-application-publishing.md

Removed unnecessary coma in list of parameters and corrected case of 'string' and 'managedResourceGroupId" to match what is in schema.

@mcollier,
Thanks for your contribution as a Microsoft full-time employee or intern. You do not need to sign a CLA.
Thanks,
Microsoft Pull Request Bot

@mcollier : Thanks for your contribution to the Azure documentation! The author, @ravbhatnagar, has been notified to review your proposed change.

@mcollier - sorry for not reviewing these changes more promptly. The changes were right when you made them, but managed apps no longer require that json file. So, we have removed that sample. #please-close


New tilting-pad hidrodynamic bearing models

PR #690 is about implementing new types of bearing models to ROSS.
Certainly it'll bring a lot of discussion along, so I'm opening this issue for this purpose. Any suggestions, enhancements, new bearing models, references, examples (how to use), etc, please, report here to keep track of what's happening on ROSS.
Moreover, always add a brief summary in each commit, it helps a lot to understand the changes in the code.
(@verg1lio, @hiagopinacio, @bela-bs, @marcusfilipesr, @JuliaMota, @davidjgm)

Great to know @rodrigomoliveira1, and it's a pleasure to meet you @JuliaMota and @davidjgm. Our team will be working on it, mostly @Ely, @marcusfilipesr and myself (@verg1lio). @bela-bs should be busy finishing the defect models for a while, and @hiagopinacio is our Python/GIT guy when we have critical decisions to make.
Other pull requests will be made for the other bearing types, in total those are: 1) Cylindrical (still to be opened); 2) Tilting-pad (open!) and 3) Thrust (being validated in Matlab), all being thermo-hydro-dynamic bearing models. We will be going for a object-oriented and modular code, using the same iterative procedures to converge the temperature, pressure and velocity fields whenever possible, so it should prove to be a very interesting code to work on. Also, an abstract bearing class with shared properties for the others to inherit is the current go-to idea, but we are open to your inputs as always. We will have a more clear view of the problem as things progress further.
Anyways, we are currently doing the hard translation of the Matlab code to Python, and will follow that with its validation and conference against the working Matlab version. After this procedure is done, we will modularize and make it object-oriented instead of linear.
It is a pleasure to be working on a challenging problem such as this, and with a capable team to top it off! Let's get to it guys.

Good Morning!
The initiative to include a hydrodynamic tilting bearing model is very good. Currently, we have a functional code validated with the literature that calculates the pressure field, forces, equilibrium position and dynamic coefficients for a cylindrical hydrodynamic bearing. Recently, the possibility of two new geometries has been added: the elliptical bearing (or lemon bearing) and the worn bearing. Both validated and with the same returns as the cylindrical bearing.
Including the hydrodynamic tilting bearing is one of the objectives that we have not yet achieved. I believe that the code already implemented in FluidFlow can be used in some way also for this case. Anyway, I think your model should be in the FluidFlow directory, not in a separate location.
I am available for any clarification.
(@verg1lio, @hiagopinacio, @bela-bs, @marcusfilipesr )

I agree with @JuliaMota. These new files should be located in fluidflow folder, because:

it belongs to the same group of classes and functions. Separating them could lead to repeated code.
you could take advantage of several existing methods in FluidFlow package.
adding new folders require adding __init__.py files to install and start the package.

Hi @verg1lio, @hiagopinacio, @bela-bs and @marcusfilipesr,
I would be pleased to help.
As your code is being committed, we can see how the currently code can be integrated with yours, since we have already done some work related to cylindrical bearings. Indeed, a model of tilting-pad bearings is a must-have in the repository; existing methods in the FluidFlow package should help.

Oh that would be all the better @JuliaMota. Our code should be compatible, or at least adaptable, to a standardized formulation without too much trouble. It is our focus at the moment, and the translation should progress quickly too. @davidjgm assistance would also be greatly appreciated, since we do our formulations ourselves, and despite knowing the physics behind it we do not have much, if any, experience with the FluidFlow package.
I believe that we should dedicate some time to familiarize ourselves with what's available at FluidFlow, before commiting to a full conversion of the more extensive convergence methods. That could save us some time and redundant work at the very least.
What is you take on the matter @marcusfilipesr, @elyqg and @hiagopinacio?

I am delighted to know that you guys are going to be around us through this process, I'm sure that your help will be essential.
And I agree with @verg1lio when saying that we should dedicate some time to understand your FluidFlow package.

We published an article at an event of the National Laboratory for Scientific Computing. It contains all the initial formulation for the pressure field and checks with the models used for short and infinitely long bearings. It is still an initial study, but it can help them better understand the formulation.
You can access the article in the proceedings of the XIII EAMC - 2020 event, available at: [http://www.eamc.lncc.br/PastEditions.php]
The article is called "Simplifications of Navier-Stokes in Journal Bearing Simulation", it was written by me, by professor @juvianna  and by @flaviorangel , who contributed a lot with all the initial part of the code.

We published an article at an event of the National Laboratory for Scientific Computing. It contains all the initial formulation for the pressure field and checks with the models used for short and infinitely long bearings. It is still an initial study, but it can help them better understand the formulation.
You can access the article in the proceedings of the XIII EAMC - 2020 event, available at: [http://www.eamc.lncc.br/PastEditions.php]
The article is called "Simplifications of Navier-Stokes in Journal Bearing Simulation", it was written by me, by professor @juvianna and by @flaviorangel , who contributed a lot with all the initial part of the code.

Alright, and thanks for the reference @JuliaMota! I will check it out now and see if it is compatible to what we have implemented here. Out material is based mostly on a Thesis and a Dissertation, and on some smaller works, which we can provide here should you wish it.

Ok, so apparently your model solves the Navier-Stokes equation for the pressure and fluid velocity fields correct? Starting from the geometry, then making the dimensionless analysis with pressure field and finally moving to the Poisson formulation to get the fluid velocity field.
Our model have some differences, but we will evaluate them better tomorrow morning in an internal meeting (@marcusfilipesr @hiagopinacio @verg1lio @elyqg), and get back to you guys after we have a consensus on how to proceed. Again, thanks a lot @JuliaMota @rodrigomoliveira1 and @davidjgm for the assistance, and we will keep updating our course of action and progress here.
Have a good evening!

We published an article at an event of the National Laboratory for Scientific Computing. It contains all the initial formulation for the pressure field and checks with the models used for short and infinitely long bearings. It is still an initial study, but it can help them better understand the formulation.
You can access the article in the proceedings of the XIII EAMC - 2020 event, available at: [http://www.eamc.lncc.br/PastEditions.php]
The article is called "Simplifications of Navier-Stokes in Journal Bearing Simulation", it was written by me, by professor @juvianna and by @flaviorangel , who contributed a lot with all the initial part of the code.

Alright, and thanks for the reference @JuliaMota! I will check it out now and see if it is compatible to what we have implemented here. Out material is based mostly on a Thesis and a Dissertation, and on some smaller works, which we can provide here should you wish it.

Of course! You can give me the references. I see it as soon as possible. As I said, this is an initial study. We've done a lot of things after that. But I believe that by synthesizing FluidFlow modeling well, it will be of great help in this beginning. Whenever I want to pass other references, including some that justify the use of this model. The parameterization of the FluidFlow is a little different from the others in order to facilitate the implementation of other types of bearings and, in the future, to enable an adaptation also for seals. However, it is different only in the way it is described, as it follows the same premises as the classic lubrication theory.

Ok, so apparently your model solves the Navier-Stokes equation for the pressure and fluid velocity fields correct? Starting from the geometry, then making the dimensionless analysis with pressure field and finally moving to the Poisson formulation to get the fluid velocity field.
Our model have some differences, but we will evaluate them better tomorrow morning in an internal meeting (@marcusfilipesr @hiagopinacio @verg1lio @elyqg), and get back to you guys after we have a consensus on how to proceed. Again, thanks a lot @JuliaMota @rodrigomoliveira1 and @davidjgm for the assistance, and we will keep updating our course of action and progress here.
Have a good evening!

That's right! This is basically the way. Any questions, I'm here.

Hello there, and good afternoon!
I will keep working on the hard translation of the matlab code into python for the moment, since there's still a lot to go. But we will soon be having the meeting to define our path from this point on. We hope to clarify some doubts on what and how should we implement the bearing models, and their integration and functioning together with the main ROSS code.
Should you (@rodrigomoliveira1 , @JuliaMota , @davidjgm  or @raphaeltimbo) need any info, just ask away anytime. We also had a general updating of our LMEst fork to the latest ROSS version recently, and i just pushed it here.
So cheers, and have a great week!
Vergilio

@JuliaMota , good afternoon!
You marked me in the Petrobrás MS Teams, but unfortunately I do not have access to that. I saw the mention, but cannot see the message. If possible, could you either give me access or resend the message here?
Thanks, and have a good week!

@JuliaMota , good afternoon!
You marked me in the Petrobrás MS Teams, but unfortunately I do not have access to that. I saw the mention, but cannot see the message. If possible, could you either give me access or resend the message here?
Thanks, and have a good week!

Hi @verg1lio! Good evening!
Unfortunately I don't know how to give you access through Teams, so I'll rewrite the message here:
"I made a simple report with a numerical simulation in FluidFlow for a cylindrical bearing and placed some of the main returns. If you have any doubts on how to generate these results or want some other information, just talk."
(The report is attached)
report_fluidflow.pdf

@JuliaMota , good afternoon!
You marked me in the Petrobrás MS Teams, but unfortunately I do not have access to that. I saw the mention, but cannot see the message. If possible, could you either give me access or resend the message here?
Thanks, and have a good week!

Hi @verg1lio! Good evening!
Unfortunately I don't know how to give you access through Teams, so I'll rewrite the message here:
"I made a simple report with a numerical simulation in FluidFlow for a cylindrical bearing and placed some of the main returns. If you have any doubts on how to generate these results or want some other information, just talk."
(The report is attached)
report_fluidflow.pdf

Ah alright! Thanks for the message here, but I am figuring out the loops at the moment, trying to make them run smoothly has not been an easy task.

@JuliaMota , good afternoon!
You marked me in the Petrobrás MS Teams, but unfortunately I do not have access to that. I saw the mention, but cannot see the message. If possible, could you either give me access or resend the message here?
Thanks, and have a good week!

Hi @verg1lio! Good evening!
Unfortunately I don't know how to give you access through Teams, so I'll rewrite the message here:
"I made a simple report with a numerical simulation in FluidFlow for a cylindrical bearing and placed some of the main returns. If you have any doubts on how to generate these results or want some other information, just talk."
(The report is attached)
report_fluidflow.pdf

Ah alright! Thanks for the message here, but I am figuring out the loops at the moment, trying to make them run smoothly has not been an easy task.

I understand! My first task here at Ross was to translate an initial Matlab code into Python. Loops can cause a lot of headaches. Good luck!

I am delighted to see that steps are taken to implement bearing codes in ROSS.
Below are some thoughts and suggestions specifically for the tilting-pad bearings, based on my experience using the commercial software NSTILT in the RAPPID package from RSR.
NSTILT supports calculation of different pivot models, e.g. tilting mechanisms:

Rocker, where the pad back rolls on the casing, the pad back radius smaller than casing radius.
Ball/Socket, where the segment rolls on a pin inserted inside of the segment.
Pivot, where the segment may pivot about an axial pin.
Do you consider pivot models to be relevant, will the calculations take this kind of input?

Litterature on tilting-pad design, and the manual of NSTILT states that the dynamic response of tilting-pad bearings is frequency dependent. NSTILT deals with this by linarizing the dynamic coefficients (Kxx, Kyy etc) around a frequency. The default is to linearize about the speed frequency, so that the results should give accurate critical speeds, but not necessarily accurate sub-synchronous or higher-order modes. E.g. Kxx @ 500 rpm and 500 cpm = 1.8e9 N/m, Kxx @ 500 rpm and 1000 cpm = 1.7e9 N/m.
Alternatively, I have read that it is possible to use a transfer function to capture this behaviour, but it was not possible in RAPPID.
I am also interested in what kind of other geometric and lubrication input you are considering.
If you want to cross-check the Python routines with output from NSTILT, I can run through some of our previously calculated bearings and compare output.

As a follow-up to my previous post, I have attached the input and output for a typical hydropower large tilting-pad bearing. Here, input, operating parameters and output is fairly well defined, and may be used for comparison.
Tilting_Pad_Example.txt

I am delighted to see that steps are taken to implement bearing codes in ROSS.
Below are some thoughts and suggestions specifically for the tilting-pad bearings, based on my experience using the commercial software NSTILT in the RAPPID package from RSR.
NSTILT supports calculation of different pivot models, e.g. tilting mechanisms:

Rocker, where the pad back rolls on the casing, the pad back radius smaller than casing radius.
Ball/Socket, where the segment rolls on a pin inserted inside of the segment.
Pivot, where the segment may pivot about an axial pin.
Do you consider pivot models to be relevant, will the calculations take this kind of input?

Litterature on tilting-pad design, and the manual of NSTILT states that the dynamic response of tilting-pad bearings is frequency dependent. NSTILT deals with this by linarizing the dynamic coefficients (Kxx, Kyy etc) around a frequency. The default is to linearize about the speed frequency, so that the results should give accurate critical speeds, but not necessarily accurate sub-synchronous or higher-order modes. E.g. Kxx @ 500 rpm and 500 cpm = 1.8e9 N/m, Kxx @ 500 rpm and 1000 cpm = 1.7e9 N/m.
Alternatively, I have read that it is possible to use a transfer function to capture this behaviour, but it was not possible in RAPPID.
I am also interested in what kind of other geometric and lubrication input you are considering.
If you want to cross-check the Python routines with output from NSTILT, I can run through some of our previously calculated bearings and compare output.

Hello @LeifParr, and thanks for the interest! I will try to answer your questions here...
Regarding the pivot, yes, our tilting-pad model does consider the pivot movement. It is a 3D, thermo-hidro-dynamic model, with "n" pads. Currently I am working on the radial pads model, and we will later move on to a thrust bearing model, with similar capabilities. I believe the pivot coefficients and dimensions can be modified in order to simulate any configuration that you cited, but I am not a specialist in bearings.
As to the acquisition of the K and C coefficients, the model produces the complete pressure, temperature, velocity, etc. fields inside the oil films, and those are converted to coefficients around a number of points, depending on the rotation speed, in steady state. These points are later interpolated by the ROSS software, producing reliable bearing coefficients for any given speed within the simulated operating range.
The lubrication is via any fluid (i.e. oil), and we are not considering active control via lubrication. Nevertheless, we do consider temperature and consequently viscosity shifts in the injection regions.
We have a number of experimental and numerical results from our company partners and from our own laboratory test-rigs, but another data set is a great addition to check the results! Thank you very much for it!

Hi there!
I have marked this issue as stale because it has not had activity for 45 days.
Consider the following options:

If the issue refers to a large task, break it in smaller issues that can be solved in
less than 45 days;
Label the issue as wontfix or wontfix for now and close it.

Code implemented in #982. Check with @elyqg to see when can we merge it.

Hi there!
I have marked this issue as stale because it has not had activity for 45 days.
Consider the following options:

If the issue refers to a large task, break it in smaller issues that can be solved in
less than 45 days;
Label the issue as wontfix or wontfix for now and close it.


INTERPRETAÇÃO DA ENTRADA (parsing) (parser)

[ ] Handle $? which should expand to the exit status of the most recently executed foreground pipeline.
[ ] Handle environment variables
[ ] Handle whitespaces
[ ] Handle single and double quotes

https://www.cs.purdue.edu/homes/grr/SystemsProgrammingBook/Book/Chapter5-WritingYourOwnShell.pdf


bqm.to_coo() not storing the offset

Description
bqm offsets are not appearing in .coo files
Steps To Reproduce
import itertools
import dimod

bqm = dimod.BQM.from_ising({}, {c: 1 for c in itertools.combinations(range(4), 2)}, offset=42)

with open("inputs/{}.coo".format("test_1"), "w") as f:
    bqm.to_coo(f, vartype_header=True)

Expected Behavior
the file should look like:
# vartype=SPIN
42
0 1 1.000000
0 2 1.000000
0 3 1.000000
1 2 1.000000
1 3 1.000000
2 3 1.000000

but it looks like:
# vartype=SPIN
0 1 1.000000
0 2 1.000000
0 3 1.000000
1 2 1.000000
1 3 1.000000
2 3 1.000000

Environment

OS: MacOS 10.15.7
Python version: Python 3.7.6
dimod version: 0.9.9

Would be pretty straightforward to add another header line,
# vartype=SPIN
# offset=42
0 1 1.000000
0 2 1.000000
0 3 1.000000
1 2 1.000000
1 3 1.000000
2 3 1.000000

or
# vartype=SPIN, offset=42
0 1 1.000000
0 2 1.000000
0 3 1.000000
1 2 1.000000
1 3 1.000000
2 3 1.000000

unless there was a particular reason you wanted it on it's own line like above?

On it's own line it looks a bit more like it's part of the problem's weights. But I don't know if this could mess with the parsing in older dimod versions.

FWIW, I like @pau557's suggestion. The next logical step is to generalize it to store one polynomial term/coefficient per line:
42
a 1.0
a b 2.0
b c 3.0
a b c 4.0

Then BinaryPolynomial could use it as well.
Obviously, that would not be the COO anymore. :rofl:
If we want to keep calling it COO, the only option, IMO, is to store it in a header. In which case, header output should default to true if offset != 0. (Also if vartype != binary.)


Removes invalid merging approach for too many rows

Closes #3956

Removes the "Merge tables" approach which is not useful for appending datasets.
Not the objective, but: adds workaround for encoding issues

This file will require more near-future work as seen in https://github.com/CartoDB/cartodb/issues/3975
cc @xavijam

Frontend tests were OK :+1: (details)

Ok!

Ok!


Support global custom pageName for pagination links

Currently it's possible to provide a custom page name by setting the name onto an exisiting paginator instance:
$paginator->setPageName('foo');

If you want to customize this for all paginators, for example in case of a non-English application, there's no real possibility except for explicitly calling the setter every time (or pull out some other tricks usings traits or so).
This PR allows to define a custom default for the ?page= and ?cursor= query parameters.
Just set it once in a service provider. And of course you'll still be able to override it whenever needed.
LengthAwarePaginator::setDefaultPageName('p');

$paginator->getPageName(); // 'p'
$paginator->setPageName('foo');
$paginator->getPageName(); // 'foo'

This PR also includes similar functionality for the CursorPaginator.

@Propaganistas
public function paginate($perPage = null, $columns = ['*'], $pageName = 'page', $page = null)

public function simplePaginate($perPage = null, $columns = ['*'], $pageName = 'page', $page = null)

public function cursorPaginate($perPage = null, $columns = ['*'], $cursorName = 'cursor', $cursor = null)

All 3 types have dynamic param for pagination.
Why this is not enough?

This PR allows you to define a global default, without the need to explicitly pass that parameter in every single paginator instance.

Thanks for your pull request to Laravel!
Unfortunately, I'm going to delay merging this code for now. To preserve our ability to adequately maintain the framework, we need to be very careful regarding the amount of code we include.
If applicable, please consider releasing your code as a package so that the community can still take advantage of your contributions!


Question : How can i add point on an existing pointlayer shape file

Hi guys,
I load a linelayer file on my application and a pointlayer with existing point on it, when I want to add a point on it, it always create a new pointlayer and because of this new point layer i can't use map1.function = FunctionMode.Info; to get information of the first point layer should i change this part of my code :
            map1.Cursor = Cursors.Cross;
            shapeType = "Point";
            pointF.Projection = map1.Projection;
            compt++;
            pointLayer = (MapPointLayer)map1.Layers.Add(pointF);
            PointSymbolizer symbol = new PointSymbolizer(Color.Red, DotSpatial.Symbology.PointShape.Ellipse, 10);
            pointLayer.Symbolizer = symbol;
            pointLayer.LegendText = "point";
            pointmouseClick = true;

Thank you for your answer !

No idea what the rest of your code looks like but pointLayer = (MapPointLayer)map1.Layers.Add(pointF); definitely adds your pointF featureset as new pointlayer to the legend.
As you posted only the part that creates the point layer but not the code around it you'll have to find out yourself where you have to move the code so you won't add the layer more than once.

I tried to add pointF on my existing pointLayer by using pointLayer = map1.Layers[1] as MapPointLayer;
but i need something to add my pointF to this layers, i tried pointLayer.DataSet.AddFeature(pointF); but that does not work. What should i try ?
Here is my code :
` public partial class frmCarte : Form
{
string shapeType;
#region Point ShapeFile class level variable
    string fichier;
    FeatureSet pointF = new FeatureSet(DotSpatial.Data.FeatureType.Point);

    MapPointLayer pointLayer = new MapPointLayer();

    DataColumn colonneId = new DataColumn("id");
    DataColumn colonneRef = new DataColumn("Référence");
    DataColumn colonneDate = new DataColumn("Date");
    DataColumn colonneh1 = new DataColumn("h1");
    DataColumn colonneh2 = new DataColumn("h2");
    DataColumn colonneh3 = new DataColumn("h3");
    DataColumn colonnehmoy = new DataColumn("hmoy");
    DataColumn colonneBat = new DataColumn("Batiment");
    DataColumn colonneEta = new DataColumn("Etage");
    DataColumn colonneLat = new DataColumn("Latitude");
    DataColumn colonneLong = new DataColumn("Longitude");

    DateTime auj = new DateTime();
    int pointID = 0;

    int compt = 0;
    bool pointmouseClick = false;
    #endregion
    public frmCarte()
    {
        InitializeComponent();
    }

    private void btnChargerCarte_Click(object sender, EventArgs e)
    {

        map1.AddLayers();

        foreach (ILayer layer in map1.Layers)
        {
            fichier = layer.DataSet.Name;
        }
        map1.AddLayer("D:\\Stage2017\\charge\\bat400_et0_casa.shp");

//I tried this :
pointLayer = map1.Layers[1] as MapPointLayer;
    }

    private void button2_Click(object sender, EventArgs e)
    {

        Passerrelle.pass.nbLay = map1.Layers.Count();
        Passerrelle.pass.tabLayer = pointLayer;
        InterfaceTableau.frmTab f = new frmTab();
        f.Show();
    }

    private void btnAddPoint_Click(object sender, EventArgs e)
    {
        if (compt == 0)
        {

            pointF.DataTable.Columns.Add(colonneId);
            pointF.DataTable.Columns.Add(colonneRef);
            pointF.DataTable.Columns.Add(colonneDate);
            pointF.DataTable.Columns.Add(colonneh1);
            pointF.DataTable.Columns.Add(colonneh2);
            pointF.DataTable.Columns.Add(colonneh3);
            pointF.DataTable.Columns.Add(colonnehmoy);
            pointF.DataTable.Columns.Add(colonneBat);
            pointF.DataTable.Columns.Add(colonneEta);
            pointF.DataTable.Columns.Add(colonneLat);
            pointF.DataTable.Columns.Add(colonneLong);

        }

        map1.Cursor = Cursors.Cross;
        shapeType = "Point";
        pointF.Projection = map1.Projection;
        compt++;
        pointLayer = (MapPointLayer)map1.Layers.Add(pointF);
        PointSymbolizer symbol = new PointSymbolizer(Color.Red, DotSpatial.Symbology.PointShape.Ellipse, 10);
        pointLayer.Symbolizer = symbol;
        pointLayer.LegendText = "point";
        pointmouseClick = true;
    }

    private void btnDeplacerCarte_Click(object sender, EventArgs e)
    {
        map1.FunctionMode = FunctionMode.Pan;
    }

    private void btnSave_Click(object sender, EventArgs e)
    {
        pointF.SaveAs("pointADP.shp", true);
        MessageBox.Show("Couche de point sauvegardé");
    }

    private void map1_MouseDown(object sender, MouseEventArgs e)
    {
        auj = DateTime.Now;
        switch (shapeType)
        {
            case "Point":
                if (e.Button == MouseButtons.Left)
                {

                    if ((pointmouseClick))
                    {
                        frmValid f = new frmValid();
                        f.ShowDialog();

                        if (Passerrelle.pass.ann)
                        {
                            GeoAPI.Geometries.Coordinate coord = map1.PixelToProj(e.Location);
                            NetTopologySuite.Geometries.Point point = new NetTopologySuite.Geometries.Point(coord);

                            IFeature currentFeature = pointF.AddFeature(point);
                            pointID = pointID + 1;
                            currentFeature.DataRow["Référence"] = fichier + Passerrelle.pass.reff;
                            currentFeature.DataRow["Date"] = auj;
                            currentFeature.DataRow["hmoy"] = Passerrelle.pass.hmoy;
                        }
                    }
                        map1.Refresh();
                        map1.ResetBuffer();
                        map1.FunctionMode = FunctionMode.Pan;
                        map1.Cursor = Cursors.Default;
                        pointmouseClick = false;
                }

                else
                {
                    map1.ResetBuffer();
                    map1.Cursor = Cursors.Default;
                    pointmouseClick = false;
                    map1.FunctionMode = FunctionMode.Pan;
                }
                break;
            case "Suppr":
                if (e.Button == MouseButtons.Left)
                {

//This part is not finish, i try here to delete a point by only click on it
//GeoAPI.Geometries.Coordinate coord = map1.PixelToProj(e.Location);
//NetTopologySuite.Geometries.Point point = new NetTopologySuite.Geometries.Point(coord);
//pointLayer.RemoveFeaturesAt();
}
break;
        }
    }`

Thank a lot for your help

I think you have confused some things. Your pointF is a FeatureSet not a Point. That's why you can't add it to your existing pointLayer.
If you want to add your point to your existing layer use
IFeature currentFeature = pointLayer.DataSet.AddFeature(point);
instead of
IFeature currentFeature = pointF.AddFeature(point);

It works, thank you again for your help !


No show Command Palette

I press Cmd+Shift+P on macOS and no show Command Palette，just show Go To File
macOS m1，install by homebrew
I coding in golang，How do I change Lapce settings in golang envrionment
Plugin show  "failed to load plugin infomation" , It is my net error? plugin address is unvisited for China Developer?
Thanks

I  press Cmd+Shift+P on macOS and no show Command Palette，just show Go To File

That's strange. You can type : when in the Go To File to switch to the command palette. Though that keybind should work as far as I know.

I coding in golang，How do I change Lapce settings in golang envrionment

If you're using the lapce-go LSP plugin, then you can go to its folder and edit the plugin.toml file. This requires knowing what settings it accepts. ( https://github.com/golang/tools/blob/master/gopls/doc/settings.md )
This will probably get a panel in the settings eventually, but it doesn't have one right now.

Plugin show "failed to load plugin infomation" , It is my net error? plugin address is unvisited for China Developer?
Thanks

If it doesn't load at all, then I presume it might be getting blocked. The plugin list is hosted at https://lapce.github.io/plugins.json

I have the same problem. Tried version 0.2.0 and 0.2.5. Windows version from website.
I can open https://lapce.github.io/plugins.json from my browser.
Also, I can't click on "Plugin settings" in Settings.

I can open lapce.github.io/plugins.json from my browser.

It's not used anymore, we have new plugin registry at https://plugins.lapce.dev

It's not used anymore, we have new plugin registry at https://plugins.lapce.dev

Well, I can open that too.


Link to information about the monster (e.g. on dndbeyond)

I would like to propose adding a link, both in the monsters table and the encounter info, to the monster on dnd beyond.
For example, a Bat would link to https://www.dndbeyond.com/monsters/bat .
I believe that could prove super helpful for people using mostly digital tools to run sessions.

Duplicate of #112

Ah was just editing to say I think it's different to that other one as I'm not talking about integrating an API into KFC, but rather a simple link-out to the page on dnd beyond, sorry!

I'd be willing to look into the creation of the dndbeyond links.
Does anyone know, whether it would be legally safe to add a preview of the boxes on DDB to KFC? (See attached image)

Furthermore I'm not sure, if all the monsters are available for free on DDB or you need to purchase the monster manual.
Anyways: awesome project! keep up the great work <3


Question: TypeGraphQL uses functions to prevent circular dependencies-wouldn't this package's API suffer from the same problem?

the quote from:
https://19majkel94.github.io/type-graphql/docs/types-and-fields.html
Why function syntax, not simple { type: Rate } config object? Because this way we solve problems with circular dependencies (e.g. Post <--> User), so it was adopted as a convention. You can use the shorthand syntax @Field(() => Rate) if you want to safe some keystrokes but it might be less readable for others.

https://github.com/prismake/typegql/blob/6797a9ad0e0449e569e8f7c247d0ddc4c2c16f65/docs/explore/object-type-and-field.md#circular-type-references

cool, but wait do you contribute here too @19majkel94 ?

@capaj Nope, I just secretly watch all related projects and sometimes try to help in the name of the open source community 😉

@19majkel94 nice :1st_place_medal:  I have to say It's a shame you don't work on the same project with @pie6k, because you two would make a great team-both of your libraries have very similar API and design goals. Seems like a waste of time to be working separately. But I guess in such an early stage of graphQL ecosystem more POCs isn't such a bad thing.

@capaj
I've proposed that a long time ago:
https://github.com/indigotech/graphql-schema-decorator/issues/65#issuecomment-370560844
But since that time our visions have splited - this is what @pie6k said:

So I think it's better when users have an ability to choose between library vs. framework and also the competition makes the development faster 😄

@19majkel94 great to hear what the difference really is. I can certainly appreciate both approaches-I am sure there are going to be apps well suited to both paradigms. Thanks for all the info! I am considering using one or the other in our API at Looop.co and these are exactly the things I need to know.

Thanks @capaj  @19majkel94 .
Right, if you've got circular dependencies you'd have to use type lazy function like:
import { ObjectType, Field } from 'typegql';

@ObjectType()
class Car {
  @Field({ type: () => Person })
  owner() {
    return db.findPersonByCarId(this.id);
  }
  @Field() id: number;
}

@ObjectType()
class Person {
  @Field() id: number;
  @Field() name: string;
  @Field({ type: () => Car })
  car() {
    return db.findCarByOwnerId(this.id);
  }
}

Note it might be not needed anymore if typescript itself would make reflection metadata lazy in its core.


Fixing shadow variables in PA-related classes [shadow-pa-dev]

This PR partially addresses issue #2701.
I tried to make minimal changes and keep the spirit of the original variable names. Hopefully, splitting these into small PRs will assist the original authors and/or reviewers in assessing the changes.
The compiler has no trouble determining which variable is intended but the choice is not always obvious to developers who may not be aware of one or the other of the possibilities.

PR
Author
Editor
Reviewers
Assignment
Approval
Merge

#2741
@mlstowell
@tzanio
@YohannDudouit + @dylan-copeland
12/28/21
2/22/22
⌛due 1/18/22

This PR is now under review (see the table in the PR description). To help with the review process, please do not force push to the branch.

Merged in next for testing...


Request: Hide by keyword (blocked keyword list)

MarcD2K23 has a wonderful script to hide items by keyword eg "sunglasses"
https://raw.githubusercontent.com/MD2K23/VineToolsUK/master/hideVineItems.user.js
It would be wonderful if there was something like this in vinehelper too!

Added to the next version


Add routing to get unaggregated entries

@JasonQiu21 /commanders works with minimal inputs on client. I'll test thoroughly later on. Please help with that

@g00gol Added a new route and server-side CR calculation

@JasonQiu21 Go through Postman requests to make sure returned data is valid. Attach a screenshot

Route get_commanders still works as usual, commanders just have topCuts and conversionRate attached to them now