[BUG] Publisher not able to pick configuration for PREPROD/ACC

Release version
4.8.0
Describe the bug
Hi Team,
I am trying to run extractor and publisher to run ApiOps on API management service as described.
My repository looks like:

For now, we are not using config_files directory for any purpose.
I have changed the publisher code similar to suggested in this previous bug https://github.com/Azure/apiops/issues/197
This is how the changed code looks like:
- task: PowerShell@2
    displayName: Run publisher for ${{ parameters.ENVIRONMENT}} environment
    inputs:
      targetType: "inline"
      script: |
        Set-StrictMode -Version Latest
        $ErrorActionPreference = "Stop"
        $VerbosePreference = "Continue"
        $InformationPreference = "Continue"

        Write-Information "Configuration YAML path is $($env:CONFIGURATION_YAML_PATH)"
        Write-Information "Configuration AZURE_RESOURCE_GROUP_NAME is $($env:AZURE_RESOURCE_GROUP_NAME)"
        Write-Information "Configuration API_MANAGEMENT_SERVICE_OUTPUT_FOLDER_PATH is $($env:API_MANAGEMENT_SERVICE_OUTPUT_FOLDER_PATH)"
        Write-Information "Configuration API_MANAGEMENT_SERVICE_NAME is $($env:API_MANAGEMENT_SERVICE_NAME)"
        Write-Information "Configuration COMMIT_ID is $($env:COMMIT_ID)"

        & "$(PUBLISHER_FILE_PATH)"
        if ($LASTEXITCODE -ne 0) { throw "Running publisher failed."}

        Write-Information "Execution complete."
      failOnStderr: true
      pwsh: true

Below is the output of this part of the code and the logging related to the issue we are facing:
2023-08-22T21:03:09.5659174Z [command]/usr/bin/pwsh -NoLogo -NoProfile -NonInteractive -Command . '/home/vsts/work/_temp/17341838-9553-4cca-9e1a-1df9c22a5d5a.ps1'
2023-08-22T21:03:09.8921081Z Configuration YAML path is /home/vsts/work/1/s/configuration_pub.preprod.yaml
2023-08-22T21:03:09.8931206Z Configuration AZURE_RESOURCE_GROUP_NAME is ACC-APIM-RG
2023-08-22T21:03:09.8937953Z Configuration API_MANAGEMENT_SERVICE_OUTPUT_FOLDER_PATH is /home/vsts/work/1/s/Artifacts
2023-08-22T21:03:09.8944185Z Configuration API_MANAGEMENT_SERVICE_NAME is ACC-APIM-NAME
2023-08-22T21:03:09.8965244Z Configuration COMMIT_ID is
2023-08-22T21:03:10.1649508Z dbug: Microsoft.Extensions.Hosting.Internal.Host[1]
2023-08-22T21:03:10.1650021Z       Hosting starting
2023-08-22T21:03:10.2475920Z info: Publisher[0]
2023-08-22T21:03:10.2476556Z       Beginning execution...
2023-08-22T21:03:10.2501292Z info: Publisher[0]
2023-08-22T21:03:10.2501908Z       Commit ID was not specified, will put all artifact files...
.
.
.
.
2023-08-22T21:03:11.5065039Z info: Publisher[0]
2023-08-22T21:03:11.5065610Z       Putting backend DEV-FUNCTION-APP...
2023-08-22T21:03:11.5073189Z trce: PutRestResource[0]
2023-08-22T21:03:11.5073670Z       Beginning request to put REST resource {
2023-08-22T21:03:11.5074302Z         "properties": {
2023-08-22T21:03:11.5074502Z           "credentials": {
2023-08-22T21:03:11.5074648Z             "header": {
2023-08-22T21:03:11.5074925Z               "x-functions-key": [
2023-08-22T21:03:11.5075171Z                 "{{DEV-FUNCTION-APP-key}}"
2023-08-22T21:03:11.5075313Z               ]
2023-08-22T21:03:11.5075422Z             }
2023-08-22T21:03:11.5075541Z           },
2023-08-22T21:03:11.5075689Z           "description": "DEV-FUNCTION-APP",
2023-08-22T21:03:11.5075835Z           "protocol": "http",
2023-08-22T21:03:11.5076300Z           "resourceId": "https://management.azure.com/subscriptions//resourceGroups/DEV-FUNCTION-RG/providers/Microsoft.Web/sites/DEV-FUNCTION-APP",
2023-08-22T21:03:11.5077265Z           "url": "https://DEV-FUNCTION-APP.azurewebsites.net/api"
2023-08-22T21:03:11.5077418Z         }
2023-08-22T21:03:11.5078098Z       } at URI https://management.azure.com/subscriptions//resourceGroups/ACC-APIM-RG/providers/Microsoft.ApiManagement/service/ACC-APIM-NAME/backends/DEV-FUNCTION-APP?api-version=2022-04-01-preview...
2023-08-22T21:03:11.6659360Z crit: Publisher[0]
2023-08-22T21:03:11.6661064Z       System.Net.Http.HttpRequestException: HTTP request to URI https://management.azure.com/subscriptions/**/resourceGroups/ACC-APIM-RG/providers/Microsoft.ApiManagement/service/ACC-APIM-NAME/backends/DEV-FUNCTION-APP?api-version=2022-04-01-preview failed with status code 400. Content is '{"error":{"code":"ValidationError","message":"One or more fields contain incorrect values:","details":[{"code":"ValidationError","target":"credentials","message":"Property 'DEV-FUNCTION-APP-key' not found."}]}}'.
Expected behavior

All the DEV environment values are replaced with ACC environment values as mentioned in file configuration_pub.preprod.yaml
The publisher run completes publishing correctly and completely.

Actual behavior
It fails because the value for DEV is not replaced with ACC.
Reproduction Steps
Not sure how to reproduce.

This looks like an issue with paths in your own DevOps environment. Unfortunately, we cannot provide support for that.

This looks like an issue with paths in your own DevOps environment. Unfortunately, we cannot provide support for that.

Can you guide how can I try to debug and deep dive to find root cause ?

Check the debug section under our wiki.
Also this step by step guide should get you going.

Hi @waelkdouh
I have reviewed everything on mentioned pages and I am back to the place where I started.
When I remove the configuration file from the repository, then it shows error as "The file not found".
But when I add back the configuration file for PREPROD, it again not considering the configuration value mentioned in the yaml file.
I suspect that probably somehow the configuration file format doesn't satisfy the need.
Can you help me by reviewing the configuration file and let me know in case you have any feedback ?
**apimServiceName: API_INSTANCE_NAME
namedValues:

name: FUNCTION_KEY_NAME
properties:
displayName: FUNCTION_KEY_DISPLAY_NAME
keyVault:
identityClientId: "IdentityClient"
secretIdentifier: "secret"
name: XYZ
properties:
displayName: Logger-Credentials--1234
value: "12065590-"
loggers:

name: applicationinsights
properties:
loggerType: applicationInsights
description: preprod application insights
resourceId: "/subscriptions/subscriptionvalue/resourceGroups/resourcegroupvalue/providers/microsoft.insights/components/Application insight name"
credentials:
instrumentationKey: "{{Logger-Credentials--1234}}"
isBuffered: true
diagnostics:

name: applicationinsights
properties:
verbosity: information
loggerId: "/subscriptions/subscriptionvalue/resourceGroups/resourcegroupvalue/providers/Microsoft.ApiManagement/service/API_INSTANCE_NAME/loggers/applicationinsights"
backends:
name: Function_name
properties:
url: "https://Function_name.azurewebsites.net/api"
resourceid: "/subscriptions/subscriptionvalue/resourceGroups/resourcegroupvalue/providers/Microsoft.Web/sites/Function_name"

apis:

name: epigs
diagnostics:

name: applicationinsights
properties:
verbosity: information
loggerId: "/subscriptions/subscriptionvalue/resourceGroups/resourcegroupvalue/providers/Microsoft.ApiManagement/service/API_INSTANCE_NAME/loggers/applicationinsights"**

@guythetechie any thoughts on this one?

@guythetechie any thoughts on this one?

Hi @waelkdouh @guythetechie
Is the behavior mentioned in https://github.com/Azure/apiops/issues/238 still the same ?
For example, for me below is the case.
Backend configuration for DEV looks like:
backends:

name: dvfun01
properties:
url: "https://dvfun01.azurewebsites.net/api"
resourceid: "/subscriptions/..../resourceGroups/dvrg01/providers/Microsoft.Web/sites/dv*fun01"

Backend configuration for ACC looks like:
backends:

name: ppfun01
properties:
url: "https://ppfun01.azurewebsites.net/api"
resourceid: "/subscriptions/..../resourceGroups/pprg01/providers/Microsoft.Web/sites/pp*fun01"

Where, dv represents Development and pp represents Pre-prod.

@umashankar337 , when you are importing the LogicApp or function app to APIM it will automatically create this integration key as a secret named value. Below are the key points.

When any named value is created as secret you have to mandatory override in the environment configuration file else publisher will skip it.
If your named values are fetching values from AKV you have to first create the values in the destination AKV and give the secret identifier in environment config file.

In your case apply the first point and it will resolve the issue.

@umashankar337 , when you are importing the LogicApp or function app to APIM it will automatically create this integration key as a secret named value. Below are the key points.

When any named value is created as secret you have to mandatory override in the environment configuration file else publisher will skip it.
If your named values are fetching values from AKV you have to first create the values in the destination AKV and give the secret identifier in environment config file.

In your case apply the first point and it will resolve the issue.

Hi @nepsmaddy @waelkdouh , thanks for the explanations.
In our case, we are going to use AKV to fetch the secret values.
If I understood correctly, then we expect below from above 2 scenarios:
For first scenario, we need values in below named value:
- name: mysecretvalue
properties:
displayName: mysecretvalue
keyVault:
identityClientId: [identity client id goes here]
secretIdentifier: [your url here]
And for first scenario, the secret identifier in the key vault should be already created for higher environments for which we are running the deployment, Right ?
And in second scenario, we need values for below 2 named values:
_- name: testSecret
properties:
displayName: testSecret
value: "{#testSecretValue#}"

name: helloworldfromfuncapp-key
properties:
displayName: helloworldfromfuncapp-key
value: "{#helloworldfromfuncappkey#}"_

Please correct me if I am missing something here !

In the case of Azure Key Vault you will need to make sure that the keyvault already exists in the target environment. Then you will need to provide the required information like the identityClientId and secretidentifier in the configuration file as you stated above. Now keep in mind that the information you need to provide will differ depending on whether you are using system assigned or user managed identity. In the example below I am using a system assigned managed identity and notice that I only had to provide the secretIdentifier without having to pass the identityClientId.

It is getting complicated now :| I will look into it and come back with result

It's really not that complicated. Make sure you look at the extracted artifacts, which typically shows you which properties were extracted so you can easily tell which properties you need to override and the configuration file.

It's really not that complicated. Make sure you look at the extracted artifacts, which typically shows you which properties were extracted so you can easily tell which properties you need to override and the configuration file.

This is how the backend section look like after extracted.
{
"properties": {
"credentials": {
"header": {
"x-functions-key": [
"{{dvfun01-key}}"
]
}
},
"description": "*****dv****fun01",
"protocol": "http",
"resourceId": "https://management.azure.com/subscriptions/..../resourceGroups/dvrg01/providers/Microsoft.Web/sites/dvfun01",
"url": "https://dvfun01.azurewebsites.net/api"
}
}

@waelkdouh @nepsmaddy
In the named value area, I think the pipeline still not able to find the change of variables.
For example: the loggings shows below
dbug: Microsoft.Extensions.Hosting.Internal.Host[2]
Hosting started
warn: Publisher[0]
Named value dv is secret, but no value or keyvault identifier was specified. Skipping it...
warn: Publisher[0]
Named value *****dv****fun01-key is secret, but no value or keyvault identifier was specified. Skipping it...
Unless, this understand that we want *****ppfun01-key instead of *****dvfun01-key, this is not going to work I assume.
I have changed my config file as below but it still doesn't work for me:

name: x-functions-key
properties:
displayName: x-functions-key
value: "{#HeaderSecretValue#}"
name: *****ppfun01-key
properties:
displayName: *****ppfun01-key
value: "{#KeySecretValue#}"

I am passing these values via my variable group, which is showing correct value under the step Perform name value secret substitution.
Please help me what is going wrong here.

In a simple term if your named value is secret and you want to publish it using publisher, you must override it and give value as a variable in {#Variable1#} syntax and it will work correctly.
@waelkdouh , please correct my understanding please.

In a simple term if your named value is secret and you want to publish it using publisher, you must override it and give value as a variable in {#Variable1#} syntax and it will work correctly.
@waelkdouh , please correct my understanding please.

I understood that. But the problem is, the name and resource ID of the backend is also not getting updated via config file.
The publisher is changing the subscription ID, Resource group etc.
But when it comes to the backed service name (azure function) which is  different in different environment, the publisher not picking up that from the config file.
Below is the logging when I run publisher for PP environment:
2023-08-23T20:13:42.7875260Z info: Publisher[0]
2023-08-23T20:13:42.7875749Z       Putting backend ***dv**fun01...
2023-08-23T20:13:42.7888498Z trce: PutRestResource[0]
2023-08-23T20:13:42.7888891Z       Beginning request to put REST resource {
2023-08-23T20:13:42.7889103Z         "properties": {
2023-08-23T20:13:42.7889249Z           "credentials": {
2023-08-23T20:13:42.7889376Z             "header": {
2023-08-23T20:13:42.7889697Z               "x-functions-key": [
2023-08-23T20:13:42.7889918Z                 "{{dvfun01-key}}"
2023-08-23T20:13:42.7890060Z               ]
2023-08-23T20:13:42.7890179Z             }
2023-08-23T20:13:42.7890284Z           },
2023-08-23T20:13:42.7890455Z           "description": "dvfun01",
2023-08-23T20:13:42.7890597Z           "protocol": "http",
2023-08-23T20:13:42.7891057Z           "resourceId": "https://management.azure.com/subscriptions/DEV-SUBS-ID/resourceGroups/DEV-RESOURCE_GROUP/providers/Microsoft.Web/sites/dvfun01",
2023-08-23T20:13:42.7891356Z           "url": "https://dvfun01.azurewebsites.net/api"
2023-08-23T20:13:42.7891507Z         }
2023-08-23T20:13:42.7892165Z       } at URI https://management.azure.com/subscriptions/**PP-SUBS-ID**/resourceGroups/**PP-RESOURCE_GROUP**/providers/ Microsoft.ApiManagement/service/ API-INSTANCE/backends/***dv**fun01?api-version=2022-04-01-preview...
2023-08-23T20:13:43.0954545Z crit: Publisher[0]
2023-08-23T20:13:43.0956918Z       System.Net.Http.HttpRequestException: HTTP request to URI https://management.azure.com/subscriptions/PP-SUBS-ID/resourceGroups/PP-RESOURCE_GROUP/providers/ Microsoft.ApiManagement/service/ API-INSTANCE/backends/dvfun01?api-version=2022-04-01-preview failed with status code 400. Content is '{"error":{"code":"ValidationError","message":"One or more fields contain incorrect values:","details":[{"code":"ValidationError","target":"credentials","message":"Property '*****dvfun01-key' not found."}]}}'.
I am not able to understand why it is still trying to create *****dvfun01 and *****dvfun01-key and not *****ppfun01 and *****ppfun01-Key ! These values are replaced on the config file.

If there is anything that can be set from the policy XML file which needs to change across environments, then using named values in the policy files will help. Let us know if this solves your issue in this case.

Yes. We added support for couple more artifacts to filter by. There is also a pending PR which will allow filtering by policy fragments. But else mentioned there still applies.

@umashankar337 - to add to the comments, there's a distinction between resource names and resource properties.
Resources are things like APIs, backends, named values, loggers, etc. Their names should be consistent across environments. Their properties however can be overridden across environments through configuration.
In your scenario, a named value is a resource. Its name should be consistent across environments (fun01-key, for instance). Its value (properties.value) is a property that can be overridden.
Note that APIM sometimes relies on the display name property (properties.displayName) of a resource rather than just its name. Named values used in policies fall in that category, for instance. In those cases, I would recommend keeping both name and properties.displayName consistent across environments.

@umashankar337 - to add to the comments, there's a distinction between resource names and resource properties.
Resources are things like APIs, backends, named values, loggers, etc. Their names should be consistent across environments. Their properties however can be overridden across environments through configuration.
In your scenario, a named value is a resource. Its name should be consistent across environments (fun01-key, for instance). Its value (properties.value) is a property that can be overridden.
Note that APIM sometimes relies on the display name property (properties.displayName) of a resource rather than just its name. Named values used in policies fall in that category, for instance. In those cases, I would recommend keeping both name and properties.displayName consistent across environments.

@guythetechie That's the comment/information i was looking for. Thanks alot.
I feel this is a very important information and should be mentioned clearly in the documentation.

@umashankar337 where do you feel in the docs it would have been easiest for you to locate? Once I hear from you I will go ahead and update the docs. Thanks for the suggestion.

@umashankar337 where do you feel in the docs it would have been easiest for you to locate? Once I hear from you I will go ahead and update the docs. Thanks for the suggestion.

@waelkdouh
I feel this information is a requirement/pre-requisite for anyone who wants to use this approach.
From that point of view, I would add this information on the page https://github.com/Azure/apiops/blob/main/docs/apiops/0-labPrerequisites/apim-prereq-0-1.md with a highlight as an assumption

@umashankar337 we ended up adding a FAQ in the wiki section which you can find here.

@waelkdouh Thanks for quick action.
Frankly from my point of view I am not fully convinced about, if that place is the suitable for this information.
People might still spend a lot of time before they referred to this FAQ section. But you can change the location of this info later or add in multiple places if more requests coming in I think.
for now, this answers my questions.

@umashankar337 I moved the docs to the following location which should make it easier to locate.

You can find it here

@waelkdouh Finally, just now, I could complete the deployment to my first higher environment. Thanks for your support.


Abnormal behavior with Redisearch - The clauses HIGHLIGHT, and SUMMARIZE do not do their job.

It happens with the following query that I have already tested to be correct and working as expected with redis-cli and concurrent node-redis:
FT.SEARCH myindex @d:"some text" RETURN 3 t d da SUMMARIZE FIELDS 1 d HIGHLIGHT FIELDS 1 d
Replacing the triplet of fields (t, d, da) with this one: (t, d, to), then the result returned by the server is as expected, that is with the summary and the highlighting of the d field.
Could it be that there is a bug in ioredis for which fields with names d, and da somehow give a problem?

Hey @Lucabenj 👋 ,
Sorry for the late reply! ioredis doesn't interpret any arguments and just passes them directly to the server. Can you show the code which has the issue?


Preliminary XML support

This commit adds preliminary support for XML dataset import and export (no databook yet). The code uses only Python's internal libraries and works on both Python 2 and 3. It supports reading XML datasets with data saved as element or as attributes. I am sure the code has a lot of room for improvement, but I prefer to get some early feedback before finishing up.

This library has had a joke in the documentation that "xml will never be supported". :)
I enjoy this joke, and it would entertain me to see it remain true. But, it can easily be removed instead.

I haven't executed the code, but the approach looks relatively sensible. Do you think having xml in/out will be useful, even though the various forms it takes are so variable?

Haha, I am aware of the joke. We will try to find another format to denigrate once this is done (let's say RDF)!
Actually most datasets provided in XML format come in two pretty simple flavours: 1) One record per line, fields as attributes (like stack exchange data dump), and 2) Records as elements, fields as sub-elements. In my experience many XML data dumps are either already in one of these formats or can be reduced to one of these with a simple XPath.
My objective, if I have time, is to support these two formats first. Then we can add XPath support in a later version. That is exactly what Google Sheets does, and I have found it largely sufficient for most data imports.
For now the data read code snippet is a bit buggy, but it reads 70-80 percent of the files I have tried in the two formats I just mentioned. The XML writer must be more robust -- I spent some time on it this morning.
I sincerely hate dealing with XML files, and that is why I am writing this: I just want to be able to turn them into other less finicky formats with as little hassle as possible. I am more of a data analyst than a programmer, and I think such a tool can be very useful for people like me.

We support RDF too! Don't worry, we'll think of something ;)
This is great work – I'm excited about it. If there's anything I can do to support the process, please let me know!

Just let me know if I have to respect some conventions that you have abided by in the code up to now. I am pretty excited too: Finally I will have one data interchange package for all my needs (or most of them at least...)!


Add Cloud RMs

See @zankner's repo https://github.com/zankner/CLoud, RM's that think out loud!

Hi @natolambert, I recently trained a generative RM (prometheus-eval/prometheus-RM-Llama-8B-v1.0) based on the CLoud code base and l think the inference using the huggingface transformers can be easily integrated to existing code of reward-bench. Can I try working on this?

@scottsuk0306 yes please! I've been curious for a bit and we're building new datasets now

Hi sorry realized I never followed up on this. @scottsuk0306 @natolambert we support HF inference in the CLoud repo which I can also add (hf-inference). However, HF generate is extremely slow. More recently we added vllm-support but I'm not sure whether that would be easy to support in your repo, if you have any thoughts.

We could try running Cloud RM with the "generative" pipeline, which is a bit different.
Otherwise, I feel like it isn't needed to use VLLM, unless we can figure out how to wrap it in the same abstraction -- which actually may be possible, because we just do some general model loading.
Either way, curious where we end up.


code is not sent

code is not sent to email

Dude, you already opened an issue, there's no need to make another, it's rude.
(P.S, I got an email with my code as I was supposed to.)
You're looking for an email with the title "Verify Your Account"

i dnt recvd any email with the code
On Sat, Nov 3, 2018 at 11:36 AM Ben<EMAIL_ADDRESS>wrote:

Dude, you already opened an issue, there's no need to make another, it's
rude.
(P.S, I got an email with my code as I was supposed to.)
You're looking for an email with the title "Verify Your Account"
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
https://github.com/ifedapoolarewaju/igdm/issues/706#issuecomment-435562463,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AqSsPTntOK2S05gJWvO4_48_rcs66Cdoks5urStrgaJpZM4YMozP
.


Rebuild for Python 3.7, GCC 7, R 3.5.1, openBLAS 0.3.2

Fixes #4

Hi! This is the friendly automated conda-forge-linting service.
I just wanted to let you know that I linted all conda-recipes in your PR (recipe) and found it was in an excellent condition.
I do have some suggestions for making it better though...
For recipe:

Whenever possible python packages should use pip. See https://conda-forge.org/docs/meta.html#use-pip

@conda-forge-admin, please re-render.

Hi! This is the friendly automated conda-forge-webservice.
I tried to patch-1 for you, but it looks like I wasn't able to push to the xhochy branch of static-feedstock/re-render. Did you check the "Allow edits from maintainers" box?

Thanks @xhochy :)

@conda-forge-admin, please update circle.
As code checkout failed on CircleCI. This combined with a restart should fix that issue.

Hi! This is the friendly automated conda-forge-webservice.
I just wanted to let you know that I updated the circle-ci deploy key and followed the project.


[AMORO-6789]Memory leaks when using mix -hive format to write parquet files.

Fix bug that memory leaks when using mix -hive format to write parquet files.

Why are the changes needed?

To avoid writing tasks causing memory leak when write a mix-formatted table. Details refers to issue pls.
Close #2789 .
Brief change log

add logic of release a compressor to pool after finishing writing a file.

How was this patch tested?

[ ] Add some test cases that check the changes thoroughly including negative and positive cases if possible

[ ] Add screenshots for manual tests if appropriate

[X] Run test locally before making a pull request

Documentation

Does this pull request introduce a new feature? (no)
If yes, how is the feature documented? (not applicable)

@zhoujinsong TBR


APIM 2.1.0 not updated("WSS API Advanced Throttling Policy details")

Description:
"WSS API Advanced Throttling Policy" can we apply on apim-2.1.0. This feature is already in apim-2.6.0 and doc is updated for that. But for the apim 2.1.0 doc is not contain that "WSS Support" related details. I already test for apim-2.1.0 with steps on 2.6.0 doc it is working fine.
Suggested Labels:
apim,wss
Suggested Assignees:
@Mariangela
Affected Product Version:
apim-2.1.0
Steps to reproduce:
Related Issues:

Added this content in the following pages.

https://docs.wso2.com/display/AM210/Create+a+WebSocket+API
https://docs.wso2.com/display/AM220/Create+a+WebSocket+API
https://docs.wso2.com/display/AM250/Create+a+WebSocket+API

Updated the content in APIM 2.6.0

https://docs.wso2.com/display/AM260/Create+a+WebSocket+API

Added the content in for 3.0.0 with PR [2].
[1] https://apim.docs.wso2.com/en/latest/Learn/DesignAPI/CreateAPI/create-a-websocket-api/
[2] https://github.com/wso2/docs-apim/pull/438


Add support for squashing final image

This adds support for --squash as a command-line and a configuration option. If specified, it will pass --squash along down to buildah commit while committing the final layer. This will squash the resulting image down to one layer.

@TomasTomecek Sure! I've been in crunch time this past week, though, and I'll be at OSSNA next week so it might be a little bit before I get back to this.

No worries, thanks for update!
I'm working on support for docker and podman (which is a shit-ton of work to be honest) and tests like these will be crucial to figure our if all three container runtimes work well. I can write that test if you won't have time for it - definitely want to merge this before I open my PR.

@TomasTomecek Yeah, I won't have time to take another swing at this until the 26th at earliest so if you want the test before then I must apologize for pushing it back on you :)

no worries, writing tests is easy and fun! :)

Merging, will open a PR with the tests.

Sorry I never got back to this! My work in this area has currently been preempted by another project.

Sorry I never got back to this! My work in this area has currently been preempted by another project.

No worries, this happens to me constantly. Aren't you by any chance at AnsibleFest?

Aren't you by any chance at AnsibleFest?

No, I'm at home, I went to OSSNA this year.


Removal of Admin features

As a lot of admin features will be handled using Git later on, it is unclear as to what features will be required in the front-end. This is a breakdown of my current understanding, and any clarification would be much appreciated. I will create a PR after to follow up and make the appropriate changes.
Unsure:

Assessments
Students
Path Submissions
Achievements
DGs
Libraries

Needed:

Grading

Not needed:

Materials

Hi Prof @martin-henz . With respect to our last meeting, it seems that majority of the content is going to be outsourced to IVLE. Then, do you think we could remove the Admin segment completely?

I've open a discussion at backend's #52, since they may be involved in this change.

Regarding the Admin segment: We may need ways to keep track of the progress of assessment submission and marking:

assessment submission progress: how many students have submitted on time, how many have not submitted, reminders of submission etc. There may be a need for a frontend for that
overdue assessment marking progress: how many submissions have been marked already? How many still need to be marked, reminders of marking. Same: a simple frontend may be required
leaderboard/progress info: We will need a way to consolidate the student progress in the missions so that we can spot students who fall behind.

As discussed in today's meeting, the admin interface will be removed, as site administrator features such as the creation and management of news and material will be managed through an IVLE interface, and dispatched to the frontend via backend API call.
This does not imply the removal of an 'instructor' interface, which handles grading. We note that the assessments listed in the instructor interface should correspond to their roles:

Administrators (essentially, the professors) should be able to view and sort meaningfully all assessments
Graduate students should be able to view assessments from students assigned to them for grading
Avengers/TAs should be able to view (and grade?) assessments from students belonging to their studio group

This issue will be closed with the removal of the admin interface.


Fix colliding option values

Hopefully, removing blank lines between the options and moving the comments to the right margin helps avoid this kind of mistake in the future.
Fixes #1171

Merged, thanks!


[Event Request] Codeunit 11, 80, 90 and more

In posting and check codeunits, the CheckDimValuePosting will be called with a generated TableID/NoArray
Since most CreateDim functions now allow to add own dimension source tables via
OnAfterCreateDimTableIDs(Rec,CurrFieldNo,TableID,No); there should be the possibility to extend the check .
(If you Setup that master data XY must be posted with Dimension X Value Y, this should be checked here.)
TableID[5] := DATABASE::Campaign;
No[5] := "Campaign No.";
OnAfterCreatedTableDims(GenJnlLine,TableID,No); // NEW
IF NOT DimMgt.CheckDimValuePosting(TableID,No,"Dimension Set ID") THEN
ThrowGenJnlLineError(GenJnlLine,Text012,DimMgt.GetDimValuePostingErr);
should allow this.
There are several positions where this Publisher should be added.
CU 11:
CU 80, 90,  CheckDimValuePostingHeader, CheckDimValuePostingLine
CU 1011 and many more

I totally missed the Test-Reports.
Perhaps it would be possible to create a "CreateDimArray" function for, say, the Sales Header, and use it on all other places?
An Extension can subscribe to a Publisher in the CreateDimArray -Function, and
Checking Codeunits, Test Reports, CreateDim will work correctly, no one will forget one place :)

Nice, thank you. Is there a possible date, when this change will be available in daily builds?


How to add an Authorization layer to Client or RequestBuild ?

When looking at the google API implementations, you usually see the pattern that services are instantiated with an http client, through which all requests will be performed. Authorisation is handled through a special version of an HTTP-Client, which will insert the respective headers on the fly and even refresh expired tokens when needed.
As Client has no trait, and as the only things I can affect are the NetworkConnector and NetworkStream, both of which don't have access to the Header anymore, I wonder how I would best achieve that without working around Hyper entirely, in that case.
Sorry again for posting a question here, just let me know if you would like me to re-post on StackOverflow.
Thank you

Actually hyper does not have a function to provide authorisation. But you can create a new client by wrapping client and passing all functions down to the original client.
Pseudocode:
pub struct AuthClient{
  client: hyper::Client,
  credentials: Credentials,

impl AuthClient {
// All the same methods as hyper::Client plus some for auth
}

Thank you.
But how would aggregation work within generics ? The APIs I write use generics a lot, and these need traits.
Unfortunately, there is no Client trait yet.
Even better than that would be if there was a RequestBuilder trait, and a generic parameter for it in the Client. That way, I could sneak in my own which could insert the respective headers.
Maybe something along the lines of this:
pub struct Client<C, B: Builder> {
    connector: C,
    redirect_policy: RedirectPolicy,

   _m: PhantomData<B>,
}

Just for the record
The original issue was not solved. A hyper Client is missing a trait, which makes it more difficult to implement new kinds of Clients, some of which may automatically deal with authentication under the hood.
As the RequestBuilder is finally issuing the send() call, it would also be sufficient to be able to replace the RequestBuilder with an own implementation, possibly by adding a generic parameter for it in the Client type. After all, most people would want to inject an Authorization header field.
Closing the issue without actually dealing with the described problem is behaviour I do not approve of. In case the point made here is not clear or faulty, then this was not made clear in the previous communication either.

Hey @Byron, if you feel like there's more to discuss to have in this issue, I'm happy to reopen. I noticed that @seanmonstar closed this, but the issue also looked resolved to me as @pyfisch told you what to do in this case. On closer inspection, I can see how the solution is not entirely satisfactory.
I agree that there's definitely more to do in terms of API surface to allow more complex modifications or extensions to Client and RequestBuilder, but that seems only tangentially related to this issue. I'd rather open another issue and link to this one from there though, since the major point of this issue has sort of been dealt with. Sound good?

Considering I didn't (even) get the subject's grammar right, I'd be happy if you would open an issue that is more to the point, the way you see it by now.
After all, I still believe that hyper can improve in the realm of extensibility, and should pursue this path further.
Thank you

Filed #378 :)

@Byron sorry, I didn't mean to just shrug this off. I read @pyfisch's response and felt it was sufficient.

As for this specific case, I don't think Client nor RequestBuilder require traits. I don't believe they need to be generic over something. I'll show how I would imagine adding an Auth (and any other kind of extension) to the Client.
Similar in nodejs, where there is the request package on npm, and http as a standard module, I'd imagine people could build specialized clients on top of the one hyper provides. For instance, with request, you can write:
var request = require('request');

request.post({
  url: 'https://example.domain/path',
  auth: someAuthValue
}).pipe(process.stdout);

I'd imagine a specialized client looking like this:
struct Client {
    inner: hyper::Client,
    auth: String
}

impl Client {
    fn request(&mut self, method: hyper::Method, url: url::Url) -> hyper::client::RequestBuilder {
        self.inner.request(method,url)
            .header(hyper::header::Authorization(self.auth.clone()))
    }
}

You could imagine any sorts of options that a specialized client could handle, such as oauth, json, tunnel, gzip, hawk, multipart, etc. Actually, there is already a multipart crate using hyper.

@seanmonstar It's alright :) - I might have been reacting a bit strongly to this too, had a bad day.
The reason I seem to be so much into having a Client trait  primarily because I see the Go code for youtube APIs which is happy just with an OAuth-enabled client. I thought it might be a wrong move to enforce my own Trait to make that usable with generics, and would have preferred such a 'tool' to be delivered by hyper.
func New(client *http.Client) (*Service, error) {
	if client == nil {
		return nil, errors.New("client is nil")
	}
	s := &Service{client: client, BasePath: basePath}
	s.Userinfo = NewUserinfoService(s)
	return s, nil
}

By now I feel differently about it. Currently I just take a hyper-client and an authenticator, which takes care about providing tokens for authentication. That looks very much like this and feels OK to me, at least on the client side.
On the side of the implementor, you see that not having a Client trait forces me to carry around the NC type parameter. Maybe there are other ways to get rid of it though ... after all, I am only interested in the hyper client and don't care what connection mechanism it might use.
Maybe some day there will be a clear idea on how these cases can and should be tackled, and we do the right thing™ to our APIs to make them as nice and easy to use as possible.

I see. That's no fun carrying around that generic, since you don't care about it. Client could be changed to have Client { connector: Box<NetworkConnector>, .. } instead of being generic. That would mean dynamic calls instead of static dispatch for everyone, though.

Though, we already do this for Request and Response, for the exact same reason: so people don't have worry about the exact type of the Stream underneath... and it doesn't seem to be a source of slowness.

Compared to the cost of other operations, mainly io, the virtual calls seem to not matter at all.


Please Add Support For langfuse and maybe for other similar type of foss solutions which help us in get analytics for our usage of api it will be very helpful for all :-))

Validations

[X] I believe this is a way to improve. I'll try to join the Continue Discord for questions
[X] I'm not able to find an open issue that requests the same enhancement

Problem
Problem is that in max llm supported solutions there is no analytics option in which user can see how many times he has used per day or per week and how much it cost and what all processing happens for each query in backend plus for billing alert etc there needs to be a solution and thankfully there are solutions now out of which for me langfuse did great job i can add more foss similar solution to list for addition too if needed
Solution
Just like google serper integration we need  integration with langfuse.You can read there docs. This will help us in having analytics of our usage of different api of llms. langfuse is pretty great solution and we can selfhost and integrate with other solution. I have personally tested it with flowise by connecting it with some keys and other things which langfuse need and i pretty much loved it.You can study and selfhost too freely and see how useful it can be :-))
Thankyou

Any news on this? This would be very helpful to keep track of uses, statistics...

This would be game changer!


Help with error in navigation. (Smoother server and localization server sometimes giving trouble when trying to launch navigation)

Robot Model
Turtlebot4 Standard
ROS distro
Humble
Networking Configuration
Discovery Server
OS
Ubuntu 22.04
Built from source or installed?
Installed
Package version
Newer one
Type of issue
Networking
Expected behaviour
I expect the robot to launch everytime without trouble localization and nav2 launch file...
Actual behaviour
Sometimes, I can launch without trouble localization and nav2, but sometimes, I get an error showing timeouts in the smoother server (in the case of nav2), and in localization I get another server error.
Error messages
[smoother_server-2] [WARN] [1700600845.157126823] [smoother_server.rclcpp]: failed to send response to /smoother_server/change_state (timeout): client will not receive response, at ./src/rmw_response.cpp:154, at ./src/rcl/service.c:314

To Reproduce
Run localization
Run Nav2
Other notes
This kind of error did not happen when I had the turtlebot4 in simple discovery, but some other errors happened did happen really often, which involved network connection issues from the iCreate3 base. That is why I changed to discovery server. This setting helps the communication by making it faster and more reliable, but I often get the error shown above, and to fix it I just reboot the robot several times until it works again, sometimes I do not require to do this because it works seamlessly the first time. This behavior brings inconsistency and uncertainty to my project, and that is why I would appreciate a lot if you can show me how to fix it or explain to me why does this happen. An important note is that I always connect via ssh to the robot and launch everything here, which is why I think my computer has not anything to do with the error. I am not that much of a ROS2 expert, which is why I require your help. Thanks a lot btw.

Hi there @alexdo105
Can you please provide full terminal outputs of what you are running.
Also please provide journalctl -b > turtlebot4_log.txt
Thanks,
Rusty

Closed due to no activity


dosocs setup (INHERIT += "dosocs") does fail

AGL master (Halibut rc2) , add feature agl-fossdriver, change INHERIT to "dosocs" ( aka yocto build of dosocs)
ERROR: glibc-2.28-r0 do_spdx: Function failed: do_spdx
"
ERROR: glibc-2.28-r0 do_spdx: Could not invoke dosocs2 oneshot Command '/home/scratch/AGL/repobuild-fossology/build-q64-dosocs-local/tmp/work/corei7-64-agl-linux/glibc/2.28-r0/recipe-sysroot-native/usr/bin/dosocs2 oneshot /home/scratch/AGL/repobuild-fossology/build-q64-dosocs-local/tmp/work/corei7-64-agl-linux/glibc/2.28-r0/spdx_temp/git' returned 1:
b'dosocs2: /home/scratch/AGL/repobuild-fossology/build-q64-dosocs-local/tmp/work/corei7-64-agl-linux/glibc/2.28-r0/spdx_temp/git: package_id: 5
dosocs2: running nomos on package 5
Traceback (most recent call last):
File /home/scratch/AGL/repobuild-fossology/build-q64-dosocs-local/tmp/work/corei7-64-agl-linux/glibc/2.28-r0/recipe-sysroot-native/usr/bin/dosocs2, line 11, in
load_entry_point('dosocs2==0.16.1', 'console_scripts', 'dosocs2')()
File /home/scratch/AGL/repobuild-fossology/build-q64-dosocs-local/tmp/work/corei7-64-agl-linux/glibc/2.28-r0/recipe-sysroot-native/usr/lib/python3.5/site-packages/dosocs2/dosocs2.py, line 336, in main
package = do_scan(**kwargs)
File /home/scratch/AGL/repobuild-fossology/build-q64-dosocs-local/tmp/work/corei7-64-agl-linux/glibc/2.28-r0/recipe-sysroot-native/usr/lib/python3.5/site-packages/dosocs2/dosocs2.py, line 143, in do_scan
scanner.run(**scanner_kwargs)
File /home/scratch/AGL/repobuild-fossology/build-q64-dosocs-local/tmp/work/corei7-64-agl-linux/glibc/2.28-r0/recipe-sysroot-native/usr/lib/python3.5/site-packages/dosocs2/scannerbase.py, line 131, in run
processed_files[file] = self.process_file(file)
File /home/scratch/AGL/repobuild-fossology/build-q64-dosocs-local/tmp/work/corei7-64-agl-linux/glibc/2.28-r0/recipe-sysroot-native/usr/lib/python3.5/site-packages/dosocs2/scanners/nomos.py, line 54, in process_file
output = subprocess.check_output(args)
File /home/scratch/AGL/repobuild-fossology/build-q64-dosocs-local/tmp/work/corei7-64-agl-linux/glibc/2.28-r0/recipe-sysroot-native/usr/lib/python3.5/subprocess.py, line 316, in check_output
**kwargs).stdout
File /home/scratch/AGL/repobuild-fossology/build-q64-dosocs-local/tmp/work/corei7-64-agl-linux/glibc/2.28-r0/recipe-sysroot-native/usr/lib/python3.5/subprocess.py, line 383, in run
with Popen(*popenargs, **kwargs) as process:
File /home/scratch/AGL/repobuild-fossology/build-q64-dosocs-local/tmp/work/corei7-64-agl-linux/glibc/2.28-r0/recipe-sysroot-native/usr/lib/python3.5/subprocess.py, line 676, in init
restore_signals, start_new_session)
File /home/scratch/AGL/repobuild-fossology/build-q64-dosocs-local/tmp/work/corei7-64-agl-linux/glibc/2.28-r0/recipe-sysroot-native/usr/lib/python3.5/subprocess.py, line 1289, in _execute_child
raise child_exception_type(errno_num, err_msg)
FileNotFoundError: [Errno 2] No such file or directory: '/usr/local/share/fossology/nomos/agent/nomossa'
'
ERROR: glibc-2.28-r0 do_spdx: Function failed: do_spdx

Cross-reference: https://jira.automotivelinux.org/browse/SPEC-2624

I have updated dosocs.bbclass, can you have try again?


Fix peer dependency issues in gestalt

Previously:

Now:

This change fixes 3 of our 5 peer dependency issues by upgrading stylelint and jest-puppeteer to the latest versions.

Deploy preview for gestalt ready!
Built with commit 7009da815db1c487652c11e96868f805939a4014
https://deploy-preview-260--gestalt.netlify.com

Deploy preview for gestalt ready!
Built with commit 8f2bd897a5b6ff28a3dd772f538e1a9863549b52
https://deploy-preview-260--gestalt.netlify.com

Codecov Report

Merging #260 into master will not change coverage.
The diff coverage is n/a.

@@           Coverage Diff           @@
##           master     #260   +/-   ##
=======================================
  Coverage   70.55%   70.55%
=======================================
  Files          45       45
  Lines         815      815
  Branches      188      188
=======================================
  Hits          575      575
  Misses        169      169
  Partials       71       71

Continue to review full report at Codecov.

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


Clarification - are keys needed to run cardano-submit-api

Hello
On https://github.com/input-output-hk/cardano-node/tree/master/cardano-submit-api it says:

You will need some a cardano network with payment address and keys.

I'm assuming that this is required to construct a tx and then send contructed tx to the submit-api, but not actually required to run the api. Can someone please confirm, or correct me on this assumption?
I'm a little concerned that I may need to have sensitive info (keys) on a server if I wish to run the cardano-submit-api.
Remote sending of transactions
The examples given on the README.md all use the cli, and therefore assume the transaction is constructed locally.

Do you have any examples sending a transaction over Http?
Does the cardani-submit-api need to be explicity installed, or is it part of the cardano node?
Is there an official Cardano or IOHK docker image that has the cardani-submit-api installed?

I'm assuming that this is required to construct a tx and then send contructed tx to the submit-api, but not actually required to run the api.

Yes, that's correct - submit API simply accepts tx sent via POST requests and submits it to node , running submit-api does not need key itself. That is only needed on your local machine where you're constructing the transaction.

Do you have any examples sending a transaction over Http?

Transaction can be created on local machine, and submitted to submit API using curl command shown in example (for production, you'd ofcourse want to secure the endpoint with https atleast).

Does the cardani-submit-api need to be explicity installed, or is it part of the cardano node?

Part of node (if using cabal install/build commands)

Is there an official Cardano or IOHK docker image that has the cardani-submit-api installed?

The current docker might be outdated, see PR here

Ok, this is very helpful, and really appreciate the prompt reply.
One more question. What is the difference between the cardanio-submit-api and cardano-wallet-api?

wallet is to query a full node wallet (eg: daedalus, or a custodial service) where keys are held locally on the server. IMO - it has very limited use cases for developer/builders
submit-api allows you to submit constructed transactions (eg: via CLI or serialisation-lib ) remotely, in this case transaction could even be created offline.

Thank you again.
It should like submit-api  is what I am looking for.
Thank you.


npm tasks don't run sync / work as blTask

I am trying to build a deploy task chain with npm run build in
but shipit always continues before the build process is complete.
are there some other techniques to do with making blocking tasks?
  shipit.blTask('build', function () {
    shipit.log('local build')
    shipit.local('npm run build').then(
      console.log('finished build')
    )
  })

this will immediately print finished build
then sometime later the output from the build process is actually finished.
some more basic shell commands do seem to block properly, and I can even use async
  shipit.blTask('checkDir', async function () {
    let cmd = 'mkdir -p ' + destDir
    shipit.log('cmd', cmd)
    await shipit.remote(cmd)
    shipit.log('mkdir done')
  })

this works as expected.
FWIW my output and script is below
➜  papp git:(toolbar) ✗ shipit prod deploy

Running 'deploy' task...

Running 'build' task...
local build
Running "npm run build" on local.
finished build
Finished 'build' after 33 ms

Running 'checkDir' task...
cmd mkdir -p /opt/rikai/bot-env/tutor/public/static
Running "mkdir -p /opt/rikai/bot-env/tutor/public/static" on host "tutor.XXXXXXX.com".
syncCheck done
Finished 'deploy' after 105 ms
@
@ ><EMAIL_ADDRESS>build /Users/dc/dev/rikai/tutorbot/papp
@ > node build/script.build.js
@
@tutor.XXXXXXX.com-err Ubuntu 14.04.5 LTS
@  WARNING!
@  Do NOT use VueRouter's "history" mode if
@  building for Cordova or Electron.
@
@  Cleaned build artifacts.
@
@  Building Quasar App with "mat" theme...
@
start sync
Finished 'checkDir' after 4.01 s

Running 'sync' task...
sync to  /opt/rikai/bot-env/tutor/public/static
Copy "dist" to "ubuntu@tutor.XXXXXXX.com:/opt/rikai/bot-env/tutor/public/static" via rsync
@tutor.XXXXXXX.com-err Ubuntu 14.04.5 LTS
sync done
Finished 'sync' after 4.3 s
@ Total precache size is about 1.48 MB for 23 resources.

@  * Reduced size by 23.67%, from 176.76kb to 134.92kb.
@
@  Build complete with "mat" theme in "/dist" folder.
@
@  Built files are meant to be served over an HTTP server.
@  Opening index.html over file:// won't work.
➜  papp git:(toolbar) ✗

module.exports = function (shipit) {

  // require('shipit-deploy')(shipit)

  shipit.initConfig({
    default: {
      workspace: '/tmp/papp',
      deployTo: '/tmp/papp/deployTo',
      // repositoryUrl: 'https://github.com/user/repo.git',
      ignores: ['.git', 'node_modules'],
      // rsync: ['--del'],
      keepReleases: 2,
      // key: '/path/to/key',
      // shallowClone: true
    },

    prod: {
      servers: [{
        host: 'tutor.XXXXXXX.com',
        user: 'ubuntu'
      }]
    }
  })

  let destDir = '/opt/rikai/bot-env/tutor/public/static'

  shipit.task('pwd', function () {
    shipit.log('pwd')
    return shipit.remote('pwd')
  })

  shipit.blTask('build', function () {
    shipit.log('local build')
    shipit.local('npm run build').then(
      console.log('finished build')
    )
  })

  shipit.blTask('sync', async function () {
    shipit.log('sync to ', destDir)
    await shipit.remoteCopy('dist', destDir)
    shipit.log('sync done')
  })

  shipit.blTask('checkDir', async function () {
    let cmd = 'mkdir -p ' + destDir
    shipit.log('cmd', cmd)
    await shipit.remote(cmd)
    shipit.log('start sync')
  })

  shipit.task('deploy', async function () {
    shipit.start('build')
    shipit.start('checkDir')
    shipit.start('sync')

    shipit.log('syncCheck done')
  })

}

PS I'm just using rsync to deploy for various reasons.

got it I have to return the result from the task...


I tryed styling the Mui dataTable like you suggested and it still isn't working

I tryed styling the Mui dataTable like you suggested and it still isn't working
Here is my code
import MUIDataTable from "mui-datatables"; import { createTheme, ThemeProvider } from "@mui/material/styles";
function Customers() { const columns = ["Name", "Company", "City", "State"];
const data = [ ["Joe James", "Test Corp", "Yonkers", "NY"], ["John Walsh", "Test Corp", "Hartford", "CT"], ["Bob Herm", "Test Corp", "Tampa", "FL"], ["James Houston", "Test Corp", "Dallas", "TX"], ["James Houston", "Test Corp", "Dallas", "TX"], ];
const options = { filterType: "multiselect", responsive: "scroll", };
return ( <ThemeProvider theme={createTheme({ components: { MUIDataTableBodyCell: { styleOverrides: { root: { backgroundColor: "#FF0000", }, }, }, }, })} > <MUIDataTable sx={{ height: "100px" }} title={"Customers"} data={data} columns={columns} options={options} /> ); }
export default Customers;

I'm running into a similar problem.
It appears that I can override the Style of an existing mui Component, but the Style is not reflected in the mui-datatables.
[ style overrides ]
ok => MuiTableRow, MuiTableCell, ...etc (mui official className)
failed => MUIDataTableHeadCell, MUIDataTableHeadRow, ...etc (mui-datatable className)
styleOverrides
It was working fine until February 19.
Originally posted by @matsuu2tatsuya in https://github.com/gregnb/mui-datatables/issues/1842#issuecomment-1047418962

Any solutions?

Seems I also not able to style this MUI-datables using mui 5.5.0 themes.

Anyone else still having this issue? Tried the override as in #162 but it's not working
export const getMuiTheme = () =>     createTheme({         overrides: {             MUIDataTableHeadCell: {                 fixedHeaderCommon: {                     backgroundColor: "blue"                 }             }         }     });
I'm actually just trying to make the column label bold but I can't get any changes to apply

@StefanIgnjatovic12 just downgrade to 4.0.0. That's the only thing that seemed to work for me

It's fixed in the PR #1882.  It just needs to get merged.

Seems like this project is no longer actively maintained...
A workaround that I can offer (to yarn users) is to pin tss-react to the newer version in your package.json like so:
"resolutions": {
    "tss-react": "3.6.0"
},
"dependencies": {
    "tss-react": "^3.6.0"
}

Once the PR get merged you will be able to remove tss-react from your dependencies.


LogisticRegression for ecoli dataset

Performed Logistic regression on ecoli dataset and tweaked the two parameters (C and penalty).

@zairah10 / @AkshayVarik: I don't see the code that you're using for saving the results to a file. Can you please commit that code? Everything seems to be running fine for me.
BTW: If you're not using the IPython Notebook (although I highly recommend using it), the file format you should use is .py, e.g., LogisticRegression.py for the file you committed yesterday.

Hi Randy, since we were facing problems in saving the ouput file, we just copied the results in an excel sheet. And we used IPython (Jupyter) only for the codes that we committed yesterday.

I see. Can you please commit (or paste the code here) that produces the error, along with the full error message? We can try to clear this issue up at our meeting next week, since it won't be scalable to copy-and-paste the results into Excel spreadsheets in the long-term.
In the meantime, focus on coding up all of the classifiers that we're looking into along with their parameters.

Hi Randy
The code that produces the error is this (Its the same one that you wrote
in the Basic Parameter Sweep example). Yes we definitely need to get over
the trouble in order to be able to systematically save our work in the
future. And both me and Zairah are focusing our attention towards getting
the code for all the algorithms with the parameter mentioned in the
document readied.
import os
import gzip
if not os.path.isdir('benchmark_results'):
os.mkdir('benchmark_results')
with
gzip.open('benchmark_results/DecisionTreeClassifier-benchmarks.tsv.gz',
'w') as out_file:
header_text = '\t'.join(['dataset',
'model',
'parameters',
'testing_score']) + '\n'
out_file.write(header_text.encode('UTF-8'))
for (dataset, model, params) in all_model_scores:
    param_string = ''
    param_string += 'max_depth={},'.format(params[0])
    param_string += 'max_features={},'.format(params[1])
    param_string += 'criterion={}'.format(params[2])

    for testing_score in all_model_scores[(dataset, model, params)]:
        out_text = '\t'.join([dataset[5:-7],
                              model,
                              param_string,
                              str(testing_score)]) + '\n'
        out_file.write(out_text.encode('UTF-8'))

Thanks
On Sat, Feb 13, 2016 at 5:15 PM, Randy Olson<EMAIL_ADDRESS>wrote:

I see. Can you please commit (or paste the code here) that produces the
error, along with the full error message? We can try to clear this issue up
at our meeting next week, since it won't be scalable to copy-and-paste the
results into Excel spreadsheets in the long-term.
In the meantime, focus on coding up all of the classifiers that we're
looking into along with their parameters.
—
Reply to this email directly or view it on GitHub
https://github.com/rhiever/sklearn-benchmarks/pull/3#issuecomment-183765275
.

--
Akshay Varik
Graduate Student- Batch of 2016
Department of Mechanical Engineering and Applied Mechanics
University of Pennsylvania, Philadelphia, PA 19104
Ph: +1<PHONE_NUMBER>

One thing that may be worth trying is changing this line:
with gzip.open('benchmark_results/DecisionTreeClassifier-benchmarks.tsv.gz', 'w') as out_file:

to
with gzip.open('benchmark_results/DecisionTreeClassifier-benchmarks.tsv.gz', 'wb') as out_file:

Let me know if that works. Without seeing the specific errors you're encountering, it is difficult to debug the issue. If you can find the specific errors that are occurring, then we can look more closely at the issue.

Hey Randy
The error persists. And what exactly is the console? I tried to look up
online to see when I can get  ore info of the error. I downloaded the
console to which I have access on the anaconda prompt. But havent been able
to figure out how to get the details of the error as yet.
On Sat, Feb 13, 2016 at 5:31 PM, Randy Olson<EMAIL_ADDRESS>wrote:

One thing that may be worth trying is changing this line:
with gzip.open('benchmark_results/DecisionTreeClassifier-benchmarks.tsv.gz', 'w') as out_file:
to
with gzip.open('benchmark_results/DecisionTreeClassifier-benchmarks.tsv.gz', 'wb') as out_file:
Let me know if that works. Without seeing the specific errors you're
encountering, it is difficult to debug the issue. If you can find the
specific errors that are occurring, then we can look more closely at the
issue.
—
Reply to this email directly or view it on GitHub
https://github.com/rhiever/sklearn-benchmarks/pull/3#issuecomment-183766447
.

--
Akshay Varik
Graduate Student- Batch of 2016
Department of Mechanical Engineering and Applied Mechanics
University of Pennsylvania, Philadelphia, PA 19104
Ph: +1<PHONE_NUMBER>

How are you running the script currently? Do you run it on the command line (say, in cygwin?) with python [SCRIPT NAME]?


Question: Reconnect / retry mechanism

Hi 👋
I have a question, as I could not find a reconnect/retry mechanism for this client yet. Is it planned to add a reconnect / retry mechanism, or do you have an example of a consumer that has a reconnect/retry mechanism?
Context:

we're using go-amqp to consume an amqp Queue indefinitely. From time to time there may be errors, mostly in non-prod environments, and we'd need to detect these and reconnect (at best with some sort of backoff algorithm, etc). We're currently implementing such a mechanism here: https://github.com/RedHatInsights/authz/blob/umb-reconnects/infrastructure/repository/messaging/UMBMessageBusRepository.go but somehow it feels like "this should be provided by the library, if possible".

I searched a bit for such thing, but all I found so-far is https://github.com/isayme/go-amqp-reconnect/blob/master/rabbitmq/rabbitmq.go which is for an amqp 0.9.1 client - and now due to the lack of results, I am questioning myself if we're completely on the wrong track here and there is a hidden mechanism we just don't know of 😅
Thanks!

@richardpark-msft and I have discussed this in the past, but nothing has been implemented in this module yet.
We do have retry/reconnect logic in our EventHubs and Service Bus modules.  Here are a few links to the implementation in Service Bus.  Note that some of the error conditions are specific to Service Bus, so if you're using a different broker then some of the logic won't apply.
Retry loop for sending/receiving a message
Predicate for determining recovery kind
Conceptually it's not that different from your retry/reconnect mechanism.  Wait for a message and if an error is received, determine if it requires a reconnect (you should add *amqp.SessionError to your list of reconnect errors).

@DGuhr, I can't speak for why other libraries don't have retries, but some things in Azure this more complicated.
For instance:

In Azure Service Bus, losing a link means you can't Accept() messages anymore (ie, those are all invalidated) so you have to attempt to settle via a "backup" route (not a general AMQP concept). So rather than have the AMQP stack waste operations we'd need to know immediately.
In Azure Event Hubs when you restart a link you want to continue from where you left off, not start at the beginning or end. So the restart would need to send in an updated set of link parameters.
We use a separate method for authentication that might require refreshing/reauthorizing credentials. So we'd need that to be called on every retry as well.

In the end most of our example designs just ended up having to be so general that it just ended up being more straightforward to handle it on a per-call-site basis.
BTW, if you do find that hidden mechanism PLEASE LET US KNOW. :)


 The game is played by laying out a circle of numbered tiles in a circle according to the following rules:

The game starts with the 0 tile at the top of the circle. This is now the 'current' tile. This tile is placed by the first player, player 0.
Each round, the next player skips next tile clockwise from the current tile, and places the next numbered tile.
The game continues until all the tiles have been laid.
Tile positions are labeled, starting with the zero in the 0th place, then increasing the number of the position clockwise around the circle.
The score is calculated by having each player multiply the number on each tile they laid with the number of the position the tile was laid in, and adding them up.

Because you're so smart (and these kids obviously aren't), you quickly realize that this game is entirely deterministic and that, given the number of players and the number of tiles, you can always know which player will win.
Business Rules/Errata

You will be given the number of players and the number of tiles in the game, as positive integers.
You should return the score of the winning player, i.e. the highest score achieved at the end of the game.

Examples
Here's an example of how a game will go with 16 tiles and 4 players. The inner ring represents the number of the tile, the middle ring is the number of the position, and the outer ring is the number of the player.
Round 1:                 Round 2:                 Round 3:

        0                        0      1                 0      2
         0                        0    1                   0    1     1
          0  #                     0  1                     0  2    2
       #        #               #        #               #        1
     #            #           #            #           #            #
    #              #         #              #         #              #
    #              #         #              #         #              #
     #            #           #            #           #            #
       #        #               #        #               #        #
          #  #                     #  #                     #  #

Round 4:                 Round 5:                Round 6:

        0      2                 0      0                0      0
         0    1     1             0    1     2            0    1     2
          0  2    2   3            0  4    2   1           0  4    2   1
       #        1   3           #        2   3          #        2   3
     #            3           #            1          #            5
    #              #         #              3 4 3    #              1 4 3
    #              #         #              #        #              3 5 3
     #            #           #            #          #            #
       #        #               #        #              #        #
          #  #                     #  #                    #  #

                          Round 16:

                                  0      0
                              3    0    1     0
                          3    15   0  8    2   1
                            14   15       4   3
                               7            9
                         2 13 14             2  4 2
                         3 12  3             10 5 2
                              13            5
                            11   6        11  6
                           1   10   12 1    7   1
                              2    9    8     3
                                  0      1

After 16 rounds, the scores are:

Player 0: 124
Player 1: 208
Player 2: 300
Player 3: 436

I'm having trouble following the example, maybe because I'm in a loud coffee shop. Aren't they supposed to be skipping spaces?

So, the spaces aren't really there, they're just placeholders to make the ASCII art less confusing (at least, that was the intention). On the first round, the "circle" is just one tile, on the second round, it's basically a straight line between two tiles, third round it's a triangle, fourth round it's a square, and so on.

Oh, and we did this one already (April 12, 2022). Gonna close this issue.


Update cloud-enabling-continuous-integration-with-github.md

Description & motivation
dbt Cloud cannot checkout commits from a fork of the repo. See ZD ticket 23941 (internal only) for more info.
Pre-release docs
Is this change related to an unreleased version of dbt?

[ ] Yes: please

update the base branch to next
add Changelog components: <Changelog>[New/Changed] in v0.x.0</Changelog>
add links to the "New and changed documentation" section of the latest Migration Guide

[x] No: please ensure the base branch is current
[ ] Unsure: we'll let you know!

hey @jeremyyeo - great write up! i just wanted to double check this was still up to date?

hey @jeremyyeo - great write up! i just wanted to double check this was still up to date?

yea we should still merge this.

hey @jeremyyeo - great write up! i just wanted to double check this was still up to date?

yea we should still merge this.

thanks @jeremyyeo and merged w small tiny tweaks! great callout on this!


no longer works in windowed maximized mode

I've been using AutoFish for over a month without problem, but I can't seem to get it to detect the bobber any more.  Could have also been the latest Turtle WOW update as well perhaps? I did notice that it the cursor WILL move AFTER I stop the bot sometimes to where the bobber is.
EDIT: Doesnt seem to work in Windowed >> Maximized mode anymore. If i untick "maximized" it seems to work OK.

Just tested it. Works properly with both modes for me. Does an old version works properly if you test it now? Have you tried to launch the bot as admin?

Might have something to do with vanilla fixes? Does that help at all?


Remove redundant definiton of C.

Fixes #29.

Merging despite failure because that failure already existed.


Have no notice when state changed after a task is disabled and re-enabled.

Hi,
Kapacitor version: 0.13
My scenario is:

create a task A
change the value of metric greater than threshold to trigger an alert (I can receive a notice that an alert is triiggerd)
disable the task A
change the value of metric lower than threshold
enable the task A

I want to receive a notice of OK when the task is re-enabled.
But, there is no either notice.
I find the DOT is clean when disable and re-enable a task.
I think this is a useful feature.
How about you?
Thanks

See #744

@phemmer  Thanks! I got it.
Do you have any way to temporarily circumvent?


Can I keep timezone in index of datetime ?

Hi, I have a dataframe with index of datetime type, I found timezone was converted automatically when openning the dataframe by using pandasgui, is there any way to prevent that ? thank you, for example as below.
original index: 2021-01-11 15:20:00+08:00
index showing: 2021-01-11T07:20:00.000000000

PandasGUI just renders columns by converting the values to string, you're seeing it displayed the same way as if you took your date column and applied .astype(str).

original index: 2021-01-11 15:20:00+08:00

Where do you see it rendered like that? I'd be open to changing this but there are a lot of possible timestamp formats and wondering what made you chose that one.

PandasGUI just renders columns by converting the values to string, you're seeing it displayed the same way as if you took your date column and applied .astype(str).

original index: 2021-01-11 15:20:00+08:00

Where do you see it rendered like that? I'd be open to changing this but there are a lot of possible timestamp formats and wondering what made you chose that one.

Just print a dataframe containing datetime  column with timezone info, you will see that in console.

Just print a dataframe containing datetime  column with timezone info, you will see that in console.

It looks correct for me, can you give me the dataset you used?
import pandas as pd
df = pd.read_csv(r"https://github.com/adamerose/datasets/raw/master/trump_tweets.csv", parse_dates=['date'])
df['date2'] = df.date.dt.tz_localize('UTC').dt.tz_convert('Asia/Kolkata').astype(str)

from pandasgui import show
show(df)

It looks correct for me, can you give me the dataset you used?
import pandas as pd
df = pd.read_csv(r"https://github.com/adamerose/datasets/raw/master/trump_tweets.csv", parse_dates=['date'])
df['date2'] = df.date.dt.tz_localize('UTC').dt.tz_convert('Asia/Kolkata').astype(str)

from pandasgui import show
show(df)

Sure, see the attachment
datetime_index.zip

Sure, see the attachment
datetime_index.zip

Huh okay weird... I get the same issue with your pickle but I still can't reproduce it myself, even with df = df.set_index('date2') added to my above snippet.
I played with yours and found that the issue appears when you use df.index.values which is used in the PandasGUI DataFrame viewer. Usually .values matches what you see when you simply print the df but yours somehow doesn't.

Huh okay weird... I get the same issue with your pickle but I still can't reproduce it myself, even with df = df.set_index('date2') added to my above snippet.
I played with yours and found that the issue appears when you use df.index.values which is used in the PandasGUI DataFrame viewer. Usually .values matches what you see when you simply print the df but yours somehow doesn't.

Sure, see the attachment
datetime_index.zip
In your case, timezone info would be gone if you set date2 as index .

Thanks, managed to figure out the root cause... you get different results depending whether you use the DataFrame value directly or pull it out of the .values array.
import pandas as pd
df = pd.read_csv(r"https://github.com/adamerose/datasets/raw/master/trump_tweets.csv", parse_dates=['date'])
print(str(df['date'][0]))
print(str(df['date'].values[0]))

2009-05-04 13:54:00
2009-05-04T13:54:00.000000000

Sure, see the attachment
datetime_index.zip
In your case, timezone info would be gone if you set date2 as index .

Thanks, managed to figure out the root cause... you get different results depending whether you use the DataFrame value directly or pull it out of the .values array.
import pandas as pd
df = pd.read_csv(r"https://github.com/adamerose/datasets/raw/master/trump_tweets.csv", parse_dates=['date'])
print(str(df['date'][0]))
print(str(df['date'].values[0]))

2009-05-04 13:54:00
2009-05-04T13:54:00.000000000


Combine two patterns through single node

As a user I want to select two nodes, an operator, and provide a name for the combination in order to create a combined pattern.

[ ] Warn when not exactly one node of each pattern was selected
[ ] Warn if the selected nodes are of different types
[ ] Create new pattern with the given name

Not seeing the use case really


op-batcher: support span batches

op-batcher v1.4.0-rc.2 introduced span batches. We should bundle these batches as blobs to celestia.

implemented in<EMAIL_ADDRESS>


Switch tabs to automatically follow focus by default

We’ll want to follow https://www.w3.org/TR/wai-aria-practices/#kbd_selection_follows_focus
So a default of follow focus with an option to go to manual activation for async tabs.

same as #254?

Similar, we can probably consolidate them


Added Accelerate Framework

Accelerate Implementation for BLAS and vDSP APIs.

Hi @afaruqui, I'm your friendly neighborhood Microsoft Pull Request Bot (You can call me MSBOT). Thanks for your contribution!

In order for us to evaluate and accept your PR, we ask that you sign a contribution license agreement. It's all electronic and will take just minutes. I promise there's no faxing. https://cla.microsoft.com.

TTYL, MSBOT;

Does it make sense to squash these into a single commit?

Yes and "squash"ed

Please for mine perfect


How to disable controls of video tag?

in RTCMultiConnection.js:
mediaElement.controls = true;

It always show controls on video tag, but I want to custom the control, how to ?

I see https://github.com/muaz-khan/RTCMultiConnection/blob/master/demos/Audio-Video-Screen.html

@tearsofphoenix How did you go about solving this? Your link doesn't work anymore and I am unable to find a demo title "audio-video-screen.html".


[Docs] GrraphQL server port

Current State:
The Network Ports section of the Meshery docs does not list the port used for the GraphQL server.
Desired State:
This table should list the network port and protocol.
Support for streaming should be considered as well.

Contributor Resources

Meshery documentation site
Meshery documentation source
Instructions for contributing to documentation

@kumarabd the port number has been documented.


Here is a new theme for the NGU

I want everyone (@woodrow3  and @TheEdmundFitzgerald ) to review it. Basicly just ckeck if you like how it looks and make seggestions. This will likely become the new theme for the NGU if you guys like it.

Alright whatever. You 2 are never going to respond. I'll just merge it in. the other looks pretty bad.

I like the font
On Fri, Dec 20, 2024 at 4:22 PM zukas97 @.***> wrote:

Merged #5 https://github.com/zukas97/NGU/pull/5 into main.
—
Reply to this email directly, view it on GitHub
https://github.com/zukas97/NGU/pull/5#event-15737125409, or unsubscribe
https://github.com/notifications/unsubscribe-auth/BM7D6T7QVPTL5KFTIPYEA632GSDAXAVCNFSM6AAAAABT7RZWM2VHI2DSMVQWIX3LMV45UABCJFZXG5LFIV3GK3TUJZXXI2LGNFRWC5DJN5XDWMJVG4ZTOMJSGU2DAOI
.
You are receiving this because you were mentioned.Message ID:
@.***>


Add global variables for sub-folder routing

I am working on multiple applications which will be hosted under the same domain name.
for eg. http://example.com/hotels (standalone react app), http://example.com/coupons (another standalone react app) etc.
In development we used url structure to route to url http://localhost:3000/* and now in production the urls to redirect to  http://example.com/* which thus breaks the app since in production it should be like http://example.com/hotels/*
Are there any changes i can make to this starter kit such that all urls get a placeholder value added to the them....
or will i have to individually change all urls from /* to /hotels(app-name)

Maybe you can change the below at line 63 of src/server.js
app.use((req, res) => {
  if (__DEVELOPMENT__) {
    // Do not cache webpack stats: the script file would change since
    // hot module replacement is enabled in the development env
    webpackIsomorphicTools.refresh();
  }

to
l```
et path = '*';
if (DEVELOPMENT) {
path = '/hotels';
}
app.use( path , (req, res) => {
if (DEVELOPMENT) {
// Do not cache webpack stats: the script file would change since
// hot module replacement is enabled in the development env
webpackIsomorphicTools.refresh();
}


Fix tachometer

There was a problem where our tachometer implementation using RAF would not paint the elements onto the page / do style recalculation before measuring.
I instead switched from using the lit element test-fixture and instead simply use lit-html's render method and checking the first child and awaiting updateComplete + forcing style recalc w/ offsetWidth.
If there is no first child with updateComplete we just simply await a RAF.
fixes #312.

CC: @sorvell @frankiefu

tested normal material checkbox vs material checkbox with extra divs:

compared lit-html vs old RAF implementations

Old implementation showed that it may be 0-4% slower and new implementation shows that it is consistently slower at4-12% slower.


Update get_userInfo.go 获取用户信息示例添加UserAccessToken参数

获取用户信息示例添加UserAccessToken参数，示例程序缺少参数
user access token is empty

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


Display gif as non animated image by default

Is it possible to opt out of displaying animated images by default? (its causing some memory issues). I only want to display the animated image using AnimatedImageView when the user chooses to do so.

Currently no. Maybe we could implement an option to load first several frames for a GIF in a later version.

besides memory issues it's also related to https://github.com/onevcat/Kingfisher/issues/375

Should be added in version 3.4.0. Use .onlyLoadFirstFrame for that purpose.


POST Request in Heroku - 403 Forbidden

I'm new to using Requests, and I'm trying to scrape a schedule of classes. My POST request has resulted in "403 Forbidden" on Heroku, but works fine on my local machine. Here's a code snippet I'm having trouble with in my application, using Python 2.7.4, Bottle, BeautifulSoup4, and of course, Requests.
import requests
from bs4 import BeautifulSoup as Soup

url = "https://telebears.berkeley.edu/enrollment-osoc/osc"
code = "26187"
values = dict(_InField1 = "RESTRIC", _InField2 = code, _InField3 = "13D2")
html = requests.post(url, params=values)
soup = Soup(html.content, from_encoding="utf-8")

sp = soup.find_all("div", {"class" : "layout-div"})[2]
print sp.text

It gives me back the string "Computer Science 61A P 001 LEC:" in development. However, when I tried to run it on Heroku (using heroku run bash and then run python), I got back "403 Forbidden".
My attempts so far include manually setting User Agent headers, changing to verify=False, but neither worked. At first I thought it's the school settings, but then I was wondering why it works locally without any problem... Any explanation/suggestion would be really appreciated! Thanks in advance.

been playing around with the javascript Todoapp and using my own server url. I find that login/logout doesn't work on versions 1.1.12-min.js. I upgrated to 1.6.14 or even parse-latest.js. Both don't have any reference ParseCollections. It's been very hard figuring out how to fix it.
2016-04-25T09:53:19.298790+00:00 heroku[router]: at=info method=POST path="/parse/1/users" host=intense-hollows-60991.herokuapp.com request_id=9cb5eaf9-603e-4b98-9f78-35058ca0dfd6 fwd="<IP_ADDRESS>" dyno=web.1 connect=0ms service=51ms status=403 bytes=466/not well-formed
2016-04-25T09:54:06.692075+00:00 heroku[router]: at=info method=POST path="/parse/1/login" host=intense-hollows-60991.herokuapp.com request_id=d934f856-85be-4315-baf4-7bb64ac501c8 fwd="<IP_ADDRESS>" dyno=web.1 connect=1ms service=14ms status=403 bytes=466/not well-formed
http://www.mobileparadigm.co.uk/urls/cft_access/services/cft/

@arkangelx I'm sorry, what specifically is your issue and what does it have to do with the requests library?

i have pointed my todoapp to my own Parse.serverUrl as instructed, however I can’t perform a login/sign up now. I can save objects easily to my account with mLabs. So in essence
Parse.$ = jQuery;
// Initialize Parse with your Parse application javascript keys
Parse.initialize("5N5FqrkAmn1C8g6hVHvb","aFZ7RUqpgrUVZrDKfM6f”); // this works using the standard Parse sdk WITHOUT hosting myself (login/signup save data)
adding the line below to point to the heroic setup after importing all my data from my dashboard now doesn’t allow me to sign up
Logs
2016-04-25T09:54:06.692075+00:00 heroku[router]: at=info method=POST path="/parse/1/login" host=intense-hollows-60991.herokuapp.com request_id=d934f856-85be-4315-baf4-7bb64ac501c8 fwd="<IP_ADDRESS>" dyno=web.1 connect=1ms service=14ms status=403 bytes=466
So I tried to change the version of the parse sdk I’m using from 1.1.12-min.js to 1.6.14-min.js or parse-latest.js, this throws an error saying that Parse.Collections isn’t referenced.
Parse.serverURL = 'https://intense-hollows-60991.herokuapp.com/parse/' https://intense-hollows-60991.herokuapp.com/parse/' (login/signup save data)

On 25 Apr 2016, at 11:27, Cory Benfield<EMAIL_ADDRESS>wrote:
@arkangelx https://github.com/arkangelx I'm sorry, what specifically is your issue and what does it have to do with the requests library?
—
You are receiving this because you were mentioned.
Reply to this email directly or view it on GitHub https://github.com/kennethreitz/requests/issues/1542#issuecomment-214251913

@arkangelx That really seems to have nothing to do with the Requests library. The sample code you're providing appears to be Javascript code, which of course is not applicable to this Python library. So once again: where does the Python Requests library come into your problem?

My apologies, I posted to the wrong session

On 25 Apr 2016, at 11:35, Cory Benfield<EMAIL_ADDRESS>wrote:
@arkangelx https://github.com/arkangelx That really seems to have nothing to do with the Requests library. The sample code you're providing appears to be Javascript code, which of course is not applicable to this Python library. So once again: where does the Python Requests library come into your problem?
—
You are receiving this because you were mentioned.
Reply to this email directly or view it on GitHub https://github.com/kennethreitz/requests/issues/1542#issuecomment-214257644

Just seeing this — my best guess is that the server in question is blocking requests from AWS (which Heroku is hosted on). Many edge CDNs offer that as a feature.
e.g. there's nothing un-vanilla about Heroku's Python, so I highly doubt it's not something network related.

any way to get around this? An Uber API is giving my node app hosted on AWS EC2 403s...

There's a heroku addon called "priximo" which allows you to proxy your way out

There's another one too

do you know how to set it up properly? my app still gets a 403 when it sends a request to the Uber API

I'm shutting down this conversation so that well over 1000 folks don't get email notifications for an issue unrelated to Requests.


Add support for a max hosts per line param when calling Flush().

Changed my mind about this feature. If someone wants it, let me know.


Integrate parsedatetime

This wonderful library can analyse dates in a natural way and parse it:
https://pypi.python.org/pypi/parsedatetime/
It would be a great fit for the .get() method of arrow.

While an interesting idea, introduces a strong dependency on that library for the get method.

Reopening. There seems to be a desire for this functionality. No ETA on when it'll be addressed.

This doesn't have to be a forced dependency, get could use parsedatetime when it's available and your built-in parser is unable to parse something. You would lose functionality if you tried to drop it in as a replacement.

It looks like parsedatetime is no longer maintained (last commit May 2017).


Interval based send suggestion needed

Hello all,
We're looking for some suggestions. We want the OPC Publisher to periodically send OPC values to the cloud, and not on a datachange. We have used the heartbeat functionality which seems to be doing more or less what we need, but data changes are sent as well. If we have a heartbeat every 10 seconds and the value changes in between two heartbeats, we receive an extra message for the datachange in between heartbeats, which we don't want.
So the heartbeat only works partly for us, we don't want that message on a data change. I've looked at the possibility to set the DataChangeFilter / DataChangeTrigger for this purpose , but it does not seem to be possible (yet?).
I don't feel much for creating a customized version of the OPC Publisher at this point. So basically the question is: how can we let the OPC Publisher only sent values periodically, without the data changes themselves? As always, thank you in advance!

Hello @b-enigma-con,
What if you set the PublishingInterval = SamplingInterval = heartbeat interval? e.g. 10 seconds like in your example.
The publisher will then only generate data-changes in the same cycle as heartbeats.

Sounds like a good suggestion, I will try this and let you know. Thank you.

Not yet (other priorities came up), but will let you know the outcome. I expect to pick this up in the coming 2 weeks.

@b-enigma-con Closing this issue due to inactivity. Please re-open if needed.

I finally managed to find some time to test this suggestion. I can confirm that it works exactly as I wanted.

In 2.9.0-preview4 we support cyclic reads now. "UseCyclicRead": true on a node id will enable this cacapbility.  Let me know if this works for you.


How to handle/consume binary data

Hi,
I have requirement where my node consumer will be consuming binary data. I get below 'message' object on receiving binary data:
{"_readableState":{"objectMode":false,"highWaterMark":0,"buffer":[],"length":0,"pipes":null,"pipesCount":0,"flowing":null,"ended":false,"endEmitted":false,"reading":false,"sync":true,"needReadable":false,"emittedReadable":false,"readableListening":false,"defaultEncoding":"utf8","ranOut":false,"awaitDrain":0,"readingMore":false,"decoder":null,"encoding":null},"readable":true,"domain":null,"_events":{},"_eventsCount":1,"command":"MESSAGE","headers":{"content-length":10,"expires":"1463061403952","destination":"/topic/test.topic.0","subscription":"1","priority":"4","message-id":"ID:shakti01.hyd.deshaw.com-51570-1462974867310-1:1:1:1:28","timestamp":"1462975003952"},"ackType":"ACK"}
I am not sure how to consume binary data with this API. Could you please help

The message object extends Node's stream.Readable class.
I imagine plenty of resources can be found on the web that show how to handle binary data in Node.  Read the official documentation of Node's Buffer and stream.Readable classes.


facebook redirect login with modsecurity

I've problem with facebook redirect login after install modSecurity
this what i see in apache log :
  ModSecurity: Access denied with code 403 (phase 2). Pattern match "([\\\\~\\\\!\\\\@\\\\#\\\\$\\\\%\\\\^\\\\&\\\\*\\\\(\\\\)\\\\-\\\\+\\\\=\\\\{\\\\}\\\\[\\\\]\\\\|\\\\:\\\\;\\"\\\\'\\\\\\xc2\\xb4\\\\\\xe2\\x80\\x99\\\\\\xe2\\x80\\x98\\\\`\\\\<\\\\>].*?){4,}" at ARGS:code. [file "C:/Apache/conf/crs/activated_rules/modsecurity_crs_41_sql_injection_attacks.conf"] [line "159"] [id "981173"] [rev "2"] [msg "Restricted SQL Character Anomaly Detection Alert - Total # of special characters exceeded"] [tag "OWASP_CRS/WEB_ATTACK/SQL_INJECTION"]

is there any way to exclude facebook redirects ?!
redirect link : example.com/?code=FACEBOOK_REDIRECTION_CODE

Looks like you're using CRS. This really looks like an issue with how SQL special char detection worked in CRS 2.x. This issue has been fixed in the 3.x branch (https://github.com/SpiderLabs/owasp-modsecurity-crs/tree/v3.0.0-dev) take a look. I think you'll find it performs a bit better :)


Use #register_resource_list_manipulator in extension

Hi @tdreyno,
Given I want to write an extension which needs to modify the ressources list. Is it safe to use [#register_resource_list_manipulator(https://github.com/middleman/middleman-blog/blob/master/lib/middleman-blog/extension.rb#L136) in my extension? Is it part of the public API?
Cheers,
Dennis

If you need to register multiple separate manipulators, sure, but if you only need it once you can make a method which will automatically self-register:
class Test < Middleman::Extension
  def manipulate_resource_list(resources)
    resources
  end
end

Ah, ok. Thanks a lot.


[New game]: Scroll dark game

🎮 Game Request
Game logic and basic description

adding this game
Point down the features
Game points
Select program in which you are contributing
GSSoC24
Code of Conduct

[X] I follow CONTRIBUTING GUIDELINE of this project.

/assign-me


[3.2] Use 2-phase setup in JavaScript.

Make the first iteration as soon as the canvas is setup, avoiding a black screen before the next animation frame is requested.
Also create OS and do setup before syncing FS to avoid crash when IDBFS access is denied.
Fixes #39471
Fixes #39495
3.2 version of #39537

Thanks!


[WIP] xdg-shell-v6: don't destroy role resources on unmap

The motivation for this is:

get_popup and get_toplevel allocate role-specific resources.
On the first non-null commit, the surface gets mapped.
On a null commit, the surface gets unmapped. It can be mapped
again with a non-null commit.
When the role object (xdg-toplevel or xdg-popup) is
destroyed, the surface is unmapped and role-specific resources
are destroyed. The client can call get_popup or get_toplevel
again on that surface.
When the xdg-surface object is destroyed, the surface is
unmapped, role-specific resources are destroyed and the surface
itself is destroyed.

TODO:

[x] zxdg-shell-v6
[ ] xdg-shell stable

Fixes #747

And also xdg shell stable changes, ofc

:+1: so far so good

This PR is ready for review.


fancy zone is too big

Microsoft PowerToys version
0.37.2
Running as admin

[X] Yes

Area(s) with issue?
FancyZones, FancyZones Editor
Steps to reproduce
I created zone for my primary monitor, and then used the zone for my second monitor which have smaller resolution

✔ Expected Behavior
I want for my zone is applicable to all my monitor with different resolution

❌ Actual Behavior
The zone is too big for my second monitor which have smaller resolution

Other Software
No response

@rizky-r-lab
canvas layout are specific for the monitor that they have been created for.
Create a new layout for the smaller monitor.
In the future we will prevent to apply a layout created for a different screen resolution.


Invalid SQL queries when joining query with Array of referenced Objects

I'm trying to query a User and its groups.
This generates an invalid SQL Query:
SELECT * FROM users INNER JOIN groups AS groups ON groups.id IN users.group_ids

..resulting in runtime errors.
This is a minimal representation of what I'm trying to do (and how you can reproduce the error):
require "sqlite3"
require "onyx/sql"
require "onyx-sql/converters/sqlite3"

class User
  include Onyx::SQL::Model

  schema users do
    pkey id : Int32, converter: SQLite3::Any(Int32)
    type groups : Array(Group), key: "group_ids", converter: SQLite3::Any(Group)
  end
end

class Group
  include Onyx::SQL::Model

  schema groups do
    pkey id : Int32, converter: SQLite3::Any(Int32)
  end
end

puts Onyx::SQL.query(
  User.select("*").join(groups: true) do |x|
  end
)

This results in the following errors:
SQLite3 Error:
Unhandled exception: no such table: users.group_ids (SQLite3::Exception)
  from lib/sqlite3/src/sqlite3/statement.cr:81:5 in 'check'
  from lib/sqlite3/src/sqlite3/statement.cr:4:5 in 'initialize'
  from lib/sqlite3/src/sqlite3/statement.cr:2:3 in 'new'
  from lib/sqlite3/src/sqlite3/connection.cr:24:5 in 'build_prepared_statement'
  from lib/db/src/db/connection.cr:7:15 in 'fetch_or_build_prepared_statement'
  from lib/db/src/db/session_methods.cr:58:9 in 'build'
  from lib/db/src/db/pool_prepared_statement.cr:37:16 in 'build_statement'
  from lib/db/src/db/pool_prepared_statement.cr:53:22 in 'initialize'
  from lib/db/src/db/pool_prepared_statement.cr:11:5 in 'new'
  from lib/db/src/db/database.cr:89:7 in 'build_prepared_statement'
  from lib/db/src/db/database.cr:7:15 in 'fetch_or_build_prepared_statement'
  from lib/db/src/db/session_methods.cr:23:9 in 'build'
  from lib/db/src/db/query_methods.cr:38:7 in 'query'
  from lib/onyx-sql/src/onyx-sql/repository/query.cr:9:11 in 'query'
  from lib/onyx-sql/src/onyx-sql/repository/query.cr:23:7 in 'query'
  from lib/onyx-sql/src/onyx-sql/repository/query.cr:34:7 in 'query'
  from lib/onyx/src/onyx/sql.cr:21:5 in 'query'
  from src/test.cr:24:1 in '__crystal_main'
  from /usr/lib/crystal/crystal/main.cr:97:5 in 'main_user_code'
  from /usr/lib/crystal/crystal/main.cr:86:7 in 'main'
  from /usr/lib/crystal/crystal/main.cr:106:3 in 'main'
  from __libc_start_main
  from _start
  from ???

PG error:
Unhandled exception: syntax error at or near "users" (PQ::PQError)
  from lib/pg/src/pq/connection.cr:204:7 in 'handle_error'
  from lib/pg/src/pq/connection.cr:0:9 in 'handle_async_frames'
  from lib/pg/src/pq/connection.cr:163:7 in 'read'
  from lib/pg/src/pq/connection.cr:158:7 in 'read'
  from lib/pg/src/pq/connection.cr:314:31 in 'expect_frame'
  from lib/pg/src/pq/connection.cr:313:5 in 'expect_frame'
  from lib/pg/src/pg/statement.cr:18:5 in 'perform_query'
  from lib/db/src/db/statement.cr:103:14 in 'perform_query_with_rescue'
  from lib/db/src/db/statement.cr:88:7 in 'query'
  from lib/db/src/db/pool_statement.cr:39:30 in 'query'
  from lib/db/src/db/query_methods.cr:38:7 in 'query'
  from lib/onyx-sql/src/onyx-sql/repository/query.cr:9:11 in 'query'
  from lib/onyx-sql/src/onyx-sql/repository/query.cr:23:7 in 'query'
  from lib/onyx-sql/src/onyx-sql/repository/query.cr:34:7 in 'query'
  from lib/onyx/src/onyx/sql.cr:21:5 in 'query'
  from src/bin/coleus.cr:73:1 in '__crystal_main'
  from /usr/lib/crystal/crystal/main.cr:97:5 in 'main_user_code'
  from /usr/lib/crystal/crystal/main.cr:86:7 in 'main'
  from /usr/lib/crystal/crystal/main.cr:106:3 in 'main'
  from __libc_start_main
  from _start
  from ???

Here is a SQLite3 DB to test it:
test.db.zip
Just install the shards sqlite3 and onyx-sql and run DATABASE_URL="sqlite3://./test.db" crystal src/test.cr to test it yourself.

Hey, @BlobCodes,
You see, there is really no SQL standard to join array references. SQLite doesn't support arrays at all, and PG, in contrary, has more than one way to do it. I'm planning on removing the ability to join array refs in an upcoming release to make Onyx::SQL more SQL.
However, IIRC PG join should work in this case, looks like the query generated by it is flawed. I'll take a deeper look into it.
Don't forget that you can do Onyx::SQL.query(User, "SELECT * FROM users ...")) as a workaround. Onyx::SQL would never be a replacement for SQL itself. Its query builder is just a helper. It's better to rely on raw SQL in complex cases. Also remember that Query(T).build would output an SQL string which you can them modify as you want.


✨Create homepage overview section

Description
Create an overview section of the homepage
Fixes #4
Type of change

[x] New feature (non-breaking change which adds functionality)

Screenshot (optional)

Checklist

[x] My code follows the style guidelines of this project
[x] I have performed a self-review of my code
[x] I have commented my code, particularly in hard-to-understand areas
[x] My changes generate no new warnings

@JAPHETHNYARANGA, @LemmyMwaura  Waiting for a merge

Good attempt but this issue has been closed . Please pick another open issue. Hint; don't delete code already in a file when working on it.


Additional tests to check for rakudo/rakudo#2166

Additional tests in support for PR rakudo/rakudo#2727

Is this still needed/relevant?