Missing easier way to return text/html content

Looking at the 'graphql' example, I have to depend on the mime crate to set text/html content-type:
let res = Response::new(StatusCode::Ok)
        .body_string(body)
        .set_mime(mime::TEXT_HTML_UTF_8);

if I don't want to depend on the mime crate, I can do:
    let res = Response::new(StatusCode::Ok)
        .body_string(body)
        .set_mime("text/html".parse().unwrap());

This looks non-optimal to me.
Such a basic use-case should be easier. I am wondering if I am missing an alternative.

On a related note, why is .set_mime() consuming the response? Shouldn't a mutable reference suffice and make the method more versatile?

I would personally prefer something like body_html or body_html_stirng or body_html since you most likely always want to pass charset i.e. text/html; charset=UTF-8.

Yeah, body_html/body_html_string would make good additions.

Created a small PR with this suggestion. Please consider it.

I'm curious how you're getting a string of html into your tide app. Is it being generated by a template engine? (if so, which one?) Or included through the include_bytes! macro? Or are you directly typing html in your route handler?

I used a template engine, handlebars.

I use ructe.
With the latest v0.10.0 release we don't require mime crate and can directly use tide::http::mime.
pub async fn not_found(_req: Request<AppState>) -> tide::Result {
    let mut res = Response::new(StatusCode::NotFound);
    res.render_html(|o| Ok(templates::notfound(o)?))?;
    Ok(res)
}

Given that we can't chain with v0.10.0 :(, I instead went ahead and created a trait that extends Response to include render  and render_html .
pub trait Render {
    fn render<Call>(&mut self, call: Call) -> std::io::Result<()>
    where
        Call: FnOnce(&mut dyn std::io::Write) -> std::io::Result<()>;

    fn render_html<Call>(&mut self, call: Call) -> std::io::Result<()>
    where
        Call: FnOnce(&mut dyn std::io::Write) -> std::io::Result<()>;
}

impl Render for tide::Response {
    fn render<Call>(&mut self, call: Call) -> std::io::Result<()>
    where
        Call: FnOnce(&mut dyn std::io::Write) -> std::io::Result<()>,
    {
        let mut buf = vec![];
        call(&mut buf)?;
        self.set_body(buf);
        Ok(())
    }

    fn render_html<Call>(&mut self, call: Call) -> std::io::Result<()>
    where
        Call: FnOnce(&mut dyn std::io::Write) -> std::io::Result<()>,
    {
        self.render(call)?;
        self.set_content_type(tide::http::mime::HTML);
        Ok(())
    }
}


lofty::mp3::read::read_from panics on broken mp3 file

amberol calls lofty::probe::read_from_path which results in a panic.
#6  0x00005555555a79bd in core::panicking::panic () at library/core/src/panicking.rs:48
#7  0x0000555555605b6b in lofty::mp3::read::read_from ()
#8  0x00005555555dcb5a in lofty::probe::read_from_path ()
#9  0x00005555555beb9e in amberol::audio::song::SongData::from_uri ()

The file (11 22:22.zip) is broken but it still should not panic.

Thanks for the report! That file is just an ID3v2 tag with no MPEG frames. Looks like that's a case I somehow missed. I'll get that fixed.

Fixed in https://github.com/Serial-ATA/lofty-rs/commit/89ebe2ed17c5a52ba95f58fdc0334f3511379e47. Published in 0.6.2, please inform the maintainer of Amberol :)


fix: headers are appended to existing one (open-telemetry#2335)

Which problem is this PR solving?

fixes: https://github.com/open-telemetry/opentelemetry-js/issues/2335
Needs Review and @vmarchaud may halp me given we were involved in the issue above ... :-)

Short description of the changes

added file util.test.ts under packages/opentelemetry-exporter-collector/test/browser/util.test.ts
which exercises the sendWithXhr method of packages/opentelemetry-exporter-collector/src/platform/browser/util.ts
File packages/opentelemetry-exporter-collector/src/platform/browser/util.ts is changed to verify if the developer who uses the CollectorTraceExporter api has set explicit Content-Type and Accept Headers . If that is not the case , only then the sendWithXhrt method applies the Content-Type and Accept Headers with the value application/json.

Once the lint is fixed this is mergeable

think there might be a github UI bug...


InputField: Android style (color, font) not being applied.

Nevermind please close, use inputStyle prop to style it.

I've tried the inputStyle, It didn't work too. But labelStyle and containerStyle do.
I'm on iOS RN 0.43.3, I wonder if it's compatibility issue.


Add requirements

Are you interested in a requirements.txt file for people who do not care about conda? 😄

Thanks! What about PyTorch in requirements?

PyTorch is a pain in the .ass (file?) to install via pip, mainly because you need a separate egg for each Linux distribution/version. So, I don't know. Maybe at least it will work for Mac users. Let's discriminate.
By the way, I pinged you on Twitter with questions 😁

@jilljenn why is installing from pip such a pain, from what I see from pytorch docs it's just pip3 install torch torchvision. It seems to work ok for me. Are there any issues with such in an installation?


Rendering Issues in PolygonLayer blocking Beta Release

Some layers (especially sharing buffer, like PolygonLayer) don't render correctly using latest luma/deck combination. until this is fixed.

The regressions are related to fix for Safari/Edge issues in v6.0

Actual Result
Expected Result
Reproduce Steps
Code Example
To Do List

[x] Add label and assign to milestone
[ ] Coding
[ ] Test

Was related to index buffer type


[Improve] Support jacoco and Codecov

What's changed?
Support jacoco and Codecov.
Before merging, @tomsun28 need to obtain the secret from Codecov management console.
And create this secret in the repo.
Checklist

[x]  I have read the Contributing Guide
[ ]  I have written the necessary doc or comment.
[ ]  I have added the necessary unit tests and all cases have passed.

Add or update API

[ ] I have added the necessary e2e tests and all cases have passed.

I have tested it in my own repo.

ok👍

Welcome to Codecov :tada:
Once you merge this PR into your default branch, you're all set! Codecov will compare coverage reports and display results in all future pull requests.
Thanks for integrating Codecov - We've got you covered :open_umbrella:

https://app.codecov.io/gh/apache/hertzbeat


MDI on ADCS servers - additional info

The MDI sensor can now be used on AD CS servers (Issuing CAs). The installation may fail due to "connection errors". Despite the fact that connectivity is in order, still this message is displayed. It turns out that the server certificate may not be not trusted, because the corresponding Root CA certificate is not present on the CA server - this is because CA servers are exempt from automatic certificate trus list (CTL) updates. So this error is not encountered on DCs and ADFS servers, but may be new for sensor installations on AD CS servers. Maybe it is good to add this information to the documentation (prerequisites)?

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

ID: c37c4c7f-22ca-16c4-9060-4e587f9e5ad1
Version Independent ID: c37c4c7f-22ca-16c4-9060-4e587f9e5ad1
Content: Install the sensor - Microsoft Defender for Identity
Content Source: ATPDocs/install-sensor.md
Service: microsoft-defender-for-identity
GitHub Login: @batamig
Microsoft Alias: bagol

Thank you for your comment. We'll investigate and get back to you.

HI @andrePKI, thanks for the feedback!
We've now added the certificates to the prerequisites as requested. I'm going to close this issue now, but feel free to continue commenting if you have more comments.
We appreciate your contribution to docs!
#please-close

Excellent! (just a small typo there: "you may recieve a connection error" should read receive.


Fix Content-Type headers of /ton-proof/checkProof

Post /ton-proof/checkProof is post as plain text instead of application/json
Luckily echo can handle that.
But unlucky, we are using gin that doesn't handle this automatically.
This PR fixes it to post as application/json content type.

Release the coins please


Hide ActiveLabel with NSLayoutConstraint

Hi!
First of all thank for this great pod! However, in my app I have a scenario where an ActiveLabel should be hidden dynamically. To do so, I set the text of the label to nil and I set its height to 0 through an attached NSLayoutConstraint. However, the ActiveLabel is still visible in the UI (as you can see in the first screen shot).

If I remove "ActiveLabel" from the custom class (in the interface builder) it works as expected:

It is normal? Is there a specific way to achieve this?
Best regards,
Nicolas

This pull request https://github.com/optonaut/ActiveLabel.swift/pull/367 will fix the issue. While waiting for the pod update to be released, you can add manually these lines in the property  intrinsicContentSize of the ActiveLabel class:
guard let text = text, !text.isEmpty else {
            return .zero
        }

Clean your project, rebuild and it will work!


[jest-plugin-fs] [docs] Poor usage docs - please post a better example

It is unclear how to use this plugin from the example code which does not use fs directly at any point, but only references an undeclared FileWriter, which I assume uses the mocked fs behind the scenes. Please improve the usage docs. For now I'll have to deep dive into the code and tests...
Also, I see you are using some of your other plugins such as set without mention.
"Too much magic" to be easy to understand for an "outsider"
fs.spec.js

The following taken directly from the spec is WAY more informative :)
/* eslint-disable no-undef */
describe('fs', () => {
  beforeEach(() => fs.mock());
  afterEach(() => fs.restore());

  context('with new file', () => {
    set('filename', () => 'some/path/to/file.txt');
    beforeEach(() => fsExtra.outputFileSync(filename, 'test-content'));

    it('should create the new file', () => {
      expect(fsExtra.readFileSync(filename, 'utf8')).toEqual('test-content');
    });
  });

  context('with nested directories', () => {
    set('filesystem', () => ({
      test: {
        directory: {
          nested: {
            file: 'hello there',
          },
        },
      },
    }));

    beforeEach(() => fs.mock(filesystem));

    it('should create nested directories', () => {
      expect(
        fsExtra.readFileSync('/test/directory/nested/file', 'utf8'),
      ).toEqual('hello there');
    });
  });
  });

Hi @kristianmandrup, this is great feedback, thank you!
I was in a rush to make this package functional for a work issue and didn't get a chance to document it well. I'd love if you made a PR to update the README with more useful information. Anything you can contribute would be appreciated 😄
Otherwise, I'll try to get to this in the next week. I didn't realize people started using these plugins and I have a lot of documentation to write to make this more accessible

Well, you could just copy paste the snippet I made in my Issue in place of the current snippet on the Readme which is pretty hard to understand since it implies a lot of "context".


some problem about value of table,thanks

I put  the form in the table,
when I use table-to-json,
It cannot be displayed,
like this:

        <tr
            id
            text

            1
            <input type="text">

Should I do something? Thanks.

---
Want to back this issue? **[Post a bounty on it!](https://www.bountysource.com/issues/32898553-some-problem-about-value-of-table-thanks?utm_campaign=plugin&utm_content=tracker%2F228299&utm_medium=issues&utm_source=github)** We accept bounties via [Bountysource](https://www.bountysource.com/?utm_campaign=plugin&utm_content=tracker%2F228299&utm_medium=issues&utm_source=github).

Thanks anyway. I found the solution....
function tableToJson() {
    var table = $('#table1').tableToJSON({
        textExtractor: function (cellIndex, $cell) {
            // get text from an input or select inside table cells;
            // if empty or non-existent, get the cell text
            return $cell.find('input,input').val() || $cell.text();
        }
    });
}


Inclusion of Aeotec Wallmote (Quad) hangs when interviewing configuration params

I have tried to include Aeotec Wallmote a few times and it always hangs when doing the same thing. I have included the whole logfile from start of inclusion to end. When reading the manual, there are only parameter 1-4, not 5 or 39.
First it tries to interview configuration parameter #5, which fails.
10:06:43.662 CNTRLR » [Node 041] querying parameter #5 value...
[...]
10:06:50.176 CNTRLR   [Node 041] The node did not respond after 3 attempts.
It is probably asleep, moving its messages to the wakeup queue.
10:06:50.184 CNTRLR   [Node 041] The node is now asleep.
10:06:50.221 CNTRLR « [Node 041] received no value for parameter #5
And after that it tries parameter #39, which wont work since the node is asleep.
10:06:50.223 CNTRLR » [Node 041] querying parameter #39 value...
wallmote.txt

Which version of the library are you using? This should be fixed in the current alpha (https://github.com/AlCalzone/node-zwave-js/commit/00718ee4216f3eb8976091e4e4003ca1fe06ab3a), but I wouldn't recommend using that in production yet, since it has issues with some secure devices.
This shouldn't be a critical problem in 4.x though, except that the interview will take a few breaks while the node is assumed asleep.
From what I've read, parameter #39 should already be there in the old firmware revisions, even though it is not documented. #5 was added in a firmware revision after 1.5, but I'm not sure which one, so I assumed 1.6. My 1.8 device does have it - which version do you have?
Once I've corrected the config files, your issue should go away.

Oh, great. I actually run alpha.1 and maybe that's the issue here. I'll try to upgrade and see if the problem disappears. I've got alot of Z-Wave devices (around 50) and there were some problems (retransmission, etc) with 4.x that has been fixed in alpha.x, so it's more stable for me.
I think this is version 2.3:
10:06:31.571 CNTRLR   [Node 041] [+] [Version] firmwareVersions: 2.3                    [Endpoint 0]

Huh, I didn't know there is a 2.x firmware. Maybe that's a different hardware. If that doesn't have parameter #39 either, please let me know and will remove them for the 2.x firmware line.

Hang on, I did link to the wrong product in the first post. The correct one is here although there's no parameter #5/#39 there either.
Either way, I tried the inclusion again in alpha.3 and it worked great. Thank you!

Does the log or values.jsonl contain any reference to these parameters?

From log:
11:34:36.280 CNTRLR   [Node 044] ConfigurationCC: Loading configuration parameters from device config
11:34:36.311 CNTRLR   [Node 044] [+] [Configuration] isParamInformationFromConfig: false  [internal]
11:34:36.329 CNTRLR   [Node 044] [Configuration] 1: metadata updated
11:34:36.366 CNTRLR   [Node 044] [Configuration] 2: metadata updated
11:34:36.372 CNTRLR   [Node 044] [Configuration] 3: metadata updated
11:34:36.399 CNTRLR   [Node 044] [Configuration] 4: metadata updated
11:34:36.404 CNTRLR   [Node 044] [Configuration] 5: metadata updated
11:34:36.439 CNTRLR   [Node 044] [Configuration] 39: metadata updated
11:34:36.495 CNTRLR   [Node 044] [Configuration] 255: metadata updated
11:34:36.500 CNTRLR   [Node 044] [~] [Configuration] isParamInformationFromConfig: false  [internal] => true
values.jsonl:
{"k":"{"nodeId":44,"commandClass":112,"endpoint":0,"property":"isParamInformationFromConfig"}","v":true}
{"k":"{"nodeId":44,"commandClass":112,"endpoint":0,"property":1}","v":1}
{"k":"{"nodeId":44,"commandClass":112,"endpoint":0,"property":2}","v":1}
{"k":"{"nodeId":44,"commandClass":112,"endpoint":0,"property":3}","v":1}
{"k":"{"nodeId":44,"commandClass":112,"endpoint":0,"property":4}","v":1}
{"k":"{"nodeId":44,"commandClass":112,"endpoint":0,"property":39}","v":20}
{"k":"{"nodeId":44,"commandClass":112,"endpoint":0,"property":"interviewComplete"}","v":true}
{"k":"{"nodeId":44,"commandClass":133,"endpoint":0,"property":"groupCount"}","v":9}
metadata.jsonl: metadata.jsonl.txt

Here's a manual which includes references to paramter 5 so it does look like it exists: https://cdn.shopify.com/s/files/1/0066/8149/3559/files/24_wallmote_quad_-_es.pdf
To configure which color will be displayed when the button is pressed.
Value1 = Red.
Value2 = Green.
Value3 = Blue.
Value4 = Reserved.

Ok that looks like your device (or firmware) does have #39, but not #5. Thanks for confirming.

No problem. This is a great library, thanks for all the work.

This should be fixed in v4.2.2, I'll port the changes to master next.


 Which direction would you like to go?  (Use arrow keys)

 ❯ Forward
   Right
   Left
   Back

if there already is content in the terminal it works normally.
Is there a way to fix this?

You can fix the bug currently with the PR above for now. Though its not clearly tested yet. Once there's enough testing, it will be merged

This issue will be open till the #4 is merged.

I have been using the #4 PR since I created this issue as I found it right after. It  has worked great until now without any issues (only tested on windows)

The #4 has been merged to both dev and master. So I am going to close this issue. :+1: :100:


Bus-refresh does not work with Config Server Vault

Hello!
I cannot get bus-refresh working with Spring Cloud Config Server + Vault as a backend. I feels like it is an issue with Spring Cloud Bus to me and this is why.
I have configured Spring Cloud Config Server with Git as a backend and have enabled Spring Cloud Bus for updated properties to be pushed to my other Microservices. This configuration works and when I send HTTP Post request tp a /bus-refresh endpoint all my web services are updated with new properties. This tells me that my Spring Cloud Config Server and Spring Cloud Bus and all of my Microservices are configured properly.
When I enable Vault as a backend in Spring Cloud Config Server I can see it can read properties stored in secret engines. I get the following response when checking if Spring Cloud Config can see the value of token.secret stored in Vault:
GET http://localhost:8012/MyConfigServer/vault

{
    "name": "MyConfigServer",
    "profiles": [
        "vault"
    ],
    "label": null,
    "version": null,
    "state": null,
    "propertySources": [
        {
            "name": "vault:MyConfigServer",
            "source": {
                "token.secret": "jf9i4jg47fhdnj58yrgh35dhjf8403jdh375jf349700000"
            }
        }
    ]
}

The Response is successful and I can see that Spring Cloud Config can see the property stored in Vault.
However if I try to push this value to my other Microservices subscribed to Spring Cloud Config Server, they do not get a new value.
The following HTTP Request is Successful(HTTP Status code is 204) but Microservices are not updated.
GET http://localhost:8012/actuator/bus-refresh
Is it an issue or there is something additional I need to configure on Spring Cloud Config Server for Spring Cloud Bus to be able to push properties to subscribed Microservices.
If I switch to use Git as a backend then all works as expected...

@simplyi What version of Spring Cloud are you using?

I tried this using Greenwich.SR1 and it worked fine.
Can you provide a complete, minimal, verifiable sample that reproduces the problem? It should be available as a GitHub (or similar) project or attached to this issue as a zip file.

@ryanjbaxter Thank you for your response. I am using Greenwich.RELEASE.
Regarding the verifiable example... I guess I need to make my Spring Cloud Config project and at least one Microservice available here on Git so that they can be cloned and ran?... They will work with Git and Native file system as a backend.. it is just the vault not working for me...

I guess I am more interested in seeing the client that is not working.  I can probably generate a backend that works from there.

@ryanjbaxter thank you!
I have published client application here: https://github.com/simplyi/SpringCloudVideoCourse/tree/master/PhotoAppApiUsers
and config server here:
https://github.com/simplyi/SpringCloudVideoCourse/tree/master/PhotoAppAPIConfigServer

Sorry, I have the same probrom in Greenwich.SR2.
My Config Server  and order-client is both:
    <parent>         <groupId>org.springframework.boot</groupId>         <artifactId>spring-boot-starter-parent</artifactId>         <version>2.1.6.RELEASE</version>         <relativePath/>     </parent>     <properties>         <java.version>1.8</java.version>         <spring-cloud.version>Greenwich.SR2</spring-cloud.version>     </properties>
when I update github configs，the Config Server print log:
`
2019-07-01 12:10:45.105  INFO 24262 --- [io-9999-exec-10] com.netflix.discovery.DiscoveryClient    : Force full registry fetch : false
2019-07-01 12:10:45.105  INFO 24262 --- [io-9999-exec-10] com.netflix.discovery.DiscoveryClient    : Application is null : false
2019-07-01 12:10:45.105  INFO 24262 --- [io-9999-exec-10] com.netflix.discovery.DiscoveryClient    : Registered Applications size is zero : true
2019-07-01 12:10:45.105  INFO 24262 --- [io-9999-exec-10] com.netflix.discovery.DiscoveryClient    : Application version is -1: true
2019-07-01 12:10:45.105  INFO 24262 --- [io-9999-exec-10] com.netflix.discovery.DiscoveryClient    : Getting all instance registry info from the eureka server
2019-07-01 12:10:45.108  INFO 24262 --- [io-9999-exec-10] com.netflix.discovery.DiscoveryClient    : The response status is 200
2019-07-01 12:10:45.109  INFO 24262 --- [io-9999-exec-10] com.netflix.discovery.DiscoveryClient    : Starting heartbeat executor: renew interval is: 30
2019-07-01 12:10:45.109  INFO 24262 --- [io-9999-exec-10] c.n.discovery.InstanceInfoReplicator     : InstanceInfoReplicator onDemand update allowed rate per min is 4
2019-07-01 12:10:45.110  INFO 24262 --- [io-9999-exec-10] com.netflix.discovery.DiscoveryClient    : Discovery Client initialized at timestamp<PHONE_NUMBER>110 with initial instances count: 2
2019-07-01 12:10:45.111  INFO 24262 --- [io-9999-exec-10] o.s.c.n.e.s.EurekaServiceRegistry        : Unregistering application CONFIG-CENTER with eureka with status DOWN
2019-07-01 12:10:45.111  WARN 24262 --- [io-9999-exec-10] com.netflix.discovery.DiscoveryClient    : Saw local status change event StatusChangeEvent [timestamp=1561954245111, current=DOWN, previous=STARTING]
2019-07-01 12:10:45.111  INFO 24262 --- [nfoReplicator-0] com.netflix.discovery.DiscoveryClient    : DiscoveryClient_CONFIG-CENTER/<IP_ADDRESS>:config-center:9999: registering service...
2019-07-01 12:10:45.111  INFO 24262 --- [io-9999-exec-10] o.s.c.n.e.s.EurekaServiceRegistry        : Registering application CONFIG-CENTER with eureka with status UP
2019-07-01 12:10:45.111  WARN 24262 --- [io-9999-exec-10] com.netflix.discovery.DiscoveryClient    : Saw local status change event StatusChangeEvent [timestamp=1561954245111, current=UP, previous=DOWN]
2019-07-01 12:10:45.111  INFO 24262 --- [io-9999-exec-10] o.s.cloud.bus.event.RefreshListener      : Received remote refresh request. Keys refreshed []
2019-07-01 12:10:45.116  INFO 24262 --- [nfoReplicator-0] com.netflix.discovery.DiscoveryClient    : DiscoveryClient_CONFIG-CENTER/<IP_ADDRESS>:config-center:9999 - registration status: 204
`
the rabbitmq with order's queue can recieve msg:
`

`
but the order-client has no log , and can't get configs.

is this still an issue with boot 2.2.2 and Hoxton.SR1?

If you would like us to look at this issue, please provide the requested information. If the information is not provided within the next 7 days this issue will be closed.

Closing due to lack of requested feedback. If you would like us to look at this issue, please provide the requested information and we will re-open the issue.


Remove service tests for dropped [static] png routes

Closese #3700

Messages

:book:
:sparkles: Thanks for your contribution to Shields, @calebcartwright!

  Generated by :no_entry_sign: dangerJS against c087cd7e4156dcd7179c034bb1a1205e1304abce


Importing a module to reference in a d.ts silently fails a declaration

TypeScript Version: nightly (1.9.0-dev.20160217), also 1.8.10
Code
tsconfig.json:
{
  "compilerOptions": {
    "charset": "utf-8",
    "emitDecoratorMetadata": true,
    "experimentalDecorators": true,
    "lib": [
      "es5"
    ],
    "module": "commonjs",
    "newLine": "LF",
    "outDir": "dist",
    "pretty": true,
    "sourceMap": true,
    "target": "es2015"
  },
  "include": [
    "src/**/*.ts",
    "typings/**/*.ts"
  ]
}

I am attempting to declare Bluebird as my global promise implementation.  I have typings for the bluebird module installed via typings.
typings/custom/global-bluebird.d.ts:
import Bluebird = require('bluebird');
declare var Promise:typeof Bluebird;

src/test.ts:
Promise.resolve();

When compiling, I have no errors on global-bluebird.d.ts, but I see TS2304: Cannot find name 'Promise'. when referencing Promise.

Interestingly, it seems to be the import statement that blows it up.  The following compiles as expected:
typings/custom/global-bluebird.d.ts:
declare class Promise {
  static resolve():void;
}

However, if I import bluebird (and do nothing with it!):
typings/custom/global-bluebird.d.ts:
import Bluebird = require('bluebird');

declare class Promise {
  static resolve():void;
}

It fails again with error TS2304: Cannot find name 'Promise'.  This seems to be true no matter what I import.
It also occurs if I explicitly add a reference to the Bluebird typings via /// <reference path="../modules/bluebird/index.d.ts" />

import statement makes the file an external module which means that Promise is declared and visible only inside this module
import Bluebird = require('bluebird');
declare var Promise:typeof Bluebird;

If you want to declare that module changes the global scope you can use global augmentations:
import Bluebird = require('bluebird');
declare global {
    var Promise:typeof Bluebird;
}

Aha, thanks!


button to reverse order

aded in https://github.com/seanbreckenridge/my_feed/commit/faa2cc2c77de1de3eadaf9fc94f8099a274d60ba


Git workflow using tags instead of branches

Note: If your question is regarding the AWS Amplify Console service, please log it in the
AWS Amplify Console repository

Which Category is your question related to?
Auth, Api (GraphQL, REST and Fargate), Function, Storage (DDB)
Amplify CLI Version
You can use amplify -v to check the amplify cli version on your system
v6.3.0
What AWS Services are you utilizing?
AppSync, ApiGateway, Fargate/ECS, Cognito, Lambda, DynamoDB
Provide additional details e.g. code snippets
Question about the git workflow. I release using tags not branches... if I want to push to prod using a tag that was already deployed to a pre-prod environment, is this what I need?
git checkout v1.0.0
amplify env checkout prod
git restore amplify
amplify push

So instead of using (for example) git merge staging I'm using git restore amplify
That should work, right? And do I need to commit after amplify push?

Hey @mattfysh :wave: when the CLI did not prompt for the secret's value, was this a new function that we merged in? After merging and running amplify env checkout <current-env-name> to init the new resources I just merged in, then run amplify push I received the following prompt:
> amplify push
⚠ Amplify command hooks are disabled in the current execution environment.
⚠ See https://docs.amplify.aws/cli/usage/command-hooks/ for more information.
? mysupersecret in 8426c0f09b53 does not have a value in this environment. Specify one now: [input is hidden]

Can you describe the workflow in which it did not prompt for the missing secret value? Also if you wouldn't mind could you file a new bug report for the function secret issue so we can document the occurrence separately?

Hi @josefaidt - I reran the scenario with the latest version of CLI and everything worked! Thanks for a great job on this one 🪄


Make @with_config stackable

I merge for now to unblock #941, but please audit if you want. I'm a bit disappointed that it ended up with so much code. I also realized you can run the doc-tests as this as well:
tox -e py27-nonhdfs -- --with-doctest test/helpers.py


[WIP] feat: added es-mx locale

Addinges-mx locale for coronastatus.mx
TODO:

Finish word list

Should also have a social media image like this: https://github.com/BustByte/coronastatus/blob/master/static/en/social-media.png
@amritnagi or @adriaanvanrossum can probably create it for you if provide them with texts 😄


Move github.com/cilium/ipam packages to main repo

First 3 commits are preparatory to update the vendored package, allow use of Cilium's concurrency-safe PRNG type in the new package and allow k8s authors in file header copyright notices.
The fourth commit moves the packages. Quoting the commit message:
ipam, vendor: move github.com/cilium/ipam packages to main repo

Instead of keeping a separate repo for these packages move them to the
main cilium repo which makes this easier to maintain and iterate on.

The code was originally forked from
k8s.io/kubernetes/pkg/registry/core/service and has since been extended
and changed to fit Cilium's needs.

This is a copy of the github.com/cilium/ipam repo at commit.
https://github.com/cilium/ipam/commit/fd66eae7909b3d3962dfc8887805181462a7e384
This corresponds to the version that is currently vendored.
Additionally, the test files are copied and unnecessry BUILD files
(stemming from upstream k8s) were removed. Some modifications to the
lock and rand types used within the packages needed to be made:

 * Use mutex types from pkg/lock for deadlock detection
 * Use pkg/rand for concurrency safe PRNG
 * Change the license/copyright format in file headers to conform to Cilium
   project requirements.

Otherwise linters would complain about the use of the Go stdlib types.

/test

/test

/test-runtime

/test


Queue & Deque segfault upon GC

Queue & Deque can segfault when GC is triggered:
<?php

$q = new \Ds\Queue();

for ($i = 0; $i < 100 ; $i++) {
    $q->push(123);
    gc_collect_cycles();
}

Observed on:

php 7.2.5 & ds 1.2.5, Mac & linux (via docker for mac);
php 7.1.14 & ds 1.2.3, Mac

Not observed on php 7.1.4 & ds 1.2.3 (using this docker image mentioned in another issue).
I can avoid this locally by altering php_ds_queue_get_gc  as follows (and similarlyphp_ds_dueue_get_gc):
     ds_queue_t *queue = Z_DS_QUEUE_P(obj);

     *gc_data  = queue->deque->buffer;
-    *gc_count = (int) queue->deque->capacity;
+    *gc_count = (int) queue->deque->size;

     return NULL;
 }

...but I'm not confident that this is a proper fix, since the bug seems to indicate that the spare capacity in the buffer is mis-initialized. Perhaps something about the lower-level mem mgmt used by deque reallocation has changed in PHP?

I'm not confident that this is a proper fix, since the bug seems to indicate that the spare capacity in the buffer is mis-initialized.

I think you're absolutely right here. I'm assuming that the GC is stepping across the buffer but encounters a bad zval, and fails. I don't think using size is safe here because the values in the buffer aren't necessarily positioned between 0 and size-1 (in the case of deque, at least). So the only solution I see here is to investigate how the buffer is allocated.
It's also worth noting that Queue uses a Deque internally so fixing Deque's GC will fix Queue as well.

Hm – upon further investigation, I can't (yet) recreate this on the official docker php image. I'll try to dig deeper to see if it's connected to another extension.

I haven't encountered this myself, but I'll try to reproduce this locally today and see what happens. 👍

@orls keep in mind that unallocated memory is unpredictable, and this might only segfault _sometimes.

I have a feeling we're not clearing out on reallocation. See https://lxr.room11.org/xref/php-src%40master/ext/spl/spl_fixedarray.c#123

keep in mind that unallocated memory is unpredictable, and this might only segfault sometimes.

Indeed. Fiddling with extensions does seem to affect it, but I doubt that's related to the particular extensions involved, it'll just be happenstance of memory allocations over time.
Here's the best recreation I can get, by restricting memory & allocating some stuff first. Using latest official php docker image (7.2.5)
<?php

ini_set('memory_limit','8M');

$junk = [];
for ($i = 0; $i < 1024; $i++) {
    $junk []= random_bytes(1024);
}

$q = new \Ds\Queue();
for ($i = 0; $i < 100 ; $i++) {
    $q->push(123);
    gc_collect_cycles();
    echo $q->count() . PHP_EOL;
}

This has now been fixed and released as 1.2.6 on PECL.


Add Support page

Adding content based on #836

Looks like proselint caught you:

content/support/index.md:7:1: cliches.garner 'First and foremost,' is cliché.

I'm running into an issue testing proselint on my machine after running yarn install.
I did fix the error though, I'll make a commit.

Yeah. proselint has to be installed through pip as it's a Python tool. pip proselint if I remember right.

The only issue I have with this PR is that it could potentially attract us a lot of contributions, so I'd like to have a more fleshed out content section mainly removing the (add more slides here) before merging this PR.

Yup. Cut the slide bit. Good to go after that.


📐 Posthog for Yaml Controller

#696  👈 (View in Graphite)
main

This stack of pull requests is managed by Graphite. Learn more about stacking.


[PolygonROI] rm shift-click, solve interactor style after repulsor, hid widgets

This PR is based on a list of bug found by radio-technicians on MUSICardio 4. I am going to wait a little bit to do a new mini release, in order to solve some other bugs they found.
In PolygonROI this PR:

remove the need to use shift-click to draw a ROI, which has been added for a functionality that has been removed (by Julien if needed), and that annoy users.
fix a bug of contrast (or other interactor style) after deactivation of Repulsor, or clear.
and also hide deactivated widget to help users.

:m:

To be used with https://github.com/Inria-Asclepios/music/pull/1091


crates-io version is 0.18.0 but max in https://crates.io/crates/crates-io is 0.16.0

in Cargo.tml the crates-io version is 0.18.0
however the index https://github.com/rust-lang/crates.io-index/blob/master/cr/at/crates-io shows only 0.16.0 (as does crates.io)
this breaks 3rd party tool https://github.com/dhuseby/cargo-bootstrap
thanks

Ah we don't publish what's on master, only when it hits the stable channel. Thanks for the report though!


[network] Move discovery to be above the core network layer

Motivation
Discovery doesn't need to be a core network module and can function just fine using the external network API. It's also not useful in all cases - e.g. when we want to use LibraNet in a non-p2p setting.
See: #1516
Have you read the Contributing Guidelines on pull requests?
Yes
Related PRs
#1706

@bors-libra delegate=bothra90
Merge after fixing nits. Code looks much cleaner now!

:v: @bothra90 can now approve this pull request

@bors-libra r+

:pushpin: Commit a0a4686 has been approved by bothra90

:hourglass: Testing commit a0a46864c23c180c9a5575918a01e31bf4f36894 with merge c356a930ea7a4a7e50c0e96c3f2350c08dbe5836...

:sunny: Test successful - checks-circle_commit_workflow
Approved by: bothra90
Pushing c356a930ea7a4a7e50c0e96c3f2350c08dbe5836 to master...


docs: fixed typo in PurgeCSS configuration note

Here's a small typo fix.
Thank you for this amazing Hugo template.

Thank you.


sharding-jdbc-transaction

为什么maven仓库里 没有这个jar吧？？？

Hello, we prefer use english to discuss issue.
For bug report, we can keep it, but for question, we will close directly.


Define requirements and potential solutions for suitable unique identifiers for papers and linking pre-prints to journal publications

Description of the task:

[ ] What would be the best unique bibliographic identifier for us to use when tracking datasets, pre-prints and journal publications? Consider the advantages and disadvantages of various bibliographic identifiers for tracking datasets and the source/related journal articles, pre-prints. The identifier should help us to avoid duplicate rows/records, i.e. not to add the same publication multiple times. It should also help programmatic queries and comparisons of bibliographic sets.
[ ] How should we link pre-prints to the published journal articles? We need a way to link pre-prints and published journal articles when they are related to the same dataset to avoid redundant records.

Acceptance criteria for the task:

[ ] Best bibliographic identifiers are selected
[ ] A solution for linking pre-prints to final publications is proposed
[ ] The software-based tracking requirement document is updated to reflect all these

I see this is tagged as operations, isn't defining software requirements development rather than operations? @clairerye ?

@rays22 @lauraclarke I just noticed this ticket is still open, but I think Ray resolved this by adding DCP specific identifiers to the tracker?

@rays22 @lauraclarke I just noticed this ticket is still open, but I think Ray resolved this by adding DCP specific identifiers to the tracker?


Unexpected error passing apiOptions

I seem to be getting an error trying to pass options through the apiOptions config in buildModules
Using this:
[
      "@storyblok/nuxt/module",
      {
        accessToken: process.env.STORYBLOK_PREVIEW_API_KEY,
        apiOptions: {
          cache: 'memory'
        }, // storyblok-js-client options
        bridge: true,
        useApiClient: true
      }
    ],
]

I seem to get this.
Removing apiOptions clears the error but I need to pass config to the js-client.
Syntax Error: Unexpected token (14:17)                                                                                friendly-errors 15:36:34
12 |     accessToken: "8OooEHvfrdAHQAAokOArXgtt",
13 |     bridge: true,
> 14 |     apiOptions: {"cache":"memory"},
|                  ^
15 |
16 |     use: [apiPlugin]
17 |   });
Any idea what is causing this?
It seems to be a problem with stringifying the apiOptions object

Same issue, can't pass any options
Any ideas when this will be resolved?

Hi all! FYI - we moved Nuxt 2 module to https://github.com/storyblok/storyblok-nuxt-2
I've just fixed this issue in the latest commit https://github.com/storyblok/storyblok-nuxt-2/commit/6d842b5eee227af8d0f31e951841838002ec9a12.
Released in @storyblok/nuxt-2 v1.0.1


Access to response bodies in modifiers fails

Describe the bug
Access to response bodies (backend_responses.<label>.*body) in modifiers (like set_response_headers) does not work.
To Reproduce
Steps to reproduce the behavior:

couper version: 0 2022-02-09 dev

Provide your configuration file *.hcl. Remove sensitive data.

server {
  endpoint "/" {
    proxy {
      url = "https://httpbin.org/anything"

      backend {
        set_response_headers = {
          x-foo = backend_responses.default.headers.content-type # works
          x-bug = backend_responses.default.json_body.method     # does not work
        }
        custom_log_fields = {
          foo = backend_responses.default.headers.content-type # works
          bar = backend_responses.default.json_body.method     # works
        }
      }
    }
  }
}

Provide a curl call for reproduction: $ curl -v localhost:8080

Expected behavior
X-Bug HTTP header field with GET value in the response.

It depends on where the set_response_headers is used. With
server {
  endpoint "/" {
    proxy {
      url = "https://httpbin.org/anything"
      set_response_headers = {
        x-foo = backend_responses.default.headers.content-type # works
        x-bug = backend_responses.default.json_body.method     # does not work
      }
    }
  }
}

or
server {
  endpoint "/" {
    set_response_headers = {
      x-foo = backend_responses.default.headers.content-type # works
      x-bug = backend_responses.default.json_body.method     # does not work
    }
    proxy {
      url = "https://httpbin.org/anything"
    }
  }
}

both headers are set.


JCL-389: removed copyright year from all headers

In all java classes and in the license text.

Pushed by mistake to this branch something from JCL-403. I reverted it.


focal loss

Hello and thanks for your work!
Did you try to use cross-entropy loss with your QAAM head? If yes, what were the results compared to the focal-loss?

Hi~
I didn't try QAM head + CELoss. However, I do have compared CELoss with Focal-Loss on ArcFace head and the results indicate that Focal-Loss is better than CELoss.

That's interesting. Thanks!


Initial js_of_ocaml support (requires the unreleased jsoo.3.0)

Documentation is still missing

The manual also need to be updated

Ok, code looks good. BTW, since we don't use the fact that (js_of_ocaml ...) is present or not, we should change the field to not be an option, and use a default value if it's absent

I started splitting gen_rules.ml to make it easier to add new systems. You should now be able to move the js_of_ocaml rules in their own module. Global variables should go in Super_context

Thanks!


Fix Interact Issues (Sprint 2)

This repo is deprecated now! https://github.com/data-8/nbgitpuller is what is now going to be used.


Resources limits confusing

Resource usage by instances
Each container instance is allocated the resources specified in its resource request. However, the resource usage by a container instance in a group depends on how you configure its optional resource limit property.
If you don't specify a resource limit, the instance's maximum resource usage is the same as its resource request.
If you specify a resource limit for an instance, you can adjust the instance's resource usage for its workload, either reducing or increasing usage relative to the resource request. The maximum resource limit you can set is the total resources allocated to the group.
For example, in a group with two instances requesting 1 CPU, one of your containers might run a workload that requires more CPUs to run than the other.
In this scenario, you could set a resource limit of 0.5 CPU for one instance, and a limit of 2 CPUs for the second. This configuration limits the first container's resource usage to 0.5 CPU, allowing the second container to use up to the full 2 CPUs if available.
With scenario mentioned above, it never succeed.

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

ID: ff247151-29f6-4a55-61b2-e5eae2d48927
Version Independent ID: 159517fe-202c-967d-f572-49c4f6988c46
Content: Introduction to container groups - Azure Container Instances
Content Source: articles/container-instances/container-instances-container-groups.md
Service: container-instances
GitHub Login: @dlepow
Microsoft Alias: danlep

@JuneZhao Thanks for the feedback! We are currently investigating and will get back on this.

@dlepow Can you please look into this feedback and add your comments.

@MicrosoftDocs/aks-pm Please look into this and add your comments.

@JuneZhao - Thanks for letting us know and apologies for any confusion in our documentation. Can you please tell us more about your scenario and where you find that the description is not accurate? See also the example in https://github.com/MicrosoftDocs/azure-docs/issues/41476
@VikasPullagura-MSFT - Could you please tag ACI PMs instead of AKS PMs on this issue? Thx!

@dkkapur can you help on this or suggest someone who might be able to ?

@dlepow, sure resources:
requests:
cpu: 1
memoryInGB: 1.5
limits:
cpu: 1.5
memoryInGB: 1.5
ports:
- port: 80
- port: 8080

name: aci-tutorial-sidecar
properties:
image: mcr.microsoft.com/azuredocs/aci-tutorial-sidecar
resources:
requests:
cpu: 1
memoryInGB: 1.5
limits:
cpu: 2
memoryInGB: 1.5  this will succeed as expected
requests:
cpu: 1
memoryInGB: 1.5
limits:
cpu: 1
memoryInGB: 1.5
ports:

port: 80
port: 8080

name: aci-tutorial-sidecar
properties:
image: mcr.microsoft.com/azuredocs/aci-tutorial-sidecar
resources:
requests:
cpu: 1
memoryInGB: 1.5
limits:
cpu: 2
memoryInGB: 1.5 this as well

@dlepow but below will fail resources:
requests:
cpu: 1
memoryInGB: 1.5
limits:
cpu: 0.5
memoryInGB: 1.5
ports:
- port: 80
- port: 8080

name: aci-tutorial-sidecar
properties:
image: mcr.microsoft.com/azuredocs/aci-tutorial-sidecar
resources:
requests:
cpu: 1
memoryInGB: 1.5
limits:
cpu: 2
memoryInGB: 1.5 this wil fail which conflict with what the doc mentioned,

If there is only 1 container inside the container group then no matter the limits is higher or lower than the resources it will always fail with confusing message:
The resource requirement '{"requests":{"memoryInGB":2.0,"cpu":1.5},"limits":{"memoryInGB":1.5,"cpu":1.0}}' in container 'aci-tutorial-app' of contain group 'myContainerGroup' is invalid. The 'Cpu' limit value must be greater than or equal to the request value.
location: eastus
name: myContainerGroup
properties:
containers:

name: aci-tutorial-sidecar
properties:
image: mcr.microsoft.com/azuredocs/aci-tutorial-sidecar
resources:
requests:
cpu: 1
memoryInGB: 1.5
limits:
cpu: 2
memoryInGB: 1.5
osType: Linux
ipAddress:
type: Public
ports:

protocol: tcp
port: '80'
protocol: tcp
port: '8080'
tags: null
type: Microsoft.ContainerInstance/containerGroups

@JuneZhao - These examples are very helpful and I'll adjust the docs after I confirm the details with the engineering team
The single-container group example might be an unusual case, since a limit (if set) would need to be exactly equal to the request. Is there a scenario where you'd want to set it differently?
#in-progress

@dlepow hi  acutually it is one of my customers who want to have this funtion, it is similar to k8s pod function that the requests is the initial request whereas the limits is when the load is high then  it can adjust to the maximum value.

@JuneZhao - As far as I know the way to accomplish this in ACI is to add resources to the group with another container that makes the resource request. The similarity of container group to the K8s pod isn't exact.

Doc update is published, so closing this issue. Thanks again for pointing it out.
#please-close


Cannot read property 'importKey' of undefined

import FlexSDKWeb from '@cybersource/flex-sdk-web';

let jwk = await this.generatePublicKey(),
    options = {
         kid: jwk.kid,
         keystore: jwk,
         cardInfo: {
             cardNumber: '4111111111111111',
             cardType: '001',
             expiryMonth: '11',
             expiryYear: '2022',
        },
        encryptionType: 'rsaoaep256',
        production: false,
 };

FlexSDKWeb.createToken(options, (response) => {
    console.log(response);
});

TypeError: Cannot read property 'importKey' of undefined
at y (flex-sdk-web.js?c502:11)
at eval (flex-sdk-web.js?c502:11)
at d (flex-sdk-web.js?c502:11)
at Object.createToken (flex-sdk-web.js?c502:11)
at VueComponent._callee3$ (AddPaymentMethod.vue?0e2c:456)
at tryCatch (runtime.js?98b8:45)
at Generator.invoke [as _invoke] (runtime.js?98b8:274)
at Generator.prototype. [as next] (runtime.js?98b8:97)
at asyncGeneratorStep (cjs.js?!./node_modules/babel-loader/lib/index.js!./node_modules/cache-loader/dist/cjs.js?!./node_modules/vue-loader/lib/index.js?!./src/components/AddPaymentMethod.vue?vue&type=script&lang=js&:24)
at _next (cjs.js?!./node_modules/babel-loader/lib/index.js!./node_modules/cache-loader/dist/cjs.js?!./node_modules/vue-loader/lib/index.js?!./src/components/AddPaymentMethod.vue?vue&type=script&lang=js&:26)
This is happening in my localhost development in Chrome version: Version 80.0.3987.149 (Official Build) (64-bit)

Firefox gives me a more descriptive error: Argument 2 of SubtleCrypto.importKey is not an object.

@cody-baker what version of @cybersource/flex-sdk-web are you using?
By the looks of things it can't import the key you've provided.
Have you definitely populated the jwk variable correctly?

Using version 0.3.0 of @cybersource/flex-sdk-web
We used CyberSource KeyGenerationApi and GeneratePublicKeyRequest to get the jwk. Here is a snippet of that request in python which is essentially a copy of the CyberSource python example for generating a key:
https://developer.cybersource.com/api-reference-assets/index.html#flex_key-generation_generate-key
import json
from CyberSource import *

def get(request):
    try:
        # Reading Merchant details from Configuration file
        key_generation_obj = KeyGenerationApi(cybersource_config)
        key_generation = GeneratePublicKeyRequest(encryption_type="None")
        message_body = json.dumps(key_generation.__dict__)
        return_data, status, body = key_generation_obj.generate_public_key(generate_public_key_request=message_body)

        return HttpResponse(return_data)
    except Exception as e:
        print("Exception when calling KeyGenerationApi->generate_public_key: %s\n" % e)

        return HttpResponse(e)

@cody-baker looks like you are creating the key with one type, then specifying differently on the front end.
key_generation = GeneratePublicKeyRequest(encryption_type="None")

encryptionType: 'rsaoaep256',

You just need these to be the same and what you have will work .
Using None is fine for development, however, I would strongly recommend going with RsaOaep for your actual integration.
Possible values for encryptionType param are:

None - all payloads are in the plain if you inspect the network tab
RsaOaep - card number is encrypted on the device before sending so you won't see this in the network tab.
RsaOaep256 - as above but with a different hash used in the encryption. This has slightly less browser support, hence why I would recommend going with RsaOaep

Hope this helps

Ah yes this was an oversight on my end. Bc of this the jwk in the response was None. But even with RsaOaep as the encryptionType param I am still getting Cannot read property 'importKey' of undefined even though I am passing a valid jwk now

@cody-baker I wasn't able to recreate this one unfortunately.
We did just push push a 0.3.1 patch this evening, perhaps worth trying with that?
The only occurrence of importKey in the codebase where the JWK is being imported via the WebCryptoAPI.
return window.crypto.subtle.importKey(...);

Given the stacktrace, is there perhaps something in your babel setup that could be interfering with it? As a test, perhaps it's worth referencing via a script tag on your page and take your tooling out of the equation?
On a side note, I'd noticed a couple of bugs in the documentation that we fixed up:

you no longer need to specify the production: true/false param
expiryMonth should be cardExpirationMonth
expiryYear should be cardExpirationYear

The example README on npm shows the correct payloads now for your reference.

According to WebCryptoAPI
crypto.subtle is supposed to be undefined in insecure contexts
And this logs undefined in my app:
console.log(window.crypto.subtle);

Seems like this is the cause of my error because I am testing in http://localhost.myWorkDomain.com:8022/ but we are not able to change this to https.
Is there no way of creating tokens in a test environment with http?

@jadonald Looks like I was able to add https: true to my devServer settings in vue.config.js and this got it to work. I appreciate your help on this but I think we are good to go now!

Glad to hear @cody-baker!


Add asm var value check.

Currently doesn't check if ALL needed asm vars have values have been set by the user. But at least it errors if none have been set yet.


chore: Add docs for debugging of transactions

Description:
This PR adds a new file debugging-transactions.md to provide detailed guidance on debugging transactions using Remix IDE and the debug_traceTransaction method.
Changes:

Added debugging-transactions.md to the docs directory.
The new documentation includes:

An overview of debugging tools in Remix.
Steps to use the built-in debugger in Remix.
Examples of debugging a transaction using the built-in debugger.
Instructions for manually calling the debug_traceTransaction method.
Examples of using debug_traceTransaction with callTracer and opcodeLogger.

Motivation:
The addition of this documentation aims to help developers effectively debug their smart contracts by providing comprehensive instructions and examples.
Related issue(s):
Fixes #2432
Checklist

[ ] Documented (Code comments, README, etc.)
[ ] Tested (unit, integration, etc.)

Should we use docs:  instead of chore:  for the PR title?


Eda:  better handle single app mode

This PR updates the logic related to singleAppMode in the EDA workspace. Previously, we assumed the first computation in the analysis.descriptor.computations array would match the singleAppMode computation type. The precludes the possibility that the analysis was created in some other context, or that the analysis contains other computations.
Now, we will look for any analysis that matches the singleAppMode type. If one is not found, one will be created before rendering the viz tab. Additionally, singleAppMode is being passed to MapAnalysis, to ensure that the computation is always created when the website is configured to use singleAppMode.
This is to enable using both the EDA Workspace view, and the Standalone Map view, for a single analysis object.
ETA this also addresses an issue with the SAM where a new analysis is not saved when the marker config is updated. This was fixed by adding a way to override the createIfUnsaved argument for the AnalysisState setters.

I think this is because I used a VectorBase map analysis.
We still have this line
      apps = apps.filter((app) => app.projects.includes(projectId));

in ComputationRoute.
So this is likely due to the fact that none of the "vanilla" pass-through visualisations are "allowed" for VectorBase (app.projects)
I'll test with a clinepi back end and then likely approve.

I think this is because I used a VectorBase map analysis.
We still have this line
      apps = apps.filter((app) => app.projects.includes(projectId));

in ComputationRoute.
So this is likely due to the fact that none of the "vanilla" pass-through visualisations are "allowed" for VectorBase (app.projects)
I'll test with a clinepi back end and then likely approve.

I think the problem is that you have REACT_APP_SINGLE_APP_MODE=pass set in your .env.local file. Try to comment that out when using VectorBase.

I think this is because I used a VectorBase map analysis.
We still have this line
      apps = apps.filter((app) => app.projects.includes(projectId));

in ComputationRoute.
So this is likely due to the fact that none of the "vanilla" pass-through visualisations are "allowed" for VectorBase (app.projects)
I'll test with a clinepi back end and then likely approve.

I think the problem is that you have REACT_APP_SINGLE_APP_MODE=pass set in your .env.local file. Try to comment that out when using VectorBase.

I suppose we can log a warning in the developer console, and render the default UI


Hide "pol lsp" subcommand

New output:
> pol
Usage: pol [OPTIONS] <COMMAND>

Commands:
  run     Run the main expression of a file
  check   Typecheck a file
  fmt     Format a code file
  texify  Render a code file as a latex document
  xfunc   De-/Refunctionalize a type in a code file
  lift    Lift local (co)matches of a type to the top-level
  help    Print this message or the help of the given subcommand(s)

Options:
      --trace    Enable trace logging
      --debug    Enable debug logging
  -h, --help     Print help
  -V, --version  Print version

I am undecided on whether I think this is a good idea. For anyone using another editor, it may be helpful to find out how to invoke the lsp server and it's not like there's that many commands at the moment :thinking:
Currently, I would lean towards not hiding it, but I don't feel very strongly about it, so feel free to merge if you do :)

My reasoning is that the help functionality of the pol binary should mainly be for normal human users, not implementors of tools. And anyone who is interested in how to invoke the LSP server will probably either look at how the vscode plugin does it, the code itself, or ask for help. And if you invoke pol lsp on the console yourself you get weird errors like:
> pol lsp

failed to decode message: codec error: missing required `Content-Length` header
Content-Length: 75

{"jsonrpc":"2.0","error":{"code":-32700,"message":"Parse error"},"id":null}%