refactor: use go-logr/logr with log/slog backend

Addresses #1419
This PR standardises on the go-logr/logr interface with log/slog as the actual logging implementation.
Level names
There's a little bit of logic on top of the globalLogger to achieve clearer level field names in log messages. By default logr negates the V() for slog, effectively achieving:

logr
slog

V(1)
-1

V(2)
-2

...
...

V(4)
-4 (DEBUG)

In practice, this means that the following logs:
log.Info("0")
log.V(1).Info("", "slog-level", "1")
log.V(2).Info("", "slog-level", "2")
log.V(3).Info("", "slog-level", "3")
log.V(4).Info("", "slog-level", "4")

result in the following log output:
time=2006-01-02T15:04:05.000-07:00 level=INFO msg=0
time=2006-01-02T15:04:05.000-07:00 level=DEBUG+3 msg="" slog-level=1
time=2006-01-02T15:04:05.000-07:00 level=DEBUG+2 msg="" slog-level=2
time=2006-01-02T15:04:05.000-07:00 level=DEBUG+1 msg="" slog-level=3
time=2006-01-02T15:04:05.000-07:00 level=DEBUG msg="" slog-level=4

Using ReplaceAttr from slog.HandlerOptions allows us to modify it, getting rid of the +{number} bit from level field. The same logs achieve the following output:
time=2006-01-02T15:04:05.000-07:00 level=INFO msg=0
time=2006-01-02T15:04:05.000-07:00 level=DEBUG msg="" slog-level=1
time=2006-01-02T15:04:05.000-07:00 level=TRACE msg="" slog-level=2
time=2006-01-02T15:04:05.000-07:00 level=TRACE msg="" slog-level=3
time=2006-01-02T15:04:05.000-07:00 level=TRACE msg="" slog-level=4

Currently the lowest defined level is LevelTrace at V(2) or slog.Level(-2), meaning that any logs with a higher logr level will never be shown.
Warning level
Since logr maps to slog.Level() by negating the V() field, it's impossible to log at warning level. I've added PR comments to highlight instances of log.Warn and tried to replace them with what made sense to me.

@bakunowski thank you so much for tackling this.
I left a number of comments -- and many of them are applicable in many places other than where I pointed them out. I didn't want to get carried away pointing out every instance of a general something I had feedback on...
Please don't let the number of comments fool you into thinking this PR is anything less than awesome. I am so happy to see progress on this! This is, unfortunately, just what happens when some cross-cutting concern like logging receives a broad update.
We're on the right track!

@bakunowski thank you so much for tackling this.
I left a number of comments -- and many of them are applicable in many places other than where I pointed them out. I didn't want to get carried away pointing out every instance of a general something I had feedback on...
Please don't let the number of comments fool you into thinking this PR is anything less than awesome. I am so happy to see progress on this! This is, unfortunately, just what happens when some cross-cutting concern like logging receives a broad update.
We're on the right track! 🙏

Thanks for the detailed review! Sounds good, I didn't expect this to go down easy 😄
Sorry about the delay in getting back - last week has been pretty busy. I'll try to address the comments and make changes where it's clear what they should be.

As we're approaching a v0.6.0 release and there's a sizeable amount of work outstanding here, this is being deferred to v0.7.0.

Closing in favor of #2073


Update MEWDX and other exogenous parameters

After we implement the new FTT:P data into E3ME, we should update the various exogenous demand parameters, such as MEWDX. This may also be an opportunity to see which ones can be deleted from the repo.

We may want to hold off on this until the updates are finalised for transport, as this should impact the baseline electricity demand (there isn't much of a change with the heat update as far as I'm aware).


buildpack not working on heroku-22 stack

I believe there is some configuration problem with this heroku buildpack and the heroku-22 stack.  Here are a few things I have tried:

Installing with different FREETDS_VERSION settings (and none at all)
with the main branch of this code, 1.1.2 and 1.1.1 versions, and same problem
On my local macbook, I can run the freetds tsql connection command to connect almost instantaneously to a variety of mssql databases (one on ec2 and two on azure), but the same command times out on heroku bash prompt:

~ $ tsql -H ***.rds.amazonaws.com -p 1433 -U *** -P ***
locale is "en_US.UTF-8"
locale charset is "UTF-8"
using default charset "UTF-8"
103Error 20002 (severity 9):
	Adaptive Server connection failed
Error 20002 (severity 9):
	Adaptive Server connection failed
There was a problem connecting to the server

I can ping the server from heroku bash:

~ $ nslookup <host1>.us-east-1.rds.amazonaws.com
Server:		<ip address>
Address:	<ip address>#53

Non-authoritative answer:
<host1>.rds.amazonaws.com	canonical name = <host name>.compute-1.amazonaws.com.
Name:	<host name>.compute-1.amazonaws.com
Address: <another ip address>

~ $ nc -zv <host1>us-east-1.rds.amazonaws.com 1433
Connection to <host1>.us-east-1.rds.amazonaws.com (<another ip address>) 1433 port [tcp/ms-sql-s] succeeded!

Any ideas would be greatly appreciated!

For some more information, here is FreeTDS version local and remote:
# LOCAL:
$ tsql -C
Compile-time settings (established with the "configure" script)
                            Version: freetds v1.3.13
             freetds.conf directory: /opt/homebrew/etc
     MS db-lib source compatibility: no
        Sybase binary compatibility: yes
                      Thread safety: yes
                      iconv library: yes
                        TDS version: 7.3
                              iODBC: no
                           unixodbc: yes
              SSPI "trusted" logins: no
                           Kerberos: yes
                            OpenSSL: yes
                             GnuTLS: no
                               MARS: yes

# Heroku:
$ heroku run bash -a doorlock-ror
Running bash on ⬢ doorlock-ror... up, run.4557 (Hobby)
~ $ tsql -C
Compile-time settings (established with the "configure" script)
                            Version: freetds v1.3.13
             freetds.conf directory: /app/freetds/etc
     MS db-lib source compatibility: no
        Sybase binary compatibility: no
                      Thread safety: yes
                      iconv library: yes
                        TDS version: 7.3
                              iODBC: no
                           unixodbc: no
              SSPI "trusted" logins: no
                           Kerberos: no
                            OpenSSL: yes
                             GnuTLS: no
                               MARS: yes


check-kernel-config: Ensure BT_HCIVHCI is enabled for halium-9

bluebinder relies on this kernel option to be enabled.
The package is already present on Erfan's Halium 9 GSI and BT works fine with it :)

Closing as nothing has happened with this and it's now also a part of #8 since Erfan picked this.


Snippet in Github Actions Marketplace is wrong

Bellow stated snippet on Github Actions Marketplace also Readme uses wrong values for retry-all and follow-redirects. Using proposed values yes, no results in following error:
Error: TypeError: Input does not meet YAML 1.2 "Core Schema" specification: follow-redirect
Support boolean input list: true | True | TRUE | false | False | FALSE
Solution: docs should use true | True | TRUE | false | False | FALSE
steps:
  - name: Check the deployed service URL
    uses: jtalk/url-health-check-action@v2
    with:
      # Check the following URLs one by one sequentially
      url: https://example.com|http://example.com
      # Follow redirects, or just report success on 3xx status codes
      follow-redirect: no # Optional, defaults to "no"
      # Fail this action after this many failed attempts
      max-attempts: 3 # Optional, defaults to 1
      # Delay between retries
      retry-delay: 5s # Optional, only applicable to max-attempts > 1
      # Retry all errors, including 404. This option might trigger curl upgrade.
      retry-all: no # Optional, defaults to "no"

Hey @MarekLani, sorry about that. The yaml spec update probably came with some of the GH dependencies, and I forgot to update the readme. Thanks for the PR!


Feature request: please update winston to v3

Though somebody may think v2 was better (for example https://github.com/winstonjs/winston/issues/1653), so it's up to you to decide.

This was fixed with #229
Thanks!


Bad Request 400 - Payload is either malformed or incomplete - code: 400003

Hi Gary, and thanks again for this provider. ✨ My team is very excited about this. However we're getting a 400 - Bad Request error when we try to create users. I've actually commented on the other issue which is closed but realised I'm getting a different error message and it's likely a different issue.
Anyways, I would appreciate if you could help me. I define users as follows:
locals {
  test_group_users = [
    {
      auth_setting = "TableauIDWithMFA"
      email        =<EMAIL_ADDRESS>      full_name    = "Example Person"
      name         = "Example"
      site_role    = "Viewer"
    },
  ]
}

resource "tableau_user" "test_user" {
  for_each = { for user in local.test_group_users : user.name => user }

  name         = each.value.name
  full_name    = each.value.full_name
  email        = each.value.email
  auth_setting = try(each.value.auth_setting, "Viewer")
  site_role    = try(each.value.site_role, "TableauIDWithMFA")
}

It plans perfectly but fails to apply with the output:
Error: Error creating user
with tableau_user.test_user["Example"]
on users.tf line 15, in resource "tableau_user" "test_user":
resource "tableau_user" "test_user" {
Could not create user, unexpected error: status: 400, body: {"error":{"summary":"Bad Request","detail":"Payload is either malformed or incomplete","code":"400003"}}

I use server version 3.13 (also tried 3.18) and provider version 0.0.17

Hey @harikaduyu!! Thanks for checking this project out! Could you try setting the name argument to being the user's email address? I have a feeling it may just be expecting that because it's MFA auth 😬
If that turns out to solve your problems I'll add it to the docs!!

Hey @harikaduyu!! Thanks for checking this project out! Could you try setting the name argument to being the user's email address? I have a feeling it may just be expecting that because it's MFA auth 😬
If that turns out to solve your problems I'll add it to the docs!!

Hi @GtheSheep! Thanks a lot for the response. It worked 🎉 I tried also SAML and it was the same, so only worked when I sent email as name as well. I wonder if it's the same for all auth methods, maybe it makes sense to not expose the name field at all and always send email to the API in the background, instead of updating the docs. Because it was a bit confusing to me as a user. Anyways, thanks again for the help! ✨

yep yep, don't think I can hide the param, but can catch the unexpected pairings 😸  thanks!


rm running avg calculation w cheaper simpler alt

This way of computing averages was innappropriate for this use case leading to excess compute. Now, simplified.

[ORA-1456]

I'm good on this PR, but I think kenny should be the one to approve it


P sparse matrix refactoring

Here it goes a big one.
See CHANGELOG.md for further details.

Codecov Report
Attention: 78 lines in your changes are missing coverage. Please review.

Comparison is base (25ed3ef) 86.40% compared to head (997ac6e) 88.82%.

Files
Patch %
Lines

src/p_sparse_matrix.jl
92.16%
68 Missing :warning:

src/p_range.jl
84.00%
4 Missing :warning:

src/primitives.jl
78.94%
4 Missing :warning:

src/p_vector.jl
98.57%
2 Missing :warning:

Additional details and impacted files
@@            Coverage Diff             @@
##           master     #125      +/-   ##
==========================================
+ Coverage   86.40%   88.82%   +2.41%
==========================================
  Files          10       10
  Lines        2641     3650    +1009
==========================================
+ Hits         2282     3242     +960
- Misses        359      408      +49

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.


Revert Test Release

Reverts xiel/location-state#5

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


adding code_of_conduct file

let me know if this needs to be done

Go ahead! @Sloth-Panda

Go ahead! @Sloth-Panda


fix: add place order button to CheckoutActions

Resolves #268
Impact: Minor
Type: fix
Summary
Adds "Place you order" button to CheckoutActions and updates example.
Testing

Visit the CheckoutActions component
Complete steps 1-4
Verify the last step display the "Place your order" button

🚀 Preview deployed
Built with commit 5910ee821fcd085e7f9d5133c96fe23ac1c302b5
https://deploy-preview-273--stoic-hodgkin-c0179e.netlify.com

@mikemurray updated to match designs

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

npm package (@latest dist-tag)
GitHub release

Your semantic-release bot :package::rocket:


WebApp - Allow selecting token to pay transaction fee on HydraDX

[x] Allow paying tx fee with tokens other than native token

Continue implementing on the issue https://github.com/Koniverse/SubWallet-Extension/issues/2959


No option to allow decorators

Decorators are disabled by default, even though the Lit documentation recommends their usage for typescript components. Perhaps it would be useful to add a --decorators=true flag if you want decorators in your project.

yea prob gonna make it an option or something in the reworked cli from the #1 idea, [src] [type] [subtype] [...options], have options be like decorators vs traditional syntax, as well as throwing a little server in rather than just a dev server (whats in full-default atm), an option could also be frontend/server

for the new version I just defaulted in the typescript templates


Ros2_control diff_drive cant turn in gazebo

Describe the bug
When working with the ros2_control package using the diff_drive_controller in gazebo the robot responds to the linear.x component of the twist message and drives forward; however it doesn't respond to the angular.z component of the message for turning.
To Reproduce
Steps to reproduce the behavior:
Download the following package: https://drive.google.com/drive/folders/1SJmruuz5IH7Jz0EOMfMslK-AsFCxvWfa?usp=sharing

Important files in package:
urdf of robot: resource/ezrassor.xacro
gazebo file for robot: resource/ezrassor.gazebo
ros2_controller config file: config/standard_rover/default_position_controllers.yaml
launch file for simulation/robot: launch/simulation_launch.py

Build package:
colcon build

Run the following launch command:
ros2 launch ezrassor_arm_v2 simulation_launch.py rover_model:=standard control_methods:=autonomous

Wait for all nodes to launch
(This will finish with a log to the console saying that the object detection and autonomous control nodes initalized.)

Publish the following message to console which will cause the robot to drive forward as intended:
ros2 topic pub /ezrassor/diff_drive_controller/cmd_vel_unstamped geometry_msgs/Twist '{linear: {x: 1.0, y: 0.0, z: 0.0}, angular: {x: 0.0,y: 0.0,z: 0.0}}'

Publish the following message to console which will show the error as the robot will not turn as intended:
ros2 topic pub /ezrassor/diff_drive_controller/cmd_vel_unstamped geometry_msgs/Twist '{linear: {x: 0.0, y: 0.0, z: 0.0}, angular: {x: 0.0,y: 0.0,z: 1.0}}'

Expected behavior
The robot should turn or at least show force being exerted to the wheels in an attempt to turn but no response is seen from the tires at all when given the angular.z component
Environment (please complete the following information):
OS: Ubuntu 20.04 (Focal Fossa)
Version Foxy

Additional context
Seems that there may be an issue with the communication of the angular.z component to the wheel drivers in gazebo. I have tried messing with the mu values as recommended in other issues like this but to no avail.

So what version is your all's stuff tested with, galactic? Just curious cause i may just upgrade the project to that version if its been tested and is stable

I was testing diff drive on rolling and galactic. There should be working.
And don't expect us to test your package. This sounds very much like wrong configuration. Check the output/publishers of DiffDrive controller and see what happens when you use "open_loop". Compare rviz and gazebo outputs.

@RobertForristall any news on this issue?

Hi, I know this question has been opened for a while but I also have the same issue on foxy. I'm using open_loop and it appears that the odometry is updating accordingly but the wheels are not rotating when sending angular input. Only linear input makes the wheels turn. I can see that the odometry is updated in rviz and when manually inspecting odom but the velocity on the wheels are not considering the angular vector. I am using the gazebo_ros2_control package.

Well this is embarrassing... I misspelled wheel_separation/wheel_seperation... now it works great, thanks!


Remove extraneous space

PR Summary
Remove extraneous space from example command.
PR Checklist

[x] Descriptive Title: This PR's title is a synopsis of the changes it proposes.
[x] Summary: This PR's summary describes the scope and intent of the change.
[x] Contributor's Guide: I have read the contributors guide.
[x] Style: This PR adheres to the style guide.

Can you please check if the other Operating System articles for the same cmdlet require the same edit? thanks

changes pushed

@microsoft-github-policy-service agree

cla signed, anything left to do on my end?

any good news?


ComputerVision 6.0.0 gives ComputerVisionErrorException "Operation returned an invalid status code 'NotFound'"

ReadInStreamAsync method in computer vision SDK(6.0.0) throws "Operation returned an invalid status code 'NotFound'" calling from container Cognitive Services Computer Vision API(vision/v3.2-preview.1/read).
Container have been configured with :
1)billing endpoint
2)eula -> accept
3)apikey
Cognitive container service Ready returns:
{"service":"computervisionread","ready":"ready","message":"Api is ready.."}
Should we use a different version in container cognitive service for computer vision SDK(6.0.0)? Please help

Thank you for your feedback.  Tagging and routing to the team best able to assist.

Thank you for your feedback.  Tagging and routing to the team best able to assist.

@logtosachin993
Apologies for the delayed response. I see that this issue is opened long time ago and no further activity had taken place. So wanted to check if you are still looking for assistance on this query? Please let us know .


When the registry doesn't know of the model/manifest, have a clearer error

I mis-typed the name of the model I wanted to run, and got a JSON-encoded error message:
MacBook-Pro-2:~ griscom$ ollama list
NAME                	SIZE  	MODIFIED
llama2:13b          	7.3 GB	9 hours ago
llama2:latest       	3.8 GB	2 days ago
nous-hermes:latest  	7.3 GB	23 hours ago
orca:latest         	1.9 GB	23 hours ago
wizard-vicuna:latest	7.3 GB	24 hours ago
MacBook-Pro-2:~ griscom$ ollama run orcq
pulling manifest
Error: stream: pull model manifest: "registry responded with code 404: {\"errors\":[{\"code\":\"MANIFEST_UNKNOWN\",\"message\":\"manifest unknown\",\"detail\":{\"Tag\":\"latest\"}}]}\n"
MacBook-Pro-2:~ griscom$

It would be helpful if ollama parsed this error (and others?) to provide a more user-friendly message, e.g. "Unknown model 'orcq'".

Same issue on my end when performing action with ollama run modelfile. Model llama2-13B was already pulled with ollama.
I will troubleshoot it to find if there are any workarounds in the current version 0.0.11

@dtgriscom this is great. Thanks for creating an issue!

@dtgriscom this is great. Thanks for creating an issue!

Always happy to complain... ;)


add stats for crd validation failures

When CRD validations fail, it is only visible in logs. It would be nice, if we have a stat to alert on it. This PR adds two stats for the same.

@ramaraochavali: The following test failed, say /retest to rerun them all:

Test name
Commit
Details
Rerun command

unit-tests_istio
b0ca5934a91a3015b2a182d5ba2cb5e35ddde7fb
link
/test unit-tests_istio

Instructions for interacting with me using PR comments are available here.  If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here.

/test unit-tests_istio

/retest


SpeakersList Recycler View Image duplication

Actual Behaviour
While testing a sample, I came across this issue wherein, the speaker images are duplicated and shown against incorrect speaker names, although on clicking on the speaker, the correct speaker image shows up in the speaker detail activity.
Expected Behaviour
There shouldn't be any duplication.
Screenshots of the issue

Would you like to work on the issue?
Yes.
Target Milestone to solve the issue
Till which milestone will you be fixing the issue?
https://github.com/fossasia/open-event-android/milestone/27

@mahikaw Yes this does happen. Very weird.
@iamareebjamal I am facing this while doing the global search too.

this has to an issue from the json side. dont think there is a fault in the codebase.

I don't think so. As this didn't happen earlier in the speaker fragment. If
the json hasn't changed this problem shouldn't have come up.
On Jun 3, 2017 5:30 PM, "Arpit Aggarwal"<EMAIL_ADDRESS>wrote:

this has to an issue from the json side. dont think there is a fault in
the codebase.
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
https://github.com/fossasia/open-event-android/issues/1644#issuecomment-305970626,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AS-BfRGfNk1NX3Xc4QvhnQ_lkyJFfglbks5sAUrMgaJpZM4NvB7-
.

@shreyasnbhat we are loading speaker images through picasso where we provide the link of the image stored in drive or elsewhere. so where do you think fault can occur? i dont think any issue is there with our codebase, its the path of images which are causing the duplication.

@arp95 as I have mentioned in the issue description the image shown is correct in speaker detail  when we click on it. It is only in the list view that this discrepancy arises.

@mahikaw It is probably standard recyclerview behaviour. RecyclerView uses only a constant amount of viewholders so if a previous viewholder contains a loaded image and the new one didn't load anything over it ( skipped due to null check ), then it will keep showing the old image. I think resetting the image if it is null, i.e., resetting it in else block of the null check for thumbnail will fix the issue

@iamareebjamal recyclerview arent fast enough to ensure correct viewholder is loaded?

Yes, I too find similar stuff on googling this. I will send a PR by tonight. I am away from my laptop right now.

@arp95 It is not about being fast. In a screen where 8 views are visible on the screen, recyclerview initializes only about 12 objects of viewholder to be fast. The disadvantage is that the viewholders are not isolated from each other and are recycled. So if you load a color or image in one recyclerview and don't load anything for some other data item, it will retain the previous loaded image and color. So, we should always reset the data in onBindViewHolder

@iamareebjamal lets say i view the app on a tablet where there is more space, does recyclerview allocate more viewholders? i mean the allocation of objects is dynamic or fixed?

Dynamic. 2 more rows than visible AFAIK

@mahikaw Please check if the issue persists. Should be fixed now

yeah i think it should be resolved now.

fixed via #1647


Custom editor / custom document discussion

Temporarily forking off a more focused discussion from #77131
Background
The custom editor proposal in VS Code 1.41 defines a single provider method called resolveWebviewEditor that both lets extensions implement the custom editor view and create a model for that view. This means there is a 1:1 relationship between views and models, which is problematic when multiple views of the same resource are opened. In cases where that happens, triggering save ends up triggering save for each model that exists for the resources, resulting in multiple saves for the same resource
To fix this, we believe the best approach is to separate the model part of custom editors from the view part of custom editors. @bpasero, @eamodio, and I iterated on some possible approach to this at the custom editor sync, and later @kieferrm and I continued the discussion.
This issue covers two possible ways to accomplish the split
Design one — Fully separate custom documents and  custom webview editors
This design attempts to decouple the idea of a custom document (the model) from the custom editor that presents that document. Custom documents would be similar to TextDocument in the existing VS Code api.
One goal of this design is to allow multiple custom editor views to be registered for a given type of custom document. These custom editor views could even come from different extensions
Key points design 1:

Two providers + two extension points, one for custom documents and one for custom editors
A single CustomDocumentDelegate is used for all editors of a given type
The CustomDocument objects would be created by VS Code. Extensions could access the original object returned by CustomDocumentDelegate using the .delegate property
CustomDocument objects share many properties with TextDocument

API:
namespace window {
	export function registerWebviewCustomEditorProvider(viewType: string, provider: WebviewCustomEditorProvider, options?: WebviewPanelOptions): Disposable;

	export function registerCustomDocumentDelegate(documentType: string, delegate: CustomDocumentDelegate): Disposable;
}

interface CustomDocumentDelegate {
	readonly editingDelegate?: CustomDocumentEditingDelegate;
}

interface CustomDocumentEditingDelegate {
	save(document: CustomDocument<unknown>): Thenable<void>;
	saveAs(document: CustomDocument<unknown>, targetResource: Uri): Thenable<void>;

	readonly onEdit: Event<{ document: CustomDocument<unknown> }>;

	applyEdits(document: CustomDocument<unknown>, edits: readonly any[]): Thenable<void>;
	undoEdits(document: CustomDocument<unknown>, edits: readonly any[]): Thenable<void>;
}

export interface WebviewCustomEditorProvider {
	resolveWebviewEditor(document: CustomDocument<unknown>, webview: WebviewPanel): Thenable<void>;
}

export interface BaseDocument {
	readonly uri: Uri;
	readonly fileName: string;
	readonly isUntitled: boolean;
	readonly isDirty: boolean;
	readonly isClosed: boolean;

	save(): Thenable<boolean>;
}

interface CustomDocument<T extends CustomDocumentDelegate> extends BaseDocument {
	readonly delegate: T;
}

Contributions:
"webviewEditors": [
    {
        "viewType": "testWebviewEditor.abc",
        "displayName": "Test ABC editor",
        "documentType": "testWebviewEditorDocument.abc"
    }
],
"customDocument": [
    {
        "documentType": "testWebviewEditorDocument.abc",
        "selector": [
            {
                "filenamePattern": "*.abc"
            }
        ]
    }
]

Design 2 — Single provider that acts as both delegate and resolver
At first, this design may appear identical to our existing api proposal. However this proposal actually evolved from Design 1
The main difference from design 1 is that here we tightly couple the custom document (model) to the custom editor (view). The reasoning for this is that while looser coupling is generally preferable, Design 1 may be too loose to actually be useful.
To understand why, consider a custom image editor. With Design 1, there are two ways the coupling between model and view could work:

The model only operates on binary data. The views manipulate the model's binary data.
This is super flexible but not performant. It is also not easy to implement views that do this.

The model expresses some set of image operations that it supports (crop, resize, ...). The views call these to operate on the image.
This however limits to views to the operations the model defines. If the model doesn't have a rotate method, a view could never add one.

Key points of Design 2:

The WebviewCustomEditorProvider becomes the delegate. This means a single delegate object is used for all views of a given type. To support this, we pass the resource as the first argument to all delegate functions
There is no more need for CustomDocument. Instead we always use uris to identify which file we are talking about

API:
namespace window {
	export function registerWebviewCustomEditorProvider(viewType: string, provider: WebviewCustomEditorProvider, options?: WebviewPanelOptions): Disposable;
}

export interface WebviewCustomEditorProvider {
	resolveWebviewEditor(resource: Uri, webview: WebviewPanel): Thenable<void>;

	readonly editingDelegate?: CustomDocumentEditingDelegate;
}

interface CustomDocumentEditingDelegate {
	save(resource: Uri): Thenable<void>;
	saveAs(resource: Uri, targetResource: Uri): Thenable<void>;

	readonly onEdit: Event<{ resource: Uri }>;

	applyEdits(resource: Uri, edits: readonly any[]): Thenable<void>;
	undoEdits(resource: Uri, edits: readonly any[]): Thenable<void>;
}

{
    "viewType": "testWebviewEditor.abc",
    "displayName": "Test ABC editor",
    "selector": [
        {
            "filenamePattern": "*.abc"
        }
    ]
}

/cc @rebornix

@eamodio Do you have any specific uses cases in mind for allowing any extension to provide webviews for another extension's custom documents?
My feeling is that while this sounds neat, it would be really difficult for extensions to actually implement this (especially for binary data) and I can't think of any killer use cases that would justify all this. That's the main reason I'm currently in favor of the simplified design 2

I've implemented the second design in this branch. Example editors using this draft api: https://github.com/mjbvz/vscode-experimental-webview-editor-extension/tree/86802-draft
I like the overall API design and found it fairly easy to work with.
I found the biggest challenge in implementing this API is tracking the lifecycle of the document models that the extension stores. The current proposal requires extension implement reference counting so that they can destory their models when the last editor goes away. It me be worth investigating adding opened and closed methods on the delegate that would notify the extension when a model for a resource needs to be created and when the last editor for that resource goes away

@eamodio Do you have any specific uses cases in mind for allowing any extension to provide webviews for another extension's custom documents?
My feeling is that while this sounds neat, it would be really difficult for extensions to actually implement this (especially for binary data) and I can't think of any killer use cases that would justify all this. That's the main reason I'm currently in favor of the simplified design 2

you should look into Vega Viewer & Data Preview integration for a good example of 2 webviews scenario you mentioned: https://marketplace.visualstudio.com/items?itemName=RandomFractalsInc.vscode-vega-viewer

ideally, I'd like to have both extensions update their views on data file changes using your new webview editor api and document model hooks.
My simple real world use case scenario for the 2 extensions I've mentioned:

Developer creates a Vega chart vg.json spec using population.json data.
You can preview it in Vega Viewer and save it as SVG or PNG document.
You can view the data source for that chart webview in Data Preview (try it!)
Developer changes population.json data file. Both Vega Viewer and Data Preview webviews get updated.

Does your design 2 support this real world use case scenario?

@mjbvz I just really like the separation of concerns of dealing with a data model (document) and UI model (editor) separately, because it can lead to many unforeseen opportunities. The examples I can think of are:

VS Code (or maybe just an extension) provides a document for editing images, then other extensions can build upon that model and provide their own image editing UI -- from something simple which maybe comes built in, to something far more advanced.

VS Code provides TextDocuments today and if those could also be provided to an editor implementation, then you can have custom editors built for specific use-cases. Think UI over configuration (e.g. our own settings could be implemented as a custom editor for our settings.json file. I think this custom editor support for TextDocuments can enable a lot of cool experiences.

Very similar to the above, but think CSV or raw textual data that can be visualized (and manipulated)

An extension could provide a document around remote data - say backed by Azure Storage or S3 or whatever and then that document could be re-mix/re-used by other extensions to provide richer UIs

Also IMO in these examples, editors don't have to perform editing -- they could be just viewers as well -- as this provides a great hook point to register alternative viewers/editors for specific file types

I guess I will never get a follow up on my real world scenario?

@RandomFractals I know you said look at your extension’s source but I do not understand the issue you are trying to solve or what your concerns are. Please try to clearly and concisely explain these

@mjbvz Matt, I think you need to download and try both extensions. You don't have to look at my source code, as long as you can support my real-world scenario described above for the data/document charting, export and data preview flow.
Let me know if you have further questions after you try them & adjust your api to support that flow.

@RandomFractals  I’ve already taken a look and your use case seems like it would work just fine...
As I cannot read your mind, please explain in text explicitly why/how the current proposals don’t meet your needs

@mjbvz happy to hear you think you can support that charting and data view integration scenario.
I simply listed it for you to consider as you draft this api & to test it with extensions used in the field with different json data formats that are beyond silly .cat(s) demoes :)
I look forward to take it for a test drive when you think you are ready for it.
Thanks!

@eamodio Thanks for the input!
Just some of my thoughts on these points:

This gets back to the point I made while introducing the rational behind design 2: It is seems difficult to define a custom document that is generic enough to be useful for multiple view types while not so generic as to be meaningless

For an image editor for example, a simple binary model isn't going to work well since it's too low level and would not perform well. However a more complex model would have to encode the type of operations it supports: crop, scale, .... But that would mean that other extensions could only ever use these high level operations and not introduce new ones

With design 2, you can still use TextDocument behind the scenes to implement a custom editor. I agree that Design 1 is more explicit in this.

Same points as above. For model reuse with design 2, there  are a few options:

If a single extension is implementing all this, just share model code
Otherwise, have the extension expose an API similar to openTextDocument that other extensions can invoke

This is sort of independent of the two designs. Neither one specifies where the data is coming from or where save write too. A file system provider may be a better fit for sharing like you are proposing

At our standup today, @kieferrm also raised an interesting meta point: introducing a CustomDocument into the VS Code API opens up a whole lot of other questions that we do not  want to address. For example,  can a workspace edit touch a CustomDocument? Can I get a list of all documents including custom documents? Do events like TextDocumentWillSave happen for custom documents? Why not?
It gets complicated

I've merged a version of 2 to proposed with the understanding that we will continue discussing it this week. Design 2 takes us in a good general direction, and the concept of CustomDocuments could be added on top if we wanted. My current feeling though is that we should keep it simpler and not introduce CustomDocument

well, I think you should do that and at least describe in text how you see this new webview editor api to sync data sources from disk, local & in remote use cases, such as vscode online & for the webview editors depending on those data/document updates to update their views.
Also, I still have not seen the proposed UX for your edits stack ...

@RandomFractals You seem to have a different understanding of what the custom editor api is trying to accomplish. Custom editors are not about how data is synchronized, nor how data is saved to disk, nor how the views are updated: that's all intentionally left up to extensions.
The goal of the custom editors api is to provide a minimal set of hooks that allow extensions to implement webview based previews/editors that can integrate with VS Code's basic operations (such as undo and save). We also aim to keep this at least somewhat consistent with rest of VS Code (such as supporting autosave). Beyond that, it's up to you

@mjbvz I am starting to get it now. So, those undo/save actions in custom webview editor would just work with normal undo/save keyboard shortcuts when that webview panel is active? What I meant by UX for the edits stack.

also, this is maybe off topic again, but what if v3 of this api provided some standard api for custom webview editor toolbar UI?
Most preview and custom webview editors I've seen have a top or bottom panel toolbar for preview actions, such as zoom, add line in REPL, etc.
What if part of this or separate efforts, vscode provided an API for the such custom webview editors to define and wire toolbar UI and actions.
I think such effort could lead to even more standard webviews across the board and would make it easier for devs to get those custom extensions working with standard vscode-icons, themes and theme colors.
@mjbvz & @eamodio your thoughts on that idea?
And thanks for your hard work on fleshing out this api, sample repo and the rest.
I do appreciate you doing it in the open for the 3rd party devs to have a peak while you draft and design this new api standard.

@RandomFractals We do not have any plans to standardize UI inside of custom editors. That could be covered by a separate proposal delivered independently of the core custom editor experience

@mjbvz so basically this new webivew editor api is just an edits stack. sounds like there is not much more to it for ext. devs to bit into or use in terms of reading/saving docs or wiring custom doc and toolbars.
Would this still work at least? & thanks for your update!

@mjbvz I am starting to get it now. So, those undo/save actions in custom webview editor would just work with normal undo/save keyboard shortcuts when that webview panel is active? What I meant by UX for the edits stack.

The api provides hooks into VS Code's save + undo/redo flows. So if you press cmd+z with a custom editor open, the extension's undoEdits is invoked. The general UX for undo/redo is the same as in a text editor (although obviously the effects depend on the custom editor implementation)

We are moving forward with the second design based on our discussions and the reasons outlined above. This has been merged into vscode.proposed.d.ts and the example extensions have been updated
Will post this update back to #77131


MultiTenant - couple of fixes to make the filter operational with a sarama based client

(I cherry-picked this PR out from #481 as it deserves to stand on its own).
Type of change
Select the type of your PR

Bugfix

Description
Allows MultiTenant filter to be used with kaf (sarama based tool) for simple publish/consume and topic/group management. It uses the Sarama client (v1.38.1) which uses some older Kafka RPCs.

OffsetFetch v2
FindCoordinator v1
DeleteTopics v1

Why: I've been experimenting with kaf as a tool to use in demos.
Additional Context
Why are you making this pull request?
Checklist
Please go through this checklist and make sure all applicable tasks have been done

[x] Write tests
[x] Make sure all tests pass
[ ] Review performance test results. Ensure that any degradations to performance numbers are understood and justified.
[ ] Make sure all Sonar-Lint warnings are addressed or are justifiably ignored.
[ ] Update documentation
[x] Reference relevant issue(s) and close them after merging
[x] For user facing changes, update CHANGELOG.md (remember to include changes affecting the API of the test artefacts too).

I wonder if there is something we can do to automate the testing of filters with multiple API versions (and is that even generally desirable?)

Mmm, I wonder if we can't extend the unit test to do just that.
At the moment, we have test scenarios that baked in to JSON which are assigned to a particular version.  How about we change the test harness to iterate the running of the same test against earlier versions too etc.  The test harness would stop execution when it hits version 1, or found an actual test definition written for that version.
For example:
Let's say there is a RPC called Whisper at v5.
We have a test def for v5, so the test harness would try to run that same test for v1...5.  Now suppose there had been a schema change as v3 (groupId -> groups[]), the test would fail at v1 and v2.  That would force us to write a v2 of the test.  The harness would run the v5 test against v3..v5 and the v2 test against v1 and v2.
I think that would automatically highlight breaking changes in fields we care about, forcing us to close gaps.

The questions about guard conditions vs comments are no reason to hold the merge.


Add translations and update MQTT config flow for Playnite Web MQTT

Summary by Sourcery
Add multilingual support for Playnite Web MQTT configuration with translations in English, Serbian Latin, and Serbian Cyrillic. Enhance the MQTT configuration flow by sourcing default values from the config entry data instead of options.
New Features:

Add translations for the Playnite Web MQTT configuration in English, Serbian Latin, and Serbian Cyrillic.

Enhancements:

Update the MQTT configuration flow to use data from the config entry instead of options for default values.

@sourcery-ai review


Data collection

Great project! I was checking what data is collected per request and the RequestLog currently holds the remote_ip as well. Storing IPs is not forbidden under GDPR but requires a reason and mentioning it in the privacy policies of a site.
I think this can all be side stepped if no personal data like an IP address was stored. Simple Analytics does this really well and they even outline how unique visit tracking works in a privacy preserving way.
For most adding statements to the privacy statement is probably fine, but if the request tracking worked like Simple Analytics it would be a GDPR compliant plug and play solution that doesn't require additional pop-ups or statements and just works.
Would this be something you'd consider or accept a draft PR for?

Hi @patrickdet , thank you for raising this issue. I was counting days since launch when this topic would be brought 😄
Since we are not really interested in storing IP addresses, as I had initial idea to show the world map but then I dropped it as maintaining up to date library with IP <-> Location is quite a challenge or you need to use paid services for that, we can easily one way hash IP address and store only hash for purpose of saving some unique identifiers.
As Simple Analytics treats every non-referer as unique visit which is imo not very accurate.
I can solve it without breaking changes in next release.
  defp hash_ip(ip), do: :crypto.hash(:md5, ip) |> Base.encode16(case: :lower)

  defp format_ip({a, b, c, d}), do: "#{a}.#{b}.#{c}.#{d}" |> hash_ip
  defp format_ip(ip), do: to_string(ip) |> hash_ip

Let me know what do you think on that solution.


Fix issue where probe fw version details weren't being emitted

Closing due to being included in another PR--see Matt's comment.


NixOS-20.09 AMI ignores user-data

minor edits after original submission to improve readability.
Describe the bug
I'm trying to spin up a new instance on AWS (us-east-1) using the AWS Community AMI nixos-20.09pre-git-6-x86_64-hvm-ebs (ami-02700dd542e3304cd). I set the user-data for the new instance to my desired NixOS configuration, expecting to see the configuration be reproduced at /etc/nixos/configuration.nix and have the instance boot into the desired configuration.
However, when I log into the instance, /etc/nixos/configuration.nix does not exist. Consequently, the desired configuration is not applied.
To Reproduce
Steps to reproduce the behavior:

Create a new instance on AWS using nixos-20.09pre-git-6-x86_64-hvm-ebs (ami-02700dd542e3304cd).
Add the desired configuration to the instance's user-data section.
Boot the instance.

Expected behavior

The file /etc/nixos/configuration.nix should be created and must contain the configuration passed to user-data.
The nixos configuration should have been applied.

Screenshots
Looking over the logs in journald, I can see the following:
...
...
Feb 08 01:25:18 ip-172-31-19-35.ec2.internal systemd[1]: Starting Reconfigure the system from EC2 userdata shell script on startup...
Feb 08 01:25:18 ip-172-31-19-35.ec2.internal amazon-shell-init-start[1344]: script not recognized, ignoring
Feb 08 01:25:18 ip-172-31-19-35.ec2.internal systemd[1]: Finished Reconfigure the system from EC2 userdata shell script on startup.
Feb 08 01:25:18 ip-172-31-19-35.ec2.internal systemd[1]: Startup finished in 26.884s (kernel) + 10.969s (userspace) = 37.853s.
...
...

Additional context
I searched for the string "Reconfigure the system from EC2 userdata shell script on startup", but it does not seem to exist in this repository. The closest I could find was the systemd service being created in amazon-init.nix.
Looking over that file, it doesn't seem like the AMI was created from the same source. Is this expected?
Attached below are logs from the instance I spun up.
[root@hostname:~]# systemctl cat amazon-shell-init.service
# /nix/store/aj1kyhchryvk34pv9kzcpv26npmq5133-unit-amazon-shell-init.service/amazon-shell-init.service
[Unit]
After=multi-user.target
Description=Reconfigure the system from EC2 userdata shell script on startup
Requires=network-online.target
X-StopOnRemoval=false

[Service]
Environment="LOCALE_ARCHIVE=/nix/store/4p9w65np73bynmmq98nn2z1an0py0jvn-glibc-locales-2.31/lib/locale/locale-archive"
Environment="PATH=/nix/store/d9nbq7v3sll90li95wkp49b87igni1zi-sops-3.6.0/bin:/nix/store/ajpsqn2gkx5mnc9xfdjd6k0zb2z5mjch-awscli-1.18.93/bin:/nix/store/4g4f5xy720443g4zbsk1j9g51wnlr6z4-nix-2.4pre20200719_a79b6dd/bin:/nix/store/g0j3pan49fp>
Environment="TZDIR=/nix/store/1h9jyn0fllqvgpa0xwck25awdvmbclss-tzdata-2019c/share/zoneinfo"

X-RestartIfChanged=false

ExecStart=/nix/store/m4r6h3ip7h3kykrcq629k4218ggar1n5-unit-script-amazon-shell-init-start/bin/amazon-shell-init-start
RemainAfterExit=true
Type=oneshot

[root@hostname:~]# cat /nix/store/m4r6h3ip7h3kykrcq629k4218ggar1n5-unit-script-amazon-shell-init-start/bin/amazon-shell-init-start
#!/nix/store/c4wxsn4jays9j31y5z9f83nr2cp7l4pa-bash-4.4-p23/bin/bash -e
#!/nix/store/c4wxsn4jays9j31y5z9f83nr2cp7l4pa-bash-4.4-p23/bin/bash -eu

userData=/etc/ec2-metadata/user-data
if grep '# amazon-shell-init' $userData; then
  source $userData
else
  echo script not recognized, ignoring
fi

That AMI doesn't seem to be one of the official NixOS AMIs. The AMIs are listed in nixos/modules/virtualisation/ec2-amis.nix, which lists ami-0a2cce52b42daccc8 (owned by<PHONE_NUMBER>61).
For comparison, the mentioned AMI is owned by<PHONE_NUMBER>96.

This is actually one of the images we generated for use with https://github.com/input-output-hk/bitte and the source for the service you found is at https://github.com/input-output-hk/ops-lib/blob/zfs-image/zfs/amazon-shell-init.nix
As you found, it simply sources the user_data and expects it to be a shell script.
An example of its use is at https://github.com/input-output-hk/bitte/blob/master/modules/terraform.nix#L669-L682 where it helps get autoscaling instances to rebuild themselves faster using nix flakes and a matching binary cache.
So yes, it's definitely not one of the official NixOS AMIs, but I can see how the name might be confusing.

The official ami's can be found at https://nixos.org/download.html#nixos-amazon

Thanks for the updates guys. Much appreciated. I'll close this out now.

As you found, it simply sources the user_data and expects it to be a shell script.

Incidentally, would https://github.com/NixOS/nixpkgs/pull/67345 mean this use case wouldn't require a custom AMI?


kubeadm: update upgrade documentation for 1.18

update the kubeadm upgrade doc to include 1.18 details and output.
/kind cleanup
/priority important-soon
@kubernetes/sig-cluster-lifecycle-pr-reviews

/milestone 1.18
@VineethReddy02 FYI

@sftim
added min-kubernetes-server-version: 1.18

These changes look good to me.

feel free to merge this one without tech LGTM, as it has no authored content changes.

/lgtm
@VineethReddy02 ready for your approval I reckon

/lgtm

Page preview:
https://deploy-preview-19551--kubernetes-io-vnext-staging.netlify.com/docs/tasks/administer-cluster/kubeadm/kubeadm-upgrade/

/lgtm

@VineethReddy02 I expect you'll want to mark this as /milestone 1.18

/milestone 1.18

had to rebase the PR, the conflict was around:
weight: 20
min-kubernetes-server-version: 1.18

here is an example of how i do this, when a PR conflicts with a k/website dev* branch:
# 'github' is the remote and '1.18-kubeadm-upgrade' is the remote branch
$ git checkout 1.18-kubeadm-upgrade
# create a patch between current PR branch and dev-1.18
# results in '0001-kubeadm-update-upgrade-documentation-for-1.18.patch'
$ git format-patch dev-1.18
$ git checkout master
# delete old branches
# at this point dev-1.18 was rebased remoteley and just pulling it locally
# would cause conflicts.
$ git branch -D dev-1.18
$ git branch -D 1.18-kubeadm-upgrade
# fetch a new dev-1.18
$ git fetch origin dev-1.18:dev-1.18
$ git checkout dev-1.18
$ git checkout -b 1.18-kubeadm-upgrade
# apply the patch
$ git am -3 0001-kubeadm-update-upgrade-documentation-for-1.18.patch
# would fail, fix conflicts here
$ git add -u
$ git am --continue
# force push the local branch to the remote
$ git push -f github 1.18-kubeadm-upgrade

i'm sure there are shortcuts to this, but the way k/website dev-* branches are managed currently can result in difficulties rebasing locally.

@neolit123 , I guess the rebase went okay -- seems overly complicated.
The output renders -- I compared against the currently published version.
/lgtm

@sftim Is this PR okay to get merged?

@VineethReddy02 I've only skimmed. Happy to let @kbhawkey's LGTM stand!
Feel free to approve.

/lgtm
/approve


ReferenceError: message is not defined

Generated client
Version: preview022, preview023
Reference error in catch body when the request throws an error does not have a callsite, and !e.isPanic. The message is not defined, which I assume should be e.message
      if (callsite) {
        const { stack } = printStack({
          callsite,
          originalMethod: clientMethod,
          onUs: e.isPanic
        });
        const message = stack + e.message;
        if (e.code) {
          throw new PrismaClientKnownRequestError(this.sanitizeMessage(message), e.code, e.meta);
        }
        if (e instanceof PrismaClientUnknownRequestError) {
          throw new PrismaClientUnknownRequestError(this.sanitizeMessage(message));
        } else if (e instanceof PrismaClientInitializationError) {
          throw new PrismaClientInitializationError(this.sanitizeMessage(message));
        } else if (e instanceof PrismaClientRustPanicError) {
          throw new PrismaClientRustPanicError(this.sanitizeMessage(message));
        }
      } else {
        if (e.code) {
          throw new PrismaClientKnownRequestError(this.sanitizeMessage(e.message), e.code, e.meta);
        }
        if (e.isPanic) {
          throw new PrismaClientRustPanicError(e.message);
        } else {
          if (e instanceof PrismaClientUnknownRequestError) {
            // HERE
            throw new PrismaClientUnknownRequestError(this.sanitizeMessage(message));
          } else if (e instanceof PrismaClientInitializationError) {
            // HERE
            throw new PrismaClientInitializationError(this.sanitizeMessage(message));
          } else if (e instanceof PrismaClientRustPanicError) {
            // HERE
            throw new PrismaClientRustPanicError(this.sanitizeMessage(message));
          }
        }
      }

@pantharshit00 not much to repro
you can init prisma by starter example (or any other running project with preview022, preview023). Generate client and go to<EMAIL_ADDRESS>to lines 104, 106, 108 and see that variable message is not defined, and should be e.message

Thanks a lot for reporting 🙏
This issue is fixed in the latest alpha version of prisma2.
You can try it out with npm i -g prisma2@alpha.
In case it’s not fixed for you - please let us know and we’ll reopen this issue!


Recommendations for links and IDs

In last API guild meetup we decided to update guidelines on links usage in payload and ids:

all links should be present in _links field which can also be used multiple times in one payload
favor simple IDs if in same namespace/system otherwise think about using URNs e.g. urn:warehouse:FG-AS-123-FD

I think we should not pretend to use the urn URI scheme without actually registering a URN namespace.

I think we should not pretend to use the urn URI scheme

zrn it is then ;)

It's more about a meaningful example which we should provide in our guidelines if we emphasize usage of URNs.


[DC-94] Updating preview table styles so they have more table definition

Before

After

my only other q right now: is there a reason to have the height of the buttons unset so that they're so tall? just feels a bit weird to me compared to all our other ones.

my only other q right now: is there a reason to have the height of the buttons unset so that they're so tall? just feels a bit weird to me compared to all our other ones.

That would be the result of copy pasting! I'll remove it, it looks better without it


Fancyzones restores minimized windows when applying new zone layout

Environment
Windows build number: 10.0.18363.900
PowerToys version: 0.19.0
PowerToy module for which you are reporting the bug (if applicable): FancyZones

Steps to reproduce
Apply a FancyZone layout.
Put window into a zone. (I used shift-drag to put Outlook into zone 1)
Minimize the app you put into a zone.
Open FancyZone layout selector (WIN+`) and select a different zone layout.
The minimized application will be restored from its minimized state.
Expected behavior
Minimized applications will stay minimized when applying a new zone layout. Windows that are "zoned" and not minimized will adjust to the new layout.
Actual behavior
Minimized windows that were previously "zoned" are being restored to the new zone layout instead of staying minimized.

Hi @Blueric
thank you for reporting the bug.

Fix added in 0.21.1, please go to https://github.com/microsoft/PowerToys/releases to upgrade


Fix Layout menu not working

Fixes #44734

Thanks! I checked other renamed methods from #44605 and it now seems OK after this fix.


Make the throughput gauge in the indexing cli smarter

Right now the throughput displayed is the overall average throughput since the start of the program.
We would like an average over a short window in order to be able to observe the possible fluctuation.

(a fun small ticket to rest from the release :) )

@fulmicoton So choosing let's say a window of 5s.

I guess the first 5s can be calculated just like we currently do since from 0s to 5s we cannot say it's zero.
There is also this enhancement that's needed at the end, when all the docs are processed and the last split is being uploaded, the number of byte processed no longer increases causing the throughput to start dropping. we can maintain this but I propose we stop calculating and just use the calculated value from that point.


BK7231N (a)synchronous PWM

I've recently got my hands on some BK7231N fairy lights (see https://github.com/tuya-cloudcutter/tuya-cloudcutter/issues/573) (didn't work with cloudcutter first, got a working profile mere minutes after uploading the dump).
Now I have a bit of an issue with making it work properly with ESPHome.
The fairy lights only have two wires, which each attach to one half-bridge on the PCB (one is attached to P7, one is attached to P8).
The two LED-colors are wired parallel to each other, but with reversed polarity. So in one polarity, color 1 is active and in the other polarity, color 2 is active.
To get both colors to light simultaneously, both pins have to be at (up to) 50% PWM, however, the two pins also need to be synchronized in a way that (at up to 50% PWM) the two PWM pulses do not overlap with each other (due to weird design choices, enabling both outputs at the same time shorts out the (luckily very low-power) power supply 🔥).
In other microcontrollers, this can be acheived by sharing a timer between the channels and inverting one of the channels, but from my understanding, on this chip, the different PWM pins are pretty much all their own thing (and turning them off and on in ESPHome makes them have different offsets to each other), so I don't really have an idea how this can be acheived or how it is acheived in the original firmware (especially as I don't know if the PWM outputs can even be inverted).
Is there a way to output this kind of PWM waveform with libretiny (ideally with ESPHome)?
Reverse engineered schematic:
As you can see here, the L1 high-side is directly enabled by L2 low-side and vice-versa, which causes a short circuit if both are enabled,

The waveforms should look something like this:
50% duty cycle

10% duty cycle

Not sure what you've tried, so my first suggestion would be to invert the pin on one input and set the max_power on both to 50%
Also just a note, the UPK had pwmhz set to 250, so you should probably also set frequency: 250Hz

Sorry, I could've been more clearer.
So far, in ESPHome, I've added two lights with PWM outputs for the corresponding pins with max_power set to 0.5.
However, when turning on and off the lights (likely because setting the duty cycle to 0 causes the PWM output to be stopped/paused entirely), the PWM pulses start at different times (verified with an oscilloscope).
For example, when I put both outputs to 10%, sometimes (after turning one off and on again) the two pulses overlap, sometimes they don't (likely because the channel that was paused starts at a random point of the other channel's PWM pulse when it is reinitialized)

There were some very recent PWM changes.  I don't think they apply here, but it may be best to try anyway.  You can check them out by using current git as LibreTiny source:
bk72xx:
  framework:
    version: 0.0.0
    source: https://github.com/libretiny-eu/libretiny.git

Beyond that, you'd probably need a custom driver to properly orchestrate timing with some sort of interlock, I don't think there is anything in stock ESPHome that does that.
You could try Slow PWM which does have controllable period.  Not sure how performant it will be at 250hz, it's made for even slower than that.

So, after some direct communication via Discord and some messing around the state is the following:

libretiny currently has no (supported) way to generate synchronous PWM
There is a hbridge light component for this kind of light in ESPHome, however, it does the polarity switching in the main loop, which means 30Hz only and glitches when using WiFi
libretiny currently has no timer / timer interrupt support, so polarity switching can't be easily done in an interrupt either
the original firmware likely just configures the PWM peripheral(s) in a way that the two channels are 180° out of phase to get the desired effect

Further development (probably getting the PWM peripherals configured properly) will likely occur in https://github.com/patagonaa/tuya-ir-string-lights


Flathub release

Flathub is one of the easiest ways for a Linux systems to get apps - working across basically every major distro (with easy updates)
It would be nice to see Beaver Notes on flathub :)

Thanks for your feedback, as mentioned in discussion #8 I'll work on flatpak support as soon as I can.

Flatpak is a great way to make updates available to the users. I check for updates to my flatpak applications at least daily.
Now if your AppImage has enabled automatic updates that would be good to know. That's how I've installed Beaver Notes.

Thanks for your feedback, as mentioned in discussion #8 I'll work on flatpak support as soon as I can.

Ah, sorry - I forgot to search discussion for flatpak. I am glad it is on your radar :)


M3-575 Clone From Existing Placeholder

Purpose
If a user has no Linodes and navigates to the Create from Existing tab on the Linode create flow, display a placeholder message instead of the form

Coverage increased (+0.04%) to 28.877% when pulling 71d0e65d6147ee15bbe242aeb6519f6f996c263b on martinmckenna:M3-575-clone-placeholder into 800a6381c5e77146b992ec72c409ea8f1a12dc5e on linode:develop.


[YBUG.IO] Not working on Android and even...

Not working on Android and even bugs my phone entirely
Source url: https://live.sovryn.app/
Reported by<EMAIL_ADDRESS>Reported at: 30 Apr at 03:50 UTC
Location: IN, Goa, Ponda
Browser: Chrome 90.0.4430.66
OS: Android 8.1.0
Screen: 360x760
Viewport: 360x690
Screenshot:

For more details please visit report page on Ybug:
https://ybug.io/dashboard/reports/detail/3cp38tjgrjcxyp1casss

Issue should be resolved now


Upgrade to latest version of Netlify

Thanks a lot for creating this Build plugin!
Netlify just released the latest version of Build plugins. Build plugins are currently enabled in the Netlify website for a small percentage of beta users.
This PR upgrades this plugin to the latest API. You can find the new documentation here.
Changes include:

add a manifest.yml.
the name property in the plugin has moved to manifest.yml
pluginConfig has been renamed to inputs
default values for inputs should be specified in the manifest.yml
errors must be reported with utils.build.failPlugin()
the event handler's promise must await all async operations to complete
add a bugs property in package.json so that it is shown to users when a bug arises

I have also tried to increase performance by running everything in parallel:

getPages() and getPosts() are now run in parallel.
creating images, pages and posts are now run in parallel. Please fix if this leads to incorrect behavior.

I have done some quick tests, but you might want to manually test this PR as well just to make sure :)
Also I made up the inputs[*].description in manifest.yml: they might not be completely accurate.

Hey @ehmicky! Thanks a lot for taking the time to update my plugin to work with the latest version of the beta Build Plugins feature. Can I ask if there will be more changes in future? I ask this because I've already had changes not too long ago, plus I have this article which shows other people how to create their own plugin which I'll need to update too:
https://david.darn.es/article/2020/03/02/building-a-netlify-build-plugin/
Just wanting to know if there will be more changes like this and if I should wait until it's become slightly more stable?

Hi @daviddarnes,
We are still in beta so there will definitely be more changes. However we expect that the biggest changes are behind us now and only minor ones should be coming. I will make sure to keep you updated on those.
The changes introduced in this PR are currently optional, but we want to make them required soon. For example, we would like to enforce every plugin having a manifest.yml since it helps us surface those plugins the best way to all Netlify users. The plan is to roll those out with the following steps:

Send PR (like this PR) to existing plugins to help plugin authors upgrade
Print deprecation warnings
Eventually, enforce those breaking changes

Hi again @ehmicky,
I'm just spending a bit of my weekend trying to fully wrap my head around all the changes you've made to my plugin. The new manifest file, the new way default values are set and the fail callback I get, but what about all the other changes?
Is there a way we could make these changes more incrementally? I don't doubt your code quality, it's just that the changes seem more drastic than they needed to be?

@daviddarnes Do you have specific changes in mind you could point out?
Feel free to remove anything that you think might be extraneous. :+1:

@ehmicky it was mainly the try / catch stuff as I'm not familiar with that syntax as much. However if this is working as well as you say I may as well merge it now and get it into testing. Build Plugins is still in beta so I should just throw it in and see what happens 😄

Also please note I am actively looking at any build that is failing due to Build plugins in production, and I am trying to report those issues back to you :)


Restore summary

I expect to see a summary at the end of restore, with all apps not installed.
It could be a change back to install list, if detected, that some apps are not installed.

It should than filter the install list for not installed/detected apps


[inter-mod Issue] Crash with ValkyrienSkies on server side when you drink water

Short Description
I made a new world loaded some chunks (/forge gen ~ ~ ~ 1000) and then drinked some water, but after drinking water i got disconnected from the server without crash report (i'm playing singleplayer), i looked at Latest.log and found this: https://pastebin.com/aWXtWm9f
To Reproduce
Steps to reproduce the behavior:

Add ValkyrienSkies and Survival Inc.
gen some chunks with /forge gen ~ ~ ~ 1000
Drink water from any water body
See error

Crash Report
Well, since it doesn't gens a crash report, here is my Latest.log, look at the bottom, also it is different from the log i uploaded above:
latest.log
Additional Notes
1.- its completly new, i have no idea why it never happened before, nor why it happens now, but at least i can confirm that it is easy to reproduce (after loading some chunks) and it will always happen again once you repeat it (in the same world)
2.- also, sadly ValkyrienSkies for 1.12, in words of its author, will not receive another update because the author (Triode) broke his Dev Environment, i have not tried to load that repo, but if this issue is completly from their side, just tell me what i need to change and fix it inside a personal modified jar

Okay so I looked a bit into it and it seems that ValkyrienSkies is placing strong policy on when the raytracing function may be called. It throws an exception every time it's called on anything but the client side, and thus it crashes server side since Survival Inc uses raytracing to verify if the client didn't send a forged request. I added a config option to disable the server raytracing, but it will leave the server unprotected against hacked clients sending forged requests (which basically allows anyone to replenish their hydration indefinitely). Unfortunately, there is no other way around this, so I think the compromise is a necessary evil. (I will commit the changes soon).

well, its a shame that ValkyrienSkies does that, but i think that the probabilities of that someone design a hacked client just for this is pretty small, thanks again.

mmm, well, i would like to add that i can't build the Dev Environment, i get an issue related to the Line 17 inside build.gradle (the plugin palantir)
https://github.com/Enginecrafter77/SurvivalInc/blob/68eb52913234db0d630b1446b936e55e51cbf61d/build.gradle#L17

Hmm that's weird I use that plugin in almost all of my projects. Can you maybe post the gradle log? (The output of gradlew)? Anyways I will try to make a separate environment from scratch to see if I can reproduce the issue. And just as a side note, maybe it would be good if you opened a separate issue about this.

ok, i made it


Ionic serve in prod mode

Can we have something like this added to the cli?
ionic serve --prod
This would be a huge help for testing the app when you have different codes for prod and dev. One example can be having different environment variables set up.
Right now the only way to run the app in prod mode is to run it on a device which is very time consuming at least.

Agreed. I am new to Ionic and assumed this functionality existed, but no.

It's not possible right now:
https://github.com/driftyco/ionic-app-scripts/issues/709

Is there any other alternative to get an optimized build for production deployment of web-app?

After reading this:
https://github.com/driftyco/ionic-app-scripts/issues/709#issuecomment-277454896
I'm closing this for now.


Implement stir control

We have a custom stir control assembly and now that the housing will start to be worked on, it's about time to finally implement stir control into the program.
The stir control is handled by a BD65496MUV DC Motor Controller breakout board from Pololu. The Raspberry Pi's GPIO13 or board.D13 pin is hooked to the PWM input of the board, and GPIO11 or board.D13 is connected to the Motor Direction pin. There was no specific use-case for the Motor Direction pin, but we had free GPIO pins so we figured why not. Could possibly be used for a sort of breaking feature when we stop.
To Do:

Make a class for the stir control, i.e. stir_control
Implement basic methods of start, set_speed_slow, set_speed_fast, set_speed (perhaps a custom speed with a PWM value), stop, etc.
Create a mock version. This would mainly be for a partially mocked titration device where we just want to test things without having the actual stir motor go crazy.
Create test routines

This has been started on my dev_titrator_testing branch now that I have my hands on the device at Rosario

This has been fixed with #89


Update tutorial 4

I have update the point 2.1 but script is now exploding the karnel. Other way is to use dask array. any suggestions?

does it help to do the cut out of the region of interest before the masking?

Constrained the time and extract region. making cube small works.


How to set a tag in shapes or markers

https://developers.google.com/android/reference/com/google/android/gms/maps/model/Polyline#public-void-settag-object-tag
I'm trying to include a tag into a Marker or Polyline but how can I reach the setTag method? My plan is to identify the item when the user interact with it (or a group of them) using some type of id's.
I'm already tried to use polyline.android.setTag('test') and polyline.setTag('') and also polyline._android.setTag('')
Any ideas?

you could just store an id on the nativescript object. ie polyline._id = 'someValue' or something similar, instead of trying to use the native android method setTag - which would not be the same for IOS


Every select in prismaField inside prismaObject raises type error

After upgrading to<EMAIL_ADDRESS>from 3.63.1, every select in prismaField inside prismaObject raises type error.
Type signature of select insists that it expects the type (args, ctx, nestedSelection) => never.

have you re-run prisma generate?

Haven't heard back, so I am assuming that resolved your issue, but let me know if your still running into any problems after regenerating the types


Method calling issue

Hi,
Calling contract method in Tronweb. But it shows 'Error The call has been reverted or has thrown an error.'
How to overcome this?

same issue #182


feat: proxy ip

reference to: https://github.com/zizifn/edgetunnel/issues/162
we need a proxy for websites that cannot be accessed, and this pr solved the problem.
just add a new entry PROXY_IP in wrangler.toml and set the default domain to:
https://github.com/zizifn/edgetunnel/issues/302

A new PR regarding PROXY_IP has been merged, so let's close this PR for now.


all input types & enums are generated when specifying -c --skip-schema

I think the input should also be omitted when specifying the skip schema parameter ? :)
input MyQueryInput {
   ...
}

At the moment, enums and input types are generated anyway, because documents are using them and not just the schema.
@polco , do you have a use can where we need to omit input types?

I realize my issue's name is not correct. So my current project is using the typescript template generator. I separated the queries and mutations in different folders, so i get a different type files generated for each. In both files, all the schema input types are present, no only the one needed by the mutations or by the queries.
So i guess the only thing is that i get unused types generated in both files.

I am with @polco on this. It's not like a big issue, but I am working on the project and there is like 50+ input types and other 20+ enums floating around that are not referenced in any of other types. There are two small-ish issues about that.

autocomplete in VSCode and I am getting a bunch of types that are useless
looking up something manually in the generated files means getting through the unrelated mess

I am wondering how hard it could be to emit only types that are actually used.

@FredyC We can't predict the usage of the generated type, but we can minimize the amount of generated output. Any chance you can provide an example for it? @FredyC

I see what might be a confusion point. The main idea is to consider a whole schema, not queries only.
Consider types of fields in the schema that are probably referencing enum types. Also, mutations would be usually referencing input types. Based on this sort of validation, it should be possible to safely mark types, that are unnecessary to keep in the generated files.
It should be probably opt-in behavior, but honestly, I don't recall a single moment when I would need to use a type of enum or input type without having them somewhere in the schema.
Does this make any sense? :)

Closing for now. We are going to keep the behaviour as-is, because of the need to input types and enums on client side as well.

@dotansimha I don't understand why unused input types are needed on client side, especially for the clients which do not use them?

Imagine you are having a mutation in you schema:
mutation add(args: TodoInput): [ToDo]

This allows you to call the mutation with an optional input to add a new todo to your list of todos. So how should the generator know, if it has to generate the TodoInput type or not? It must look into your client code to know this.
What I can imagine, would be a different approach here: Maybe someone can argue for a config flag allowing you to only generate types, used in calls like this:
mutation AddTodoMutation($input: TodoInput) {
  add(args: $input) {
    # some selection
  }
}

so only if an input type is used in a named query + defined variables, it should be generated into interfaces, but this then of course also means, if someone is then only using the mutation without naming + variable definition, someone will not have type for that, but hopefully that someone is then aware of the config flag.
Sorry for bumping this quiet old topic, but I kind of like the approach of looking only at the named queries. At least on our end we are naming all of our queries on all of our projects. So I would strongly like the possibility to have a config flag as described.


Closes #16: Show queue position of participants per study

I made a first attempt to solve #16, by showing the currently displayed study's position in the participant's queue. A small todo is that a value is not yet updated if a participant's priority value is changed, but that should be easy to add if you like this approach.

A small todo is that a value is not yet updated if a participant's priority value is changed, but that should be easy to add if you like this approach.

This has been added now too. Ready for review!

A small todo is that a value is not yet updated if a participant's priority value is changed, but that should be easy to add if you like this approach.

This has been added now too. Ready for review!

The suite indicates that everything passed, but I do see error messages. I attached the log.
test.log
In addition, I cannot log in anymore, getting the following error message:
HttpException: EBADCSRFTOKEN: Invalid CSRF token
    at Shield.verifyToken (/home/sebastiaan/git/omm-server/node_modules/@adonisjs/shield/src/Shield/index.js:268:13)
    at Shield.handle (/home/sebastiaan/git/omm-server/node_modules/@adonisjs/shield/src/Shield/index.js:393:12)
    at async SessionMiddleware.handle (/home/sebastiaan/git/omm-server/node_modules/@adonisjs/session/src/Session/Middleware.js:76:5)
    at async BodyParser.handle (/home/sebastiaan/git/omm-server/node_modules/@adonisjs/bodyparser/src/BodyParser/index.js:284:7)

It seems odd that this log-in error would result from this update (?). But I'm building it clean (i.e. removing node_modules, doing a fresh seed of the database, using the same version of node and npm as before).

The suite indicates that everything passed, but I do see error messages. I attached the log.
test.log
In addition, I cannot log in anymore, getting the following error message:
HttpException: EBADCSRFTOKEN: Invalid CSRF token
    at Shield.verifyToken (/home/sebastiaan/git/omm-server/node_modules/@adonisjs/shield/src/Shield/index.js:268:13)
    at Shield.handle (/home/sebastiaan/git/omm-server/node_modules/@adonisjs/shield/src/Shield/index.js:393:12)
    at async SessionMiddleware.handle (/home/sebastiaan/git/omm-server/node_modules/@adonisjs/session/src/Session/Middleware.js:76:5)
    at async BodyParser.handle (/home/sebastiaan/git/omm-server/node_modules/@adonisjs/bodyparser/src/BodyParser/index.js:284:7)

It seems odd that this log-in error would result from this update (?). But I'm building it clean (i.e. removing node_modules, doing a fresh seed of the database, using the same version of node and npm as before).

In addition, I cannot log in anymore, getting the following error message:

See my message on slack ;)

FYI, I had to make some slight changes to get everything working on omm.cogsci.nl. One change is a requirement for an APP_URL environment variable in the .env file. You can see a sample value in .env.example, which is fine to use on the dev server (API_URL=$BASE_URL/api/v1). If you don't add this variable to your env file, you get an Invalid CSRF token error (edited)

In addition, I cannot log in anymore, getting the following error message:

See my message on slack ;)

FYI, I had to make some slight changes to get everything working on omm.cogsci.nl. One change is a requirement for an APP_URL environment variable in the .env file. You can see a sample value in .env.example, which is fine to use on the dev server (API_URL=$BASE_URL/api/v1). If you don't add this variable to your env file, you get an Invalid CSRF token error (edited)


Petclinic cloudfoundry link is broken.

A very minor thing i noticed...
The link to the app in Cloudfoundry on the home petclinic wiki page doesn't work.
 http://spring-petclinic.cloudfoundry.com/
It is giving me 404 not found.
If it's not hosted on there anymore, perhaps update that bit on that wiki page.?

I have see the same issue, it works on the STS Spring Tool TC server on a localhost, but deployed to cloud foundry I can not get to the URL.  I even went to apps manager and tried to map it to a new url which did not work.

Hi @colinbut ,
Create a route and hostname for spring-petclinic app in your apps manager console.
For route, check it your console and give hostname as spring-petclinic. It will work!!!!

I deleted the wiki (it duplicated the README anyway).

Create a route and hostname for spring-petclinic app in your apps manager console.

Can someone give me a little more detail?  Thx

https://docs.cloudfoundry.org/devguide/deploy-apps/routes-domains.html


Bring up-to-parity with Fris' Light Version

Resolves #49
Resolves #51

PS: Also resolves #34
It doesn't do it in the way discussed in #34 (it may potentially restore incompatible-after-the-update mods), but this was the implementation @Fris0uman came up with. Keeping parity with his Light-version fork, within the realms of compatibility, is one of the tenets of this repo. Also, it solves the fundamental point that was aggravating some users, so I cannot argue with the results.

The code I brough back in my PR #19 was never removed from this fork so I don't see how it could help here. Either there is a deeper issue or #34 is an invalid issue for this version of the launcher

@Fris0uman You are right. After comparing that particular cherry-picked commit with the current build, I see that no changes are effectively applied in the mod-handling part. I am by no means a Python virtuoso, but looking at the code I see that it should be restoring the mods in the "previous" folder; tho #34 claims that isn't happening.
I don't play with mods myself, so I haven't personally tested this behaviour. I shall have to do a test of my own and see what happens when a mod is in place.


MacOS Sonoma version 14 is incompatible with Xcode 15.0 (15A240d) switch 14.2 (14C18). Download the latest version for free from the App Store.

Describe the bug
After installing a different version of xcode, when I open it and run it, it says that I need to update to the latest version, which is not compatible with macOS Sonoma.
To Reproduce
Download the different versions of xcode and open them ，Switching between old and new versions and large versions, switching when not compatible with the system version
Expected behavior
My version is the MacOS Sonoma 14 version, and I want to use a lower version to adapt to other development tools to assist in development. Because the development tool displays the specified version, it cannot recognize this version. I am not sure if Xcodes version management can be achieved. Regardless of the Mac system version, I can switch to the XCode version and fully adapt to it, Or perhaps I misunderstood this tool and it can only switch xcode around Mac system version adaptation
Screenshots

Version

OS: macOS Sonoma 14
Xcodes: Xcode 15.0(15A240d) switch 14.2(14C18)

This is a limitation of macOS rather than Xcodes, see this Apple Developer forum discussion (note: there is a workaround in the discussion).


Updated release responsible and date

Updated release responsible and date

Hi @anhelina44 ,

Please rebase this PR on top of the main branch.
Ask Peter(@killev) to resolve all the comments; otherwise, the PR will be blocked from merging.


Unbound keys are stored bounded

INI parser stores all keys and missing one are replaced by them.

Related issue #21

#21

#21

Fixed in faac8a4b794e672e320e43db92bb805c651f86b3


add authorship, github and twitter links to docs page

[x] add authorship
[x] add github repo link & open source call-out
[x] add twitter link

Added to footer with


Unexpected error in examples/sql

I ran examples/sql/sql2olap.sh, then ran the cubes server, and got the error below. I don't know exactly which "Title" is the problem.

To replicate:

# Apply https://github.com/jjmontesl/cubetl/pull/8 to open port 5005
docker-compose run --service-ports cubetls /bin/bash
pip install cubes click flask
cd examples/sql
sh sql2olap.sh
# Edit chinook.cubes-config.ini to use host <IP_ADDRESS> to listen for connections outside docker
slicer serve chinook.cubes-config.ini >& slicer.log &

From outside the docker container, connect to http://localhost:5005/cube/Invoice/facts.

The error (from slicer.log):

2019-11-22 20:28:26,018 DEBUG Exception stack trace:
Traceback (most recent call last):
  File "/usr/local/lib/python3.7/site-packages/cubes/sql/query.py", line 575, in column
    column = table.columns[mapping.column]
  File "/usr/local/lib/python3.7/site-packages/sqlalchemy/util/_collections.py", line 194, in __getitem__
    return self._data[key]
KeyError: 'Title'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/local/lib/python3.7/site-packages/flask/app.py", line 1949, in full_dispatch_request
    rv = self.dispatch_request()
  File "/usr/local/lib/python3.7/site-packages/flask/app.py", line 1935, in dispatch_request
    return self.view_functions[rule.endpoint](**req.view_args)
  File "/usr/local/lib/python3.7/site-packages/cubes/server/decorators.py", line 118, in wrapper
    return f(*args, **kwargs)
  File "/usr/local/lib/python3.7/site-packages/cubes/server/decorators.py", line 167, in wrapper
    retval = f(*args, **kwargs)
  File "/usr/local/lib/python3.7/site-packages/cubes/server/blueprint.py", line 414, in cube_facts
    page_size=g.page_size)
  File "/usr/local/lib/python3.7/site-packages/cubes/sql/browser.py", line 249, in facts
    include_fact_key=True)
  File "/usr/local/lib/python3.7/site-packages/cubes/sql/browser.py", line 486, in denormalized_statement
    context = self._create_context(context_attributes)
  File "/usr/local/lib/python3.7/site-packages/cubes/sql/browser.py", line 472, in _create_context
    safe_labels=self.safe_labels)
  File "/usr/local/lib/python3.7/site-packages/cubes/sql/query.py", line 883, in __init__
    bases = {attr:self.star_schema.column(attr) for attr in base_names}
  File "/usr/local/lib/python3.7/site-packages/cubes/sql/query.py", line 883, in <dictcomp>
    bases = {attr:self.star_schema.column(attr) for attr in base_names}
  File "/usr/local/lib/python3.7/site-packages/cubes/sql/query.py", line 579, in column
    % (mapping.column, mapping.table, avail))
cubes.sql.query.SchemaError: Unknown column 'Title' in table 'Invoice' possible: Invoice.InvoiceId, Invoice.CustomerId, Invoice.InvoiceDate, Invoice.BillingAddress, Invoice.BillingCity, Invoice.BillingState, Invoice.BillingCountry, Invoice.BillingPostalCode, Invoice.Total

I attach chinook.cubes-model.json.txt in case that helps. github doesn't allow .json, so I added .txt.  "Title" is all over, so it's not obvious to me what's happening.
$ grep Title examples/sql/chinook.cubes-model.json  | wc -l
      49

chinook.cubes-model.json.txt

I took just the "Invoice" part of the model and put that in a file (attached).
There are only two titles in it:
$ grep Title invoice.json.txt
                "CustomerId_SupportRepId_Title",
                "CustomerId_SupportRepId_Title.Title": "CustomerId_SupportRepId.Title",

invoice.json.txt

This works for me using Cubes master.  Please try if that solves your issue:
pip install https://github.com/DataBrewery/cubes/archive/master.zip click flask --upgrade
Cubes master includes a change I had to do to support aliased dimensions, but I was still facing some bugs in cubes which are difficult for me to debug. Ideally, my roadmap was to try and implement OLAP queries on CubETL and use it as a replacement for slicer in the future, since CubETL already has information about mappings and schema.

BTW, last week I introduced a bug in master which prevents this example from working. I'm pushing a fix in a minute.

When I just tried master, it worked. Thanks.
I would suggest tagging a 1.1.1 or something, so a labeled version has the fix. But, it's not blocking me for anything, so it's not high priority.
I'll close this, and you can reopen if you need to.


[WIP] Tag editor modal parity additions

This change refactors the existing taggingWidget component into two
primary components: a smart TagEditor component that manages the state
of the tags and a reusable, presentational TagList component responsible
for rendering the tags for a resource in multiple contexts.
The new TagEditor will not need the extra 'Add' button and will instead
add tags to the TagList once a value is selected from a dropdown menu.
https://bugzilla.redhat.com/show_bug.cgi?id=1439634
https://www.pivotaltracker.com/story/show/143255995
@miq-bot add_label fine/yes, ux/review, services
No screenshot yet but will post once I remove WIP label.

Closing in favor of #660 which is a smaller, more direct fix for the indicated BZ. Will re-open this PR when refactoring work is complete.


When using an xcodeproj (such as generated by cargo xcode) one should not use the SwiftLinker but rather build the package through the xcodeproj

Not really a bug but something to add into the docs. It took me a while to figure out what was going on...
When building for an ios target on a macos device, the swift build command generated by SwiftLinker is ignoring the -target specification. See below the command built by cargo from within a xcodeproj built by cargo-xcode.
As per my findings trying to wrap the swift command with xcrun as suggested in some threads, or adding a swift -arch  with or without -Xswiftc, or prepending the command with export ARCHS= doesn't change the outcome.
A workaround (and probably the best course of action) is to build the package within the xcodeproject itself :
1 - Drag the package folder which contains the Package.swift into your Xcode project
2 - Click the Plus button in the "Link Binary with Libraries" section, locate the package in the modal dialog, select the gray library icon inside the package, and add this one.
                  command: cd "apple/EdamameNative" && "swift" "build" "-c" "release" "--build-path"
                  "/Users/flyonnet/Library/Developer/Xcode/DerivedData/Runner-gyjydghdoilsppddiyqqpyifgfkp/Build/Intermediates.noindex/edamame_core.buil
                  d/cargo_target/aarch64-apple-ios/release/build/edamame_core-7be057f67cfcb7b2/out/swift-rs/EdamameNative" "-Xswiftc" "-sdk" "-Xswiftc"
                  "/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS16.4.sdk" "-Xswiftc" "-target"
                  "-Xswiftc" "aarch64-apple-ios"
                  error: 'edamamenative': Invalid manifest (compiled with:
                  ["/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/swiftc", "-vfsoverlay",
                  "/var/folders/s9/vlddfbs96d12sz5jgrhg3js40000gn/T/TemporaryDirectory.XDdAsN/vfs.yaml", "-L",
                  "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/pm/ManifestAPI", "-lPackageDescription",
                  "-Xlinker", "-rpath", "-Xlinker",
                  "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/pm/ManifestAPI", "-target",
                  "arm64-apple-macosx12.0", "-sdk",
                  "/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS16.4.sdk", "-F",
                  "/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/Library/Frameworks", "-I",
                  "/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/usr/lib", "-L",
                  "/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/usr/lib", "-swift-version", "5", "-I",
                  "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/pm/ManifestAPI", "-sdk",
                  "/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS16.4.sdk",
                  "-package-description-version", "5.7.0",
                  "/Users/flyonnet/Temporaire/Programming/edamame/rust/userspace/apple/EdamameNative/Package.swift", "-Xfrontend",
                  "-disable-implicit-concurrency-module-import", "-Xfrontend", "-disable-implicit-string-processing-module-import", "-o",
                  "/var/folders/s9/vlddfbs96d12sz5jgrhg3js40000gn/T/TemporaryDirectory.bYOOTT/edamamenative-manifest"])
                  <unknown>:0: warning: using sysroot for 'iPhoneOS' but targeting 'MacOSX'
                  <unknown>:0: error: unable to load standard library for target 'arm64-apple-macosx12.0'
                  thread 'main' panicked at 'Failed to compile swift package EdamameNative',

I have the same exact problem, nothing seems to make -target work.
Did you have to put the package in a specific directory of the xcodeproject?

The problem here lies within the swift package manager, good thread here

I don't understand much of what is going on here - would one of you mind creating a reproduction repo?

If I'm not mistaken, isn't SwiftLinker creating the correct build command?
swift build
    -c release
    --build-path "/Users/flyonnet/Library/Developer/Xcode/DerivedData/Runner-gyjydghdoilsppddiyqqpyifgfkp/Build/Intermediates.noindex/edamame_core.build/cargo_target/aarch64-apple-ios/release/build/edamame_core-7be057f67cfcb7b2/out/swift-rs/EdamameNative"
    -Xswiftc "-sdk"
    -Xswiftc "/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS16.4.sdk"
    -Xswiftc "-target"
    -Xswiftc "aarch64-apple-ios"

It seems like Xcode is producing the wrong target:
swiftc
    -vfsoverlay "/var/folders/s9/vlddfbs96d12sz5jgrhg3js40000gn/T/TemporaryDirectory.XDdAsN/vfs.yaml"
    -L "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/pm/ManifestAPI"
    -lPackageDescription
    -Xlinker "-rpath"
    -Xlinker "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/pm/ManifestAPI"
    -target "arm64-apple-macosx12.0"
    -sdk "/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS16.4.sdk"
    -F "/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/Library/Frameworks"
    -I  "/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/usr/lib"
    -L "/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/usr/lib"
    -swift-version 5
    -I "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/pm/ManifestAPI"
    -sdk "/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS16.4.sdk"

Seems like Xcode is specifying the correct -sdk but specifying the arm64-apple-macosx12.0 target and macOS frameworks to link against.
Maybe it's supposed to be like this, I'm not sure.

@guillemcordoba Oh that's interesting, I don't understand much about this error but if that solves it then I'd be happy to merge your branch. Would you be able to explain a bit about how/why it works?

Mmm I wouldn't know actually, I don't have any experience with xcode, swift or anything iOS related. This was just something I found to work after a full day of research around forums and stack overflow.